Git Product home page Git Product logo

nowinstock's Introduction

NowInStock

Tracker to send SMS alerts instantly when an out-of-stock item returns in stock at online retailers. Uses your Twilio account to send text messages and Puppeteer to check the retailer pages.

Currently-supported online retailers:

  • Amazon
  • Costco
  • Best Buy
  • Target
  • GameStop

Getting Started

Prerequisites

  • NodeJS (> v10.x)
  • NPM
  • A Twilio account (trial is fine), and create a phone number in their dashboard to send SMS messages.
  • Chromium/Chrome installed on the target environment (headless is fine)
  • Technical inclination and ability to work a bit from a command line

Setup

  1. Clone this project on a computer which can keep it running all the time (A VPS or a Raspberry Pi is a good idea).
  2. Go into the directory of the project and run npm install.
  3. run node index.js to start it up. The first time you run it, you will be prompted for your Twilio credentials, your phone number, and the first product page you want to track.

That's it! If you want to add additional products, you can edit the generated config.json file to add to the "items" list. It is pretty self-explanatory. By default, the script checks every 2 minutes. Change that by adding a interval property to config.json to specify milliseconds between runs. For example, adding "interval": 60000 would tell the script to run every minute (60 seconds, AKA 60000 milliseconds).

You probably also want to set this script up to run indefinitely on your server without having a terminal window open. PM2 is an excellent tool for this.

Development

To develop locally, follow the steps above but run npm run dev to start a server which watches for changes and reloads automatically.

nowinstock's People

Contributors

baggachipz avatar mattcurtisox avatar

Stargazers

 avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.