The Facebook Graph API responds to any data if the limit is set to 20

I request data in the Facebook Graph API Explorer:

access_token="SECRET"
GET https://graph.facebook.com/me/home?limit=20&until=1334555920&fields=id

result:

{
  "data": [
  ]
}

I was shocked because there are many channels in my “house”.

Then I tried to set the limit to 100, then I got a list of feeds.

What's going on here? Does the "limit" parameter affect the result of the api chart?


I tried to increase the limit to 25 and request again, there is one channel.

So, what is the relationship between the “limit” and the “before”?

+3
source share
1 answer

The Facebook API can be a little weird sometimes because of the data you are trying to get, and there are several parts to this question.

Limits

, , , , : Graph API.

, FB, , . , - Friend, . (, , ).

API

, Graph API, , - . API- Graph : , /. - Facebook ( ), / . , , :

// This obviously isn't valid as written, but you the params change as described
limit=fixed-value&offset=programmatic-increase&since=some-fixed-date-here

: . , :

// My example query
limit=20&since=1334555920

--> {#1,#2, ... #20}

, . ( , n , n/2 - ):

// My example query
limit=20&since=1334555920&offset=20

---> {#10, #11 ... #25}

, , , , 50-100 . , , .

, , . - , , , ( , # 10-30 = 20, offset = 10), .

+3
source

All Articles