Discounts
A discount is a promo code customers can redeem at checkout. Discounts are managed in the dashboard. The Seller API supports listing, reading, and toggling them on or off.
GET /v1/discounts
List discounts for the server.
Tier: B · Auth: required · Idempotent: N/A
Query parameters
| Parameter | Type | Description |
|---|---|---|
active | boolean | Filter by active state. |
limit | integer | Page size (max 100, default 50). |
cursor | string | Pagination cursor. |
Request
curl "https://subscord.com/api/v1/discounts?active=true" \
-H "Authorization: Bearer ssk_live_..."Response — 200 OK
{
"data": [
{
"id": "7",
"code": "LAUNCH20",
"mode": "percentage",
"amountOff": null,
"percentOff": 20,
"startsAt": "2026-04-01T00:00:00.000Z",
"expiresAt": "2026-05-01T00:00:00.000Z",
"useLimit": 1000,
"perCustomerUseLimit": 1,
"minimumSpend": null,
"maximumSpend": null,
"active": true,
"paymentMethod": "any",
"usesCount": 312
}
],
"nextCursor": null
}GET /v1/discounts/{id}
Returns a single discount.
Tier: A · Auth: required · Idempotent: N/A
Path parameters
| Parameter | Type | Description |
|---|---|---|
id | integer | The discount ID. |
Request
curl https://subscord.com/api/v1/discounts/7 \
-H "Authorization: Bearer ssk_live_..."Response — 200 OK
Same shape as a single entry in the list response above.
PATCH /v1/discounts/{id}
Toggle a discount on or off. This is the only mutation on discounts — to change a code, amount, validity window, or use limits, edit the discount in the dashboard.
Tier: D · Auth: required · Idempotent: required (Idempotency-Key header)
Path parameters
| Parameter | Type | Description |
|---|---|---|
id | integer | The discount ID. |
Request body
| Field | Type | Description |
|---|---|---|
active | boolean | true to enable, false to disable. Sending the current value is a safe no-op. |
Request
curl https://subscord.com/api/v1/discounts/7 \
-X PATCH \
-H "Authorization: Bearer ssk_live_..." \
-H "Content-Type: application/json" \
-H "Idempotency-Key: discount-7-disable-2026-04-25" \
-d '{ "active": false }'Response — 200 OK
Returns the updated discount with active reflecting the new state.
Errors
| Status | Code | When |
|---|---|---|
| 400 | invalid_request | id is not an integer or active is missing/wrong type. |
| 404 | not_found | No discount with that ID exists for this server. |
Field reference
| Field | Type | Description |
|---|---|---|
id | string | Discount ID. |
code | string | The promo code customers enter. |
mode | string | "absolute" (fixed amount off) or "percentage" (percent off). |
amountOff | integer | null | Set when mode === "absolute". Amount off in minor units of the purchase currency (e.g. 500 = $5.00 off). null when mode === "percentage". See Conventions. |
percentOff | integer | null | Set when mode === "percentage". Whole-number percentage from 0 to 100. null when mode === "absolute". |
startsAt | string | null | UTC ISO 8601 timestamp when the discount becomes valid, or null for immediate validity. |
expiresAt | string | null | UTC ISO 8601 timestamp when the discount expires, or null for no expiry. |
useLimit | integer | null | Maximum total redemptions across all customers, or null for no limit. |
perCustomerUseLimit | integer | null | Maximum redemptions per customer, or null for no limit. |
minimumSpend | integer | null | Minimum order amount required for the discount to apply, in minor units. null if no minimum. |
maximumSpend | integer | null | Maximum order amount the discount applies to, in minor units. null if no cap. |
active | boolean | Whether the discount is currently usable at checkout. |
paymentMethod | string | Restricts where the discount applies. One of any, stripe, crypto. |
usesCount | integer | Total redemptions to date. |