Overview

Examples of Discord component layouts in messages

The components flag#

To use components, send messages with the IS_COMPONENTS_V2 flag (1<<15). This flag disables traditional content and embeds, so every part of the message must be expressed as components instead.

Legacy message component behavior is not being deprecated and remains available on a message-by-message basis. New projects and features should use the current components.

What you can send#

How a component reaches your app#

A user clicking a button or choosing from a select menu produces a MESSAGE_COMPONENT interaction, type 3. Your app answers it like any other interaction, with the same three-second window. Two callback types exist for components specifically: UPDATE_MESSAGE (7) edits the message the component is attached to, and DEFERRED_UPDATE_MESSAGE (6) acknowledges without showing a loading state.

Next steps#

Updated

Was this page helpful?