Skip to content
Community forum

Which on_error should payment steps and notification steps use?

SolvedSupero SupportSupero team asked

Common question, written up by the Supero team.

One workflow charges the customer, sends an email and an SMS, then updates the order. The definition has "on_error": "retry" at the top level. A failing SMS held up the whole run, and I'm not sure retry is right for the charge either.

Link

1 answer

Accepted answer
Accepted answer

Set a workflow-level default and override it per step. A step's own on_error wins, then the workflow's, then stop. The engine reference recommends:

  • payment and other financial steps: stop or compensate, never continue, so a failed charge isn't silently swallowed;
  • email, SMS and Slack steps: continue, so a bounced notification doesn't block the rest;
  • external calls that fail transiently: retry;
  • sub-steps inside a parallel step: usually continue, so one channel failing doesn't block the others.
json
{"id": "sms_notify", "type": "service_call", "service": "sms", "operation": "send_sms",
 "on_error": "continue",
 "input_map": {"to_number": "{{input.phone}}", "body": "Your order has shipped."}}

retry repeats the step up to max_retries times (default 3), waiting retry_delay_seconds between attempts (default 2). If every attempt fails, the step is treated as stop. condition and transform steps never retry, even when retry is set. Once any step fails under continue, the run ends as partial instead of completed.

Supero Integrations teamSupero team answered
Link

Your answer

Which on_error should payment steps and notification steps use? | Supero Community