Automette docs

Get a template

GET
/api/v1/templates/{id}

Authorization

ApiKeyAuth
AuthorizationBearer <token>

API key from Settings → API Keys.

In: header

Path Parameters

id*string

Query Parameters

version?integer

Read this saved version instead of the current one. Changes nothing.

Response Body

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1/templates/string"
{  "id": "cm4tpl8e20001js04xq2v9k3m",  "name": "Event Badge",  "engine": "canvas",  "fields": [    {      "key": "attendee_name.text",      "label": "Text",      "type": "text",      "example": "Priya Nair",      "primary": true    },    {      "key": "attendee_name.fill",      "label": "Color",      "type": "color",      "example": "#1a1a1a",      "primary": false    }  ],  "layers": [    {      "name": "attendee_name",      "type": "text",      "properties": [        {          "key": "attendee_name.text",          "name": "text",          "label": "Text",          "type": "text",          "example": "Priya Nair",          "primary": true        },        {          "key": "attendee_name.fill",          "name": "fill",          "label": "Color",          "type": "color",          "example": "#1a1a1a",          "primary": false        }      ]    }  ],  "created_at": "2026-04-01T09:00:00.000Z",  "updated_at": "2026-04-22T11:00:00.000Z"}

Create a template POST

Creates a template, either from scratch or as a copy of one in the library. **From the library** — send `from_library` with a slug or id from `GET /api/v1/library_templates`. This is the path most callers want: start from a design that already works, then edit the copy. Do not copy the `document` yourself; the copy operation also duplicates the images and rewrites the references, which canvas templates need to render their own assets rather than the library's. **From scratch** — send `name`, `engine` and `document`. Nothing is validated on the way in, because a half-finished template is a legitimate thing to save. Call `POST /api/v1/templates/{id}/validate` to find out whether it will render. For `engine: "docx"`, omit `document`: a Word body is an uploaded file, so you get an empty template and upload the file to `PUT /api/v1/templates/{id}/docx` next. Passing `document` with `engine: "docx"` is rejected rather than ignored. Copying a DOCX template from the library works too, and brings its Word body with it.

Update a template PATCH

Updates the fields present in the body and leaves everything else alone. Returns the template in the same shape as `GET`. Nothing is validated on the way in — saving work in progress has to be possible. Call `POST /api/v1/templates/{id}/validate` when you want to know whether it renders. **`archived` puts a template away, reversibly.** An archived template drops out of `GET /api/v1/templates` and changes nothing else: renders keep their files, the id keeps resolving, connected forms and live Dynamic URLs keep serving. Send `archived: false` to bring it back, and `GET /api/v1/templates?archived=true` to find it again. That is what separates it from `DELETE`, which starts a 7-day clock on the same objects.