1. Go to this page and download the library: Download revolution/discord-manager library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
revolution / discord-manager example snippets
use Revolution\DiscordManager\Events\InteractionsWebhook;
use Revolution\DiscordManager\Facades\DiscordManager;
//
/**
* Handle the event.
*
* @param InteractionsWebhook $event
* @return void
*/
public function handle(InteractionsWebhook $event)
{
DiscordManager::interaction($event->request);
}
use App\Listeners\InteractionsListener;
use Revolution\DiscordManager\Events\InteractionsWebhook;
//
protected $listen = [
Registered::class => [
SendEmailVerificationNotification::class,
],
InteractionsWebhook::class => [
InteractionsListener::class,
],
];