Skip to main content
Version: 0.36.1

APIBaseInteraction <Type, Data>

Type parameters

Index

Properties

optionalapp_permissions

app_permissions?: string

Bitwise set of permissions the app or bot has within the channel the interaction was sent from

application_id

application_id: string

ID of the application this interaction is for

optionalchannel_id

channel_id?: string

The channel it was sent from

optionaldata

data?: Data

The command data payload

optionalguild_id

guild_id?: string

The guild it was sent from

optionalguild_locale

guild_locale?: en-US | en-GB | bg | zh-CN | zh-TW | hr | cs | da | nl | fi | fr | de | el | hi | hu | it | ja | ko | lt | no | pl | pt-BR | ro | ru | es-ES | sv-SE | th | tr | uk | vi

The guild’s preferred locale, if invoked in a guild

id

id: string

ID of the interaction

locale

locale: en-US | en-GB | bg | zh-CN | zh-TW | hr | cs | da | nl | fi | fr | de | el | hi | hu | it | ja | ko | lt | no | pl | pt-BR | ro | ru | es-ES | sv-SE | th | tr | uk | vi

The selected language of the invoking user

optionalmember

Guild member data for the invoking user, including permissions

This is only sent when an interaction is invoked in a guild

optionalmessage

message?: APIMessage

For components, the message they were attached to

token

token: string

A continuation token for responding to the interaction

type

type: Type

The type of interaction

optionaluser

user?: APIUser

User object for the invoking user, if invoked in a DM

version

version: 1

Read-only property, always 1