Skip to main content
Glama

Solana Vault MCP

by olaxbt

Solana Vault MCP

A Model Context Protocol (MCP) implementation for secure Solana blockchain wallet operations in python.

Overview

Solana Vault MCP provides secure wallet operations for Solana blockchain through a standardized Model Context Protocol interface. It allows AI assistants to securely interact with the Solana blockchain without direct access to private keys.

Features

  • Secure Solana wallet operations
  • SOL balance checking
  • SOL transfer capabilities
  • Transaction history retrieval
  • Model Context Protocol compliant API
  • Support for Flask web server and WebSocket connections
  • Detailed logging and error handling

Installation

Prerequisites

  • Python 3.9+
  • pip

Setup

  1. Clone the repository:
    git clone https://github.com/olaxbt/solana-vault-mcp.git cd solana-vault-mcp
  2. Create and activate a virtual environment:
    python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
  3. Install dependencies:
    pip install -r requirements.txt
  4. Create a .env file based on .env.example:
    cp .env.example .env
  5. Edit the .env file to add your Solana private key and RPC URL.

Usage

Starting the Server

python run.py

The server will start on the port specified in your .env file (default: 5000).

API Endpoints

  • GET / - Welcome page with service information
  • GET /health - Health check endpoint
  • GET /api/mcp/ping - MCP service health check
  • POST /api/mcp/query - Main MCP query endpoint

MCP Actions

The Solana Vault MCP supports the following actions:

  1. wallet.info - Get wallet information
  2. wallet.balance - Get SOL balance
  3. wallet.transfer - Transfer SOL to another wallet
  4. wallet.transactions - Get recent transactions
  5. wallet.token_balance - Get token balance for a specific token

Example Query

{ "id": "request123", "action": "wallet.balance", "params": {} }

Response:

{ "id": "request123", "result": { "balance": 1.5, "currency": "SOL", "address": "YourSolanaPublicKey" } }

Development

Project Structure

solana-vault-mcp/ ├── app/ │ ├── handlers/ # Action handlers │ ├── routes/ # API routes │ ├── services/ # Core services │ └── utils/ # Utilities ├── logs/ # Log files ├── tests/ # Test cases ├── .env # Environment variables ├── .env.example # Example environment file ├── requirements.txt # Dependencies ├── run.py # Main entry point └── README.md # Documentation

Running Tests

pytest

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

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

hybrid server

The server is able to function both locally and remotely, depending on the configuration or use case.

安全的模型上下文协议服务器,使 AI 助手无需直接访问私钥即可与 Solana 区块链交互,支持余额检查、SOL 转账和交易历史记录检索等操作。

  1. 概述
    1. 特征
      1. 安装
        1. 先决条件
        2. 设置
      2. 用法
        1. 启动服务器
        2. API 端点
        3. MCP 操作
        4. 示例查询
      3. 发展
        1. 项目结构
        2. 运行测试
      4. 执照
        1. 贡献

          Related MCP Servers

          • -
            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 -
            20
            119
            Apache 2.0
            • Linux
            • Apple
          • -
            security
            A
            license
            -
            quality
            A 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.
            Last updated -
            20
            22
            TypeScript
            MIT License
          • -
            security
            A
            license
            -
            quality
            A Model Context Protocol server that enables AI models to interact with the Solana blockchain, providing RPC methods, wallet management, DeFi trading capabilities, and Helius API integration for enhanced Solana development.
            Last updated -
            3
            TypeScript
            MIT License
          • -
            security
            F
            license
            -
            quality
            A Model Context Protocol server that enables Claude AI to interact with the Solana blockchain, allowing it to execute transactions, query accounts, manage wallets, get price predictions, trade tokens, and access various blockchain data sources.
            Last updated -
            3
            • 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/olaxbt/solana-vault-mcp'

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