laralabs/here-api-oauth2-client
最新稳定版本:3.0.2
Composer 安装命令:
composer require laralabs/here-api-oauth2-client
包简介
Easily get an OAuth 2.0 access token to use with the HERE API services
README 文档
README
HERE API OAuth 2.0 Client
Easily retrieve OAuth 2.0 bearer access token to use with the HERE API services.
🚀 Quick Start
Require the package in the composer.json of your project.
composer require laralabs/here-api-oauth2-client
Set the following variables in your env file, you can get these from the HERE Developer Site.
Check in the REST section for OAuth 2.0 Tokens.
HERE_OAUTH_ACCESS_ID="your-access-key-id"
HERE_OAUTH_ACCESS_SECRET="your-access-key-secret"
Now you can retrieve an access token using either the facade or helper function. The package will return an access token from the cache or request a new one if it has expired.
Helper function
$token = getHereApiToken();
Facade
use Laralabs\HereOAuth\Facade\HereOAuth; $token = HereOAuth::getToken();
👏 Credits
Special thanks to Roberto for his assistance in getting the signing working correctly, go check out his repositories if you're looking for a pure PHP library 👍
统计信息
- 总下载量: 621
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 6
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-03-16