Solana Agent Kit MCP Server

Apache 2.0
60
69
  • Linux
  • Apple

Integrations

  • Enables interaction with the Solana blockchain, including retrieving asset information, deploying tokens, checking balances, transferring tokens, minting NFTs, executing trades, and resolving domain names.

Solana Agent Kit MCP Server

A Model Context Protocol (MCP) server that provides onchain tools for Claude AI, allowing it to interact with the Solana blockchain through a standardized interface. This implementation is based on the Solana Agent Kit and enables AI agents to perform blockchain operations seamlessly.

Overview

This MCP server extends Claude's capabilities by providing tools to:

  • Interact with Solana blockchain
  • Execute transactions
  • Query account information
  • Manage Solana wallets

The server implements the Model Context Protocol specification to standardize blockchain interactions for AI agents.

Prerequisites

  • Node.js (v16 or higher)
  • pnpm (recommended), npm, or yarn
  • Solana wallet with private key
  • Solana RPC URL (mainnet, testnet, or devnet)

Installation

# Download the installation script curl -fsSL https://raw.githubusercontent.com/sendaifun/solana-mcp/main/scripts/install.sh -o solana-mcp-install.sh # Make it executable and run chmod +x solana-mcp-install.sh && ./solana-mcp-install.sh --backup

This will start an interactive installation process that will guide you through:

  • Setting up Node.js if needed
  • Configuring your Solana RPC URL and private key
  • Setting up the Claude Desktop integration

Option 2: Install from npm ( recommend for clients like Cursor/Cline)

# Install globally npm install -g solana-mcp # Or install locally in your project npm install solana-mcp

Option 3: Build from Source

  1. Clone this repository:
git clone https://github.com/sendaifun/solana-mcp cd solana-mcp
  1. Install dependencies:
pnpm install
  1. Build the project:
pnpm run build

Configuration

Environment Setup

Create a .env file with your credentials:

# Solana Configuration SOLANA_PRIVATE_KEY=your_private_key_here RPC_URL=your_solana_rpc_url_here OPENAI_API_KEY=your_openai_api_key # OPTIONAL

Integration with Claude Desktop

To add this MCP server to Claude Desktop, follow these steps:

  1. Locate the Claude Desktop Configuration File
    • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: %APPDATA%\Claude\claude_desktop_config.json
    • Linux: ~/.config/Claude/claude_desktop_config.json
  2. Add the Configuration Create or edit the configuration file and add the following JSON:If you installed via npm (Option 1):
    { "mcpServers": { "solana-mcp": { "command": "npx", "args": ["solana-mcp"], "env": { "RPC_URL": "your_solana_rpc_url_here", "SOLANA_PRIVATE_KEY": "your_private_key_here", "OPENAI_API_KEY": "your_openai_api_key" // OPTIONAL }, "disabled": false, "autoApprove": [] } } }
    If you built from source (Option 2):
    { "mcpServers": { "solana-mcp": { "command": "node", "args": ["/path/to/solana-mcp/build/index.js"], "env": { "RPC_URL": "your_solana_rpc_url_here", "SOLANA_PRIVATE_KEY": "your_private_key_here", "OPENAI_API_KEY": "your_openai_api_key" // OPTIONAL }, "disabled": false, "autoApprove": [] } } }
  3. Restart Claude Desktop After making these changes, restart Claude Desktop for the configuration to take effect.

Project Structure

solana-agent-kit-mcp/ ├── src/ │ ├── index.ts # Main entry point ├── package.json └── tsconfig.json

Available Tools

The MCP server provides the following Solana blockchain tools:

  • GET_ASSET - Retrieve information about a Solana asset/token
  • DEPLOY_TOKEN - Deploy a new token on Solana
  • GET_PRICE - Fetch price information for tokens
  • WALLET_ADDRESS - Get the wallet address
  • BALANCE - Check wallet balance
  • TRANSFER - Transfer tokens between wallets
  • MINT_NFT - Create and mint new NFTs
  • TRADE - Execute token trades
  • REQUEST_FUNDS - Request funds (useful for testing/development)
  • RESOLVE_DOMAIN - Resolve Solana domain names
  • GET_TPS - Get current transactions per second on Solana

Security Considerations

  • Keep your private key secure and never share it
  • Use environment variables for sensitive information
  • Consider using a dedicated wallet for AI agent operations
  • Regularly monitor and audit AI agent activities
  • Test operations on devnet/testnet before mainnet

Troubleshooting

If you encounter issues:

  1. Verify your Solana private key is correct
  2. Check your RPC URL is accessible
  3. Ensure you're on the intended network (mainnet, testnet, or devnet)
  4. Check Claude Desktop logs for error messages
  5. Verify the build was successful

Dependencies

Key dependencies include:

Contributing

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

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the MIT License.

-
security - not tested
A
license - permissive license
-
quality - not tested

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.

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.

  1. Overview
    1. Prerequisites
      1. Installation
        1. Option 1: Quick Install (Recommended)
        2. Option 2: Install from npm ( recommend for clients like Cursor/Cline)
        3. Option 3: Build from Source
      2. Configuration
        1. Environment Setup
        2. Integration with Claude Desktop
      3. Project Structure
        1. Available Tools
          1. Security Considerations
            1. Troubleshooting
              1. Dependencies
                1. Contributing
                  1. License

                    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 Model Context Protocol server that provides Claude with comprehensive access to Solana blockchain data via the Helius API, enabling operations like checking wallet balances, retrieving blockchain information, and interacting with tokens and NFTs.
                      Last updated -
                      119
                      8
                      TypeScript
                      MIT License
                      • Apple
                      • Linux
                    • -
                      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 -
                      60
                      15
                      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 -
                      TypeScript
                      MIT License

                    View all related MCP servers

                    ID: 6yukeoy0bb