1
votes

I am using Twilio to forward incoming SMS to email, using a self-hosted php webhook page, which sends the SMS as an email.

I'd like to include some info from the Twilio account/number in the webhook params - specifically the Twilio "Friendly Name" for the number. And if it's possible, additional user-configurable text for the number (though I don't see anywhere I could configure any more info).

Is "Friendly Name" (and other acct info) available to add to the webhook URL?

1

1 Answers

2
votes

The best way to look at the Webhook URL parameters is send them to a tool like Ngrok, and then use the Ngrok Debug (http://127.0.0.1:4040) to view them.

You can pull the Friendly Name using the IncomingPhoneNumbers API or better yet, send the friendlyName as a URL query parameter at the end of your webhook.

AccountSid
AddOns
ApiVersion
Body
From
FromCity
FromCountry
FromState
FromZip
MessageSid
NumMedia
NumSegments
SmsMessageSid
SmsSid
SmsStatus
To
ToCity
ToCountry
ToState
ToZip