Skip to content

Developed to compete with scalpers, the Bestest Buy Bot autonomously purchases high-demand products while utilizing node.js, puppeteer, pm2, and discord web hooks.

License

Notifications You must be signed in to change notification settings

ShepLT1/bestest-buy-bot

Repository files navigation

bestest-buy-bot

License

Description

Best Buy purchase bot developed to compete with scalper bots. Sends purchase updates via discord web hook. Utilizes node.js, puppeteer, and pm2.

Table of Contents


Demo

bestest-buy-bot

Installation

Clone this repository via Git. Once cloned, run

npm install

to download node modules.

You may also need to install the specific firefox version of puppeteer and firefox nightly. To do this, run

PUPPETEER_PRODUCT=firefox npm i puppeteer

Configuration

You can edit the best buy product page url (currently set to Nvidia RTX 3070 Founders Edition) and price limit on line 9 and 10 of purchaseProduct.js.

You will need to set up a .env file in the root directory to utilize the bot. To do this, navigate to the bestest-buy-bot folder and add a file named '.env'. The file contents should be as follows (substituting your information within the quotation marks):

FIRST="FIRST_NAME"
LAST="LAST_NAME"
STREET="STREET_ADDRESS"
STREET2="APARTMENT_NUMBER"
CITY="CITY"
STATE="STATE"
ZIP="ZIPCODE"
EMAIL="EMAIL"
PHONE="PHONE"
NUMBER="CREDIT_CARD_NUMBER"
EXPIREMONTH="CREDIT_CARD_EXPIRATION_MONTH"
EXPIREYEAR="CREDIT_CARD_EXPIRATION_YEAR"
CVV="CREDIT_CARD_SECURITY_CODE"
DISCORD="DISCORD_WEBHOOK_URL"

**make sure to leave the quotation marks in place
**leave STREET_2 blank if apartment number not applicable

Usage

Auto-purchasing is disabled to avoid accidental purchasing. To enable auto-purchase, uncomment lines 172-177 in purchaseProduct.js.

To start bot, navigate to bestest-buy-bot folder in command line interface and type

pm2 start index.js

To stop bot, type

pm2 stop index.js
To monitor bot after initiating bot startup, type
pm2 monit
To view bot logs, type
pm2 logs
NOTE: pm2 logs and pm2 monit will log an error within puppeteer:

TypeError: Cannot read property '1' of null

This is normal and does not impact bot performance.

License

Click on the badge (top of page) for this project's MIT licensing information.

Contributing

Pull requests and stars are always welcome. For bugs and feature requests, please submit an issue

About

Developed to compete with scalpers, the Bestest Buy Bot autonomously purchases high-demand products while utilizing node.js, puppeteer, pm2, and discord web hooks.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published