Expand description
Constants, error types, and functions for validating Component
s.
Structs§
- Component
Validation Error - A provided
Component
is invalid.
Enums§
- Component
Validation Error Type - Type of
ComponentValidationError
that occurred.
Constants§
- ACTION_
ROW_ COMPONENT_ COUNT - Maximum number of
Component
s allowed inside anActionRow
. - COMPONENT_
BUTTON_ LABEL_ LENGTH - Maximum
Component
label length in codepoints. - COMPONENT_
COUNT - Maximum number of root
Component
s in a message. - COMPONENT_
CUSTOM_ ID_ LENGTH - Maximum length of a
Component
custom ID in codepoints. - SELECT_
MAXIMUM_ VALUES_ LIMIT - Maximum number of
SelectMenuOption
s that can be chosen in aSelectMenu
. - SELECT_
MAXIMUM_ VALUES_ REQUIREMENT - Minimum number of
SelectMenuOption
s that can be chosen in aSelectMenu
. - SELECT_
MINIMUM_ VALUES_ LIMIT - Maximum number of
SelectMenuOption
s that must be chosen in aSelectMenu
. - SELECT_
OPTION_ COUNT - Maximum number of
SelectMenuOption
s in aSelectMenu
. - SELECT_
OPTION_ DESCRIPTION_ LENGTH - Maximum length of a
SelectMenuOption::description
in codepoints. - SELECT_
OPTION_ LABEL_ LENGTH - Maximum length of a
SelectMenuOption::label
in codepoints. - SELECT_
OPTION_ VALUE_ LENGTH - Maximum length of a
SelectMenuOption::value
in codepoints. - SELECT_
PLACEHOLDER_ LENGTH - Maximum length of a
SelectMenu::placeholder
in codepoints. - TEXT_
INPUT_ LABEL_ MAX - Maximum length of
TextInput::label
. - TEXT_
INPUT_ LABEL_ MIN - Minimum length of
TextInput::label
. - TEXT_
INPUT_ LENGTH_ MAX - Maximum length of
TextInput::value
. - TEXT_
INPUT_ LENGTH_ MIN - Minimum length of
TextInput::value
. - TEXT_
INPUT_ PLACEHOLDER_ MAX - Maximum length of a
TextInput::placeholder
in codepoints.
Functions§
- action_
row - Ensure that an action row is correct.
- button
- Ensure that a button is correct.
- component
- Ensure that a top-level request component is correct.
- select_
menu - Ensure that a select menu is correct.
- text_
input - Ensure that a text input is correct.