Edit a Code node
Add Code from the Data group, select it, and choose Edit code. The editor provides:- Python, HTML, JavaScript, and CSS language tabs.
- Syntax highlighting and line numbers.
- Live syntax diagnostics for all four languages.
- Basic JavaScript and Python type diagnostics where a mismatch can be inferred locally.
- A Problems panel with severity, message, line, and column.
Ctrl+SorCmd+Sto save.- Write with AI to generate or revise the complete file using a connected model.
Choose source or run mode
Run mode requires command-execution approval for the current workflow revision and the corresponding interpreter installed on the desktop host. A material code edit revokes the earlier execution approval.
Map any JSON-compatible value into the Code node’s
input port. A running script reads its serialized JSON from the SNDBOX_INPUT environment variable. Standard output is returned as both stdout and result; result is parsed as JSON when possible and otherwise remains a string. A non-zero exit, cancellation, missing interpreter, or timeout fails the node.
Build a localhost site
Create this graph and connect it in control-flow order:code output binding:
Each connector accepts only a Code node configured for its matching language. All three inputs are required, even when the JavaScript or CSS file is intentionally minimal. Removing one of these visual connections also removes the binding it created.
Set Port to
0 to choose an available port, or enter a fixed port from 1 to 65535. Leave Open site after building enabled to launch the URL in the default browser.
On success, Web Builder returns:
url: the completehttp://127.0.0.1:<port>/address.port: the bound loopback port.status:serving.
/, and /health returns a small JSON health response. Rerunning the same Web Builder node stops and replaces its previous server. The combined HTML, JavaScript, and CSS input is limited to 4 MB.
Localhost boundary
Web Builder binds only to127.0.0.1, so it is a local preview tool rather than production hosting or a LAN server. The site remains available while the desktop application and its local engine are running. Closing the app stops the server.
Code running inside the rendered page still has normal browser capabilities and restrictions. It can make network requests allowed by the browser and the destination’s CORS policy, so do not place credentials or protected workflow data in generated client-side source.