This is in regards with the Facebook User Profile API (https://developers.facebook.com/docs/messenger-platform/identity/user-profile/). Previously I was able to access details of all the users who messaged our FB Messenger Bot using their USER_ID. But since a couple of days, I'm not able to access details of all the users. I'm only able to access details of few of them.
Example: This User (3200103453356504) regularly texts me, so accordingly to the documentation and how it used to work previously, I should be able to access his information but when I try to access it. It shows the following error:
{
"error": {
"message": "Unsupported get request. Object with ID '320010123356504' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api",
"type": "GraphMethodException",
"code": 100,
"error_subcode": 33,
"fbtrace_id": "AFARcLffkfOE55crL3qvJAL"
}
}
But this behavior does not exist for all the users. For ex, For this User ID - 2238372056224053 - its working perfectly fine and returning the correct response with first_name, last_name etc.,
Can you please point out what exactly is the issue.
Thank you,
Murtuza
Related
I need to know If I need to give up on Facebook and just use Twitter for my purposes (if so, just tell me to use Twitter). I want to use pages I don't own.
I am doing this same process in Twitter, but Twitter doesn't have pages that rate places, services or things in general with comments and a rating system (or atleast the ones I need from one city with specific places).
Twitter has much more liberty to get comments from any #user_name but its not good enough for a sentiment analysis specific assignment I need to do. I am trying to get facebook comments or posts from multiple facebook pages (pages from restaurants) based on the comments used for ratings and download them to a csv or database with any program or by coding (Preferably Node.js, javavascript or php) for sentiment analysis (this is very easy with Twitter!). How can I achieve this with all the policies and restrictions Facebook has in 2018??
I have some questions with reference to facebook:
Will an app_id and app_secret by making an app in 2018 give me an access token to get the comments I need from ANY page and download them with graph api?
Is facebook graph API the only way to get comments or posts to download them?
Why doesn't any type of code or programs before and even right now in 2018 work anymore to get comments? (I get the errors below with either programs or graph api).
I tried to use Graph API from facebook for 2 different pages using GET and POST and I get some errors that I didn't have trouble with 9 months ago (this happens with every page I try to search with code in node.js, javascrip, php or the graph API from facebook):
GET/v3.1/OMENbyHPLatam/feed
{
"error": {
"message": "(#10) To use 'Page Public Content Access', your use of this endpoint must be reviewed and approved by Facebook. To submit this 'Page Public Content Access' feature for review please read our documentation on reviewable features: https://developers.facebook.com/docs/apps/review.",
"type": "OAuthException",
"code": 10,
"fbtrace_id": "CXg962vUvjY"
}
}
POST/v3.1/minecraft/feed
{
"error": {
"message": "(#200) Requires either publish_to_groups permission and app being installed in the group, or manage_pages and publish_pages as an admin with sufficient administrative permission",
"type": "OAuthException",
"code": 200,
"fbtrace_id": "EZvhzuk/UHL"
}
}
We have a server application monitoring certain Facebook pages for Videos being uploaded. As there is no user involved (server app only), we use an App-Token for our requests.
So far so good, but we have issues with Pages that are only available in certain countries or territories, e.g. "/bitburger" seems to be available in Germany only. I can access the page via API with an User Token (relating to a german user), but my server or even the graph/api explorer (authenticating with an App Token) cannot access the page info.
It will result in an error such as:
{
"error": {
"message": "Unsupported get request. Object with ID 'bitburger' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api",
"type": "GraphMethodException",
"code": 100,
"fbtrace_id": "AlDpyo1BjLm"
}
}
Our application is supposed to be global solution that does not care about "regionalized pages" and needs to get the page info (and its published videos) independently from a users location.
Is there any way to achieve this?
So is there a possibility to tell the API-call to ignore regionalized filtering?
User Tokens are not an option (as I said, server app only) and we cannot have a user for every country in the world. We wouldn't even know the right country to begin with :/ It has to work with a location-independant App Token.
Thanks in advance for your help!
Looking forward to any solution.
Thanks and kind regards,
Daniel
// Update:
Thanks for your responses!
I got in touch with Facebook and it is in fact due to "market sites" that only users from this market (country or whatever) have access to. This maps to the API as well and teh App itself does not relate to any market.
The only solution there is (when not having a user to request with), is to get access for your App granted by the page admin. Then you can access the pages info. Unfortunately that does not help for anonymous monitoring.
I am using v2.6 of Facebook API, trying the requests in GraphAPI interface. My goal is to get the messages from the account but i always receive this error message:
"error": {
"message": "(#100) Tried accessing nonexisting field (messages) on node type (User)",
"type": "OAuthException",
"code": 100,
"fbtrace_id": "DdRsSIGtBNX"
}
This is the url.. me/messages. Below is a screenshot of the permissions that i selected when creating the access token used in the request.
I know this was possible in the older versions, but I am not sure anymore if we can do it now with the last version(everytime i select a method from the Facebook docs it does not take into consideration the api already chosen and i think this is confusing). Does anyone know if getting messages/conversation still possible with v2.6? Thank you.
No, it is not possible any more to get access to a user’s messages - that has been removed with API v2.4
https://developers.facebook.com/docs/apps/changelog#v2_4_deprecations
I have a server side app with an access_token created using the facebook apps appKey and secret.
I use version 2.5 of facebook graph API and cannot use an older API version.
I want to get periodically stats on posts. The posts where created via the same facebook app but with the Facebook users logged in. So in my db I've got the userid_postid for each post.
If I query with the apps id and a posts id I get the expected results for some posts.
GET "{appKey}_{PostId}?fields=shares
If I query like this 'GET "{postingUserId}_{postId}?fields=shares' with the user id and the post id I get this error:
{
"error": {
"message": "Unsupported get request. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api",
"type": "GraphMethodException",
"code": 100,
"fbtrace_id": "AyT8LYQDlDd"
}
}
A cron runs periodically a query to get number of likes and shares and it uses the appId and secret to get its access_token.
How do I query for informations on posts?
The question raises because I was reading a book about Facebook Application development and when it explains how to make call to the graph, it says that I can verifiy how simply I can retrieve informations from the graph just writitng https://graph.facebook.com/myProfileId in my web browser. Well, I do that but I get this
{
"error": {
"message": "(#803) Cannot query users by their username (myusername)",
"type": "OAuthException",
"code": 803
}
}
but then if I include in the url an access token generated from the Graph API explorer, I can see the JSON with more informations, as I expected to be.
The question is: do I always need an access token to make a request with the Facebook Graph API even if the informations that I want to access are public? In case of affirmative answer to this question, why the book I'm reading says I can get informations from the graph even without an access token? Maybe this is a feature of an older version of the graph api?
Of course you need a token, the token is intrinsically linked to a specific user.
How could you retreive any informations (even public) with only a generic Url,
you must add to the request an information to identify the user that you want.
Personally I use this link "https://graph.facebook.com/me?access_token=" from the facebook doc : https://developers.facebook.com/docs/graph-api/overview