vcmeet / laravel-jitsi
Meeting management package extracted from Laravel application
Requires
- php: ^8.0
- laravel/framework: ^9.0|^10.0|^11.0
Requires (Dev)
- orchestra/testbench: ^8.0|^9.0
- phpunit/phpunit: ^10.0|^11.0
This package is auto-updated.
Last update: 2026-05-09 14:18:21 UTC
README
A Laravel package for managing Jitsi meetings with participants, scheduling, and real-time status tracking. Extracted from a production Laravel application for easy integration into any Laravel project.
Requirements
- PHP 8.1+
- Laravel 10.0+ or 11.0+
- MySQL/PostgreSQL/SQLite database
Installation
Via Composer (Recommended)
composer require vcmeet/laravel-jitsi
Local Development
Add this to your host app's composer.json:
"repositories": [ { "type": "path", "url": "./packages/vcmeet/laravel-jitsi", "options": { "symlink": true } } ]
Then run:
composer require vcmeet/laravel-jitsi:@dev
Configuration
1. Publish the configuration file:
php artisan vendor:publish --tag=laravel-jitsi-config
This creates config/meeting.php where you can customize:
- Default meeting duration
- Meeting code length
- Participant statuses
- Model references
2. Publish the migration files:
php artisan vendor:publish --tag=laravel-jitsi-migrations
3. Run the migrations:
php artisan migrate
4. (Optional) Publish views for customization:
php artisan vendor:publish --tag=laravel-jitsi-views
Usage
Creating a Meeting
use VcMeet\Jitsi\Models\Meeting; use Illuminate\Support\Str; // Create a new meeting $meeting = Meeting::create([ 'code' => Str::random(10), 'host_id' => auth()->id(), 'start_time' => now()->addMinutes(15), // Optional: schedule for future 'duration_minutes' => 60 ]); // Access meeting properties echo $meeting->code; // Random 10-character code echo $meeting->host_id; // Host user ID echo $meeting->participants; // Related participants
Managing Participants
use VcMeet\Jitsi\Models\MeetingParticipant; // Add a participant to a meeting $participant = MeetingParticipant::create([ 'meeting_id' => $meeting->id, 'user_id' => $userId, 'status' => 'waiting' // waiting, approved, or kicked ]); // Update participant status $participant->status = 'approved'; $participant->save(); // Check participant status if ($participant->status === 'approved') { // User can join the meeting }
Available Routes
The package provides the following routes (all require authentication):
| Method | URI | Name | Description |
|---|---|---|---|
| GET/POST | /meeting/create |
meeting.create |
Create a new meeting |
| GET | /meeting/{code} |
meeting.join |
Join a meeting by code |
| POST | /meeting/{code}/approve |
meeting.approve |
Approve a participant |
| POST | /meeting/{code}/kick |
meeting.kick |
Kick a participant |
| GET | /meeting/{id}/ended |
meeting.ended |
Meeting ended page |
| GET | /meeting/{code}/time-remaining |
- | Get remaining time (JSON API) |
| GET | /meetings |
meetings.index |
List all meetings |
Using the Facade
use VcMeet\Jitsi\Facades\Jitsi; // Access configuration $defaultDuration = config('meeting.default_duration_minutes'); // 60 $codeLength = config('meeting.code_length'); // 10
Real-time Time Tracking
The package includes a JavaScript-based timer that syncs with the server:
// The join.blade.php view includes a timer that: // 1. Fetches remaining time from `/meeting/{code}/time-remaining` // 2. Updates every second with server time // 3. Shows warnings when time is running out // 4. Automatically redirects when meeting ends
Testing
Running Tests
# From the package directory ./vendor/bin/phpunit # With coverage ./vendor/bin/phpunit --coverage-html build/coverage
Test Structure
tests/Feature/MeetingTest.php- Feature tests for routes and functionalitytests/Unit/MeetingModelTest.php- Unit tests for modelstests/TestCase.php- Base test case with Testbench setup
Available Artisan Commands
The package doesn't include custom commands yet, but you can use standard Laravel commands:
# Run migrations php artisan migrate # Publish package files php artisan vendor:publish --tag=laravel-jitsi-config php artisan vendor:publish --tag=laravel-jitsi-migrations php artisan vendor:publish --tag=laravel-jitsi-views
Configuration Options
Edit config/meeting.php after publishing:
return [ 'default_duration_minutes' => 60, // Default meeting duration 'code_length' => 10, // Length of meeting codes 'participant_statuses' => [ 'waiting', 'approved', 'kicked' ], 'meeting_model' => \VcMeet\Jitsi\Models\Meeting::class, 'participant_model' => \VcMeet\Jitsi\Models\MeetingParticipant::class, ];
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Run the test suite
- Submit a pull request
License
MIT License - see LICENSE file for details.
Changelog
1.0.0
- Initial release
- Meeting management functionality
- Participant approval system
- Real-time time tracking
- Full test coverage
- Laravel auto-discovery support