Twilio SMS
Use this node to send SMS messages via the Twilio messaging service — for example, alerting a field technician’s mobile when a device alarm is raised, or sending an automated status update to a manager’s phone number stored in device metadata.
Configuration
Section titled “Configuration”- Number From — required. Twilio sender phone number in E.164 format (e.g.,
+19995550123). Supports templatization. - Numbers To — required. Comma-separated recipient phone numbers. Supports templatization.
- Account SID — required. Twilio account identifier.
- Account Token — required. Twilio authentication token.
The message content is taken from the incoming message data (outer quotes and \n escape sequences are handled automatically).
Message processing algorithm
Section titled “Message processing algorithm”- Resolve sender and recipient phone numbers from the configuration templates.
- Send an SMS to each resolved recipient using the Twilio API with the incoming message data as the body.
- Route via
Successon delivery. Message data and metadata are not modified. - Route via
Failureon unexpected error.
Output connections
Section titled “Output connections”| Connection | Condition |
|---|---|
Success | SMS sent to all recipients successfully. |
Failure | Invalid credentials, Twilio API error, or unexpected error. |
Examples
Section titled “Examples”Example 1 — Send alert SMS from metadata phone
Section titled “Example 1 — Send alert SMS from metadata phone”Data: "High temperature detected: 85°C" | Metadata: { "techPhone": "+15551234567" }.
{ "numberFrom": "+19995550123", "numbersTo": "${techPhone}", "accountSid": "ACxxxxxxxx", "accountToken": "your_token"}Result: SMS "High temperature detected: 85°C" sent to +15551234567. Routes via Success.
JSON schema
Section titled “JSON schema”{ "$schema": "https://json-schema.org/draft/2020-12/schema", "title": "TbTwilioSmsNodeConfiguration", "type": "object", "required": ["numberFrom", "numbersTo", "accountSid", "accountToken"], "additionalProperties": false, "properties": { "numberFrom": { "type": "string" }, "numbersTo": { "type": "string" }, "accountSid": { "type": "string" }, "accountToken": { "type": "string" } }}