Module message

Source
Expand description

Constants, error types, and functions for validating Message fields.

Structs§

MessageValidationError
A message is not valid.

Enums§

MessageValidationErrorType
Type of MessageValidationError that occurred.

Constants§

ATTACHMENT_DESCIPTION_LENGTH_MAX
Maximum length of an attachment’s description.
EMBED_COUNT_LIMIT
Maximum number of embeds that a message may have.
MESSAGE_CONTENT_LENGTH_MAX
Maximum length of message content.
STICKER_MAX
Maximum amount of stickers.

Functions§

attachment
Ensure an attachment is correct.
attachment_description
Ensure an attachment’s description is correct.
attachment_filename
Ensure an attachment’s description is correct.
components
Ensure a list of components is correct.
content
Ensure a message’s content is correct.
embeds
Ensure a list of embeds is correct.
sticker_ids
Ensure that the amount of stickers in a message is correct.