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.

DocumentTemplate Class

The DocumentTemplate class provides methods to manage document generation templates.

Namespace

industries_docgen

Example

1System.Callable connect = (System.Callable) type.newInstance();
2Map<String, Object> inputMap = new Map<String, Object>();
3inputMap.put('documentTemplateId', templateId);
4docTemplate = SObjectProxy.of(DocGenObjectMappings.getSObjectType(DocGenObjectMappings.DOCUMENT_TEMPLATE_STR).newSObject());
5Map<String, Object> mapData = (Map<String, Object>)connect.Call('getNamespaceByDocumentTemplateId', inputMap);

This GET request retrieves the Namespace field from the DocumentTemplate entity, using the documentTemplate ID as input.

DocumentTemplate Methods

The following are methods for DocumentTemplate.

Call(methodName, inputMap)

Invokes a method with input parameters to manage document templates.

Signature

public Object Call(String methodName, Map<String,ANY> inputMap)

Parameters

  • methodName: Type: String Name of the method to be called.
  • inputMap: Type: Map<String,ANY> Map that contains input parameters for the method that is called.

Return Value

Type: Object