Skip to main content

Base URL

All API requests use this base URL:

Authentication

The Mandate API uses two authentication schemes depending on the caller.

Agent authentication (RuntimeKeyAuth)

Agents authenticate with a runtime key in the Authorization header:
Runtime keys use prefixes to enforce environment separation:
  • mndt_test_* for testnet (Sepolia, Base Sepolia)
  • mndt_live_* for mainnet (Ethereum, Base)
The runtime key is issued during agent registration and stored in ~/.mandate/credentials.json. You can regenerate it from the dashboard if compromised.

Dashboard authentication (Sanctum)

Dashboard users authenticate via GitHub OAuth. The Laravel session and Sanctum token are managed automatically by the frontend. Dashboard API endpoints require an active session or a Sanctum token.

Request format

All requests use JSON:

Error format

Every error response returns JSON. The format depends on the error type. Policy block:
General error:
See Error Codes for the full HTTP status reference and Block Reasons for all blockReason values.

Endpoint groups

Agent API (7 endpoints)

These endpoints are called by agents using RuntimeKeyAuth.

Dashboard API (10+ endpoints)

These endpoints are called by the dashboard frontend using Sanctum authentication.

Open endpoint (1)

Rate limiting

The API enforces per-agent rate limits. See Rate Limits for default limits per endpoint category and retry strategies. Rate limit headers are included in every response:
  • X-RateLimit-Limit
  • X-RateLimit-Remaining
  • Retry-After (on 429 responses only)

Interactive playground

The API reference pages include an interactive playground powered by the OpenAPI specification. You can test endpoints directly from the docs using your runtime key. Enter your mndt_test_* key to test against the Mandate API without writing code.
Never use a mndt_live_* key in the playground. Use testnet keys for testing.

Next Steps

Register Agent

Create your first agent via the API.

Validate Transaction

Run a validation check against the policy engine.

Error Codes

Full HTTP status code reference.