/** * Represents a message to be sent to the API * @typedef {Object} MessagePayload * @property {string} [content] - The message content * @property {MessageEmbed[]|object[]} [embeds] - The embeds for the message (see [here]{@link https://discord.com/developers/docs/resources/channel#embed-object} for more details) * @property {MessageReference} [message_reference] - A message reference object */ /** * Represents a message to be sent to the API * @typedef {Object} MessageReference * @property {string} [message_id] - Id of the originating message * @property {string} [channel_id] - Id of the originating message's channel * @property {string} [guild_id] - Id of the originating message's guild * @property {string} [fail_if_not_exists] - When sending, whether to error if the referenced message doesn't exist instead of sending as a normal (non-reply) message, default false */ export interface MessageReference { message_id?: string; channel_id?: string; guild_id?: string; fail_if_not_exists?: boolean; } import type { Client } from '../client/Client'; import { ChannelType } from '../constants/channelTypes'; import { DataManager } from './DataManager'; import type { Guild } from './Guild'; import type { MessageEmbed, RawMessageEmbed } from './MessageEmbed'; export interface MessagePayload { content?: string; embeds?: (MessageEmbed | RawMessageEmbed)[]; reference?: MessageReference; } export declare type MessageOptions = string | MessagePayload; /** * Represents an unknown channel on Discord */ declare class Channel extends DataManager { id: string; name: string; type: ChannelType; createdTimestamp: number; guild?: Guild; constructor(client: Client, data: any, guild?: Guild); /** * Indicates whether this channel can have messages * @returns {boolean} */ isTextBased(): boolean; /** * Indicates whether this channel is a {@link TextChannel} * @returns {boolean} */ isText(): boolean; /** * Indicates whether this channel is a {@link DMChannel} * @returns {boolean} */ isDM(): boolean; /** * Indicates whether this channel is an unknown type channel * @returns {boolean} */ isUnknown(): boolean; /** * When concatenated with a string, this automatically returns the channel's mention instead of the Channel object * @returns {string} */ toString(): string; parseData(data: any): any; _update(data: any): Channel; } export { Channel }; //# sourceMappingURL=Channel.d.ts.map