Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to get accessToken? #160

Open
RomeoDavide91 opened this issue May 9, 2018 · 1 comment
Open

how to get accessToken? #160

RomeoDavide91 opened this issue May 9, 2018 · 1 comment

Comments

@RomeoDavide91
Copy link

RomeoDavide91 commented May 9, 2018

Q A
Bug? no
New Feature? no
Are you using composer? yes

I'm trying to get accessToken through queues.

There is no function that I am looking for.

The function should be:

$linkedIn = new Happyr\LinkedIn\LinkedIn($oauthToken, $oauthSecret);
$accessToken = $linkedIn->getAccessToken($codeToken);

how do I receive the access token?

@RomeoDavide91 RomeoDavide91 changed the title accessToken how to get accessToken? May 9, 2018
@SuperToma
Copy link

SuperToma commented Jun 1, 2018

I find the way.

That's not explicit in the doc...

  1. Instanciate the library
    $this->linkedIn = new LinkedIn(self::LINKED_IN_API_KEY, self::LINKED_IN_CLIENT_SECRET);

  2. Generate the auto-connect link :
    echo '<a href="'.$this->linkedIn->getLoginUrl().'" >Click here</a>';

  3. You can get the token :
    $this->linkedIn->getAccessToken();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants