MCP server for AI agents
Wagyu serves a Model Context Protocol endpoint, so an AI agent can quote, create and track a swap without writing an HTTP client:
https://api-beta.wagyu.xyz/v2/mcp
It is a stateless Streamable HTTP server. No key is needed.
Connect
Claude Code:
claude mcp add --transport http wagyu https://api-beta.wagyu.xyz/v2/mcp
Any client that takes a JSON config (Claude Desktop, Cursor, Windsurf):
{ "mcpServers": { "wagyu": { "type": "http", "url": "https://api-beta.wagyu.xyz/v2/mcp" } } }
Tools
| Tool | What it does |
|---|---|
list_chains | Chains available right now, and which can be a source or a destination. |
search_tokens | Find a token's address and decimals by symbol, name or address. |
get_quote | Estimate a swap. Spend an amount (side: "from") or receive one (side: "to"). |
create_swap | Create the order. Returns the deposit address, exact amount, expiry, orderId and sessionId. |
get_swap | Read the order's status and customerState with its sessionId. |
set_refund_address | Save a refund destination when customerState asks for one. |
Amounts sent to the tools are human decimals ("0.5"). The server converts them using the live catalog's decimals and refuses an amount that has more decimal places than the token supports.
Funding stays with the agent's wallet
The server never holds keys or moves funds. create_swap returns a funding instruction. The agent sends it with its own wallet tool, or shows it to the user. No money moves until that deposit arrives.
Rules the agent must follow
These are the same rules as the HTTP API. See actions and retries.
- Confirm with the user before
create_swap. Never call it again after a timeout or error: a second call creates a second order. - Keep
sessionIdprivate. It is the only credential for reading or acting on the order. - Poll
get_swapno more than every 30 seconds, untilcompleted,failed,expiredorrefunded. - A failed tool call returns the API error envelope. Branch on its
code, never on its prose.
Integrators
Orders placed through the MCP are attributed to Wagyu's own MCP integration. If you embed this server in your own product, send your key in the MCP connection headers as x-integrator-key: wg_.... Your orders are then attributed to you and earn your fee. See integrator key.