Custom Variables
Let your customers customize their purchases by providing extra customizable input like, names, or numbers. These values are passed into your product commands and can even affect pricing.
Last updated
Let your customers customize their purchases by providing extra customizable input like, names, or numbers. These values are passed into your product commands and can even affect pricing.
Custom Variables allow you to collect additional input from customers at checkout. This can include:
Dropdown selections (e.g. server region, item color)
Text input (e.g. username, tag)
Numeric input (e.g. levels, amounts)
These values can be used dynamically in your product commands and templates, giving you much more flexibility without needing separate products.
To get started:
Navigate to the Custom Variables tab in your dashboard.
Click the New custom variable button.
You’ll be prompted to enter the following:
Name: Displayed to customers.
Identifier: Used in commands as {identifier}.
Description (optional): Appears under the input on the product page.
Type: Choose between:
Dropdown – Add multiple options, each with optional extra cost.
Text – Freeform input. Supports regex validation.
Number – Numeric input. Also supports regex validation.
Let’s say you’ve added the following custom variables:
{kit} (Dropdown – e.g. bronze, silver, gold)
{name} (Text – e.g. “Lord”)
{slots} (Number – e.g. 6)
You can reference these in your command like so:
If the customer selects:
Kit: gold
Name: Lord
Slots: 6
Your executed commands will be:
This setup is ideal for selling VIP ranks, timed perks, or custom packages in Rust stores.
For dropdown variables, you can define:
Name/Value: Shown to the customer and used in commands.
Pricing Type: Fixed or Percentage.
Additional Cost: Charge extra for certain options if needed.
These variables are optional. If not filled, they will not be injected.
Regex validation helps ensure valid input for Text and Number types.
Last updated
oxide.usergroup add {customer.steam.id} {kit}
say "{customer.name} just purchased the {kit} package!"
o.grant user {customer.steam.id} backpacks.size.{slots}oxide.usergroup add 7656119XXXXXXXXXXX gold
say "Lord just purchased the gold package!"
o.grant user 7656119XXXXXXXXXXX backpacks.size.6