Skip to content

Documents

Documents

Digital document wallet supporting ID cards, licenses, passports, permits, insurance, and registration certificates. Documents have verification codes, NFC sharing, and proximity-based sharing.

Database Tables

TablePurpose
phone_documentsDocuments -- identifier, doc_type, title, holder_name, holder_number, expires_at, verification_code, nfc_enabled
phone_documents_nfc_scansNFC scan log -- document_id, scanned_by, scan_type (nfc/manual/shared)

Server Callbacks

CallbackPurpose
gcphone:documents:getListReturns all documents for the player
gcphone:documents:createCreates a new document with a generated verification code
gcphone:documents:deleteDeletes a document
gcphone:documents:toggleNFCEnables/disables NFC sharing on a document
gcphone:documents:scanNFCStub -- returns NFC_USE_OX_TARGET (handled via ox_target)
gcphone:documents:verifyStub -- returns VERIFY_DISABLED_USE_OX_TARGET
gcphone:documents:getScanHistoryReturns NFC scan history for the player's documents
gcphone:documents:shareShares a document with a nearby player (proximity check, NFC must be enabled)
gcphone:documents:getTypesReturns the list of available document types

Document Types

IDName
idDNI / ID
licenseLicencia de Conducir
passportPasaporte
permitPermiso Especial
work_permitPermiso de Trabajo
insuranceSeguro
registrationRegistro Civil

Config Options

lua
Config.Features.Documents = true

Config.Documents = {
    AllowCustomTitle = true,
}

Config.Proximity.ShareDocumentDistance = 2.0

Exports

None.

Released under GPL-3.0 License