@wowok/agent-mcp 3.0.3 → 3.0.5

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 (300) hide show
  1. package/dist/evaluation/path-reasoning.d.ts +4 -2
  2. package/dist/evaluation/path-reasoning.js +1 -1
  3. package/dist/extensions/constraint-registry.d.ts +2 -2
  4. package/dist/extensions/constraint-registry.js +1 -1
  5. package/dist/extensions/custom-registry-file.d.ts +22 -0
  6. package/dist/extensions/custom-registry-file.js +1 -0
  7. package/dist/extensions/index.d.ts +2 -1
  8. package/dist/extensions/index.js +1 -1
  9. package/dist/extensions/industry-pack.d.ts +7 -0
  10. package/dist/extensions/industry-pack.js +1 -1
  11. package/dist/extensions/metric-registry.d.ts +2 -2
  12. package/dist/extensions/metric-registry.js +1 -1
  13. package/dist/extensions/modes.js +1 -1
  14. package/dist/extensions/registry.d.ts +2 -2
  15. package/dist/extensions/registry.js +1 -1
  16. package/dist/extensions/types.d.ts +4 -0
  17. package/dist/goal/GoalEngine.d.ts +13 -1
  18. package/dist/goal/GoalEngine.js +1 -1
  19. package/dist/goal/next-steps.d.ts +12 -0
  20. package/dist/goal/next-steps.js +1 -0
  21. package/dist/goal/pursue.d.ts +18 -0
  22. package/dist/goal/pursue.js +1 -0
  23. package/dist/goal/types.d.ts +72 -0
  24. package/dist/goal/types.js +1 -1
  25. package/dist/graph/onchain/analyze.d.ts +44 -0
  26. package/dist/graph/onchain/analyze.js +1 -0
  27. package/dist/graph/onchain/analyze.spec.d.ts +1 -0
  28. package/dist/graph/onchain/analyze.spec.js +1 -0
  29. package/dist/graph/onchain/anti-cheat.d.ts +39 -0
  30. package/dist/graph/onchain/anti-cheat.js +1 -0
  31. package/dist/graph/onchain/anti-cheat.spec.d.ts +1 -0
  32. package/dist/graph/onchain/anti-cheat.spec.js +1 -0
  33. package/dist/graph/onchain/dataplane.d.ts +44 -0
  34. package/dist/graph/onchain/dataplane.js +1 -0
  35. package/dist/graph/onchain/edge-schema.d.ts +60 -0
  36. package/dist/graph/onchain/edge-schema.js +1 -0
  37. package/dist/graph/onchain/expand.d.ts +4 -0
  38. package/dist/graph/onchain/expand.js +1 -0
  39. package/dist/graph/onchain/extract.d.ts +21 -0
  40. package/dist/graph/onchain/extract.js +1 -0
  41. package/dist/graph/onchain/index.d.ts +17 -0
  42. package/dist/graph/onchain/index.js +1 -0
  43. package/dist/graph/onchain/interest.d.ts +10 -0
  44. package/dist/graph/onchain/interest.js +1 -0
  45. package/dist/graph/onchain/interest.spec.d.ts +1 -0
  46. package/dist/graph/onchain/interest.spec.js +1 -0
  47. package/dist/graph/onchain/onchain.spec.d.ts +1 -0
  48. package/dist/graph/onchain/onchain.spec.js +1 -0
  49. package/dist/graph/onchain/order-status.d.ts +53 -0
  50. package/dist/graph/onchain/order-status.js +1 -0
  51. package/dist/graph/onchain/project-relationship.d.ts +3 -0
  52. package/dist/graph/onchain/project-relationship.js +1 -0
  53. package/dist/graph/onchain/sdk-batch.d.ts +117 -0
  54. package/dist/graph/onchain/sdk-batch.js +1 -0
  55. package/dist/graph/onchain/sdk-dataplane.d.ts +40 -0
  56. package/dist/graph/onchain/sdk-dataplane.js +1 -0
  57. package/dist/graph/onchain/strategy.d.ts +54 -0
  58. package/dist/graph/onchain/strategy.js +1 -0
  59. package/dist/graph/onchain/strategy.spec.d.ts +1 -0
  60. package/dist/graph/onchain/strategy.spec.js +1 -0
  61. package/dist/graph/onchain/types.d.ts +238 -0
  62. package/dist/graph/onchain/types.js +1 -0
  63. package/dist/graph/onchain/viewport.d.ts +5 -0
  64. package/dist/graph/onchain/viewport.js +1 -0
  65. package/dist/harness/recover.js +1 -1
  66. package/dist/index.js +1 -1
  67. package/dist/intent/enrich.js +1 -1
  68. package/dist/keeper/detectors.d.ts +1 -1
  69. package/dist/keeper/detectors.js +1 -1
  70. package/dist/knowledge/account-marks.js +1 -1
  71. package/dist/knowledge/anti-cheat.d.ts +2 -37
  72. package/dist/knowledge/anti-cheat.js +1 -1
  73. package/dist/knowledge/contract-invariants.js +1 -1
  74. package/dist/knowledge/event-semantics.js +1 -1
  75. package/dist/knowledge/getting-started.d.ts +37 -0
  76. package/dist/knowledge/getting-started.js +1 -0
  77. package/dist/knowledge/goal-completion.js +1 -1
  78. package/dist/knowledge/guard-puzzle.js +1 -1
  79. package/dist/knowledge/guard-render.d.ts +1 -0
  80. package/dist/knowledge/guard-render.js +1 -1
  81. package/dist/knowledge/guard-submission-brief.d.ts +83 -0
  82. package/dist/knowledge/guard-submission-brief.js +1 -0
  83. package/dist/knowledge/guard-submission-prompt.d.ts +13 -0
  84. package/dist/knowledge/guard-submission-prompt.js +1 -1
  85. package/dist/knowledge/index.d.ts +6 -4
  86. package/dist/knowledge/index.js +1 -1
  87. package/dist/knowledge/industry-registry.js +1 -1
  88. package/dist/knowledge/industry-strategy.d.ts +91 -0
  89. package/dist/knowledge/industry-strategy.js +1 -0
  90. package/dist/knowledge/jsonrpc-enum.js +1 -1
  91. package/dist/knowledge/market-metrics.d.ts +14 -3
  92. package/dist/knowledge/market-metrics.js +1 -1
  93. package/dist/knowledge/migration-preflight.js +1 -1
  94. package/dist/knowledge/operation-dictionary.d.ts +1 -1
  95. package/dist/knowledge/safety-rules.js +1 -1
  96. package/dist/knowledge/scenario-topology.d.ts +6 -1
  97. package/dist/knowledge/scenario-topology.js +1 -1
  98. package/dist/knowledge/service-ledger.js +1 -1
  99. package/dist/knowledge/service-risk-node.d.ts +3 -0
  100. package/dist/knowledge/service-risk-node.js +1 -0
  101. package/dist/knowledge/service-risk.d.ts +2 -0
  102. package/dist/knowledge/service-risk.js +1 -1
  103. package/dist/knowledge/service-templates.d.ts +2 -0
  104. package/dist/knowledge/service-templates.js +1 -1
  105. package/dist/knowledge/strategy-manuals.d.ts +17 -0
  106. package/dist/knowledge/strategy-manuals.js +1 -0
  107. package/dist/knowledge/supply-chain.d.ts +3 -1
  108. package/dist/knowledge/supply-chain.js +1 -1
  109. package/dist/knowledge/template-registry.js +1 -1
  110. package/dist/knowledge/tools-reference.js +1 -1
  111. package/dist/knowledge/workflow-guidance.d.ts +3 -118
  112. package/dist/knowledge/workflow-guidance.js +1 -1
  113. package/dist/knowledge/workspace-lists.js +1 -1
  114. package/dist/monitor/MonitorLoop.js +1 -1
  115. package/dist/monitor/ScopeResolver.js +1 -1
  116. package/dist/participation/radar-core.d.ts +15 -15
  117. package/dist/participation/radar-core.js +1 -1
  118. package/dist/persona/analyzer.d.ts +2 -1
  119. package/dist/persona/bridge.d.ts +5 -1
  120. package/dist/persona/bridge.js +1 -1
  121. package/dist/persona/defaults.js +1 -1
  122. package/dist/persona/distill-goal.d.ts +7 -1
  123. package/dist/persona/distill-goal.js +1 -1
  124. package/dist/persona/index.d.ts +13 -3
  125. package/dist/persona/index.js +1 -1
  126. package/dist/persona/model.d.ts +12 -2
  127. package/dist/persona/model.js +1 -1
  128. package/dist/persona/overrides.d.ts +1 -0
  129. package/dist/persona/overrides.js +1 -1
  130. package/dist/persona/topology-focus.d.ts +29 -0
  131. package/dist/persona/topology-focus.js +1 -0
  132. package/dist/persona/types.d.ts +81 -0
  133. package/dist/playbooks/service-build/business-puzzle.js +1 -1
  134. package/dist/playbooks/service-build/context-assembly.js +1 -1
  135. package/dist/playbooks/service-build/machine-nodes.js +1 -1
  136. package/dist/playbooks/service-build/machine-panorama.js +1 -1
  137. package/dist/playbooks/service-build/object-panorama.js +1 -1
  138. package/dist/playbooks/service-build/participation-radar.js +1 -1
  139. package/dist/playbooks/service-build/relationship-profile.d.ts +1 -0
  140. package/dist/playbooks/service-build/relationship-profile.js +1 -1
  141. package/dist/playbooks/service-build/service-panorama.d.ts +4 -0
  142. package/dist/playbooks/service-build/service-panorama.js +1 -1
  143. package/dist/playbooks/service-build/topology-query.d.ts +14 -0
  144. package/dist/playbooks/service-build/topology-query.js +1 -0
  145. package/dist/role/index.d.ts +1 -0
  146. package/dist/role/index.js +1 -1
  147. package/dist/role/profiles.d.ts +26 -0
  148. package/dist/role/profiles.js +1 -0
  149. package/dist/safety/confirm-gate.d.ts +4 -1
  150. package/dist/safety/confirm-gate.js +1 -1
  151. package/dist/schema/call/allocation.d.ts +11 -6
  152. package/dist/schema/call/arbitration.d.ts +5 -0
  153. package/dist/schema/call/base.d.ts +5 -0
  154. package/dist/schema/call/base.js +1 -1
  155. package/dist/schema/call/bridge.d.ts +26 -1
  156. package/dist/schema/call/contact.d.ts +5 -0
  157. package/dist/schema/call/demand.d.ts +5 -0
  158. package/dist/schema/call/guard.d.ts +35 -20
  159. package/dist/schema/call/machine.d.ts +10 -0
  160. package/dist/schema/call/order.d.ts +5 -0
  161. package/dist/schema/call/payment.d.ts +5 -0
  162. package/dist/schema/call/permission.d.ts +5 -0
  163. package/dist/schema/call/personal.d.ts +5 -0
  164. package/dist/schema/call/progress.d.ts +5 -0
  165. package/dist/schema/call/proof.d.ts +10 -0
  166. package/dist/schema/call/repository.d.ts +5 -0
  167. package/dist/schema/call/repository.js +1 -1
  168. package/dist/schema/call/reward.d.ts +5 -0
  169. package/dist/schema/call/semantic.js +1 -1
  170. package/dist/schema/call/service.d.ts +9 -4
  171. package/dist/schema/call/treasury.d.ts +5 -0
  172. package/dist/schema/common/index.js +1 -1
  173. package/dist/schema/employee/index.d.ts +7 -7
  174. package/dist/schema/evaluation/index.d.ts +22 -9
  175. package/dist/schema/evaluation/index.js +1 -1
  176. package/dist/schema/goal/index.d.ts +37 -1
  177. package/dist/schema/goal/index.js +1 -1
  178. package/dist/schema/goal/planning.d.ts +1 -1
  179. package/dist/schema/index.d.ts +2 -0
  180. package/dist/schema/index.js +1 -1
  181. package/dist/schema/industry-pack/index.d.ts +7 -0
  182. package/dist/schema/industry-pack/index.js +1 -1
  183. package/dist/schema/interaction/index.d.ts +34 -0
  184. package/dist/schema/interaction/index.js +1 -0
  185. package/dist/schema/local/index.d.ts +8 -4
  186. package/dist/schema/local/index.js +1 -1
  187. package/dist/schema/messenger/index.d.ts +324 -64
  188. package/dist/schema/messenger/index.js +1 -1
  189. package/dist/schema/operations.d.ts +236 -11
  190. package/dist/schema/operations.js +1 -1
  191. package/dist/schema/persona/index.d.ts +15743 -0
  192. package/dist/schema/persona/index.js +1 -1
  193. package/dist/schema/query/bi.d.ts +869 -2
  194. package/dist/schema/query/bi.js +1 -1
  195. package/dist/schema/query/index.d.ts +163 -41
  196. package/dist/schema/query/index.js +1 -1
  197. package/dist/schema/schema-query/index.d.ts +16 -0
  198. package/dist/schema/schema-query/index.js +1 -1
  199. package/dist/schema/schema-version.js +1 -1
  200. package/dist/schema/strategy-review/index.d.ts +137 -0
  201. package/dist/schema/strategy-review/index.js +1 -0
  202. package/dist/schema/trust/index.d.ts +6 -6
  203. package/dist/schema/workflow/index.d.ts +2 -2
  204. package/dist/schema-query-impl/index.js +1 -1
  205. package/dist/schemas/account_operation.output.json +8 -4
  206. package/dist/schemas/account_operation.schema.json +6 -2
  207. package/dist/schemas/ask_user.output.json +54 -0
  208. package/dist/schemas/ask_user.schema.json +78 -0
  209. package/dist/schemas/bridge_operation.schema.json +50 -5
  210. package/dist/schemas/evaluation_operation.output.json +24 -0
  211. package/dist/schemas/goal_operation.schema.json +124 -0
  212. package/dist/schemas/guard2file.schema.json +10 -1
  213. package/dist/schemas/index.json +13 -1
  214. package/dist/schemas/industry_pack_operation.output.json +39 -0
  215. package/dist/schemas/local_mark_operation.schema.json +2 -2
  216. package/dist/schemas/machineNode2file.schema.json +10 -1
  217. package/dist/schemas/messenger_operation.output.json +678 -200
  218. package/dist/schemas/messenger_operation.schema.json +74 -239
  219. package/dist/schemas/onchain_events.output.json +2 -2
  220. package/dist/schemas/onchain_operations.schema.json +183 -21
  221. package/dist/schemas/onchain_operations_allocation.schema.json +10 -1
  222. package/dist/schemas/onchain_operations_arbitration.schema.json +10 -1
  223. package/dist/schemas/onchain_operations_contact.schema.json +10 -1
  224. package/dist/schemas/onchain_operations_demand.schema.json +10 -1
  225. package/dist/schemas/onchain_operations_gen_passport.schema.json +10 -1
  226. package/dist/schemas/onchain_operations_gen_proof.schema.json +10 -1
  227. package/dist/schemas/onchain_operations_guard.schema.json +10 -1
  228. package/dist/schemas/onchain_operations_machine.schema.json +10 -1
  229. package/dist/schemas/onchain_operations_order.schema.json +10 -1
  230. package/dist/schemas/onchain_operations_payment.schema.json +10 -1
  231. package/dist/schemas/onchain_operations_permission.schema.json +10 -1
  232. package/dist/schemas/onchain_operations_personal.schema.json +10 -1
  233. package/dist/schemas/onchain_operations_progress.schema.json +10 -1
  234. package/dist/schemas/onchain_operations_proof.schema.json +10 -1
  235. package/dist/schemas/onchain_operations_repository.schema.json +13 -4
  236. package/dist/schemas/onchain_operations_reward.schema.json +10 -1
  237. package/dist/schemas/onchain_operations_service.schema.json +10 -1
  238. package/dist/schemas/onchain_operations_treasury.schema.json +10 -1
  239. package/dist/schemas/onchain_table_data.output.json +184 -0
  240. package/dist/schemas/onchain_table_data.schema.json +43 -43
  241. package/dist/schemas/persona_operation.output.json +37778 -262
  242. package/dist/schemas/persona_operation.schema.json +5960 -1
  243. package/dist/schemas/query_toolkit.output.json +1580 -2
  244. package/dist/schemas/query_toolkit.schema.json +194 -32
  245. package/dist/schemas/schema_query.schema.json +25 -1
  246. package/dist/schemas/strategy_review_operation.output.json +532 -0
  247. package/dist/schemas/strategy_review_operation.schema.json +66 -0
  248. package/dist/schemas/wowok_buildin_info.output.json +188 -6
  249. package/dist/schemas/wowok_buildin_info.schema.json +14 -0
  250. package/dist/strategy/collectors.d.ts +66 -0
  251. package/dist/strategy/collectors.js +1 -0
  252. package/dist/strategy/collectors.spec.d.ts +1 -0
  253. package/dist/strategy/collectors.spec.js +1 -0
  254. package/dist/strategy/index.d.ts +5 -0
  255. package/dist/strategy/index.js +1 -0
  256. package/dist/strategy/metrics.d.ts +20 -0
  257. package/dist/strategy/metrics.js +1 -0
  258. package/dist/strategy/review.d.ts +48 -0
  259. package/dist/strategy/review.js +1 -0
  260. package/dist/strategy/scorecard.d.ts +32 -0
  261. package/dist/strategy/scorecard.js +1 -0
  262. package/dist/strategy/store.d.ts +26 -0
  263. package/dist/strategy/store.js +1 -0
  264. package/dist/tools/handlers/ask-user.d.ts +3 -0
  265. package/dist/tools/handlers/ask-user.js +1 -0
  266. package/dist/tools/handlers/config.js +1 -1
  267. package/dist/tools/handlers/evaluation.js +1 -1
  268. package/dist/tools/handlers/goal.js +1 -1
  269. package/dist/tools/handlers/industry-pack.js +1 -1
  270. package/dist/tools/handlers/local.js +1 -1
  271. package/dist/tools/handlers/messenger.js +1 -1
  272. package/dist/tools/handlers/onchain.js +1 -1
  273. package/dist/tools/handlers/permission.js +1 -1
  274. package/dist/tools/handlers/persona.js +1 -1
  275. package/dist/tools/handlers/query.d.ts +6 -0
  276. package/dist/tools/handlers/query.js +1 -1
  277. package/dist/tools/handlers/schema-query.js +1 -1
  278. package/dist/tools/handlers/strategy-review.d.ts +2 -0
  279. package/dist/tools/handlers/strategy-review.js +1 -0
  280. package/dist/tools/handlers/watch.js +1 -1
  281. package/dist/tools/handlers/workflow.js +1 -1
  282. package/dist/tools/index.d.ts +5 -2
  283. package/dist/tools/index.js +1 -1
  284. package/dist/tools/registry/agent.js +1 -1
  285. package/dist/tools/registry/bridge.js +1 -1
  286. package/dist/tools/registry/business.js +1 -1
  287. package/dist/tools/registry/interaction.d.ts +2 -0
  288. package/dist/tools/registry/interaction.js +1 -0
  289. package/dist/tools/registry/local.js +1 -1
  290. package/dist/tools/registry/messenger.js +1 -1
  291. package/dist/tools/registry/monitor.js +1 -1
  292. package/dist/tools/registry/onchain.js +1 -1
  293. package/dist/tools/registry/query.js +1 -1
  294. package/dist/tools/rules-hook.js +1 -1
  295. package/dist/tools/shared.d.ts +2 -1
  296. package/dist/tools/shared.js +1 -1
  297. package/dist/tools/types.d.ts +7 -1
  298. package/dist/tools/wrap.d.ts +3 -3
  299. package/dist/tools/wrap.js +1 -1
  300. package/package.json +2 -2
