Facebook Graph Api, limit and / or order?

Is it possible to limit / filter FB Graph queries (page):

  • Category (per page)? (e.g. & category = restaurant)
  • The amount he liked (minimum threshold)
  • Does it have certain properties (for example, it should have location.city or maybe a filter where location.city == "San Jose")

and is it possible to order results (for example, by the number of similar descending ones?)

I use this as a starting point:

http://graph.facebook.com/search?q=california&type=page&fields=id,name,location,category 
+8
facebook facebook-graph-api
source share
2 answers

I'm not sure about the functionality of the order, but here you can add a limit parameter, such as this:

http://graph.facebook.com/search?q=california&type=page&fields=id,name,location,category&limit=2

+3
source share

The Facebook api chart first returns the last object. and, unfortunately, you cannot sort the return sequence. The API does its best by calculating relativity by its own logic.

  • limit: number of returned objects
  • offset: the starting point of the result

No order in ascending or descending order.

You can use FQL for some objects, but this does not apply to search.

To find out if this is supported, simply enter the URL into the browser and look at the bottom section of the search call. Most of the supported options are there.

http://graph.facebook.com/search?fields=id,name,location,category&q=california&limit=2&type=page

  "paging": { "next": "http://graph.facebook.com/search?fields=id,name,location,category&q=california&limit=2&type=page&offset=2&__after_id=108131585873862" } 
+5
source share

All Articles