According to this other recent HN comment, Twilio numbers cannot be used for SMS verification. Banks and Gmail are mentioned:
https://news.ycombinator.com/item?id=19219150
"I have this problem because my main, personal number is actually a twilio number (as I built my own personal telco within twilio) and this means I cannot receive validation messages from shortcodes (like a bank)."
Yes. I wouldn't have mentioned it if it didn't work.
Here's a screenshot showing the Apple and PayPal 2FA codes I have received through Slack via Twilio...
https://i.imgur.com/bQYSbPZ.png
I also don't have any accounts with banks that are stupid enough to use SMS for 2FA [1] so I haven't needed to use my Twilio number for that purpose.
Using SMS for Gmail 2FA doesn't make any sense when Google supports U2F.
[1] https://motherboard.vice.com/en_us/article/mbzvxv/criminals-...
Would you mind sharing a working source?
Twilio/Google Voice (more generally, VOIP numbers) are explicitly being blocked (because it's possible to find out what type of number it is) at a number of services, likely to combat fraud.
I've found MSFT (Azure) and AWS to be recent examples of such services. Google itself does the same.
https://i.imgur.com/6b3cg5L.png
62226 = PayPal and 51472 = Apple.
This is one of the reasons I purchased a mobile/cell number from Twilio to use as a backup for all of the websites that only support 2FA via SMS (Apple, PayPal etc.).
The 2FA code gets sent to a channel on my own private Slack workspace via a webhook [1]. If I lose my phone I can always log into the Slack website on another device to access the code.
[1] https://www.twilio.com/docs/studio/tutorials/how-to-post-sms...