Skip to main content

List templates

GET /api/templates

List the account's templates with their declared variables (variablesSummary). The full project JSON is not included — fetch a template by ID for that.

Authentication​

  • Option 1: x-api-key: YOUR_API_KEY (header). API key for authentication. Create one in your dashboard.
  • Option 2: Authorization: Bearer YOUR_ACCESS_TOKEN. Dashboard JWT in Authorization: Bearer <token>, only on operations that explicitly list this scheme. Prefer x-api-key for REST integrations. OAuth for hosted MCP is a separate connection at https://mcp.zvid.io/mcp.

Create API keys at app.zvid.io/api-keys. Keep credentials on your server.

Parameters​

ParameterLocationTypeRequiredDescription and constraints
pagequeryintegerNoDefault: 1. Minimum: 1.
limitqueryintegerNoDefault: 20. Minimum: 1. Maximum: 100.

Request​

The shell examples read credentials from ZVID_API_KEY (or ZVID_ACCESS_TOKEN for Bearer authentication). Set that variable in your environment. Replace sample project, template, job, and asset identifiers with values from your own account.

This operation does not take a request body.

Request example​

curl --request GET 'https://api.zvid.io/api/templates' \
--header "x-api-key: $ZVID_API_KEY"

Responses​

HTTP 200​

Templates for the authenticated account

Content type: application/json.

Required properties: templates, pagination.

FieldTypeRequiredDescription and constraints
response.templatesarray of TemplateSummaryYes
response.paginationPaginationYes

Nested field: response.templates

Array item: response.templates[]

Schema: TemplateSummary.

Example response

{
"templates": [
{
"id": "tpl_rAequJHzUETcLAMfrezk",
"userId": 5,
"name": "Product promo",
"description": "16:9 promo with title/brand variables",
"type": "video",
"variablesSummary": [
{
"name": "title",
"type": "string",
"used": true,
"default": "Hello world"
}
],
"version": 3,
"status": "active",
"createdAt": "2026-07-01T09:00:00.000Z",
"updatedAt": "2026-07-06T18:30:00.000Z"
}
],
"pagination": {
"page": 1,
"limit": 20,
"total": 1,
"totalPages": 1
}
}

HTTP 401​

Unauthorized

Content type: application/json.

Unknown properties are rejected. Required properties: error.

FieldTypeRequiredDescription and constraints
response.errorstringYesError type
response.messagestringNoHuman-readable error message

Schema definitions​

The following definitions describe the fields referenced above. Expand a definition to inspect its complete contract.

TemplateList

Required properties: templates, pagination.

FieldTypeRequiredDescription and constraints
TemplateList.templatesarray of TemplateSummaryYes
TemplateList.paginationPaginationYes

Nested field: TemplateList.templates

Array item: TemplateList.templates[]

Schema: TemplateSummary.

TemplateSummary

One template as returned by the template list endpoint (no project JSON — fetch the template by ID for that).

Required properties: id, name, type, version, status.

FieldTypeRequiredDescription and constraints
TemplateSummary.idstringYes
TemplateSummary.userIdintegerNo
TemplateSummary.namestringYes
TemplateSummary.descriptionstring / nullNo
TemplateSummary.type"video" / "image"Yes
TemplateSummary.variablesSummaryarray of TemplateVariableSummaryNo
TemplateSummary.versionintegerYes
TemplateSummary.status"active" / "archived"Yes
TemplateSummary.createdAtstringNoFormat: date-time.
TemplateSummary.updatedAtstringNoFormat: date-time.

Nested field: TemplateSummary.variablesSummary

Array item: TemplateSummary.variablesSummary[]

Schema: TemplateVariableSummary.

TemplateVariableSummary

One declared template variable and whether the project uses it.

Required properties: name.

FieldTypeRequiredDescription and constraints
TemplateVariableSummary.namestringYes
TemplateVariableSummary.typestringNo
TemplateVariableSummary.usedbooleanNo
TemplateVariableSummary.defaultany JSON valueNoDeclared default value (any JSON type)
Pagination

Standard pagination envelope for list endpoints.

Required properties: page, limit, total, totalPages.

FieldTypeRequiredDescription and constraints
Pagination.pageintegerYes
Pagination.limitintegerYes
Pagination.totalintegerYes
Pagination.totalPagesintegerYes
Pagination.hasNextbooleanNoWhether there are more pages after the current one
Pagination.hasPrevbooleanNoWhether there are pages before the current one
AuthenticationError

Unknown properties are rejected. Required properties: error.

FieldTypeRequiredDescription and constraints
AuthenticationError.errorstringYesError type
AuthenticationError.messagestringNoHuman-readable error message