@@ -62,9 +62,63 @@
62
62
  "description": "Plaintext hash"
63
63
  },
64
64
  "plaintext": {
65
- "description": "Decrypted plaintext (optional)",
65
+ "description": "Decrypted plaintext text. UNDEFINED for attachment messages (zipMetadata present) — their base64 envelope is stripped at the read boundary; read msg.attachment for metadata and use save_attachment for bytes",
66
66
  "type": "string"
67
67
  },
68
+ "attachment": {
69
+ "description": "Present when this message is an attachment (zipMetadata present). Byte-free descriptor; payload never embedded",
70
+ "type": "object",
71
+ "properties": {
72
+ "kind": {
73
+ "type": "string",
74
+ "enum": [
75
+ "image",
76
+ "video",
77
+ "audio",
78
+ "voice",
79
+ "file",
80
+ "wts",
81
+ "wip"
82
+ ],
83
+ "description": "Attachment business type: image/video/audio are inline-renderable media; 'voice' is an explicit voice message (webm cannot be auto-distinguished from video); 'file' is a generic document; wts/wip are evidence files"
84
+ },
85
+ "fileName": {
86
+ "type": "string",
87
+ "description": "Original file name (transport .zip suffix stripped)"
88
+ },
89
+ "mimeType": {
90
+ "type": "string",
91
+ "description": "MIME type inferred from extension or sender-provided"
92
+ },
93
+ "size": {
94
+ "type": "number",
95
+ "description": "Payload size in bytes (uncompressed)"
96
+ },
97
+ "caption": {
98
+ "description": "Sender-provided caption (E2EE, inside the encrypted envelope)",
99
+ "type": "string"
100
+ },
101
+ "durationMs": {
102
+ "description": "Audio/video duration in milliseconds",
103
+ "type": "number"
104
+ },
105
+ "width": {
106
+ "description": "Media width in pixels",
107
+ "type": "number"
108
+ },
109
+ "height": {
110
+ "description": "Media height in pixels",
111
+ "type": "number"
112
+ }
113
+ },
114
+ "required": [
115
+ "kind",
116
+ "fileName",
117
+ "mimeType",
118
+ "size"
119
+ ],
120
+ "additionalProperties": false
121
+ },
68
122
  "replyTo": {
69
123
  "description": "Quoted (replied-to) message reference, if this message replies to a previous one",
70
124
  "type": "object",
@@ -596,9 +650,63 @@
596
650
  "description": "Plaintext hash"
597
651
  },
