Facebook Graph API return only one page of Inbox?

4.7k Views Asked by At

I tried accessing the facebook inbox using the graph API's https://graph.facebook.com/me/inbox?limit=0&access_token=<extended_access_token> This returns few recent messages of the inbox without access to previous messages. There is no paging for inbox. Also, I couldn't find any documentation related to this. Any help would be appreciated.

Is the API designed to be this way?

2

There are 2 best solutions below

2
On BEST ANSWER

Try using the until parameter for pagination of your inbox.

/me/threads?until=2011-05-01

The new inbox is now called threads rather than inbox. See https://developers.facebook.com/docs/reference/api/thread/ (yes in the Graph API Explorer it is plural rather than what the documentation shows as singular)

0
On

You can set any limit you want by adding ?limit=Amount on the request.

Example:

FB.api('/me/threads/?limit=50', function(response){ 
   console.log(response);
});