Run IM CLI command
runExecute native DingTalk or WeCom CLI commands through one interface and return JSON output; preview write actions before confirming.
Instructions
统一 IM 透传:执行指定平台的 CLI 命令并返回其 JSON 输出。args 是原生命令参数(不是自然语言)。写操作需用户明确意图:可先用 --dry-run 预览,确认后钉钉加 --yes。发现能力见资源 im://providers、im://dingtalk/services、im://wecom/sessions、im://dingtalk/templates。
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": {
"provider": "<provider>",
"args": "<args>"
},
"name": "run"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | Yes | 对应平台 CLI 的命令及参数(字符串数组) | |
| provider | Yes | IM 平台标识:dingtalk=钉钉,wecom=企业微信 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| data | No | CLI 的 JSON 输出(非 JSON 时为原始文本) | |
| error | No | ||
| command | No | 实际执行的命令(人类可读) | |
| provider | Yes |