Everything the console does is available over REST with JSON bodies. Create an API key in the console (account menu, API keys; the secret is shown once). Authentication is a bearer token.
https://portmem-api-140315397522.us-central1.run.app
Interactive reference at /docs, OpenAPI spec at /openapi.json.
curl -X POST "https://portmem-api-140315397522.us-central1.run.app/v1/ingest_file" \
-H "Authorization: Bearer pmk_YOUR_KEY" \
-F "file=@indenture.pdf" -F "source_id=indenture.pdf"
curl -X POST "https://portmem-api-140315397522.us-central1.run.app/v1/review/async" \
-H "Authorization: Bearer pmk_YOUR_KEY" -H "Content-Type: application/json" \
-d '{"document": "<the LLM-generated text>", "source": "indenture.pdf", "max_claims": 30}'
# poll until status is "done"; the result contains every claim + verdict
curl "https://portmem-api-140315397522.us-central1.run.app/v1/review/jobs/JOB_ID" -H "Authorization: Bearer pmk_YOUR_KEY"
curl -X POST "https://portmem-api-140315397522.us-central1.run.app/v1/decisions/REQUEST_ID/signoff" \
-H "Authorization: Bearer pmk_YOUR_KEY" -H "Content-Type: application/json" \
-d '{"claim": "<the flagged claim text>", "decision": "approved", "note": "checked s4.09"}'
curl -X POST "https://portmem-api-140315397522.us-central1.run.app/v1/decisions/REQUEST_ID/publish" \
-H "Authorization: Bearer pmk_YOUR_KEY" -H "Content-Type: application/json" -d '{"publish": true}'
# what a recipient sees (no auth; 404 until published)
curl "https://portmem-api-140315397522.us-central1.run.app/v1/public/verification/REQUEST_ID"
curl -X POST "https://portmem-api-140315397522.us-central1.run.app/v1/retrieve" \
-H "Authorization: Bearer pmk_YOUR_KEY" -H "Content-Type: application/json" \
-d '{"query": "change of control provisions", "max_results": 5, "sources": ["indenture.pdf"]}'
Returns the passages that currently govern, with supersession handled; scope with sources.
A self-contained MCP bridge gives Claude Desktop, Claude Code, or any MCP client direct tools over your workspace (search, upload, reviews, sign-offs, publishing). Setup instructions live in the console under account menu, API keys.
Every review, sign-off, and publish lands in a hash-chained, Ed25519-signed, append-only ledger. Read records with GET /v1/decisions/REQUEST_ID; export evidence packets for your own archive.