companion_button_press
Trigger a button press on a running Bitfocus Companion instance via its HTTP API by specifying page, button index, and host/port.
Instructions
Press a button on a running Bitfocus Companion instance via HTTP API (SAFE_WRITE).
Sends a GET request to Companion's REST API to trigger a button press.
Companion must be running and accessible at the specified host/port.
Args:
page: Companion page number (1-based).
button: Button index on the page (0-based).
host: Companion host (default "localhost").
port: Companion HTTP API port (default 8000).
Returns:
str: JSON with status, url_called, response text.
Examples:
- Press button 0 on page 1: companion_button_press(page=1, button=0)
- Remote Companion: companion_button_press(page=1, button=3, host="192.168.1.50")
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": {
"page": "<page>",
"button": "<button>"
},
"name": "companion_button_press"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | No | localhost | |
| page | Yes | ||
| port | No | ||
| button | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |