ios - User Authentication using linkedin -


i trying sign using linkedin.once succesful login,i write following code.my problem when acceses token use same api lisdksession *session = [[lisdksessionmanager sharedinstance] session]; nsstring *at=[[session accesstoken] accesstokenvalue]; nsstring *url=[[nsstring alloc] initwithformat:@"https://api.linkedin.com/v1/people/~:(email-address)?oauth2_access_token=%@&format=json",at]; in response follwing { "errorcode": 0, "message": "unable verify access token", "requestid": "xxfro610rp", "status": 401, "timestamp": 1443599825188 }

don't pass access token request. once user authorized , permissions assigned, try this.

 if ([lisdksessionmanager hasvalidsession])    {   nsstring *url=[[nsstring alloc] initwithformat:@"https://api.linkedin.com/v1/people/~:(email-address)&format=json"];    [[lisdkapihelper sharedinstance] getrequest:url success:^(lisdkapiresponse *response) {      // response     }  error:^(lisdkapierror *apierror) {     // error    }]; ]} 

Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -