Represents a group direct message.

Hierarchy

Constructors

Properties

The application that made this group channel. This can be a partial object with just an id property.

icon: null | string

The icon hash of this group, if any.

id: string
lastMessage: null | Uncached | Message<Uncached | AnyTextChannel>

The last message sent in this channel. This can be a partial object with only an id property.

managed: boolean

If this group channel is managed by an application.

The cached messages in this channel.

name: null | string

The name of this group channel.

nicks?: Record<"id" | "nick", string>

The nicknames used when creating this group channel.

owner: User | Uncached

The owner of this group channel. This can be a partial object with just an id.

recipients: Collection<string, RawUser, User, []>

The other recipients in this group channel.

type: GROUP_DM

The type of this channel.

Accessors

  • get mention(): string
  • A string that will mention this channel.

    Returns string

Methods

  • Add a reaction to a message in this channel.

    Parameters

    • messageID: string

      The ID of the message to add a reaction to.

    • emoji: string

      The reaction to add to the message. name:id for custom emojis, and the unicode codepoint for default emojis.

    Returns Promise<void>

  • Delete a message in this channel.

    Parameters

    • messageID: string

      The ID of the message to delete.

    • Optional reason: string

      The reason for deleting the message.

    Returns Promise<void>

  • Remove a reaction from a message in this channel.

    Parameters

    • messageID: string

      The ID of the message to remove a reaction from.

    • emoji: string

      The reaction to remove from the message. name:id for custom emojis, and the unicode codepoint for default emojis.

    Returns Promise<void>

  • Get the users who reacted with a specific emoji on a message.

    Parameters

    • messageID: string

      The ID of the message to get reactions from.

    • emoji: string

      The reaction to remove from the message. name:id for custom emojis, and the unicode codepoint for default emojis.

    • Optional options: GetReactionsOptions

      The options for getting the reactions.

    Returns Promise<User[]>

  • The url of this application's icon.

    Parameters

    • Optional format: "jpg" | "jpeg" | "png" | "webp" | "gif"

      The format the url should be.

    • Optional size: number

      The dimensions of the image.

    Returns null | string

  • Pin a message in this channel.

    Parameters

    • messageID: string

      The ID of the message to pin.

    • Optional reason: string

      The reason for pinning the message.

    Returns Promise<void>

  • Remove a user from this channel.

    Parameters

    • userID: string

      The ID of the user to remove.

    Returns Promise<void>

  • Unpin a message in this channel.

    Parameters

    • messageID: string

      The ID of the message to unpin.

    • Optional reason: string

      The reason for unpinning the message.

    Returns Promise<void>