Facebook : List of all pages liked by - facebook

I am new to Facebook's Graph API and FQL. I want small information about the same.
I want to get List of all pages liked by any particular user.
I have used Graph API just to allow user to get logged in with their Facebook ID and Can access their wall but don't know much about rest of the this.
I searched on Google for same but got information about list of pages that user administrate that I don't want, I want full list which is like by them.

It's a connection property of the User object.
https://developers.facebook.com/docs/reference/api/user/#likes

Related

Facebook API: how to find if a user liked my page

I need to check, using facebook graph api, if a facebook user has liked a certain page (I am the admin and can grant myself any permission). Does anyone know how I can achieve that?
I can't find it in the docs. The closest in the docs is the following:
https://developers.facebook.com/docs/graph-api/reference/v2.10/object/likes/
It says that the request returns: "An array of User or Page objects representing the people or Pages that liked the object" Which is in fact what I am looking for, as I could simply query the user in the list and see if there is a match. BUT , in fact, what the request (mentioned above) actually returns is an array of User or Page objects representing the people or Pages that the object (my page) liked.
The request from the docs might sill be implemented to solve the problem:
facebook graph api if a user has liked a page
BUT it doesn't help me, because I don't want to take the user's permission. I want to implement the solution from the side of the admin of the page- the admin needs to check for multiple users if they liked the page or not.
Can anyone help me sort this out?

Retrieve all liked objects from Facebook Graph API

Is it possible to get a list of all liked objects using the Graph API? I want to save a list of any articles (ie. items with URLs) the user has liked (say, in the past week). I've tried:
/me/likes - this is liked pages only, not other items
/me/feed - this is posts by the user only, not others
/me/home - this might be possible, but seems to be deprecated
If I understand what you're trying to get correctly, you can probably use the /me/og.likes Graph API endpoint. You'll need the user_likes permission for this.
The /me/likes endpoint returns Facebook Pages that the user likes, while the /me/og.likes endpoint returns any posts/links that the user has Liked (i.e. performed an Open Graph Like action on).

Get all Facebook friends that like a specific page

is there an easy way to get all Facebook friends that like a specific Facebook page?
I know that there is this site here
https://www.facebook.com/browse/friended_fans_of/?page_id=245323855526590
Where you can type in the page_id and get all friends that like this. But is this also possible with the Graph API? Or would I need to go every friend of a user, using the correct permission and THEN check if the user likes a specific page? I couldn't find an API Endpoint in the API Reference of Facebook

Using single access token to get the 'likes' of other users

Using the normal Facebook website, one can get to a page showing which pages a user has 'liked'.
From the graph API, it is possible to get this for pretty much all pages, using graph.facebook.com/userid/likes?access_token=MYACCESSTOKEN.
However, I need to be able to do the same - i.e. get the list of pages a user has 'liked' for normal Facebook users (and not 'pages' who have 'liked' other pages).
Is this possible with the single access token? Judging by the fact you can get this info from the normal Facebook web page, I would expect it to be possible.
Privacy works slightly differently for applications accessing the API and for users accessing the actual site.
An application doesn't have access (by default) to your friends' likes to prevent data mining. In order to get a users friend's likes, you'll need to request the friends_likes permission.
You can read about this permission and others in the documentation.

Determine first 50 likes via Facebook Graph API

Is it possible to get for example the first 50 people who liked a post, photo, whatever I created on facebook via the Graph API? Is there any kind of order when accessing connections like /likes or /comments?
Use the following link (given that you have permissions to access to the post):
/likes?limit=50
This should be the first 50 likes ordered via Facebook (usually based on time).
ASFAIK, you cannot get a list of people who like a page. It's a privacy issue. If you wanted to create an app, and users authorized your app, then you could get a list of the current users friends who like the page.