add_input_binding
Add keyboard, mouse, or joypad bindings to an existing input action in Godot.
Instructions
Add key/mouse/joypad binding to 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": {
"action": "<action>"
},
"name": "add_input_binding"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | No | Keyboard key name (e.g. "Space", "A", "Escape") — uses physical keycode | |
| action | Yes | Existing input action name | |
| device | No | Device ID (-1 for all) | |
| joypad_axis | No | Joypad axis (e.g. "left_x", "right_trigger") | |
| mouse_button | No | Mouse button index (1=left, 2=right, 3=middle) | |
| joypad_button | No | Joypad button index |