This is a Discord Bot that dispenses Testnet ETH written in TypeScript.
Change the example.config.json
into config.json
, and fill in the required fields.
Create a file called .env
and paste in the following lines. Make sure to fill it out with your details
WALLET_PRIVATE_KEY="<wallet-private-key>"
BOT_TOKEN="<bot-token>"
DB_USERNAME="<username>"
DB_PASSWORD="<password>"
-
If you do not have pnpm, run
npm i -g pnpm
. -
Install Dependancies using
pnpm install
.
Optionally you can update the dependancies using pnpm update
.
- Fill in the config and run the bot :
pnpm start:dev
These are the supported Networks and Tokens as of yet. Feel free to do PRs to add any other testnet networks or tokens!
- Goerli
- Mumbai
- Celo
- LINK
Adding Networks or Tokens are fairly straighforward.
- Open up the
config.json
. - Add a network Object in the
networks
field ex :{ "name": "networkName", "nativeCurrency": "kool", "ALCHEMY_URL": "https://rpc-url/xxx", "scan": "https://myscan.kool.io/tx/" }
- That's literally it!
- Make sure to do a PR into the Main Repo! (Edit the
example.config.json
)
This BOT currently has two modes it can run, KeyV - Memory and Postgres - Storage. You can change the mode by changing the database
value in the stats
field of config.json
like so :
"database": "pg",
This sets the BOT to use storage - Postgres DB. Make sure you setup the necessary database parameters
"database": "keyv",
This sets the BOT to use memory - KeyV. Use this if you want to just use the BOT without having to configure Databases. In addition, this is the default if no parameter was set into database
.
- Fork the project
- Create a new branch - (Call it feature/)
- Commit the changes
- Yeet the changes using a PR into this!
- Get the Bot Working
- Convert to TypeScript
- Migrate to Postgres DB
- Beautify the code more
- Add Support for Sepolia
- Feature - Only Transferring if the user's account has low ETH