SuperAPIAI Directory

pumpswap-mcp

github.com · AI developer platforms

Real-time token swaps and automated on-chain trading on PumpSwap.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)

About this tool

pumpswap-mcp is an MCP server designed to enable AI agents to interact with PumpSwap for real-time token swaps and automated on-chain transactions.

Key capabilities:

  • Buy tokens: Use SOL to buy tokens, with support for custom slippage and priority fees.
  • Sell tokens: Sell tokens back for SOL, with configurable parameters.
  • Token price query: Get the current price of a token denominated in SOL.
  • Pool data retrieval: Retrieve and display detailed pool information for a specified token mint address.

Requirements:

  • Python 3.13 or higher.
  • uv for dependency management and script execution.
  • A Solana RPC endpoint (e.g., https://api.mainnet-beta.solana.com)。\n- A valid Solana private key for transaction signing.

Installation and configuration:

  1. Clone the repository: git clone https://github.com/kukapay/pumpswap-mcp.git\n cd pumpswap-mcp
  2. Install uv: If uv is not installed, follow the official installation guide. For example: curl -LsSf https://astral.sh/uv/install.sh | sh
  3. Install dependencies: uv sync
  4. Configure environment variables: Create a .env.private file in the project root directory containing the following variables: HTTPS_RPC_ENDPOINT=https://api.mainnet-beta.solana.com\n BUY_SLIPPAGE=0.3 SELL_SLIPPAGE=0.1 SWAP_PRIORITY_FEE=1500000 PRIVATE_KEY=your-solana-private-key Replace your-solana-private-key with your actual Solana private key.
  5. Run the MCP server: Use uv to run the server.

Exposed tools:

  • buy_token(mint: str, sol_amount: float, user_private_key: str): Buy tokens with SOL.
  • sell_token(mint: str, token_amount: float, user_private_key: str): Sell tokens back for SOL.
  • get_token_price(mint: str): Get the current SOL price of a token.
  • get_pool_data(mint: str): Get formatted token pool data.

Environment variable description: The server loads environment variables from .env.private. PRIVATE_KEY must be set, otherwise the server will throw an error.

License and risk: This project is licensed under the MIT License. This software interacts with decentralized finance (DeFi) protocols and handles sensitive data such as private keys. Use it at your own risk. Ensure the .env.private file is secure and never share your private key. The authors are not responsible for any financial losses or security issues arising from the use of this software.

Use cases: Suitable for development scenarios that require AI agents to perform on-chain operations such as token buying and selling, price queries, and pool information retrieval on PumpSwap.

Limitations: You must provide your own Solana RPC endpoint and private key; it involves real asset trading and carries financial and security risks; no information on fees, pricing, or platform support is provided.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools