> For the complete documentation index, see [llms.txt](https://help.tillit.cloud/tillit/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.tillit.cloud/tillit/knowledge-base/setting-up-tillit/integrations/wire-flow/advanced-configuration.md).

# Advanced Configuration

## Task Timeout

Only available for some tasks. Set a maximum execution time per task:

<figure><img src="/files/IZeb5rjHbASZ0atZOYzk" alt=""><figcaption></figcaption></figure>

| Field                 | Description                                      |
| --------------------- | ------------------------------------------------ |
| **Timeout (seconds)** | If exceeded, the task fails with a timeout error |

A timeout error can be caught by an Error Boundary event and routed to a fallback path.

{% hint style="info" %}
JSONata and Wait tasks do not support timeout. JSONata is a pass-through operation; Wait has its own timing mechanism.
{% endhint %}

## Iteration (Map)

Any task (except JSONata) can iterate over an array from the previous step's output:

<figure><img src="/files/1RtLJIusf1keBBD4nnBV" alt=""><figcaption></figcaption></figure>

| Field               | Description                                                   |
| ------------------- | ------------------------------------------------------------- |
| **Items Path**      | Path to the array in the workflow state, e.g., `$.body.items` |
| **Max Concurrency** | Number of parallel iterations (empty = unlimited)             |

When set, the task executes once per item. A **Map** label appears on the node.

## Retry Configuration

Any task (except JSONata) can retry automatically on failure:

<figure><img src="/files/uDB9x27livHANs03NT33" alt=""><figcaption></figcaption></figure>

| Field                  | Default | Description                      |
| ---------------------- | ------- | -------------------------------- |
| **Max Attempts**       |         | Number of retries                |
| **Interval (seconds)** | 1       | Initial delay between retries    |
| **Backoff Rate**       | 2.0     | Exponential multiplier per retry |

Example — Max Attempts: 3, Interval: 2, Backoff Rate: 2.0:

* 1st retry after 2s, 2nd after 4s, 3rd after 8s

## Error Handling

To catch errors from a specific task and route to a fallback:

1. Drag an **Error Boundary Event** from the palette.

   <figure><img src="/files/RTq8RnQiUATK3SWEmGvs" alt=""><figcaption></figcaption></figure>
2. Drop it on the edge of the task node (it snaps to the border).
3. Connect the boundary event to a fallback task or End Event.

   <figure><img src="/files/X3Oeud1vIOUyhC2aHvl2" alt=""><figcaption></figcaption></figure>

   <figure><img src="/files/sRqvV2w759K7zp767Hep" alt=""><figcaption></figcaption></figure>

| Field           | Description                                           |
| --------------- | ----------------------------------------------------- |
| **Error Codes** | Comma-separated list. Leave empty to catch all errors |

## Branching Logic

### Exclusive Gateway (If/Else)

1. Place an **Exclusive Gateway** on the canvas.

   <figure><img src="/files/xb7uNSIudI9mpASnwHFx" alt=""><figcaption></figcaption></figure>
2. Connect it to two or more downstream tasks.

   <figure><img src="/files/S77A2X795Vv3Pr4vAOyr" alt=""><figcaption></figcaption></figure>
3. Click each **sequence flow arrow** to set its condition, or click the **gateway** to set all conditions at once.

   <figure><img src="/files/xKFc5DOuXCwAqNL2nOU4" alt=""><figcaption></figcaption></figure>

| Field                         | Description                                                     |
| ----------------------------- | --------------------------------------------------------------- |
| **JSONata Gateway Condition** | Evaluates to true/false, e.g., `$states.input.statusCode = 200` |
| **Default flow**              | Checkbox — taken when no other condition matches                |

{% hint style="warning" %}
Always mark one outgoing flow as **Default** to prevent dead ends.
{% endhint %}

### Parallel Gateway

<figure><img src="/files/TatrnzXtbJVc7GmRDimL" alt=""><figcaption></figcaption></figure>

1. Place a **Parallel Gateway** to fork execution.
2. Connect it to multiple downstream paths.

   <figure><img src="/files/NvQWiSPBGEeqn9hfnWsY" alt=""><figcaption></figcaption></figure>
3. Optionally, place a second **Parallel Gateway** downstream to join all branches.

   <figure><img src="/files/zOFSEFBdXvze7EU1gHee" alt=""><figcaption></figcaption></figure>

All branches execute simultaneously. The join waits for all branches to complete before continuing.

## Fail End Event

<figure><img src="/files/28vfQThITuHxLkDBoeM8" alt=""><figcaption></figcaption></figure>

By default, reaching an End Event means success. To terminate with an explicit failure:

1. Click the **End Event** node.
2. Set ***Error Code*** (e.g., `ValidationError`) and ***Error Cause*** (human-readable description).

   <figure><img src="/files/9om70vYvUf3lGhAqOh51" alt=""><figcaption></figcaption></figure>

When an Error Code is set, the workflow terminates with a labelled failure — useful for signalling different failure modes to calling systems.
