feat: add POST /openclaw endpoint and enrich heartbeats with OpenClaw metadata
- Bridge server now accepts POST /openclaw from OpenClaw plugin - OpenClawMeta struct stores version, plugin_version, and agents - Heartbeat sendOnce() enriches payload with plugin metadata when available - Telemetry Payload adds optional openclaw_version field - README updated to document /openclaw endpoint and metadata enrichment - All communication remains optional — Monitor functions without plugin data
This commit is contained in:
11
README.md
11
README.md
@@ -74,6 +74,17 @@ HarborForge.Monitor/
|
||||
|------|------|
|
||||
| `GET /health` | 健康检查,返回 Monitor 版本和标识符 |
|
||||
| `GET /telemetry` | 返回最新的遥测数据快照 |
|
||||
| `POST /openclaw` | 接收 OpenClaw 插件推送的元数据(版本、代理等) |
|
||||
|
||||
### OpenClaw 元数据 enrichment
|
||||
|
||||
当 OpenClaw 插件通过 `POST /openclaw` 推送元数据后,Monitor 会在后续的心跳上报中自动将这些信息附加到遥测数据中:
|
||||
|
||||
- `openclaw_version` — OpenClaw 运行时版本
|
||||
- `plugin_version` — 插件版本
|
||||
- `agents` — 代理列表
|
||||
|
||||
如果插件从未推送过元数据,这些字段会被省略,心跳上报完全不受影响。
|
||||
|
||||
**重要**:桥接端口是可选的。如果 `MONITOR_PORT` 为 0 或未设置,桥接服务不会启动,Monitor 的心跳上报功能完全不受影响。即使桥接服务启动失败,心跳上报也会继续正常工作。
|
||||
|
||||
|
||||
Reference in New Issue
Block a user