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 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it.

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

KeyDatatypeRequiredDescription
Content-Typestring