Overview
TheButtonStyleTypes enum defines the visual appearance of button components. Each style has a different color and purpose.
Enum Values
Button Styles
PRIMARY (1)
Blurple button, used for primary actions. Visual: Blue/Blurple colored buttonSECONDARY (2)
Gray button, used for secondary actions. Visual: Gray colored buttonSUCCESS (3)
Green button, used for positive or success actions. Visual: Green colored buttonDANGER (4)
Red button, used for destructive or dangerous actions. Visual: Red colored buttonLINK (5)
Link button, navigates to a URL when clicked. Visual: Gray button with link icon Note: Link buttons must include aurl property and cannot have a custom_id.
PREMIUM (6)
Premium button, used for premium SKU purchases. Visual: Purple button with premium styling Note: Premium buttons must include asku_id property.
Usage Examples
Custom Button
Link Button
Premium Button
Button Style Constraints
- Custom Buttons: Can use PRIMARY, SECONDARY, SUCCESS, or DANGER styles and require a
custom_id - Link Buttons: Must use LINK style and require a
urlinstead ofcustom_id - Premium Buttons: Must use PREMIUM style and require a
sku_id
Visual Reference
| Style | Color | Use Case |
|---|---|---|
| PRIMARY | Blurple | Primary actions, main call-to-action |
| SECONDARY | Gray | Secondary actions, less emphasis |
| SUCCESS | Green | Confirmations, positive actions |
| DANGER | Red | Destructive actions, warnings |
| LINK | Gray | External links, navigation |
| PREMIUM | Purple | Premium SKU purchases |