Skip to main content

Class: GuildTextChannel

Hierarchy

Constructors

constructor

new GuildTextChannel(app, raw)

Parameters

NameType
appApp
rawAPIGuildChannel<GuildText>

Overrides

BaseChannel.constructor

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:28

Properties

app

app: App

Inherited from

BaseChannel.app

Defined in

packages/disploy/src/structs/Base.ts:4


createdTimestamp

createdTimestamp: number

Timestamp of when the channel was created.

Inherited from

BaseChannel.createdTimestamp

Defined in

packages/disploy/src/structs/BaseChannel.ts:10


guildId

guildId: string

The ID of the guild.

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:16


id

id: string

The ID of the channel.

Inherited from

BaseChannel.id

Defined in

packages/disploy/src/structs/ChannelMethods.ts:9


name

name: string

The name of the channel.

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:21


type

type: GuildText = ChannelType.GuildText

The type of the channel.

Overrides

BaseChannel.type

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:26

Methods

delete

delete(): Promise<void>

Deletes the channel.

Returns

Promise<void>

Inherited from

BaseChannel.delete

Defined in

packages/disploy/src/structs/ChannelMethods.ts:19


send

send(payload): Promise<Message>

Sends a message to the channel.

Parameters

NameTypeDescription
payloadAddUndefinedToPossiblyUndefinedPropertiesOfInterface<{ allowed_mentions?: APIAllowedMentions ; attachments?: Pick<APIAttachment, "id" | "description"> & Partial<Pick<APIAttachment, "filename">>[] ; components?: APIActionRowComponent<APIMessageActionRowComponent>[] ; content?: string ; embeds?: APIEmbed[] ; flags?: MessageFlags ; message_reference?: APIMessageReferenceSend ; nonce?: string | number ; sticker_ids?: [string, string, string] | [string] | [string, string] ; tts?: boolean }>Message payload

Returns

Promise<Message>

Created message

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:49


toString

toString(): string

Returns a string that represents the Channel object as a mention.

Example

interaction.reply(You chose ${interaction.channel}); // => You chose #general

Returns

string

A string that represents the Channel object as a mention.

Overrides

BaseChannel.toString

Defined in

packages/disploy/src/structs/GuildTextChannel.ts:40