Shop
The Shop module: products sold for the site balance, categories, terms and prices, discounts and promo codes, presents, and orders that track the delivery of every reward to the server.
Once it is set up, the site has a "Shop" section: players buy privileges (GiveCore), currency and items for the site balance, and the site delivers the purchase to the game server by itself. Each product is made of rewards from the Rewards module and "term and price" options. The order shows whether every reward reached the player.

| Dependencies | Games | Permissions | Studio blocks | Bot commands | Cron tasks |
|---|---|---|---|---|---|
| Flute 2.0, the Rewards module; suggests Chat, Migration, Monitoring | any game whose server is connected through GameLink | admin.shop, admin.shop.view, admin.shop.orders, admin.shop.orders.view, admin.shop.refund, admin.shop.grant, admin.shop.retry, admin.shop.discounts, admin.shop.settings | "Shop: products", "Shop: community goal", "Shop: balance top-up" | shop, giveproduct | four, below |
Where the module shows up
| Place | What is there |
|---|---|
/shop and the "Shop" menu item | the storefront with categories, the product page, the cart, presents for other players |
| Player profile | the "Purchases" tab: "In force now" and "Order history", with a "Renew" button |
| AdminShop | the "Products", "Shop orders", "Product categories", "Discounts and promo codes" and "Settings" tabs |
| Player card in the admin | the "Purchases" tab with the player's orders and the "Give a product" action |
| GameLink game menu | a shop section: the player buys for the site balance without leaving the game |
| Studio | the "Shop: products", "Shop: community goal" and "Shop: balance top-up" blocks |
The /shop address can be changed in the settings, and the routes, the menu item and old links follow it. The Monitoring module adds the player count and the current map of each server to the storefront. With the Chat module a product can be shared in chat.
Install and first setup
Install the module from the marketplace together with Rewards, as described in first steps; every install option is in Installing modules. Products are sold for the site balance, so connect a payment provider first. Until a payment method is turned on, the "Products" tab shows "Players can't top up their balance" with a "Set up payments" button.
Rewards reach the game server through the GameLink plugin. Without it the site will sell a privilege, but nothing will deliver it. Connecting a server is covered in Connect a game server.

A category and a product with a privilege
The example: a "Privileges" category and a 30-day VIP product that gives the vip group on the server.
Create a category
Open AdminShopProduct categories and click "New category". Fill in "Name" and leave the rest: "Address" is made from the name, and "Product view" on "Auto" shows privileges as tariffs and everything else as tiles. A sub-category is made with "Inside the category", one level deep only.
If there are no categories yet, you can skip this step: the product form then has a "Category" field for a new one, created together with the product.
Create the product
Open AdminShopProducts and click "New product". In "What the buyer sees", fill in "Name", "One phrase about the product" and "Advantages", one per line. Pick the category.

Add a reward
In "What the buyer gets", pick a type in the empty row. For a group on the server that is "Server group by name": put the group name, as the plugin has it, into "Group on the server": vip. A role on the site itself comes from the "Site role" type. Other reward types, including those added by game modules, are listed under Reward types.
A reward inside a product has no term of its own: the purchase option sets it. A role is taken away when the bought term ends; with the "forever" option it stays, and the delivery goes to the server with no end date.
Set terms and prices
In "Terms and prices", the first row is already set to 30 days; fill in "Price". A row without a price is not sold. To let the buyer pick the number of days, fill in "Own term: price of a day" and the "From, days" and "To, days" limits.
Pick servers and put it on sale
In "Where it works", leave "Server choice" on "As the rewards say", or pick "The buyer picks" and tick "Servers of the product". An empty list means every server able to give the product's rewards. Turn on "On sale" in the "Sale" block and save.
Until the product has a reward and a price, "On sale" will not switch on and the form shows a warning. To sell several products in one purchase there is "Create bundle"; a bundle needs at least two products.
"Sale" holds "Sale opens", "Sale closes", "Purchases per account" and "Copies for sale". A refunded copy goes back on sale. A product priced at 0 saves only with a limit of purchases per account.
"Who can buy it" can require "Roles" (any one of them is enough), "Linked networks" (all of them) or a "Product in force" the buyer already holds. When the product is a present, the conditions are checked on the recipient.
If a player holds a senior privilege, a junior one cannot be bought: the buyer sees "You hold a senior privilege: …. A junior one cannot be bought." Buying a senior privilege over a junior one replaces it. With "Credit for the rest on an upgrade", the unused whole days of a junior privilege bought in the shop lower the price of the senior one.
Privilege tiers and how they differ
Say a server has three tiers: VIP, Premium and Legend. The site handles three things: which group to grant, which tier is senior and how the buyer sees the difference. What a group gives in the game (armour, slots, skins, commands) is set in the VIP or admin plugin itself, on the group vip:gold, vip:premium and so on. The site does not change those perks, it only grants the group.
Create the tiers in GiveCore
Create three privileges in GiveCore and give each its server group. In "Ladder and seniority" give all three the same "Ladder", for example vip, and a rising "Seniority": 10, 20, 30. Premium then replaces VIP, and VIP cannot be bought over Premium.
One product per tier, in one category
For each privilege press "Sell in the shop" and put all three products in one category, for example "Privileges".
Write the "Advantages" as matching lines
The "Advantages" build the table "What each of them includes": products are columns, advantage lines are rows. Lines with the same text in different products share a row, so write them the same way.
- A line without a colon, like
Own chat tag, shows "Yes" for the products that list it and "No" for the rest. - A line with a colon, like
Slots: 5, puts the value in the cell. WriteSlots: 10for Premium and the same row shows 10. - A line like
Everything VIP givescopies all of VIP's lines into the column, so you do not repeat them. Its last word must match the name of another product in the category.
Premium, for example:
Everything VIP gives
Slots: 10
Own chat tagMark the recommended tier
Turn on "Recommended in the comparison" for one product: its column is highlighted and marked "Recommended", and its card shows "Beyond VIP" with the lines the cheaper tier lacks.
The category gets a "Compare" view next to "Rows" and "Cards". A signed-in player sees "You have it" over their tier. The comparison shows up to six products, and only when the category has at least two. Turn it off in the shop settings with "Comparison of a category's products".
Check the delivery
Test the product before anyone buys it. Open the player in AdminPlayers, choose the "Give a product" action, then "Product and term", "Server" and "Reason". Nothing is charged, and the order gets the "Given by hand" status. This needs the admin.shop.grant permission.
The order appears in AdminShopShop orders. The "Rewards" column shows how many rewards were delivered, how many are waiting and how many failed. Clicking the row opens the order, where every reward has its own state.

