> ## 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.

# licenses

`config/licenses.lua` defines the license types and the question pool of each theory test. More in the [License Center](https://docs.aps-store.com/assets/aps_cityhall/guides/license-center.md) guide.

> [!WARNING]
>
> **Server-only file.** It contains the correct answers, so players never receive it. For the same reason the full file is not shown here: open `config/licenses.lua` in your resource to see and edit all questions.

## Included licenses

| id | Label | Icon |
| - | - | - |
| `car` | Driving License | `DirectionsCar` |
| `motorcycle` | Motorcycle License | `TwoWheeler` |
| `truck` | Truck License (HGV) | `LocalShipping` |
| `boat` | Boat License | `Sailing` |
| `pilot` | Pilot License | `Flight` |
| `firearms` | Firearms License | `GpsFixed` |

## Structure

```lua theme={null}
Config.Licenses = {
    {
        id          = 'car',                    -- stored in the database, keep it stable
        label       = 'Driving License',        -- display name
        description = 'Required to legally operate any standard passenger vehicle on public roads.',
        icon        = 'Car',                    -- Car, Motorcycle, Truck, Anchor, Plane, Crosshair, Badge
        cost        = 500,                      -- test fee (Config.MoneyAccount)
        passingPct  = 80,                       -- % needed to pass (0–100)
        timeLimit   = 600,                      -- seconds
        questions   = {
            {
                id      = 'car_1',              -- unique id
                text    = 'What does a red traffic light mean?',
                answers = {
                    { id = 'a', text = 'Stop' },
                    { id = 'b', text = 'Speed up' },
                    { id = 'c', text = 'Turn right' },
                },
                correct = 'a',                  -- id of the correct answer
            },
            -- … at least Config.Settings.questionsPerTest questions
        },
    },
}
```

> [!NOTE]
>
> Each pool should contain at least `Config.Settings.questionsPerTest` questions (default 20). The license card itself is a document in [documents.lua](https://docs.aps-store.com/assets/aps_cityhall/configuration-files/documents.lua.md) with `requiresLicense = '<id>'`.


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