Skip to main content
Glama
wowjinxy
by wowjinxy

unpin_message

Remove a pinned message from a Discord channel to manage pinned content and maintain channel organization.

Instructions

Unpin a message in a text channel.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
channel_idYes
message_idYes
reasonNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Implements the unpin_message tool: fetches the specified channel and message, then calls Discord's message.unpin() method. Also serves as registration via @server.tool() decorator.
    @server.tool()
    async def unpin_message(channel_id: str | int, message_id: str | int, reason: str | None = None, ctx: Context = None) -> str:  # type: ignore[override]
        """Unpin a message in a text channel."""
    
        assert ctx is not None
        bot, _ = await _acquire(ctx)
        channel = await _ensure_channel(bot, _require_int(channel_id, "channel_id"))
        message = await _fetch_message(channel, _require_int(message_id, "message_id"))
        await _call_discord("unpin message", message.unpin(reason=reason))
        return f"Unpinned message {message.id} in channel {channel.id}."
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden but only states the basic action. It doesn't disclose whether this requires specific permissions, what happens to the message after unpinning, whether the action is reversible, or any rate limits/error conditions. For a mutation tool with zero annotation coverage, this is inadequate.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that gets straight to the point with no wasted words. It's appropriately sized for a simple action and front-loads the essential information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with 3 parameters, 0% schema coverage, no annotations, and an output schema (which helps but doesn't compensate for missing behavioral context), the description is incomplete. It covers the basic action but lacks crucial information about parameters, permissions, side effects, and usage context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate but provides no parameter information. It doesn't explain what channel_id and message_id refer to, how to obtain them, what format they should be in, or what the optional reason parameter is for. The three parameters remain undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('unpin') and resource ('a message in a text channel'), making the purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'pin_message' or explain what unpinning entails beyond the basic action.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided about when to use this tool versus alternatives or prerequisites. The description doesn't mention when unpinning is appropriate, what permissions are required, or how it relates to 'pin_message' (its obvious sibling).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/wowjinxy/mcp-discord'

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