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

# Get if player ID owns a plate

> Check if a specific player owns a vehicle plate server side.

This export can be used to know if a player owns a vehicle plate (can also check shared, temporary, etc.).

```lua Export theme={null}
exports["vehicles_keys"]:isPlayerOwnerOfVehiclePlate(playerId, plate, onlyOwnedVehicles)
```

### Parameters

| Name                | Data Type | Description                                                                                      |
| ------------------- | --------- | ------------------------------------------------------------------------------------------------ |
| `playerId`          | integer   | The player server ID                                                                             |
| `plate`             | string    | The vehicle plate to check                                                                       |
| `onlyOwnedVehicles` | boolean   | `true` = only search owned vehicles. `false` = also search temporary vehicles, shared keys, etc. |

### Return

`true` if the vehicle is owned.

`false` if the vehicle is not owned.

## Example

```lua theme={null}
RegisterCommand("checkPlate", function(playerId, args)
    local plate = args[1] -- Example "ABC 123"

    if(exports["vehicles_keys"]:isPlayerOwnerOfVehiclePlate(playerId, plate, false)) then
        print("I own this vehicle plate")
    else
        print("I DO NOT own this vehicle plate")
    end
end)
```


## Related topics

- [Server](/vehicles-keys/server/index.md)
- [Get if player is owner of vehicle plate](/jobs-creator/server/buyable-vehicles/get-if-player-is-owner-of-vehicle-plate.md)
- [Get if local player owns a plate](/vehicles-keys/client/get-if-local-player-owns-a-plate.md)
- [Buyable Vehicles](/jobs-creator/server/buyable-vehicles/index.md)
- [Get owned plates of local player](/vehicles-keys/client/get-owned-plates-of-local-player.md)
