> For the complete documentation index, see [llms.txt](https://docs.lenoscripts.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lenoscripts.com/scripts/lenoreports/customization.md).

# Customization

Customize categories, language, appearance, permissions, and integration bridges.

Start with the supplied configuration and change one area at a time. Keep copies of your customized files so you can reapply your changes when updating the resource.

## Editable files

| File or folder       | Purpose                                                                               |
| -------------------- | ------------------------------------------------------------------------------------- |
| `config.lua`         | Framework, inventory, notification backend, categories, limits, commands, and actions |
| `locales/*.json`     | Text connected to the locale system                                                   |
| `web/theme.css`      | Theme overrides for the packaged interface                                            |
| `bridge/**`          | Framework, inventory, screenshot, and notification integrations                       |
| `shared/**`          | Shared helpers                                                                        |
| `client/main.lua`    | Client hooks for opening the UI and starting actions                                  |
| `server/main.lua`    | Server hooks for access and report lifecycle behavior                                 |
| `server/exports.lua` | Public export wrappers                                                                |

These paths are listed as editable in the resource's escrow configuration. Public export signatures are integration contracts: preserve them when customizing behavior. See [Exports and Events](/scripts/lenoreports/exports-and-events.md).

## Categories

Each entry in `Config.Categories` has three fields:

| Field   | Meaning                                                                      |
| ------- | ---------------------------------------------------------------------------- |
| `key`   | Persistent database value; also used when creating reports through an export |
| `label` | Text displayed to users                                                      |
| `color` | Hex color in `#rrggbb` form                                                  |

Use unique, stable keys. The database category column holds up to 32 characters. Renaming a key does not rename the category on existing reports.

```lua
Config.Categories = {
    { key = 'player_report', label = 'Player Report', color = '#c4b5fd' },
    { key = 'bug_report', label = 'Bug Report', color = '#fdba74' },
    { key = 'other', label = 'Other', color = '#a1a1a1' },
}
```

An integration should send `category = 'player_report'`, not `category = 'player'`.

## Report limits

`Config.Reports` controls creation cooldown, maximum active reports authored by each identity, and subject/description lengths. A value of `0` disables the creation cooldown or active-report limit respectively.

The default subject maximum is 30; the database subject column holds up to 64 characters. Keep the configured maximum within that storage limit. The current Lua truncation uses bytes rather than Unicode characters, so validate titles/descriptions with the languages used on your server.

## Language files

1. Copy the complete `locales/en.json` to a new file, for example `locales/pt.json`.
2. Translate the string values while keeping the same keys and nested structure.
3. Preserve placeholders such as `%s` and `{count}` in the strings that contain them.
4. Set `Config.Locale = 'pt'` without a file extension.
5. Restart the resource and check the translated messages in game.

## Interface theme

Edit the existing rules and overrides in `web/theme.css` to customize the packaged interface. Keep the supplied selectors and variable names, and check contrast for text, borders, buttons, and category badges in game after changing colors.

## Commands and notifications

Change `Config.UI.playerCommand`, `staffCommand`, and their key settings for the menus. `Config.StaffNotify.openKey` controls the last-report notification shortcut. See [Commands](/scripts/lenoreports/commands.md) and the [User Guide](/scripts/lenoreports/user-guide.md#set-staff-duty-and-receive-notifications).

Select `Config.Notify` explicitly: `default`, `ox_lib`, `okokNotify`, `qb`, `esx`, or `custom`. Start the selected external resource before LenoReports.

For a custom notification system, implement the adapter under `bridge/notify/custom`. The generic client hook is `Bridge.Notify(message, type, duration, title)`; `Bridge.StaffNotify(payload)` can handle the richer staff-notification fields when needed.

## Inventory bridges

Inventory integration supplies the captured item list for report investigations. Select a supported bridge with `Config.Inventory`.

For a custom adapter, select `Config.Inventory = 'custom'` and implement `InvBridge.GetInventory(source)` in `bridge/inventory/custom/server.lua`. The supplied custom stub does not already implement this full-inventory read.

Return a flat table of item entries. Supported item fields include `name` (or `item`), `label`, `count` (or `amount` / `quantity`), and optional `metadata` (or `info`). Unwrap containers such as `inventory.items` in your adapter before returning them.

Example **return shape** for an adapter, using illustrative items:

```lua
return {
    { name = 'water', label = 'Water', count = 2 },
    { name = 'sandwich', label = 'Sandwich', count = 1 },
}
```


---

# 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://docs.lenoscripts.com/scripts/lenoreports/customization.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.
