declare class MessageReferenceBuilder implements JSONEncodable<RESTAPIMessageReference>
A builder that creates API-compatible JSON data for message references.
Constructors
data?: Partial<RESTAPIMessageReference>)
constructor(data?: Partial<RESTAPIMessageReference>
Creates a new message reference builder from API data.
external setChannelIdchannelId: Snowflake) : this (
channelId: Snowflake
Sets the id of the channel being referenced
external setFailIfNotExistsfailIfNotExists?: boolean) : this (
failIfNotExists?: boolean
Sets whether to fail the message creation if the referenced message does not exist
external setGuildIdguildId: Snowflake) : this (
guildId: Snowflake
Sets the id of the guild being referenced
external setMessageIdmessageId: Snowflake) : this (
messageId: Snowflake
Sets the id of the message being referenced
external setTypetype: MessageReferenceType) : this (
type: MessageReferenceType
Sets the type of message reference this represents
external toJSONvalidationOverride?: boolean) : RESTAPIMessageReference (
validationOverride?: boolean
Serializes this builder to API-compatible JSON data.Note that by disabling validation, there is no guarantee that the resulting object will be valid.