Smart Technology
Core Platformdevice_list_allSmart TechnologyLists all connected devices (screens, cameras, Sonos speakers, sensors) registered to one or multiple facilities.
BATCH OPERATIONS SUPPORTED:
- Single facility: Provide facilityId
- Multiple facilities: Provide facilityIds array to get devices across all facilities in one call
Returns device inventory including:
- Device type (screen, camera, speaker, sensor) and model
- Online/offline status (device considered offline after 5 minutes of no heartbeat)
- Device location/assignment (displayName, equipmentRound for screens, camera names)
- Network connection details (IP address, WiFi signal strength or ethernet connected, quality, SSID, channel)
- System health metrics (CPU temperature, memory usage, uptime)
- Hardware identifiers (deviceID, serial numbers, MAC addresses)
- Configuration metadata (resolution, orientation, scheduled reboots)
- Nearby WiFi networks (for site surveys and interference analysis - note in general push users to use hard wired ethernet and not rely on wifi)
- Last update timestamp (in metadata.updated only)
Identifying Active vs. Replaced Devices:
When analyzing devices, if a device has been offline for more than 7 days (1 week) AND there is another online device with the same configuration (same equipment association, camera name, location, etc.), assume the offline device has been replaced but not yet removed from the account. In such cases:
- Do NOT consider the offline device as an active device
- Focus analysis on the online replacement device
- The offline device is likely decommissioned hardware still in the system
Important:
- Device update timestamps are in metadata.updated (Unix timestamp in milliseconds)
- A device offline for >7 days with an online duplicate is likely replaced hardware
- Always prioritize online devices over offline ones when duplicates exist
Use this when troubleshooting device issues, checking facility equipment, auditing device inventory, or identifying replaced/decommissioned devices.
Parameters
| Name | Type | Description |
|---|---|---|
facilityId | string | Single facility ID. Omit this if using facilityIds for batch operations. |
facilityIds | array | Array of facility IDs for batch operations across multiple facilities. Use this instead of facilityId when checking multiple facilities at once. |
device_send_commandSmart TechnologySends remote control commands to devices (screens, cameras) at one or multiple facilities via websockets.
BATCH OPERATIONS SUPPORTED:
- Single facility: Provide facilityId
- Multiple facilities: Provide facilityIds array to send commands across all facilities in one call
- BATCH OPERATIONS: When facilityIds array is provided (multiple facilities), this will execute the action across ALL specified facilities. The AI assistant MUST ask the user to confirm before proceeding with batch actions.
CRITICAL: TWO WAYS TO SEND COMMANDS
1. BROADCAST to ALL devices at facility:
Use when you want to control ALL devices at once (e.g., "turn off all displays").
Required: facilityId, command, broadcast: true
Example: {"command": "displayOff", "broadcast": true}
2. TARGET a SPECIFIC device:
Use when controlling a single device (e.g., "reboot the reception camera").
Required: facilityId, command, uuid (device's balenaUUID)
Example: {"uuid": "60fd75d147f9ce8700fc974737ed5cff", "command": "rebootDevice"}
IMPORTANT: Get device UUIDs from device_list_all tool FIRST
To target a specific device, you MUST call the device_list_all tool first to get the balenaUUID of the device.
SCREEN COMMANDS (coaching screens/workout displays):
displayOff - Turns screen display off (device stays on, just blanks the screen)
Use: End of day, saving power, screen not neededdisplayOn - Turns screen display on
Use: Morning startup, after hours access, wake displaysunlockUpdates - Allows pending system updates to install immediately (doesn't wait for 2am)
Use: When updates need to happen urgently, during maintenance windowsrebootDevice - Full device reboot (like unplugging and plugging back in)
Use: Device frozen, major issues, after configuration changesrestartChromium - Restarts the web browser service (X11 Chromium)
Use: Display showing blank page, browser frozen, visual glitches, faster than full rebootgpuDebugOn - Shows performance overlay on screen (CPU, GPU, memory metrics)
Use: Diagnosing performance issues, checking resource usagegpuDebugOff - Removes performance overlay from screen
Use: After debugging is completerestartBleScanner - Restarts Bluetooth Low Energy scanner service
Use: BROADCAST to all devices after adding duress buttons if they're not registering
Common scenario: "Duress buttons aren't working" → broadcast restartBleScanner to all devicesosd - Displays an on-screen text message overlay on the display
Use: Show announcements, alerts, or test messages on screens
Arguments: The message text as a string
Example: {"uuid": "abc123", "command": "osd", "arguments": "Class starts in 5 minutes"}
Note: Message appears as overlay on current contentloadUrl - Loads a custom URL/webpage on the display (replaces current content)
Use: Display custom content, emergency information, or test pages
Arguments: The URL to load (must include http:// or https://)
Example: {"uuid": "abc123", "command": "loadUrl", "arguments": "http://google.com/"}
Note: This temporarily overrides the configured workout display until next program load or reboot
Technical note: Sends MQTT message as {"loadURL": "..."} format directlypowerCyclePort - Power cycles a PoE port on the network switch (advanced)
SPECIAL CASE - READ CAREFULLY:
This command makes the device send an API request to the Unifi Controller to power cycle a specific PoE port.
Use this to remotely reboot OFFLINE CCTV cameras that are powered by PoE.How to use powerCyclePort:
- Call device_list_all to find the OFFLINE camera
- Look for unifiDeviceStats in the offline camera's metadata
- Extract switchID and sw_port from unifiDeviceStats
- Send powerCyclePort command to ANY ONLINE device with arguments:
{"command": "powerCyclePort", "arguments": {"switchID": "abc123", "switchPort": 12}, "broadcast": false, "uuid": ""} - The online device will make the API call to power cycle that port, rebooting the offline camera
Why this works:
- Offline cameras can't receive commands (they're offline!)
- So we send the command to ANY online device on the network
- That device makes the Unifi API call to physically cut and restore power to the camera's PoE port
- The camera reboots and comes back online
Requirements:
- Facility must have Unifi network equipment configured
- Camera must be PoE-powered and have unifiDeviceStats in metadata
- You need an ONLINE device to send the command from
CAMERA COMMANDS (CCTV cameras):
unlockUpdates - Allows pending system updates to install immediately
Use: When updates need to happen urgentlyrebootDevice - Full camera reboot
Use: Camera frozen, not responding, connection issuespurgeSD - DESTRUCTIVE: Formats/erases ALL recordings on camera's SD card
WARNING: This permanently deletes all video recordings!
Use: ONLY when SD card is full AND user confirms they want to delete everything
Always confirm with user first: "This will permanently delete all recordings. Are you sure?"
OFFLINE DEVICE BEHAVIOR:
⚠️ Offline devices CANNOT receive commands (they're not connected to websockets).
- For broadcast commands: Only online devices will respond
- For targeted commands: Check device is online in device_list_all metadata first
- For offline cameras: Use the powerCyclePort workaround described above
WORKFLOW EXAMPLES:
Example 1: "Turn off all displays"
- Send: {"facilityId": "TestClub", "command": "displayOff", "broadcast": true}
Example 2: "Reboot the reception screen"
- Call device_list_all to find device with displayName containing "reception"
- Get its balenaUUID (e.g., "60fd75d147f9ce8700fc974737ed5cff")
- Send: {"facilityId": "TestClub", "uuid": "60fd75d147f9ce8700fc974737ed5cff", "command": "rebootDevice", "broadcast": false}
Example 3: "The front door camera is offline, bring it back online"
- Call device_list_all to find offline camera
- Check if it has metadata.unifiDeviceStats (contains switchID and sw_port)
- Find ANY online device's balenaUUID from device_list_all
- Send powerCyclePort command to the online device with camera's switch info:
{"facilityId": "TestClub", "uuid": "", "command": "powerCyclePort", "arguments": {"switchID": "abc123", "switchPort": 12}, "broadcast": false}
Example 4: "Duress buttons aren't working"
- Send: {"facilityId": "TestClub", "command": "restartBleScanner", "broadcast": true}
(This restarts Bluetooth scanner on ALL devices)
Example 5: "Show a message on the Round 1 screen saying class starts in 5 minutes"
- Call device_list_all to find screen with equipmentRound "1"
- Get its balenaUUID
- Send: {"facilityId": "TestClub", "uuid": "
", "command": "osd", "arguments": "Class starts in 5 minutes"}
Example 6: "Load Google on the reception screen to test it"
- Call device_list_all to find screen with displayName containing "reception"
- Get its balenaUUID
- Send: {"facilityId": "TestClub", "uuid": "
", "command": "loadUrl", "arguments": "http://google.com/"}
IMPORTANT NOTES:
- Always get balenaUUID from device_list_all tool before targeting specific devices
- Broadcast commands affect ALL devices (use sparingly)
- For cameras with full SD cards, confirm with user before using purgeSD
- powerCyclePort is for rebooting offline PoE devices via the network switch
- osd displays an overlay message without changing the underlying content
- loadUrl temporarily replaces content until next program load or device reboot
- Commands are sent via MQTT and execute within seconds on online devices
Parameters
| Name | Type | Description |
|---|---|---|
facilityId | string | Single facility ID. Omit this if using facilityIds for batch operations. |
facilityIds | array | Array of facility IDs for batch operations across multiple facilities. When provided, the AI MUST ask for user confirmation before executing. |
command* | string | Command to send to device(s). Screens: displayOff, displayOn, unlockUpdates, rebootDevice, restartChromium, gpuDebugOn, gpuDebugOff, restartBleScanner, osd, loadUrl, powerCyclePort. Cameras: unlockUpdates, rebootDevice, purgeSD. |
broadcast | boolean | If true, sends command to ALL devices at facility. If false, must provide uuid for specific device. Default: false. |
uuid | string | Device balenaUUID (from device_list_all tool). Required when broadcast is false. Omit when broadcast is true. |
arguments | objectstring | Optional command arguments. Used for: powerCyclePort (object with switchID and switchPort), osd (string message to display), loadUrl (string URL to load). Omit for other commands. |
integration_test_unifiSmart TechnologyTests connectivity to one or multiple facilities' Ubiquiti Unifi Network Controllers using in-club devices.
BATCH OPERATIONS SUPPORTED:
- Single facility: Provide facilityId
- Multiple facilities: Provide facilityIds array to test controllers across all facilities in one call
- BATCH OPERATIONS: When facilityIds array is provided (multiple facilities), this will execute the action across ALL specified facilities. The AI assistant MUST ask the user to confirm before proceeding with batch actions.
How it works:
- Identifies online Performance Hub devices (screens/cameras) at the facility
- Sends MQTT command to preferred device to test Unifi Controller login
- Returns controller information if connection succeeds
Returns on success:
- Controller hostname and device type
- Firmware version and update availability
- Controller uptime and IP addresses
- Connection status and response time
Common failure scenarios:
- Timeout: IP address incorrect or controller not on same network as devices
- Authentication failure: Invalid username or password
- No devices online: No ethernet-connected devices available to perform test
Requirements:
- At least one online Performance Hub device (screen or camera) at the facility
- Device must be ethernet-connected for reliable testing
- Unifi Controller must be on the same network as Performance Hub devices
Use this tool when:
- Diagnosing network connectivity issues
- Verifying Unifi Controller credentials after configuration
- Troubleshooting smart facility device health monitoring
- Validating Performance Hub setup during initial deployment
Parameters
| Name | Type | Description |
|---|---|---|
facilityId | string | Single facility ID. Omit this if using facilityIds for batch operations. |
facilityIds | array | Array of facility IDs for batch operations across multiple facilities. When provided, the AI MUST ask for user confirmation before executing. |
timeoutMs | number | Timeout in milliseconds for MQTT response. Defaults to 10000 (10 seconds). |
network_check_healthSmart TechnologyChecks network health by comparing current internet speeds against facility bandwidth requirements for one or multiple facilities.
BATCH OPERATIONS SUPPORTED:
- Single facility: Provide facilityId
- Multiple facilities: Provide facilityIds array to check network health across all facilities in one call
Analyzes bandwidth for all connected devices:
- Screens: download/upload requirements
- Cameras: recording + live streaming requirements
- Sonos speakers: streaming requirements
Returns:
- Latest speed test results (download/upload Mbps)
- Device count per category
- Required bandwidth per device type
- Pass/fail status for total bandwidth needs
Use this when diagnosing network performance issues or planning device deployments.
Parameters
| Name | Type | Description |
|---|---|---|
facilityId | string | Single facility ID. Omit this if using facilityIds for batch operations. |
facilityIds | array | Array of facility IDs for batch operations across multiple facilities. |