Git Product home page Git Product logo

linkedinsignin's Introduction

LinkedInSignIn

CI Status Version License Platform

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Also you need to setup app on LinkedIn and fill in dictionary with your app credetials:

let linkedinCredentilas = [
    "linkedInKey": "",
    "linkedInSecret": "",
    "redirectURL": ""
]

Login proces is simple as:

let linkedInConfig = LinkedInConfig(linkedInKey: linkedinCredentilas["linkedInKey"]!, linkedInSecret: linkedinCredentilas["linkedInSecret"]!, redirectURL: linkedinCredentilas["redirectURL"]!)
let linkedInHelper = LinkedinHelper(linkedInConfig: linkedInConfig)
linkedInHelper.login(from: self, completion: { (accessToken) in
        let alertVC = UIAlertController(title: "Success", message: "Your access token is : \(accessToken)!", preferredStyle: .alert)
        alertVC.addAction(UIAlertAction(title: "Ok", style: .default, handler: { _ in
            alertVC.dismiss(animated: true, completion: nil)
        }))
    self.present(alertVC, animated: true, completion: nil)
}) { error in
    print(error.localizedDescription)
}

Installation

LinkedInSignIn is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'LinkedInSignIn'

Author

Github: Serhii Londar

Email: [email protected]

License

LinkedInSignIn is available under the MIT license. See the LICENSE file for more info.

linkedinsignin's People

Contributors

captainhaddockfr35 avatar serhii-londar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

linkedinsignin's Issues

Get LinkedIn user full profile + Logout from LinkedIn

Really appreciate for your hard work with this great library!

Is there a way to get full profile of logged in user based on token?
I think that can be done easily during completion. Its just a suggestion ๐Ÿ‘

Is there a possibility to logout user ?
I have this case:

  1. enter credentials
  2. get user token
  3. get full profile by calling another API
  4. join in app(my app)
  5. logout from my app, and again login with LinkedIn
    At this point its automatically fetch token for credentials added first time, and no way to enter other credentials only if I delete the app from device.
    I think there should be a logout function just to remove initial data.

Thanks!

Question about Login flow

Hi,

right now on login it opens up the Authorise screen where user has to fill email and password, instead of that can I redirect to LinkedIn app and authorise there, considering if LinkedIn app is installed if not then redirect to browser.

Authorize Login token not shows

Its loaded the LInkedIn page and continues shows Loading ...!

After Configuration I have set the login
http://localhost:3000/auth/linkedin/callback

let linkedinCredentilas = [
"linkedInKey": "81g0jkvkqmoyas",
"linkedInSecret": "securityKeyValue",
"redirectURL": "http://localhost:3000/auth/linkedin/callback"
]

https://www.linkedin.com/uas/oauth2/authorization?response_type=code&client_id=81g0jkvkqmoyas&redirect_uri=http://localhost:3000/auth/linkedin/callback&state=linkedin1587169042&scope=r_basicprofile

Please let me know if I missed anything to make it work for SignIn via LInkedIn.

IMG_6031

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.