Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How Did GroupMe verify my number?

Tags:

ios

iphone

I am working on an iPhone application where I need the user's phone number. From what I've read (here for instance - Programmatically get own phone number in iOS), the device's phone number is not available within your application's container. I've always had the user enter his or her own number. But when I joined GroupMe the other day, after clicking the Get Started button, my phone opened up a drafted text message to some US area code number "Send this text to verify your phone number(b2bd308eb7)" After I sent the text, the app knew my number....how does one implement a system like this?

like image 915
mistahenry Avatar asked Aug 14 '12 14:08

mistahenry


1 Answers

What GroupMe does is use the MessageUI Framework ( http://developer.apple.com/library/ios/#DOCUMENTATION/MessageUI/Reference/MessageUI_Framework_Reference/_index.html) to send a text message to their servers.

Basically it works like this:

  1. The app is turned on and calls the server.
  2. The server responds with a code b2bd308eb7.
  3. The app sends that code via SMS to the server.
  4. The server gets the code and your phone number (from SMS) and confirms them.
  5. Your phone number and app are connected!
like image 170
James Paolantonio Avatar answered Sep 21 '22 11:09

James Paolantonio