Reputation: 475
I would get user likes from facebook using Android sdk 3.0 beta.
How do I do this?
Upvotes: 1
Views: 4029
Reputation: 4928
Provided that you have a valid session, this is the code to get the user likes
Session session = Session.getActiveSession();
Request.Callback callback = new Request.Callback() {
@Override
public void onCompleted(Response response) {
// response should have the likes
Toast.makeText(getApplicationContext(), response.toString(), Toast.LENGTH_LONG).show();
}
};
Request request = new Request(session, "me/likes", null, HttpMethod.GET, callback);
RequestAsyncTask task = new RequestAsyncTask(request);
task.execute();
Upvotes: 10