---
title: "Duplicate published document"
method: POST
path: "/v1/documents/{documentId}/duplicate"
tags: ["Documents"]
---

# Duplicate published document

`POST /v1/documents/{documentId}/duplicate`

Duplicate a published document.

## Path parameters

- `documentId` string, required

## Query parameters

- `userId` string

## Request body

- object
  - `name` string, required — The name for the duplicated document
  - `folderPath` string, nullable — Path to the destination folder. If not provided, the document will be duplicated to the root.
  - `scope` 'organization' | 'restricted' — The visibility scope for the duplicated document. If not provided, inherits from the destination folder or defaults to `restricted`.

## Response `201`

Document duplicated successfully

- object
  - `dashboardId` string — The dashboard ID, if the duplicated document has a dashboard
  - `identifier` string — Unique identifier for the newly created document
  - `name` string — The name of the duplicated document
  - `workbookId` string — The workbook ID of the duplicated document

## Other responses

- `400` — Bad Request. Possible error messages: - `name: Name cannot be empty` - `name: Name must be 255 characters or less` - `Scope "organization" and folder scope "restricted" do not match`
- `401` — Missing or invalid authentication
- `403` — Insufficient permissions. Possible error messages/causes: - `User does not have access to create content on the specified connection` - `User-scoped API keys can only be used to act on behalf of the authenticated user.` - `Document duplication is disabled`. The document's duplication permission is disabled. - Operations targeting personal/restricted scope require the user's **Personal content access** setting (`omni_allows_personal_content` system attribute) to be enabled for the user. If not enabled, the API will respond with `403 Forbidden`.
- `404` — Not Found. Possible error messages: - `Document with identifier "<documentId>" not found` - `Published document with id "<documentId>" does not exist`. This will surface when attempting to duplicate a draft. - `Folder with path "<folderPath>" does not exist`
- `405` — Method Not Allowed - Invalid HTTP method for this endpoint
- `429` — Too Many Requests - Rate limit exceeded (60 requests/minute)

---

[API](https://skmtc.net/omni/apis/omni-api.md) · [All operations](https://skmtc.net/omni/apis/omni-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/omni/omni-api/revisions/6b02f7349d0e/schema)
