Request additional field
Create a Single Line Request additional field common for incident and service with name 'Last Approval Comments'. Replace the api name in the below function.Global functions
1)
Function Name - Get Configurations
Return type - Map
API Name - getconfigurationfor
Parameters
configname - String
2)
Function Name - Generate Response
Return type - Map
API Name - generateresponse
Parameters
parameter_map - Map
method - String
configname - String
url - String3)
Function Name -Approval configurations
Return type - Map
API Name - getapprovalconfig
Parameters
approveremailid - String
level - int
Approval Custom function
1)
Function Name - updaterequest
API Name - updaterequest
Type - Action1)
Function Name -approvalverification
Type - Condition
API Name - approvalverification2)
Function Name - Conditional approvals for Incident and Service Requests
Type - Action
API Name - conditionapproval
1) Approval Custom trigger
Configure criteria with the users for whom if mail is sent the chain of mails needs to be triggered.
2) Request Custom trigger
How this works
When a user with an email id say test@abc.com is chosen in submit for approval, if there is configuration mentioned in getapprovalconfig for this email id, then the list of users configured for this email id will be triggered the approval flow.
The content of the approval triggered will be based on the Approval template configured under Notification rules.