CaseCloud Help

Apex Invocable Methods Available Within the Connector

Updated on

CaseCloud provides a wide range of Apex invocable methods that allow you to easily execute different HotDocs-related actions as part of your flow, process builder, or from an Apex class.

List of Available Apex Invocable Methods

There are many different HotDocs-related actions that can be automated with the HotDocs connector. Here you can find the list of all available Apex methods:

Within the Flow Builder canvas, click on the (+) button menu and add an Action. From the Search Actions list, search for and select the relevant action to add to the canvas.
 

The detailed usage of the above-mentioned Apex actions is outlined below:

Expand or collapse content Assemble Documents
Expand or collapse content Using the Apex Method in a Salesforce Flow
Input Values
  1. HotDocs Document Template ID -Provide the HotDocs Document Template record's Record ID value here.
  2. Record ID -Provide the current record's Record ID value here.
Output Values

When the document assembly is initiated successfully, this method returns an Apex data type variable. The response will contain values such as the HotDocs Interview ID, Status, and Status Message (which would contain error messages in case of errors).

Salesforce does not allow REST API calls or DML operations, such as inserting or updating records, in a single transaction. In these cases, Salesforce alerts the user with the error 'You have uncommitted work pending. Please commit or rollback before calling out'. When this error occurs, CaseCloud advises users to use the Scheduled Paths in the flow.

Expand or collapse content Using the Apex Method in an Apex Class

Example Apex script:

hdocs.HotDocsInterviewCreateAssembleAction.Request req1 = new hdocs.HotDocsInterviewCreateAssembleAction.Request();
req1.recordId = '0010C00000WxO5fUAF';
req1.templateId = '0a20C00000WxO5fUAF';
List<hdocs.HotDocsInterviewCreateAssembleAction.Request> reqList = new List<hdocs.HotDocsInterviewCreateAssembleAction.Request>{ req1 };
List<hdocs.HotDocsInterviewCreateAssembleAction.Response> resp = hdocs.HotDocsInterviewCreateAssembleAction.process( reqList );
system.debug('Assemble Documents Response :: '+resp[0]);
Previous Article Using the HotDocs Document Templates
Next Article Flow Actions Available Within the Connector
Still need help? Click here!
AdvoLogix® is a registered trademark of AdvoLogix.com LLC a Texas Limited Liability Company. All references to other trademarks belonging to third parties that appear on this website, documentation, or other materials shall be understood to refer to those registered trademarks owned by others, and not to any trademark belonging to AdvoLogix. Otherwise, all material herein is the copyright of AdvoLogix.com LLC. All Rights Reserved.