Consider X and Y are friends in Facebook and they both have installed an app in their respective phones. But they are not
Use Facebook-sdk 3.1
User-generated requests are initiated when the app enables the user to select one or more friends to send a request to.
We will walk you through the steps to send out an invite or a request:
You can set up your app to prompt the user to send out an invite after the user has used the app a certain number of times. You should also give the user the ability to invite friends to use the app at any time through the use of a menu button they can always get to. In this step we will show you a simple way of triggering the invitation request.
See https://developers.facebook.com/docs/howtos/send-requests-using-ios-sdk/#protip2 for different types of coding logic.
See also: