SMS to Email trunk#
An SMS to Email trunk forwards incoming SMS messages from your Direct Inward Dialing (DID) numbers directly to a specified email address. Each message is converted and delivered as a standard email. The trunk settings define the recipient email address and the subject and body of each forwarded email.
How SMS delivery to email works#
When someone sends an SMS to one of your DID numbers, DIDWW uses the SMS trunk assigned to that number to determine where to deliver the message. For an SMS to Email trunk, DIDWW converts the message into an email and sends it to the trunk’s Recipient email address.
%%{init: {
"theme": "base",
"themeVariables": {
"fontSize": "14px",
"primaryColor": "#e0f2fe",
"primaryBorderColor": "#38bdf8",
"primaryTextColor": "#1f2d3d",
"secondaryColor": "#ccfbf1",
"secondaryBorderColor": "#2dd4bf",
"secondaryTextColor": "#1f2d3d",
"lineColor": "#0066cc",
"textColor": "#1f2d3d",
"nodeTextColor": "#1f2d3d",
"edgeLabelBackground": "#ffffff"
}
}}%%
flowchart LR
sender["SMS sender"] --> |sends SMS| did["DID number"]
did --> |assigned trunk| trunk["SMS to Email trunk"]
trunk --> |converts SMS to email| mailbox["Recipient mailbox"]
classDef endpoint fill:#e0f2fe,stroke:#0066cc,color:#1f2d3d,stroke-width:1.5px
classDef process fill:#ccfbf1,stroke:#2dd4bf,color:#1f2d3d,stroke-width:1.5px
class sender,mailbox endpoint
class did,trunk process
linkStyle default stroke:#0066cc,stroke-width:1.5px
For the sender address of forwarded emails and how to keep them from being filtered as spam, see SMS to Email delivery in the Inbound SMS guidelines.
Email subject and body#
The Email subject and Email body settings are templates for each
forwarded email. Variables in the templates are replaced with the details of
the received SMS. For example, {SMS_SRC_ADDR} inserts the sender
address, {SMS_DST_ADDR} inserts the DID number that received the message,
and {SMS_TEXT} inserts the message text. For all available variables, see
Email subject and body variables.
A long SMS that the sender’s network splits into several parts is delivered as one email. The email contains the complete, reassembled message text. Each part is still billed as a separate fragment. For encoding limits, concatenation, and fragment billing, see SMS encoding reference.
When to use an SMS to Email trunk#
Use an SMS to Email trunk when incoming messages should arrive in an email inbox and you do not want to run an HTTP endpoint or an SMPP connection to receive them.
If your application should receive messages directly, use an HTTP IN trunk, which delivers each message as an HTTP request, or an SMPP ESME trunk or SMPP SMSC trunk, which exchange messages over SMPP. To compare all SMS trunk types, including trunks for sending SMS, see SMS trunks.
SMS to Email trunks and DID numbers#
A DID number receives the SMS, while the SMS to Email trunk defines where and
how the message is forwarded by email. To receive messages, assign the
trunk or an SMS trunk group containing it to one or more DID numbers that support inbound SMS. Multiple DID numbers can use
the same trunk. The default email subject includes {SMS_DST_ADDR}, so each
email shows which DID number received the message.
SMS to Email trunks and trunk groups#
To enable failover, add the trunk to an existing SMS trunk group and assign the group to your DID numbers. Within the trunk group, the trunk’s Priority determines the order in which trunks are used. The system attempts to contact the target SMS trunk with the highest-numbered priority first.
Get started#
Create a trunk, assign it to your DID numbers, and test delivery to your mailbox.
Set the recipient email address and the email subject and body, then create the trunk.
Assign the SMS to Email trunk or its trunk group to one or more DID numbers.
Send an SMS to an assigned DID number and review its delivery in Inbound SMS logs.
Manage trunks and email content#
Update existing trunks and customize the forwarded email.
Edit trunk settings or delete trunks that are no longer required.
Look up the variables that insert the sender, DID number, time, and message text into the forwarded email.
SMS trunk groups#
Use these guides when the trunk will share message delivery with other SMS trunks.
Group existing SMS trunks and assign the group to DID numbers.
Set the order in which the trunks in a group are attempted.
Understand how trunk groups provide failover for inbound SMS.
Technical references#
Find field definitions, variables, and trunk group settings for SMS to Email trunks.
Check the sender address of forwarded emails and allow it in your email system.
Review encoding limits, concatenation, and fragment billing.