I try using this link this. In this tutorial i post my app link only my wall. But i want to share my app link to all my friends. Same like as a XYZ invited to you to try ABCapp only in notification bar. When click on it open google play store of my app page. I want to share my app app link to app facebook friends or selected facebook friend. How can i achieve this?
To invite friends through your app you can use App Invites. Before using this feature make sure to set up your Android Facebook SDK version to 4.0 or later.
You can take a look at the overview in this link
https://developers.facebook.com/docs/app-invites/overview
For the implementation you probably need this
https://developers.facebook.com/docs/app-invites/android
https://developers.facebook.com/docs/apps/faq#invite_to_app
If your app has a Canvas presence, you may also use the Requests Dialog on iOS and Android
If your app does not have a presence on Facebook Canvas: You may use the Message Dialog on iOS and Android, or the Send Dialog on Web
I assume you don´t have a Canvas presence? In that case you should not use App Requests.
Basically what you need is the list of all the friends of user on facebook to invite them. you can get ALL friends' list only if your app is in "GAME" category.
If not, then you can still get the friend list of user , but only some, not all. refer to terms friends and invitable_friends on facebook.
So, here are few things you can do (BUT NOT RECOMMENDED AT ALL)
Change the category of your app to "GAMES" & you'll be able to get
all friend's list & then you can use WebDialog & WebDialog.RequestsDialogBuilder to invite that friends
give any link to canvas URL on facebook app setting. that link will be used only when user clicks your notification from web. that link won't affect your app in any way.
Related
So I am using react-native-fbsdk in my app. I want my app to have functionality to invite user facebook friends to use my app. That functionality will be in card that show user friends profile picture and name, and a button that can be used to invite that friend. My app is not a game.
My first question is how can I get all user friends that not using my app and using react-native-fbsdk for invitation?
So far I know that facebook has two API to do this taggable_friends and invitable_friends.
taggable_friends is used when user need to do post and tag his friend (I think this not what I looking for, cause all I want is user press the button and the invitation will imediately send to his friend)
invitable_friends is use for game, but for non game app, I can use message dialog
https://developers.facebook.com/docs/apps/faq/
For apps which are not games, or for apps without a Canvas presence,
use our other products such as the Message Dialog on iOS and Android,
Send Dialog for the Web or the Share Dialog on iOS, Android, Web.
These products let a person easily select the friends they want to
message or share with.
So the second question is how I can use this message dialog inside my react-native app?
note: react-native-fbsdk has FBAppInviteDialog, is it relevant to this question?
I use Facebook SDK 3.22 for Android. I want my app to do the following:
Post content on user's wall
Share content with user's friend
For the 1st point I've decided to use feed dialog. So I've made logging in and dialog. It works perefect. No questions about this.
But I confused with the 2nd. At first, I also wanted to use feed diolog with parameter "TO" but with the help of this question
I undersand that I need to invite friend befor posting on it's wall. So I've made invite dialog. But with the help of this question I understand that I can't do even this.
Could you explain to me how can I share content with friend.
P.S My app is not a game and does not have a canvas version. It has only basic permissions
I've decided to post only to the user's wall throw the Feed dialod or Share dialog (if Facebook is installed). You can only send private messages to user's friends
I am little bit confused about new api and app review steps of facebook api. I need to have facebook login and get the list of friends of a logged in user and sent invitation to use app for selected friends. What are the steps i should follow it? do i need to submit my app for review in facebook?
You can´t get all the friends of a user anymore, at least not for an Android App. You only get the friends who authorized the App too.
There is invitable_friends for inviting friends, but:
The Invitable Friends API is only available to apps classified as Games, which also have a Canvas presence. This API is not available in v1.0. It may be called by mobile games as long as they also have a Canvas presence.
You may want to read this too: https://developers.facebook.com/docs/apps/faq#invite_to_app
Facebook change there api police. if you do not get Friends to send invitation. if you want to do that then you need to submit your app for review by facebook team but if your app is Game then you able to do that.
But another way, you can do that, You can do it via facebook web-dialog to send invitation.
Thanks
I have seen some android apps around that are able to invite friends to the app and detect when these friends have accepted the request.
I have been reading a bunch of documentation there at facebook and I can see I just need to create a request dialog to let the current signed user invite people. The problem comes when I want to know if this invited people have accepted the invitation and have installed the app.
First of all, It seems that I can just use the invite api if I have a canvas application beside the android one (At least this is what the docs state when using new 2.0 api -> "The invitable_friends API is only available for games that have a Facebook Canvas app implementation using version 2.0 of the Graph API."). Does this need to be in production too? Or I can just leave the canvas application as a placeholder there at facebook developer portal and just use the android one.
Second, How am I supposed to query the information I need (check if the friend the user invited has accepted + installed my app)?
The solution is a bit more complex that what it seems. Here is an approach you can take to get this working:
From inside your game, you can invite non-player friends by querying the Invitable Friends graph api call newly introduced in 2.0, and then creating a multi friend selector to invite those friends.
Suppose a player accepts that request, and enters your game. Their URL will contain extra information (won't be just app.facebook.com/yourgame), so you have to use Deep Linking to parse that extra information, and know that the user came because YOU invited him (you can send data in the request to help you do this). After you do this, a server is needed with a backend to record that your friend accepted your request and is playing.
Now, in the sender account, you need to query the server to see if any friend of yours accepted, and then give the appropriate message/reward.
Hope this clears up how to achieve this!
I want to create an app that allows a user to post to Facebook, but I want this to view posts by other users using the app, so basically a blog app in between friends using the app. How do i go about doing this, what API's do i use?
You Need to Checkout,how Oauth2 Works and check the Facebook Sdk for android and ios,there is a sample application in the sdk package,try that it will help and make you know how to use it in your application.