Overview
The Transformer step takes the output from previous steps and reshapes it using AI. Instead of writing code to parse, map, and restructure data, you write a natural language prompt describing the transformation you want — and the AI produces the result as structured JSON. This is useful when you need to:- Extract specific fields from a large API response
- Rename and restructure data to match a target format
- Merge or flatten nested objects
- Filter an array down to matching items
- Convert between data formats (e.g. CSV-style rows to nested JSON)
How It Works
At runtime, the Transformer step receives the full execution context (trigger data, previous step outputs, database records) as input. Your prompt tells the AI what to do with that input. The AI returns the result as a JSON object in theresult output field, which downstream steps can reference.
Because the output is always JSON, the Transformer works best when your prompt is specific about the structure you expect back.
Example: extract and rename fields
Example: extract and rename fields
Prompt:Input (from a previous API Request step):Output (
result):Configuration
| Field | Description |
|---|---|
| Prompt | Natural language instructions describing the transformation to apply. Use template variables to reference specific data from previous steps. |
Writing Good Prompts
- Be specific about output structure — tell the AI exactly what keys and shape you expect back
- Reference input paths explicitly — e.g. “from the
body.dataarray” rather than “from the data” - Keep it focused — one transformation per step is easier to debug than a complex multi-part prompt
Using Libraries
The prompt editor has built-in library integration. Click Library above the editor to load a saved prompt, or click Save to store the current prompt as a reusable library item. This is useful when the same transformation logic is shared across multiple automations.Output
| Field | Type | Description |
|---|---|---|
result | any | The transformed data as JSON |
error | boolean | Whether an error occurred |
error_message | string | Error description if failed |