Installation
Make sure you have a MySQL/MariaDB database set up and oxmysql properly configured before proceeding.
2
3
Database setup
Import the SQL file included in the resource to create the whitelist table:
CREATE TABLE IF NOT EXISTS `user_whitelist` (
`user_id` INT NOT NULL AUTO_INCREMENT,
`steam` VARCHAR(255) NOT NULL,
`discord` VARCHAR(255) DEFAULT NULL,
`whitelisted` TINYINT(1) DEFAULT 0,
`created_at` TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`user_id`),
UNIQUE KEY `steam` (`steam`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;Import this using your preferred MySQL client (phpMyAdmin, HeidiSQL, etc.).
4
5
Configuration
Resource configuration is handled in config.lua.
Config = {}
-- Discord server link for whitelist requests
Config.DiscordLink = "https://discord.gg/yE8qBjGjD9"
-- Localization
Config.Locale = "en" -- Available: en, ru, de, fr, es
-- Message when player is not whitelisted
Config.NotWhitelisted = "⚪ You are not in the whitelist. ⚠️ Your user_id = %s. Send it to Discord."
-- Command to add user to whitelist (admin only)
Config.WhitelistCommand = "addwl"Verification
To test the installation:
- Connect to your server without being whitelisted
- You should receive a message with your generated
user_id - Use
/addwl [user_id]as an admin to whitelist a player - The player can now connect normally
⚠️
This script fully complies with FiveM Releases rules. For support, join our Discord server (opens in a new tab).