MCP-ODOS
MCP-ODOS: 分散型取引所向けモデルコンテキストプロトコルサーバー
このプロジェクトは、分散型取引所(DEX)と連携するためのモデルコンテキストプロトコル(MCP)サーバーを実装します。MCP対応クライアント(AIアシスタント、IDE拡張機能、カスタムアプリケーションなど)が、スワップの見積もり取得やスワップ実行などの機能にアクセスできるようになります。
このサーバーは TypeScript とfastmcpを使用して構築されています。
機能(MCPツール)
サーバーは、MCP クライアントが利用できる次のツールを公開します。
ODOS_GET_QUOTE: スワップの見積もりを取得します。パラメータ:
chainId(数値)、sellToken(文字列)、buyToken(文字列)、sellAmount(文字列)
ODOS_EXECUTE_SWAP: スワップを実行します。パラメータ:
chainId(数値)、sellToken(文字列)、buyToken(文字列)、sellAmount(文字列)、quote(文字列)、walletProvider(文字列)
パラメータの内訳
chainId: DEX のチェーン ID。sellToken: 販売したいトークン。buyToken: 購入したいトークン。sellAmount: 販売したいトークンの量。quote:get-quoteサービスから取得した見積もり。walletProvider: 使用するウォレットプロバイダー。
Related MCP server: CCXT MCP Server
前提条件
Node.js (v18以降を推奨)
pnpm ( https://pnpm.io/installationを参照)
インストール
mcp-odosを使用するにはいくつかの方法があります。
1. pnpm dlxを使用する (ほとんどの MCP クライアント設定に推奨):
pnpm dlxを使えば、グローバルインストールを必要とせずにサーバーを直接実行できます。これは、MCPクライアントと統合する最も簡単な方法です。例については、「MCPクライアントでサーバーを実行する」セクションをご覧ください。( pnpm dlxは、pnpmにおけるnpxに相当します)
2. npm からのグローバルインストール (pnpm 経由):
mcp-odosコマンドをシステム全体で使用できるようにするには、パッケージをグローバルにインストールします。
pnpm add -g mcp-odos3. ソースからのビルド (開発またはカスタム変更用):
リポジトリをクローンします。
git clone https://github.com/IQAIcom/mcp-odos.git cd mcp-odos依存関係をインストールします:
pnpm install**サーバーをビルドします。**これにより、TypeScript コードが
distディレクトリ内の JavaScript にコンパイルされます。pnpm run buildprepareスクリプトはpnpm run buildも実行するため、クローンを作成してpnpm installを実行すると、インストール時に依存関係が構築されます。
設定(環境変数)
このMCPサーバーは、それを実行するMCPクライアントによって特定の環境変数の設定を必要とする場合があります。これらの環境変数は通常、クライアントのMCPサーバー定義(例えば、Cursorの場合はmcp.jsonファイル、その他のクライアントの場合は同様のファイル)で設定されます。
ウォレットプロバイダーまたは API キーに必要な環境変数。
MCPクライアントでサーバーを実行する
MCPクライアント(AIアシスタント、IDE拡張機能など)は、このサーバーをバックグラウンドプロセスとして実行します。クライアント側でサーバーの起動方法を設定する必要があります。
以下は、MCPクライアントが使用できる設定スニペットの例です(例: mcp_servers.jsonまたは同様の設定ファイル)。この例では、公開されているnpmパッケージをpnpm dlx経由で使用してサーバーを実行する方法を示しています。
{
"mcpServers": {
"iq-odos-mcp-server": {
"command": "pnpm",
"args": ["dlx", "mcp-odos"],
"env": {
"WALLET_PRIVATE_KEY": "your_wallet_private_key_here"
}
}
}
}グローバルにインストールされている場合の代替手段:
mcp-odosグローバルにインストールした場合 ( pnpm add -g mcp-odos )、 commandとargsを簡素化できます。
{
"mcpServers": {
"iq-odos-mcp-server": {
"command": "mcp-odos",
"args": [],
"env": {
"WALLET_PRIVATE_KEY": "your_wallet_private_key_here"
}
}
}
}command: 実行する実行可能ファイル。pnpm dlxの場合:"pnpm"(最初の引数として"dlx"を使用)グローバルインストールの場合:
"mcp-odos"
args: コマンドに渡す引数の配列。pnpm dlxの場合:["dlx", "mcp-odos"]グローバルインストールの場合:
[]
env: サーバープロセスの起動時に設定される環境変数を含むオブジェクト。必要な環境変数はここに指定します。workingDirectory:pnpm dlxまたはグローバルインストール経由で公開されたパッケージを使用する場合は、パッケージが自身のパスを正しく処理するため、通常は必要ありません。ソースコード (node dist/index.js) から実行する場合は、workingDirectoryプロジェクトルートに設定することが重要になります。
Available Tools
3 toolsODOS_GET_CHAIN_IDA
Get the chain ID for a given chain name
Inputs: chain (required).
ODOS_GET_QUOTEB
Get a quote for a swap or exchange operation
Inputs: fromToken (required), toToken (required), amount (required), chain, +1 more.
ODOS_SWAPC
Execute a swap transaction
Inputs: fromToken (required), toToken (required), amount (required), chain, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool targets a distinct step in the swap process: chain ID lookup, quote retrieval, and execution. No ambiguity or overlap exists.
All tools use a consistent ODOS_ prefix followed by clear verb_noun patterns (GET_CHAIN_ID, GET_QUOTE, SWAP), making them predictable.
With 3 tools, the server is well-scoped for the core swap workflow without unnecessary bloat or deficiency.
The tools cover the essential swap steps but lack a token approval tool, which is commonly required for many swaps, creating a potential gap.
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Multi-aggregator swap router for AI agents on Base. 10 bps fee. MCP-native, non-custodial.
A Model Context Protocol server for Wix AI tools
The Mercado Pago MCP Server implements the Model Context Protocol to provide AI agents and LLMs with access to Mercado Pago's APIs and tools within compatible development environments. It acts as an intermediary that translates Mercado Pago resources into executable functions (tools) that AI applications can invoke to perform actions and automate flows. The server simplifies integration, enables using documentation to implement or improve code, and optimizes operations through natural language interactions without manual implementations.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol server enabling AI agents to interact with the Solana blockchain for DeFi operations like checking balances, transferring tokens, executing swaps, and fetching price data.47 npm21MIT
- AlicenseBqualityDmaintenanceA server that allows AI models to interact with cryptocurrency exchange APIs through the Model Context Protocol, providing access to over 100 exchanges and their trading capabilities.20149 npm95MIT
- FlicenseAqualityDmaintenanceA Model Context Protocol server that enables AI agents to autonomously execute cross-chain trading operations on Paloma DEX across seven EVM chains including Ethereum, Arbitrum, and Polygon.21-
- AlicenseNot gradedqualityNot gradedmaintenanceA comprehensive Model Context Protocol server that enables AI agents to interact with BNB Chain, opBNB, and other EVM networks through natural language. It provides tools for DeFi trading, DEX swaps, smart contract deployment, token operations, security analysis, and market data across multiple blockchain networks.41 npm-