Skip to main content

Error Handling

Handling errors in integrations

Errors happen. An API you integrate with may encounter a temporary outage, or the "eventually" part of an "eventually consistent" database may need a couple more seconds to save a record. When you encounter errors, you have two tools to handle them:

  1. Flow-level error handling.

Flow-level error handling

If an execution fails, you have have the runner automatically retry a few minutes later. The webhook payload that you received will be passed back through your flow again, and your flow will start again at its first step. This is handy if your flow is idempotent and you don't know which step might fail.

Read more about flow-level error handling on the automatic retry article.

Step-level error handling

You might not want your entire flow to stop because one step failed, especially if you're looping over hundreds of items and one item has issues.

You can configure how the runner should handle errors on each step. To do that, click a step that you would like to configure, and then open the Error Handling tab in the step configuration drawer.

Under Error Handler Type you have three options:

  • Fail - stop the flow and throw an error.
  • Ignore - ignore the error and continue running the rest of the flow.
  • Retry - wait for an amount of time (Seconds Between Attempts) and then try the step again, a maximum of Max Attempts times. Optionally wait longer and longer (Exponential Backoff, twice as long each time) between retries. If the last attempt still fails, either fail the integration or ignore the error depending on if Ignore Final Error is true or false.
Screenshot of step-level error handling configuration

Branching after ignored errors

If a step is configured to Ignore errors, or if the step has retried its configured number of times and then ignored the final error, the step returns a result with an error property detailing the error that occurred. You can use the branch component to branch based on that error.

This is useful if you have some sort of dead letter queue to write the failed item to, or if you would like to notify someone of the problematic item. You can branch on whether or not the step's returned error exists, and act accordingly.

Screenshot of branching on step-level error handling