Delete message
delete_messageDelete a Discord message through a two-step preview and confirm_token flow, so the user approves before anything is removed. Supports dry_run.
Instructions
Delete one message. Safe to call directly: the first call deletes nothing and returns a preview plus a confirm_token, and the deletion only happens when the call is repeated with that token. Use this two-step flow to let the user approve through the conversation rather than telling them to delete things by hand in Discord. Supports dry_run.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"channel": "<channel>",
"message_id": "<message_id>"
},
"name": "delete_message"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| guild | No | Guild (server) name or ID. Omit to use the default guild. | |
| reason | No | Audit log reason. | |
| channel | Yes | Channel name or ID. | |
| dry_run | No | ||
| message_id | Yes | The message to delete: its ID or link. | |
| confirm_token | No | The token from this exact action's preview. Where the app can show a confirmation dialog, calling with it asks the user there, and it happens only if they agree. |