Overview
Walmart sellers and arbitrage buyers need to track price movements and availability changes on the second-largest US e-commerce platform. This workflow searches Walmart daily for tracked products, compares against baseline prices, and sends alerts for significant price drops, out-of-stock events, and new competitor listings. Catch Walmart price changes within hours instead of days.
Trigger
Daily at 8 AM via cron.
Schedule
Daily 8 AM
Workflow Steps
Load Product Watchlist
Read the list of Walmart products to monitor: names, target prices, and baseline data.
Search Walmart for Each Product
Call Scavio with walmart platform for each product. Extract current price, availability, and seller info.
Compare Against Baseline
Check if price dropped below target, if stock changed, or if new sellers appeared.
Send Price Drop Alerts
For products with significant changes, send a Slack or email alert with the details.
Update Baseline
Save current prices and availability as the new baseline for tomorrow's comparison.
Python Implementation
import requests, os, json
from pathlib import Path
from datetime import date
API_KEY = os.environ["SCAVIO_API_KEY"]
H = {"x-api-key": API_KEY, "Content-Type": "application/json"}
WATCHLIST = [
{"name": "Dyson V15 Detect", "target_price": 550},
{"name": "Apple AirPods Pro 2", "target_price": 180},
{"name": "Samsung 65 inch OLED TV", "target_price": 1200},
]
BASELINE_FILE = Path("walmart_baseline.json")
def search_walmart(product: str) -> dict:
resp = requests.post(
"https://api.scavio.dev/api/v1/search",
headers=H,
json={"query": product, "platform": "walmart"},
timeout=15,
)
results = resp.json().get("organic_results", [])
if results:
top = results[0]
return {"title": top.get("title", ""), "price": top.get("price"), "rating": top.get("rating"), "in_stock": top.get("in_stock", True), "url": top.get("link", "")}
return {}
def monitor_walmart():
baseline = json.loads(BASELINE_FILE.read_text()) if BASELINE_FILE.exists() else {}
alerts = []
new_baseline = {}
for item in WATCHLIST:
result = search_walmart(item["name"])
if not result:
continue
key = item["name"]
new_baseline[key] = result
prev = baseline.get(key, {})
if result.get("price") and result["price"] <= item["target_price"]:
alerts.append({"type": "PRICE_TARGET", "product": item["name"], "price": result["price"], "target": item["target_price"]})
if prev.get("price") and result.get("price"):
change = (result["price"] - prev["price"]) / prev["price"]
if change <= -0.05:
alerts.append({"type": "PRICE_DROP", "product": item["name"], "old": prev["price"], "new": result["price"], "change": f"{change:.1%}"})
if prev.get("in_stock") and not result.get("in_stock"):
alerts.append({"type": "OUT_OF_STOCK", "product": item["name"]})
BASELINE_FILE.write_text(json.dumps(new_baseline, indent=2))
return alerts
alerts = monitor_walmart()
print(f"Walmart monitoring: {len(alerts)} alerts")
for a in alerts:
print(f" [{a['type']}] {a['product']}: {json.dumps({k:v for k,v in a.items() if k not in ['type','product']})}")JavaScript Implementation
const H = {'x-api-key': process.env.SCAVIO_API_KEY, 'Content-Type': 'application/json'};
const fs = await import('fs');
const WATCHLIST = [
{name:'Dyson V15 Detect', targetPrice:550},
{name:'Apple AirPods Pro 2', targetPrice:180},
{name:'Samsung 65 inch OLED TV', targetPrice:1200},
];
async function searchWalmart(product) {
const r = await fetch('https://api.scavio.dev/api/v1/search', {method:'POST', headers:H, body:JSON.stringify({query:product, platform:'walmart'})});
const results = (await r.json()).organic_results || [];
if (results.length) {
const top = results[0];
return {title:top.title||'', price:top.price, rating:top.rating, inStock:top.in_stock!==false, url:top.link||''};
}
return null;
}
async function monitorWalmart() {
let baseline = {};
try { baseline = JSON.parse(fs.readFileSync('walmart_baseline.json','utf8')); } catch {}
const alerts = [];
const newBaseline = {};
for (const item of WATCHLIST) {
const result = await searchWalmart(item.name);
if (!result) continue;
newBaseline[item.name] = result;
const prev = baseline[item.name] || {};
if (result.price && result.price <= item.targetPrice) alerts.push({type:'PRICE_TARGET', product:item.name, price:result.price, target:item.targetPrice});
if (prev.price && result.price) {
const change = (result.price - prev.price) / prev.price;
if (change <= -0.05) alerts.push({type:'PRICE_DROP', product:item.name, old:prev.price, new:result.price, change:(change*100).toFixed(1)+'%'});
}
if (prev.inStock && !result.inStock) alerts.push({type:'OUT_OF_STOCK', product:item.name});
}
fs.writeFileSync('walmart_baseline.json', JSON.stringify(newBaseline, null, 2));
return alerts;
}
const alerts = await monitorWalmart();
console.log('Walmart monitoring: '+alerts.length+' alerts');
for (const a of alerts) console.log(' ['+a.type+'] '+a.product);Platforms Used
Walmart
Product search with pricing and fulfillment data