UtilitiesDocs

Transactions

Log every sale, see who has spent what, and give roles to your best customers.

#Overview

Utilities keeps a log of what people buy from you. Every transaction has a buyer, an amount and a short note, and adds to that person's total. Transaction autoroles give a buyer a role once their total reaches an amount you choose, and take it away again if it drops.

#Getting started

  1. Log a sale. Run /log with the buyer and the amount, and a note if you like. The bot posts the transaction with its reference number.

  2. Add a role for big spenders. Run /transaction autorole add with a role and an amount. Anyone whose total reaches it gets the role.

  3. Finish sales from tickets. In a ticket, /ticket done with the amount logs it for the person who opened the ticket and closes the ticket in one go.

/log @buyer 25 Logo design
/transaction autorole add @Client 100

#Logging a transaction

/log and /transaction log do the same thing. With the prefix, ,log and ,transaction both log.

  • The amount is a whole number from 1 to 999,999.
  • The note can be up to 50 characters, and cannot contain custom emoji.
  • You cannot log a transaction for yourself or for a bot.
  • Each person can log one transaction every 10 seconds.

Every transaction gets a reference number, counting up from 1 in your server. Deleting one leaves a gap, so the numbers you have written down never change.

#Editing and deleting

The message the bot posts for a transaction has Edit transaction and Delete transaction buttons. You can also use /transaction edit and /transaction delete with its reference number.

  • Editing can change the buyer, the amount and the note. The buyer can be a username, a mention or an ID.
  • Deleting asks you to confirm first. A deleted transaction no longer counts toward anyone's total, but it stays in the history, marked as deleted.

Buyers' roles are updated straight away when a transaction is logged, edited or deleted, so a refunded buyer loses a role they no longer qualify for.

#Transaction autoroles

A transaction autorole is a role and an amount. A buyer gets every role whose amount is at or below their total, so the roles work as a ladder: someone who reaches your top role keeps the ones below it.

  • Amounts go from 1 to 999,999,999, since a total can be far more than one sale.
  • The role cannot be @everyone, a role managed by another app, or a role above the bot's highest role or above your own.
  • /transaction autorole edit changes a role's amount, and /transaction autorole list shows them all.
  • /transaction sync checks every buyer and fixes their roles. Use it after changing amounts, or if roles were changed while the bot could not manage them. It goes through one member at a time, so a large server takes a while.

#History and transfers

These need Tier 1, either on your server or as user premium of the person running them.

  • /transaction history lists every transaction in your server, or one person's when you name them. Its search can show only Edited or only Deleted transactions.
  • /transaction transfer moves all of one person's transactions to another, for example when a buyer moves to a new account. It shows both people's totals and asks you to confirm, because it cannot be undone.

#Totals and statistics

/server stats and /server leaderboard show what your buyers have spent. /server channels can pin figures from the log to your channel list, such as TOP Client, USD Value, Total Deals, Total Clients and Highest Transaction. Those channels are updated every 10 minutes. See Server.

#Good to know

  • Every transaction command needs both Manage Server and Manage Roles.
  • The bot needs Manage Roles, and its role must sit above the autoroles it gives. Roles it cannot reach are skipped.
  • A server can keep 1 transaction autorole on Free, 25 on Tier 1 and 50 on Tier 2. If a server drops a tier and has more than it now allows, the ones with the lowest amounts keep working. See Premium.

#Commands

/log (user) (amount)Manage ServerManage Roles

Log a new transaction Also: ,transaction

/transaction log (user) (amount) [details]Manage ServerManage Roles

Log a new transaction

/transaction edit (reference) (user) (amount)Manage ServerManage Roles

Edit an existing transaction

/transaction delete (reference)Manage ServerManage Roles

Delete an existing transaction

/transaction historyManage ServerManage Roles

View the guild's transaction history

/transaction autorole add (role) (amount)Manage ServerManage Roles

Add a transaction auto-role

/transaction autorole edit (role) (amount)Manage ServerManage Roles

Edit a transaction auto-role threshold

/transaction autorole remove (role)Manage ServerManage Roles

Remove a transaction auto-role Also: ,transaction autorole delete

/transaction autorole listManage ServerManage Roles

List transaction auto-roles

/transaction transfer (from) (to)Manage ServerManage Roles

Transfer transaction statistics from one user to another

/transaction syncManage ServerManage Roles

Sync transaction roles