
Sandbox Service
The Code node depends on thesandbox service, defined in the standard Docker Compose deployment and started automatically with the rest of the stack:
SANDBOX_* environment variables in docker/envs/core-services/sandbox.env.example (worker timeout, network access via SSRF proxy, port) and through the CODE_* variables in docker/envs/core-services/shared.env.example (output limits consumed by the API).
Configuration
Define Input Variables to access data from other nodes in your workflow, then reference these variables in your code. Your function must return a dictionary containing the Output Variables you’ve declared.Language Support
Choose between Python and JavaScript based on your needs and familiarity. Both languages run in secure sandboxes with access to common libraries for data processing.- Python
- JavaScript
Python includes standard libraries like
json, math, datetime, and re. Ideal for data analysis, mathematical operations, and text processing.Error Handling and Retries
Configure automatic retry behavior for failed code executions and define fallback strategies when code encounters errors.

Output Validation and Limits
Code outputs are validated against configurable limits set on the API container:- Strings: Maximum length set by
CODE_MAX_STRING_LENGTH(default 400,000 characters); null bytes are stripped. - Numbers: Range set by
CODE_MAX_NUMBERandCODE_MIN_NUMBER(default int64 range); float precision set byCODE_MAX_PRECISION(default 20 decimal places). - Objects and arrays: Maximum nesting depth set by
CODE_MAX_DEPTH(default 5); array sizes set byCODE_MAX_STRING_ARRAY_LENGTH,CODE_MAX_OBJECT_ARRAY_LENGTH, andCODE_MAX_NUMBER_ARRAY_LENGTH.
docker/envs/core-services/shared.env.example. Tighten limits to constrain output sizes; relax them when workflows legitimately produce larger payloads.
Security Considerations
Code executes in a strict sandbox that prevents file system access, network requests, and system commands. This maintains security while providing programming flexibility. Some operations are automatically blocked for security reasons. Avoid attempting to access system files or execute potentially dangerous operations. By default, outbound network calls from sandboxed code route through the SSRF proxy; setSANDBOX_ENABLE_NETWORK=false to disable network access from sandboxed code entirely.