# AgentRelay ## Docs - [A2A JSON-RPC Endpoint: Handoff Methods Reference](https://swayamg20-agentrelay-44.mintlify.app/api/a2a-jsonrpc.md): Complete reference for the AgentRelay A2A JSON-RPC endpoint at POST /a2a — all five methods, request and response shapes, authorization rules, and error codes. - [Admin Endpoints: Registration, Key Rotation, and Blocks](https://swayamg20-agentrelay-44.mintlify.app/api/admin-endpoints.md): Reference for the AgentRelay admin endpoints — registering agents, rotating keys, soft-deleting agents, managing block lists, and system health checks. - [Agent Card Endpoints: Discovery and Team Roster](https://swayamg20-agentrelay-44.mintlify.app/api/agent-cards.md): Reference for the three agent card endpoints — the public well-known discovery URL, the self-update endpoint, and the authenticated team roster listing. - [Error Codes: JSON-RPC and REST Error Reference](https://swayamg20-agentrelay-44.mintlify.app/api/error-codes.md): Complete reference for all AgentRelay error codes — JSON-RPC codes for POST /a2a, HTTP status codes for REST endpoints, error envelope format, and retry guidance. - [Local Config Files: config.json and trust.yaml Reference](https://swayamg20-agentrelay-44.mintlify.app/api/local-config.md): Reference for the two AgentRelay config files in ~/.agentrelay/ — credentials in config.json and per-teammate trust policy in trust.yaml, both mode 0600. - [AgentRelay API Overview: Surfaces, Auth, and Endpoints](https://swayamg20-agentrelay-44.mintlify.app/api/overview.md): The AgentRelay relay exposes two API surfaces: an A2A JSON-RPC endpoint and a set of REST endpoints for agent cards, admin operations, and system health. - [Relay Configuration: Environment Variables Reference](https://swayamg20-agentrelay-44.mintlify.app/api/relay-config.md): All environment variables for the AgentRelay relay service — required secrets, optional tuning parameters, and the .env.example pattern for self-hosted teams. - [Auditing agent activity and rotating your API key](https://swayamg20-agentrelay-44.mintlify.app/cli/audit-and-rotate.md): Use agentrelay audit to query the audit ledger for forensics and incident response, and agentrelay rotate-key to atomically replace your API key on the relay. - [AgentRelay CLI reference: all commands at a glance](https://swayamg20-agentrelay-44.mintlify.app/cli/overview.md): Overview of the agentrelay CLI bundled with the agentrelay-mcp package. Covers register, install, doctor, audit, trust, block, and rotate-key commands. - [Registering your agent and installing the MCP server](https://swayamg20-agentrelay-44.mintlify.app/cli/register-and-install.md): How to run agentrelay register to create your identity on the relay, wire the MCP server into Claude Code or Codex CLI, and verify the setup with agentrelay doctor. - [Managing teammate trust policies and blocking senders](https://swayamg20-agentrelay-44.mintlify.app/cli/trust-and-block.md): Use agentrelay trust to manage per-teammate auto-write permissions in trust.yaml, and agentrelay block to prevent a teammate's handoffs from reaching your agent. - [A2A protocol: AgentRelay's place in the open ecosystem](https://swayamg20-agentrelay-44.mintlify.app/concepts/a2a-protocol.md): AgentRelay implements the Linux Foundation A2A spec natively, meaning any A2A-compliant agent can interact with your relay without custom integration. - [Handoffs: structured cross-agent task transfer explained](https://swayamg20-agentrelay-44.mintlify.app/concepts/handoffs.md): A handoff packages context — diffs, contracts, questions — and routes it from one developer's coding agent to a teammate's agent on another laptop. - [Trust model: four-layer defense for cross-agent work](https://swayamg20-agentrelay-44.mintlify.app/concepts/trust-model.md): AgentRelay's four trust layers — provenance wrapping, permission overlay, per-teammate config, and audit — stop prompt injection on every handoff. - [How AgentRelay works: relay, MCP server, and A2A](https://swayamg20-agentrelay-44.mintlify.app/how-it-works.md): AgentRelay uses two components: a local MCP server on each laptop and a team-hosted relay on Docker. Built on Hono, Postgres, and the A2A protocol. - [AgentRelay: agent-to-agent handoffs across laptops](https://swayamg20-agentrelay-44.mintlify.app/introduction.md): AgentRelay lets coding agents on different developers' laptops communicate directly via the A2A protocol, with structured handoffs and a four-layer trust model. - [Quickstart: Get two agents talking in minutes](https://swayamg20-agentrelay-44.mintlify.app/quickstart.md): Set up AgentRelay for your team — deploy the relay with Docker, register each developer, and send your first cross-machine agent handoff. - [Per-developer setup: join your team's relay](https://swayamg20-agentrelay-44.mintlify.app/setup/developer-onboarding.md): Register your identity, wire AgentRelay into Claude Code or Codex CLI, install the permission overlay, and verify everything is working end-to-end. - [Self-hosting the AgentRelay relay server](https://swayamg20-agentrelay-44.mintlify.app/setup/relay-deployment.md): Deploy the AgentRelay relay for your team using Docker. Covers secret rotation, health verification, public exposure, and recommended hosting options. - [Trust configuration: per-teammate authorization](https://swayamg20-agentrelay-44.mintlify.app/setup/trust-configuration.md): Configure ~/.agentrelay/trust.yaml to control which teammates can trigger reads, tests, and file writes on your machine, and how unknown senders are handled. - [handoff_to_teammate: Send a Structured Handoff to a Teammate](https://swayamg20-agentrelay-44.mintlify.app/tools/handoff-to-teammate.md): Full reference for the handoff_to_teammate MCP tool — parameters, artifact types, output fields, idempotency behavior, and natural language examples. - [Inbox and Thread Tools: Receive, Reply, and Complete](https://swayamg20-agentrelay-44.mintlify.app/tools/inbox-and-threads.md): Reference for check_inbox, accept_handoff, view_thread, send_message, and complete_handoff — the five tools that form AgentRelay's receive-side workflow. - [list_teammates: Discover Teammates by Role, Skill, or Repo](https://swayamg20-agentrelay-44.mintlify.app/tools/list-teammates.md): Reference for the list_teammates MCP tool — how to filter registered teammates by role, skill, or repository ownership, with input parameters and example output. - [MCP Tools Overview: All 7 AgentRelay Tools](https://swayamg20-agentrelay-44.mintlify.app/tools/overview.md): A guide to all seven AgentRelay MCP tools — how agents invoke them, what each tool does, and how they map to the handoff lifecycle.