Custom code: code steps and Custom Actions

How to extend an automation with your own code: a code step for logic inside one flow, a Custom Action for logic you reuse.

Opening frame of the video

Watch the video

Transcript

When the standard steps are not enough, you can add your own code. In this video, we look at code steps and Custom Actions, and when to use which.

For a small piece of logic inside one flow, add a code step: in the step picker, under Utilities, select Code.

A code step runs TypeScript. It can read the message and the results of earlier steps, and it returns values for the steps after it.

Open the editor to write the code yourself, or describe what you need, and the AI assistant writes it for you.

Later steps use what the code returns. Here, the order reference becomes a label on the email.

When the same logic is needed in several flows, or it calls another system with a secret key, build a Custom Action instead.

You write and test it once, publish a version, and then add it to any flow as a step, like a standard action.

That is how to extend automations with your own code. In the next video, we test an automation safely, before it goes live.

Read more

0 comments

Please sign in to leave a comment.