ios - Facebook OAuthException when calling taggable_friends using Social Framework -


i using social framework fetch taggable_friends of user. when call api first time using below url working fine.

[nsstring stringwithformat:@"https://graph.facebook.com/%@/taggable_friends", userid]; 

and response in format

{   "data": [      ... endpoint data here   ],    paging =     {     cursors =         {         after = qwfkq0llndf0s05vzaxbcswqxndm1mtfpbfbhzaxlyv2f5x2uxb1bpwdvtuu82lufyamzaywupfqtrfwxplskrzru9byxnuswvts2zaft21tdlnycxfcwxnpcuxor01snkd3uxzaymldyv1rutw9qcgczd;         before = qwfjs2e3tgjdelflni04bldxrg4zcnvuexvyy2l0vgvvtk84u1vwdv9zaufjrb08ztf90d3zarxzjsb2tabfza6x2lmnuvqqxfsugh6nvjrbzfgrm9teldwzatdqak5cum9gm0vhtmvrzakrszafazzalezd;     };     next = "https://graph.facebook.com/v2.3/996970000322616/taggable_friends?access_token=caaxvxrj0gjebafxammhzw4qotmq1uzbourwlyp1jfswoupptullrkihgoxlu0lqvyf6hoqumhb9pvuis9vekp6qlzch9sizdv1xteqsvr7rtjzxifpjzcdxztamdzcwvasmmibgidusuyofcl8sajbqlwlk57q1hwtpyjkb9wuxay2oo9zcujmuzcsmeufesvslopraraufbvfws3z7h4kwi9kqqg6bzbytswthhgaj1gzdzd&limit=25&after=qwfkq0llndf0s05vzaxbcswqxndm1mtfpbfbhzaxlyv2f5x2uxb1bpwdvtuu82lufyamzaywupfqtrfwxplskrzru9byxnuswvts2zaft21tdlnycxfcwxnpcuxor01snkd3uxzaymldyv1rutw9qcgczd"; };  } 

since response paginated made second request fetch friends(recursive call) in second page using url in 'next'. when called api, got oauthexception below

error =     {     code = 1;     message = "an unknown error has occurred.";     type = oauthexception; }; 

when loaded above 'next' url in browser, loading correct data.

i used slrequest(social framework) fetch response facebook

   nsurl *url = [nsurl urlwithstring:requesturl];     slrequest *request = [slrequest requestforservicetype:slservicetypefacebook                                             requestmethod:slrequestmethodget                                                       url:url                                                parameters:nil];     request.account = facebookaccount;     [request performrequestwithhandler:^(nsdata *responsedata, nshttpurlresponse *urlresponse, nserror *error) {         nsdictionary *responsedictionary = [nsjsonserialization jsonobjectwithdata:responsedata                                                                            options:nsjsonreadingmutablecontainers                                                                              error:nil]; 

also set following permissions on requestaccesstoaccountswithtype method

    nsdictionary *options = @{ acfacebookappidkey: fb_app_id ,                                acfacebookpermissionskey: @[@"basic_info",@"user_friends"]}; 

can 1 please me this?


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -