0

您可以像这样friendList使用 :respective name and idFBGraph API

  FbGraphResponse *fb_graph_response = [fbgraph doGraphGet:@"/me/friends" withGetVars:nil];

但是如何name, id and picture使用all friendsFBGraph API

4

1 回答 1

1

您可以像这样使用friendList各自的方法:name, id and pictureFBGraph API

NSDictionary *param=[NSDictionary dictionaryWithObjectsAndKeys:@"picture,name",@"fields", nil];

FbGraphResponse *fb_graph_response = [fbgraph doGraphGet:@"/me/friends" withGetVars:param];

Response将会

data = {
   id = 100001625299089;
   name = "Name here";
   picture = {
              data = {
                      s_silhouette" = 0;
                      url = "url here";
                      };
              };
 },
    //all other friends here
 }

编辑:您可以loactionbirthday和许多other fields列在FBGraph API 文档中。

只需更改param dictionary上面的代码

 NSDictionary *param=[NSDictionary dictionaryWithObjectsAndKeys:@"picture,name,location,birthday",@"fields", nil];
于 2013-01-10T12:09:03.617 回答