When to use
Use real-time when:- You want live pricing and availability without sync lag
- You don’t have local catalog infrastructure to maintain
- You want the simplest possible integration path
- You already have a local catalog or search index you want to blend Snappy products into
- You need offline access or want to blend with other data sources
- Your rendering layer can’t tolerate API latency on every request
Two paths
Collection-based (recommended)
Fetch products scoped to a specific collection — the usual pattern for partners who have a dedicated collection for their program.links.next until it returns null.
Filter-based
Fetch from the full catalog with filters, without scoping to a collection.collectionId.
After picking a product
Once a user selects a product, fetch the full detail and its variants:JavaScript
data wrapper). The variants endpoint returns { data, links } with page-number pagination.
Resolve the selected variant at checkout
JavaScript
firstSelectableVariant on page load to avoid dead-end combinations.
Caching guidance
Fetching live on every render is fine for most traffic levels. Add a short cache at your edge if you need to reduce latency or API call volume:
Cache by
(collectionId, location, page[cursor]) for list pages, and by (productId, location) for detail pages.
Common pitfalls
Related
- Bulk Catalog Export — for local catalog infrastructure
- Place Orders — the next step after catalog browsing
- Build a Rewards Experience — end-to-end recipe using this pattern