Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Message<T>

Type parameters

Hierarchy

Index

Constructors

constructor

Properties

attachments

attachments: Attachment[]

author

author: User

channel

channel: T

channelMentions

channelMentions: string[]

Optional cleanContent

cleanContent: undefined | string

Optional command

command: undefined | Command

content

content: string

createdAt

createdAt: number

Optional editedTimestamp

editedTimestamp: undefined | number

embeds

embeds: Embed[]

Optional guildID

guildID: undefined | string

id

id: string

Optional member

member: undefined | Member

mentionEveryone

mentionEveryone: boolean

mentions

mentions: User[]

pinned

pinned: boolean

Optional prefix

prefix: undefined | string

reactions

reactions: { count: number; me: boolean }

Type declaration

  • [s: string]: any
  • count: number
  • me: boolean

roleMentions

roleMentions: string[]

timestamp

timestamp: number

tts

tts: boolean

type

type: number

Optional webhookID

webhookID: undefined | string

Methods

addReaction

  • addReaction(reaction: string, userID?: string): Promise<void>
  • Parameters

    • reaction: string
    • Optional userID: string

    Returns Promise<void>

crosspost

  • Returns Promise<Message<T>>

delete

  • delete(reason?: string): Promise<void>
  • Parameters

    • Optional reason: string

    Returns Promise<void>

edit

  • Parameters

    Returns Promise<Message<T>>

getReaction

  • getReaction(reaction: string, limit?: number, before?: string, after?: string): Promise<User[]>
  • Parameters

    • reaction: string
    • Optional limit: number
    • Optional before: string
    • Optional after: string

    Returns Promise<User[]>

inspect

  • Returns Message<T>

pin

  • pin(): Promise<void>
  • Returns Promise<void>

removeMessageReactionEmoji

  • removeMessageReactionEmoji(reaction: string): Promise<void>
  • Parameters

    • reaction: string

    Returns Promise<void>

removeReaction

  • removeReaction(reaction: string, userID?: string): Promise<void>
  • Parameters

    • reaction: string
    • Optional userID: string

    Returns Promise<void>

removeReactions

  • removeReactions(): Promise<void>
  • Returns Promise<void>

toJSON

  • Parameters

    • Optional props: string[]

    Returns JSONCache

unpin

  • unpin(): Promise<void>
  • Returns Promise<void>

Generated using TypeDoc