Look up a product by identifier, print title + Walmart price + cheapest cross-retailer offer. Single file, zero deps, Node 20+.
export RETAILERAPI_KEY=rk_live_…
node index.js # default: Walmart pressure cooker
node index.js 194629116676 # any UPC
node index.js B07ABCDEFG # any Amazon ASINSample output:
12-in-1 Electric Pressure Cooker 6 QT Stainless Steel Multi Cooker…
brand: Cooks Essentials
walmart: $100.56 (https://www.walmart.com/ip/19667262713)
cheapest off-Walmart: $59.99 at lowes
tokens_consumed: 10 · tokens_remaining: 998
- Bearer-token auth via
Authorization: Bearer rk_live_… ?include_cross_retailer=trueto fold in non-Walmart pricingcross_retailer[].statussemantics —ok/indexing/not_found/ etc.- Token accounting headers on the response.
Use the same pattern with /v1/products/{id}/history for price history, /v1/products/{id}/reviews for reviews, or /v1/sellers/{id} for seller profiles.
Full reference: docs.retailerapi.com.