coupon_code
Collection: coupon_codes
Coupon codes are configured for each coupon you set up. They are unique codes to be used by your customers to obtain the coupon's discount.
If you would like to create multiple coupon codes at once, see the coupon documentation.
Required Scopes
Full
store_full_access
Read
coupons_read
Write
coupons_write Actions
GET View a coupon code
PATCH Update a coupon code (send only the properties you want to modify)
PUT Replace a coupon code (send the entire representation)
DELETE Delete a coupon code
HEAD Get just the header response
OPTIONS Get a response explaining which HTTP methods are supported
Properties (4)
code String · Required · max 50 The string value of this coupon code which your customer will add to their cart to use this coupon.
number_of_uses_to_date Number · Read-only For informational purposes, this shows you how many times this coupon code has already been used.
date_created String (nullable) · Read-only The date this resource was created.
date_modified String (nullable) · Read-only The date this resource was last modified.
Link Relations (4)
self This Coupon Code https://api.foxycart.com/coupon_codes/{id}
Available via
fx:coupon_code on applied_coupon_code·fx:coupon_code on coupon_code_transaction·fx:coupon_code on coupon_detail·fx:coupon_code on discount Example Representation
{
"_links": {
"curies": [
{
"name": "fx",
"href": "https://api.foxycart.com/rels/{rel}",
"templated": true
}
],
"self": {
"href": "https://api.foxycart.com/coupon_codes/123",
"title": "This Coupon Code"
},
"fx:store": {
"href": "https://api.foxycart.com/stores/456",
"title": "This Store"
},
"fx:coupon": {
"href": "https://api.foxycart.com/coupons/999",
"title": "This Coupon"
},
"fx:coupon_code_transactions": {
"href": "https://api.foxycart.com/coupon_codes/123/transactions",
"title": "Transactions using this Coupon Code"
}
},
"code": "test",
"number_of_uses_to_date": 31,
"date_created": null,
"date_modified": null
}