CoW Protocol MCP Server
by saturn-dbeal
README.md
# CoW Protocol MCP Server
An MCP (Model Context Protocol) server for interacting with CoW Protocol's order book API.
## Features
### Token Tools
- **cow_resolve_token** - Look up token address by symbol (uses official CoW Swap token list)
- **cow_search_tokens** - Search for tokens by name/symbol across networks
### Order Tools
- **cow_get_quote** - Get price and fee quotes for trades (accepts symbols OR addresses)
- **cow_get_order** - Get full order details by UID
- **cow_get_order_status** - Check order status (open, filled, cancelled, expired)
- **cow_get_trades** - Fetch trade history for an address or order
- **cow_get_auction** - View current auction batch information
## Token Resolution
The server uses the official [CoW Protocol token list](https://github.com/cowprotocol/token-lists) for symbol resolution. This is the same list used by CoW Swap.
Example: Instead of providing the full address for USDC or COW, you can just use the symbol:
```
sellToken: "WETH"
buyToken: "COW"
```
And it will automatically resolve to the correct address for the specified network.
## Supported Networks
- mainnet (Ethereum)
- gnosis (Gnosis Chain)
- arbitrum (Arbitrum One)
- base (Base)
- avalanche (Avalanche)
- polygon (Polygon)
- bnb (BNB Chain)
- sepolia (Sepolia testnet)
## Installation
```bash
npm install
npm run build
```
## Usage
### With Claude Desktop
Add to your Claude Desktop config:
```json
{
"mcpServers": {
"cow": {
"command": "node",
"args": ["/path/to/cow-mcp-server/dist/index.js"]
}
}
}
```
### With OpenClaw
Add to your OpenClaw MCP servers configuration.
### Testing with MCP Inspector
```bash
npx @modelcontextprotocol/inspector node dist/index.js
```
## Development
```bash
# Watch mode
npm run dev
# Build
npm run build
# Clean
npm run clean
```
## API Reference
### cow_get_quote
Get a quote for a potential trade:
```json
{
"network": "mainnet",
"sellToken": "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2",
"buyToken": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
"kind": "sell",
"amount": "1000000000000000000",
"from": "0xYourAddress"
}
```
### cow_get_order_status
Check an order's status:
```json
{
"network": "mainnet",
"orderUid": "0x..."
}
```
### cow_get_trades
Get trade history:
```json
{
"network": "mainnet",
"owner": "0xYourAddress",
"limit": 20
}
```
## License
MIT
TDQS
A4.2/5.0
Scored across 8 tools
Disambiguation5/5
Each tool targets a distinct aspect of CoW Protocol: auction state, order details, order status, quote, trades, order preparation, token resolution, and token search. No overlapping functionality.
Naming Consistency5/5
All tools follow a consistent 'cow_verb_noun' pattern with snake_case. Examples: cow_get_auction, cow_prepare_order, cow_search_tokens.
Tool Count5/5
8 tools is well-scoped for a protocol-specific server. They cover key operations without being excessive or minimal.
Completeness3/5
Covers core query and preparation operations but lacks direct submission of orders, cancellation, and listing of all orders for a user. Agents must rely on external curl commands for submission.
Maintenance
ActivityInactive
ResponsivenessNo issues