Interacting with the Uniswap API in Rust
Config is the same across clients — only the file and path differ.
{
"mcpServers": {
"uniswap": {
"env": {
"UNISWAP_API_KEY": "your_key_here"
},
"command": "/absolute/path/to/uniswap-api-rust/target/release/uniswap-mcp-server-rust"
}
}
}Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
An MCP (Model Context Protocol) server in Rust that exposes Uniswap Trade API quotes as a tool for AI clients. Built with the official Rust SDK RMCP (rmcp on crates.io).
No automated test available for this server. Check the GitHub README for setup instructions.
Five weighted categories — click any category to see the underlying evidence.
No known CVEs.
No package registry to scan.
Click any tool to inspect its schema.
Be the first to review
Have you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Others in finance
Real-time financial market data: stocks, forex, crypto, commodities, and economic indicators
A Model Context Protocol server for building an investor agent
AI agents get on-chain identity, credentials, reputation, escrow, and persistent memory on XRPL.
Remote MCP server to integrate and validate self-hosted PayRam deployments.
MCP Security Weekly
Get CVE alerts and security updates for Uniswap Mcp Server Rust and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.

An MCP (Model Context Protocol) server in Rust that exposes Uniswap Trade API quotes as a tool for AI clients. Built with the official Rust SDK RMCP (rmcp on crates.io).
cargo, rustc)UNISWAP_API_KEY (see Uniswap docs)Create a .env file next to Cargo.toml (or export the variable in your shell):
UNISWAP_API_KEY=your_key_here
The server loads .env at startup using the crate manifest directory, so it works when MCP hosts run the binary from another working directory.
cargo build --release
rmcp with server + transport-io.uniswap_swap_quote — calls POST https://trade-api.gateway.uniswap.org/v1/quote with your API key and returns the JSON quote (pretty-printed text). Use token_in_preset to pick the asset you sell on Ethereum mainnet without typing addresses: native_eth, usdc, usdt, wbtc, dai, weth. If you set a preset, it overrides token_in; otherwise pass a full token_in address.Async runtime: Tokio (required by RMCP and reqwest).
Point your MCP host at the compiled binary. Example for Cursor (.cursor/mcp.json or global MCP settings):
{
"mcpServers": {
"uniswap": {
"command": "/absolute/path/to/uniswap-api-rust/target/release/uniswap-mcp-server-rust",
"env": {
"UNISWAP_API_KEY": "your_key_here"
}
}
}
}
You can omit env if UNISWAP_API_KEY is already in the environment.
To debug with the official inspector (see RMCP examples):
npx @modelcontextprotocol/inspector /absolute/path/to/target/debug/uniswap-mcp-server-rust
Run the commands from the previous section and open the MCP Inspector in your browser.
"tokenIn": "0x0000000000000000000000000000000000000000", // ETH
"tokenOut": "0xdAC17F958D2ee523a2206206994597C13D831ec7", // USDT
"tokenInChainId": 1,
"tokenOutChainId": 1,
"type": "EXACT_INPUT",
"amount": "1000000000000000000", // 1 ETH in wei
"swapper": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045", // User's wallet address (vitalik.eth)
start, stop, unicorns)See LICENSE in the repository.