MessageManager - antilandjs/antiland.js GitHub Wiki

The manager for any and all, cached or uncached, messages.

extends BaseManager

Methods

.await(options?) : Promise<Map<string, Message>>

Await messages that meet specified conditions.

Name Type Optional
options object Yes

.bulkDelete(options?) : Promise<boolean>

Bulk delete messages.

Name Type Optional
options object Yes

.create(content, options?) : Promise<boolean>

Create a message.

Name Type Optional
content string No
options object Yes

.delete(messageId) : Promise<boolean>

Delete a message.

Name Type Optional
messageId string No

.edit(messageId, content) : Promise<boolean>

Edit a message.

Name Type Optional
messageId string No
content string No

.fetch(messageId, options?) : Promise<Message | null>

Fetch any or all messages in the chat.

Name Type Optional
messageId string Yes
options object Yes

.like(messageId) : Promise<boolean>

Like a message.

Name Type Optional
messageId string No

.translate(messageId) : Promise<boolean>

Translate a message.

Name Type Optional
messageId string No