---
title: "Duplicate template"
method: POST
path: "/api/templates/{id}/duplicate"
tags: ["Templates"]
---

# Duplicate template

`POST /api/templates/{id}/duplicate`

## Request

- Base URL: `https://api.zvid.io`
- URL: `https://api.zvid.io/api/templates/{id}/duplicate`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Create an independent copy of an owned template with an automatically derived name. No request body is needed and no render is submitted.

## Path parameters

- `id` string, required

## Response `201`

Copy created

- TemplateEnvelope
  - `template` Template, required
    - `id` string, required
    - `userId` integer
    - `name` string, required
    - `description` string, nullable
    - `project` RenderPayload, required (unresolved $ref)
    - `type` 'video' | 'image'
    - `variablesSummary` TemplateVariableSummary[]
      - `name` string, required
      - `type` string
      - `used` boolean
      - `default` unknown
    - `version` integer
    - `status` string
    - `createdAt` string, date-time
    - `updatedAt` string, date-time

## Other responses

- `400`: Invalid input or semantic validation error
- `401`: Missing or invalid credentials
- `404`: Not found for this account
- `500`: Server error

---

[API](https://skmtc.dev/zvid/apis/zvid-api.md) · [All operations](https://skmtc.dev/zvid/apis/zvid-api/llms.txt) · [OpenAPI document](https://skmtc.dev/zvid/apis/zvid-api/revisions/8a665b293b37?raw)
