# Uniswap Api — how to use (mcp.ai)

Connect your Uniswap Api account and use 7 tools for developer tools straight from your AI agent. Connect with your own API key. Uniswap Trading API for executing swaps and managing liquidity across 25+ blockchain networks.

## Option A — via MCP (recommended)
Remote MCP endpoint (HTTP, streamable): `https://api.mcp.ai/p_uniswap_api?ms=1787296020000`
Add it as a custom/remote MCP connector in your client (Claude, Cursor, VS Code…), then authenticate when prompted. Once connected, ask the agent to use the server's tools (e.g. `uniswap_api_check_approval`).

## Option B — via direct REST API
Base URL: `https://api.mcp.ai/api/uniswap_api`
Auth: `Authorization: Bearer sk_live_…` — create a workspace API key at https://mcp.ai/settings/api-keys
Discover endpoints: `GET https://api.mcp.ai/api/uniswap_api/_endpoints`

### Endpoints
- `POST https://api.mcp.ai/api/uniswap_api/check/approval` — Tool to check if a wallet has sufficient token approval for a specified transaction amount. Returns an approval transaction if needed, or null if approval already exists. Use this before executing a s
  - body: { token: string, amount: string, chainId: integer, urgency?: string, tokenOut?: string, walletAddress: string, includeGasInfo?: boolean, tokenOutChainId?: integer }
- `POST https://api.mcp.ai/api/uniswap_api/check/wallet/delegation` — Get the current delegation status and message for a smart contract wallet across different chains. Returns delegation information for each chain ID in the request, including whether the wallet is dele
  - body: { chain_ids: integer[], wallet_addresses: string[] }
- `POST https://api.mcp.ai/api/uniswap_api/encode7702/transactions` — Encode a list of transactions into a single transaction for smart contract wallet execution (EIP-7702). All transactions must have the same chainId. Use when you need to batch multiple transactions in
  - body: { calls: object[], walletAddress: string, smartContractDelegationAddress: string }
- `POST https://api.mcp.ai/api/uniswap_api/get/gasless/orders` — Retrieve one or more gasless orders from Uniswap, optionally filtered by query parameters. Must include at least one of: orderId, orderIds, orderStatus, swapper, or filler. Use when you need to check 
  - body: { sort?: string, limit?: integer, cursor?: string, filler?: string, swapper?: string, order_id?: string, sort_key?: string, order_ids?: string, order_type?: string, order_status?: string }
- `POST https://api.mcp.ai/api/uniswap_api/get/quote` — Requests a quote according to the specified swap parameters. This endpoint may be used to get a quote for a swap, a bridge, or a wrap/unwrap. The resulting response includes a quote for the swap and t
  - body: { type?: string, amount: string, swapper: string, urgency?: string, token_in: string, protocols?: string[], token_out: string, auto_slippage?: string, hooks_options?: string, permit_amount?: string, integrator_fees?: object[], token_in_chain_id?: integer, routing_preference?: string, slippage_tolerance?: number, token_out_chain_id?: integer, spread_optimization?: string, generate_permit_as_transaction?: boolean }
- `POST https://api.mcp.ai/api/uniswap_api/get/swap/status` — Tool to retrieve the current status of swap or bridge transactions on the Uniswap trading platform. Use when you need to check if a swap transaction has been confirmed, is pending, or has failed. Prov
  - body: { chain_id?: integer, tx_hashes: string[] }
- `POST https://api.mcp.ai/api/uniswap_api/get/swappable/tokens` — Returns the list of destination bridge chains for a given token on a given chain. Useful for discovering cross-chain swap/bridge options. Returns tokens that are available for swapping/bridging from t
  - body: { token_in?: string, token_in_chain_id?: integer }

## Example prompts
- "What can I do in Uniswap Api?"
- "Show me a summary of my Uniswap Api account"

## More
- Page: https://mcp.ai/uniswap_api
- Agent spec (llms.txt): https://mcp.ai/uniswap_api/llms.txt
- Postman collection: https://mcp.ai/uniswap_api/postman.json
