Add an error handler to a flow

  • 릴리스 버전: Australia
  • 업데이트 날짜 2026년 03월 12일
  • 소요 시간: 4분
  • Run a sequence of Workflow Studio actions and subflows to identify and correct issues that are caused by flow errors.

    시작하기 전에

    Role required: flow_designer or admin

    이 태스크 정보

    A flow error handler allows your flow to catch an error and run a set of actions, flow logic options, and subflows.
    중요사항:
    A flow error handler cannot resume or restart a flow that produces an error.

    프로시저

    1. Navigate to All > Process Automation > Flow Designer.
    2. Create a flow or open an existing flow.
      For more information about creating a flow, see Create a flow in Workflow Studio.
    3. Enable the ERROR HANDLER switch.
      Workflow Studio adds an error handler section to the flow and the Data pane.
    4. Add actions, flow logic options, or subflows to the Error Handler section.
      You can add up to 10 actions, flow logic options, or subflows to this section. Consider using a subflow to capture the error information or to correct issues with the record data.
      You can add flow logic options to the error handler. These options are described in the following table.
      표 1. Supported flow logic options
      Flow logic option Description
      If Selectively apply one or more actions only when a list of conditions is met. For more information, see If.
      Wait for a duration of time Use this flow logic option to pause the flow for a specified time period and resume the flow execution after the time period elapses. For more information, see Wait for a duration of time.
      End Flow Use this flow logic option to stop a flow within Workflow Studio. For more information, see End Flow.
      Dynamic Flow Identify and run a flow or subflow dynamically by using runtime data. Build templates to provide expected inputs for dynamically called flows or subflows. For more information, see Dynamic Flow.
      Set Flow Variables Assign a value to one or more flow variables. Change or update a variable's value during a flow. For more information, see Set Flow Variables.

      The Error Status object contains the information about the flow error. You can also use the Action Status object that is returned by each action to build the conditional logic. Both of these objects are available from the Data pane.

    5. 옵션: Add stages in the Error Handler.
      For more information on how to add stages, see Configure stages and add them to a flow.
    6. Add a custom action to the main body of the flow that throws an error.
      To learn how to create a custom action, see Create a custom action to throw an error.
    7. Test your flow to ensure that the error handler works as expected.
      For more information about testing a flow, see Test your flow.
    8. When your flow error handling is working as expected, select the delete icon next to your custom action that throws an error to remove it from your flow.

    결과

    Your flow runs the actions, flow logic options, and subflows that you specify when the flow produces an error. The flow execution details display the Completed (error caught) state for both the flow and the action that returned an error.