Get the FREE Ultimate OpenClaw Setup Guide →

a2a-directory

Agent2Agent (A2A) – AgentCards, Servers, Clients, Docs

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio sing1ee-a2a-directory node server.js \
  --env NODE_ENV="production"

How to use

A2A Directory serves as an MCP-compatible server that facilitates agent-to-agent coordination and directory-like interactions within the A2A ecosystem. The server is designed to register and expose directory-related capabilities so agents can discover and communicate with each other through standardized HTTP/JSON-RPC channels. Typical usage revolves around starting the server and then leveraging the included tools to query available agents, register new agents, and perform cross-agent tasks via the A2A protocol. If you’re building or testing agents, you’ll want to interact with the server’s endpoints to discover agents, fetch capability descriptors, and initiate tool-assisted tasks as defined by the A2A specification. The project emphasizes interoperability, security, and async task handling, which means you can chain long-running operations and stream results as needed while maintaining privacy boundaries between agents.

How to install

Prerequisites:

  • Node.js (v18+ recommended) and npm/yarn installed
  • Git to clone the repository

Step-by-step installation:

  1. Clone the repository git clone https://github.com/google-a2a/a2a-directory.git cd a2a-directory

  2. Install dependencies npm install

    or

    yarn install

  3. Configure environment (optional but recommended)

    • Create a .env file or export variables as needed. Example: export NODE_ENV=production export A2A_PORT=8080 export A2A_HOST=0.0.0.0
  4. Start the MCP server npm run start

    or if using a direct node script

    node server.js

  5. Verify the server is running curl http://localhost:8080/health

  6. Optional: run with a process manager (e.g., pm2) pm2 start server.js --name a2a-directory

Additional notes

Notes:

  • Ensure proper network access if exposing the MCP server beyond localhost (firewalls, TLS termination, and authentication may be required).
  • Review A2A protocol compatibility when integrating with other agents or services to ensure JSON-RPC handlers and endpoints align with the standard.
  • If you customize environment variables, document them in a README or .env.example for future contributors.
  • Check logs for initialization messages and verify that the server registers correctly with any central registries or discovery services you rely on.
  • Common issues include port conflicts, missing dependencies, or misconfigured environment variables; verify the startup script path and ensure Node.js version compatibility.

Related MCP Servers

Sponsor this space

Reach thousands of developers