Posts Tagged ‘TwiML’
Send an SMS from a Twilio sim via Programmable SMS
Send an SMS from a Twilio sim via Programmable SMS to the outside world.
Enter this as TwiML in the SMS section of the ‘Progammable Voice and SMS’ in the settings menu for your sim.
<?xml version="1.0" encoding="UTF-8"?> <Response> <!-- The from tag contains the phone number assigned to the sim --> <Message from="+19195551212" to="{{To}}"> {{Body}} </Message> </Response>
Forward SMS to multiple phone numbers with TwiML Bin
Other parameters are possible like {{FromCity}} and {{FromState}}. You can forward to multiple numbers by duplicating the Message tag.
More details here:
https://www.twilio.com/docs/sms/twiml
<?xml version="1.0" encoding="UTF-8"?> <Response> <Message to="+16623458765">Twilio: {{From}}: {{Body}}</Message> <Message to="+15033943032">Twilio: {{From}}: {{Body}}</Message> </Response>