jboga
jboga

Reputation: 219

Set webhook for incoming messages on Twilio-Whatsapp phone number

We have a Twilio phone number that's Whatsapp-capable. When trying to programmatically set the webhook for incoming messages, the webhook is correctly set but messages are not coming through.

It appears that the webhook for Whatsapp phone number lives in a different place than the one for normal phone numbers.

To manually fix this we had to go into the Twilio console -> Programmable SMS -> Whatsapp -> Senders -> select our phone number -> paste the webhook URL and save.

So the question is: is there a way to programmatically (Twilio API) set the webhook for Whatsapp phone number?

Thanks,

Upvotes: 2

Views: 2170

Answers (2)

Duncan
Duncan

Reputation: 226

It looks like Twilio now supports programmatically updating the inbound SMS urls.

You can find the resource here on how to do it.

https://www.twilio.com/docs/phone-numbers/api/incomingphonenumber-resource#update-an-incomingphonenumber-resource

Upvotes: 1

stefan judis
stefan judis

Reputation: 3889

Heyo Twilio Developer Evangelist here. 👋

I checked with the team and unfortunately, setting the webhook URL programmatically is not possible right now. The console is the only place to do it today.

Upvotes: 2

Related Questions