Kund:innen und Zugänge
Grant access
/ v1 / access / grant Gives a person access to a live product without an order: no payment and no invoice. For example a gift, or a purchase on another platform.
- Creates the customer if needed. A customer created this way counts toward the plan limit of external customers until they buy.
- The person gets an email with the access link, unless
send_emailisfalse. - It does not subscribe the person to the newsletter.
- Not possible for booking, newsletter and external products.
Autorisierung
-
Authorizationstring Header erforderlichBearer tnt_…· A personal API key (tnt_...). Create it in the Tentary app on the page AI & API. Einführung
Body application/json
-
emailstring erforderlichThe customer's e-mail address.
min. Länge
3max. Länge255 -
product_idinteger erforderlichThe id from list_products.
min.
1 -
variant_idintegerNeeded for a product with variants (get_product shows them).
min.
1 -
first_namestringFor a new customer.
max. Länge
100 -
last_namestringFor a new customer.
max. Länge
100 -
reasonstringShown in the app. Default manual.
Mögliche Werte:
manualcomplimentarypurchased_elsewhere -
send_emailbooleanSend the access e-mail (default true).
Antwort
Felder der Antwort mit Status 200. Fehler haben immer dasselbe Format, siehe Fehler.
-
statusstringexists and purchased: the customer had access already, so no grant was added. A deactivated customer is still reactivated: see customer.reactivated.
Mögliche Werte:
createdreactivatedexistspurchased -
messagestringWhat happened, in words for the seller.
-
grant_idinteger kann null seinThe ID of the access grant.
-
customerobjectThe customer.
4 Felder anzeigen Felder ausblenden
-
idintegerThe ID.
-
emailstringE-mail address.
-
createdbooleantrue = a new customer.
-
reactivatedbooleantrue = a deactivated customer was reactivated.
-
-
productobjectThe product.
3 Felder anzeigen Felder ausblenden
-
idintegerThe ID.
-
namestringThe name.
-
variant_idinteger kann null seinThe variant ID, if any.
-
-
access_emailstringqueued = the e-mail with the access link goes out in the next minutes. suppressed = the address bounced before.
Mögliche Werte:
queuedsuppressednot_sent