(A simple, developer-friendly project to help you catch Black Friday, Cyber Monday, and Christmas deals before anyone else)
It’s that time of the year again, everyone’s hunting for discounts, limited-time deals, and that one item you’ve been keeping an eye on all year. You know the drill: tabs open everywhere, price tracker sites breaking under traffic, browser extensions that promise magic but fail right when The Deal drops.
So this year, I decided to build something different, something that actually works when I need it the most.
A personal price-alert system, powered by:
And honestly? It ended up being one of the simplest, useful and most reliable holiday project I’ve made in a long time.
❌ No HTML parsing.
❌ No complex CSS selectors.
❌ No brittle scrapers that break during peak traffic.
✅Just a clean API call, structured product data, and a push notification when the price hits your set target.
Let me walk you through the whole thing :
🎁 Why Build Your Own Deal Tracker?
Because holiday deals don’t wait for anyone. Every year I get messages from friends asking,
“Bro, what’s the best price tracker? Nothing seems to work today.”
And they’re right. Most free services throttle, break, or go down completely during Black Friday and Cyber Monday because everyone hits them at once.
Meanwhile, with a few lines of Python and Zyte’s AI-powered extraction, you can build something that:
- Works only for you
- Deals with anti-ban, anti-bot and captchas
- Checks as often as you want (make it run on your pc, github-actions, server or a raspberry pi)
- Doesn’t rely on brittle selectors
- Doesn’t choke on JavaScript
- Doesn’t get rate-limited
- Sends you a mobile ping instantly when price drops
It’s the perfect mix of practical dev fun + a tool you’ll actually use.
🎄 Why Zyte?
Scraping e-commerce sites for price data is usually a pain: blocking, JavaScript rendering, cookie rules, bot detection, dynamic DOMs, infinite variations in product page layouts... you get it.
The magic here is Zyte’s Automatic Extraction.
You literally tell AI powered Zyte API:
{
"url": "<product-url>",
"product": true
}
and it returns structured fields like:
- price
- currency
- product name
- sku
- images
- stock availability
- description
You don’t write selectors. You don’t parse HTML. You don’t chase CSS changes. You just get clean data. And that makes this holiday project absurdly simple.
🎅 What We’re Building
A script that:
- Takes:
- a product URL
- a target price
- your Zyte API key
your IFTTT Webhook key
Fetches structured product data using Zyte API
Checks if the product price is ≤ your target
If yes → triggers an IFTTT event
Your phone instantly notifies you with product URL:
“Your product dropped to your target price. Go get it!”
You can run this:
- manually (when you want)
- on a cron job (in the background)
- in GitHub Actions
- on a Raspberry Pi
- on a cloud function Your call.
🛠 Setup
- Clone your project
git clone https://github.com/apscrapes/zyte-sale-alert.git
cd zyte-sale-alert
- Create your virtual environment
python3 -m venv venv
source venv/bin/activate
- Install dependencies
pip install -r requirements.txt
- Create and add secrets in .env file
ZYTE_API_KEY=your_zyte_key_here (obtained from zyte)
IFTTT_KEY=your_webhooks_key (obtained from IFTTT, see next step)
IFTTT_EVENT=price_drop (name of your ifttt applet, see next step)
TARGET_PRICE=149.99 (example)
PRODUCT_URL=https://example.com/product/123
- Create an IFTTT Webhook Applet
a. Download IFTTT mobile app, it’s paid but you get a 7-day trial and it has tons of automation you can build using no-code, so i think it’s worth it.
b. Click create new automation / applet
c. In “IF” field, select “Webhooks” > Add Event Name
d. In “THEN” field select Notification > App Notification > JSON Payload > High Priority
Note : You can instead of notification can also set other automation like getting an email for example
e. Here's how it should look like when it's successfully created:
Once the automation is created add your IFTTT_KEY and IFTTT_EVENT to your .env file
- Set product parameters The main script is at src/pricedrop.py, edit the following variables to add your:
PRODUCT_URL = “ ”
DESIRED_PRICE = 250
PRODUCT_URL “ ” is the URL of the product you want to track and DESIRED_PRICE is the price at which you want to be notified, that is it.
- Run the project
python src/pricedrop.py
You can run it manually or set up a cronjob to run at regular intervals. Whenever the price drops equal or below your target price you’ll get a notification from the IFTTT app on your phone with product URL so you can order it right away.
Let’s understand how it works.
🧩 Core Logic (Short Version)
resp = client.get({"url": url, "product": True})
“product : True” tells zyte API that the webpage we’re scraping has a product so the Machine Learning powered scrapper gets you all the relevant parameters like price, quantity, description, currency etc.
And that’s literally all you need.
The reason this works so beautifully is Zyte is handling:
JS rendering
blocking
retries
browser simulation
extraction logic
AI-powered field detection
In-detail :
- Importing all the necessary libraries
import os
import sys
import requests
from zyte_api import ZyteAPI
from dotenv import load_dotenv
- Setting required variables
PRODUCT_URL = "https://outdoor.hylnd7.com/product/a1b2c3d4-e5f6-4a7b-8c9d-000000000293"
DESIRED_PRICE = 250
Here we've setup a sample product link whose price we want to track and a price at which if it goes below we want to be notified.
- Loading the API keys from .env file
load_dotenv()
# from Zyte API
ZYTE_API_KEY = os.getenv("ZYTE_API_KEY")
# from IFTTT Service applets
EVENT_NAME= os.getenv("EVENT_NAME")
IFTTT_KEY= os.getenv("IFTTT_KEY")
if not ZYTE_API_KEY:
print("ERROR: ZYTE_API_KEY not found in environment.")
sys.exit(1)
In the project root directory, create a .env file and add ZYTE API Key you'll get after logging into zyte.com and IFTTT webhook API key you get after creating the automation applet
- Function to trigger the mobile notification :
def trigger_ifttt(event_name, key, value1):
url = f"https://maker.ifttt.com/trigger/{event_name}/json/with/key/{key}"
payload = {
"value1": value1,
}
What this funciton is doing is basically making an API call to IFTTT and IFTTT applet is set so whenever the API calls comes with payload it sends mobile notification with that payload, which in this case is product URL so you can directly click and open the product page and buy it before it goes out of stock, SMART right? 😉
- Scraping init
client = ZyteAPI(api_key=ZYTE_API_KEY)
payload = {
"url": PRODUCT_URL,
"product": True,
}
resp = client.get(payload)
Making a GET request on Zyte API with product : True, we're asking zyte to treat the URL as product page and thus it's uses it's ML capabilities to fetch product relevant details, price in this case.
- Compare price to SETPOINT
if price_float <= DESIRED_PRICE:
trigger_ifttt(EVENT_NAME, IFTTT_KEY, value1 = PRODUCT_URL)
If price of the product reaches to or below our target price it will call the IFTTT function, thus triggering the notification.
🌟 Make It Even Better
You can extend this to:
- Track multiple URLs
- Log daily prices to CSV
- Plot graphs
- Send WhatsApp alerts
- Push to a Telegram bot
- Use GitHub Actions to check every hour
- Deploy as a Streamlit dashboard
Zyte handles the extraction. You build the magic on top.
🧘 Final Thoughts
I love projects like this because they hit the sweet spot between:
- seasonal usefulness
- real-world scraping challenges
- a clean developer experience
- a fun weekend build
If you're new to the world of web scraping like me, this shows how powerful the right tools can be. If you're experienced, it’s refreshing to skip the boilerplate and let Zyte handle the messy parts.
And honestly, there’s something fun about getting a custom alert on your phone saying:
“Hey, that gadget you wanted all year just dropped to your target price.”
Happy building, happy holidays, and happy deal-hunting! 🎄🎁
Let me know what you end up tracking.
Join Zyte Discord to share what you're building or get any support :
https://discord.com/invite/DwTnbrm83s







Top comments (0)