Migration: Availability to Occurrences
Migration: Availability to Occurrences
Guide for migrating from the legacy GET /api/v4/availability/products/{productId}/... endpoint to the new GET /api/v3/events/{eventId}/occurrences endpoint.
Endpoint Comparison
What Changed
Simplified URL
The v4 endpoint encoded filters (quantity, date range) in the URL path. The v3 endpoint moves these to optional query parameters.
Terminology
Quantity and Date Range Are Now Optional Query Parameters
In v4, quantity, from, and to were required path segments. In v3, they are optional query parameters:
All parameters can be combined freely or omitted entirely:
Money Format
Prices changed from decimal (major units) to integer (minor units) with explicit currency.
Legacy (v4):
New (v3):
All monetary values in v3 use minor units (cents for USD, pence for GBP). Divide by 100 for display.
Availability Status
Discount Information
The v3 endpoint adds discount data not available in v4:
maxDiscountPercentage— Best available % discount (e.g.,29= “Up to 29% off”)maxDiscountAmount— Best available amount discount (e.g.,{ amount: 5000, currency: "USD" }= “Save up to $50”)
These fields are optional — omitted when no discount exists.
Response Shape
Legacy (v4)
New (v3)
Key differences:
- Each occurrence has an
idyou’ll need for subsequent calls (inventory, cart) startsAtincludes timezone offset — no separate date/time fieldsendsAtis nullable (some events have no fixed end time)fromPriceis null instead ofavailable: false
Migration Checklist
- Replace
productIdwitheventIdin your integration - Update the endpoint URL from v4 path to
GET /api/v3/events/{eventId}/occurrences - Move
quantityfrom URL path to?quantity=query parameter (now optional) - Move date range from URL path to
?startDate=and?endDate=query parameters (now optional) - Update price parsing: divide
fromPrice.amountby 100 for display (or appropriate factor for the currency) - Store the occurrence
id— you need it for inventory browsing and cart creation - Filter out occurrences where
fromPriceis null (sold out or off-sale) - Optionally display discount badges using
maxDiscountPercentageormaxDiscountAmount
Next Steps
After migrating the browse step, continue with the full Purchase Flow:
- Browse Inventory —
GET /api/v3/events/{eventId}/occurrences/{occurrenceId}/inventory-items - Create Cart —
POST /api/v3/carts - Checkout —
POST /api/v3/orders