Exports
Server-side
Add Transaction to Player Transaction History
exports['okokBankingV2']:AddTransaction(citizenid, transactionData, source)Variables:
citizen_id: The player's unique identifier - can be citizenid, job name, or account identifier
transactionData: {
sender_identifier = "steam:110000123456789", -- senderIdentifier/senderCitizenid
sender_name = "John Doe",
receiver_identifier = "bank", -- receiverIdentifier/receiverCitizenid
receiver_name = "Bank",
value = 500,
type = "deposit",
reason = "ATM Deposit"
} source: source (Optional - The player's server source ID for webhook purposes)
Get Player Transaction History
exports['okokBankingV2']:GetPlayerTransactions(citizenid, limit)Variables:
citizen_id: The player's unique identifier - can be citizenid, job name, or account identifier
limit: 50 (Optional - Maximum number of transactions to return. If nil, returns all transactions. If 0 or negative, returns empty table)
Example Usage:
-- Get all transactions
local allTransactions = exports['okokBankingV2']:GetPlayerTransactions("steam:110000123456789")
-- Get last 10 transactions
local recentTransactions = exports['okokBankingV2']:GetPlayerTransactions("steam:110000123456789", 10)Last updated