Skip to content
Back to search

solana-mcp

A Model Context Protocol server for interacting with the Solana blockchain, powered by the Solana Agent Kit (https://github.com/sendaifun/solana-agent-kit)

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/sendaifun--solana-mcp/badge.svg)](/listings/sendaifun--solana-mcp)

HTML

<a href="/listings/sendaifun--solana-mcp"><img src="/api/listings/sendaifun--solana-mcp/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Option 1: Quick Install (Recommended)

# 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

2. Install dependencies:

pnpm install

3. Build the project:

pnpm run build

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 207 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Solana Agent Kit MCP Server
  2. [![npm version](https://badge.fury.io/js/solana-mcp.svg)](https://www.npmjs.com/package/solana-mcp)
  3. [![License: ISC](https://img.shields.io/badge/License-ISC-blue.svg)](https://opensource.org/licenses/ISC)
  4. <a href="https://cloud.phala.network/features/mcp-hosting/solana-mcp-by-sendai-and-dark" target="_blank" rel="noopener noreferrer" style="display:inline-flex;align-items:center;text-decoration:none;background:#fff;border:1px solid #e5e7eb;border-radius:6px;padding:2px 8px;font-size:16px;font-family:sans-serif;">
  5. <img src="https://raw.githubusercontent.com/Phala-Network/mcp-hosting/refs/heads/main/assets/logs/phala.png" alt="Phala Logo" height="24" style="vertical-align:middle;margin-right:8px;"/>
  6. <span style="color:#222;font-weight:600;">Check on Phala</span>
  7. </a>
  8. 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.
  9. ## Overview
  10. This MCP server extends Claude's capabilities by providing tools to:
  11. * Interact with Solana blockchain
  12. * Execute transactions
  13. * Query account information
  14. * Manage Solana wallets
  15. The server implements the Model Context Protocol specification to standardize blockchain interactions for AI agents.
  16. ## Prerequisites
  17. * Node.js (v16 or higher)
  18. * pnpm (recommended), npm, or yarn
  19. * Solana wallet with private key
  20. * Solana RPC URL (mainnet, testnet, or devnet)
  21. ## Installation
  22. ### Option 1: Quick Install (Recommended)
  23. ```bash
  24. # Download the installation script
  25. curl -fsSL https://raw.githubusercontent.com/sendaifun/solana-mcp/main/scripts/install.sh -o solana-mcp-install.sh
  26. # Make it executable and run
  27. chmod +x solana-mcp-install.sh && ./solana-mcp-install.sh --backup
  28. ```
  29. This will start an interactive installation process that will guide you through:
  30. - Setting up Node.js if needed
  31. - Configuring your Solana RPC URL and private key
  32. - Setting up the Claude Desktop integration
  33. ### Option 2: Install from npm ( recommend for clients like Cursor/Cline)
  34. ```bash
  35. # Install globally
  36. npm install -g solana-mcp
  37. # Or install locally in your project
  38. npm install solana-mcp
  39. ```
  40. ### Option 3: Build from Source
  41. 1. Clone this repository:
  42. ```bash
  43. git clone https://github.com/sendaifun/solana-mcp
  44. cd solana-mcp
  45. ```
  46. 2. Install dependencies:
  47. ```bash
  48. pnpm install
  49. ```
  50. 3. Build the project:
  51. ```bash
  52. pnpm run build
  53. ```
  54. ## Configuration
  55. ### Environment Setup
  56. Create a `.env` file with your credentials:
  57. ```env
  58. # Solana Configuration
  59. SOLANA_PRIVATE_KEY=your_private_key_here
  60. RPC_URL=your_solana_rpc_url_here
  61. OPENAI_API_KEY=your_openai_api_key # OPTIONAL
  62. ```
  63. ### Integration with Claude Desktop
  64. To add this MCP server to Claude Desktop, follow these steps:
  65. 1. **Locate the Claude Desktop Configuration File**
  66. - macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`
  67. - Windows: `%APPDATA%\Claude\claude_desktop_config.json`
  68. - Linux: `~/.config/Claude/claude_desktop_config.json`
  69. 2. **Add the Configuration**
  70. Create or edit the configuration file and add the following JSON:
  71. If you installed via npm (Option 1):
  72. ```json
  73. {
  74. "mcpServers": {
  75. "solana-mcp": {
  76. "command": "npx",
  77. "args": ["solana-mcp"],
  78. "env": {
  79. "RPC_URL": "your_solana_rpc_url_here",
  80. "SOLANA_PRIVATE_KEY": "your_private_key_here",
  81. "OPENAI_API_KEY": "your_openai_api_key" // OPTIONAL
  82. },
  83. "disabled": false,
  84. "autoApprove": []
  85. }
  86. }
  87. }
  88. ```
  89. If you built from source (Option 2):
  90. ```json
  91. {
  92. "mcpServers": {
  93. "solana-mcp": {
  94. "command": "node",
  95. "args": ["/path/to/solana-mcp/build/index.js"],
  96. "env": {
  97. "RPC_URL": "your_solana_rpc_url_here",
  98. "SOLANA_PRIVATE_KEY": "your_private_key_here",
  99. "OPENAI_API_KEY": "your_openai_api_key" // OPTIONAL
  100. },
  101. "disabled": false,
  102. "autoApprove": []
  103. }
  104. }
  105. }
  106. ```
  107. 3. **Restart Claude Desktop**
  108. After making these changes, restart Claude Desktop for the configuration to take effect.
  109. ## Project Structure
  110. ```
  111. solana-agent-kit-mcp/
  112. ├── src/
  113. │ ├── index.ts # Main entry point
  114. ├── package.json
  115. └── tsconfig.json
  116. ```
  117. ## Available Tools
  118. The MCP server provides the following Solana blockchain tools:
  119. * `GET_ASSET` - Retrieve information about a Solana asset/token
  120. * `DEPLOY_TOKEN` - Deploy a new token on Solana
  121. * `GET_PRICE` - Fetch price information for tokens
  122. * `WALLET_ADDRESS` - Get the wallet address
  123. * `BALANCE` - Check wallet balance
  124. * `TRANSFER` - Transfer tokens between wallets
  125. * `MINT_NFT` - Create and mint new NFTs
  126. * `TRADE` - Execute token trades
  127. * `REQUEST_FUNDS` - Request funds (useful for testing/development)
  128. * `RESOLVE_DOMAIN` - Resolve Solana domain names
  129. * `GET_TPS` - Get current transactions per second on Solana
  130. ## Security Considerations
  131. * Keep your private key secure and never share it
  132. * Use environment variables for sensitive information
  133. * Consider using a dedicated wallet for AI agent operations
  134. * Regularly monitor and audit AI agent activities
  135. * Test operations on devnet/testnet before mainnet
  136. ## Troubleshooting
  137. If you encounter issues:
  138. 1. Verify your Solana private key is correct
  139. 2. Check your RPC URL is accessible
  140. 3. Ensure you're on the intended network (mainnet, testnet, or devnet)
  141. 4. Check Claude Desktop logs for error messages
  142. 5. Verify the build was successful
  143. ## Dependencies
  144. Key dependencies include:
  145. * [@solana/web3.js](https://github.com/solana-labs/solana-web3.js)
  146. * [@modelcontextprotocol/sdk](https://github.com/modelcontextprotocol/typescript-sdk)
  147. * [solana-agent-kit](https://github.com/sendaifun/solana-agent-kit)
  148. ## Contributing
  149. Contributions are welcome! Please feel free to submit a Pull Request.
  150. 1. Fork the repository
  151. 2. Create your feature branch (`git checkout -b feature/amazing-feature`)
  152. 3. Commit your changes (`git commit -m 'Add some amazing feature'`)
  153. 4. Push to the branch (`git push origin feature/amazing-feature`)
  154. 5. Open a Pull Request
  155. ## License
  156. This project is licensed under the MIT License.

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.