Catalog
Resolve a storefront URL
Changed onTells a headless storefront what a path is, in the order the storefront checks it: a category slug, a product URL key (only a visible, enabled product), the last segment of a nested category path (a 301), then a URL rewrite. type is category, product, redirect or home. A path nothing matches answers 404.
get/url-resolver
Request
- Base URLhttp://localhost:8000/api/shop
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Query parameters
pathstring required
Example:nike-shoes
The path, without the domain, e.g. men/shirts or /nike-shoes.
Headers
X-STOREFRONT-KEYstring required
Storefront API Key for authentication. Required for all shop/storefront API requests.
X-Localestring
Example:en
Locale code for localized data (e.g. "en", "fr", "ar"). Defaults to channel's default locale.
X-Channelstring
Example:default
Channel code (e.g. "default"). Defaults to the current channel.
X-Currencystring
Example:USD
Currency code (e.g. "USD", "EUR", "INR"). Defaults to channel's base currency.
Response
What the path is.
Changes
- info
endpoint added
- info