Coupons

List a project's coupons

curl "https://api.subscriby.net/v1/projects/7f3d1c92-8b45-4e6a-9d21-5c8e0a4b6f13/coupons?active=true&per_page=25&page=1" \
  -H "Authorization: Bearer sbt_..."

Pages the project's coupons, newest first. active filters on the creator's on/off switch only; code finds one exact code.

active=true is not the same as redeemable. A coupon can be switched on and still not apply: outside its window, fully claimed, or capped for that subscriber. Read redeemable on each row for the combined answer.

get/v1/projects/{project}/coupons

Request

  • Base URL: https://api.subscriby.net
  • URL: https://api.subscriby.net/v1/projects/{project}/coupons
  • Auth: HTTP bearer

Path parameters

projectstring uuid required

The project, resolved by the route binder.

Query parameters

activeboolean

Keep only coupons whose on/off switch is in this position. Not the same as redeemable: read redeemable on each row for the combined answer.

codestring

Find one coupon by its exact code, compared in upper case.

pageinteger

The 1-based page to return. A page past the last answers an empty data array with meta.total still filled, so a loop can stop without guessing.

per_pageinteger

Rows per page, 1 to 100. A higher value clamps to the cap silently. Defaults to 25.

sort_bystring

The column to order by. Defaults to created_at; a column the endpoint does not offer falls back to the default rather than failing.

sort_direction'asc' | 'desc'

asc or desc. Defaults to desc.

Response

The page.

Example response

{
  "data": [
    {
      "id": "4b9d3e08-a1f6-4275-9c83-7e01d6a2f594",
      "project_id": "7f3d1c92-8b45-4e6a-9d21-5c8e0a4b6f13",
      "code": "BLACKFRIDAY",
      "name": "Black Friday 2026",
      "discount": {
        "type": "percentage",
        "value": "25.0000"
      },
      "duration": "once",
      "limits": {
        "max_redemptions": 500,
        "max_redemptions_per_user": 1
      },
      "redemptions": {
        "count": 137,
        "remaining": 363
      },
      "window": {
        "starts_at": "2026-11-27T00:00:00+00:00",
        "expires_at": "2026-12-01T00:00:00+00:00"
      },
      "active": true,
      "redeemable": true,
      "created_at": "2026-11-20T09:14:02+00:00",
      "updated_at": "2026-11-24T16:41:11+00:00"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.