README & Quickstart

Project overview, installation, SDK usage, CLI commands, and architecture.

Protocol

Authorization request/response protocol, endpoints, and data formats.

Policy Language

How to write authorization policies: rules, conditions, obligations, and trust levels.

OpenClaw Integration

Run OpenLeash as a sidecar for OpenClaw. Configuration and hook points.

Agent Integration Guide

Step-by-step guide for AI agents: registration, authorization, and proof verification.

OpenAPI Reference

Interactive API documentation with Scalar UI. Full OpenAPI 3.0 spec for all endpoints.

Concepts

SDKs

CLI commands

npx openleash start Start the sidecar (with GUI)
npx openleash init Non-interactive setup
npx openleash wizard Interactive setup
npx openleash policy <cmd> list | show | upsert | validate | delete | unbind
npx openleash owner <cmd> list | show | add-contact | add-gov-id | add-company-id | validate
npx openleash keys <cmd> list | rotate
npx openleash playground Test policies locally

API endpoints

Public (no auth)

GET /v1/health Server health check
GET /v1/public-keys Fetch signing keys for offline verification
POST /v1/verify-proof Verify a proof token online
GET /v1/reference OpenAPI reference (Scalar UI)

Agent (Ed25519 signed)

POST /v1/authorize Request authorization + proof token
POST /v1/agents/register Register agent with challenge proof
GET /v1/agent/self Agent's own registration details
POST /v1/agent/approval-requests Create approval request
POST /v1/agent/policy-drafts Propose a new policy for owner review
GET /v1/agent/policy-drafts List and poll policy draft status

Owner (PASETO session)

POST /v1/owner/login Login with passphrase
GET /v1/owner/agents List agents under owner
GET /v1/owner/policies List owner's policies
GET /v1/owner/approval-requests Pending + resolved approval requests
POST .../approve Approve a request (issues approval token)
GET /v1/owner/audit Owner-scoped audit log (filter by user/org/agent)
GET /v1/owner/organizations/:orgId Organization details and members
POST .../members/:userId Invite members, manage roles

Admin (PASETO session with admin role)

GET /v1/admin/owners List all owners
GET /v1/admin/organizations List all organizations
GET /v1/admin/agents List all agents
GET /v1/admin/policies List all policies
GET /v1/admin/audit Full audit log
GET /v1/admin/config Server configuration (read-only)