Skip to main content
Version: 0.37.12

APIBaseInteraction <Type, Data>

@deprecated

API and gateway v8 are deprecated and the types will not receive further updates, please update to v10.

Type parameters

Index

Properties

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