Template and version IDs
A template is the parent record. Each version is a revision of that template's content.
| Field | What it is | Required |
|---|---|---|
templateId | UUID of the template | Yes |
templateVersionId | UUID of a specific version | No |
Default behaviour
When templateVersionId is omitted, the API uses the latest approved version for the template.
Pin a version
Send both IDs when you need a fixed revision:
{
"templateId": "550e8400-e29b-41d4-a716-446655440000",
"templateVersionId": "660e8400-e29b-41d4-a716-446655440001",
"variables": { "title": "Q1 Report" }
}Find IDs
# Templates → use "id" as templateId
curl -sS 'https://adminapi.commspliant.com/api/v1/templates' \
-H 'X-Api-Key: ck_YOUR_API_KEY'
# Versions → use version "id" as templateVersionId
curl -sS 'https://adminapi.commspliant.com/api/v1/templates/TEMPLATE_ID/versions' \
-H 'X-Api-Key: ck_YOUR_API_KEY'Common mistake
Putting a version UUID in templateId returns 404 template not found for this organization.