EXIT PROTOCOL API V1

Controlled API access to the current workpaper contract.

Exit Protocol API V1 provides session-authenticated access to case, account, claim, report, and verification workflows. The broader product includes ReviewedTransfer, Money Flow Review, and Value Lineage; those authenticated workspaces are not exposed as API V1 endpoints. This page documents only the implemented API routes.

Session-authenticated V1 Case-scoped permissions Exact-byte verification Single-claim workpaper export No external API keys in V1

Overview

API at a glance

Public Utilities

  • health
  • capabilities
  • file verification

Case Data

  • cases
  • accounts
  • transactions
  • claims

Workpaper Workflow

  • calculate
  • export
  • report metadata
  • download

Security Boundary

  • session cookies
  • CSRF
  • case membership
  • permission checks
  • no raw storage paths

Onboarding

Understand the V1 access model first.

  1. Authenticate through the dashboardSign in at the product login. External API key access is not enabled in V1.
  2. Retain the authenticated session cookieProtected GET and POST endpoints require the live session cookie from that sign-in.
  3. Use CSRF token for calculate/export requestsSend X-CSRFToken with the session cookie on unsafe POST operations.
  4. Access only records allowed by case membership and permissionsFinancial endpoints require can_view_financials. Calculation requires authenticated session access, case membership, financial-view permission, financial-edit permission, and a valid CSRF token.

Public request

curl -s https://exitprotocols.com/api/v1/capabilities/

Protected GET

curl -s -b cookies.txt \
  https://exitprotocols.com/api/v1/cases/

Protected POST

curl -s -X POST -b cookies.txt \
  -H "Content-Type: application/json" \
  -H "X-CSRFToken: <CSRF_TOKEN>" \
  -d '{"strategy":"neutral"}' \
  https://exitprotocols.com/api/v1/claims/<CLAIM_UUID>/calculate/

Workflow

API V1 workpaper lifecycle

The API exposes controlled workflow steps. It does not make legal conclusions, provide expert opinions, or guarantee admissibility.

Reference

Endpoint directory

Public Endpoints

GET /api/v1/health/
AuthNone
PermissionNone
PurposeConfirm API availability without exposing private data.
ErrorsNone expected
{
  "status": "ok",
  "service": "Exit Protocol API",
  "version": "v1"
}
GET /api/v1/capabilities/
AuthNone
PermissionNone
PurposeReturn bounded V1 capability flags for diligence review.
Key fieldslibr_single_claim_workpaper, public_file_verification
{
  "libr_single_claim_workpaper": true,
  "multi_claim_pro_rata_default": false,
  "public_file_verification": true,
  "clio_selected_document_workflow": true,
  "legal_advice": false,
  "expert_report": false,
  "admissibility_guarantee": false
}
POST /api/v1/verify/
AuthNone (CSRF-exempt)
PermissionNone
RequestMultipart file or file_to_verify (max 10 MB; PDF, JPG, PNG, DOCX)
Errors400 invalid request/type · 413 file too large
{
  "match_found": true,
  "calculated_hash": "abc123...",
  "record_type": "Generated Review Workpaper",
  "timestamp": "2026-06-19T12:00:00+00:00",
  "message": "Final file hash verified"
}

Authenticated Case Access

GET/api/v1/me/
AuthSession cookie
PermissionAuthenticated user
PurposeReturn current user identity.
Errors401 authentication_required
{"id": "…", "email": "counsel@firm.example", "is_authenticated": true}
GET/api/v1/cases/
AuthSession cookie
PermissionCase membership
Responsecases[] with id, case_number, role, status
Errors401 · no cross-case leakage
{"cases": [{"id": "…", "case_number": "MAT-001", "role": "attorney_petitioner"}]}
GET/api/v1/cases/<case_id>/
AuthSession cookie
PermissionCase membership
PurposeCase metadata for an accessible case.
Errors401 · 404 if not a member
GET/api/v1/cases/<case_id>/accounts/
AuthSession cookie
Permissioncan_view_financials
Responseaccounts[] active accounts only
Errors401 · 404 without financial view
GET/api/v1/accounts/<account_id>/
AuthSession cookie
Permissioncan_view_financials on account case
ResponseAccount summary fields (no storage paths)
Errors401 · 404
GET/api/v1/accounts/<account_id>/transactions/
AuthSession cookie
Permissioncan_view_financials
Querypage/page_size or limit/offset (max 200)
Errors401 · 404
{"account_id": "…", "transactions": [...], "pagination": {"page": 1, "page_size": 50, "total": 120}}
GET/api/v1/accounts/<account_id>/claims/
AuthSession cookie
Permissioncan_view_financials
ResponseClaim list with strategy and traceable amount
Errors401 · 404
{"account_id": "…", "claims": [{"id": "…", "claim_name": "Premarital Savings", "last_strategy": "neutral"}]}
GET/api/v1/claims/<claim_id>/
AuthSession cookie
Permissioncan_view_financials
ResponseExtended claim detail including is_paid, tracing fields
Errors401 · 404

Workpaper Operations

