Build a leave request process
A complete process: a request form, an approval step in the Inbox and automatic closing.
On this page
This recipe builds a process where an employee asks for leave, a manager approves it in the Inbox, and the task is closed. Requests that nobody approves within 3 days are closed automatically.
1. Create the process
- Open Processes and select Create.
- Enter the Name
Demo processand the CategoryDemo, then select SUBMIT. - Select the new card to open the designer.
2. Create the request form
- Select the blue + button, enter the Name
Leave request, choose Default template and select SUBMIT. - In the UI editor, drag a Form into the container and a Textbox into the form.
- In the settings of the Textbox, set the name to
Reason, the path toreason, and make it required. - In the settings of the Form, set the text of the button to
SEND. - Drag a Flow Output into the container. Set its Name to
Sendand its Target to the submit of the form. - Select SAVE and close the editor.
3. Create the approval form
Repeat step 2 with the Name Approval, a field Comment with the path comment, the button APPROVE and a Flow Output Approve.
4. Draw the process
Reload the designer, then drag these nodes onto the canvas and connect them:
| From | Output | To | Input |
|---|---|---|---|
| Start | Start | Leave request | No data |
| Leave request | Send | Approval | No data |
| Approval | Approve | Close | Payload |
| Approval | Expire | Close | Payload |

5. Configure the nodes
| Node | Settings |
|---|---|
| Start | Name Leave request |
| Leave request | Workflow action Create, Workflow name Leave request, Template name Leave: {{ value.reason }} |
| Approval | Workflow action Step, Workflow name Approval, Expiration 3 days, Template subject Approved: {{ value.comment }} |
| Close | Name Done, Template result Approved |
Select APPLY in each settings window, and then APPLY in the toolbar. Then select Publish in the toolbar, write First version in What changed and select PUBLISH. See Process versions.
6. Try it
- Open Inbox, select Create > Leave request, type a reason, for example
Demo vacation, and select SEND. - The task Leave: Demo vacation appears in the Inbox at the step Approval.
- Select it, confirm Assign, type a comment and select APPROVE.
- Open Tasks: the task is at the step Done, closed, with the result Approved and the subject Approved: your comment.