> For the complete documentation index, see [llms.txt](https://dtrx-studio.gitbook.io/dtrx-studio-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dtrx-studio.gitbook.io/dtrx-studio-docs/fivem-products/dtrx-chat/installation-guide.md).

# Installation Guide

{% stepper %}
{% step %}

## Install dependencies

{% hint style="danger" %} <mark style="color:yellow;">**Verify all dependencies below are started**</mark><mark style="color:yellow;">**&#x20;**</mark>*<mark style="color:yellow;">**before**</mark>*<mark style="color:yellow;">**&#x20;**</mark><mark style="color:yellow;">**this script in your**</mark> **`server.cfg`**<mark style="color:yellow;">**.**</mark>
{% endhint %}

**Required**

| Resource      | Purpose                                                                                                                                                    |
| ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **oxmysql**   | Database driver for messages, settings, channels, sticky notes, PM, admin logs. [Download oxmysql](https://github.com/CommunityOx/oxmysql/releases/latest) |
| **Framework** | One of: **qb-core**, **qbx\_core** (QBox), **es\_extended** (ESX Legacy). Or **custom** via `public/bridge/framework/`.                                    |

**Optional**

| Resource       | Purpose                                                                                                               |
| -------------- | --------------------------------------------------------------------------------------------------------------------- |
| **ox\_lib**    | Preferred notifications when auto-detected. [Download ox\_lib](https://github.com/CommunityOx/ox_lib/releases/latest) |
| **okokNotify** | Alternative notify bridge when `ox_lib` is not used.                                                                  |
| {% endstep %}  |                                                                                                                       |

{% step %}

## Disable the native FiveM chat

{% hint style="warning" %}
DTRX Chat **replaces** the built-in `chat` resource (`provide 'chat'` in `fxmanifest.lua`). You must disable system chat and remove conflicting resources **before** starting `dtrx_chat`.
{% endhint %}

Add or update these convars **at the top** of `server.cfg` (before any `ensure` lines):

```cfg
set resources_useSystemChat false
set chat_showJoins false
set chat_showQuits false
```

**Remove or comment** every line like:

```cfg
# ensure chat
# ensure chat-theme-gtao
# ensure qbx_chat_theme
# ensure esx_chat_theme
# ensure esx_rpchat
```

| Framework     | Also remove                                   |
| ------------- | --------------------------------------------- |
| **QBox**      | `qbx_chat_theme`                              |
| **QBCore**    | `chat-theme-gtao` (cfx-default gameplay pack) |
| **ESX**       | `esx_rpchat`, `esx_chat_theme` (if present)   |
| {% endstep %} |                                               |

{% step %}

## Install DTRX Chat

### Install resource from [Portal](https://portal.cfx.re/assets/granted-assets)

**After installing, you should get a zip file with the name shown below.**

* <mark style="color:yellow;">dtrx\_chat.pack.zip</mark>

{% hint style="info" %}
Creating a subfolder (e.g. `[dtrx]/dtrx_chat`) is optional but **highly recommended** for large servers.
{% endhint %}

1. Extract the **full** resource into your server, for example:\
   `resources/[dtrx]/dtrx_chat/`

<div align="left"><figure><img src="/files/MP8EkdoFmS5jjIOY9nct" alt=""><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}

#### Add ACE permission

Open `server.cfg` (or `permissions.cfg` on Qbox) and add:

```cfg
add_ace group.admin dtrx_chat.admin allow
```

**or** grant a single license:

```cfg
add_ace identifier.license:xxxxxxxxxxxx dtrx_chat.admin allow
```

{% hint style="danger" %} <mark style="color:$warning;">**Important:**</mark> On **Qbox**, the recommended place for ACE lines is often `permissions.cfg` instead of `server.cfg`.
{% endhint %}

{% hint style="info" %}
**Alternative:** framework job groups `admin`, `god`, and `superadmin` are whitelisted by default in `ChatConfig.Admin.FrameworkGroups`. You can add more groups in `public/shared/config.lua` without ACE  but ACE is still the standard for staff tools.
{% endhint %}
{% endstep %}

{% step %}

#### Update `server.cfg` and perform a full restart

{% hint style="info" %}
Place `ensure dtrx_chat` at the **bottom** of your resource start list, **after** oxmysql and your framework:
{% endhint %}

```cfg
ensure oxmysql
ensure ox_lib          # optional
ensure qbx_core        # OR qb-core OR es_extended
# ... inventory, target, other resources ...
ensure dtrx_chat
```

{% hint style="success" %}
**Note:** After a clean install, press **T** in-game to open chat. Admins can run `/chatadmin` to open the Admin Panel (Channels, Players, Runtime Settings, Control Messages, Themes).
{% endhint %}

{% hint style="danger" %}
If you run a **custom framework** or **custom notify**, read Integrations and Configurations to align `ChatConfig.Bridge` and optional files under `public/bridge/`.
{% endhint %}

{% hint style="warning" %}
Perform a **full server restart** after the first install. Restarting only `dtrx_chat` is enough for updates, but the first install should be a full boot so ACE and convars apply cleanly.
{% endhint %}
{% endstep %}
{% endstepper %}

***

### Framework-specific notes

{% tabs %}
{% tab title="QBOX" %}

#### QBox

Folders Structure ( Hight Recommend)

<div align="left"><figure><img src="/files/gTAvKz5u34BvBXzt1J0A" alt=""><figcaption></figcaption></figure></div>

Server CFG Structure

```cfg
# ensure qbx_chat_theme   ← remove
set resources_useSystemChat false
ensure oxmysql
ensure qbx_core
ensure dtrx_chat
```

Bridge auto-detects `qbx_core`. Optional force in `config.lua`:

```lua
Bridge = {
    Framework = "qbx_core",
    Notify    = "ox_lib",
},
```

{% endtab %}

{% tab title="QBCore" %}

#### QBCore

Folders Structure ( Hight Recommend)

<div align="left"><figure><img src="/files/4WvIo8GzSlhHZ5nELFFk" alt=""><figcaption></figcaption></figure></div>

Server CFG Structure

```cfg
# ensure chat-theme-gtao  ← remove
ensure oxmysql
ensure qb-core
ensure dtrx_chat
```

Bridge auto-detects `qb-core`. Optional force in `config.lua`:

```lua
Bridge = {
    Framework = "qb-core",
    Notify    = "qbcore",
},
```

{% endtab %}

{% tab title="ESX Legacy" %}

#### ESX Legacy

Folders Structure ( Hight Recommend)

<div align="left"><figure><img src="/files/PMnlmbvF8hZCedVNGtez" alt=""><figcaption></figcaption></figure></div>

Server CFG Structure

```cfg
# ensure esx_rpchat
# ensure esx_chat_theme
ensure oxmysql
ensure es_extended
ensure dtrx_chat
```

Bridge auto-detects `es_extended`. Optional force in `config.lua`:

```lua
Bridge = {
    Framework = "es_extended",
    Notify    = "esx",
},
```

{% endtab %}
{% endtabs %}

***


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://dtrx-studio.gitbook.io/dtrx-studio-docs/fivem-products/dtrx-chat/installation-guide.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
