- Introduction
- Getting started
- Process modeling with BPMN
- Process modeling with Case Management
- Designing a persistent case entity schema
- Defining case keys (system vs. external)
- Establishing task I/O and write-back contracts
- Exit rules and early stage termination
- Modeling primary and secondary stages
- Triggering a case from Data Fabric
- Implementing stage-level personas and permissions
- Setting SLAs and automated escalation rules
- Configuring a rework loop (re-entry)
- Managing live case instances: pause, migrate, and retry
- Maestro case management component dictionary
- Process modeling with Flow
- Getting started
- Core concepts
- Node reference
- Build guides
- Best practices
- Reference
- Process implementation
- Debugging
- Simulating
- Publishing and upgrading agentic processes
- Common implementation scenarios
- Extracting and validating documents
- Process operations
- Process monitoring
- Process optimization
- Reference information
Maestro user guide
What you'll build: A workflow that fires automatically when a new email arrives, extracts key fields from the message, and routes it to the right downstream action based on the content — for example, logging support requests to a ticketing system or escalating urgent messages to a Slack channel.
What you'll need
- A UiPath Automation Cloud account with access to Maestro Flow.
- A mailbox connected via Integration Service (UiPath's connector platform). Supported providers include Microsoft 365 and Gmail. To set up a connection, go to Integration Service in the UiPath Platform and configure the connector for your email provider.
Nodes used
- Email integration trigger — fires when a new email arrives in the connected mailbox
- Data Transform — extracts sender, subject, and body from the email payload
- Decision — routes the email based on content
- Terminate — ends the workflow cleanly if the payload is malformed
Steps
1. Create a new Flow and add an email trigger
- Open Maestro → Flow and create a new workflow.
- In the node panel, open Integration nodes and find your email connector (Microsoft 365 or Gmail).
- Drag the Email received trigger onto the canvas.
- In the configuration panel, select the Connection to use and configure any filters (for example, a specific inbox folder).
2. Extract fields from the email
- Drag a Data Transform node onto the canvas and connect it to the trigger.
- Map the fields you need from the trigger's output payload:
trigger.body.from→senderEmailtrigger.body.subject→emailSubjecttrigger.body.body.content→emailBody
The exact field names vary by connector — check the trigger's output schema in the configuration panel.
3. Route based on content
- Drag a Decision node onto the canvas and connect it to the Data Transform node.
- Set the condition to evaluate the email content. For example, to catch urgent messages:
$vars.emailSubject.toLowerCase().includes("urgent"). - Connect the True branch to a high-priority action (for example, a Slack notification node).
- Connect the False branch to a standard action (for example, creating a ticket in your support system).
4. Handle malformed payloads
Not every email will have the fields you expect. Guard against malformed payloads before they break the workflow:
- Add a Decision node after the Data Transform and check that required fields are present — for example,
$vars.senderEmail != null. - Connect the valid branch to the routing Decision from step 3.
- Connect the invalid branch to a Script node that logs the problem.
- Connect the Script node to a Terminate node set to
Failed.
For any node that exposes an error handle, you can also connect it to the same error path. See Error handling.
5. Test and debug
To test without waiting for a real email:
- Add a Manual Trigger alongside the email trigger temporarily.
- Configure it with a sample input schema that matches the email payload shape.
- Run the test with sample values and verify the routing logic in the execution trace.
- Remove the Manual Trigger before publishing.
Result
Your workflow fires automatically when a new email arrives, extracts the sender, subject, and body, and routes the message to the correct downstream action. Malformed payloads terminate cleanly on the error path rather than breaking the workflow.
Extend this workflow
- Invoke an AI agent — Before the Decision node, add an Agent node to classify the email with AI rather than a keyword match.
- Loop over attachments — If the email has attachments, add a Loop node to process each one.
- Reply to the sender — After routing, add an email integration action node to send a confirmation reply to
{{ $vars.senderEmail }}.