Creating custom buttons
Guide to creating buttons that run the functionality of certain commands
Discord buttons with bot actions (gift, purchase, quest, profile…). On the website it is easier to build messages in the builder.
The main command for creating buttons is /components
Arguments of the /components buttons add command:
message_url
Link to the message the button will be added to
Yes
style
Button style: Link - a link button
Yes
id-or-url
Button ID or a link to a resource (if the style is Link)
Yes
row
The component row the button will be added to
Yes
column
The component column the button will be added to
Yes
label
Button label
No
emoji
Button emoji
No
disabled
Whether the button will be disabled
No
Arguments of the /components buttons remove command:
message_url
Link to the message the button will be removed from
Yes
row
The component row the button will be removed from
Yes
column
The component column the button will be removed from
Yes
Available button commands:
ID: cmd{buy}item{itemId}amount{10}price_type{currency}price{10} prms-off dscnt-off limits-off
Arguments:
item
Item ID
Yes
amount
Amount to buy
No
price_type
Price: item ID; currency - server currency
No
price
Price: amount
No
prms-off
Disables purchase permissions, if any
No
dscnt-off
Disables the reputation-based discount
No
limits-off
Disables purchase limits
No
ignr-shop
Ignores the item's availability and amount in the shop
No
ID: cmd{sell}item{itemId}amount{10}
Arguments:
item
Item ID
Yes
amount
Amount to sell
No
ID: cmd{quest-give-to-user}quest{questId}
Arguments:
quest
Possible values: 1. Quest ID 2. active - get all active quests 3. daily - get a random daily quest 4. weekly - get a random weekly quest
Yes
ID: cmd{getQuestReward}quest{questId}
Arguments:
quest
Quest ID
No
If the quest argument is omitted, the user will receive the rewards from all quests.
ID: cmd{quest-take-from-user}quest{questId}
Arguments:
quest
Quest ID
Yes
ID: cmd{give-item}item{itemId}amount{10}usr{userId}
Arguments:
item
Item ID
Yes
amount
Amount to give
No
usr
The user the item will be given to; if omitted, it is given to the user who pressed the button
No
ID: cmd{take-item}item{itemId}amount{10}usr{userId}
Arguments:
item
Item ID
Yes
amount
Amount to take
No
usr
The user the item will be taken from; if omitted, it is taken from the user who pressed the button
No
ID: cmd{help}commands eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
ID: cmd{profile} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
usr
ID of the user who can use the button; if omitted, anyone can use it
No
mbr
ID of the user whose profile will be shown; if omitted, the profile of the user who pressed the button is shown
No
ID: cmd{inventory} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
usr
ID of the user who can use the button; if omitted, anyone can use it
No
mbr
ID of the user whose inventory will be shown; if omitted, the inventory of the user who pressed the button is shown
No
ID: cmd{achievements} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
usr
ID of the user who can use the button; if omitted, anyone can use it
No
mbr
ID of the user whose achievements will be shown; if omitted, the achievements of the user who pressed the button are shown
No
ID: cmd{rank} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
mbr
ID of the user whose card will be shown; if omitted, the card of the user who pressed the button is shown
No
ID: cmd{rank-set} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
ID: cmd{say}channelId{ID}messageId{ID}permission{ID} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
update
If present, the message will be edited
No
channelId
ID of the channel to look up the message in
No
messageId
Message ID
No
permission
Permission ID
No
ID: cmd{stats} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
usr
ID of the user who can use the button; if omitted, anyone can use it
No
mbr
ID of the user whose stats will be shown; if omitted, the stats of the user who pressed the button are shown
No
ID: cmd{inventory-roles} eph reply
Arguments:
eph
If present, the message is visible only to the user who pressed the button
No
reply
If present, the message is sent as a reply
No
usr
ID of the user who can use the button; if omitted, anyone can use it
No
mbr
ID of the user whose role inventory will be shown; if omitted, the role inventory of the user who pressed the button is shown
No
ID: cmd{custom-role}
Last updated