0

I am using the RestFB client to fetch all post_ids of a Facebook Page.

The query is

select post_id from stream where source_id=265813166783408

Where the id if of the page I'm querying. It can be found here

I initially tried executing this without an access token. This gives a 104: Requires valid signature error from Facebook.

I looked up this error and the solution that many gave on SO is to use an access token. However if I try with an accessToken (with permissions: manage_pages, publish_stream, read_stream, offline_access, read_insights) then Facebook gives a different error 190: Impersonated access tokens can only be used with the Graph API.

Does this mean I shouldn't use FQL for getting page posts. The Facebook documentation doesn't mention anything on these lines but like I said it keeps alternating between these two errors.

PS: I can use the Graph API with my access token to fetch Posts but for my specific scenario I felt FQL would be a far better option, since I can nest this query into a query on the comments table (eventual aim).

Thank you.

UPDATE:

Please see Facebook developers for a discussion on this particular issue If you are using the RestFB library then also see the relevant issue

Sagar V
  • 1,916
  • 15
  • 23
  • Have you found anything on this matter. I have the same problem when making a request using fql and page access_token? Is there a work around. – NimmoNet Jun 11 '12 at 21:36
  • 1
    @NimmoNet - None so far. I am using Graph API to fetch Posts and then switching to FQL for comments. – Sagar V Jun 12 '12 at 02:45

1 Answers1

1

We encountered the same problem and found it to be an issue with using fbclient library and a page access token. We switched to calling the API directly (with the Apache HttpClient) and our FQL ran fine with the page access tokens.

bflorian
  • 26
  • 2
  • Oh is that the case? I will try this out and let you know. Thanks. – Sagar V Jul 17 '12 at 06:22
  • The RestFB library that I am using currently uses the deprecated endpoint for read only queries. The current unreleased library has a new function to handle this issue so am currently maintaining a local workaround. You were on the right track so I will accept your answer :) – Sagar V Jan 04 '13 at 05:17