Skip to main content
AgentRelay stores two configuration files on each developer’s laptop under ~/.agentrelay/. Both files must have mode 0600 (readable only by the owning user) because they contain secrets and per-teammate authorization policy. The agentrelay register command creates config.json and the agentrelay install command creates trust.yaml with safe defaults.
Both files contain secrets. Keep them at mode 0600. Do not commit them to source control, copy them to shared drives, or let other processes read them. Run chmod 0600 ~/.agentrelay/config.json ~/.agentrelay/trust.yaml if the permissions are ever reset.

config.json — credentials and connection

config.json stores the credentials the MCP server needs to authenticate with the relay. It is written by agentrelay register and read by the MCP server on every startup.
If config.json is missing or unreadable, the MCP server still starts but every tool call returns an instructive error:
This means you can install the MCP server before registering without breaking your agent harness.

trust.yaml — per-teammate trust policy

trust.yaml is Layer 3 of AgentRelay’s four-layer trust model. It defines how much autonomy each teammate’s agent has on your machine: which action classes run without a prompt, which paths can be written automatically, and which senders are blocked outright. Created by agentrelay install with a default reject policy for unknown teammates. Managed by agentrelay trust commands or by editing the file directly.

Field reference

version
number
required
Schema version. Must be 1. Future schema bumps will document migration steps. Unknown top-level keys produce a warning, not an error.
teammates
object
A map of teammate handles to trust policies. Each key is a handle (bob@acme).
unknown_teammates
object
Policy for handoffs from agents not listed in teammates.
blocked
string[]
Hard block list. Entries here always reject, regardless of any entry in teammates. Populated by agentrelay block <handle>. Your MCP server rejects handoffs from these handles on every evaluation.
defaults
object
Fallback policy applied to teammates listed in teammates that do not override a specific field. Also applied to unknown teammates when unknown_teammates.policy is allow_with_default_trust.

Glob matching for auto_write_paths

Path entries in auto_write_paths are matched as glob prefixes. A trailing / matches all files under that directory:
  • "docs/" matches docs/api.md, docs/setup/quickstart.md, and docs/reference/components.md
  • "README.md" matches only README.md at the repo root
  • "src/generated/" matches any file under src/generated/
A sender in the blocked list is always rejected even if they are also listed in teammates with a permissive policy.

Environment overrides for testing

Two environment variables let you redirect the MCP server to alternate paths without editing the filesystem: These are testing overrides only. In normal operation, use the files in ~/.agentrelay/.