Credentials

Create a credential template

Create a credential template for the authenticated tenant. A template binds an existing credential schema to a reusable issuance profile — a name and a validity window (in seconds) — that issuance references by uuid. The referenced schema must belong to the same tenant, otherwise the request returns 404. Requires Authorization: Bearer <tenant API key>.

post/v1/credential-templates

Request body

schemastring uuid required

UUID of the credential schema this template binds to. Must reference a schema owned by the authenticated tenant; otherwise the request returns 404.

namestring required

Human-readable name of the template.

validity_secondsinteger

Lifetime, in seconds, to apply to credentials issued from this template (sets expires_at = issuance time + validity_seconds). Defaults to 31536000 (365 days).

Example request

{
  "schema": "3a1f9c20-8d4e-4b1a-9f2c-7e6d5a4b3c2d",
  "name": "Gold-tier membership (1 year)",
  "validity_seconds": 31536000
}

Response

No response body

Changes