This repository contains the codebase for the Pump-Fun Sniper Bot developed by @licketyspliket and me. Although this project is archived and not intended for further iteration, this README provides a comprehensive overview to help anyone who may want to understand or run the bot.
The Pump-Fun Sniper Bot is designed to interact with the Solana blockchain, purchasing newly minted coins and managing them, based on our replication of orcACR...'s strategy. I detail the strategy more in my first blog post on this project, which can be found here.
PRIVATE_KEY
: The bot pulls the bot wallet's private key from this environment variable.PROXY_URL
: Set this to an https proxy if you want to proxy the main RPC clientThe main configuration values for the bot are located in main.go
and can be edited as needed.
sendTxRPCs
string slice variable.rpcURL
and wsURL
to their proper values for a high-performance Solana RPC (Note: free/cheap RPC services will likely be ratelimited immediately due to the number of requests needed to vet coins and their creators).sql.Open("mysql", "root:XXXXXX!@/CoinTrades")
The bot is instantiated with the following parameters:
// Purchase coins with 0.05 Solana, priority fee of 200000 microlamports
bot, err := NewBot(rpcURL, wsURL, privateKey, db, 0.05, 200000)
if err != nil {
log.Fatal(err)
}
To remove Jito integration, comment out the following block:
if err := bot.beginJito(); err != nil {
log.Fatal("Error Starting Jito", err)
}
Clone the Repository:
git clone https://github.com/1fge/pump-fun-sniper-bot.git
cd pump-fun-sniper-bot
Install Dependencies: Ensure you have Go installed. Then, run:
go mod tidy
Set Environment Variables:
Ensure PRIVATE_KEY
is set in your environment.
Edit Configuration:
Modify the RPC URLs, WebSocket URLs, and MySQL database credentials in main.go
as needed.
Run the Bot:
go run .
A special thank you to Gagliardetto for creating the open-source Solana Go packages that were instrumental in developing this bot. The code we used and built on from him can be found in the pkg/jito-go
directory, as well as the output from his anchor-go
package based on the Pump.fun IDL, which is found in the pump
directory.
Also, a huge thank you to weeaa for their work on Jito Go SDK, which we used to handle all interactions with Jito.
Read more about the development of this project on my blog.