598
652
  "plaintext": {
599
- "description": "Decrypted plaintext (optional)",
653
+ "description": "Decrypted plaintext text. UNDEFINED for attachment messages (zipMetadata present) — their base64 envelope is stripped at the read boundary; read msg.attachment for metadata and use save_attachment for bytes",
600
654
  "type": "string"
601
655
  },
656
+ "attachment": {
657
+ "description": "Present when this message is an attachment (zipMetadata present). Byte-free descriptor; payload never embedded",
658
+ "type": "object",
659
+ "properties": {
660
+ "kind": {
661
+ "type": "string",
662
+ "enum": [
663
+ "image",
664
+ "video",
665
+ "audio",
666
+ "voice",
667
+ "file",
668
+ "wts",
669
+ "wip"
670
+ ],
671
+ "description": "Attachment business type: image/video/audio are inline-renderable media; 'voice' is an explicit voice message (webm cannot be auto-distinguished from video); 'file' is a generic document; wts/wip are evidence files"
672
+ },
673
+ "fileName": {
674
+ "type": "string",
675
+ "description": "Original file name (transport .zip suffix stripped)"
676
+ },
677
+ "mimeType": {
678
+ "type": "string",
679
+ "description": "MIME type inferred from extension or sender-provided"
680
+ },
681
+ "size": {
682
+ "type": "number",
683
+ "description": "Payload size in bytes (uncompressed)"
684
+ },
685
+ "caption": {
686
+ "description": "Sender-provided caption (E2EE, inside the encrypted envelope)",
687
+ "type": "string"
688
+ },
689
+ "durationMs": {
690
+ "description": "Audio/video duration in milliseconds",
691
+ "type": "number"
692
+ },
693
+ "width": {
694
+ "description": "Media width in pixels",
695
+ "type": "number"
696
+ },
697
+ "height": {
698
+ "description": "Media height in pixels",
699
+ "type": "number"
700
+ }
701
+ },
702
+ "required": [
703
+ "kind",
704
+ "fileName",
705
+ "mimeType",
706
+ "size"
707
+ ],
708
+ "additionalProperties": false
709
+ },
602
710
  "replyTo": {
603
711
  "description": "Quoted (replied-to) message reference, if this message replies to a previous one",
604
712
  "type": "object",
@@ -811,14 +919,11 @@
811
919
  "properties": {
812
920
  "operation": {
813
921
  "type": "string",
814
- "const": "extract_zip_messages"
922
+ "const": "save_attachment"
815
923
  },
816
924
  "result": {
817
- "type": "array",
818
- "items": {
819
- "type": "string"
820
- },
821
- "description": "Extracted file paths"
925
+ "type": "string",
926
+ "description": "Absolute path of the saved attachment file"
822
927
  }
823
928
  },
824
929
  "required": [
@@ -844,6 +949,13 @@
844
949
  },
845
950
  "description": "Generated WTS file paths"
846
951
  },
