Skip to main content
Glama

Base Network MCP Server

by fakepixels

ベースネットワークMCPサーバー

これはBaseネットワーク用のMCPサーバーです。LLMは、ウォレット管理、残高確認、トランザクション実行など、自然言語コマンドを通じてBaseネットワーク上でブロックチェーン操作を実行できます。

このサーバーは、Base Mainnet と Base Sepolia テストネットの両方で動作します。

ツール

利用可能なツールは次のとおりです。

プロセスコマンド

ベースネットワーク操作のための自然言語コマンドを処理します。以下の引数を受け入れます。

  • command : 処理する自然言語コマンド(例:「0.5 ETHを0x1234に送信...」)

送信操作のトランザクションの詳細、残高チェックの残高情報、ウォレット作成のウォレットの詳細など、操作の結果を含む構造化された応答を返します。

ウォレットを作成する

ベースネットワーク上に新しいウォレットを作成します。以下の引数を受け入れます。

  • name : (オプション) ウォレットの名前

ウォレットのアドレス、名前、その他の詳細を含むオブジェクトを返します。

残高確認

Baseネットワーク上のウォレットの残高を確認します。以下の引数を受け入れます。

  • wallet : (オプション) 確認するウォレット名またはアドレス (デフォルトはプライマリウォレット)

ウォレットの残高を ETH で返します。

ウォレット一覧

利用可能なすべてのウォレットを一覧表示します。

ウォレット オブジェクトの配列を返します。各オブジェクトにはウォレット アドレス、名前、その他の詳細が含まれます。

使用法

クロード・デスクトップ

Claude Desktopは、モデルコンテキストプロトコル(MCP)をサポートする人気のLLMクライアントです。Base MCPサーバーをClaude Desktopに接続することで、自然言語コマンドでブロックチェーン操作を実行できます。

次の設定ファイルを使用して、Claude Desktop に MCP サーバーを追加できます。

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Base MCP サーバーを Claude Desktop に追加するには、構成ファイルのmcpServersオブジェクトに次の構成を追加します。

{ "mcpServers": { "base": { "command": "npx", "args": [ "-y", "base-network-mcp-server" ], "env": { "BASE_PROVIDER_URL": "https://api.developer.coinbase.com/rpc/v1/base/YOUR_API_KEY", "WALLET_PRIVATE_KEY": "your_private_key_here" }, "disabled": false, "autoApprove": [] } } }

構成

  • BASE_PROVIDER_URL : ベースネットワークプロバイダー(メインネットまたはセポリア)のURL
  • WALLET_PRIVATE_KEY : 認証とトランザクション署名用のウォレット秘密鍵
  • DEFAULT_GAS_PRICE : (オプション) Gweiのデフォルトのガス価格

プログラムで(カスタム MCP クライアント)

独自のMCPクライアントを構築する場合は、お好みのトランスポートを使用してプログラム的にBase MCPサーバーに接続できます。MCP SDKには、組み込みのstdioおよびSSEトランスポートが用意されています。

インストール

npm i base-network-mcp-server # or yarn add base-network-mcp-server # or pnpm add base-network-mcp-server

次の例では、StreamTransport を使用して MCP クライアントとサーバー間を直接接続します。

import { Client } from '@modelcontextprotocol/sdk/client/index.js'; import { StreamTransport } from '@modelcontextprotocol/sdk/client/stream.js'; import { BaseMcpServer } from 'base-network-mcp-server'; // Create a stream transport for both client and server const clientTransport = new StreamTransport(); const serverTransport = new StreamTransport(); // Connect the streams together clientTransport.readable.pipeTo(serverTransport.writable); serverTransport.readable.pipeTo(clientTransport.writable); const client = new Client( { name: 'MyClient', version: '0.1.0', }, { capabilities: {}, } ); // Create and configure the Base MCP server const server = new BaseMcpServer({ providerUrl: 'https://api.developer.coinbase.com/rpc/v1/base/YOUR_API_KEY', privateKey: 'your_private_key_here', }); // Connect the client and server to their respective transports await server.connect(serverTransport); await client.connect(clientTransport); // Call tools const output = await client.callTool({ name: 'process_command', arguments: { command: 'Check my wallet balance', }, }); console.log(output); // Example output: // { // "success": true, // "message": "Balance of wallet \"default\": 1.5 ETH", // "balance": "1.5", // "wallet": "default" // }

コマンド例

統合されると、次のような自然言語コマンドを使用できるようになります。

  • 「貯蓄用の新しいウォレットを作成する」
  • 「ウォレットの残高を確認してください」
  • 「私の貯金箱の残高はいくらですか?」
  • 「0.1 ETHを0x1234567890123456789012345678901234567890に送信」
  • 「貯蓄ウォレットから 0.5 ETH を 0xABCD に転送します...」

セキュリティに関する考慮事項

この実装は実際のブロックチェーン ネットワークと対話し、秘密鍵を処理するため、

  1. 秘密鍵のセキュリティ: 秘密鍵を安全に保管し、バージョン管理にコミットしないでください。
  2. まずはテストネットを使用する: メインネットに移行する前に、ベースとなる Sepolia テストネットから始める
  3. トランザクション検証: 送信前に必ずトランザクションパラメータを検証します
  4. エラー処理: ネットワークの問題に対する堅牢なエラー処理を実装する
  5. レート制限: 頻繁にリクエストを行う場合は、API レート制限に注意してください。

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

ウォレット管理、残高チェック、トランザクション実行などの自然言語コマンドを通じて、LLM がベース ネットワーク上でブロックチェーン操作を実行できるようにする MCP サーバー。

  1. ツール
    1. プロセスコマンド
    2. ウォレットを作成する
    3. 残高確認
    4. ウォレット一覧
  2. 使用法
    1. クロード・デスクトップ
    2. 構成
    3. プログラムで(カスタム MCP クライアント)
  3. インストール
      1. コマンド例
        1. セキュリティに関する考慮事項

          Related MCP Servers

          • -
            security
            A
            license
            -
            quality
            An MCP server that integrates with MySQL databases, enabling secure read and write operations through LLM-driven interfaces with support for transaction handling and performance monitoring.
            Last updated -
            48
            3
            JavaScript
            MIT License
          • A
            security
            A
            license
            A
            quality
            An MCP server that enables secure terminal command execution, directory navigation, and file system operations through a standardized interface for LLMs.
            Last updated -
            10
            23
            Python
            MIT License
            • Apple
          • A
            security
            F
            license
            A
            quality
            An MCP server that fetches on-chain blockchain data via the Ankr API, allowing LLMs to retrieve token balances for wallet addresses on specific networks.
            Last updated -
            1
            56
            1
            TypeScript
          • -
            security
            -
            license
            -
            quality
            A suite of MCP servers that allow LLMs to interact with blockchains through MetaMask wallet without exposing private keys, facilitating secure AI-powered blockchain interactions and simplified user onboarding.
            Last updated -
            1
            TypeScript

          View all related MCP servers

          MCP directory API

          We provide all the information about MCP servers via our MCP API.

          curl -X GET 'https://glama.ai/api/mcp/v1/servers/fakepixels/base-mcp-server'

          If you have feedback or need assistance with the MCP directory API, please join our Discord server