With this package you can create Zoom meetings from your Laravel application using Server-To-Server OAuth.
You can install the package via composer:
composer require philharmonie/laravel-zoom-meetings
You can publish the config file with:
php artisan vendor:publish --tag="zoom-meetings-config"
This is the contents of the published config file:
return [
'account_id' => env('ZOOM_ACCOUNT_ID'),
'client_id' => env('ZOOM_CLIENT_ID'),
'client_secret' => env('ZOOM_CLIENT_SECRET'),
'base_url' => 'https://api.zoom.us/v2/',
'token_url' => 'https://zoom.us/oauth/token',
];
Create a Server-to-Server OAuth app in your Zoom account following this
instruction: https://developers.zoom.us/docs/internal-apps/create/.
You will need the user:read:admin meeting:write:admin
scopes.
Save the Account ID, Client ID and Client Secret in your .env
file.
$access_token = Auth::getToken();
$meeting = Meeting::setAccessToken($access_token)->create([
'topic' => 'Test Meeting',
'type' => 2,
'start_time' => now()->addDay()->startOfHour()->format('Y-m-d\TH:i:s'),
'duration' => 60,
], '[email protected]');
See the test cases for more usage examples.
cp phpunit.xml.dist phpunit.xml
Update the environment variables in phpunit.xml
:
<php>
<env name="ZOOM_ACCOUNT_ID" value=""/>
<env name="ZOOM_CLIENT_ID" value=""/>
<env name="ZOOM_CLIENT_SECRET" value=""/>
<env name="ZOOM_EMAIL_ACCOUNT" value=""/>
</php>
Run
composer test
Please see CHANGELOG for more information on what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security-related issues, please email [email protected] instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.