class GuildPreviewEmoji
extends
BaseGuildEmojiexport class GuildPreviewEmoji extends BaseGuildEmoji
Represents an instance of an emoji belonging to a public guild obtained through Discord's preview endpoint.
readonlyDate createdAt :
The time the emoji was created at, or null if unicode
Inherited from: BaseGuildEmoji
readonlynumber createdTimestamp :
The timestamp the emoji was created at, or null if unicode
Inherited from: BaseGuildEmoji
GuildPreview guild :
The public guild this emoji is part of
readonlystring identifier :
The identifier of this emoji, used for message reactions
Inherited from: Emoji
Whether this emoji is managed by an external service
Inherited from: BaseGuildEmoji
Whether or not this emoji requires colons surrounding it
Inherited from: BaseGuildEmoji
Snowflake[] roles :
The roles this emoji is active for
deprecatedreadonlystring url :
Use imageURL instead.
Returns a URL for the emoji.
Inherited from: BaseGuildEmoji
imageURLoptions?: BaseImageURLOptions) : string (
Returns a URL for the emoji.
Inherited from: BaseGuildEmoji
toStringstring () :
When concatenated with a string, this automatically returns the text required to form a graphical emoji on Discord instead of the Emoji object.
// Send a custom emoji from a guild:
const emoji = guild.emojis.cache.first();
msg.channel.send(`Hello! ${emoji}`);
// Send the emoji used in a reaction to the channel the reaction is part of
reaction.message.channel.send(`The emoji used was: ${reaction.emoji}`);
Inherited from: Emoji