oauth2.0 client for mobile
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src
README.md
composer.json

README.md

Oauth-client

Oauth-client is use for the third-part account login verify on the backend server.
It support Google, Facebook, Weixin, Weibo etc.

How to use it

$id = '{Google account id}';
$token = '{Google login account token}';
$option = [
    'clientId' => '{Google app id}'
];
try {
    $oauth = new OauthAdaptor('google', $option);
    $user = $oauth->verify($id, $token);
    print_r($user);
} catch (\Exception $e) {
    echo $e->getMessage();
}