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
Related
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
I'd like to receive data on a public page event via the graph api. I have been doing this for quite a while now, but suddenly my code is not working any longer.
Take for example the page ID 128431033877314. A graph api GET call to
128431033877314/events
delivers – as expected – the list of events for this page. Amongst them, for example, the event with ID 158032248286483. Trying to receive any data for this event fails, returning my favorite graph api error:
{
"error": {
"message": "Unsupported get request. Object with ID '158032248286483'
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": "GN5BhnWsN5O"
}
}
I have tried accessing /158032248286483 and 158032248286483?fields=id, I have used the graph API explorer to check different versions (2.6 and 2.12), I have tried with user, page and app access tokens. All in vain. Same goes for any other event returned.
As I said – this has most certainly been working before. I can hardly imagine this being a bug, as it would affect quite an important piece of graph api functionality. So I assume I am missing something here. Could somebody please tell me what it is?
Thanks so much in advance!
Yes, #CBroe, is right, in lights of "Cambridge Analytica" issue, Facebook was recently closed/deprecated/changed some endpoints. Reading bug reports many people complaining about lost access to some endpoints related to Events, Groups and Pages APIs. But, there actually two types of changes they did: some endpoints of Event and Groups APIs are deprecated means nothing you can do right now. (They will change/replace/tune it in future). And second part related to Pages API, that actually can be fixed with some coding on your side. For the Pages API they just forced May 8 breaking changes to take effect immediately. You need to migrate your requests to use "page access token" instead of "user access token" when you use those endpoints.
More info you can check there:
Blog post about actions they have taken:
https://developers.facebook.com/blog/post/2018/04/04/facebook-api-platform-product-changes/
Facebook breaking changes:
https://developers.facebook.com/docs/graph-api/changelog/version2.11
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.
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
I need to build an application which needs to search in public Facebook posts.
As I search for solution I found the Topic Search API: https://developers.facebook.com/docs/topic_search/v2.4
I tried this API using a Facebook Application but getting this error:
{
"error": {
"message": "(#3) Application does not have the capability to make this API call.",
"type": "OAuthException",
"code": 3
}
}
How can I gain access to use the search API?
As far as I know this is not a public API (which should be documented by FB), so this means that you cannot use this with your own apps. I guess specific app_ids from partners are actively whitelisted.