> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cronozen.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Proof Quickstart

> Add tamper-proof evidence to your AI decisions in under 5 minutes

# Proof Quickstart

Add decision evidence to your application in 3 steps.

***

## Step 1: Install

```bash theme={null}
npm install cronozen
```

## Step 2: Record a Decision

```typescript theme={null}
import { Cronozen } from "cronozen"

const cz = new Cronozen({
  apiKey: process.env.CZ_KEY!,
  baseUrl: "https://cronozen.com/api/v1",
})

const event = await cz.decision.record({
  type: "agent_execution",
  actor: { id: "billing_agent", type: "ai_agent", name: "Billing Agent" },
  action: {
    type: "invoice_approved",
    input: { invoiceId: "INV-001", amount: 280000 },
  },
  aiContext: { model: "gpt-4", confidence: 0.91 },
})

console.log(`Recorded: ${event.id}`)
console.log(`Status: ${event.status}`) // → "recorded"
```

## Step 3: Approve and Seal

```typescript theme={null}
const approval = await cz.decision.approve(event.id, {
  approver: { id: "finance_lead", type: "human", name: "Finance Lead" },
  result: "approved",
  reason: "Verified against contract terms",
})

console.log(`Sealed hash: ${approval.sealedHash}`)

// Export audit-ready report
const report = await cz.evidence.export(event.id)
console.log(report) // JSON-LD v2
```

***

## What Just Happened?

1. **Record** — Your decision was captured with structured metadata (who, what, why, AI context)
2. **Chain** — The event was linked to the previous event's hash, forming an immutable SHA-256 chain
3. **Seal** — Human approval triggered the final hash seal. The event is now tamper-proof.
4. **Export** — The JSON-LD document contains everything an auditor needs: decision, approval, and chain integrity proof.

```
[Event #N-1] ──hash──▶ [Your Event #N] ──hash──▶ [Event #N+1]
                              │
                        SHA-256 sealed
                        Approval recorded
```

If anyone modifies event #N after sealing, the hash chain breaks at #N+1 — **immediately detectable**.

***

## Try with cURL

```bash theme={null}
# Record a decision
curl -X POST https://cronozen.com/api/v1/decision-events \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "agent_execution",
    "actor": { "id": "support_agent", "type": "ai_agent" },
    "action": {
      "type": "ticket_escalated",
      "input": { "ticketId": "TKT-789" }
    },
    "aiContext": { "model": "claude-sonnet-4-5-20250514", "confidence": 0.88 }
  }'

# Approve
curl -X POST https://cronozen.com/api/v1/decision-events/{id}/approvals \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "approver": { "id": "team_lead", "type": "human", "name": "Team Lead" },
    "result": "approved",
    "reason": "Confirmed escalation criteria met"
  }'

# Export evidence
curl https://cronozen.com/api/v1/evidence/{id}/export \
  -H "Authorization: Bearer YOUR_API_KEY"
```

***

## Next Steps

<CardGroup cols={2}>
  <Card title="Proof SDK Reference" icon="code" href="/examples/proof-sdk">
    Full API reference with error handling and integration patterns
  </Card>

  <Card title="DPU Architecture" icon="link" href="/architecture/dpu">
    How the hash chain and governance guards work under the hood
  </Card>

  <Card title="Proof Pipeline" icon="shield" href="/architecture/proof-pipeline">
    5-stage evidence pipeline from decision to audit-ready proof
  </Card>

  <Card title="Why Cronozen" icon="lightbulb" href="/why-cronozen">
    How Cronozen differs from traditional compliance tools
  </Card>
</CardGroup>
