- Installs the base messenger files, publishing the config and service provider. This will also register the published service provider in your
app.php
config file inside the providers array.- You will be asked to confirm running this command, as well as an option to run the migrations before completion.
--uuids
flag when your provider models use UUIDs instead of auto-incrementing integers as their primary keys.--force
flag to overwrite any existing published files.
- Attaches the Messenger model to your existing registered provider records.
- By default, this will chunk queries for each of your providers at 100, looping through and checking if a
Messenger
model record exists for each provider, and creating one if it does not. - You will be asked to confirm running this command.
- By default, this will chunk queries for each of your providers at 100, looping through and checking if a
--provider=
flag you can set the singular provider you want to attach messengers for. Eg:--provider="App\Models\User"
--force
flag to attach messengers without checking if one exist for each provider.
- Check active calls for active participants, end calls with none.
--now
flag to run immediately without dispatching jobs to queue.
- End all active calls and disable the calling system for the specified minutes (30 default).
--duration=X
flag to set timeframe in minutes for calling to be disabled.--now
flag to run immediately without dispatching jobs to queue.
- Put the call system back online if it is temporarily disabled.
- Check active invites for any past expiration or max use cases and invalidate them.
--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted document messages that were archived past the set days (30 default). The document files will be removed from storage and message models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted audio messages that were archived past the set days (30 default). The audio files will be removed from storage and message models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted video messages that were archived past the set days (30 default). The video files will be removed from storage and message models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted image messages that were archived past the set days (30 default). The image files will be removed from storage and message models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted messages that were archived past the set days (30 default).
--days=X
flag to set how many days in the past to start at.
- Purge all soft deleted threads that were archived past the set days (30 default). The thread directories and sub files will be removed from storage and the thread models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Purge all soft deleted bots that were archived past the set days (30 default). The bot directories and sub files will be removed from storage and the bot models pruned from the database.
--days=X
flag to set how many days in the past to start at.--now
flag to run immediately without dispatching jobs to queue.
- Generates a new bot handler class. The class will be placed in your default
App
namespace, under theBots
directory. eg:App\Bots
name
The name of the generated bot handler class.
- Generates a new packaged bot class. The class will be placed in your default
App
namespace, under theBots
directory. eg:App\Bots
name
The name of the generated packaged bot class.
<?php
namespace App\Console;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
/**
* Define the application's command schedule.
*
* @param \Illuminate\Console\Scheduling\Schedule $schedule
* @return void
*/
protected function schedule(Schedule $schedule)
{
$schedule->command('messenger:calls:check-activity')->everyMinute();
$schedule->command('messenger:invites:check-valid')->everyFifteenMinutes();
$schedule->command('messenger:purge:threads')->dailyAt('1:00');
$schedule->command('messenger:purge:messages')->dailyAt('2:00');
$schedule->command('messenger:purge:images')->dailyAt('3:00');
$schedule->command('messenger:purge:documents')->dailyAt('4:00');
$schedule->command('messenger:purge:audio')->dailyAt('5:00');
$schedule->command('messenger:purge:bots')->dailyAt('6:00');
$schedule->command('messenger:purge:videos')->dailyAt('7:00');
}
}