-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change Facebook API endpoint #90
Comments
Currently ALM is using this API call (with authentication): https://graph.facebook.com/fql?q=select%20url,%20share_count,%20like_count,%20comment_count,%20click_count,%20total_count%20from%20link_stat%20where%20url%20=%20%27http%3A%2F%2Fwww.plosntds.org%2Farticle%2Finfo%253Adoi%252F10.1371%252Fjournal.pntd.0001969%27 {
"data": [
{
"url": "http://www.plosntds.org/article/info%3Adoi%2F10.1371%2Fjournal.pntd.0001969",
"share_count": 2707,
"like_count": 4603,
"comment_count": 4447,
"click_count": 0,
"total_count": 11757
}
]
} The depreciated REST API call: http://api.facebook.com/restserver.php?method=links.getStats&urls=%27http%3A%2F%2Fwww.plosntds.org%2Farticle%2Finfo%253Adoi%252F10.1371%252Fjournal.pntd.0001969%27&format=json [
{
"url": "http://www.plosntds.org/article/info%3Adoi%2F10.1371%2Fjournal.pntd.0001969",
"normalized_url": "http://www.plosntds.org/article/info:doi/10.1371/journal.pntd.0001969",
"share_count": 2707,
"like_count": 4603,
"comment_count": 4447,
"total_count": 11757,
"click_count": 0,
"comments_fbid": 214278208697221,
"commentsbox_count": 0
}
] The graph API: https://graph.facebook.com/v2.1/?id=http%3A%2F%2Fwww.plosntds.org%2Farticle%2Finfo%253Adoi%252F10.1371%252Fjournal.pntd.0001969 {
"og_object": {
"description": "PLOS Neglected Tropical Diseases is an open-access journal publishing peer-reviewed research on the world\\'s most neglected tropical diseases, such as elephantiasis, river blindness, leprosy, hookworm, schistosomiasis, and African sleeping sickness",
"title": "An In-Depth Analysis of a Piece of Shit: Distribution of Schistosoma mansoni and Hookworm Eggs in Human Stool",
"type": "article",
"updated_time": "2014-08-20T03:12:34+0000",
"url": "http://www.plosntds.org/article/info%3Adoi%2F10.1371%2Fjournal.pntd.0001969",
"id": "214278208697221"
},
"share": {
"comment_count": 0,
"share_count": 11757
},
"id": "http://www.plosntds.org/article/info%3Adoi%2F10.1371%2Fjournal.pntd.0001969"
} Using the DOI gives exactly the same reponse, as before: https://graph.facebook.com/v2.1/?id=http%3A%2F%2Fdx.doi.org%252F10.1371%252Fjournal.pntd.0001969 {
"og_object": {
"description": "PLOS Neglected Tropical Diseases is an open-access journal publishing peer-reviewed research on the world\\'s most neglected tropical diseases, such as elephantiasis, river blindness, leprosy, hookworm, schistosomiasis, and African sleeping sickness",
"title": "An In-Depth Analysis of a Piece of Shit: Distribution of Schistosoma mansoni and Hookworm Eggs in Human Stool",
"type": "article",
"updated_time": "2014-08-20T03:12:34+0000",
"url": "http://www.plosntds.org/article/info%3Adoi%2F10.1371%2Fjournal.pntd.0001969",
"id": "214278208697221"
},
"share": {
"comment_count": 0,
"share_count": 11757
},
"id": "http://dx.doi.org/10.1371/journal.pntd.0001969"
} The new |
Facebook is depreciated the fql link_stat API endpoint with the 2.1 API on August 7, and new API keys no longer work. https://developers.facebook.com/docs/apps/changelog/
We should use the graph API instead.
The text was updated successfully, but these errors were encountered: