[FREE] Discord Whitelist

Discord Whitelist
A very simple discord whitelist script I made because I was bored and wanted to learn a little how the discord apis work.

When a player are not whitelisted its coming up a adaptive card where you can customize and set your own logotype and on the button you can navigate to your discord server.

Config

Config.Settings = {
    discord = {
        discordGuildId = , -- https://gyazo.com/5aa52f81977372e26f75c9ce07db7c83.
        botToken = '', -- You have to create a bot here (https://discord.com/developers/applications) then add it into your server and copy the bot token and paste it where its blank.
    },

    whitelistRole = , -- What role that have access to your the server (https://gyazo.com/fc9677afd09e62fceea3a4115e108c7a)

    lang = {
        notWhitelisted = 'You are not whitelisted on (Server Name)',
        checkConnection = 'Check that you have connected your discord with FiveM',
        joinDiscord = 'Join our discord here'
    },

    card = {
        image = 'https://cdn.discordapp.com/attachments/1022227022967218206/1082954076783923230/TransparentVertex.png',
        discordUrl = 'https://discord.com/invite/yourdiscord'
    }
}

Download here

Code is accessible Yes
Subscription-based No
Lines (approximately) 75
Requirements Nothing
Support No
4 Likes

you have a unused call to esx

I did, forgot to remove it.

Update

  • Added a adaptive card when you are not whitelisted.
  • You can now add your logotype.
  • Navigate to your own discord on the button.

Hey good job !, but you should do a cache system, bc the api discord have a limit and u could be shadow ban (i think?) if u do too many requests

Ooh thats probably true, I might fix that tomorrow didn’t really think about that.

u updatet id ?

bro ?

No, i have much in school right now so i dont really have the time to fix it

hi, when u enter appear this https://forum.cfx.re/uploads/default/original/4X/5/5/6/55682198f6bbdc568a5f5266d7fd57845f7aea09.png but like in 2 second after appear this Imgur: The magic of the Internet

Hey, you need to invite the bot to the discord server that you used in the cfg.

@dillish Great release though <3

it’s already in my discord