| State | What it means |
|---|---|
| "Sent to the server, waiting for its answer" | the site queued the delivery, the plugin has not confirmed yet |
| "Delivered" | the server confirmed it |
| "Waiting in the inventory" | the player claims the reward from the inventory |
| "Waiting in the inventory: link your game account" | the buyer has no game account for this server |
| "Not delivered: the server did not answer, we will try again" | the site retries by itself |
| "Not delivered: an administrator has to look" | the site has stopped retrying and needs you |
Send a stuck reward again with "Try the delivery again" in the order; this needs admin.shop.retry. When several orders are stuck, the list shows "Waiting for delivery: N" with a "Review orders" button. What the plugin did and why it failed is on Sent to servers. The grants of every module are collected in AdminRewardsGrants, described under Grants.
The "Refund" button, with admin.shop.refund, returns the money for an order to the buyer's balance and takes back what was given for the refunded lines. A refund is possible for "Refund window, days" after the purchase, 14 by default.
Discounts and promo codes
AdminShopDiscounts and promo codes holds two lists. A discount lowers the price by itself, either "On products" by a percent or "By quantity in an order" from two products up. With no "Products" or "Categories" picked, it covers the whole catalogue.
The buyer types a promo code in the cart. "New promo code" sets the "Code" (2 to 64 characters), "Percent" or "Sum", "Minimum order sum", "Uses in total" and "Uses per account". A bonus on balance top-ups is a different thing, set up in top-up promo codes.
By default a promo code and the site's discounts do not add up: the better of the two applies. "Promo code and site discounts" in the settings changes that.
Settings
The settings are the last tab of the module's screens: AdminShopSettings. They are grouped into "Storefront", "Buying", "Notifications", "Your own wording", "Refunds", "The shop across the site", "Community" and "Storefront pictures".

