---
title: "Update Document"
method: PATCH
path: "/v1/documents/{id}"
tags: ["Document Access"]
---

# Update Document

`PATCH /v1/documents/{id}`

Updates properties of an existing document. Supports partial updates via JSON for title, parent, and classification.

Supports moving documents into (but not out of) repositories by providing a repo_-prefixed repository ID as the parent.

## Path parameters

- `id` string, uuid, required

## Request body

- PatchDocumentRequestBody — Request body for updating a document. At least one field should be provided.
  - `title` string — New title for the document. Must be non-empty, at most 300 characters, and must not start or end with whitespace.
  - `parent` union — ID of the folder or repository to move the document into. Set to null to move the document to the root folder. For repositories, use the repository ID prefixed with `repo_` (e.g., `repo_12345`). For folders, use the numeric folder ID.
    - integer — Numeric folder ID.
    - string — Repository ID prefixed with `repo_`.
  - `customTags` string[] — List of custom tags to assign to the document. Including this field overwrites all existing tags on the document with the provided values. Each tag must be non-empty and must not start or end with whitespace. Omitting this field leaves existing tags unchanged; set to an empty array to clear all tags.
  - `classificationId` string, uuid, nullable — ID of the classification to assign to the document. Omitting this field leaves the existing classification unchanged; set to null to remove the classification.

## Response `200`

OK with Document resource containing information about the updated document.

- Document
  - `documentId` string, uuid, required — Unique ID of the document
  - `title` string, required — Title of the document
  - `editUrl` string, uri, required — Link to edit the document
  - `viewUrl` string, uri, required — Link to view the document
  - `version` integer, required — Most recent version
  - `pageCount` integer, required — Number of pages within the document
  - `canEdit` boolean, required — If requesting user can edit the document
  - `created` string, date-time, required — Date and time of when the document was created
  - `creatorId` integer, required — ID of user who created and owns the document
  - `lastModified` string, date-time, required — Date and time of when the document was last modified
  - `lastModifiedUserId` integer, required — ID of user who most recently modified the document
  - `customAttributes` CustomAttribute[], required — List of any custom attributes belonging to the document. Populated for Enterprise Accounts only.
    - `type` 'singleLineText' | 'multiLineText' | 'singleSelectDropdown' | 'multiSelectDropdown' | 'webLink' | 'numericalRange' | 'hierarchicalDropdown', required — The custom attribute type
    - `name` string — Title of the custom attribute. hierarchicalDropdown attributes do not have names.
    - `value` union — The value assigned to the custom attribute. The type of this value is determined by the Attribute Type.
      - string
      - union[]
        - union
          - DataPair — Object representing a key-value pair of data.
            - `name` string, required — Custom data key
            - `value` string, required — Custom data value
          - string
  - `customTags` string[], required — List of any custom tags assigned to the document
  - `product` 'lucidchart' | 'lucidscale' | 'lucidspark', required — The Lucid Suite product that a document was created in.
  - `status` string, nullable — Current assigned status of the document
  - `classification` string, nullable — Current assigned classification of the document
  - `classificationId` string, uuid, nullable — Current assigned classification ID of the document.
  - `trashed` string, date-time, nullable — If defined, the timestamp when the document was moved to the trash
  - `parent` integer, nullable — ID of the parent folder
  - `repository` Repository
    - `repositoryId` string — the ID of the repository
  - `accountId` integer, nullable, required — ID of Lucid account that owns the document
  - `owner` DocumentOwner
    - `id` number — Id of either the user or the account, depending on the type of the document user resource.
    - `type` string — Specifies if the owner resource is referring to a user or an account. Value will be either "user" or "account".
    - `name` string — Full name of the user that owns this document. This field is excluded if this document is owned by an account.

## Other responses

- `400` — Bad Request. * Title must be non-empty when included. * Title must be at most 300 characters. * Title must not start or end with whitespace. * Invalid parent ID. Must be either a string prefixed with repo_ (for repositories) or a number. * Custom tag values must be non-empty when included. * Custom tag values must not start or end with whitespace. * Classification ID must either be null or an existing classification ID.
- `403` — Forbidden. The app making the request does not have permission to the document, or the document does not exist.
- `409` — Conflict. A conflict occurred when saving the document.

---

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