Connect AgentGateway to Claude
Last updated: April 2026
Control your entire AgentGateway instance from natural conversation with Claude. List agents, rotate credentials, audit traffic, send emails, and manage rate limits — all without leaving Claude.
AgentGateway exposes its full management API as a remote Model Context Protocol (MCP) server, which means Claude can use it as a tool. This guide walks through connecting Claude to your AgentGateway account.
Note: AgentGateway is currently a custom connector. Once we're listed in the Anthropic Connectors Directory, setup will be a single click — no manual configuration required.
What You Can Do
Once connected, Claude can:
- Manage agent relays — create, list, update, delete, and inspect your agents
- Handle credentials — store API keys in the vault, link them to agents, rotate them safely
- Audit traffic — query request logs, view audit events, summarize error rates and latency
- Configure routing — inspect and update rate limits and circuit breakers
- Monitor usage — check plan limits, health scores, and monthly spend
- Send and read emails — use AgentGateway's email relay to read threads, send replies, or compose drafts
- Set up alerts — create, update, and delete alert rules based on your own conditions
All actions respect your role (admin, manager, or operator) and are scoped to your organization.
Prerequisites
Before connecting, make sure you have:
- An AgentGateway account — Sign up at agentgateway.com if you don't already have one
- Claude Pro, Max, Team, or Enterprise — Custom connectors are not available on the Free plan
- A Claude client — Claude.ai (web), Claude Desktop, or Claude Code
Setup Instructions
Claude.ai (Web) and Claude Desktop
- Open Claude and go to Settings → Connectors
- Scroll to the bottom and click Add custom connector
- Enter the following details:
- Name:
AgentGateway - URL:
https://app.agentgateway.com/api/mcp
- Name:
- Click Add and then Connect
- A new browser tab will open to the AgentGateway consent page
- Log in to AgentGateway if prompted
- Review the permissions — AgentGateway will request access to agents, credentials, audit logs, alerts, email, and usage data
- Click Allow Access
- You'll be redirected back to Claude automatically. The connector will show as connected.
That's it. You can now talk to AgentGateway directly from any Claude conversation.
Claude Code
- Open your MCP config file (
~/.config/claude-code/mcp.jsonon macOS/Linux, or equivalent on Windows) - Add AgentGateway as a server:
{ "mcpServers": { "agentgateway": { "url": "https://app.agentgateway.com/api/mcp" } } } - Restart Claude Code
- The first time you invoke an AgentGateway tool, Claude Code will open a browser window to complete OAuth
- Log in and click Allow Access — then return to Claude Code
Your tokens are stored securely and refreshed automatically. You won't need to re-authenticate unless you explicitly revoke access.
Example Prompts
Once connected, try asking Claude any of the following:
Agent Management
- “List all my agent relays and show me which ones have the lowest health scores.”
- “Create a new agent called 'stripe-relay' that proxies to api.stripe.com with a 300 RPM rate limit.”
- “What's the configuration for my 'hubspot-relay' agent?”
- “Delete the 'old-test-agent' relay — it hasn't been used in a month.”
Credentials & API Keys
- “Show me all credentials in my vault.”
- “Rotate the API key for my 'openai-relay' agent and send me the new one.”
- “Link the 'stripe-prod-key' credential to the stripe-relay agent.”
Audit & Monitoring
- “Show me all audit events from the last 24 hours where the status was 5xx.”
- “Summarize request volume by agent for this week — which is getting the most traffic?”
- “Pull the last 50 request logs for the stripe-relay agent.”
Usage & Billing
- “What's my usage looking like this month? Am I close to my plan limit?”
- “Show me the health scores for all agents — flag anything below 80.”
Alerts & Configuration
- “Create an alert rule that fires when the error rate on any agent exceeds 5% for 10 minutes.”
- “List all current rate limits and flag any agents that are rate-limited below 60 RPM.”
- “Show me unread email threads on the support@ mailbox.”
- “Draft a reply to the latest thread saying we'll investigate and respond within 24 hours.”
You can chain these together conversationally — Claude remembers context within a session, so follow-up questions like “now delete the one from that list with the lowest health score” work naturally.
How It Works
AgentGateway's MCP connector uses OAuth 2.0 with PKCE — the same standard used by Slack, Google, and Stripe for secure authorization. You never paste API keys into Claude. Instead:
- Claude redirects you to AgentGateway
- You log in and explicitly grant permission
- AgentGateway issues a short-lived access token to Claude
- Claude uses that token to make authenticated requests on your behalf
- Tokens refresh automatically, so you stay connected until you revoke access
All actions Claude takes on your behalf are logged in AgentGateway's audit trail, so you always have a full record of what was done and when.
Managing Access
You can revoke Claude's access at any time:
From Claude
Go to Settings → Connectors, find AgentGateway, and click Disconnect.
From AgentGateway
Log in to your AgentGateway dashboard, go to Settings → Connected Apps, and revoke the Claude session. This will immediately invalidate any tokens Claude holds, even if you don't disconnect from the Claude side.
Troubleshooting
“Couldn't reach the MCP server”
- Confirm you entered
https://app.agentgateway.com/api/mcpexactly (no trailing slash,httpsnothttp) - Check status.agentgateway.com for ongoing incidents
- If you're on an enterprise network, your firewall may be blocking outbound requests from Anthropic's infrastructure
“Authorization failed”
- Make sure you're logged in to the correct AgentGateway organization before clicking Allow
- If you have multiple orgs, check the org switcher in the top-right of the consent page
- Clear the connector from Claude and re-add it to start fresh
“Tool not found” or permission errors
- Your AgentGateway role determines which tools you can use. Admins and managers can perform all actions; operators can only read. Ask an org admin to upgrade your role if needed.
Tokens expired unexpectedly
- Access tokens last 1 hour and refresh automatically. Refresh tokens last 30 days. If you haven't used Claude in 30+ days, you'll need to reconnect — this is normal.
Security & Privacy
- Your credentials stay in AgentGateway. Claude never sees plaintext API keys or secrets — all credentials are fetched and used server-side within AgentGateway.
- Scoped access. Tokens are scoped to your user and organization. Claude cannot access other orgs' data.
- Audit logged. Every action Claude takes is recorded in your audit log with full context.
- Revocable. You can cut Claude off at any time from either side.
What's Next
We're actively working to get AgentGateway listed in the Anthropic Connectors Directory. Once approved, users will be able to install AgentGateway with a single click from within Claude — no manual URL entry required.
We're also planning a Cowork plugin that bundles the MCP server with opinionated skills and workflows, so you'll get not just tool access but full operational playbooks built in.
Need Help?
- Docs: agentgateway.com/docs
- Support: support@agentgateway.com
- Status: status.agentgateway.com