E-Mails
Create e-mail campaign
/ v1 / email / campaigns Writes a newsletter (an email to subscribers, sent once) as a draft. It sends nothing.
- The account owner checks the draft at
admin_url. POST /v1/email/testsends a test to the account owner.POST /v1/email/campaigns/{campaign_id}/sendsends or schedules it after the account owner confirms.
The answer is the campaign, as in GET /v1/email/campaigns/{campaign_id}.
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
-
namestring erforderlichName in the Tentary app (subscribers do not see it).
min. Länge
1max. Länge255 -
subjectstringThe subject line. Takes %FIRST_NAME%, %FULL_NAME% and %EMAIL%.
max. Länge
255 -
body_htmlstringThe text as HTML: p, br, h1-h3, strong, em, u, del, ul, ol, li, blockquote, a (class "button" makes a button), img with a https src (the image_url from finish_image), span; style only color and background-color. Takes %FIRST_NAME%, %FULL_NAME% and %EMAIL%. Only https:// links, no link shorteners. Tentary adds the seller's design, imprint and unsubscribe link: do not write them.
max. Länge
65535 -
audiencestringWho gets it, always only contacts who subscribed to the newsletter: all_subscribers (default), all_buyers, all_non_buyers, subscribers_who_bought or subscribers_who_did_not_buy one of product_ids.
Mögliche Werte:
all_subscribersall_buyersall_non_buyerssubscribers_who_boughtsubscribers_who_did_not_buy -
product_idsarray of integerFor subscribers_who_bought and subscribers_who_did_not_buy: products from list_products.
min.
1max. Einträge200
Antwort
Felder der Antwort mit Status 200. Fehler haben immer dasselbe Format, siehe Fehler.
-
idintegerThe ID.
-
namestringName in the Tentary app.
-
subjectstringThe subject line.
-
body_htmlstringThe text as HTML.
-
audiencestringAlways only contacts who subscribed to the newsletter.
Mögliche Werte:
all_subscribersall_buyersall_non_buyerssubscribers_who_boughtsubscribers_who_did_not_buy -
product_idsarray of integerFor subscribers_who_bought and subscribers_who_did_not_buy.
-
statusstringThe status.
Mögliche Werte:
draftscheduledsendingsent -
send_atstring<date-time> kann null seinUTC, like 2026-01-31T14:05:00Z. null for a draft.
-
problems_before_sendingarray of stringFor a draft: what stops sending. Empty = it can be sent.
-
admin_urlstring<uri>The page in the Tentary app.