Trigger a campaign for specific recipients
curl --request POST \ --url https://rocketem.fotone.io/api/v2/campaigns/example/trigger \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "email": "hello@example.com", "data": {}, "language": "example" }'Required scope: campaigns:trigger
Send a trigger campaign to one or more recipients. The campaign must be
of type trigger and have mail_status: trigger_active.
Supports single recipient (email + data) or batch mode (recipients array, max 100).
Each recipient can include personalization data that is available as merge tags:
the keys of data are used flat ({first_name}), values are HTML-escaped when
inserted. data may be at most 64 KB per recipient (payload_too_large).
A campaign created as an API send does not take this call (use_messages_endpoint):
its mails are handed in one by one with POST /campaigns/{campaignId}/messages.
Authorizations
Abschnitt betitelt „Authorizations“Parameters
Abschnitt betitelt „Parameters“Path Parameters
Abschnitt betitelt „Path Parameters“Campaign public_id
Header Parameters
Abschnitt betitelt „Header Parameters“Unique key for idempotent requests. Responses cached 24h.
Request Bodyrequired
Abschnitt betitelt „Request Bodyrequired“object
Recipient email
Personalization data (available as merge tags)
object
Language code (de, en, fr)
object
object
object
Example generated
{ "email": "hello@example.com", "data": {}, "language": "example"}Responses
Abschnitt betitelt „Responses“Trigger result
object
object
Number of recipients successfully queued
Number of recipients skipped
object
deferred (reason retry_later): a suppression check was temporarily unavailable — nothing was sent; send this recipient again later.
Why a recipient was skipped (e.g. blacklisted:unsubscribe, hard_bounce, not_in_audience)
Example
{ "data": { "details": [ { "status": "queued" } ] }}Missing scope or trigger mails not in the plan (feature_not_available)
object
object
Example generated
{ "error": { "code": "example", "message": "example", "status": 1 }}Resource not found
object
object
Example generated
{ "error": { "code": "example", "message": "example", "status": 1 }}Campaign is not a trigger campaign, not active, an API send (use_messages_endpoint) or an e-mail of an automation (owned_by_automation: start the automation with POST /automations/trigger)
object
object
Example generated
{ "error": { "code": "example", "message": "example", "status": 1 }}