discord_pin_message
Pin or unpin a message in a channel using a boolean flag. Requires the Pin Messages permission and enforces the 50-pin limit. Idempotent: no effect if already pinned or unpinned.
Instructions
Pin or unpin a message in a channel, controlled by the pin flag. Requires the Pin Messages permission (a dedicated permission since early 2026, separate from Manage Messages). A channel holds at most 50 pins. Idempotent: pinning an already-pinned message (or unpinning an unpinned one) has no additional effect.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| channel_id | Yes | ID (snowflake) of the channel or thread containing the message. | |
| message_id | Yes | ID of the message to pin or unpin. | |
| pin | Yes | true to pin the message, false to unpin it. |