Restore a Document from the Specified Version - Restore a Document from the Specified Version - Restores the specified version of a document to its working copy. - Content Innovation Cloud - Hyland Content REST API - Current/Hyland-Content-REST-API/qly1740763464567 - Current - Current

Hyland Content REST API

Platform
Content Innovation Cloud
Product
Hyland Content REST API
Release
Current
License
ft:lastPublication
2026-11-09T23:12:01.844878
ft:locale
en-US

Restores the specified version of a document to its working copy.

Base Request

POST /api/documents/[versionId]/restore

where [versionId] is the alphanumeric ID for the version.

Headers

Header Name Description Required Values
Authorization The access token Required Bearer [access_token]

where [access_token] is a string generated when you complete authentication (see Getting Started)

User-Agent Identity of the client making the request to the server Required [product]/[version]

where [product] is the name of the software you are using to make the request and [version] is the numbered version of the software (for example, MyCompanyProduct/1.0).

For information on other types of values commonly included in user-agent request headers, see the User-Agent HTTP header reference section on the Mozilla developer documentation website.

HXCS-REPOSITORY The repository ID Optional Any contributed repository name. Default is default.
Accept The format of the data to be returned Optional application/vnd.hxcs.v1+json

Sample Request

POST /api/documents/[versionId]/restore

Authorization: Bearer [access_token]
User-Agent: MyCompanyProduct/1.0
HXCS-REPOSITORY: default
Accept: application/vnd.hxcs.v1+json

Response Body

See Document for response body details.

Sample Response

{
  "sys_acl": [
    {
      "begin": "2025-02-28T17:01:13.080Z",
      "creator": "string",
      "end": "2025-02-28T17:01:13.080Z",
      "granted": true,
      "group": {
        "id": "string",
        "name": "string"
      },
      "permission": "string",
      "status": "PENDING",
      "user": {
        "email": "string",
        "firstName": "string",
        "id": "string",
        "lastName": "string"
      }
    }
  ],
  "sys_changeToken": "string",
  "sys_contributors": [
    {
      "email": "string",
      "firstName": "string",
      "id": "string",
      "lastName": "string"
    }
  ],
  "sys_created": "2025-02-28T17:01:13.080Z",
  "sys_creator": {
    "email": "string",
    "firstName": "string",
    "id": "string",
    "lastName": "string"
  },
  "sys_description": "string",
  "sys_effectiveAcl": [
    {
      "begin": "2025-02-28T17:01:13.080Z",
      "creator": "string",
      "end": "2025-02-28T17:01:13.080Z",
      "granted": true,
      "group": {
        "id": "string",
        "name": "string"
      },
      "permission": "string",
      "status": "PENDING",
      "user": {
        "email": "string",
        "firstName": "string",
        "id": "string",
        "lastName": "string"
      }
    }
  ],
  "sys_effectivePermissions": [
    "string"
  ],
  "sys_fulltextBinary": "string",
  "sys_id": "string",
  "sys_isFolderish": true,
  "sys_lastContributor": {
    "email": "string",
    "firstName": "string",
    "id": "string",
    "lastName": "string"
  },
  "sys_lifecycleState": "string",
  "sys_lockCreated": "2025-02-28T17:01:13.080Z",
  "sys_lockOwner": {
    "email": "string",
    "firstName": "string",
    "id": "string",
    "lastName": "string"
  },
  "sys_mixinTypes": [
    "string"
  ],
  "sys_modified": "2025-02-28T17:01:13.080Z",
  "sys_name": "string",
  "sys_parentId": "string",
  "sys_parentPath": "string",
  "sys_path": "string",
  "sys_pathDepth": 0,
  "sys_pos": 0,
  "sys_primaryType": "string",
  "sys_repository": "string",
  "sys_secpol": [
    "string"
  ],
  "sys_title": "string",
  "additionalProp1": {}
}

Status Codes and Errors

The following table lists the returned status codes.

Code Description Notes
200 OK Restores the specified version of a document to its working copy.
401 Not Authorized Authentication has failed or was not provided.
403 Not Allowed Access permissions are invalid or missing.
404 Not Found The document could not be found.
412 Precondition Failed The server did not allow document restoration because the document is not versionable.
422 Unprocessable Entity The document selected for restoration is not a version.