Skip to main content
Glama

modify_sticker

Update custom Discord stickers by changing their name, description, or tags within a server. Use this tool to manage and organize sticker collections.

Instructions

Modify a custom sticker in a server

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
guildIdYesThe ID of the server (guild)
stickerIdYesThe ID of the sticker to modify
nameNoNew name for the sticker
descriptionNoNew description
tagsNoNew tags
reasonNoReason for modifying

Implementation Reference

  • Handler function implementing the modify_sticker tool: fetches guild and sticker, prepares optional edit data, performs the edit, handles errors with withErrorHandling, and formats response.
    async ({ guildId, stickerId, name, description, tags, reason }) => { const result = await withErrorHandling(async () => { const client = await getDiscordClient(); const guild = await client.guilds.fetch(guildId); const sticker = await guild.stickers.fetch(stickerId); const editData: { name?: string; description?: string; tags?: string; reason?: string } = {}; if (name) editData.name = name; if (description) editData.description = description; if (tags) editData.tags = tags; if (reason) editData.reason = reason; const updated = await sticker.edit(editData); return { id: updated.id, name: updated.name, description: updated.description, tags: updated.tags, message: 'Sticker updated successfully', }; }); if (!result.success) { return { content: [{ type: 'text', text: result.error }], isError: true }; } return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }] };
  • Zod input schema defining parameters for the modify_sticker tool.
    { guildId: z.string().describe('The ID of the server (guild)'), stickerId: z.string().describe('The ID of the sticker to modify'), name: z.string().optional().describe('New name for the sticker'), description: z.string().optional().describe('New description'), tags: z.string().optional().describe('New tags'), reason: z.string().optional().describe('Reason for modifying'),
  • Direct registration of the modify_sticker tool using server.tool(), including name, description, input schema, and inline handler.
    // Modify sticker server.tool( 'modify_sticker', 'Modify a custom sticker in a server', { guildId: z.string().describe('The ID of the server (guild)'), stickerId: z.string().describe('The ID of the sticker to modify'), name: z.string().optional().describe('New name for the sticker'), description: z.string().optional().describe('New description'), tags: z.string().optional().describe('New tags'), reason: z.string().optional().describe('Reason for modifying'), }, async ({ guildId, stickerId, name, description, tags, reason }) => { const result = await withErrorHandling(async () => { const client = await getDiscordClient(); const guild = await client.guilds.fetch(guildId); const sticker = await guild.stickers.fetch(stickerId); const editData: { name?: string; description?: string; tags?: string; reason?: string } = {}; if (name) editData.name = name; if (description) editData.description = description; if (tags) editData.tags = tags; if (reason) editData.reason = reason; const updated = await sticker.edit(editData); return { id: updated.id, name: updated.name, description: updated.description, tags: updated.tags, message: 'Sticker updated successfully', }; }); if (!result.success) { return { content: [{ type: 'text', text: result.error }], isError: true }; } return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }] }; } ); }
  • src/index.ts:59-59 (registration)
    Invocation of registerEmojiTools(server) which registers multiple emoji/sticker tools including modify_sticker.
    registerEmojiTools(server);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/scarecr0w12/discord-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server