discord-interactions.py

create_container

Fonction

Container (type 17) : la carte qui regroupe les composants V2. Une chaîne devient un texte.

from discord_interactions import create_container

Signature

def create_container(    *components: Any,    accent_color: int | None = None,    spoiler: bool = False,    component_id: int | None = None,) -> Dict[str, Any]

Paramètres

NomTypeDéfautDescription
*componentsAny
accent_colorint | NoneNoneCouleur de la bordure, entier RGB (0x5865F2).
spoilerboolFalseContainer masqué jusqu'au clic.
component_idint | NoneNone

Retour

Dict[str, Any]

Tape un nom : create_button, ModalBuilder, cooldown.