Script that buys a token for example - CAKE2 whenever liquidity is provided to the pool.
The following is written for Binance Test SmartChain.
- Install the dependencies
npm install
- Create a
.env
file in the root and add the following
PRIVATE_KEY=<no quotes>
ADDRESS=<no quotes>
RPC_URL=<with quotes>
- Run the cron job
node cron-ping.js
cron-ping.js
is the entry point of the botindex.js
contains the logic for the contract interaction