Skip to main content
Glama

Solana MCP Server

Solana MCP 服务器

MCP 服务器使用您自己的私钥与 Solana 区块链进行交互。

📖 目录

✨ 特点

  • 获取最新插槽
  • 获取钱包地址
  • 获取钱包余额
  • 转移SOL

⚙️ 设置

通过 Smithery 安装

要通过Smithery自动为 Claude Desktop 安装 Solana MCP:

npx -y @smithery/cli install @Grandbusta/solana-mcp --client claude

手动设置

  1. 克隆存储库
git clone https://github.com/Grandbusta/solana-mcp.git
  1. 安装依赖项
npm install
  1. 构建项目
npm run build
  1. 创建密钥对文件 在任何位置创建一个名为keypair.json的文件,并将你的私钥复制到其中。查看 example-keypair.json 文件以获取示例。

注意:RPC 端点默认设置为api.devnet.solana.com 。如果您想使用其他端点,可以在run.sh文件中进行设置。

与 Cursor 集成

要与 Cursor 集成,请按照以下步骤操作:

  1. 在光标设置中,转到 MCP
  2. 点击“添加新的 MCP 服务器”
  3. 输入以下信息:
    • 名称: Solana MCP
    • 类型:命令
    • 命令: /path/to/your/solana-mcp/run.sh /path/to/your/keypair.json

示例命令: /Users/username/projects/solana-mcp/run.sh /Users/username/Documents/keypair.json

🛠️ 可用工具

1. 获取最新槽

返回最新的插槽号:

368202671

2. 获取钱包地址

返回钱包地址:

5GTuMBag1M8tfe736kcV1vcAE734Zf1SRta8pmWf82TJ

3. 获取钱包余额

返回 SOL、Lamports 和 USD 的钱包余额:

{ "lamportsBalance": "4179966000", "solanaBalnce": 4.179966, "usdBalance": "553.0513" }

4. 转让

将 SOL 转移到收件人地址:

{ "blockTime": "1742316463", "meta": { "computeUnitsConsumed": "150", "err": null, "fee": "5000", "innerInstructions": [], "loadedAddresses": { "readonly": [], "writable": [] }, "logMessages": [ "Program 11111111111111111111111111111111 invoke [1]", "Program 11111111111111111111111111111111 success" ], "postBalances": [ "4179966000", "819999000", "1" ], "postTokenBalances": [], "preBalances": [ "4399970000", "600000000", "1" ], "preTokenBalances": [], "rewards": [], "status": { "Ok": null } }, "slot": "368211978", "transaction": { "message": { "accountKeys": [ "6qhddtBoEHqTc3VM35a3rb3aLUe6vDQfmLigo2G4r5s1", "5GTuMBag1M8tfe736kcV1vcAE734Zf1SRta8pmWf82TJ", "11111111111111111111111111111111" ], "addressTableLookups": [], "header": { "numReadonlySignedAccounts": 0, "numReadonlyUnsignedAccounts": 1, "numRequiredSignatures": 1 }, "instructions": [ { "accounts": [ 0, 1 ], "data": "3Bxs452Q9hdvHuwd", "programIdIndex": 2, "stackHeight": null } ], "recentBlockhash": "BLqtPS9BHPp9CRFTrVAsrxFMWC98VTUAQ3vi12bSquLo" }, "signatures": [ "3bLyqbPn26ofkaxSAVqadQnHqXu9hyoryixmKCn69nunKg2cSryDVAWnfCcYPcGtjSmXcMHfrzc3bw25zFTabXvs" ] }, "version": "0" }

🧑‍💻 贡献

欢迎贡献!请打开一个问题或提交一个拉取请求。

🔖 许可证

WTFPL许可证

-
security - not tested
F
license - not found
-
quality - not tested

local-only server

The server can only run on the client's local machine because it depends on local resources.

一个使用您自己的私钥与 Solana 区块链进行交互的服务器,支持获取钱包信息、检查余额和转移 SOL 等操作。

  1. 📖 目录
    1. ✨ 特点
      1. ⚙️ 设置
        1. 通过 Smithery 安装
        2. 手动设置
      2. 与 Cursor 集成
        1. 🛠️ 可用工具
          1. 获取最新槽
          2. 获取钱包地址
          3. 获取钱包余额
          4. 转让
        2. 🧑‍💻 贡献
          1. 🔖 许可证

            Related MCP Servers

            • -
              security
              A
              license
              -
              quality
              A Model-Context-Protocol server enabling users to perform basic operations on Solana and Ethereum blockchains through simple RPC endpoints.
              Last updated -
              10
              51
              TypeScript
              Apache 2.0
            • -
              security
              A
              license
              -
              quality
              A server that enables interaction with the Solana blockchain, providing access to over 40 Solana RPC methods including getting balances, transaction details, block information, and sending transactions.
              Last updated -
              Python
              MIT License
              • Apple
            • A
              security
              F
              license
              A
              quality
              A server that provides simple RPC endpoints for common Solana blockchain operations, allowing users to check balances, get account information, and transfer SOL between accounts.
              Last updated -
              5
              TypeScript
            • -
              security
              A
              license
              -
              quality
              A Model Context Protocol server that enables Claude AI to interact with the Solana blockchain through a standardized interface, providing tools for transactions, account queries, and wallet management.
              Last updated -
              219
              79
              Apache 2.0
              • Linux
              • Apple

            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/Grandbusta/solana-mcp'

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