list-templates
Updated Nov 4, 2026·2 min read
Lists the Salesforce document templates in your CloudFiles account that are ready to generate from, newest first. The agent can filter by Salesforce object or by words in a template's name, description or tags. Each template includes the values to supply when generating from it. Only the newest version of each template is listed, because that is the version documents are generated from.
The user the connection acts as needs a CloudFiles Document Generation license. See Who the Agent Acts As. Templates must be published in CloudFiles to be listed. Draft templates are not available to agents, and templates built for HubSpot are not listed.
| Input | Required | Description |
objectType | No | Salesforce object API name, such as Opportunity or Invoice__c. Case does not matter. |
search | No | Words to find in a template's name, description or tags. A template matches when it contains every word. Case does not matter. |
Outputs
| Field | Description |
templates | Every matching template, newest first, with the fields below. |
id | The template's ID, used to generate from it. |
externalKey | A stable name an admin gave the template, when it has one. |
name | The template's name. |
description | The template's description, when it has one. |
objectType | The Salesforce object the template generates from. |
kind | The file type: docx, pptx, xlsx or pdf. |
tags | The template's tags. |
versionNumber | The template's version number. |
updatedAt | When the template last changed, in ISO 8601 format. |
variables | The values to supply when generating, with the fields in the next table. |
total | How many templates matched. |
Variable fields
| Field | Description |
name | The name to use when supplying a value to generate-document. |
label | The variable's label. |
type | The data type, such as string, double or date. |
defaultValue | The variable's default value, when it has one. |
isCollectionVariable | true when the variable takes a list of values. |
Example requests
| You ask | What the agent does |
| What templates can I use on this opportunity? | Calls list-templates with objectType set to Opportunity and lists the templates by name. |
| Do we have an NDA template? | Calls list-templates with search set to NDA and lists the matches. |
| What values does the NDA template need? | Calls list-templates, finds the NDA template and lists its variables with their labels and types. |