0

I am facing an issue in JavaScript: I want to get a Twilio account verification number from an API request.

Twilio Account SID: Axxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Twilio Auth Token: exxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

I read the Twilio documentation but I can't find any such API request. Which API request should I use to get Twilio account verification number??

Adrian Mole
  • 49,934
  • 160
  • 51
  • 83
devs1994
  • 21
  • 4
  • Please remove the screenshot so it doesn’t expose your token. Also change your token now that it is no longer secured. https://support.twilio.com/hc/en-us/articles/223136027-Auth-Tokens-and-How-to-Change-Them – Alan Aug 24 '20 at 08:46
  • ok sorry my mistake remove screenshot [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 24 '20 at 09:00

1 Answers1

0

It looks like doing an HTTPS GET request to https://verify.twilio.com/v2/Services with your account SID and Auth Token returns an object with an array of Verify Services. This doesn't appear to be documented.

Alan
  • 10,465
  • 2
  • 8
  • 9
  • thanks i try GET request to https://verify.twilio.com/v2/Services but it does not show my Twilio account phone # [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 24 '20 at 12:29
  • No array of Verify Services display [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 24 '20 at 12:34
  • Are you using VerifyV2? https://www.twilio.com/console/verify/dashboard/ (make sure V2) - https://www.twilio.com/blog/introducing-verify-v2-public-beta. – Alan Aug 24 '20 at 13:03
  • yes using this api request https://verify.twilio.com/v2/Services but it shows `"services": []` [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 25 '20 at 08:33
  • Next question, I assume you created a Verify V2 Service? You can this via the API or via the Twilio console, https://www.twilio.com/docs/verify/api, `Create a Verification Service` code example or https://www.twilio.com/console/verify/services. – Alan Aug 25 '20 at 11:08
  • how can i created a Verify V2 Service? [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 26 '20 at 00:56
  • can you please tell me how can i get `twilio Active Numbers`? any api request? [@](https://stackoverflow.com/users/9750066/alan) – devs1994 Aug 26 '20 at 06:21
  • That is another question but it was already answered, https://stackoverflow.com/questions/63296967/list-my-phone-number-inventory-inside-twilio-flex – Alan Aug 26 '20 at 12:27