Create a coupon
POST {{baseUrl}}/v1/coupons
You can create coupons easily via the coupon management page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.
A coupon has either a percent_off
or an amount_off
and currency
. If you set an amount_off
, that amount will be subtracted from any invoice’s subtotal. For example, an invoice with a subtotal of amount_off
of amount_off
of
Request Body
[{"name"=>"amount_off", "value"=>"<integer>", "datatype"=>"string"}, {"name"=>"applies_to[products][0]", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"applies_to[products][1]", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"currency", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"duration", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"duration_in_months", "value"=>"<integer>", "datatype"=>"string"}, {"name"=>"expand[0]", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"expand[1]", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"id", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"max_redemptions", "value"=>"<integer>", "datatype"=>"string"}, {"name"=>"name", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"percent_off", "value"=>"<number>", "datatype"=>"string"}, {"name"=>"redeem_by", "value"=>"<unix-time>", "datatype"=>"string"}]
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string |