Cron Jobs
Several features require scheduled tasks (cron jobs) to run. All URLs are listed in Setup โ Settings โ Products at the bottom.
Why Cron Jobs?โ
- Abandoned cart emails - Sent only when the cron runs.
- Back-in-stock notifications - Checked when the cron runs.
- Price drop alerts - Checked when the cron runs.
warning
Without these crons, these features will not work.
Cron URLsโ
| Feature | URL | Recommended |
|---|---|---|
| Abandoned cart emails | https://yoursite.com/products/cron/abandoned_cart_emails | Daily |
| Back-in-stock | https://yoursite.com/products/cron/back_in_stock_emails | Daily |
| Price drop | https://yoursite.com/products/cron/price_drop_emails | Daily |
Replace yoursite.com with your actual domain.
How to Add to Crontabโ
Linux / cPanelโ
- Open your crontab:
crontab -e - Add lines like:
# Run daily at 9:00 AM
0 9 * * * curl -s "https://yoursite.com/products/cron/abandoned_cart_emails" > /dev/null 2>&1
0 9 * * * curl -s "https://yoursite.com/products/cron/back_in_stock_emails" > /dev/null 2>&1
0 9 * * * curl -s "https://yoursite.com/products/cron/price_drop_emails" > /dev/null 2>&1
Alternative: wgetโ
0 9 * * * wget -q -O - "https://yoursite.com/products/cron/abandoned_cart_emails" > /dev/null 2>&1
PHP CLI (if curl/wget unavailable)โ
0 9 * * * php -r "file_get_contents('https://yoursite.com/products/cron/abandoned_cart_emails');"
Cron Behaviorโ
- Each endpoint checks if its feature is enabled before running.
- If disabled, it exits immediately.
- Output is minimal (e.g., "Sent: X" for emails). No output usually means nothing to process or feature disabled.
Testingโ
You can test by visiting the URL in a browser or running:
curl "https://yoursite.com/products/cron/abandoned_cart_emails"
You should see a short response (e.g., "Sent: 0" or "Disabled").
Support
If you need help with Perfex Shop, visit the Support Ticketing Area.