Documents

Copy a document

Copies a document with its contents. The copy belongs to the key's owner.

POST /v1/documents/:id/copy

Permission

The key must be granted docs.documents.write

A key without it gets 403 insufficient_scope, with the missing permission named in details.

Copies the contents, not an empty shell, so a copied spreadsheet has its data. Viewing the original is enough, because nothing about it changes; the copy belongs to the key's owner.

Path parameters

Field Type Description
id required string The document to copy.

Request body

The whole body is optional: send nothing to copy it into the root under a default name.

Field Type Description
title string Defaults to "Copy of" the original.
folder_id string Where to put the copy. The root when omitted.

Request

curl https://api.veruapis.com/v1/documents/:id/copy \
  -X POST \
  -H "Authorization: Bearer vak_live_..." \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{ "title": "Q4 plan", "folder_id": "0192f002-0000-7a41-b8d2-5e9f0c3a7b41" }'

Idempotency-Key is required on every write. Retrying with the same key returns the original response rather than repeating the operation, so a timeout is something you retry rather than something you investigate.

Response

Answers 201.

Field Type Description
id string
type string documentspreadsheet
title string
state string activetrashed
owner_id string The workspace user who owns it, which is not necessarily the key's owner.
folder_id string Empty for a document in the root.
metadata object Whatever you stored on it.
created_at RFC 3339
updated_at RFC 3339
{
  "data": {
  "id": "0192a1c2-7777-7a41-b8d2-5e9f0c3a7b41",
  "type": "spreadsheet",
  "title": "Q4 plan",
  "state": "active",
  "folder_id": "0192f002-0000-7a41-b8d2-5e9f0c3a7b41",
  "created_at": "2026-09-10T09:15:00Z"
},
  "meta": { "request_id": "req_01j8z9...", "timestamp": "2026-09-02T10:00:00Z" }
}
Worth knowing

The body is optional: send nothing and the copy lands in the root as "Copy of" the original. Contents come with it, so this is how a template becomes next quarter's sheet.

Errors

Every failure uses the same shape, with a stable string code you can branch on. See the error reference.

Related

POST /v1/documents/:id/copy

id
Sends this body to your own workspace, for real. Edit it before running.