Error Handling in Zenphi
📖 Definition
The "Error Handling in Zenphi" feature allows users to effectively manage, respond to, and resolve errors that occur during flow execution. It provides a structured way to handle both expected and unexpected issues at different levels—whether within individual actions or across the entire workflow.
Key capabilities include:
- Action-level error handling to manage failures in specific steps.
- Global error handling for centralized management of flow-wide issues.
- Manual options like Rerun and Retry, giving users control to reprocess failed steps or flows.
- Advanced strategies to trigger responses (e.g., send notifications, apply conditional logic) based on error events, such as integrating with email arrival or branching flows when an error occurs.
This powerful system ensures workflows remain reliable, transparent, and resilient—even when things go wrong.
🛠️ Systematic Error Handling
Zenphi supports automatic error management through two main methods: Action-Level Error Handling and Global Flow Error Handling. These options let you decide how to respond when parts of a flow fail — whether to retry, continue, or alert someone.
⚙️ Action-Level Error Handling
This applies to individual actions within your flow. Most actions have an Error Handling tab in their settings, allowing you to define how Zenphi should behave if that specific action encounters an error.
**Access Point:**Click the gear icon next to the action > go to the Error Handling tab (last tab).
Available Settings:
-
RetriesSet how many times Zenphi should retry the action after it fails, and how long to wait between each attempt. This is ideal for temporary issues like slow APIs or timeouts.
-
Behavior on ErrorChoose what Zenphi should do after retries are exhausted:
- Fault the Flow: Stop the entire flow.
- Continue: Skip the failed action and move to the next one.
**Example:**Let’s say you’re updating a Google Sheet. If the service is temporarily unavailable, you can retry the action 3 times, waiting 5 minutes each time. If it still fails, you can choose to either continue the flow or stop it completely.
🌐 Global Flow Error Handling
This acts as a safety net when something goes wrong that isn’t caught at the action level. It's configured at the workspace level and applies to any flow published under that workspace.
**Access Point:**Go to the gear icon in the bottom-left of the Zenphi dashboard > select Flow Error Handling.
Available Settings:
- Add one or more email addresses to receive notifications when a flow fails and wasn’t handled at the action level.
- You can notify the flow publisher by default or specify additional recipients like team leads or admins.
**Example:**If a flow for processing employee onboarding fails at a critical point, Zenphi will send an email with details to the assigned contacts — ensuring the failure doesn’t go unnoticed.
🧰 Manual Error Handling
Manual error handling in Zenphi gives you direct control over how to respond when a flow run fails. From the Recent Runs section, you can monitor run statuses, review what went wrong, and choose to either Rerun or Retry the flow depending on the situation.
🔍 Accessing Recent Runs
To manage failed or completed runs:
-
In the left-hand menu, click the gear icon > select “Recent Runs.”
-
This page shows a list of your most recent flow executions.
-
You can filter runs by:
- Status: Executing, Completed, Faulted, Canceled, Skipped, All
- Start Time
- Flow Name
👉 Tip: If you open a specific flow and click into its “Recent Runs”, the list will be automatically filtered to show runs from that flow.
You can select one or more runs from this list. Once selected, two main options appear: Rerun and Retry. Before diving into these, let’s quickly cover an important concept: Flow Versions.
🔁 Understanding Flow Versions
Each flow in Zenphi has a version number formatted as:X.Y → where X is the published version, and Y is the number of changes saved after publishing.
-
Publishing a flow increases the number before the dot:
- e.g., from
2.1
to3.0
- e.g., from
-
Saving a flow increases the number after the dot:
- e.g., from
3.0
to3.1
- e.g., from
🔸 Only published versions (X) are used for flow executions.🔸 Versions like 4.0
and 4.5
will run the same way—unless 4.5
is published as version 5.0
.
**Why it matters:**When you rerun or retry a flow, Zenphi refers to the version used in the original run or the latest published one—depending on the option you choose.
🔄 Rerun vs. Retry
🔁 Rerun
-
Starts the flow from the beginning, using the latest published version.
-
Useful when:
- You’ve made changes to fix the issue.
- You want the flow to run under updated logic.
-
The old run stays in history, and a new run begins based on the current published version.
📌 **Example:**A flow failed under version 4.0
. You fixed the issue, published the flow (now version 5.0
), and choose Rerun. The flow starts over with version 5.0
.
🔂 Retry
-
Resumes the same run from the step where it failed.
-
Keeps the original version number (does not use any changes made after the failure).
-
Best when:
- The failure was caused by an external issue (e.g., server down, API error).
- The flow’s structure didn’t need changing.
📌 **Example:**A flow failed at version 4.0
due to a network timeout. You fix the external issue but make no changes to the flow. When you click Retry, the same run resumes from the error point using version 4.0
.
🚀 Advanced Error Handling
Sometimes, basic retries and email alerts aren't enough. For more flexible and powerful responses to errors, Zenphi supports advanced error handling. This allows you to build automated recovery logic or custom responses within your flows.
There are two key ways to implement advanced error handling in Zenphi:
1️⃣ Triggering Automation from Global Flow Errors
When a flow fails (even after retries), Zenphi can notify you by email — but it can also do much more. By connecting that global error alert to a Zenphi email trigger, you can start a new automation flow in response to any failure.
How it works:
- Create a new Zenphi flow with the Zenphi Mail trigger.
- Set up Global Flow Error Handling to send emails to the specific address in the trigger.
- Configure this flow to listen to the error emails and respond as needed.
Example Use Case:
- A business-critical flow fails after hours.
- It sends alerts to Slack/Google Chat, logs the issue in a tracking sheet, or creates a support ticket automatically.
For more detail and an example of this in action, see this post: Advanced Error Handling with Zenphi Mail Trigger
2️⃣ Using Boolean Outputs to Branch Logic on Errors
When configuring Action-Level Error Handling, if you choose to “Continue on Error,” Zenphi adds a Boolean field to the action’s output — typically named like Step Errored
.
This output helps you check if the action failed, and based on that, take different actions in your flow using an If Condition.
How it works:
- In the action settings, set Behavior on Error to Continue.
- In the next step, add an If Condition that checks the Boolean output.
- Based on whether the action failed (
true
) or not, direct the flow to different logic paths.
💡 Example Use Cases for Advanced Handling
Here are real-world scenarios where advanced error handling helps recover or adapt:
-
**PDF Merge Fails?**Check if all input files are PDFs. If not, automatically convert them using the "Convert to PDF" action before retrying the merge.
-
**Null or Missing Data?**If a required parameter is empty and caused the error, send a Request Data action to the manager or team member to provide the missing value.
-
**Notify When Errors Occur?**If any step fails:
- Automatically generate a Google Doc with failure details (e.g., input values, error message).
- Send it via Google Chat or email to notify your support or IT team.
-
**API Integration Timeout?**If a webhook or external API fails, wait 5 minutes, then retry the same step — or route the flow to a fallback action.
-
**Smart Retry Paths:**Use advanced If-Else conditions to retry with alternate settings or credentials if the first attempt fails.
Zenphi gives you the flexibility to not just detect errors, but to respond smartly, recover gracefully, and keep your processes running — even when things go wrong.
🧩 Example: Handling PDF Merge Failure with Smart Recovery
🔍 Scenario:
You're running an automated flow that merges several uploaded documents into a single PDF using the "Merge PDF" action. Occasionally, the merge fails — either because one of the files isn't in PDF format, or a file is missing altogether.
You want to handle this gracefully, without stopping the flow, and try to fix the issue automatically.
⚙️ How You Set It Up:
-
Configure the Merge PDF Action
In the Error Handling tab, set:
- Retries: 3 attempt after 1 minute, 10 minutes, 1 hour
- Behavior on Error: Continue to the next step
- This enables the action’s HasErrored output for further logic.
-
Add an If Condition
Check if
MergePDF.Step Errored
is true.If it is, route to a recovery branch in your flow.
-
In the Recovery Branch:
Use a Loop to check each file’s format.
- If a file is not a PDF, run a "Convert to PDF" action.
After converting all non-PDF files, retry the Merge PDF action again with the cleaned file list.
-
Still Failing? Ask for Help
If the second merge attempt also fails:
- Use a "Request Data" action to ask the team lead or file uploader to re-submit missing or correct files.
- Attach the original error message for context.
-
Log and Notify
Create a Google Doc summarizing:
- What failed
- What recovery steps were taken
- Who was contacted
Automatically send this doc to your IT team’s Google Chat channel or a shared mailbox.
✅ Outcome:
- Your flow doesn’t fail silently.
- Users are notified and assisted without manual intervention.
- Your team saves time by only getting involved when auto-recovery fails.
- Error handling becomes part of your workflow logic, not just a dead end.
🏁 Conclusion
Error handling in Zenphi is more than just preventing failures — it's about building resilient, intelligent workflows that adapt when things go wrong. Whether you're applying simple retries, notifying your team with global alerts, or designing advanced recovery logic using conditional branches and boolean checks, Zenphi gives you the tools to stay in control.
By combining systematic settings, manual intervention options, and smart automation, you can ensure your processes remain reliable, transparent, and efficient — even in the face of unexpected issues.
With a thoughtful approach to error handling, your workflows don’t just run — they evolve.
Updated about 17 hours ago