Who it is forA developer or platform team that runs agents from frameworks such as LangGraph or Pydantic AI and wants one gateway entry point for them.
The problemEach agent framework exposes its own endpoint and auth, so clients need separate setup for every agent.
The outcomeA client sends a message to a named agent through the gateway and prints the text reply.
What you need first
- Python and the uv package manager installed
- API keys for the LLM providers you plan to call, such as OpenAI or Anthropic
- For the gateway use cases: a machine to run the proxy server on and a LiteLLM master key or virtual key for clients
Steps
- Add your agent to the AI Gateway by following https://docs.litellm.ai/docs/a2a#adding-your-agent and set protocolVersion to 1.0 or 0.3
- Install the A2A client with
pip install a2a-sdk>=1.1.0(inferred from the README requirement) (inferred, check the README) - Set the Authorization header to a LiteLLM master key or virtual key
- Create the client from the agent card at http://localhost:4000/a2a/<agent-name> and call send_message
Prompt for your agent
Using the litellm repo at <path>, register the agent <agent_name> on the gateway and send it the message 'Hello!' through an A2A client pointed at http://localhost:4000/a2a/<agent_name>. Expected output: the agent's text reply printed to the console. Verify that the agent card loads before sending the message.
Caveat. The README requires a2a-sdk version 1.1.0 or newer, and the agent must already be running on its own framework before the gateway can call it.
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer