km_add_shell_script
Add a shell script action to a Keyboard Maestro macro by name or UID, with optional output saved to a variable.
Instructions
Add an action to execute a shell script.
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": {
"macroIdentifier": "<macroIdentifier>",
"script": "<script>"
},
"name": "km_add_shell_script"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| script | Yes | Shell script to execute | |
| saveToVariable | No | Optional: Variable name to save the script output to | |
| macroIdentifier | Yes | Macro name or UID |