> For the complete documentation index, see [llms.txt](https://theobsidianstudio-1.gitbook.io/theobsidianstudio-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://theobsidianstudio-1.gitbook.io/theobsidianstudio-docs/assets/obs_adminmenu/core-configuration.md).

# CORE CONFIGURATION

The entire architecture of OBS Admin is controlled from a single, centralized command file: `shared/config.lua`. This file grants you unprecedented, surgical control over every layer of the ecosystem.

{% hint style="danger" %}
**Developer Note** Please ensure you use a proper code editor (like Visual Studio Code) when modifying the configuration. The LUA parser is highly strict; a single missing comma `,` can break the entire file architecture and halt the boot sequence.
{% endhint %}

***

### 🧭 Intelligent Hook Engine & Routing

OBS Admin utilizes a dynamic routing engine. By leaving these variables on `'auto'`, the script will dynamically hook into your active resources, bypassing the need for tedious manual configuration. It intelligently maps its internal functions to match your server's DNA.

```lua
-- ─── FRAMEWORK & INVENTORY INTEGRATION ────────
Config.Framework = 'auto'    -- Supports: 'auto', 'esx', 'qbcore', 'custom'
Config.Inventory = 'auto'    -- Supports: 'auto', 'ox_inventory', 'qs-inventory', 'qb-inventory', 'esx'
Config.Target    = 'auto'    -- Supports: 'auto', 'ox_target', 'qb-target', 'none'
```

***

### 🎨 Fluid UI Branding & Identity

Make the dashboard feel like a native, bespoke extension of your server. Customize the UI to match your community's exact color palette and brand identity. The React frontend will dynamically calculate shades and gradients based on your chosen HEX code to ensure perfect contrast and accessibility.

```lua
Config.ServerName    = 'OBS ADMIN'
Config.ServerTagline = 'Staff Portal'
Config.ServerLogo    = 'img/obsidian.png'  -- Use a local PNG in html/img/ OR paste a direct Imgur URL!
Config.AccentColor   = '#3b82f6'           -- Accepts any standard HEX code for UI highlights.
```

***

### ⌨️ Tactical Keybind Architecture

We understand every server has a complex web of keybind conflicts. OBS Admin allows absolute, total control over how staff access the interface, ensuring it never overlaps with your existing scripts.

* **`Config.Commands.AdminMenu`** = `'admin'` - Type `/admin` to open the panel natively.
* **`Config.OpenKey`** = `'F10'` - Hard keybind to invoke the web dashboard.
* **`Config.InGameMenuKey`** = `'F11'` - Opens the rapid, low-latency in-game UI.
* **`Config.DutyKey`** = `'F9'` - Clocks staff on and off duty with a visual indicator.
* **`Config.NoclipKey`** = `'b'` - Instantly noclip. *(Avoid '/' or 'T' to prevent chat input overlap)*.
* **`Config.Commands.Widget`** = `'wc'` - Reposition Live Activity widgets to any corner of your monitor (e.g., `/wc activity tr`).

***

### 📝 Announcement Templates & Ban Presets

Optimize your administration workflow by creating predefined interaction templates. Instead of typing out *"Server Restarting in 5 Minutes"* repeatedly during a crisis, staff can execute these payloads with a single click.

```lua
Config.AnnouncementTemplates = {
    { label = '🔄 Server Restart',   title = 'SERVER ANNOUNCEMENT', message = 'The server will restart in 5 minutes. Please find a safe location.' },
}

Config.BanReasons = {
    'Hacking / Cheating',
    'Exploiting Game Bugs',
}

Config.BanDurations = {
    { label = '30 Minutes', value = 30    },
    { label = 'Permanent',  value = -1    }, -- Set value to -1 for permanent, irreversible bans
}
```

***

### 📡 Exhaustive Logging Systems

OBS Admin provides an exhaustive, military-grade logging system that can output data to local storage files, your in-game terminal, and Discord webhooks simultaneously, guaranteeing total accountability.

{% tabs %}
{% tab title="Standard Logging" %}

```lua
Config.LogToFile      = true  -- Saves to a highly compressed local text file on your server
Config.LogToDiscord   = true  -- Transmits actions to a secure Discord channel
Config.DiscordWebhook = 'YOUR_WEBHOOK_URL_HERE'
Config.DiscordBotName = 'OBS Admin'
```

{% endtab %}

{% tab title="Combat & Activity Logs" %}
⚠️ **Performance Warning:** Setting `EnableWeaponFire = true` will log every single bullet fired on the server. This generates an immense amount of data and should only be used temporarily when conducting a deep-dive investigation into a specific suspect.

```lua
Config.CombatLogs = {
    EnableKills      = true,    -- Log player deaths/kills
    EnableDamage     = true,    -- Log player damage
    EnableWeaponFire = false,   -- Log every single bullet fired
    DiscordWebhook   = '',      -- Dedicated webhook for combat data streams.
}
```

{% 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, and the optional `goal` query parameter:

```
GET https://theobsidianstudio-1.gitbook.io/theobsidianstudio-docs/assets/obs_adminmenu/core-configuration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
