FiveUnityManual

Tebex store

Connect your Tebex store and FiveUnity posts every purchase, refund, chargeback and subscription event into Discord, with a button your team presses once an order has been fulfilled.

Note

Where: Dashboard โ†’ Core โ†’ Tebex ยท In Discord: /setup โ†’ Tebex Connect Info, or /tebex setup

#Pick an integration type

Integration typeWhat it does
Tebex ExpressTebex posts to FiveUnity's own endpoint. The bot verifies each delivery with your secret key, records the purchase, and posts the full embeds with the Mark as Processed button. /tebex lookup works.
Discord webhookTebex posts straight into one Discord channel through a webhook. Simple logging only, no purchase records, no processed button, and /tebex lookup has nothing to read.

Express is the one you want unless you only care about a raw feed of events.

#Set up Tebex Express

There are two things to supply: your secret key and your endpoint URL. Everything else builds itself.

  1. In your Tebex store, go to Developers โ†’ Webhooks โ†’ Endpoints and copy your secret key.
  2. On Dashboard โ†’ Core โ†’ Tebex, set Integration type to Tebex Express.
  3. Paste the key into Tebex secret key and press Save Tebex. It has to be 8-256 characters. The key is write-only: once saved the field only ever shows "Stored (type to replace)", and it is never shown again. Saving it creates the log channels straight away.
  4. Back in Tebex, press Add Endpoint and point it at your server's own URL:
text
https://api.fiveunity.com/webhooks/tebex/<your server id>

The dashboard shows the path part of that URL under Webhook path. To get the whole thing ready to copy, run /setup in Discord and press Tebex Connect Info.

  1. Tick every event type in the list Tebex shows you, and confirm.

That is the whole setup. FiveUnity handles all seventeen event types, and when Tebex validates the endpoint the bot creates any log channel that is still missing and points the pickers at it. There is no Create Tebex log channels step to remember; the button is still there, but only as a way to rebuild everything at once.

Tip

Always use the URL that ends in your server id. It lets the bot check exactly one signature per delivery instead of trying every store it knows about.

#Set up a Discord webhook instead

Pick Discord webhook as the integration type, choose a Discord webhook channel, and press Create Discord webhook. The URL appears once, in a yellow "Copy this URL now" box. Paste it into Tebex โ†’ Settings โ†’ Webhooks straight away, because it is not shown again. The line underneath only ever tells you whether a webhook URL is set or not set.

/tebex setup method: does the same from Discord. Choosing Express Server (Advanced Sync) gives you a ๐Ÿ” Enter Tebex secret key button that opens a private form, so the key never travels as a command option. Choosing Direct Discord Webhook (Simple Logging) needs a log-channel: and prints the webhook URL in the reply.

#Log channels

One picker per event group. Several Tebex events can share a channel, which is why there are thirteen of these and not seventeen.

SettingChannelWhat lands there
Purchases๐Ÿ“ฆ | NEW-PURCHASESEvery completed payment, with the Mark as Processed button.
Claimsโœ… | CLAIMED-LOGSA record of who marked each order processed, and when.
Disputes openedโš ๏ธ | CHARGEBACKSA dispute opened against a payment, announced with an @everyone ping.
Dispute resultsโš–๏ธ | DISPUTE-RESULTSA dispute won, lost or closed. A lost one also pings @everyone.
Refunds๐Ÿ’ธ | REFUNDSRefunded payments.
Declinedโ›” | DECLINEDPayments Tebex could not take, with the decline reason.
Subscription started๐Ÿ”„ | SUBS-NEWA subscription starting.
Subscription renewed๐Ÿ”„ | SUBS-RENEWA subscription renewing.
Subscription endedโŒ | SUBS-ENDA subscription ending.
Cancellations๐Ÿšซ | SUBS-CANCELA cancellation requested, and one the subscriber then aborted.
Subscription status๐Ÿ“Š | SUBS-STATUSA subscription changing status.
Trials๐ŸŽŸ๏ธ | SUBS-TRIALA trial starting, ending soon, ending, or being cancelled.
Anything else๐Ÿงพ | TEBEX-OTHERAn event type Tebex adds after this release, so a new webhook is never lost.

