Skip to content

Retrieve Complete Audit History for a Single Object Record

curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v18.3/vobjects/product__v/00P000000000601/audittrail

Retrieve complete audit history for a single object record.

Vault does not audit individual field values for newly created records. For example, the audit trail for a new Product record would only include a single entry, and the Event Description would be “Product: CholeCap created”. We recommend exporting the current record along with the audit trail to ensure a complete export of all values. When a user deletes an object record, the audit trail captures all field values.

GET/api/{version}/vobjects/{object_name}/{object_record_id}/audittrail
NameDescription
Acceptapplication/json (default)
NameDescription
{object_name}The name__v of the object for which to retrieve audit history.
{object_record_id}The object record ID for which to retrieve audit history.
NameDescription
start_dateSpecify a start date to retrieve audit history. This date cannot be more than 30 days ago. Dates must be YYYY-MM-DDTHH:MM:SSZ format, for example, 7AM on January 15, 2018 would use 2018-01-15T07:00:00Z. If omitted, defaults to the Vault's creation date.
end_dateSpecify an end date to retrieve audit history. This date cannot be more than 30 days ago. Dates must be YYYY-MM-DDTHH:MM:SSZ format, for example, 7AM on January 15, 2018 would use 2018-01-15T07:00:00Z. If omitted, defaults to today’s date.
format_resultTo request a CSV file of your audit history, use csv.

Dates and times are in UTC. If the time is not specified, it will default to midnight (T00:00:00Z) on the specified date.

{{ "responseDetails": { "offset": 0, "limit": 200, "size": 3, "total": 3, "object": { "name": "object_audit_trail", "label": "Object Audit Trail", "url": "/api/v18.3/metadata/audittrail/object_audit_trail" } }, "data": [ { "id": "1718", "timestamp": "2018-03-20T22:00:15Z", "user_name": "c.brandon@veepharm.com", "full_name": "Cody Brandon", "action": "Edit", "item": "Product : Nyaxa", "field_name": "Generic Name", "old_value": "NYX", "new_value": "", "record_id": "00P000000000601", "object_label": "Product", "workflow_name": "", "task_name": "", "verdict": "", "reason": "", "capacity": "", "event_description": "\"NYX\" was removed from the \"Generic Name\" field." } ], "responseStatus": "SUCCESS" }

On SUCCESS, the response includes some of the following metadata: