---
title: "Duplicate a template"
method: POST
path: "/templates/{templateId}/duplicate"
tags: ["templates"]
---

# Duplicate a template

`POST /templates/{templateId}/duplicate`

## Request

- Base URL: `https://docs-api.formify.eu/v1`
- URL: `https://docs-api.formify.eu/v1/templates/{templateId}/duplicate`
- Auth: OAuth 2 (authorization code, authorization URL `https://docs-api.formify.eu/v1/oauth/authorize`, token URL `https://docs-api.formify.eu/v1/oauth/token`, scopes: `write`)

Creates a new template with the same document and signature fields as the source. The original is
untouched.

The copy belongs to whoever duplicated it, so this is also how you take a private copy of a template a
colleague shared with the account.

Duplicating a template is free — unlike duplicating a public link.

## Path parameters

- `templateId` string, uuid, required

## Request body

- DuplicateRequest: Everything except the name is copied from the source.
  - `name` string: Name for the copy. Defaults to the source's name when omitted, which leaves you with two items of the same name.
  - `errorLanguage` 'en' | 'sv' | 'es': Language for error messages

## Response `201`

Template duplicated successfully

- TemplateCreatedResponse
  - `templateId` string, uuid: Unique identifier of the template
  - `name` string: Name of the template
  - `createdAt` string, date-time: Template creation timestamp
  - `userId` string, uuid: User ID of the template owner
  - `sharingSetting` 'shared' | 'private': Who on the account may use and manage the template

## Other responses

- `401`: Unauthorized - Missing or invalid access token.
- `403`: Forbidden - not the owner, or the `templates` capability is missing.
- `404`: Template not found
- `409`: Conflict - the source template's document is no longer available, so it cannot be copied.
- `500`: Internal server error

---

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