> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aps-store.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Compability

`config/config.compat.lua` — frameworks, inventories, society accounts, licenses and other scripts.

## Supported resources

| Area | Supported | Option |
| - | - | - |
| Framework | ESX Legacy, QBCore, Qbox | `Config.Framework` |
| Target | ox\_target, qb-target, or proximity prompt | `Config.Interaction.type` |
| Notifications | vms\_notifyV2, okokNotify, ESX, QBCore, ox\_lib, or your own function | `Config.Settings.notifyType`, `Config.Notify` |
| Inventory | ox\_inventory, qs-inventory, origen\_inventory, tgiann-inventory, core\_inventory, framework inventories (qb-inventory, ps-inventory, ESX…) | `Config.Inventory` |
| Society accounts | esx\_addonaccount, qb-banking, qb-management, Renewed-Banking, vms\_bossmenu | `Config.Society` |
| Licenses | esx\_license, Buty-license, QBCore / Qbox `metadata.licences` | `Config.LicenseSync` |
| Vehicles | `owned_vehicles` / `player_vehicles`, custom columns | `Config.DB`, `Config.OwnedVehiclesColumns` |
| Phones | sd-phone, LB Phone, 17Movement Phone, YSeries, qs-smartphone-pro, GKSPhone, qb-phone, any other phone through `Config.PhoneCustom` | `Config.Phone` (see [Phone](https://docs.aps-store.com/assets/aps_cityhall/guides/phone-integration.md)) |
| Other scripts | vms\_cityhall export names, `esx_billing:sendBill` | `Config.Compat` |

## Framework

```lua theme={null}
Config.Framework = 'auto'   -- 'auto' | 'esx' | 'qbcore' | 'qbox'
```

`'auto'` checks `qbx_core`, then `qb-core`, then `es_extended`. Players are identified by the ESX `identifier` or the QBCore / Qbox `citizenid`. Everything framework-specific lives in `bridge/`, which stays editable when the resource is escrowed.

## Inventory

```lua theme={null}
Config.Inventory = 'auto'   -- 'auto' | 'ox_inventory' | 'qs-inventory' | 'origen_inventory'
                            -- | 'tgiann-inventory' | 'core_inventory' | 'framework'
```

`'auto'` picks the first one that is started in that order. Usable document items on origen\_inventory, tgiann-inventory and core\_inventory go through the framework's usable-item system, as they do for those inventories' own items. The origen and tgiann bridges try both export spellings those inventories have used (`AddItem` / `addItem`…); if your version differs, edit `bridge/sv_bridge.lua`, which stays editable when escrowed.

Used for `Config.PaymentItem` and document items. Give a document type an `item` to hand it out when ordered. On ox\_inventory it gets `holder`, `expires` and `description` metadata:

```lua theme={null}
-- config/documents.lua
{ id = 'id_card', name = 'ID Card', item = 'id_card', icon = 'CreditCard', options = { … } },
```

## Society accounts

```lua theme={null}
Config.Society = {
    system         = 'auto',  -- 'auto' | 'esx_addonaccount' | 'qb-banking' | 'qb-management'
                              -- | 'Renewed-Banking' | 'vms_bossmenu' | 'none'
    payBills       = true,    -- pay the society's share when a player pays a bill
    defaultPercent = 100,     -- share when the bill has no percentageForSociety
}
```

The society comes from the bill's `society` (`'society_police'`) or `job` (`'police'`). `'auto'` uses vms\_bossmenu when it's running, otherwise esx\_addonaccount (ESX), qb-banking → qb-management (QBCore) or Renewed-Banking → qb-banking (Qbox).

## License sync

Licenses earned in the License Center are also granted in the framework, so police, gun shops and other scripts see them.

```lua theme={null}
Config.LicenseSync = {
    system = 'auto',   -- 'auto' | 'esx_license' | 'Buty-license' | 'metadata' | 'none'
    butyCategories = { firearms = 'weapon' },   -- Buty-license category (default 'driving')
    map = {
        esx = { car = 'drive', motorcycle = 'drive_bike', truck = 'drive_truck', boat = 'boat', firearms = 'weapon' },
        qb  = { car = 'driver', motorcycle = 'driver', truck = 'driver', firearms = 'weapon' },
    },
}
```

Licenses not listed in the map are not synced. `'auto'` uses esx\_license, or Buty-license when esx\_license isn't running. On ESX the license type must exist in your `licenses` table. `removeLicense` (export) removes it again.

## Other scripts

```lua theme={null}
Config.Compat = {
    vmsCityhall  = false,
    vmsDocuments = false,
    esxBilling   = { enabled = false, maxAmount = 100000, requireJob = true },
    healthInsurance = 'health_insurance',   -- document type for the health insurance exports
    licenseAliases  = { drive_b = 'car', practical_boat = 'boat', … },   -- other scripts' license names
}
```

| Option | What it does |
| - | - |
| `vmsCityhall` | Scripts that call `exports['vms_cityhall']` are answered by City Hall. Server: `giveBill`, `getVehicleInsurance`, `addVehicleInsurance`, `getHealthInsurance`, `addHealthInsurance`. Client: `openCityHall`, `getTaxAmount`. Ignored while vms\_cityhall is installed. See the table below for the rest. |
| `vmsDocuments` | Scripts that call `exports['vms_documentsv2']` (`giveDocument`, `isAnyDocumentValid`, `invalidateDocument`, `getMyDocuments`, `GenerateSSN`) are answered by the built-in documents. |
| `esxBilling` | Handles `TriggerServerEvent('esx_billing:sendBill', target, 'society_x', label, amount)` from esx\_policejob, esx\_ambulancejob, esx\_mechanicjob… and turns it into a City Hall invoice (due in 7 days, paid to the society). Only when `esx_billing` is **not** started. The issuer must have the society's job, be within 15 m of the target, and the amount must be ≤ `maxAmount`. |

## VMS scripts

With `vmsCityhall = true` City Hall answers these `exports['vms_cityhall']` calls:

| Export | Used by | Needs |
| - | - | - |
| `giveBill`, `getVehicleInsurance`, `addVehicleInsurance`, `getHealthInsurance`, `addHealthInsurance` | MDTs, job scripts | bills, insurance |
| `getTaxAmount`, `addPlayerTaxToPay`, `addPlayerCustomTaxToPay`, `addCompanyTaxAmount`, `addCompanyCustomTaxAmount`, `addCompanyFlatTaxAmount`, `registerBusinessTaxAccount`, `getJobTaxes`, `TaxBusinessAllowMakeDelayedDeclarations`, `TaxBusinessPercentagePerMonthForDelay` | vms\_tuning, vms\_vehicleshopV2, vms\_stores, vms\_tattooshop, vms\_barber, vms\_gym, your own scripts | [taxes](https://docs.aps-store.com/assets/aps_cityhall/guides/taxes-and-treasury.md) |
| `getCompanyMoney`, `addCompanyMoney`, `removeCompanyMoney` | scripts that use City Hall's money | taxes (the treasury) |
| `isLicenseSuspended`, `suspenseLicense`, `reinstateLicense` | vms\_driveschoolV2, vms\_boatschoolV2, vms\_flightschoolV2 (`Config.UseVMSCityHall`), MDTs | always |
| `getPenaltyPoints`, `addPenaltyPoints`, `removePenaltyPoints`, `resetPenaltyPoints` | MDTs | penaltyPoints |
| `GenerateVIN`, `GenerateSSN` | vms\_garagesV2, vms\_vehicleshopV2, esx\_identity / multicharacter edits | vin, documents |
| `updatePaychecks` | framework paycheck edit, vms\_bossmenu | paychecks |
| `setResumeAllowed`, `getJobResumes` | vms\_bossmenu | jobCenter |

> [!WARNING]
>
> Some vms scripts only call City Hall when `GetResourceState('vms_cityhall') == 'started'` (vms\_garagesV2 and vms\_vehicleshopV2 for VINs). That check can't see City Hall under another name. For those, set the script's own City Hall option, or call `exports['aps_cityhall']` in its open config instead.

Other VMS resources work alongside City Hall: vms\_bossmenu (society money, badge numbers, tax and application permissions, announcements), vms\_notifyV2 (notifications), vms\_housing (property tax), and the business scripts' company accounts (business taxes).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.