Reputation: 1505
I think this might be a very simple setting issue and since I am very new to swift and LinkedIn API I might be doing this wrong:
I am making an iOS app with swift and want to use LinkedIn to authenticate. For that, I created an application on LinkedIn Developer Network. But now I am not able to put my app redirect URL in OAuth 2.0 Redirect URLs:
The app redirect URL in my code looks like oauth-testapp://oauth-callback/linkedin and its working fine with OAuth 1.0 but for OAuth 2.0 I need to have this in http:// or https:// format.
This is where my confusion is as I cant add my URL oauth-testapp://oauth-callback/linkedin in OAuth 2.0 Redirect URLs:
I read some posts like this and this and I don't want to create a website to redirect the user to the app or create a web view inside the app. I mean I can do it but I just want to make a POC and this is where I am blocked on. Is it at all possible without these methods? Has anyone done it with swift? Thanks a lot for your help guys!
Upvotes: 8
Views: 3897
Reputation: 11
For authentication in LinkedIn oauth 2.0, your redirect url should be like this: https://com.testapp.linkedin.oauth/oauth
Upvotes: 0
Reputation: 53928
You'll have to create a webview inside the app - it's not that hard and you'll need to trigger a browser anyhow - and override the behaviour for this specific (redirect URI) callback URL as described in: Oauth 2.0 authorization for LinkedIn in Android
Upvotes: 2