caikeal/coding-open-api

Coding Open Api SDK

v1.0.4 2019-09-11 17:21 UTC

This package is auto-updated.

Last update: 2024-11-12 05:16:45 UTC


README

composer install caikeal/coding-open-api

Settings

获取配置项: php artisan vendor:publish --provider="CodingOpenApi\LaravelCoding\ServiceProvider"

Usage

...
use CodingOpenApi\LaravelCoding\Facade;

...

public function test () {
    return Facade::enterprise('ksbaozi')->access_token->getToken();
}

当用 refresh_token 刷新 access_token 时, 会同时更新原来的 refresh_token, 并会发出事件CodingOpenApi\Enterprise\Events\RefreshTokenChanged

注意:首次生成 refresh_token 是不会触发该事件的

Thanks

overtrue