With this API, you can submit approval requests asynchronously. This API accepts the object type and the object ID of the context object as input parameters.
API
Signature
submitForApprovalsAsync
WebService static Boolean submitForApprovalsAsync(String sObjectType, ID sObjectId);
Request Parameters
Name
Type
Required?
Description
approvalObjectId
ID
Yes
ID of the approval context object.
approvalObjectType
String
Yes
Type of the approval context object.
Response Parameter
Name
Type
Description
result
Boolean
Returns true if the API is executed successfully.
/**
* Apttus Approvals Management
* TestSubmitAsyncAPISample
*
* @2020 Apttus Inc. All rights reserved.
*/
public with sharing class TestSubmitAsyncAPISample {
/**
* Class Constructor
*/
public TestSubmitAsyncAPISample() {
}
// test webservice API calls by running as anonymous apex from developer console
//TestSubmitAsyncAPISample.TestSubmitForApprovalsAsync('Apttus__APTS_Agreement__c','a07R000000AiYQX');
/**
* Submit an approvals process asynchronously
* @param sObjectType the approval context sobject type
* @param sObjectId the approval context sobject identifier
* @return true if successful
*/
public static void TestSubmitForApprovalsAsync(String sObjectType, ID sObjectId) {
// call API to submit async
Boolean ok = Apttus_Approval.ApprovalsWebService.SubmitForApprovalsAsync(sObjectType, sObjectId);
system.assertEquals(ok, true);
}
}
CODE
Integration Details
Use the following information in your integrations with Conga Approvals API. Refer to Integrating Conga with External Systems for information on how to get started.