| Field | What it changes | Default |
|---|---|---|
| "The shop is open" | a closed shop says "The shop is closed for now. What you bought stays in force." and sells nothing | on |
| "Show prices to guests" | when off, only signed-in visitors see prices | on |
| "Cart" | when off, products are bought one at a time | on |
| "Products in the cart" | 1 to 100 | 20 |
| "Promo codes" | when off, the promo code field disappears and codes are refused | on |
| "Promo code and site discounts" | "Only the better of the two applies" or "They add up" | the better one |
| "Renewing what is in force" | when off, something in force cannot be bought again until its term ends | on |
| "Auto-renewal from the balance" | the buyer turns it on for a bought term; payment is taken "Renew, hours ahead" of the end | on, 24 hours |
| "Presents for other players" | a product can be bought for another player from its page | on |
| "Presents a day from one account" | 0 removes the limit | 5 |
| "Discount for regular buyers" | a discount that grows with the sum of paid orders; "Discount levels" as "sum: percent" lines | off, 1000: 3, 5000: 5, 20000: 10 |
| "Credit for the rest on an upgrade" | a senior privilege costs less by what is left of the junior one | on |
| "Agreement with the offer before the first purchase" | asked once the site has published an offer | on |
| "Refund window, days" | 0 means always | 14 |
| "When the reward has been spent" | "Refund less what was spent" or "Refuse the refund" | refund less what was spent |
| "Do not refund a used term" | for an expired or replaced privilege only the unused share of the term is refunded | on |
| "Shop in the game menu" | the shop section in the GameLink menu on servers | on |
| "Community goal" | a block with the sum raised by purchases over a week or a month | off |
"Storefront" also has "Storefront view" (tiles or a list), "Default sorting", "Advantages in a product row" (3), "Comparison of a category's products", "Server first", and the "My purchases", "Best sellers" and shop numbers blocks. "Buying" has "Cart for guests", "Keep a cart, days" (30), "Wrong promo codes before a pause" (5) and "Pause after guessing, minutes" (15).
"Notifications" turns on messages about a paid order, a refund, a grant by an administrator and a present, plus "Remind of an abandoned cart" after 24 hours and "Remind of a term about to end" 3 days ahead. "Community" holds "The sum of the goal" (10,000), "The period of the goal", "Goal rewards" and the "Latest purchases" and "Top supporters" blocks. "Your own wording" replaces the section name, the phrase of a closed shop and the profile tab name; "Storefront pictures" gives covers to products without a picture of their own.
| Permission | What it gives |
|---|---|
admin.shop | products and categories, includes admin.shop.view |
admin.shop.view | viewing the catalogue |
admin.shop.orders | orders, includes viewing orders and retrying deliveries |
admin.shop.orders.view | viewing orders and the "Purchases" tab of the player card |
admin.shop.refund | refunds |
admin.shop.grant | giving a product without payment |
admin.shop.retry | retrying a delivery |
admin.shop.discounts | discounts and promo codes |
admin.shop.settings | settings |
The "Shop: products" block has a "Section" field: by default "The privileges section", the category with the most privileges. Its look is one of "Rank ladder", "List and showcase" and "Product poster". "Shop: community goal" shows the goal from the settings, and "Shop: balance top-up" opens a top-up with ready-made sums.
In bots, the shop command shows popular products. giveproduct gives a product to a player without payment and is available only to holders of admin.shop.grant.
Background tasks
The tasks are listed in AdminScheduler and run only when the scheduler is started every minute.
| Task | How often |
|---|---|
| Shop: forgetting old carts | daily |
| Shop: cart reminders | hourly |
| Shop: reminders of a term about to end | hourly |
| Shop: auto-renewal of terms | hourly |
Game servers
The shop itself knows nothing about games: it gives rewards, and GameLink carries them to the server. Installing the plugin and what it can give are covered on the game pages, for example Counter-Strike 2, Rust and Minecraft. Game modules add reward types of their own: RustKit, GmodKit, FiveMKit and Minecraft.
The shop section of the game menu is built from the categories and purchase options. A product sold by the day stays on the site and is not offered in the game. The order of menu items is set in the game menu.
FiveM and RedM purchases are paid through Tebex, see Tebex. The Migration module moves a catalogue over from an old store.
For developers
After a payment the module dispatches flute.shop.order_paid (OrderPaid), after a refund flute.shop.order_refunded (OrderRefunded). A grant by hand comes as the same event with kind = manual and a total of 0. The rewards of an order go to the Rewards log with the shop source and an order:<id> reference.
A way to pay other than the balance plugs in through the Flute\Modules\Shop\Contracts\ExternalCheckout contract, registered in PaymentRoutes. Tebex works this way.
How the core side works: Payments, Events and listeners, Extension points.
Troubleshooting
For any other message, use the error lookup.
No server can give the product's rewards: it cannot be bought.
No enabled server has what the reward gives: the plugin is not connected or the group is not set up. Connect a server through GameLink or change the reward. The buyer meanwhile sees "No server can deliver this product right now. Check back later."
Waiting for delivery: N
The orders are paid, the rewards never arrived, and the site has stopped retrying. Open the order, check the reason on Sent to servers and click "Try the delivery again".
| Message | What to do |
|---|---|
| "A product on sale must give something: add a reward." | add a row to "What the buyer gets" |
| "A product on sale must have a price: add a term and a price." | fill in a price in at least one option |
| "A free product needs a limit of purchases per account." | fill in "Purchases per account" |
| "The product puts :worth on the balance for a price of :price: a buyer gets more than they pay. Raise the price or lower the reward." | a product that tops up the balance costs less than it gives |
| "No game account is linked for this server: the purchase will wait in the inventory." | the buyer links a game account; the reward waits in the inventory |
| ":sum is missing. Top up the balance." | the buyer has to top up the balance |
| "The shop is closed." | turn on "The shop is open" |