WNC Weekly Ad Offer Collector avatar

WNC Weekly Ad Offer Collector

Pricing

Pay per usage

Go to Apify Store
WNC Weekly Ad Offer Collector

WNC Weekly Ad Offer Collector

Collects coupon and sale offers from weekly-ad pages you list and rewrites them in a standard form (sale price, dollar off, percent off, BOGO, multi-buy, spend-and-save) with expiry dates, ready for price comparison.

Pricing

Pay per usage

Rating

0.0

(0)

Developer

Adam Miller

Adam Miller

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

5 days ago

Last modified

Categories

Features

Limited permissions

Share

This Actor collects coupon and sale offers from weekly-ad pages that you list, rewrites each offer in a standard form, and saves the results for comparison. It was built for comparing grocery and retail deals across stores in western North Carolina, but it works on any weekly-ad page where offers appear as text.

What it produces

  • Offers (dataset): one row per offer, with the store, offer type, normalized text, expiry date, the raw text it came from, the page URL, and a needsReview flag.
  • Offers ready to import (key-value store record OFFERS_IMPORT): a JSON array of normalized, unexpired offers with text, appliesTo, and expires fields.

Before you run it

Only add pages whose terms of use allow automated access. Many retailer sites prohibit scraping, and many load their weekly ads from third-party circular services with their own terms. The Actor respects robots.txt by default.

Input

FieldPurpose
storesRequired. A list of pages to collect. Each entry has url (required), storeName, chain, town, and optionally appliesTo.
renderJavaScriptUse a browser for pages that load offers with JavaScript. This option is slower and uses more compute.
waitForSelectorIn browser mode, a CSS selector to wait for before reading the page.
selectorsOptional CSS selectors for more accurate extraction: item, title, price, details, expires. Leave this empty to use automatic detection.
followLinkGlobs and maxDepthFollow additional pages, such as ad page 2, that match the given patterns.
maxRequestsPerCrawlThe maximum number of pages loaded in one run.
defaultValidDaysThe expiry used when neither the offer nor the page states an end date.
respectRobotsTxtSkip pages that robots.txt disallows. This is on by default.
proxyConfigurationOptional proxy settings.

Example input:

{
"stores": [
{
"url": "https://www.example.com/weekly-ad",
"storeName": "Example Grocery, Boone",
"chain": "Example Grocery",
"town": "Boone"
}
],
"selectors": { "item": ".offer-card", "title": ".offer-title", "price": ".offer-price" }
}

How offers are normalized

TypeNormalized form
Sale priceSale [item] $X (with /lb when the price is per pound)
Dollar off$X off [item] or $X off [item] when you buy N
Percent offN% off [item]
BOGOBOGO [item]
Multi-buyN for $X [item]
BasketSpend $X get $Y off

The Actor looks for an expiry date in the offer first, then on the page (for example, "Prices valid 11/18 - 11/24"), and otherwise uses the default. The expiresSource field records which of the three it used. A row is flagged with needsReview when its type is unknown, when no item name could be found, or when the expiry is only the default.

Limits

  • Automatic detection works on pages where each offer appears as its own block of text. Image-only circulars, PDFs, and canvas-rendered flyers contain no readable offer text, so the Actor cannot extract offers from them.
  • With automatic detection, item names can include extra description text. Supplying selectors for the item name and price gives cleaner results.
  • Sites that block automated requests will return errors, and the Actor does not try to get around them.