Broadleaf API Map
The storefront is a thin wrapper over the publicly documented Broadleaf Commerce Catalog Browse and Cart Operations APIs. Gateway: https://autozone-api.base1.app/api — connected.
| Area | Broadleaf endpoint | Storefront | Current source |
|---|---|---|---|
| Catalog | GET /catalog-browse/products/details?productUris= | /p/[slug], search hydration | Broadleaf (60s cache) |
| Catalog | GET /catalog-browse/categories/details?categoryUrl= | /c/[slug] | Broadleaf (60s cache) |
| Search | GET /catalog-browse/search/catalog?query=&page=&size=&sort= | /search?q=&page= | Broadleaf, facets derived from results |
| Search | GET /catalog-browse/search/catalog/suggest | Header search box | Broadleaf + product/brand matches |
| Cart | POST /cart-operations/cart/items (create) · /cart/{cartId}/items | Add to Cart | POST /api/cart (op: add) |
| Cart | PATCH /cart-operations/cart/{cartId}/items/{itemId} | /cart quantity + fulfillment | POST /api/cart (op: update) |
| Cart | DELETE /cart-operations/cart/{cartId}/items/{itemId} | /cart remove | POST /api/cart (op: remove) |
| Cart | GET /cart-operations/cart/{cartId}?price=true | Header badge, /cart | GET /api/cart (httpOnly az_cart cookie) |
Flat Files
Products follow the Broadleaf ProductDetails shape. Replace data/catalog/products.json with an export, or edit scripts/generate-catalog.mjs and run node scripts/generate-catalog.mjs.
Cart Business Rules
- Core deposit
- Batteries, alternators and starters carry a refundable core charge (corePrice), shown on PDP and summed in cart.
- Quantity cap
- Max 10 per line and 50 lines per cart, validated client-side and in the /api/cart BFF.
- Versioning
- Every cart mutation sends X-Cart-Version. On 409 the BFF re-reads the cart and retries once with the current version.
- Fulfillment
- Each line is PICKUP (store #3071) or SHIP, passed as itemAttributes.fulfillmentType.
- Free shipping
- Ship-to-home lines are free at $35+, otherwise $7.99.
- Fitment
- Products are UNIVERSAL or VEHICLE_SPECIFIC; the selected vehicle is kept in the browser.
