mark-domkan/env-token-auth
Composer 安装命令:
composer require mark-domkan/env-token-auth
包简介
Adds the ability to use environtment token for the auth:api middleware.
README 文档
README
Adds the ability to use token saved in env for the auth:api middleware.
Install
-
Install the package with composer:
composer require markdomkan/env-token-auth
-
Set the api guard driver to
env-tokenin the fileconfig/auth.php:'guards' => [ // ... 'api' => [ 'driver' => 'env-token', // <- Change this FROM token TO env-token // ... ], ],
Usage
-
Add
AUTH_TOKENin .env file. -
Make a call with Authorization header with token (without Bearer).
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 78
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-03-15