Download the PHP package sumocoders/teamleader-oauth2 without Composer
On this page you can find all versions of the php package sumocoders/teamleader-oauth2. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download sumocoders/teamleader-oauth2
More information about sumocoders/teamleader-oauth2
Files in sumocoders/teamleader-oauth2
Package teamleader-oauth2
Short Description PHP Teamleader oauth2 package to connect with Teamleader API (https://developer.teamleader.eu/)
License BSD-2-Clause
Informations about the package teamleader-oauth2
Teamleader oauth2
Installation
composer require sumocoders/teamleader-oauth2
Setup
This package uses PSR-17 and PSR-18. You can use any implementation you want.
For saving the access we provide a TokenStorageInterface, where you'll need to implement storing and fetching of the tokens:
Look at the default token storage class how you can make your own implementation.
The Teamleader class will need a clientId and clientSecret. Which you'll need to obtain at the Teamleader marketplace.
Usage
To obtain an access token you'll need to call:
Where $redirectUrl
is the url you want Teamleader to come back to after Oauth2 authentication and $code
is for the return when Teamleader comes back to your site and validate the authentication.
After that you can use the Teamleader class to make calls to the Teamleader API. When the access token is expired the Teamleader class will automatically refresh the token.
Getting data
Posting data
All versions of teamleader-oauth2 with dependencies
psr/http-client Version ^1.0
psr/http-factory Version ^1.0
ext-json Version *