@core-workspace/infoflow-openclaw-plugin 2026.3.9 → 2026.3.27-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/CHANGELOG.md +91 -0
  2. package/CLAUDE.md +135 -0
  3. package/COLLABORATION_REPORT.md +209 -0
  4. package/PROJECT_GUIDE.md +355 -0
  5. package/README.md +158 -66
  6. package/docs/dev-guide.md +63 -50
  7. package/docs/qa-feature-list.md +452 -0
  8. package/docs/webhook-guide.md +178 -0
  9. package/index.ts +28 -2
  10. package/openclaw.plugin.json +131 -21
  11. package/package.json +16 -3
  12. package/scripts/deploy.sh +66 -7
  13. package/scripts/postinstall.cjs +80 -0
  14. package/skills/infoflow-dev/SKILL.md +2 -2
  15. package/skills/infoflow-dev/references/api.md +1 -1
  16. package/src/adapter/inbound/webhook-parser.ts +27 -5
  17. package/src/adapter/inbound/ws-receiver.ts +304 -43
  18. package/src/adapter/outbound/markdown-local-images.ts +80 -0
  19. package/src/adapter/outbound/reply-dispatcher.ts +146 -65
  20. package/src/adapter/outbound/target-resolver.ts +4 -3
  21. package/src/channel/accounts.ts +97 -22
  22. package/src/channel/channel.ts +456 -12
  23. package/src/channel/media.ts +20 -6
  24. package/src/channel/monitor.ts +8 -3
  25. package/src/channel/outbound.ts +358 -21
  26. package/src/channel/streaming.ts +740 -0
  27. package/src/commands/changelog.ts +80 -0
  28. package/src/commands/doctor.ts +545 -0
  29. package/src/commands/logs.ts +449 -0
  30. package/src/commands/version.ts +20 -0
  31. package/src/compat/openclaw-sdk.ts +218 -0
  32. package/src/handler/message-handler.ts +673 -166
  33. package/src/logging.ts +1 -1
  34. package/src/runtime.ts +1 -1
  35. package/src/security/dm-policy.ts +1 -4
  36. package/src/security/group-policy.ts +174 -51
  37. package/src/tools/actions/index.ts +15 -13
  38. package/src/tools/cron/relay.ts +1154 -0
  39. package/src/tools/hooks/index.ts +13 -1
  40. package/src/tools/index.ts +714 -32
  41. package/src/types.ts +144 -25
  42. package/src/utils/audio/g722/dct_tables.ts +381 -0
  43. package/src/utils/audio/g722/decoder.ts +919 -0
  44. package/src/utils/audio/g722/defs.ts +105 -0
  45. package/src/utils/audio/g722/hd-parser.ts +247 -0
  46. package/src/utils/audio/g722/huff_tables.ts +240 -0
  47. package/src/utils/audio/g722/index.ts +78 -0
  48. package/src/utils/audio/g722/output_decoded.pcm +0 -0
  49. package/src/utils/audio/g722/output_decoded.wav +0 -0
  50. package/src/utils/audio/g722/tables.ts +173 -0
  51. package/src/utils/audio/g722/test_api.ts +31 -0
  52. package/src/utils/audio/g722/test_voice.hd +0 -0
  53. package/src/utils/bos/im-bos-client.ts +219 -0
  54. package/src/utils/group-agent-cache.ts +142 -0
  55. package/src/utils/token-adapter.ts +120 -51
@@ -15,7 +15,7 @@
15
15
  * 3. 如果是可选功能,可以加配置开关。
16
16
  */
17
17
 
18
- import type { OpenClawPluginApi } from "openclaw/plugin-sdk";
18
+ import type { OpenClawPluginApi } from "openclaw/plugin-sdk/plugin-entry";
19
19
 
20
20
  // ---------------------------------------------------------------------------
21
21
  // Hook: infoflow-intro(注入如流平台背景知识)
@@ -52,11 +52,23 @@ export function buildInfoflowIntroContext(): string {
52
52
  - 定时播报天气、日程、监控告警等信息。
53
53
  - 撤回误发的消息。
54
54
 
55
+ ### 定时任务
56
+ - 创建定时任务时优先使用 OpenClaw 内置 cron 能力。
57
+ - 在如流会话里创建“定时发消息/提醒”时,必须优先使用 \`infoflow_cron\` 工具。
58
+ - \`infoflow_cron\` 会从当前可信会话上下文自动绑定 FromUserId / groupId,不要直接用 \`openclaw cron create\` 猜测收件目标。
59
+
55
60
  ### 消息访问控制
56
61
  - 私聊:通过 dmPolicy 控制(open / pairing / allowlist)。
57
62
  - 群聊:通过 groupPolicy 控制(open / allowlist / disabled)。
58
63
  - 白名单通过 allowFrom / groupAllowFrom 配置。
59
64
 
65
+ ### 文件管理(BOS)
66
+ - **infoflow_bos_upload 工具**:将生成的文件内容(文本、代码、CSV、Markdown 等)上传到 BOS 云存储,自动返回带有效期的预签名下载链接。
67
+ - **infoflow_bos_get_url 工具**:为已存在的 BOS 文件获取/刷新预签名下载 URL。
68
+ - 当用户请求生成文件(报告、代码、数据导出等)时,使用 infoflow_bos_upload 上传内容,然后将下载链接发送给用户。
69
+ - 预签名 URL 默认 1 小时有效,最长 24 小时。用户链接过期后可请求刷新。
70
+ - 上传的文件名应包含正确的扩展名(.md、.csv、.py、.txt 等),以便用户下载后能直接打开。
71
+
60
72
  > 注意:如流消息 API 使用非标准 Bearer 格式(Bearer-<token>,含连字符),
61
73
  > 且大整数 messageid / msgseqid 需保留原始字符串精度。
62
74
  `.trim();