Rabattcodes
Coupons
/ v1 / coupons The coupons (discount codes), newest first: code, status, state, percent or amount, uses and use limit, start and end day, the products they apply to (with their status live, draft, archived or deleted), and admin links.
status is what you set: active or archived. Without status, the list has active coupons only. Archived coupons are deleted coupons.
state is the result for buyers, and read only:
valid: buyers can use the code now.scheduled: the start is in the future.expired: the end is in the past.used_up: the use limit is reached.archived: deleted.no_products: the coupon applies to no live product. The checkout sells only live products.reserved: open checkouts of the last hour hold the remaining uses. They become free again if the buyers do not pay.
The fields have the same names and formats as in POST /v1/coupons and PATCH /v1/coupons/{coupon_id}.
Autorisierung
-
Authorizationstring Header erforderlichBearer tnt_…· A personal API key (tnt_...). Create it in the Tentary app on the page AI & API. Einführung
Query-Parameter
-
statusstringactive (default) or archived.
Mögliche Werte:
activearchived -
cursorstringnext_cursor of the previous page. Send the same filters and limit again: the cursor does not keep them. Leave out for the first page.
-
limitintegerItems per page, default 25.
min.
1max.50
Antwort
Felder der Antwort mit Status 200. Fehler haben immer dasselbe Format, siehe Fehler.
-
couponsarray of objectNewest first.
16 Felder anzeigen Felder ausblenden
-
idintegerThe ID.
-
codestringThe code buyers type.
-
statusstringWhat the seller set. archived = deleted.
Mögliche Werte:
activearchived -
statestringThe result for buyers: valid = buyers can use the code now.
Mögliche Werte:
validscheduledexpiredused_upreservedarchivedno_products -
percentinteger kann null seinDiscount in percent, or null for a fixed amount.
-
amountstring kann null seinDecimal string, like "19.90". Fixed discount, or null for a percent discount.
-
currencystringCurrency code, like EUR.
-
usedintegerHow often the code was used.
-
max_usesinteger kann null seinnull = no limit.
-
reserved_in_open_checkoutsintegerUses held by open checkouts of the last hour.
-
starts_onstring<date> kann null seinLike 2026-01-31. First day the code works.
-
ends_onstring<date> kann null seinLike 2026-01-31. The code stops at the start of this day.
-
product_idsarray of integer kann null seinnull = all products. [] = no product.
-
productsarray of objectThe products of product_ids (the first 200).
3 Felder anzeigen Felder ausblenden
-
idintegerThe ID.
-
namestring kann null seinThe name.
-
statusstringThe status.
Mögliche Werte:
livedraftarchiveddeleted
-
-
created_atstring<date-time> kann null seinUTC, like 2026-01-31T14:05:00Z.
-
admin_urlstring<uri>The page in the Tentary app.
-
-
next_cursorstring kann null seinSend it as cursor for the next page, with the same filters and limit. null = this is the last page.
-
linksobjectPages in the Tentary app or on tentary.com.
2 Felder anzeigen Felder ausblenden
-
couponsstring<uri>Page in the Tentary app.
-
new_couponstring<uri>Page in the Tentary app.
-