Skip to main content
GET
/
v1
/
coupons
/
{id}
Get Coupon
curl --request GET \
  --url https://api.withflex.com/v1/coupons/{id} \
  --header 'Authorization: Bearer <token>'
{
  "coupon": {
    "coupon_id": "fcoup_1234567890",
    "amount_off": 0,
    "applies_to": {},
    "duration": "once",
    "duration_in_months": 0,
    "metadata": {},
    "name": "Example",
    "percent_off": 0,
    "max_redemptions": 0,
    "times_redeemed": 0,
    "valid": false,
    "created_at": "2024-01-01T00:00:00Z",
    "test_mode": false
  }
}

Authorizations

Authorization
string
header
required

Use a Bearer token to access this API.

Path Parameters

id
string
required
Example:

"obj_01EXAMPLE00000000000000000"

Response

Success

coupon
object
required

A coupon contains information about a percent-off or amount-off discount you might want to apply to a customer. Coupons may be applied to subscriptions and checkout sessions.

Example:
{
"coupon_id": "fcoup_1234567890",
"amount_off": 0,
"applies_to": { "products": ["string"] },
"duration": "once",
"duration_in_months": 0,
"metadata": {},
"name": "Example",
"percent_off": 0,
"max_redemptions": 0,
"times_redeemed": 0,
"valid": false,
"created_at": "2024-01-01T00:00:00Z",
"test_mode": false
}