ansjabar/laravel-agora-token

Generate Agora authentication token

0.1.0 2022-11-23 08:42 UTC

This package is auto-updated.

Last update: 2024-03-23 12:20:38 UTC


README

Generate Agora authentication tokens.

Installation

Require this package with composer.

$ composer require ansjabar/laravel-agora-token

Integration

$ php artisan vendor:publish --provider="AnsJabar\LaravelAgoraToken\AgoraServiceProvider"

Add AGORA_APP_ID, AGORA_CERTIFICATE and 'AGORA_TOKEN_EXPIRE_TIME to your .env file.

Usasge

\AnsJabar\LaravelAgoraToken\Agora::appToken(); // To get app token
\AnsJabar\LaravelAgoraToken\Agora::userToken($uuid); // To get user token from its uuid
\AnsJabar\LaravelAgoraToken\Agora::userAccountToken("username"); // To get user token from uts username

License

This laravel-teams-logger package is available under the MIT license. See the LICENSE file for more info.