A X-bot which automatically post a Quote.
A simple HTML frontend is available at index.html that displays random quotes from the ZenQuotes API.
- Clone this repo ,
cdto project root and add.envfile with your username and password. - Make sure node is installed on your system.
- Install chrome-driver on your system.
- Install dependencies using
npm i - Run
node index.js
- Keep your chrome-driver in folder which is already in a system variable path.(Took me forever to figure this small thing out)
- Can hard-code your email and password.
- You might get flagged and required to enter your username between entering email and password, then you can just uncomment lines 94-100 in ./WebPage.js and enter your Username there.
- Line 13 ./WebPage.js Enter your Chrome.exe path.
- You can change API in Line 120 ./WebPage.js to get whatever data You wanna post.
- SSH into your cloud instance.
- Clone this repo.
- Configure your environment variables.
3.a) MacOS/Linux
> export USERNAME="Replace this with your X username without quotes)"
> export PASSWORD="Replace this with your X password without quotes)"
3.b) Windows-CMD
> setx USERNAME "Replace this with your X username without quotes"
> setx PASSWORD "Replace this with your X password without quotes"
& ensp;3.c) Powershell
> $Env:USERNAME="Replace this with your X username"
> $Env:PASSWORD="Replace this with your X password" - Install node and chrome-driver.
cdto project root and install dependencies usingnpm i- Run the application.
6.a) Launch script by runningnode index.js
6.b) Launch using pm2 by runningnpm install pm2@latest -g && pm2 start index.js<n