Adding Variable Tokens to Your Template
Last updated
Last updated
The Documint app can access token data for these objects:
Contacts
Companies
Deals
Tickets
Custom Objects
To search and view the available tokens, just click the Editor Mode toggle on and then click the View Tokens button.
You can filter and view all tokens for your object as well as the tokens for associated objects.
Primary tokens are properties that belong to the object that is currently selected.
See Working with Custom Object Data on how to change the selected object.
Copy a token by highlighting it and pressing "Ctrl+C". Then paste it into your template.
Association tokens are the properties for associated objects. For example: your selected object is contacts and its associations are contacts (other contacts), companies, deals, and tickets.
Because associations are lists/arrays of data for related records (see array data type), you can either display the values for associations by looping over each record, or you can just display data for a singe record from the list (This is useful when an associations list only contains a single associated record).
The Documint app does not currently provide associations for custom objects.
To display values from a single record use the following syntax in your template:
Select "First item" from the "Use type" dropdown and then copy the associated object property you want to use.
Now just paste the token into you template.
Select "All items" from the "Use type" dropdown and copy the association list token that appears at the top of the tokens table.
In your Documint template, select the parent element that will be repeated for each item in the list then click "Edit logic"
Paste the associated token name into the "List variable" field.
Copy one of the associated object's properties from the Documint app.
Paste it inside the repeating element in your template.
You're all set to generate your document!