
- ESX
By Luke

To connect txAdmin to Discord, create a dedicated Discord application and bot, invite it to the correct server with only the permissions it needs, copy the bot token into txAdmin's Discord settings, and configure status messages and role-based access as separate features. Keep the token private: it authenticates the bot and should never appear in screenshots, client files or a public repository.
| Part | Purpose | Typical failure |
|---|---|---|
| Discord application and bot | Identity used by txAdmin | Wrong application, disabled bot or regenerated token |
| Server status | Publishes or updates status in a chosen channel | Wrong channel or missing view/send/embed permissions |
| Roles or whitelist | Maps Discord membership/roles to the configured access rule | Wrong server/role ID, role hierarchy or member intent requirement |
| txAdmin permissions | Controls who may administer the FiveM server | Discord role assumed to grant txAdmin rights automatically |
Do not debug these as one feature. First prove that the bot is online, then prove it can access one channel, then add status behavior, and only then test optional role or whitelist logic.
A bot token is a secret, not an application ID or public key. If it is exposed, reset it in Discord and update txAdmin immediately. Store the replacement only in the server-side setting intended for the token.
Use Discord's OAuth2 installation flow for the application and select the bot scope required by the current setup. Start with the smallest channel permissions that satisfy the feature: view the selected channel, send messages, embed links and read message history where status updating needs it. Avoid Administrator unless the official integration explicitly requires it and you have reviewed why.
Restrict the bot to a dedicated status or administration channel where practical. After inviting it, confirm it appears in the intended Discord server. Being listed as offline is expected until txAdmin successfully logs in with the token.
Open txAdmin as an authorized administrator and locate the Discord integration settings in your installed release. Paste the token into the token field without quotes or extra whitespace. Select the intended Discord server and channel using the inputs txAdmin provides. Save, then restart only the component or server if the interface requests it.
If you are building the FiveM side from scratch, use the FiveM server setup path first. Discord cannot repair an unhealthy FXServer or an unreachable txAdmin instance.
Enable the status feature and select a channel where the bot can post. Start with a plain test update before adding custom wording or embeds. Confirm that the message changes when the FiveM server starts, stops or changes player count according to the behavior documented by your txAdmin version.
If the bot logs in but no status appears, check the selected channel ID and channel-specific overrides. A server-wide role may allow sending while a channel override denies it. Also inspect txAdmin's console/log output for the Discord API response rather than repeatedly regenerating the token.
Role-based access requires the exact Discord server and role identifiers expected by the integration. Enable Discord's developer mode to copy IDs when the current setup asks for them. Role names are not stable identifiers and two roles may share a similar name.
Test with one account that has the required role and one that does not. Remove and re-add the role, reconnect, and confirm when the integration refreshes membership. Do not assume a Discord role automatically grants txAdmin administrator permissions; txAdmin's own permission model remains a separate control unless the documented feature explicitly maps them.
| Symptom | Check |
|---|---|
| Bot stays offline | Token belongs to the correct bot, contains no whitespace, has not been reset, and txAdmin logs show a login attempt |
| Bot is online but cannot post | Selected channel, view/send/embed permissions and channel overrides |
| Status never updates | Status feature enabled, correct channel, txAdmin/FXServer state and integration log |
| Role member is rejected | Correct server/role ID, role actually assigned, refresh/reconnect behavior and any required member intent |
| Unauthorized member is accepted | Fallback access rules, multiple allowed roles and server-side permission configuration |
| It stopped after a token reset | txAdmin still has the old token; save the new one and restart as required |
Once these checks pass independently, the integration is easier to maintain: one bot identity, one protected secret, narrowly scoped channel access and explicit rules for status, whitelist and administration.
Cfx.re — txAdmin · Source: docs.discord.com · Source: docs.discord.com





