Fraud ScammingLogs

Logs

Log what players do with Fraud Scamming to Discord webhooks, Fivemanage, the console or a script of your own.

On this page

tr_fraud can log what players do with it for your admins: who did what, where, and for how much. Each log has the player's name and server id, their character and its identifier, the identifiers you pick (license, discord, fivem, steam, xbl, live), where they stood, and the ids of the cards, checks, sales, laptops and burner phones involved, so you can look them up in the database.

It's off as it ships. Turn it on in config.lua:

config.lua
logs = {
    enabled = true,
    method = 'discord', -- or 'fivemanage', 'console', or a list: { 'discord', 'fivemanage' }
    ...
}
Part (logs.events)What's logged
textsConversations that got a victim's card details (with allTexts = true, every conversation and how it ended)
cardsCards cloned on a card skimmer; cloned cards an ATM paid on, kept, or kept as cancelled
moneyOrdersMoney orders bought, declined, or the card flagged or kept; money orders cashed, and players the bank flagged
returnsElectronics bought with cloned cards, receipts forged, returns paid, caught (and what the clerk caught) or flagged
checksChecks taken from mailboxes, forged, cashed, and reported (and what the teller caught)
alertsEvery police alert, with where it really came from (police only see an area)
adminAdmins giving themselves test checks and cards with /fraud_check and /fraud_card

Set one to false to leave it out.

Discord

Make a webhook

In your Discord server, open the channel's settings › Integrations › Webhooks › New Webhook, and Copy Webhook URL.

Add it to server.cfg

server.cfg
set tr_fraud_webhook "https://discord.com/api/webhooks/..."

Every log goes there. To give a part its own channel, add a webhook for it too; the parts without one still use tr_fraud_webhook:

server.cfg
set tr_fraud_webhook_returns "https://discord.com/api/webhooks/..."
set tr_fraud_webhook_alerts "https://discord.com/api/webhooks/..."

The part names are those in the table above. Or put them in server_config.lua (webhooks.default, webhooks.returns, ...).

Restart the server

Logs go up to ten to a message, and no more than a message every two seconds to one webhook, so a busy server doesn't get rate limited. A player's Discord shows as a mention you can click, and nobody is pinged. logs.discord.username and logs.discord.avatar set what the webhook posts as.

Fivemanage

Make a key

At fivemanage.com, open your team, make an API key for Logs, and copy it.

Add it to server.cfg

server.cfg
set tr_fraud_fivemanage_key "..."

If you already run Fivemanage's own resource (fmsdk), you don't need this: the logs go through it, with its key.

Pick the dataset and restart

Set logs.fivemanage.dataset if your logs go to a dataset other than default.

Each log's metadata has the part (category), what happened (action), the player (playerSource, playerName, character, identifier, identifiers), coords, and the ids (card, check, sale, order, laptop, phone), so you can search on any of them.

Your own

While logs are on, every log is also a server event, whatever method says, for a script of your own (method = 'none' sends them only there):

server.lua
AddEventHandler('tr_fraud:log', function(log)
    -- log.category, log.action, log.level ('info', 'success' or 'warn'), log.title, log.message,
    -- log.time, log.player { id, name, character, identifier, identifiers }, log.coords, log.fields
end)

The words are in locales/en.json under logs. If logs are on and a webhook or key is missing, or Discord or Fivemanage refuses it, the server console says so (once, not with every log).

Was this page helpful?

Still stuck? Open a ticket on Discord.Privacy