A program that scraps websites for prices and notifies you about it.
Project description
Web Price Watcher
A tiny script that scrapes a page in headless Chrome and sends an ntfy.sh notification when your target text (a price) changes. Currently, the example is checking Palworld's price on Steam, but you can easily adapt it to other websites by changing the URL and CSS selectors. It scrapes the pages every 24 hours, but you can change the schedule as needed. Scrape data is saved to a JSON file, so it can be compared with the last scraped data.
Based on: slashtechno/scrape-and-ntfy The Ntfy class was adapted from there.
Usage
To use, just use:
from website_price_notifier import utils
utils.main()
To customize, from website_price_notifier, import the Ntfy class and the PriceScraper class, then create your own instances of PriceScraper with the URL and CSS selector for the price you want to track. You can also change the ntfy_notifier URL to your own ntfy topic.
Install
git clone https://github.com/Bai756/web-price-watcher.git
cd web-price-watcher
pip install selenium webdriver-manager httpx schedule
Usage
To use, edit the top of the main function. Add your own urls and css-selectors, and change the ntfy_notifier url to your ntfy topic. Add as many PriceScraper instances as you want.
Then run:
python main.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file website_price_notifier-0.0.1.tar.gz.
File metadata
- Download URL: website_price_notifier-0.0.1.tar.gz
- Upload date:
- Size: 14.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3f5e51e0ad4622a2155a079b9138e2109e7b39889835aa9d5bc2ed480c89219d
|
|
| MD5 |
a5ca95395632cd707761c49a1154d02a
|
|
| BLAKE2b-256 |
e050e8dbfe72b6754772ac9a257cf9096aef38dd843fdd670381c8cf6e17fee6
|
File details
Details for the file website_price_notifier-0.0.1-py3-none-any.whl.
File metadata
- Download URL: website_price_notifier-0.0.1-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.19
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
33af7ab03ab4660faf73966473d5f804ff4cd9c9cf98692268fddf8403dcde4a
|
|
| MD5 |
3bfb4b4b2a7e32a75ec3d58c7d3273cd
|
|
| BLAKE2b-256 |
10a19f421c218f4f70600876fcb22f5edd162d734abff657f4b50d621eaff277
|