# THORChain Swap — Agent View

Public web interface for native cross-chain swaps (BTC, ETH, stablecoins, and more) powered by THORChain and Maya Protocol. No accounts, no bridges, no wrapped assets.

This is the machine-readable view of https://swap.thorchain.org/ (`?mode=agent`). The same document is available as JSON: request `https://swap.thorchain.org/?mode=agent` with `Accept: application/json`.

## Capabilities

- **swap-quote** — Fetch indicative swap output, fees, slippage, and timing; use core prepare_swap for executable deposit instructions.
  - Access: MCP tool quote_swap at https://mcp.thorchain.org/mcp; amount is an integer in 1e8 base units
  - Auth: none
- **list-pools** — List THORChain liquidity pools through Midgard with limit/offset pagination.
  - Access: MCP tool list_pools at https://mcp.thorchain.org/mcp
  - Auth: none
- **network-status** — Read node counts, APY, reserve, pooled RUNE, churn height, and vault migration state.
  - Access: MCP tool get_network_summary at https://mcp.thorchain.org/mcp
  - Auth: none
- **memoless-swap** — Swap without a connected wallet by sending funds to a deposit address; the user sends the funds themselves.
  - Access: https://swap.thorchain.org/ (UI) or https://api.thorchain.org/memoless/api/v1
  - Auth: none
- **wallet-swap** — Swap by connecting a wallet in the browser; transactions are signed locally by the user.
  - Access: https://swap.thorchain.org/ (UI only — cannot be driven by an agent)
  - Auth: user wallet
- **partner-api-key** — Obtain an aggregator API key (and affiliate fee splits, widget, and earnings reporting) through the affiliate program.
  - Access: https://affiliate.thorchain.org — register, verify email, key issued on approval
  - Auth: partner account
- **subscribe-updates** — Subscribe to updates through the public REST API.
  - Access: POST https://swap.thorchain.org/api/v1/newsletter
  - Auth: none (rate limited, Idempotency-Key supported)

Not supported:

- Executing or signing a swap on a user behalf — the server holds no keys and never submits transactions.
- Fiat on/off-ramps, NFTs, derivatives, or custodial accounts.
- Any credential from this site — it issues none, and needs none.
- Instant, unreviewed keys for the swap aggregator backend (https://api.thorchain.org/v1) — those come from the affiliate program after review.

## Authentication

Browsing, quoting, the MCP server, and the support APIs require no credentials, and this site runs no authorization server — clients that probe for OAuth metadata find none and connect directly. The swap aggregator backend (https://api.thorchain.org/v1) takes an x-api-key issued free through the affiliate program at https://affiliate.thorchain.org after review; the memoless API and the MCP server need no key.

No authorization server, no tokens: a client that probes for OAuth metadata finds none and connects directly. Aggregator API keys come from https://affiliate.thorchain.org.

Details: https://swap.thorchain.org/auth.md and https://swap.thorchain.org/developers/auth

## Endpoints

MCP server (streamable HTTP, no key) — https://mcp.thorchain.org/mcp

Canonical Registry: org.thorchain/thorchain-mcp (https://registry.modelcontextprotocol.io/v0.1/servers/org.thorchain%2Fthorchain-mcp/versions/latest). Send Accept: application/json, text/event-stream and support SSE responses. The legacy https://swap.thorchain.org/mcp URL redirects with HTTP 308; it does not translate old tool names or arguments. The core endpoint currently has no browser CORS support; connect from an MCP host or a server-side client.

Selected tools (retrieve the full list with tools/list):

- `quote_swap` — Read indicative THORChain swap output, fees, slippage, and timing.
- `list_pools` — Read THORChain pools from Midgard with pagination.
- `get_network_summary` — Read node counts, APY, reserve, pooled RUNE, churn height, and vault migration state.

REST:

- `POST https://swap.thorchain.org/api/v1/newsletter` — Subscribe an email address to THORChain Swap updates. (auth: `none`)
- `GET https://swap.thorchain.org/.well-known/status` — Discovery endpoint status. (auth: `none`)

OpenAPI description: https://swap.thorchain.org/openapi.json

Upstream swap APIs the UI itself uses: https://api.thorchain.org/v1 (quotes and routing, `x-api-key` gated — free keys via https://affiliate.thorchain.org) and https://api.thorchain.org/memoless/api/v1 (memoless swaps, no key).

## Pricing

Free. No accounts, subscriptions, or usage tiers; per-swap costs are protocol fees itemised in each quote. Full breakdown: https://swap.thorchain.org/pricing.md

## Conventions

- Assets: CHAIN.SYMBOL, e.g. BTC.BTC, ETH.USDC-0XA0B86991C6218B36C1D19D4A2E9EB0CE3606EB48
- Amounts: Core MCP quote_swap takes an integer in 1e8 base units (1 BTC = 100000000); REST protocol amounts are strings.
- Errors: Support REST APIs return JSON error, code, hint, and documentation fields. Core MCP uses JSON-RPC envelopes over JSON/SSE.
- Rate limits: Support REST APIs return 429 with Retry-After. MCP limits belong to the canonical core deployment.

## Safety

- Never request, store, or infer private keys or seed phrases.
- Never execute a swap for a user; only users sign in their own wallets.
- Treat quotes, memos, inbound addresses, and balances as time-sensitive — re-fetch before presenting.
- Confirm destination addresses with the user before they submit any transaction.

## More Discovery

- llms: https://swap.thorchain.org/llms.txt
- llms_full: https://swap.thorchain.org/llms-full.md
- agents: https://swap.thorchain.org/AGENTS.md
- developers: https://swap.thorchain.org/developers.md
- pricing: https://swap.thorchain.org/pricing.md
- auth: https://swap.thorchain.org/auth.md
- api_catalog: https://swap.thorchain.org/.well-known/api-catalog
- agent_card: https://swap.thorchain.org/.well-known/agent-card.json
- agent_skills: https://swap.thorchain.org/.well-known/agent-skills/index.json
- developer_docs: https://swap.thorchain.org/developers/quickstart, https://swap.thorchain.org/developers/api, https://swap.thorchain.org/developers/mcp, https://swap.thorchain.org/developers/auth, https://swap.thorchain.org/developers/sdks, https://swap.thorchain.org/developers/webhooks
- source: https://github.com/thorchain/swap.thorchain
