# Client Exports

### generatePlate

Generating a license plate, you can use this export in your other resources in which you need to give a different license plate than the one generated by GTA by default.\
Export will return the license plate string

{% code overflow="wrap" %}

```lua
---@param plateFormat: You can use the option to enter a custom format, but you can also leave the generation of the license plate according to the specified format in config vms_vehicleshopV2.

exports['vms_vehicleshopV2']:generatePlate(plateFormat)
```

{% endcode %}

<details>

<summary>Explanation</summary>

Some resources require an export to generate plates, as this export should also verify the license plates in the database so that they do not duplicate.

For example, [**esx\_policejob**](https://github.com/esx-framework/esx_policejob/blob/b3b729fe0f71721277f2285bfe71b266dca23c13/client/vehicle.lua#L244) uses the **generatePlate** export from **esx\_vehicleshop**, then replace it with the following export.

</details>

<details>

<summary>Example usage</summary>

Generate a random license plate with a specific format

```lua
local plate = exports['vms_vehicleshopV2']:generatePlate('11 XXX11')
print('My custom format generated plate:', plate)

-- The results will be random, e.g. "24 AGE49" / "53 KDF93" / "95 JDS14"
-- But the results will always follow the predefined format.
```

***

Generate random license plate with format from vms\_vehicleshopV2

```lua
local plate = exports['vms_vehicleshopV2']:generatePlate()
print('My generated plate:', plate)
```

</details>

***

### openShowroom

Opening the showroom menu

```lua
---@param {id: string or nil}: Dealership ID or don't give ID, then it will detect the current area of the dealership you are in

exports['vms_vehicleshopv2']:openShowroom(id)
```


---

# Agent Instructions: 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://docs.vames-store.com/assets/vms_vehicleshopv2/developer-api/client-exports.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.
