Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
Approve a Record
Use the Process Approvals resource to approve a record or a collection of records. Each call takes
an array of requests. The current user must be an assigned approver. The contextId is ID of
the record to submit for approval..
Example usage
1curl https://MyDomainName.my.salesforce.com/services/data/v67.0/process/approvals/ -H "Authorization: Bearer token" -H "Content-Type: application/json" -d @approve.json"Example request body approve.json file
1{
2 "requests" : [{
3 "actionType" : "Approve",
4 "contextId" : "04iD0000000Cw6SIAS",
5 "nextApproverIds" : ["005D00000015rY9"],
6 "comments" : "this record is approved"}]
7}Example JSON response body
1[ {
2 "actorIds" : null,
3 "entityId" : "001D000000I8mImIAJ",
4 "errors" : null,
5 "instanceId" : "04gD0000000CvmAIAS",
6 "instanceStatus" : "Approved",
7 "newWorkitemIds" : [ ],
8 "success" : true
9} ]