Easy Pump.Fun API BUY SELL
API Version 2.1 • Production Ready

Easy Pump Fun API Documentation

Easiest way to BUY and SELL on pump.fun! Copy Paste and Run. Focus on your trading algorithm and let Easy Pump Fun handle the rest.

Zero Configuration

Automatically configures RPC nodes, manages program addresses, token accounts, bonding curves, and fees.

ZERO LOG Policy

Your data stays yours. No tracking. No storage. Ever. End-to-end encryption for all requests.

Free RPC Nodes

No setup required. Free tier includes shared RPC nodes. Premium users get dedicated nodes for faster, reliable performance.

Designed with simplicity in mind, it allows you to execute swaps effortlessly just by simply calling the endpoint and providing the necessary parameters. API automatically configures RPC nodes (free for all user), manages all program addresses and token programs, opens and closes token accounts, connects to the bonding curve, handles Compute Units and microLamports, and more.

To further enhance security, Easy Pump Fun features end-to-end encryption for all requests, IP whitelisting for controlled access (available for subscription plans only) and more.

Subscribers get access to dedicated RPC node exclusive to individual account. So there are no bottlenecks caused by other users.

PREMIUM API provides advanced features including token sniping, uptime guarantees, higher rate limits, and priority support. Contact support@easypumpfun.com

And for any other questions feel free to contact support@easypumpfun.com

POST

1. Buy

https://api.easypumpfun.com/buy

Request Example

import requests

url = "https://api.easypumpfun.com/buy"
data = {
    "keypair": "2oPQn9z1OaXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXNwt02aoMW7",
    "mint": "9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump",
    "sol_in": 0.5,
    "slippage": 2,
    "sol_fee": 0.0001
}

response = requests.post(url, json=data)

print("Status Code:", response.status_code)
print("Response:", response.json())
POST

2. SELL

https://api.easypumpfun.com/sell

Request Example

import requests

url = "https://api.easypumpfun.com/sell"
data = {
    "keypair": "2oPQn9z1OaXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXNwt02aoMW7",
    "mint": "9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump",
    "percentage": 75,
    "slippage": 2,
    "sol_fee": 0.0001
}

response = requests.post(url, json=data)

print("Status Code:", response.status_code)
print("Response:", response.json())

3. Responses

3.1 Response status code

Status Code: 200

A response status code 200 means the API is functioning correctly and handling requests as expected. Any other status code indicates an issue with the API. Even if the status code is 200 the transaction can still fail. This indicates that the API is functioning correctly but the transaction failed due to an incorrect setup or another issue.

3.2 Response Body

{
    "failed": {
        "message": null,
        "status": false
    },
    "signature": "4ci6dTW6D6ocnKiT8qzD9Bg89wpWx5KeXW2h8JTqeZfk6zKF81AbYUnKuEcTQmdma7Q2mBnutZEW89ZCYpADfzo1"
}

failed

This field provides information about whether the transaction failed. It contains two subfields:

  • message A description of the issue if the transaction failed. If transaction succeeds it's None.
  • status A boolean indicating if the transaction failed. If False the transaction did not fail. If True the transaction failed.

signature

Hash for the completed transaction. If the transaction fails, this field might still be present if the API successfully processed the request but encountered an issue with the transaction completion.

4. Payload explained

BUY EXAMPLE
#FOR BUY
data = {
    "keypair": "2oPQn9z1OaXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXNwt02aoMW7",
    "mint": "9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump",
    "sol_in": 0.5,
    "slippage": 2,
    "sol_fee": 0.0001
}
Token CA 9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump
Buy token for 0.5 SOL
Slippage 2%
Fees cost 0.0001 SOL
SELL EXAMPLE
#FOR SELL
data = {
    "keypair": "2oPQn9z1OaXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXNwt02aoMW7",
    "mint": "9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump",
    "percentage": 100,
    "slippage": 2,
    "compute": 100_000,
    "mlamports": 2_000_000
}
Token CA 9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump
Sell percentage 100%
Slippage 2%
Compute Units 100_000
microLamports 2_000_000

4.1 Wallet and Token

keypair

string

Your private key for the wallet you want to use.

DO NOT SHARE THIS WITH ANYONE!

How to find your private key in Phantom Wallet
"keypair": 2oPQn9z1OaXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXNwt02aoMW7

mint

string

Token's contract address (CA).

"mint": 9BB6NFEcjBCtnNLFko2FqVQBq8HHM13kCyYcdQbgpump

4.2 SOL amount

sol_in

float BUY only

Amount of SOL you want to spend buying the token.

"sol_in": 0.3 (buy for 0.3 SOL)

percentage

float SELL only

Percentage of token holdings you want to sell.

"percentage": 50 (sell 50% of your tokens)

slippage

float

The acceptable slippage percentage for the transaction. Higher values increase the likelihood of a successful transaction.

"slippage": 2 (if unsure set it to 2%)

Slippage is like agreeing to a small price change while buying or selling. Let's say you set slippage to 0% while buying X amount of tokens for 1 SOL. But by the time your transaction is completed other people might also be buying, which drives the price up. If the price of the token increases by 1% during that time, the cost for X tokens would now be 1.01 SOL. Since your transaction is only set to pay 1 SOL for now 1.01 SOL worth of tokens, it will fail. In the same example if you were to set slippage to 2%, you are basically saying you are willing to pay up to 2% more than 1 SOL for that X amount of tokens. So if the price increases to 1.01 SOL, your transaction will succeed and you will pay 1.01 SOL for X amount of tokens. Notice that you only paid 1% more, meaning not all of the available slippage was used. If the price change is greater than 2%, for example 1.03 SOL, your transaction will still fail. Slippage is essentially like saying you are willing to paying up to 2% more for X tokens to make sure my transaction goes through, even if the price changes while it's being processed. Higher slippage is needed for tokens with a lot of trading activity. But don't set it too high to avoid overpaying. If you didn't understand any of this just set it to 2%

All the parameters listed above are required and the API cannot function without them. When determining transaction fee costs you have two options. Either set the fee automatically by specifying the desired amount in SOL. Or configure it manually by providing the Compute Units and microLamports. One of these two methods must be used. Otherwise the transaction cannot be completed without setting up the fees

4.3 Transaction fees

Easy Pump Fun API doesn't charge you any fees. However for every transaction you'll pay an additional 1% of the transaction value to Pump Fun (nothing you can do about it). Plus if you're buying a token for the first time a little bit more than 0.002 SOL will be charged to create the token account in your wallet (also nothing you can do about it).

sol_fee

float

Amount of SOL you want to use for fees. It will be added on top of the transaction cost.

"sol_fee": 0.0001

Keep in mind that if you configure fees this way, the actual cost may not be exact but will be approximately around the specified value.

compute

int

Maximum number of compute units to be used for the transaction.

If you set "sol_fee" you don't need to set this.

"compute": 100_000

mlamports

int

Cost of a single compute unit in microLamports.

If you set "sol_fee" you don't need to set this.

"mlamports": 2_000_000
Priority Fee Tracker