List coupons with cursor-based pagination
Changed onReturns coupon data with cursor-based pagination and optional full-text search via the query parameter.
Request
- Base URLhttps://api.session.services
- AuthAPI key in header x-tenant-id
Query parameters
Unique identifier of the team whose coupons to retrieve
Optional filter to retrieve only active or inactive coupons
Optional search query to filter coupons by name or description. When provided, search-backed pagination is used.
Maximum number of coupons to return per request (1-100, default: 20)
Pagination cursor returned by a previous request. Omit on the first request.
Response
OK
Array of coupons for the current result set
Cursor for navigating backward in the result set. Omitted when there are no prior results.
Cursor for navigating forward in the result set. Omitted when there are no subsequent results.
Maximum number of items to return in each result set
Example response
{
"coupons": [
{
"id": "cpn_01jps5cgsfzs1ksqaet5hba8ac",
"couponId": "cpn_01jps5cgsfzs1ksqaet5hba8ac",
"createdAt": "2026-12-02T02:43:23.597Z",
"updatedAt": "2026-12-02T02:43:23.597Z",
"name": "Half Price",
"active": true,
"kind": "PERCENT",
"filter": "EVENTS",
"currency": "AUD",
"discount": 50,
"limit": -1,
"orderLimit": 2,
"saleStartsAt": "2025-02-10T03:00:00"
}
],
"before": "eyJ2ZXJzaW9uIjoxLCJpbnRlbnQiOnsic291cmNlIjoiZGVtbyJ9LCJwb3MiOnsicHJpbWFyeUtleSI6InBybV8wMXM4NTNqIn19",
"after": "eyJ2ZXJzaW9uIjoxLCJpbnRlbnQiOnsic291cmNlIjoiZGVtbyJ9LCJwb3MiOnsicHJpbWFyeUtleSI6InBybV8wMXM4NTNkIn19",
"limit": 20
}Changes
- breaking
for the
queryrequest parameterlimit, the type changed fromnumbertointeger - warning
for the
queryrequest parameterlimit, the max was set to100.00 - warning
for the
queryrequest parameterlimit, the min was set to1.00
2 more changes in this revision
- breaking