EmbedFieldBuilder

export declare class EmbedFieldBuilder
export declare class EmbedFieldBuilder
A builder that creates API-compatible JSON data for embed fields.
constructor(data?)
Creates a new embed field from API data.
NameTypeOptionalDescription
dataPartial<APIEmbedField>Yes
The API data to use
setInline(inline?):this
Sets whether this field should display inline.
NameTypeOptionalDescription
inlinebooleanYes
Whether this field should display inline
setName(name):this
Sets the name for this embed field.
NameTypeOptionalDescription
namestringNo
The name to use
setValue(value):this
Sets the value for this embed field.
NameTypeOptionalDescription
valuestringNo
The value to use
toJSON(validationOverride?):APIEmbedField
Serializes this builder to API-compatible JSON data.
Note that by disabling validation, there is no guarantee that the resulting object will be valid.
NameTypeOptionalDescription
validationOverridebooleanYes
Force validation to run/not run regardless of your global preference