Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

July 2013 breaking changes: Graph API post search with or without access token?

The Developer Roadmap states in the Graph API search changes paragraph:

User access tokens will be required for all search Graph API calls except Posts, Places and Pages. App access tokens may also be used for Post search Graph API calls. Places and Pages search Graph API calls will still require an App access token. Search for Applications will no longer be supported.

But this Developer Blog Post says in the Graph API search changes paragraph:

App access tokens will be required for all search Graph API calls except Places and Pages. Search for application will no longer be supported.

So the first says that I will not need an User access token to search for posts (but I may use an App access token if I want to). And the second says that I need to use an App access token. I'm confused. Which one is correct?

like image 652
Stefan Pi Avatar asked Nov 18 '25 17:11

Stefan Pi


1 Answers

There are a few things regarding the search API that I would like to mention to clear your confusion.

  1. You can use the User Access Token for the Graph API search, for all types of nodes like Post, Places and Pages and retrieve the User's view of the result which might differ from other two cases. The difference arises basically from the permissions that other have for the respective User. I would recommend this over the others basically because the result might be more User respective.

  2. You can use App Access token to get the Public view of the data from the Graph API Search. The data retrieved might be different or same as the other cases. Using this is a best thing to do in case of doubt over what access token is to be used.

  3. To complicate the things further, you may even get away using Graph API search without any access token (Sample request /search?type=post&q=video). Although this is highly not recommended because Facebook might just change the API anytime requiring further changes in your app.

So in short use User Access token if you would want User view of data or if you just want public data for some statistics etc. you may use App Access token.

And to answer your question You will be required to use the App Access token after July 10,2013

like image 140
Anvesh Saxena Avatar answered Nov 23 '25 03:11

Anvesh Saxena



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!