This is the best, fastest, and most efficient self-bundling script for PumpFun, allowing you to create a token and buy tokens with your own 20 different wallets in one single bundle.
The PumpDotFunSDK
class provides methods to interact with the PumpFun protocol. Below are the method signatures and their descriptions.
async createAndBuy(
creator: Keypair,
mint: Keypair,
createTokenMetadata: CreateTokenMetadata,
buyAmountSol: bigint,
slippageBasisPoints: bigint = 500n,
priorityFees?: PriorityFee,
commitment: Commitment = DEFAULT_COMMITMENT,
finality: Finality = DEFAULT_FINALITY
): Promise<TransactionResult>
- Creates a new token and buys it.
- Parameters:
creator
: The keypair of the token creator.mint
: The keypair of the mint account.createTokenMetadata
: Metadata for the token.buyAmountSol
: Amount of SOL to buy.slippageBasisPoints
: Slippage in basis points (default: 500).priorityFees
: Priority fees (optional).commitment
: Commitment level (default: DEFAULT_COMMITMENT).finality
: Finality level (default: DEFAULT_FINALITY).
- Returns: A promise that resolves to a
TransactionResult
.
To run the basic example for creating, buying, and selling tokens, use the following command:
npx ts-node example/basic/index.ts
We welcome contributions! Please submit a pull request or open an issue to discuss any changes.
This project is licensed under the MIT License - see the LICENSE file for details.
Create and buy with 20 wallets in a single bundle