Hello I'm working on a system that simulates a client logging into their site and checking statuses. The site is using google oauth for login and has 2-factor authentication enabled (turning this off is not an option).
As the system is automatic we need to login past the 2-factor dynamically. I'm looking into using twilio/authy to do this as they allow creating a phone number and then interacting with its texts through the api.
I want to receive the 2-factor text with twilio and send that code to my api to complete the sign-in process.
I'm not sure how best to go about this though as the docs aren't clear and additionally I'm not sure if it's possible after looking at this https://support.twilio.com/hc/en-us/articles/223133447-Not-Receiving-Incoming-SMS-and-MMS-Messages-on-Twilio-Phone-Number
Are you expecting to receive SMS from a short code?
Services like Google Voice, Facebook, and Skype, which use short codes (e.g. 55555) to send SMS will not be able to send messages to Twilio phone numbers. This is because short code carriers have arrangements to exchange messages with mobile phone numbers only, and Twilio phone numbers are not considered mobile numbers. Unfortunately, we can not guarantee delivery from these incoming messages.
If anyone with more experience could let me know if I'm interpreting this correctly in that it cannot be done with twilio? If it cannot do you know any software that supports this functionality (my company already has a twilio account so that's our preference, but we're willing to support a different program if needed).