Pin Message
discord.pin_message
ActionChat & messagingconnection required
Calls the Discord API with the connection's credentials.
Pin a message to the top of its channel.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- API key
- Providers
- Discord
- Secret shape
- the bot token (sent as "Authorization: Bot <token>") for every op except discord.execute_webhook, whose secret is the webhook URL
- Resolved by
- config.connection_id, else node.connection_id
Configuration
3 fields, 2 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
channel_id Id of the Discord channel (right-click the channel → Copy Channel ID). | string | Yes | — | — | — |
message_id Id of the message to act on (right-click the message → Copy Message ID). | string | Yes | — | — | — |
reason Why the change was made; recorded in the server's audit log. | string | No | — | ≤ 512 characters | — |
Output
One shape.
result
| Field | Type | Example |
|---|---|---|
ok True once Discord accepted the call. | boolean | true |
message_id Id of the pinned message. | string | — |
channel_id Channel it was pinned in. | string | — |
pinned True — the message is now pinned. | boolean | true |
{
"channel_id": "",
"message_id": "",
"ok": true,
"pinned": true
}Notes
- Needs a Discord connection whose secret is the bot token.
- Needs PIN_MESSAGES — the permission Discord split out of MANAGE_MESSAGES; a channel holds at most 250 pinned messages.
See Pin Message run in a workflow.
In a technical demo we add the Discord connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.