Skip to content

$removeComponents

$removeComponents removes a component from a specific message.

Usage

$removeComponents[channelID;messageID;...customIDs]

Parameters

FieldTypeDescriptionRequired
channelIDnumberChannel ID of the command that has been executed.true
messageIDnumberThe ID of the message that will remove the component(s).true
customIDsstringThe custom id of component that will be removed.true

Example(s)

This will send a message with a button that will be removed after 5 seconds.

1
client.command({
2
name: "removeComponents",
3
code: `
4
$removeComponents[$channelID;$get[msgID];customID]
5
$wait[5s]
6
$let[msgID;$sendMessage[This button will be removed in 5 seconds.
7
{actionRow:{button:Button:primary:customID:false}};true]]`
8
});