API

Guides

Messages

Voice

WhatsApp Business

Groups

Contacts

Outbox

Account

Sender IDs

Teammate/Subaccount

Conversations

Workflows

Message Templates

Birthday Message

Opt-out

Other

Webhooks (v2)

Workflow actions

data.config.actionType of an action node. Fields marked tpl accept {{ placeholders }} from the payload (see Triggers). Every action reports what it did in the execution result (see Executions).

send_sms

Sends an SMS.

{ "id": "reply", "type": "actionNode",
  "data": { "title": "Auto-reply", "config": { "actionType": "send_sms", "messageType": "reply_message",
    "message": "Thanks for your message, we are closed right now and will reply tomorrow." } } }

{ "id": "notify", "type": "actionNode",
  "data": { "title": "Notify sales", "config": { "actionType": "send_sms", "messageType": "new_message",
    "sender": "SMSTools", "receiver": "32470123456", "message": "New lead: {{ contact.phone }} wrote {{ message.body }}" } } }
Key Values Description
messageTypenew_message (default) / reply_message / trigger_contactnew_message: to receiver (or contact.phone) with sender. reply_message: reply to the triggering message from the inbox number it arrived on. trigger_contact: to contact.phone with sender.
sendermax. 17 charactersSender ID or number.
receiverphone number, optionalEmpty = contact.phone of the payload.
messagetpl, required, max. 1600 charactersText of the message.
channeloptionalChannel hint from the builder.

send_whatsapp_template

Sends an approved WhatsApp Business template; works outside the 24-hour window.

{ "id": "welcome", "type": "actionNode",
  "data": { "title": "Welcome template", "config": { "actionType": "send_whatsapp_template",
    "wabaId": "123456789012345", "sender": "32460123456",
    "templateName": "welcome_message", "templateLanguage": "en_US", "templateCategory": "utility",
    "templateParameterFormat": "POSITIONAL", "headerType": "none",
    "bodyParams": [ { "variable": "1", "value": "{{ contact.firstname }}" } ] } } }
Key Values Description
wabaIdWhatsApp Business account IDThe account the template belongs to.
senderWhatsApp number of that accountNumber to send from.
receiverphone number, optionalEmpty = contact.phone.
templateNamerequiredName of the template.
templateId, templateLanguage, templateCategorye.g. en_US; utility / marketing / authenticationTemplate details as in List WhatsApp templates.
templateParameterFormatPOSITIONAL (default) / NAMEDHow the template expects its parameters.
headerType, headerUrlnone (default) / text / image / video / documentHeader of the template and the media URL for media headers.
bodyParamslist of { variable, value } (tpl)Values for the body parameters.
messageTypeoptionalSame meaning as for send_sms.

send_whatsapp_message

Sends a free-form WhatsApp message to contact.phone. Only possible inside the 24-hour customer service window; outside it the message is not sent and the fallback handle is followed, so you can connect a send_whatsapp_template or send_sms node there.

{ "id": "wa_reply", "type": "actionNode",
  "data": { "title": "WhatsApp reply", "config": { "actionType": "send_whatsapp_message",
    "message": "Hi {{ contact.firstname }}, thanks for reaching out!" } } }

"edges": [
	{ "id": "e4", "source": "wa_reply", "sourceHandle": "out",      "target": "assign" },
	{ "id": "e5", "source": "wa_reply", "sourceHandle": "fallback", "target": "welcome" }
]
Key Values Description
messagetpl, required, max. 4096 charactersText of the message.

forward

Forwards the triggering inbound message.

{ "id": "forward", "type": "actionNode",
  "data": { "title": "Forward to support", "config": { "actionType": "forward", "forwardMethod": "email", "receiver": "[email protected]" } } }
Key Values Description
forwardMethodemail (default) / sms / sms_groupForward by e-mail, by SMS to one number or by SMS to a group.
receivere-mail address or phone numberFor email and sms.
groupidgid_...For sms_group.
inboxMessageIdoptionalInbound message to forward; empty = the triggering message.

http_webhook

Calls a URL of your own with the payload data. The request times out after 15 seconds.

{ "id": "crm", "type": "actionNode",
  "data": { "title": "Push to CRM", "config": { "actionType": "http_webhook",
    "method": "POST", "url": "https://crm.example.com/api/leads",
    "authType": "bearer", "authToken": "my-secret-token",
    "headers": [ { "key": "X-Source", "value": "smstools" } ],
    "bodyType": "form",
    "bodyFields": [ { "key": "phone", "value": "{{ contact.phone }}" }, { "key": "message", "value": "{{ message.body }}" } ] } } }
