run_slash_command
Executes a Discord bot slash command in a channel or DM, including subcommands and named options, and returns the bot's reply or any modal to fill.
Instructions
Run a bot's slash command in a channel/DM, like typing /command. command can include subcommands ("music play"). options are by name. Returns the bot's reply (or a modal to fill).
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_id": "<channel_id>",
"command": "<command>"
},
"name": "run_slash_command"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| files | No | Files to attach (each: path, url or data_base64) | |
| command | Yes | Command name, with subcommand group/subcommand separated by spaces, e.g. "imagine" or "config set" | |
| options | No | Option values by name, e.g. {"prompt": "a cat"}; users/channels/roles by ID; attachments by file index | |
| channel_id | Yes | ||
| wait_seconds | No | How long to wait for the reply (default 15, 0 = don't wait) | |
| application_id | No | Which app, if several have this command |