Macy's
Macy's Category API
Browse one macys.com (US) category by id or URL: 60 organic items per page with the same sorts and filters as search (brand, color, special offer, price range, store pickup, any facet). Each item has id, title, brand, URL, image, current, regular and sale price, percent off, price label, on-sale flag, sale end date, deal label, promotions, rating, review count, colors and a sponsored flag. Also returns the category's id, name and URL, total, total_pages, the facets with counts and the filters Macy's applied. Costs 1 credit per request.
Authorizations
AuthorizationstringheaderrequiredBearer authentication header of the form Bearer <token>, where <token> is your Scavio API key (e.g. Bearer sk_live_your_key).
Body
application/jsoncategory_idintegerMacy's category id: the id= of a macys.com /shop/ URL, a product's categories[].id, or a search's redirected_to_category.id. 3763 is Men's Coats & Jackets. Pass category_id or url.
Example: 3763
urlstringA macys.com category URL with its id=. Filters, page and sort already in the URL are kept.
Example: https://www.macys.com/shop/mens/clothing/coats?id=3763
pageintegerResults page, 1-based, up to 1000. Defaults to 1. 60 organic items per page.
Example: 1
sortstringfeatured (default), price_low_to_high, price_high_to_low, top_rated, best_sellers or newest. The total can differ between sorts, as it does on macys.com.
brandstring | string[]Only these brands, spelled as the BRAND facet lists them (Levi's, Calvin Klein). A list of up to 20 matches any of them.
Example: Levi's
colorstring | string[]Only these colors, as the COLOR_NORMAL facet lists them (Black, Blue, Red...). A list matches any of them.
Example: Blue
special_offerstring | string[]Only items with this offer: limited_time_special, gift_with_purchase, black_friday_deal, clearance, last_act, our_lowest_price, sales_and_discounts, special_offer or today_only. A list matches any of them.
Example: clearance
min_pricenumberLowest price in US dollars. Any bound works, not only the site's price buckets; an item sold at a price range matches when its range overlaps.
Example: 50
max_pricenumberHighest price in US dollars. Either bound can be sent alone.
Example: 100
pickup_store_idintegerOnly items available for pickup at this store: a store_id from /api/v1/macys/stores (4592 is State Street, Chicago).
Example: 4592
filtersobjectAny other facet from a previous response's facets list: its name to one value or a list, up to 10 facets and 20 values each, e.g. {"GENDER": "Women", "CUSTRATINGS": "4 stars & up"}.
Example: {"GENDER": "Women"}
include_sponsoredbooleanKeep the ad-only sponsored tiles, flagged is_sponsored. Defaults to false: they are dropped and counted in sponsored_dropped. Organic items that also hold a paid slot are always kept, flagged is_sponsored.
Request
from scavio import ScavioClient
client = ScavioClient(api_key="sk_live_your_key")
res = client.macys.category(category_id=3763, sort="price_low_to_high", special_offer="black_friday_deal")["data"]
print(res["category"]["name"], res["total"], "items")
for item in res["items"]:
print(item["id"], item["brand"], item["title"], item["price"], item["regular_price"], item["sale_ends"])Response