Key Values Description
methodGET / POST (default) / PUT / PATCH / DELETEHTTP method.
urltpl, required, http(s)The URL to call.
authTypenone (default) / bearer / basic / api_key_header / api_key_queryAuthentication.
authTokentplToken for bearer.
authUsername, authPasswordtplCredentials for basic.
authKeyName, authKeyValuetplHeader or query parameter for the API-key types.
headers, queryParamslists of { key, value } (tpl)Extra headers and query parameters.
bodyTypejson (default) / formHow the body is encoded.
bodyJsonraw JSON string, tplBody for json.
bodyFieldslist of { key, value } (tpl)Body for form.

contact

Adds, loads, updates or removes the contact with contact.phone in one of your groups. get loads the contact into the payload for the nodes that follow.

{ "id": "save", "type": "actionNode",
  "data": { "title": "Save as lead", "config": { "actionType": "contact", "editMethod": "add",
    "groupid": "gid_3520a1ec234dbabe1232def67e858855",
    "updateFields": { "firstname": "{{ contact.firstname }}", "extra1": "{{ message.body }}" } } } }
Key Values Description
editMethodadd (default) / get / update / removeWhat to do.
groupidgid_...Required for add, update and remove.
updateFieldsobjectAny of firstname, lastname, extra1 .. extra8, birthdate (YYYY-MM-DD or DD/MM/YYYY) for add and update.

opt_out

Opts the contact with contact.phone out (or back in).

{ "id": "opt_out", "type": "actionNode",
  "data": { "title": "Opt out", "config": { "actionType": "opt_out", "editMethod": "opt_out" } } }
Key Values Description
editMethodopt_out (default) / opt_in / add / removeadd = opt out, remove = opt back in.
groupidgid_..., optionalLimit the opt-out to one group.

get_contact

Loads a contact into the payload (contact.*), for example at the start of a cron workflow or to enrich an inbound message with the contact's name and extra fields.

{ "id": "load", "type": "actionNode",
  "data": { "title": "Load contact", "config": { "actionType": "get_contact", "lookupBy": "phone_from_payload" } } }

{ "id": "pick", "type": "actionNode",
  "data": { "title": "Random winner", "config": { "actionType": "get_contact", "lookupBy": "group_random", "groupId": "gid_3520a1ec234dbabe1232def67e858855" } } }
Key Values Description
lookupByphone_from_payload (default) / phone_from_payload_in_group / phone / group_first / group_randomBy the phone number of the payload, by that number within a group, by a fixed number, or the first / a random contact of a group.
phoneValuephone numberFor phone.
groupIdgid_...For the group variants.

wait

Parks the execution (status waiting) and resumes it later with the same version of the workflow, for example to send a follow-up the next morning.

{ "id": "wait", "type": "actionNode",
  "data": { "title": "Wait until morning", "config": { "actionType": "wait", "waitMode": "until_time", "untilTime": "09:00", "timezone": "Europe/Brussels" } } }

{ "id": "wait", "type": "actionNode",
  "data": { "title": "Wait 2 days", "config": { "actionType": "wait", "waitMode": "duration", "durationValue": 2, "durationUnit": "days" } } }
Key Values Description
waitModeduration (default) / until_timeWait a fixed time, or until a time of day.
durationValueinteger, 1 or more, default 30How long, for duration.
durationUnitseconds / minutes (default) / hours / days / weeks / monthsUnit of durationValue.
untilTimeHH:MMFor until_time.
timezoneIANA name, default Europe/BrusselsTime zone of untilTime.

assign_conversation

Hands the conversation of contact.phone to a team member, exactly like the Conversations endpoints do. Meant for the inbound_message and delivery_report triggers; without contact.phone in the payload the action is skipped.

{ "id": "assign", "type": "actionNode",
  "data": { "title": "Assign to support", "config": { "actionType": "assign_conversation",
    "assignMode": "round_robin",
    "teamMembers": [ "sub_3520a1ec234dbabe1232def67e858855", "sub_9b74c9897bac770ffc029102a200c5de" ],
    "onlyIfUnassigned": true, "status": "open" } } }
Key Values Description
assignModefixed (default) / round_robinfixed always assigns to teamMember. round_robin takes turns over teamMembers: the member whose most recent assignment is the oldest is next; members without any assignment come first, in list order.
teamMembersub_...Required for fixed.
teamMemberslist of sub_...At least one for round_robin.
onlyIfUnassignedboolean, default falseWhen true and the conversation already has an assignee, the action is skipped and reports the current assignee.
statusopen / pending / nullAlso set the conversation status after assigning; null leaves it as it is.

SMS API

Smstools
Mit unserer SMS Gateway API können Sie Ihre eigene Software mit unserem SMS-Gateway API verbinden. Direkt Loslegen. SMS API
5 aus 5 basierend auf 3303 Benutzerbewertungen.
SMSGATEWAYAPI API1

REGISTRIEREN

Entdecken Sie jetzt unsere SMS-Plattform!

REGISTRIEREN