Skip to content

This endpoint is for Extensible Controlled Copy; controlled_copy_trace__v and controlled_copy_user_input__v objects. If your organization is not using these objects, you should use the endpoints for Legacy Controlled Copy.

After initiating a controlled copy user action, use this endpoint to download the controlled copy. To execute this request in an integration flow, Retrieve the Job Status and use the href under "rel": "artifacts". We do not recommend executing this request outside of this flow.

Before submitting this request:

  • You must have previously requested an initiate controlled copy job (via the API) which is no longer active
  • You must be the user who initiated the job or have the Admin: Jobs: Read permission
GET/api/{version}/objects/documents/actions/{lifecycle.state.action}/{job_id}/results
NameDescription
Acceptapplication/json (default) or application/xml. For this request, the Accept header controls only the error response. On SUCCESS, the response is a file stream (download).
NameDescription
{lifecycle.state.action}The name__v values for the lifecycle, state, and action. We recommend you Retrieve the Job Status and use the href under "rel": "artifacts" to obtain this value.
{job_id}The ID of the job, returned from the original job request. For controlled copy, you can find this ID in the Initiate User Action response.
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v19.1/objects/documents/actions/draft_to_effective_lifecycle__c.effective__c.downloadControlledCopya95fbf38/39303/results -OJ
Content-Type: application/octet-stream;charset=UTF-8 Content-Disposition: attachment;filename="Download Issued Batch Record - 2018-10-10T22-01-18.473Z.zip"

On SUCCESS, Vault downloads your controlled copy.

The HTTP Response Header Content-Type is set to application/octet-stream. The HTTP Response Header Content-Disposition contains a default filename component which you can use when naming the local file.

By default, your file is named in the format {user action label} - {now()}.zip, which is consistent with downloading this file through the Vault UI. If you choose to name this file yourself, make sure you add the .zip extension.