Quickstart
One path, end to end: install the CLI, get a key, prove the gate
(DENY → sandbox → ALLOW), wrap your first endpoint, then point the
scanner at your own codebase.
Repo script for the proof below:
./scripts/demo-five-minute.sh(dry-runs without a key — prints the commands and hits the keyless sandbox).
1. Install
Alternative: a standalone script you can run without pip.
2. Get a key
The sponsor token (writ_sp_...) is shown once for a new tenant.
Save it in a password manager — it approves grants and revokes
principals, and it is never recoverable. See Authentication
for the full two-credential model.
3. Prove the gate
Keep sponsor, agent, verb, target, purpose identical across sandbox and check — the grant matches on all five fields.
What just happened:
A second identical check after ALLOW is DENY again — the grant was
spent. Real verbs use writ grant --sponsor-token ... (or the
dashboard). See Concepts for the modes (allow | deny
| require_grant | step_up) and Audit log for
receipts and chain verification.
Two CLI notes: --key is required on each subcommand (check /
receipts / verify-chain do not read WRIT_API_KEY), and output is
raw JSON — parse decision, receiptId, ok.
4. Wrap your first endpoint
Add one check in front of the write:
Every decision writes a receipt to your tamper-evident audit log. To revoke the principal later — one call, no key rotation, no redeploy:
5. Scan your codebase
Have an existing codebase? Give this prompt to your coding agent to instrument it. The scanner is an on-ramp — discovery, not complete security coverage. See Scanner.
Next steps
- Concepts — principals, decisions, receipts
- CLI reference — every
./writcommand - API reference — the REST API