6.6. COPY /db/doc

6.6.1. Copying a Document
6.6.2. Copying from a Specific Revision
6.6.3. Copying to an Existing Document
MethodCOPY /db/doc
Request None
Response JSON of the new document and revision
Admin Privileges Requiredno
Query ArgumentsArgumentrev
 Description Revision to copy from
 Optionalyes
 Typestring
HTTP HeadersHeaderDestination
 DescriptionDestination document (and optional revision)
 Optionalno
   
Return Codes
201 Document has been copied and created successfully
409 Conflict (target document already exists)

The COPY command (which is non-standard HTTP) copies an existing document to a new or existing document.

The source document is specified on the request line, with the Destination HTTP Header of the request specifying the target document.