Button component

button

Used for creating a button component.

Schema fields #

Key Type Description
component String For buttons always button
id String The ID of the button. Used to identify when interacted with.1
label String The text shown on the button.
disabled Boolean
(false by default)
Whether this button is disabled.
style String
(secondary by default)
The style of the button.
emoji Emoji object The emoji shown on the button.
url String The URL opened when clicking the button.2

Button styles#

String Preview
primary Primary
secondary Secondary
success Success
danger Danger
link Link

  1. Not required for URL style. 

  2. Only required for URL style.