952
+ "htmlFiles": {
953
+ "type": "array",
954
+ "items": {
955
+ "type": "string"
956
+ },
957
+ "description": "Generated HTML report paths — one human-readable companion per WTS file, written next to it (same base name)"
958
+ },
847
959
  "totalMessageCount": {
848
960
  "type": "number",
849
961
  "description": "Total message count"
@@ -870,6 +982,7 @@
870
982
  },
871
983
  "required": [
872
984
  "files",
985
+ "htmlFiles",
873
986
  "totalMessageCount",
874
987
  "timeRange"
875
988
  ],
@@ -1634,229 +1747,594 @@
1634
1747
  "const": "pull_messages"
1635
1748
  },
1636
1749
  "result": {
1637
- "type": "array",
1638
- "items": {
1639
- "type": "object",
1640
- "properties": {
1641
- "messageId": {
1642
- "type": "string",
1643
- "description": "Message ID"
1644
- },
1645
- "fromAddress": {
1646
- "type": "string",
1647
- "description": "Sender address"
1648
- },
1649
- "toAddress": {
1650
- "type": "string",
1651
- "description": "Recipient address"
1652
- },
1653
- "plaintextHash": {
1654
- "type": "string",
1655
- "description": "Plaintext hash"
1656
- },
1657
- "plaintext": {
1658
- "description": "Decrypted plaintext (optional)",
1659
- "type": "string"
1660
- },
1661
- "replyTo": {
1662
- "description": "Quoted (replied-to) message reference, if this message replies to a previous one",
1750
+ "anyOf": [
1751
+ {
1752
+ "type": "array",
1753
+ "items": {
1663
1754
  "type": "object",
1664
1755
  "properties": {
1665
1756
  "messageId": {
1666
1757
  "type": "string",
1667
- "description": "Replied-to message ID (unique within the conversation)"
1668
- }
1669
- },
1670
- "required": [
1671
- "messageId"
1672
- ],
1673
- "additionalProperties": false
1674
- },
1675
- "guardAddress": {
1676
- "description": "Guard address",
1677
- "type": "string"
1678
- },
1679
- "passportAddress": {
1680
- "description": "Passport address",
1681
- "type": "string"
1682
- },
1683
- "lastReceivedLeafIndex": {
1684
- "description": "Last received leaf index",
1685
- "type": "number"
1686
- },
1687
- "direction": {
1688
- "type": "string",
1689
- "enum": [
1690
- "sent",
1691
- "received"
1692
- ],
1693
- "description": "Message direction"
1694
- },
1695
- "status": {
1696
- "type": "string",
1697
- "enum": [
1698
- "pending",
1699
- "confirmed",
1700
- "read",
1701
- "failed",
1702
- "rejected",
1703
- "decrypted",
1704
- "decrypt_failed"
1705
- ],
1706
- "description": "Message status"
1707
- },
1708
- "msgType": {
1709
- "anyOf": [
1710
- {
1711
- "type": "number",
1712
- "const": 1
1758
+ "description": "Message ID"
1713
1759
  },
1714
- {
1715
- "type": "number",
1716
- "const": 3
1717
- }
1718
- ],
1719
- "description": "Message type"
1720
- },
1721
- "leafIndex": {
1722
- "description": "Leaf index",
1723
- "type": "number"
1724
- },
1725
- "prevRoot": {
1726
- "description": "Previous Merkle Root",
1727
- "type": "string"
1728
- },
1729
- "newRoot": {
1730
- "description": "Current Merkle Root",
1731
- "type": "string"
1732
- },
1733
- "serverSignature": {
1734
- "description": "Server signature",
1735
- "type": "string"
1736
- },
1737
- "serverTimestamp": {
1738
- "description": "Server confirmation timestamp",
1739
- "type": "number"
1740
- },
1741
- "serverPublicKey": {
1742
- "description": "Server public key",
1743
- "type": "string"
1744
- },
1745
- "arkConfirmed": {
1746
- "description": "ARK confirmation",
1747
- "type": "object",
1748
- "properties": {
1749
- "recipient": {
1760
+ "fromAddress": {
1761
+ "type": "string",
1762
+ "description": "Sender address"
1763
+ },
1764
+ "toAddress": {
1750
1765
  "type": "string",
1751
1766
  "description": "Recipient address"
1752
1767
  },
1753
- "recipientPublicKey": {
1768
+ "plaintextHash": {
1754
1769
  "type": "string",
1755
- "description": "Recipient public key"
1770
+ "description": "Plaintext hash"
1756
1771
  },
1757
- "signature": {
1772
+ "plaintext": {
1773
+ "description": "Decrypted plaintext text. UNDEFINED for attachment messages (zipMetadata present) — their base64 envelope is stripped at the read boundary; read msg.attachment for metadata and use save_attachment for bytes",
1774
+ "type": "string"
1775
+ },
1776
+ "attachment": {
1777
+ "description": "Present when this message is an attachment (zipMetadata present). Byte-free descriptor; payload never embedded",
1778
+ "type": "object",
1779
+ "properties": {
1780
+ "kind": {
1781
+ "type": "string",
1782
+ "enum": [
1783
+ "image",
1784
+ "video",
1785
+ "audio",
1786
+ "voice",
1787
+ "file",
1788
+ "wts",
1789
+ "wip"
1790
+ ],
1791
+ "description": "Attachment business type: image/video/audio are inline-renderable media; 'voice' is an explicit voice message (webm cannot be auto-distinguished from video); 'file' is a generic document; wts/wip are evidence files"
1792
+ },
1793
+ "fileName": {
1794
+ "type": "string",
1795
+ "description": "Original file name (transport .zip suffix stripped)"
1796
+ },
1797
+ "mimeType": {
1798
+ "type": "string",
1799
+ "description": "MIME type inferred from extension or sender-provided"
1800
+ },
1801
+ "size": {
1802
+ "type": "number",
1803
+ "description": "Payload size in bytes (uncompressed)"
1804
+ },
1805
+ "caption": {
1806
+ "description": "Sender-provided caption (E2EE, inside the encrypted envelope)",
1807
+ "type": "string"
1808
+ },
1809
+ "durationMs": {
1810
+ "description": "Audio/video duration in milliseconds",
1811
+ "type": "number"
1812
+ },
1813
+ "width": {
1814
+ "description": "Media width in pixels",
1815
+ "type": "number"
1816
+ },
1817
+ "height": {
1818
+ "description": "Media height in pixels",
1819
+ "type": "number"
1820
+ }
1821
+ },
1822
+ "required": [
1823
+ "kind",
1824
+ "fileName",
1825
+ "mimeType",
1826
+ "size"
1827
+ ],
1828
+ "additionalProperties": false
1829
+ },
1830
+ "replyTo": {
1831
+ "description": "Quoted (replied-to) message reference, if this message replies to a previous one",
1832
+ "type": "object",
1833
+ "properties": {
1834
+ "messageId": {
1835
+ "type": "string",
1836
+ "description": "Replied-to message ID (unique within the conversation)"
1837
+ }
1838
+ },
1839
+ "required": [
1840
+ "messageId"
1841
+ ],
1842
+ "additionalProperties": false
1843
+ },
1844
+ "guardAddress": {
1845
+ "description": "Guard address",
1846
+ "type": "string"
1847
+ },
1848
+ "passportAddress": {
1849
+ "description": "Passport address",
1850
+ "type": "string"
1851
+ },
1852
+ "lastReceivedLeafIndex": {
1853
+ "description": "Last received leaf index",
1854
+ "type": "number"
1855
+ },
1856
+ "direction": {
1758
1857
  "type": "string",
1759
- "description": "Recipient signature"
1858
+ "enum": [
1859
+ "sent",
1860
+ "received"
1861
+ ],
1862
+ "description": "Message direction"
1760
1863
  },
1761
- "timestamp": {
1864
+ "status": {
1865
+ "type": "string",
1866
+ "enum": [
1867
+ "pending",
1868
+ "confirmed",
1869
+ "read",
1870
+ "failed",
1871
+ "rejected",
1872
+ "decrypted",
1873
+ "decrypt_failed"
1874
+ ],
1875
+ "description": "Message status"
1876
+ },
1877
+ "msgType": {
1878
+ "anyOf": [
1879
+ {
1880
+ "type": "number",
1881
+ "const": 1
1882
+ },
1883
+ {
1884
+ "type": "number",
1885
+ "const": 3
1886
+ }
1887
+ ],
1888
+ "description": "Message type"
1889
+ },
1890
+ "leafIndex": {
1891
+ "description": "Leaf index",
1892
+ "type": "number"
1893
+ },
1894
+ "prevRoot": {
1895
+ "description": "Previous Merkle Root",
1896
+ "type": "string"
1897
+ },
1898
+ "newRoot": {
1899
+ "description": "Current Merkle Root",
1900
+ "type": "string"
1901
+ },
1902
+ "serverSignature": {
1903
+ "description": "Server signature",
1904
+ "type": "string"
1905
+ },
1906
+ "serverTimestamp": {
1907
+ "description": "Server confirmation timestamp",
1908
+ "type": "number"
1909
+ },
1910
+ "serverPublicKey": {
1911
+ "description": "Server public key",
1912
+ "type": "string"
1913
+ },
1914
+ "arkConfirmed": {
1915
+ "description": "ARK confirmation",
1916
+ "type": "object",
1917
+ "properties": {
1918
+ "recipient": {
1919
+ "type": "string",
1920
+ "description": "Recipient address"
1921
+ },
1922
+ "recipientPublicKey": {
1923
+ "type": "string",
1924
+ "description": "Recipient public key"
1925
+ },
1926
+ "signature": {
1927
+ "type": "string",
1928
+ "description": "Recipient signature"
1929
+ },
1930
+ "timestamp": {
1931
+ "type": "number",
1932
+ "description": "ARK confirmation time"
1933
+ }
1934
+ },
1935
+ "required": [
1936
+ "recipient",
1937
+ "recipientPublicKey",
1938
+ "signature",
1939
+ "timestamp"
1940
+ ],
1941
+ "additionalProperties": false
1942
+ },
1943
+ "createdAt": {
1762
1944
  "type": "number",
1763
- "description": "ARK confirmation time"
1945
+ "description": "Message creation time (client)"
1946
+ },
1947
+ "receivedAt": {
1948
+ "description": "Local reception time",
1949
+ "type": "number"
1950
+ },
1951
+ "zipMetadata": {
1952
+ "description": "ZIP file metadata",
1953
+ "type": "object",
1954
+ "properties": {
1955
+ "fileName": {
1956
+ "type": "string",
1957
+ "description": "ZIP filename"
1958
+ },
1959
+ "fileSize": {
1960
+ "type": "number",
1961
+ "description": "File size in bytes"
1962
+ },
1963
+ "fileHash": {
1964
+ "type": "string",
1965
+ "description": "File SHA256 hash"
1966
+ },
1967
+ "contentType": {
1968
+ "type": "string",
1969
+ "enum": [
1970
+ "text",
1971
+ "zip",
1972
+ "wts",
1973
+ "wip"
1974
+ ],
1975
+ "description": "Content type"
1976
+ },
1977
+ "localCachePath": {
1978
+ "description": "Local cache path",
1979
+ "type": "string"
1980
+ },
1981
+ "downloadedAt": {
1982
+ "description": "Download timestamp",
1983
+ "type": "number"
1984
+ }
1985
+ },
1986
+ "required": [
1987
+ "fileName",
1988
+ "fileSize",
1989
+ "fileHash",
1990
+ "contentType"
1991
+ ],
1992
+ "additionalProperties": false
1993
+ },
1994
+ "proof": {
1995
+ "description": "On-chain proof object address",
1996
+ "type": "string"
1997
+ },
1998
+ "decryptError": {
1999
+ "description": "Decryption failure reason",
2000
+ "type": "string"
2001
+ },
2002
+ "decryptAttempts": {
2003
+ "description": "Number of decryption attempts",
2004
+ "type": "number"
2005
+ },
2006
+ "lastDecryptAttemptAt": {
2007
+ "description": "Last decryption attempt timestamp",
2008
+ "type": "number"
2009
+ },
2010
+ "viewedAt": {
2011
+ "description": "Timestamp when the current user viewed this message (local storage). If present, indicates the message has been viewed by the user. Only applicable to received messages (direction === 'received')",
2012
+ "type": "number"
1764
2013
  }
1765
2014
  },
1766
2015
  "required": [
1767
- "recipient",
1768
- "recipientPublicKey",
1769
- "signature",
1770
- "timestamp"
2016
+ "messageId",
2017
+ "fromAddress",
2018
+ "toAddress",
2019
+ "plaintextHash",
2020
+ "direction",
2021
+ "status",
2022
+ "msgType",
2023
+ "createdAt"
1771
2024
  ],
1772
- "additionalProperties": false
1773
- },
1774
- "createdAt": {
1775
- "type": "number",
1776
- "description": "Message creation time (client)"
1777
- },
1778
- "receivedAt": {
1779
- "description": "Local reception time",
1780
- "type": "number"
2025
+ "additionalProperties": false,
2026
+ "description": "Message object"
1781
2027
  },
1782
- "zipMetadata": {
1783
- "description": "ZIP file metadata",
2028
+ "description": "Single-account mode: messages pulled from server"
2029
+ },
2030
+ {
2031
+ "type": "array",
2032
+ "items": {
1784
2033
  "type": "object",
1785
2034
  "properties": {
1786
- "fileName": {
2035
+ "account": {
1787
2036
  "type": "string",
1788
- "description": "ZIP filename"
2037
+ "description": "Account address"
1789
2038
  },
1790
- "fileSize": {
2039
+ "pulled": {
1791
2040
  "type": "number",
1792
- "description": "File size in bytes"
1793
- },
1794
- "fileHash": {
1795
- "type": "string",
1796
- "description": "File SHA256 hash"
2041
+ "description": "Number of messages pulled and decrypted in this round"
1797
2042
  },
1798
- "contentType": {
1799
- "type": "string",
1800
- "enum": [
1801
- "text",
1802
- "zip",
1803
- "wts",
1804
- "wip"
1805
- ],
1806
- "description": "Content type"
2043
+ "messages": {
2044
+ "type": "array",
2045
+ "items": {
2046
+ "type": "object",
2047
+ "properties": {
2048
+ "messageId": {
2049
+ "type": "string",
2050
+ "description": "Message ID"
2051
+ },
2052
+ "fromAddress": {
2053
+ "type": "string",
2054
+ "description": "Sender address"
2055
+ },
2056
+ "toAddress": {
2057
+ "type": "string",
2058
+ "description": "Recipient address"
2059
+ },
2060
+ "plaintextHash": {
2061
+ "type": "string",
2062
+ "description": "Plaintext hash"
2063
+ },
2064
+ "plaintext": {
2065
+ "description": "Decrypted plaintext text. UNDEFINED for attachment messages (zipMetadata present) — their base64 envelope is stripped at the read boundary; read msg.attachment for metadata and use save_attachment for bytes",
2066
+ "type": "string"
2067
+ },
2068
+ "attachment": {
2069
+ "description": "Present when this message is an attachment (zipMetadata present). Byte-free descriptor; payload never embedded",
2070
+ "type": "object",
2071
+ "properties": {
2072
+ "kind": {
2073
+ "type": "string",
2074
+ "enum": [
2075
+ "image",
2076
+ "video",
2077
+ "audio",
2078
+ "voice",
2079
+ "file",
2080
+ "wts",
2081
+ "wip"
2082
+ ],
2083
+ "description": "Attachment business type: image/video/audio are inline-renderable media; 'voice' is an explicit voice message (webm cannot be auto-distinguished from video); 'file' is a generic document; wts/wip are evidence files"
2084
+ },
2085
+ "fileName": {
2086
+ "type": "string",
2087
+ "description": "Original file name (transport .zip suffix stripped)"
2088
+ },
2089
+ "mimeType": {
2090
+ "type": "string",
2091
+ "description": "MIME type inferred from extension or sender-provided"
2092
+ },
2093
+ "size": {
2094
+ "type": "number",
2095
+ "description": "Payload size in bytes (uncompressed)"
2096
+ },
2097
+ "caption": {
2098
+ "description": "Sender-provided caption (E2EE, inside the encrypted envelope)",
2099
+ "type": "string"
2100
+ },
2101
+ "durationMs": {
2102
+ "description": "Audio/video duration in milliseconds",
2103
+ "type": "number"
2104
+ },
2105
+ "width": {
2106
+ "description": "Media width in pixels",
2107
+ "type": "number"
2108
+ },
2109
+ "height": {
2110
+ "description": "Media height in pixels",
2111
+ "type": "number"
2112
+ }
2113
+ },
2114
+ "required": [
2115
+ "kind",
2116
+ "fileName",
2117
+ "mimeType",
2118
+ "size"
2119
+ ],
2120
+ "additionalProperties": false
2121
+ },
2122
+ "replyTo": {
2123
+ "description": "Quoted (replied-to) message reference, if this message replies to a previous one",
2124
+ "type": "object",
2125
+ "properties": {
2126
+ "messageId": {
2127
+ "type": "string",
2128
+ "description": "Replied-to message ID (unique within the conversation)"
2129
+ }
2130
+ },
2131
+ "required": [
2132
+ "messageId"
2133
+ ],
2134
+ "additionalProperties": false
2135
+ },
2136
+ "guardAddress": {
2137
+ "description": "Guard address",
2138
+ "type": "string"
2139
+ },
2140
+ "passportAddress": {
2141
+ "description": "Passport address",
2142
+ "type": "string"
2143
+ },
2144
+ "lastReceivedLeafIndex": {
2145
+ "description": "Last received leaf index",
2146
+ "type": "number"
2147
+ },
2148
+ "direction": {
2149
+ "type": "string",
2150
+ "enum": [
2151
+ "sent",
2152
+ "received"
2153
+ ],
2154
+ "description": "Message direction"
2155
+ },
2156
+ "status": {
2157
+ "type": "string",
2158
+ "enum": [
2159
+ "pending",
2160
+ "confirmed",
2161
+ "read",
2162
+ "failed",
2163
+ "rejected",
2164
+ "decrypted",
2165
+ "decrypt_failed"
2166
+ ],
2167
+ "description": "Message status"
2168
+ },
2169
+ "msgType": {
2170
+ "anyOf": [
2171
+ {
2172
+ "type": "number",
2173
+ "const": 1
2174
+ },
2175
+ {
2176
+ "type": "number",
2177
+ "const": 3
2178
+ }
2179
+ ],
2180
+ "description": "Message type"
2181
+ },
2182
+ "leafIndex": {
2183
+ "description": "Leaf index",
2184
+ "type": "number"
2185
+ },
2186
+ "prevRoot": {
2187
+ "description": "Previous Merkle Root",
2188
+ "type": "string"
2189
+ },
2190
+ "newRoot": {
2191
+ "description": "Current Merkle Root",
2192
+ "type": "string"
2193
+ },
2194
+ "serverSignature": {
2195
+ "description": "Server signature",
2196
+ "type": "string"
2197
+ },
2198
+ "serverTimestamp": {
2199
+ "description": "Server confirmation timestamp",
2200
+ "type": "number"
2201
+ },
2202
+ "serverPublicKey": {
2203
+ "description": "Server public key",
2204
+ "type": "string"
2205
+ },
2206
+ "arkConfirmed": {
2207
+ "description": "ARK confirmation",
2208
+ "type": "object",
2209
+ "properties": {
2210
+ "recipient": {
2211
+ "type": "string",
2212
+ "description": "Recipient address"
2213
+ },
2214
+ "recipientPublicKey": {
2215
+ "type": "string",
2216
+ "description": "Recipient public key"
2217
+ },
2218
+ "signature": {
2219
+ "type": "string",
2220
+ "description": "Recipient signature"
2221
+ },
2222
+ "timestamp": {
2223
+ "type": "number",
2224
+ "description": "ARK confirmation time"
2225
+ }
2226
+ },
2227
+ "required": [
2228
+ "recipient",
2229
+ "recipientPublicKey",
2230
+ "signature",
2231
+ "timestamp"
2232
+ ],
2233
+ "additionalProperties": false
2234
+ },
2235
+ "createdAt": {
2236
+ "type": "number",
2237
+ "description": "Message creation time (client)"
2238
+ },
2239
+ "receivedAt": {
2240
+ "description": "Local reception time",
2241
+ "type": "number"
2242
+ },
2243
+ "zipMetadata": {
2244
+ "description": "ZIP file metadata",
2245
+ "type": "object",
2246
+ "properties": {
2247
+ "fileName": {
2248
+ "type": "string",
2249
+ "description": "ZIP filename"
2250
+ },
2251
+ "fileSize": {
2252
+ "type": "number",
2253
+ "description": "File size in bytes"
2254
+ },
2255
+ "fileHash": {
2256
+ "type": "string",
2257
+ "description": "File SHA256 hash"
2258
+ },
2259
+ "contentType": {
2260
+ "type": "string",
2261
+ "enum": [
2262
+ "text",
2263
+ "zip",
2264
+ "wts",
2265
+ "wip"
2266
+ ],
2267
+ "description": "Content type"
2268
+ },
2269
+ "localCachePath": {
2270
+ "description": "Local cache path",
2271
+ "type": "string"
2272
+ },
2273
+ "downloadedAt": {
2274
+ "description": "Download timestamp",
2275
+ "type": "number"
2276
+ }
2277
+ },
2278
+ "required": [
2279
+ "fileName",
2280
+ "fileSize",
2281
+ "fileHash",
2282
+ "contentType"
2283
+ ],
2284
+ "additionalProperties": false
2285
+ },
2286
+ "proof": {
2287
+ "description": "On-chain proof object address",
2288
+ "type": "string"
2289
+ },
2290
+ "decryptError": {
2291
+ "description": "Decryption failure reason",
2292
+ "type": "string"
2293
+ },
2294
+ "decryptAttempts": {
2295
+ "description": "Number of decryption attempts",
2296
+ "type": "number"
2297
+ },
2298
+ "lastDecryptAttemptAt": {
2299
+ "description": "Last decryption attempt timestamp",
2300
+ "type": "number"
2301
+ },
2302
+ "viewedAt": {
2303
+ "description": "Timestamp when the current user viewed this message (local storage). If present, indicates the message has been viewed by the user. Only applicable to received messages (direction === 'received')",
2304
+ "type": "number"
2305
+ }
2306
+ },
2307
+ "required": [
2308
+ "messageId",
2309
+ "fromAddress",
2310
+ "toAddress",
2311
+ "plaintextHash",
2312
+ "direction",
2313
+ "status",
2314
+ "msgType",
2315
+ "createdAt"
2316
+ ],
2317
+ "additionalProperties": false,
2318
+ "description": "Message object"
2319
+ },
2320
+ "description": "Newly pulled messages (read boundary applied: attachment payloads stripped into descriptors)"
1807
2321
  },
1808
- "localCachePath": {
1809
- "description": "Local cache path",
2322
+ "error": {
2323
+ "description": "Per-account pull error; absent on success. Other accounts are unaffected",
1810
2324
  "type": "string"
1811
- },
1812
- "downloadedAt": {
1813
- "description": "Download timestamp",
1814
- "type": "number"
1815
2325
  }
1816
2326
  },
1817
2327
  "required": [
1818
- "fileName",
1819
- "fileSize",
1820
- "fileHash",
1821
- "contentType"
2328
+ "account",
2329
+ "pulled",
2330
+ "messages"
1822
2331
  ],
1823
- "additionalProperties": false
1824
- },
1825
- "proof": {
1826
- "description": "On-chain proof object address",
1827
- "type": "string"
1828
- },
1829
- "decryptError": {
1830
- "description": "Decryption failure reason",
1831
- "type": "string"
1832
- },
1833
- "decryptAttempts": {
1834
- "description": "Number of decryption attempts",
1835
- "type": "number"
1836
- },
1837
- "lastDecryptAttemptAt": {
1838
- "description": "Last decryption attempt timestamp",
1839
- "type": "number"
2332
+ "additionalProperties": false,
2333
+ "description": "Per-account fan-out pull result"
1840
2334
  },
1841
- "viewedAt": {
1842
- "description": "Timestamp when the current user viewed this message (local storage). If present, indicates the message has been viewed by the user. Only applicable to received messages (direction === 'received')",
1843
- "type": "number"
1844
- }
1845
- },
1846
- "required": [
1847
- "messageId",
1848
- "fromAddress",
1849
- "toAddress",
1850
- "plaintextHash",
1851
- "direction",
1852
- "status",
1853
- "msgType",
1854
- "createdAt"
1855
- ],
1856
- "additionalProperties": false,
1857
- "description": "Message object"
1858
- },
1859
- "description": "List of messages pulled from server"
2335
+ "description": "Fan-out mode (allAccounts/accounts set): one entry per account with isolated errors"
2336
+ }
2337
+ ]
1860
2338
  }
1861
2339
  },
1862
2340
  "required": [