Proof API
Base URL:https://cronozen.com/api/v1
Authentication
The Proof API uses API Key authentication, not JWT tokens. Include your key in theAuthorization header:
API Key Scopes
Each API key has one or more scopes that control access:
A key with
proof:read cannot record or approve decisions. A key with proof:write can do everything.
API keys are hashed with SHA-256 before storage. The plaintext key is only shown once at creation time. Treat it like a password.
Endpoints
POST /v1/decision-events
Record a new decision event. Scope required:proof:write
Request:
Response (201):
Idempotency
Pass anidempotencyKey to prevent duplicate events from retries or network issues. If the same key is sent again, the original event is returned (200) instead of creating a duplicate.
Use idempotency keys for any event that might be retried — settlement webhooks, queue consumers, or cron-triggered recordings.
GET /v1/decision-events
List decision events with filters. Scope required:proof:read
Query parameters:
Example:
POST /v1/decision-events//approvals
Add human approval and seal the event with SHA-256. Scope required:proof:write
Request:
Response (200):
GET /v1/evidence/
Retrieve sealed evidence with full hash chain verification data. Scope required:proof:read
Response (200):
The
evidence.get() endpoint returns the full event payload including input data, AI context, and chain position. Use this for compliance checks and chain integrity verification. Use evidence.export() when you need a portable audit document.GET /v1/evidence//export
Export a sealed event as a JSON-LD v2 audit document. Scope required:proof:read
Response (200):
Error Reference
All error responses follow this format:
409 Conflict — Sealed Event
The most common non-trivial error. Occurs when callingPOST /v1/decision-events/{id}/approvals on an event that has already been approved and sealed.
Why this happens:
- Concurrent approval attempts (two approvers clicking simultaneously)
- Retry logic re-sending an already-successful approval
- Webhook handler firing multiple times
idempotencyKey on the original decision.record() call to prevent duplicate events upstream.
Proof SDK
TypeScript SDK reference with error handling and integration patterns
Proof Pipeline
How the 4-stage evidence pipeline works under the hood