Coupons
Update coupon
/ v1 / coupons / {coupon_id} Changes the fields that you send.
statusarchivedswitches the code off. The Tentary app calls this "delete".activeswitches it on again.nullremovesstarts_on,ends_onormax_uses.
The fields have the same names and formats as in GET /v1/coupons.
Authorization
-
Authorizationstring header requiredBearer tnt_…· A personal API key (tnt_...). Create it in the Tentary app on the page AI & API. Introduction
Path parameters
-
coupon_idinteger requiredThe id from list_coupons.
min
1Example:702
Body application/json
-
statusstringarchived = switched off. active = on again.
Allowed values:
activearchived -
codestringThe code buyers type, like SUMMER20. Unique in the shop (upper and lower case count as the same).
min length
1max length255 -
percentinteger can be nullDiscount in percent. Give percent or amount.
min
1max100 -
amountnumber | string can be nullFixed discount. Amount in the account currency, like 49 or 19.99.
above
0pattern^[0-9]{1,9}(\.[0-9]{1,2})?$ -
max_usesinteger can be nullHow often the code can be used in total. 0 = no limit. On create, left out = no limit. On update, left out = no change, null removes the limit.
min
0 -
starts_onstring can be nullFirst day the code works, like 2026-11-27. On create, left out = at once. On update, left out = no change, null removes the date.
pattern
^[0-9]{4}-[0-9]{2}-[0-9]{2}$ -
ends_onstring can be nullThe code stops at the start of this day (00:00). On create, left out = no end. On update, left out = no change, null removes the date.
pattern
^[0-9]{4}-[0-9]{2}-[0-9]{2}$ -
product_idsarray of integer can be nullOnly these products (ids from list_products). null = all products. On create, left out = all products. On update, left out = no change. [] = no product (the code works nowhere).
max items
200
Response
Fields of the answer with status 200. Errors always have the same format, see Errors.
-
idintegerThe ID.
-
codestringThe code buyers type.
-
statusstringWhat the seller set. archived = deleted.
Allowed values:
activearchived -
statestringThe result for buyers: valid = buyers can use the code now.
Allowed values:
validscheduledexpiredused_upreservedarchivedno_products -
percentinteger can be nullDiscount in percent, or null for a fixed amount.
-
amountstring can be nullDecimal string, like "19.90". Fixed discount, or null for a percent discount.
-
currencystringCurrency code, like EUR.
-
usedintegerHow often the code was used.
-
max_usesinteger can be nullnull = no limit.
-
reserved_in_open_checkoutsintegerUses held by open checkouts of the last hour.
-
starts_onstring<date> can be nullLike 2026-01-31. First day the code works.
-
ends_onstring<date> can be nullLike 2026-01-31. The code stops at the start of this day.
-
product_idsarray of integer can be nullnull = all products. [] = no product.
-
productsarray of objectThe products of product_ids (the first 200).
Show 3 fields Hide fields
-
idintegerThe ID.
-
namestring can be nullThe name.
-
statusstringThe status.
Allowed values:
livedraftarchiveddeleted
-
-
created_atstring<date-time> can be nullUTC, like 2026-01-31T14:05:00Z.
-
admin_urlstring<uri>The page in the Tentary app.