km_create_macro
Create a new macro in Keyboard Maestro by name, optionally adding an initial action using XML.
Instructions
Create a new macro with a name. Optionally include action XML to add an initial action.
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": {
"name": "<name>"
},
"name": "km_create_macro"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Name for the new macro | |
| actionXml | No | Optional: XML for an action to add (e.g. <dict><key>MacroActionType</key><string>DisplayLargeText</string><key>Text</key><string>Hello</string></dict>) | |
| groupName | No | Optional: name of the group to add the macro to (defaults to Global Macro Group) |