An action is one step a flow can run. Create it with createAction and list it in the plug’s actions.
Fields
The context
Return a result
Return anything that can be written as JSON. The next steps read it by field: a return value of { orderId: "A1", confirmed: true } lets the data picker offer orderId and confirmed. Keep the result small and flat, and return only what a flow needs. A result that is very large is kept as a file next to the run and read in full by later steps.
Fail clearly
Throw an Error with a message that tells a person what to change:
The message is shown on the failed step. It must not contain a credential, an address of your network or the raw text of a library error. A step may run for up to 10 minutes before it is stopped.
Make an action safe to repeat
A step may run twice, for example after a retry. An action that creates something should check first, or send an idempotency key that the other system understands. Use context.run.id together with the step as a stable key.
Last modified on October 26, 2026