Skip to content

Instantly share code, notes, and snippets.

@preslavrachev
Created May 8, 2013 12:37
Show Gist options
  • Save preslavrachev/5540161 to your computer and use it in GitHub Desktop.
Save preslavrachev/5540161 to your computer and use it in GitHub Desktop.
How to submit a FQL query to Facebook on Android (thanks to http://stackoverflow.com/a/13163261/1107412)
String fqlQuery = "select uid, name, pic_square, is_app_user from user where uid in (select uid2 from friend where uid1 = me())";
Bundle params = new Bundle();
params.putString("q", fqlQuery);
Session session = Session.getActiveSession();
Request request = new Request(session,
"/fql",
params,
HttpMethod.GET,
new Request.Callback(){
public void onCompleted(Response response) {
Log.i(TAG, "Got results: " + response.toString());
}
});
Request.executeBatchAsync(request);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment