Documents

Solution Move

Markdown for LLMs
PUT
/documents/solution/{documentSolutionId}/move

Moves a document solution into a folder, or back to the root. This is the only thing it changes: to change anything else about a document solution, use documents-solution-update.

Send the target folder's id as documentSolution.folderId, or send folderId as null to take the document solution out of its current folder and place it at the root. The folder must be one of the caller's own folders for document solutions — one created with folderEntityId DOCUMENT_SOLUTIONS. Any other is rejected with 400, and the document solution stays where it was: FOLDER_ID_INVALID for an id that matches no folder, FOLDER_FORBIDDEN for another user's folder, FOLDER_NAMESPACE_MISMATCH for an envelope template folder, and FOLDER_ENTITY_TYPE_MISMATCH for a Documents folder that holds another kind of record. Leaving folderId out places the document solution at the root, as null does.

Only the document solution's owner can move it. Anyone else in the subscription is rejected with 403 DOCUMENT_SOLUTION_FORBIDDEN. documents-solution-list returns folderId for a document solution in a folder.

A well-formed documentSolutionId that matches no document solution fails with 500 DOCUMENT_SOLUTION_NOT_FOUND, as does a deleted document solution, a body without documentSolution with 500 EDIT_DOCUMENT_SOLUTION_ERROR, and a documentSolution.folderId that is not a GUID with 500.

Authorization

AuthorizationBearer <token>

JWT token to authenticate the request.

In: header

X-Api-Key<token>

API key, sent as a request header.

In: header

Path Parameters

documentSolutionId*string

Id of the document solution to move, as returned by documents-solution-create in result.data.documentSolution.id.

Formatuuid

Request Body

application/json

The document solution's new folder under documentSolution, alongside an optional externalContext. documentSolution is mandatory.

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X PUT "https://example.com/documents/solution/d290f1ee-6c54-4b01-90e6-d701748f0851/move" \  -H "Content-Type: application/json" \  -d '{    "documentSolution": {      "folderId": "123e4567-e89b-12d3-a456-426614174000"    },    "externalContext": {      "id": "12345"    }  }'
{  "result": {    "statusCode": 200,    "message": "OK"  },  "origin": "PUT https://api.doctavian.com/v1/documents/solution/{documentSolutionId}/move",  "dateTime": "2026-10-08T09:30:12.000Z",  "externalContext": {    "id": "12345"  },  "userId": "1a2b3c4d-5e6f-4a1b-8c2d-3e4f5a6b7c8d",  "operationId": "d41c7e09a2b84f63915e0c8b27f3a6d1"}
{  "error": {    "statusCode": 400,    "message": "Bad Request",    "innerErrors": [      {        "code": "FOLDER_ID_INVALID",        "message": "No folder matches the given folderId.",        "userMessage": "No folder matches the given folderId."      }    ],    "externalErrors": []  },  "origin": "PUT https://api.doctavian.com/v1/documents/solution/{documentSolutionId}/move",  "dateTime": "2026-10-21T09:04:24.000Z",  "userId": "1fa93f1d-07e8-4e08-84e6-c0098f3b6ed5",  "operationId": "6d2a9c4e1b7f43a08e5c3d2b1a9f7e64"}
{  "error": {    "statusCode": 403,    "message": "Forbidden",    "innerErrors": [      {        "code": "DOCUMENT_SOLUTION_FORBIDDEN",        "message": "The document solution belongs to another user.",        "userMessage": "The document solution belongs to another user."      }    ],    "externalErrors": []  },  "origin": "PUT https://api.doctavian.com/v1/documents/solution/{documentSolutionId}/move",  "dateTime": "2026-10-21T09:04:24.000Z",  "userId": "1fa93f1d-07e8-4e08-84e6-c0098f3b6ed5",  "operationId": "6d2a9c4e1b7f43a08e5c3d2b1a9f7e64"}
Empty
{  "error": {    "statusCode": 500,    "message": "Internal Server Error",    "innerErrors": [      {        "code": "EDIT_DOCUMENT_SOLUTION_ERROR",        "message": "The document solution could not be moved.",        "userMessage": "Something went wrong. Please try again or contact support."      }    ]  },  "origin": "PUT https://api.doctavian.com/v1/documents/solution/{documentSolutionId}/move",  "dateTime": "2026-10-08T09:30:12.000Z",  "userId": "1a2b3c4d-5e6f-4a1b-8c2d-3e4f5a6b7c8d",  "operationId": "91f5c3e8a2b7406d9c1e4f0a8b3d6e27"}