Skip to main content
All CollectionsBuild AutomationsWorkflowsData
Escape JSON Strings to Use Python in Torq
Escape JSON Strings to Use Python in Torq

Learn how to properly escape JSON strings and take advantage of using Python code in Torq.

Updated over a week ago

It's important to escape the JSON string when using Python scripts with workflow data in JSON format. Escaping special characters helps prevent code injection attacks and ensures the JSON data is valid.

Here is how you can escape JSON in Torq:

  • jsonEscape function

  • Escape JSON string step

jsonEscape function

  • Use the Escaped string Output Utils step.

json-escape-function

Escape JSON string step

  • Use the Escape JSON string String Utils step.

escape-json-step
Did this answer your question?