Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can I retrieve the location of a phone number with Twilio?

I'm working on a project that uses the Twilio API to send and receive text messages, but I'd like to be able to show the location of those cellular users in a table on my customer's dashboard.

In short, I'm looking for the data that shows up when you're shopping for a phone number on Twilio and it tells you it's from Newport Beach, California, etc.

Is there any way to retrieve that information from Twilio for a number besides one that is available for purchase?

like image 548
Steven Sokulski Avatar asked Sep 04 '25 04:09

Steven Sokulski


1 Answers

Twilio Evangelist here. When Twilio makes a request to your server using a web hook, the SMS and voice will sometimes have geographical information.

  • FromCity
  • FromState
  • FromZip
  • FromCountry

But this information is not always available. There is no facility in the API to allow you to look up these outside of this context.

Hope this helps!

like image 198
xmjw Avatar answered Sep 07 '25 17:09

xmjw