feat: implement telemetry sidecar with API Key authentication #1

Closed
zhi wants to merge 3 commits from feat/telemetry-sidecar into main
Owner

变更内容

  • 重构 telemetry.mjs 支持 API Key 认证(替代 challenge_uuid)
  • 系统指标收集:CPU、内存、磁盘、负载、运行时间
  • OpenClaw 状态读取:版本和 agent 列表
  • 指数退避重试逻辑(最大 5 分钟)
  • 离线缓存:磁盘持久化 + 恢复后批量上报
  • 更新 plugin/index.ts 传递 apiKey 配置
  • 更新安装脚本提示 apiKey 配置
  • 更新 README 文档

依赖

需要 Backend PR(feat/monitor-api-key)先合并

## 变更内容 - 重构 telemetry.mjs 支持 API Key 认证(替代 challenge_uuid) - 系统指标收集:CPU、内存、磁盘、负载、运行时间 - OpenClaw 状态读取:版本和 agent 列表 - 指数退避重试逻辑(最大 5 分钟) - 离线缓存:磁盘持久化 + 恢复后批量上报 - 更新 plugin/index.ts 传递 apiKey 配置 - 更新安装脚本提示 apiKey 配置 - 更新 README 文档 ## 依赖 需要 Backend PR(feat/monitor-api-key)先合并
zhi added 3 commits 2026-03-19 17:28:54 +00:00
- Add HF_MONITOR_API_KEY environment variable support
- Add X-API-Key header to HTTP requests
- Remove challenge_uuid dependency
- Use heartbeat-v2 endpoint for API Key auth
- Warn instead of exit when API key is missing
- Add offline cache with disk persistence
- Flush cached payloads on successful heartbeat
- Store failed payloads to cache for retry
- Configurable cache path and max size
- Load cache on startup
- plugin/index.ts: use apiKey instead of challengeUuid
- scripts/install.mjs: update prompts and examples
- README.md: update config docs and examples
zhi closed this pull request 2026-03-19 20:22:09 +00:00

Pull request closed

Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: zhi/HarborForge.OpenclawPlugin#1