Retrieve comprehensive audit trails for UIP signatures using task hashes. Provides legally admissible records of what was signed, when, by whom, and who requested the signature.
The Audit API provides immutable, cryptographically verifiable records of all UIP signatures. Use signature task hashes to retrieve complete audit trails that meet legal requirements for digital signature verification.
Every UIP signature generates a unique task hash that serves as an immutable reference to the complete signing transaction. This hash can be used indefinitely to retrieve the full audit trail.
User signs document via Sign API or Messaging API
Unique hash created and returned in webhook
Use hash to retrieve full audit trail anytime
https://audit.api.uip.id/v1/{task_hash}
Authorization: Bearer YOUR_API_KEY
Parameter | Type | Description |
---|---|---|
task_hash | string | The unique task hash returned from Sign API or Messaging API signature completion |
GET https://audit.api.uip.id/v1/task_a1b2c3d4e5f6789012345678901234567890abcdef
Authorization: Bearer your_api_key_here
Task hashes are provided in the webhook response when a signature is completed via the Sign API or Messaging API. Store these hashes in your database to enable future audit lookups.
The audit response contains the complete signature transaction record with all relevant details for legal verification.
{
"task_hash": "task_a1b2c3d4e5f6789012345678901234567890abcdef",
"signature_type": "document", // or "simple"
"document": "base64_encoded_document_data", // actual file if document was attached
"title": "Employment Contract - Senior Developer Position",
"intent": "Please review and sign this employment contract",
"signed_at": "2024-01-15T10:45:23.123Z",
"signature": "uip_sig_def456ghi789...",
"signer_info": {
"uip_id": "uip_user_1234567890",
"full_name": "Alice Johnson"
},
"requesting_party": {
"uip_id": "uip_user_5432109876",
"full_name": "John Smith",
"api_key_id": "ak_987654321",
"requested_at": "2024-01-15T10:30:00Z"
},
"status": "signed"
}
• task_hash
- Unique signature identifier
• document
- Base64 encoded document
• title
- Document title
• intent
- Message from requester
• signed_at
- When signed
• signature
- Cryptographic signature
• status
- signed/pending/declined
// JavaScript implementation
async function getSignatureAuditTrail(taskHash) {
try {
const response = await fetch('https://audit.api.uip.id/v1/' + taskHash, {
method: 'GET',
headers: {
'Authorization': 'Bearer ' + YOUR_API_KEY
}
});
if (!response.ok) {
if (response.status === 404) {
throw new Error('Task hash not found');
}
throw new Error('HTTP error! status: ' + response.status);
}
const auditData = await response.json();
return auditData;
} catch (error) {
console.error('Audit retrieval failed:', error);
throw error;
}
}
// Generate audit report
function generateAuditReport(auditData) {
return {
documentTitle: auditData.title,
signerName: auditData.signer_info.full_name,
signerUipId: auditData.signer_info.uip_id,
signedAt: new Date(auditData.signed_at),
requestedBy: auditData.requesting_party.full_name,
requestedAt: new Date(auditData.requesting_party.requested_at),
signatureHash: auditData.signature,
status: auditData.status
};
}
// Usage examples
// Get audit trail from webhook task hash
const taskHash = 'task_a1b2c3d4e5f6789012345678901234567890abcdef';
const auditTrail = await getSignatureAuditTrail(taskHash);
// Generate summary report
const report = generateAuditReport(auditTrail);
console.log('Signature Report:', report);
// Export for legal use
const legalRecord = {
signedDocument: auditTrail.title,
signedBy: auditTrail.signer_info.full_name + ' (UIP: ' + auditTrail.signer_info.uip_id + ')',
signedOn: auditTrail.signed_at,
requestedBy: auditTrail.requesting_party.full_name,
status: auditTrail.status,
auditHash: auditTrail.task_hash
};
Ready to implement signature auditing in your application?