Template and version IDs

A template is the parent record. Each version is a revision of that template's content.

Customer integration API

Sync render endpoints (POST /api/v1/render/html, POST /api/v1/render/pdf) accept only:

FieldWhat it isRequired
templateIdUUID of the templateYes
variablesPlaceholder values for the templateYes

The latest approved version is always used. You cannot pin a specific version on the customer API.

json
{
  "templateId": "550e8400-e29b-41d4-a716-446655440000",
  "variables": { "title": "Q1 Report" }
}

Admin API (jobs and template management)

Version IDs still matter on the admin API:

  • Async render jobs require templateVersionId.
  • Template approval, audit, and version listing use version UUIDs.
bash
# Templates → use "id" as templateId on the customer API
curl -sS 'https://adminapi.commspliant.com/api/v1/templates' \
  -H 'X-Api-Key: ck_YOUR_API_KEY'

# Versions → informational; also used for admin render jobs
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.