Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Query Parameters
Value in
- "active"
- "archived"
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/rewards"{ "data": [ { "id": "string", "name": "string", "cost": 0, "currency": "string", "availability": 0, "issued": 0, "expiry_after": "string", "status": "active", "version": 0, "created_at": "string", "updated_at": "string" } ], "next_cursor": "string", "has_more": true}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Header Parameters
Required by the API on this route (400 idempotency_key_required without it); the official clients generate a UUID when you omit it.
1 <= length <= 255Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/rewards" \ -H "Content-Type: application/json" \ -d '{ "name": "Free audiobook", "cost": 500, "currency": "points", "availability": 100, "expiry_after": "30d" }'{ "id": "string", "name": "string", "cost": 0, "currency": "string", "availability": 0, "issued": 0, "expiry_after": "string", "status": "active", "version": 0, "created_at": "string", "updated_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/rewards/string"{ "id": "string", "name": "string", "cost": 0, "currency": "string", "availability": 0, "issued": 0, "expiry_after": "string", "status": "active", "version": 0, "created_at": "string", "updated_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/rewards/string" \ -H "Content-Type: application/json" \ -d '{}'{ "id": "string", "name": "string", "cost": 0, "currency": "string", "availability": 0, "issued": 0, "expiry_after": "string", "status": "active", "version": 0, "created_at": "string", "updated_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X DELETE "https://example.com/rewards/string"Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Query Parameters
1 <= value <= 20050length <= 2048Value in
- "issued"
- "redeemed"
- "cancelled"
- "expired"
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/reward_issuances"{ "data": [ { "id": "string", "reward_id": "string", "customer_id": "string", "status": "issued", "source_type": "rule_execution", "source_id": "string", "cost_entry_id": "string", "expires_at": "string", "redeemed_at": "string", "cancelled_at": "string", "version": 0, "created_at": "string" } ], "next_cursor": "string", "has_more": true}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Header Parameters
Required by the API on this route (400 idempotency_key_required without it); the official clients generate a UUID when you omit it.
1 <= length <= 255Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/reward_issuances" \ -H "Content-Type: application/json" \ -d '{ "reward_id": "rw_123", "customer_id": "cust_123" }'{ "id": "string", "reward_id": "string", "customer_id": "string", "status": "issued", "source_type": "rule_execution", "source_id": "string", "cost_entry_id": "string", "expires_at": "string", "redeemed_at": "string", "cancelled_at": "string", "version": 0, "created_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/reward_issuances/string"{ "id": "string", "reward_id": "string", "customer_id": "string", "status": "issued", "source_type": "rule_execution", "source_id": "string", "cost_entry_id": "string", "expires_at": "string", "redeemed_at": "string", "cancelled_at": "string", "version": 0, "created_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/reward_issuances/string/redeem"{ "id": "string", "reward_id": "string", "customer_id": "string", "status": "issued", "source_type": "rule_execution", "source_id": "string", "cost_entry_id": "string", "expires_at": "string", "redeemed_at": "string", "cancelled_at": "string", "version": 0, "created_at": "string"}Authorization
bearer Secret key (osk_…), publishable key (opk_…) or personal access token (opat_…).
In: header
Path Parameters
1 <= lengthRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/reward_issuances/string/cancel" \ -H "Content-Type: application/json" \ -d '{}'{ "id": "string", "reward_id": "string", "customer_id": "string", "status": "issued", "source_type": "rule_execution", "source_id": "string", "cost_entry_id": "string", "expires_at": "string", "redeemed_at": "string", "cancelled_at": "string", "version": 0, "created_at": "string"}