PHP code example of abenevaut / laravel-discord-client

1. Go to this page and download the library: Download abenevaut/laravel-discord-client 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/ */

    

abenevaut / laravel-discord-client example snippets


'discord' => [
    'baseUrl' => 'https://discord.com/api', // Discord API URL
    'debug' => env('BLUESKY_DEBUG', false), // Debug mode
],

use Abenevaut\DiscordClient\Facades\Discord;

Discord::getClient(): DiscordClient; // Get the Discord client
Discord::countFollowers(string $invitationLink): int; // Get the number of followers of a discord server, invitation link looks like "https://discord.gg/pwwPEXcFfU" (prefer the use link without expiration)