How to retrieve document history using BoldSign API?
If you need to track the history of a completed document, BoldSign offers an API that allows you to download the audit trail of the document. The audit trail document provides a comprehensive record containing all the information about the document, including its ID, name, sender, signers, IP addresses, timestamps, actions taken within the document, and more.
Please note that the audit trail document can be downloaded only after all the signers have completed the signing process for the document.
Here are code examples in various programming languages demonstrating how to download the audit trail via API:
Code snippet
curl -X GET 'https://api.boldsign.com/v1/document/downloadAuditLog?documentId={Your document Id}' \ -H 'accept: application/json' \ -H 'X-API-KEY: {your-api-key}'
var documentId = "{Your document Id}"; ApiClient apiClient = new ApiClient("https://api.boldsign.com", "your API key"); DocumentClient documentClient = new DocumentClient(apiClient); var documentStream = documentClient.DownloadAuditLog(documentId).ConfigureAwait(false);
import requests url = "https://api.boldsign.com/v1/document/downloadAuditLog?documentId={Your document Id}" payload={} headers = { 'accept': 'application/json', 'X-API-KEY': '{your API key}' } response = requests.request("GET", url, headers=headers, data=payload) print(response.text)
const axios = require('axios'); const response = axios.get('https://api.boldsign.com/v1/document/downloadAuditLog', { params: { 'documentId': '{Your document Id}' }, responseType: "stream", headers: { 'accept': 'application/json', 'X-API-KEY': '{your API key}' } });
In the provided examples, replace documentId
with the actual ID of the document for which you want to retrieve the history. After executing the relevant code snippet, you will receive an audit trail document containing the complete history of the specified document.