A simple WhatsApp User bot.
-
Deploy to Heroku
- Click SCAN and scan the QR code through the "WhatsApp Linked Devices" option in your WhatsApp app.
- You will get a session ID in WhatsApp, copy the ID only.
- If you don't have an account on Heroku, create an account now.
- If you don't have a GitHub account, sign up now.
- FORK this repository.
- Now DEPLOY.
-
Deploy to Koyeb
- Create an account on Koyeb. Sign up now.
- Get DATABASE_URL. You'll need this while deploying.
- Get SESSION_ID. Open Linked Devices in WhatsApp and SCAN now.
- Get the Koyeb API key. Let's Go.
- DEPLOY now.
- Enter Environment Variables. Read More.
- Enter a name and click "Create Service."
-
Deploy on VPS or PC (Example here as in Ubuntu)
-
Install with script
wget -N -O levanter.sh https://bit.ly/43JqREw && chmod +x levanter.sh && ./levanter.sh
-
Install without a script
-
Install git, ffmpeg, and curl:
sudo apt -y update && sudo apt -y upgrade sudo apt -y install git ffmpeg curl
-
Install nodejs:
sudo apt -y remove nodejs curl -fsSl https://deb.nodesource.com/setup_lts.x | sudo bash - && sudo apt -y install nodejs
-
Install yarn:
npm install -g yarn
-
Install pm2:
sudo yarn global add pm2
-
Clone the repository and install packages:
git clone https://github.com/Giftedmaurice/levanter-md botName cd botName yarn install --network-concurrency 1
-
Enter Environment Variables: Copy-paste the lines below (remove SESSION_ID if not needed):
echo "SESSION_ID = Session_Id_you_Got_After_Scan_Dont_Add_This_Line_If_You_Can_Scan_From_Terminal_Itself PREFIX = . STICKER_PACKNAME = GiftedTech ALWAYS_ONLINE = true RMBG_KEY = DJwc34NaWmhXmDxEeh6YUEmm LANGUAG = en WARN_LIMIT = 5 FORCE_LOGOUT = false BRAINSHOP = 159501,6pq8dPiYt7PdqHz3 MAX_UPLOAD = 250 REJECT_CALL = false SUDO = 254728782591 TZ = Africa/Nairobi VPS = true AUTO_STATUS_VIEW = true SEND_READ = false AJOIN = true DISABLE_START_MESSAGE = false PERSONAL_MESSAGE = null" > config.env
-
-
Edit the
config.env
using nano if needed. To save, pressCtrl + O
, then pressEnter
, and to exit, pressCtrl + X
. -
Start and stop the bot:
- To start the bot:
pm2 start . --name botName --attach --time
- To stop the bot:
pm2 stop botName
- To start the bot:
-