Blueprints
A blueprint lets you define a step-by-step process that records in a custom module must follow. When you create a blueprint, you set up a sequence of states (or statuses) that a record moves through, with rules and actions at each step.
Note: This feature is currently in Early Access. Write to us at support@zohoexpense.com to enable it for your organizaiton.
Scenario: Zylker’s Business Units module has a Status dropdown with values: Draft, Under Review, Active, and Inactive. When a new BU is set up, the Finance Head first reviews the ERP account code, and then the IT Admin verifies the member configuration. Only after both reviews are done can the BU be marked Active. The admin creates a blueprint to enforce this review process. The blueprint flow: Draft > Under Review (Finance Head reviews ERP account code) > Under Review (IT Admin verifies member setup) > Active or Inactive.
Prerequisite: The custom module must have a Dropdown field that represents the statuses (states) the record will move through.
Key Terms
Before you create a blueprint, familiarize yourself with the following terms:
| Term | Description |
|---|---|
| State | A specific stage in the process. States are derived from the values of a dropdown field in the module. For example: Draft, Under Review, Active, Inactive. |
| Transition | The movement of a record from one state to another. For example, moving a record from Draft to Under Review is a transition. |
| Before Transition | Conditions or actions that must be satisfied before a transition can occur. For example, requiring a mandatory field to be filled. |
| During Transition | Actions that occur while the transition is in progress. For example, displaying a form for the user to fill in additional information. |
| After Transition | Actions that occur after the transition is complete. For example, sending a notification email. |
| SLA (Service Level Agreement) | A time-based escalation that triggers actions if a record stays in a state longer than expected. |
Create a Blueprint
To create a blueprint:
- Click Admin View on the left sidebar.
- Go to Settings on the left sidebar.
(OR)
Click Settings in the top right corner of the page. - Select the custom module under Custom Modules.
- Click More in the top right corner.
- Select Blueprints.
- Click + New Blueprint.
- Fill in the following details:
| Field | Description |
|---|---|
| Blueprint Name | Enter a name for the blueprint. |
| Description | Enter a brief description of the process the blueprint defines. |
| Field | Select the dropdown field whose values represent the states in the process. |
| Criteria | Optionally, define criteria to determine which records this blueprint applies to. If no criteria is set, the blueprint applies to all records. |
- Click Save.
Design a Blueprint Flow
After creating a blueprint, you need to design its flow by defining the states and transitions.
Add States
States represent the stages a record goes through. The values of the dropdown field you selected while creating the blueprint are available as states.
To add states to the blueprint flow:
- In the blueprint editor, drag and drop states from the left panel onto the canvas.
- Connect the states by drawing transitions between them.
Connect States with Transitions
Click and drag from one state to another to create a transition. Each transition represents the movement of a record from one state to the next.
Note: Every blueprint must have at least one transition. The first state in the flow is the starting state, and the last state is the end state.
Transitions
Transitions define the rules and actions associated with moving a record from one state to another. You can configure what happens before, during, and after each transition.
Before Transition
Configure conditions that must be met before the transition can be initiated:
- Allowed Roles: Specify which user roles can initiate the transition. For example, only the Finance Admin role can move a record from Under Review to Active.
- Criteria: Define conditions based on field values that must be true for the transition to be available. For example, the transition to Active is only available when the ERP Account Code field is not empty.
During Transition
Configure what happens while the transition is in progress:
- Required Fields: Specify fields that must be filled before the transition can be completed.
- Messages: Display a message or instruction to the user during the transition.
After Transition
Configure actions that occur automatically after the transition is complete:
- Field Updates: Automatically update field values when the transition completes. For example, set Activation Date to the current date when a BU record moves to Active.
- Email Notifications: Send email notifications to specific users or roles. For example, notify the BU Head when a BU record is marked Active or Inactive.
- Webhooks: Trigger external webhooks to integrate with other systems.
- Custom Functions: Execute Deluge scripts to perform custom actions.
SLA (Service Level Agreement)
SLAs let you set time-based escalations for each state. If a record stays in a state longer than expected, the actions you set up are triggered automatically.
To set an SLA:
- Open the state in the blueprint editor.
- Click SLA.
- Set the Escalation Time, which is how long a record can stay in a state before the escalation is triggered.
- Configure the escalation actions (email notifications, field updates, or custom functions).
- Click Save.
Insight: SLAs help you make sure records move through the process on time. For example, if a Business Units record stays in Under Review for more than 3 business days without the Finance Head reviewing the ERP account code, an SLA can send a notification to the Finance Head and alert the admin.
Publish a Blueprint
Once you’ve designed the blueprint flow and configured all transitions, you need to publish it to make it active.
To publish a blueprint:
- Open the blueprint in the editor.
- Review the flow, transitions, and actions.
- Click Publish in the top right corner.
Note: After publishing, the blueprint is active and applies to all new records (or records matching the criteria you defined). Existing records are not affected.
Execute a Blueprint
Once a blueprint is published, it is automatically applied to records in the custom module. When a user views a record that is part of a blueprint, the available transitions are displayed as buttons on the record.
To execute a transition:
- Open the record in the custom module.
- Click the transition button (for example, Submit for Review or Approve).
- Fill in any required fields or information displayed during the transition.
- Click Submit to complete the transition.
The record moves to the next state, and any after-transition actions are executed automatically.
Manage Blueprints
Edit a Blueprint
To edit a blueprint:
- Click Admin View on the left sidebar.
- Go to Settings on the left sidebar.
(OR)
Click Settings in the top right corner of the page. - Select the custom module under Custom Modules.
- Click the More icon in the top right corner.
- Select Blueprints.
- Click the blueprint you want to edit.
- Make the necessary changes.
- Click Republish to apply the changes.
Note: Changes to a published blueprint do not affect records that are already in the middle of a process. The updated blueprint applies only to new records or records that haven’t entered the blueprint flow yet.
Deactivate a Blueprint
You can deactivate a blueprint to temporarily stop it from being applied to new records.
- Open the blueprint.
- Click the Active toggle to set it to Inactive.
Delete a Blueprint
To delete a blueprint:
- Open the blueprint list for the custom module.
- Hover over the blueprint you want to delete and click the Delete icon.
- In the pop-up that appears, click Delete to confirm.
Warning: Deleting a blueprint is irreversible. Records that are in the middle of a blueprint process will no longer follow the defined flow.