Skip to main content
All server exports are called with colon syntax: exports.vrs_permanentid:Fn(...).

GetPermanentId

Returns the permanent ID of an online player.
number
required
The player’s server id.
Returns: number | nil

GetPermanentIdByIdentifier

Database fallback that works even when the player is offline.
string
required
The player’s citizenid (QB/QBox) or identifier (ESX).
Returns: number | nil

GetIdentifierByPermanentId

Reverse lookup: resolve a permanent ID back to a stored identifier.
number
required
The permanent ID to look up.
Returns: string | nil

GetSourceByPermanentId

Resolve a permanent ID to a live server id. Online only.
number
required
The permanent ID to look up.
Returns: number | nil

GetAllOnline

Returns a map of every online player’s source to their permanent ID.
Returns: { [source] = pid }

Statebags

Replicated on every online player. Read from client or server, no export required.
Last modified on July 28, 2026