Restore Document Attachment Version
POST
/api/{version}/objects/documents/{doc_id}/attachments/{attachment_id}/versions/{attachment_version}?restore=trueHeaders
Section link for Headers| Name | Description |
|---|---|
Accept | application/json (default) or application/xml |
URI Path Parameters
Section link for URI Path Parameters| Name | Description |
|---|---|
{doc_id} | The document id field value. |
{attachment_id} | The attachment id field value. |
{attachment_version} | The attachment version__v field value. |
Query Parameters
Section link for Query Parameters| Name | Description |
|---|---|
restore | The parameter restore must be set to true. |
Request
Section link for Requestcurl -X POST -H "Authorization: {SESSION_ID}" \
https://myvault.veevavault.com/api/v22.1/objects/documents/565/attachments/567/versions/2?restore=trueResponse
Section link for Response{
"responseStatus": "SUCCESS",
"data":
{
"id": "567",
"version__v": 3
}
}Response Details
Section link for Response DetailsOn SUCCESS, Vault restores the specific version of an existing attachment to make it the latest version. The response will contain the attachment ID and version of the restored attachment.