Integrations
Provides tools for creating, buying, and selling tokens on the Pump.fun platform on the Solana blockchain, with account management capabilities and balance checking
pumpfun-mcp
A Model Context Protocol (MCP) server for interacting with the Pump.fun platform on Solana. This server enables AI assistants to create, buy, and sell tokens on the Pump.fun platform.
Usage
https://github.com/user-attachments/assets/0b0f1f6f-6ea6-4ca8-92a8-b4cc895814e4
To use this server with Claude or other MCP-compatible AI assistants, add the following configuration to your MCP client:
If you're on MacOS and want to run this in Claude Desktop, in your ~/Library/Application \Support/Claude/claude_desktop_config.json file, write the following:
Replace https://your-helius-rpc-url.com
with your Helius RPC URL.
Installation
- Clone this repository:Copy
- Install dependencies:Copy
- Create a
.env
file with your Solana RPC URL:You can get a free RPC URL from Helius.To use an existing Solana wallet, add your private key to theCopy.env
file:Then run the conversion script to create a keypair file:CopyThis will create aCopydefault.json
file in the.keys
folder with your keypair. - Build the project:Copy
- Run the MCP server:Copy
Components
Tools
- get-token-info
- Get information about a Pump.fun token
- Input parameters:
tokenAddress
(string, required): The token's mint address
- create-token
- Create a new Pump.fun token
- Input parameters:
name
(string, required): Token namesymbol
(string, required): Token symboldescription
(string, required): Token descriptionimageUrl
(string, optional): Path to local image fileinitialBuyAmount
(number, required): Initial buy amount in SOL (min 0.0001)accountName
(string, optional): Name of the account to use (defaults to "default")
- buy-token
- Buy a Pump.fun token
- Input parameters:
tokenAddress
(string, required): The token's mint addressbuyAmount
(number, required): Amount to buy in SOL (min 0.0001)accountName
(string, optional): Name of the account to use (defaults to "default")slippageBasisPoints
(number, optional): Slippage tolerance in basis points (defaults to 100)
- sell-token
- Sell a Pump.fun token
- Input parameters:
tokenAddress
(string, required): The token's mint addresssellAmount
(number, required): Amount of tokens to sell (use 0 to sell all)accountName
(string, optional): Name of the account to use (defaults to "default")slippageBasisPoints
(number, optional): Slippage tolerance in basis points (defaults to 100)
- list-accounts
- List all accounts in the keys folder
- No input parameters required
- get-account-balance
- Get the SOL and token balances for an account
- Input parameters:
accountName
(string, optional): Name of the account to check (defaults to "default")tokenAddress
(string, optional): Token address to check balance for
Account Management
The MCP automatically creates and manages Solana keypairs in the .keys
folder. Each keypair is stored as a JSON file with the account name as the filename.
When creating a token, the mint keypair is also saved in the .keys
folder with the prefix mint-
.
To use the MCP with your own account, you need to:
- Add your private key to the
.env
file and runnode convert-key.js
- Have sufficient SOL in that wallet
Standalone Scripts
The project includes several standalone scripts that can be run directly:
- Get Token Info:
node build/get-token-info.js <token_address>
- Create Token:
node build/create-token.js <name> <symbol> <description> <initial_buy_amount> [account_name] [image_url]
- Buy Token:
node build/buy-token.js <token_address> <buy_amount_sol> [account_name] [slippage_basis_points]
- Sell Token:
node build/sell-token.js <token_address> <sell_amount> [account_name] [slippage_basis_points]
- List Accounts:
node build/list-accounts.js
- Get Account Balance:
node build/get-token-balance.js <account_name> [token_address]
Important Notes
- Security: The keypairs are stored unencrypted in the
.keys
folder. Make sure to secure this folder appropriately. - Fees: All transactions on Solana require SOL for transaction fees. Make sure your accounts have enough SOL.
- Slippage: The default slippage tolerance is 1% (100 basis points). You can adjust this for each transaction.
- Images: When creating tokens with images, you must provide a local file path to the image. Remote URLs are not supported.
Development
Project Structure
src/index.ts
: Main MCP server entry pointsrc/get-token-info.ts
: Token information retrievalsrc/create-token.ts
: Token creation functionalitysrc/buy-token.ts
: Token buying functionalitysrc/sell-token.ts
: Token selling functionalitysrc/list-accounts.ts
: Account listing functionalitysrc/get-token-balance.ts
: Account balance checkingsrc/utils.ts
: Shared utility functionsconvert-key.js
: Utility to convert a base58 private key to a keypair JSON file
Building
This server cannot be installed
local-only server
The server can only run on the client's local machine because it depends on local resources.
A Model Context Protocol server enabling AI assistants to create, buy, and sell tokens on the Pump.fun platform on Solana.
Related Resources
Related MCP Servers
- AsecurityAlicenseAqualityA Model Context Protocol server that allows AI assistants to interact with Appwrite's API, providing tools to manage databases, users, functions, teams, and other resources within Appwrite projects.Last updated -8436PythonMIT License
- AsecurityFlicenseAqualityA Model Context Protocol server that enables AI assistants to interact with the Deriv trading API, providing access to active trading symbols and account balance information.Last updated -2Python
- -securityAlicense-qualityA 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 -6015TypeScriptMIT License
- -securityFlicense-qualityA Model Context Protocol server that enables AI assistants to access Flow blockchain data and perform operations such as checking balances, resolving domains, executing scripts, and submitting transactions.Last updated -JavaScript