loading
loading
Utilities
Run a JavaScript file between workflow stages.
overview
execute-nodejs sits between stages when catalog tools do not line up. Feed it a script FILE, run custom JavaScript, and emit FILE plus FOLDER for the next node.
Operators reach for it to normalize JSON, merge host lists, call an HTTP API, or apply logic the catalog lacks. Wire prior output into the script workspace, transform it, write results out.
Versus jq or gron, this is full Node, not a fixed JSON transform. Prefer those peers for pure reshape jobs. Prefer a Python execution node when the team writes Python instead.
use cases
Read the output of one stage, transform it in JavaScript to the exact shape the next tool wants, and write it back so two otherwise-incompatible nodes connect cleanly.
Use Node's HTTP client to enrich results from a third-party service, then emit the combined data for downstream nodes to consume.
When no existing tool covers a step, encode the logic as a Node script so the workflow keeps running end to end without manual intervention.
Aggregate findings from earlier stages and render them into the exact JSON, CSV, or HTML layout a report or alert step expects.
reference
| Name | Type | Flag | Description |
|---|---|---|---|
| script | FILE | · | JavaScript code file to execute. |
Showing key inputs. execute-nodejs exposes 1 inputs in total.
example
# execute-nodejs: run transform.js against a host list# inputs: script=transform.jsnode transform.js # writes api.example.com and app.example.com linesapi.example.comapp.example.comstaging.example.comdev.example.commail.example.comcdn.example.comvpn.example.comwww.example.comguidance
Use execute-nodejs when a stage needs custom JavaScript, data reshaping, or an API call no catalog tool covers. Prefer jq for pure JSON transforms. Prefer the Python execution node for Python logic.
Purpose-built JSON transform. Prefer it when you only reshape JSON and do not need full Node.
Flattens JSON into greppable lines. Useful for quick filters, not general scripting.
Fixed JSON-to-HTML render. A narrow transform versus arbitrary Node code.
faq
related
Spider a URL and return a wordlist for password crackers.
Wordlist and mined-word subdomain permutation.
Import, export, and upsert workflow data against an Airtable base.
Decode Android APK files into smali sources and resources.
Check a file's values against conditions and exit with a matching code.
Authenticated Route53 hosted-zone inventory.
Raw data feeds execute-nodejs, which runs a JavaScript file to transform it and writes the reshaped result as a queryable output.
Facts on this page come from the live Trickest tool library.