PHP code example of hskrasek / laravel-zero-oauth
1. Go to this page and download the library: Download hskrasek/laravel-zero-oauth library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
hskrasek / laravel-zero-oauth example snippets
use HSkrasek\LaravelZeroOAuth\Auth\Keyring;
// ...
public function handle(Keyring $keyring)
{
$token = $keyring->get('access_token');
// Use the token to make requests to your provider.
Http::withToken($token->accessToken)->get('https://api.example.com');
}