EmojiShorter

Signature

export declare class EmojiShorter extends BaseShorter

Properties

0

No properties.

Methods

5

Methods

list(guildId: string, force?: boolean): Promise<GuildEmojiStructure[]>;

Retrieves a list of emojis in the guild.

Parameters
guildId
The ID of the guild.
force
Whether to force fetching emojis from the API even if they exist in the cache.
Returns

A Promise that resolves to an array of emojis.

fetch(guildId: string, emojiId: string, force?: boolean): Promise<GuildEmojiStructure>;

Fetches an emoji by its ID.

Parameters
guildId
The ID of the guild.
emojiId
The ID of the emoji to fetch.
force
Whether to force fetching the emoji from the API even if it exists in the cache.
Returns

A Promise that resolves to the fetched emoji.

delete(guildId: string, emojiId: string, reason?: string): Promise<void>;

Deletes an emoji from the guild.

Parameters
guildId
The ID of the guild.
emojiId
The ID of the emoji to delete.
reason
The reason for deleting the emoji.
edit(guildId: string, emojiId: string, body: RESTPatchAPIGuildEmojiJSONBody, reason?: string): Promise<GuildEmojiStructure>;

Edits an emoji in the guild.

Parameters
guildId
The ID of the guild.
emojiId
The ID of the emoji to edit.
body
The data to update the emoji with.
reason
The reason for editing the emoji.
Returns

A Promise that resolves to the edited emoji.