Dex-sniper-bot is a bot to make swaps immediately after creating a BNB/targetToken pair in the pancake-swap-core
Addresses of the Pancakeswap router in networks:
- bsc_testnet: 0xD99D1c33F9fC3444f8101754aBC46c52416550D1
- bsc_mainnet: 0x10ED43C718714eb63d5aA57B78B54704E256024E
git clone https://github.com/SamWarden/dex-sniper-bot
cd dex-sniper-bot
Install dependencies of this package.json:
npm i -D
Use .env as a local config to set private options manually:
Don't commit it to git! (keep it secret)
Create it from template
cp .env.template .env
To run any script enter:
npx hardhat run path/to/script.ts --network network_name
Use the script to generate a new wallet with it's own private key and address:
npx hardhat run scripts/0_create_new_wallet.ts
Copy generated private key (or your own private key) to .env config on the corresponding line.
Add some BNB to address of this wallet. For tests you can use any faucet for your network. For example BSC Faucet
To add target tokens you should set their addresses to this tokens.txt file by separating with line breaks.
This file can be updated while the bot is running and it will change its target tokens.
You can specify this network
npx hardhat run app/main.ts --network bsc_mainnet
Or just use the default value (bsc_mainnet)
npx hardhat run app/main.ts
npx hardhat run app/main.ts --network bsc_tesnet