PHP code example of sngular / sngulauth

1. Go to this page and download the library: Download sngular/sngulauth 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/ */

    

sngular / sngulauth example snippets

ruby
$token = $auth->authByCode($_GET['code']);

$user = $auth->getResourceOwner($token);

$userData = $auth->decryptResponse($token->getToken());