#Channels look after themselves

Leave a picker empty and FiveUnity creates that channel the first time the event arrives, inside a Tebex Logs category hidden from @everyone, and fills the picker in. Delete a channel by accident and the next event of that type rebuilds it. Point a picker at a channel of your own and FiveUnity posts there instead and creates nothing.

Two controls govern this:

SettingWhat it does
Create log channels automaticallyOn by default. Turn it off and the channel list is frozen at whatever the pickers say; an event with no channel is dropped.
Muted eventsPost nothing and create nothing for the log types you pick. This is how you silence an event: an empty picker means "make it for me", not "off".

Create Tebex log channels still exists and builds the whole set in one go. Running it again reuses whatever is already there, so it is also how a store set up before this release picks up the newer channels.

Note

Creating channels needs Discord's Manage Channels permission. Without it FiveUnity logs a warning once an hour, stops trying for ten minutes, and keeps recording purchases; set the channels yourself with the pickers and everything posts normally.

A channel is only ever made when one is genuinely absent. A burst of sales produces one channel, not one per sale; a channel you rename or drag into another category is still recognised as yours; and pressing Create Tebex log channels twice changes nothing the second time.

#Deleting them again

Core โ†’ Delete channels (server owner only) empties a category, so removing the whole Tebex Logs category is one action. Leave Stop FiveUnity recreating these on and the log types you deleted are muted, so the next sale does not rebuild what you just removed. See Core settings.

#What happens on a purchase

FiveUnity records and announces purchases. It does not deliver packages: fulfilment stays manual, and the Purchases channel is your team's work queue.

When Tebex reports a completed payment:

  1. The purchase is stored against your server as unclaimed, with the player name, price, package list, transaction id and date.
  2. A ๐Ÿ“ฆ New Purchase embed goes to the Purchases channel: Player, Price, Status "โฌ‡๏ธ Action Required", Packages and Transaction ID, plus a green โœ… Mark as Processed button.
  3. Once your team has handed the package over, someone presses Mark as Processed. The purchase is marked claimed against their name, a โœ… Purchase Claimed entry is posted in the Claims channel, and the original message is removed from the queue.

Mark as Processed is limited to staff (a member of a permission group, the server owner, or an Administrator) and also needs Discord's Manage Server permission. Everyone else gets "No Permission."

Refunds and disputes update the stored purchase as well, so a refunded or disputed order stops looking like an open one.

Add a package variable in Tebex with the identifier discord_id and ask the buyer for their Discord user id at checkout. When it is present, FiveUnity stores it with the purchase and mentions the buyer directly in every log embed (@Buyer (playername) instead of just the store name) so you can reach them without hunting through the store.

#The /tebex command

/tebex needs Discord's Administrator permission.

SubcommandWhat it does
/tebex setup method: log-channel:Switches the integration type, opens the secret-key form, or creates the Discord webhook.
/tebex lookup user:Shows the five most recent stored purchases for a member, with packages, status, transaction id and date. Express only.
/tebex verify code:Confirms a purchase code / transaction id from Express webhook history (status, player, packages, amount). Also tries a live Tebex Plugin API lookup when the stored key is accepted; that API needs a Game Server secret, which is different from the webhook private key. Express only.
/tebex forcecheckRe-posts up to ten purchases from the last 14 days that nobody has marked as processed, so a log embed lost to an outage or a deleted channel comes back.
Tip

/tebex lookup matches the stored discord_id first, and falls back to the Tebex customer's username. Set the discord_id package variable (above) and it finds every purchase reliably, whatever the buyer called themselves in the store.

When Log Lookup is enabled, FiveUnity also indexes these Tebex log channels so /logs find and Ask the logs can answer questions such as "did Bob buy VIP last night", "what did Bob purchase with gems" or "investigate Bob's chargebacks". Official purchase logs are locked behind the tebex permission. In-game gem and cash shop embeds from Log Builder destinations (for example sheisty_tebex_gems) join Other Logs automatically. Tebex / gems trace and abuse-style questions widen across every category you can access and read up to 90 days. /logs tebex is the exact-term search over the official Tebex channels with the full retention window.