01

Self-service Workspace Admin API keys & zero-plaintext SHA-256 custody

Workspace Administrators mint, rotate, and revoke programmatic credentials directly inside /workspace#view=team under Developer API keys, giving carrier engineering and legal ops teams full self-service control.

Full secrets (prefixed tdl_live_ in production and tdl_test_ in isolated QA environments) are displayed exactly once upon creation or rotation. TrueDoc Legal stores only the irreversible SHA-256 cryptographic digest—never plaintext keys.

  • Authenticate via Authorization: Bearer tdl_live_... or the X-TrueDoc-API-Key request header.
  • Instant 0ms revocation & rotation: revoking a key immediately rejects subsequent requests with HTTP 401 api_key_revoked and records an immutable audit event.
  • Configurable expiration policies: 30 days, 90 days, 365 days, or non-expiring keys for governed service accounts.
02

Granular least-privilege scopes

Every API key is scoped to an explicit subset of five permissions so ingestion microservices never hold report-download privileges unless authorized.

  • cases:write — Create new claim or litigation cases via POST /v1/cases.
  • documents:write — Upload evidentiary files to POST /v1/cases/{case_id}/documents with SHA-256 custody sealing.
  • analysis:run — Trigger asynchronous 50+ control forensic runs via POST /v1/cases/{case_id}/analyze.
  • cases:read — List cases, inspect document manifests, and poll asynchronous job progress (/v1/jobs/{job_id}).
  • reports:read — Retrieve structured JSON forensic findings and sealed PDF reports (/report and /report.pdf).
03

Idempotency-Key safety, rate limits & dual upload modes

Supplying an Idempotency-Key header on POST /v1/cases, POST /v1/cases/{case_id}/documents, and POST /v1/cases/{case_id}/analyze guarantees safe network retries without creating duplicate dossiers or double-billing workspace quotas.

To ensure seamless traversal through enterprise WAFs and outbound proxies, POST /v1/cases/{case_id}/documents accepts both JSON payloads ({filename, content_type, content_base64}) and standard multipart/form-data uploads up to 35 MB.

  • Every authenticated response emits X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset headers.
  • Multi-tenant zero-enumeration: cross-workspace case, job, or run lookups always return HTTP 404.
  • Zero external AI training: documents and metadata submitted via /v1/* are never used to train public or third-party models.
04

Human-in-the-loop evidentiary structure & LatAm regulatory alignment

Developed in collaboration with Estudio Carvallo (insurance and litigation practice founded in 1885), the structured JSON returned by GET /v1/cases/{case_id}/runs/{run_id}/report never reduces a claim to an opaque black-box score. Every finding separates observed_fact, ai_hypothesis, and pending_verification anchored to exact document and page citations.

This contract supports auditable human-in-the-loop governance across CMF & Law 21.719 (Chile), CNSF & LFPDPPP (Mexico), SFC & Law 1581 (Colombia), SBS (Peru), SSN (Argentina), and SUSEP / LGPD (Brazil).