简体   繁体   中英

How to get facebook friends list using facebook sdk in android

I am making a demo for facebook friend list,And goen through facebook api reference ,

I have implemeted as per suggested in the facebook api docs,But i only got friends count from it,Can any buddy please tell me how to get fiernds name and profile pic from facebook api,my code is as belo:

code

new Request(Session.getActiveSession(), "/me/friends", null,
                HttpMethod.GET, new Request.Callback() {
                    public void onCompleted(Response response) {
                        /* handle the result */

                        System.out
                                .println("=============my frineds============"
                                        + response);
                    }

                }).executeAsync();

Since v2.0 you can only get friends who authorized your App too, for privacy reasons. More information can be found in the answer over here: Facebook Graph Api v2.0+ - /me/friends returns empty, or only friends who also use my app

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM