Appearance
Bridge Mode
The bridge mode forwards MQTT beacon and gateway data to Zabbix for monitoring. It is implemented in server/src/bridge.ts.
Overview
The bridge acts as a translator between the MQTT beacon/gateway protocol and Zabbix's monitoring system. It can run standalone (bridge-only) or alongside the full SafeCall server.
How It Works
- Cache: Periodically fetches the list of known beacons and gateways from the SafeCall REST API
- Filter: Only processes MQTT messages for devices that exist in the cache
- Throttle: Applies configurable delays between updates to avoid flooding Zabbix
- Send: Forwards device metrics to Zabbix via
ZabbixSender
Data Forwarded
Beacon Data (from adv1/adv4/adv8)
- Battery level
- Temperature
- Humidity
- SOS/panic button state
- Signal strength
Gateway Data (from alive messages)
- IP address
- Uptime
- Firmware version
- Last seen timestamp
Configuration
| Key | Description |
|---|---|
bridge_mqtt_url | MQTT broker URL |
bridge_mqtt_user | MQTT username |
bridge_mqtt_pass | MQTT password |
bridge_server_url | SafeCall server URL (for REST cache) |
bridge_zabbix_host | Zabbix server hostname |
bridge_zabbix_port | Zabbix server port |
bridge_endpoint_beacon | REST endpoint for beacon list |
bridge_endpoint_gateway | REST endpoint for gateway list |
bridge_delay_beacon | Minimum seconds between beacon updates |
bridge_delay_gateway | Minimum seconds between gateway updates |
bridge_cache_update_interval | Seconds between cache refreshes |
LLD Integration
The bridge also supports Zabbix Low-Level Discovery (LLD). The server exposes LLD endpoints:
GET /lld/beacons— Returns beacon discovery data in LLD formatGET /lld/gateways— Returns gateway discovery data in LLD format
These are consumed by Zabbix to automatically create monitoring items for new devices.
Standalone Mode
When server_features contains only "bridge", the server starts in standalone bridge mode. This only requires MQTT and Zabbix configuration — no database, HTTP server, or JWT setup is needed.