POST/api/v1/claims/<claim_id>/calculate/
AuthSession + CSRF
PermissionCalculation requires authenticated session access, case membership, financial-view permission, financial-edit permission, and a valid CSRF token.
Request{"strategy": "neutral|maximize|minimize"}
Errors400 · 401 · 403 permission_denied · 404

Under the current V1 deployment, the configured calculation runner executes synchronously. The response returns refreshed persisted claim fields after the calculation path completes.

POST /api/v1/claims/<claim_id>/calculate/
{"claim_id": "…", "strategy": "neutral", "calculation_status": "complete", "current_traceable_amount": "8500.00", "lowest_intermediate_balance": "8200.00", "updated_at": "…"}

Claim detail (read later)

GET /api/v1/claims/<claim_id>/ remains useful for reading persisted claim values in a later session or after other updates.

GET /api/v1/claims/<claim_id>/

{
  "calculation_status": "complete",
  "current_traceable_amount": "8500.00",
  "lowest_intermediate_balance": "8200.00",
  "last_strategy": "neutral",
  "updated_at": "2026-06-19T12:00:00+00:00"
}
POST/api/v1/claims/<claim_id>/export/
AuthSession + CSRF
Permissioncan_view_financials, paid claim, single-claim account
Responsereport_id, file_hash_sha256, download URL
Errors403 payment_required · 403 multi_claim_export_blocked · 500 workpaper_export_failed
{
  "status": "created",
  "report_id": "…",
  "file_hash_sha256": "…",
  "download_url": "https://exitprotocols.com/api/v1/reports/…/download/",
  "verification_url": "https://exitprotocols.com/verify/"
}
GET/api/v1/reports/<report_id>/
AuthSession cookie
Permissioncan_view_financials on report case
Responsefile_hash_sha256, integrity_hash (snapshot), strategy, traceable amount
Errors401 · 404
GET/api/v1/reports/<report_id>/download/
AuthSession cookie — report download URLs are not signed public URLs
Permissioncan_view_financials
Responseapplication/pdf attachment bytes
Errors401 · 404

Security

Permission and response matrix

Scenario Response Meaning
No session401Sign in through the dashboard
No case membership404Resource is not disclosed
Missing financial-view permission404Financial data remains hidden
Missing financial-edit permission403Read access may exist, but calculation changes are not allowed
Missing CSRF403Session-authenticated POST requires CSRF
Unpaid export403Workpaper export remains gated
Multi-claim export403V1 export scope requires separate review
Tampered file200 with match_found: falseFile bytes do not match an integrity-ledger record

Integrity

What verification confirms — and what it does not.

  • POST /api/v1/verify/ hashes uploaded bytes with SHA-256 before any match lookup.
  • A match means uploaded bytes exactly match a recorded final-file hash in the integrity ledger.
  • Renaming a file does not matter — matching is byte-exact, not filename-based.
  • Editing or re-saving a PDF changes bytes and can fail matching even if content looks similar.
  • Snapshot hash (integrity_hash) and final file hash are different artifacts; snapshot hash alone does not verify.
  • Static synthetic sample PDFs may not be registered unless explicitly recorded in the ledger.
  • Verification does not decide ownership, admissibility, or legal outcome — attorney or expert review is required.

Integration

Designed for controlled workflows, not open data scraping.

Internal operational automation

Session-authenticated reads and exports inside case-scoped workflows.

Technical diligence and partner review

Bounded capability flags, OpenAPI schema, and explicit permission matrix for evaluation.

User-triggered selected-document integration workflows

The current Clio path is authorize → select one matter document → stage extraction candidates → review and approve ledger rows → confirm one source transaction. A separate user-confirmed finalization runs deterministic LIBR, stores the local workpaper, and attempts to upload a new PDF to the selected matter. Staging alone performs none of those downstream actions.

Future controlled integration paths

Machine API credentials are a separate future program — not enabled in V1.

  • No external API keys in V1
  • No bulk case sweep
  • No cross-case search
  • No raw file storage paths in API responses
  • No payment bypass
  • No Clio OAuth proxy through this API
  • No uncontrolled write endpoints

Applications

API use cases

A. Case Workspace Automation

Retrieve permitted case, account, and claim metadata inside an authenticated review workflow.

B. Controlled Workpaper Export

Trigger the same guarded single-claim workpaper path used by the product interface.

C. Integrity Verification

Confirm whether a downloaded generated export exactly matches a recorded file hash.

Machine-readable

OpenAPI schema

OpenAPI 3.1 JSON documents all V1 routes with session-cookie authentication, CSRF requirements on mutation endpoints, and bounded response envelopes. No API key schema. No undocumented endpoints.

Download OpenAPI Schema

GET /api/openapi.json

Live check

Try public endpoints

Only public GET endpoints are available here. Authenticated and mutation routes are not invocable from this panel.

Select an endpoint to view the JSON response.

Attorney-reviewable only · not legal advice · not an expert report · no admissibility guarantee · API V1 exposes the single-claim LIBR workpaper path, not Money Flow or Value Lineage endpoints