LinkedIn OAuth token with Javascript SDK

2019-07-12 19:35发布

问题:

I was integrating LinkedIn sign-in with my web application,

Initially I was doing the implementation using JS SDK. After I realised that for iOS Mobile Devices, LinkedIn does not support JS SDK. So Currently I am using OAuth implementation.

My question is, Is there any way to use JS SDK after getting OAuth login success and after getting the access token. My point is, I don't want to do the logic for token validation, expiration etc.

PS - Similar feature I have found in Facebook SDK, they are allowing to use Facebook JS SDK after setting the access token to SDK.

Please share your thoughts, comments, links.

Thanks in advance.

回答1:

You are using JS SDK, which has all of the following features to work with authorization, tokens etc.

Example:

IN.User.authorize()
IN.User.logout()
IN.User.refresh()
IN.API.RAW.... etc