@wowok/agent-mcp 2.2.11 → 2.2.13

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 (93) hide show
  1. package/dist/docs/index.d.ts +3 -0
  2. package/dist/docs/index.js +2 -0
  3. package/dist/docs/loader.d.ts +12 -0
  4. package/dist/docs/loader.js +177 -0
  5. package/dist/docs/search.d.ts +17 -0
  6. package/dist/docs/search.js +325 -0
  7. package/dist/docs/types.d.ts +55 -0
  8. package/dist/docs/types.js +1 -0
  9. package/dist/index.d.ts +12 -0
  10. package/dist/index.js +146 -39
  11. package/docs/README.md +249 -0
  12. package/docs/WIP.md +388 -0
  13. package/docs/WTS.md +536 -0
  14. package/docs/docs/account.md +914 -0
  15. package/docs/docs/allocation.md +635 -0
  16. package/docs/docs/arbitration.md +1804 -0
  17. package/docs/docs/arbitration_state_machine.md +270 -0
  18. package/docs/docs/contact.md +709 -0
  19. package/docs/docs/demand.md +948 -0
  20. package/docs/docs/guard.md +1465 -0
  21. package/docs/docs/localinfo.md +432 -0
  22. package/docs/docs/localmark.md +583 -0
  23. package/docs/docs/machine.md +2490 -0
  24. package/docs/docs/messenger.md +2098 -0
  25. package/docs/docs/onchain_events.md +267 -0
  26. package/docs/docs/order.md +1001 -0
  27. package/docs/docs/payment.md +512 -0
  28. package/docs/docs/permission.md +1438 -0
  29. package/docs/docs/personal.md +742 -0
  30. package/docs/docs/progress.md +1748 -0
  31. package/docs/docs/query.md +467 -0
  32. package/docs/docs/repository.md +1043 -0
  33. package/docs/docs/reward.md +833 -0
  34. package/docs/docs/service.md +2130 -0
  35. package/docs/docs/stage-01-introduction.md +243 -0
  36. package/docs/docs/stage-02-trust.md +302 -0
  37. package/docs/docs/stage-03-collaboration.md +337 -0
  38. package/docs/docs/stage-04-transaction.md +277 -0
  39. package/docs/docs/stage-05-business.md +151 -0
  40. package/docs/docs/stage-06-personal.md +203 -0
  41. package/docs/docs/stage-07-query.md +572 -0
  42. package/docs/docs/stage-08-examples.md +184 -0
  43. package/docs/docs/treasury.md +1149 -0
  44. package/docs/docs/wowok_buildin_info.md +740 -0
  45. package/docs/examples/Insurance/Insurance.md +594 -0
  46. package/docs/examples/Insurance/Insurance_TestResults.md +481 -0
  47. package/docs/examples/Insurance/insurance_complete_guard_v1.json +50 -0
  48. package/docs/examples/MyShop/MyShop.md +1353 -0
  49. package/docs/examples/MyShop/MyShop_TestResults.md +1003 -0
  50. package/docs/examples/MyShop_Advanced/MyShop_Advanced.md +1898 -0
  51. package/docs/examples/MyShop_Advanced/MyShop_Advanced_MerchantSystem_TestResults.md +1297 -0
  52. package/docs/examples/MyShop_Advanced/MyShop_Advanced_OrderFlow_TestResults.md +743 -0
  53. package/docs/examples/MyShop_Advanced/machine_nodes.json +222 -0
  54. package/docs/examples/ThreeBody_Signature/ThreeBody_Signature.md +776 -0
  55. package/docs/examples/ThreeBody_Signature/ThreeBody_Signature_TestResults.md +599 -0
  56. package/docs/examples/Travel/Travel.md +1157 -0
  57. package/docs/examples/Travel/Travel_TestResults.md +743 -0
  58. package/docs/examples/Travel/calc-weather-timestamps.js +8 -0
  59. package/docs/examples/Travel/travel_machine_v2_export.json +104 -0
  60. package/docs/examples/Travel/weather_check_guard_v1.json +51 -0
  61. package/docs/skills/WOWOK.md +650 -0
  62. package/docs/skills/onchain_operations/_common.md +406 -0
  63. package/docs/skills/onchain_operations/_index.md +196 -0
  64. package/docs/skills/onchain_operations/allocation.md +28 -0
  65. package/docs/skills/onchain_operations/arbitration.md +106 -0
  66. package/docs/skills/onchain_operations/contact.md +40 -0
  67. package/docs/skills/onchain_operations/demand.md +53 -0
  68. package/docs/skills/onchain_operations/gen_passport.md +23 -0
  69. package/docs/skills/onchain_operations/guard.md +56 -0
  70. package/docs/skills/onchain_operations/machine.md +89 -0
  71. package/docs/skills/onchain_operations/order.md +56 -0
  72. package/docs/skills/onchain_operations/payment.md +24 -0
  73. package/docs/skills/onchain_operations/permission.md +68 -0
  74. package/docs/skills/onchain_operations/personal.md +58 -0
  75. package/docs/skills/onchain_operations/progress.md +38 -0
  76. package/docs/skills/onchain_operations/repository.md +70 -0
  77. package/docs/skills/onchain_operations/reward.md +38 -0
  78. package/docs/skills/onchain_operations/service.md +78 -0
  79. package/docs/skills/onchain_operations/treasury.md +68 -0
  80. package/docs/skills/schema-account_operation.md +402 -0
  81. package/docs/skills/schema-guard2file.md +153 -0
  82. package/docs/skills/schema-local_info_operation.md +160 -0
  83. package/docs/skills/schema-local_mark_operation.md +148 -0
  84. package/docs/skills/schema-machineNode2file.md +155 -0
  85. package/docs/skills/schema-messenger_operation.md +547 -0
  86. package/docs/skills/schema-onchain_events.md +201 -0
  87. package/docs/skills/schema-onchain_table_data.md +334 -0
  88. package/docs/skills/schema-query_toolkit.md +395 -0
  89. package/docs/skills/schema-wip_file.md +240 -0
  90. package/docs/skills/schema-wowok_buildin_info.md +296 -0
  91. package/docs/wip-examples/three_body.html +57 -0
  92. package/docs/wip-examples/three_body.wip +30 -0
  93. package/package.json +3 -2
@@ -0,0 +1,512 @@
1
+
2
+ # Payment Component (💰 Direct Transfer)
3
+
4
+ ---
5
+
6
+ ## Component Overview
7
+
8
+ The Payment component is used to send instant, irreversible token transfers to any wallet address. Payment is an immutable object that can only be created, not modified.
9
+
10
+ ---
11
+
12
+ ## Function List
13
+
14
+ | Function Name | Purpose | Usage Scenario | Significance |
15
+ |---------------|---------|----------------|-------------|
16
+ | **Create Single Recipient Payment** | Send tokens to one recipient | Personal payments, simple transfers | Direct, secure one-to-one token transfers |
17
+ | **Create Multi-Recipient Payment** | Send tokens to multiple recipients in one transaction | Team bonuses, payroll, bulk transfers | Efficiently distribute tokens to multiple addresses simultaneously |
18
+ | **Named Payment** | Create a named Payment object for tracking | Recorded transactions, audit trails | Creates identifiable payment objects on-chain |
19
+ | **Payment with Info** | Add payment metadata (remark, index, for_object, for_guard) | Service payments, order payments, Guard-verified payments | Provides context and verification for payments |
20
+
21
+ ---
22
+
23
+ ## Complete Tool Call Structure
24
+
25
+ Payment operations use the following top-level structure:
26
+
27
+ ```json
28
+ {
29
+ "operation_type": "payment",
30
+ "data": { ... }, // Payment data definition
31
+ "env": { ... } // Execution environment (optional)
32
+ }
33
+ ```
34
+
35
+ ---
36
+
37
+ ## Schema Tree
38
+
39
+ ```
40
+ payment (Payment Object)
41
+ ├── operation_type: "payment" (fixed value)
42
+ ├── data (Payment data definition)
43
+ │ ├── object (object definition, required)
44
+ │ │ ├── name|tags|type_parameter (create new object)
45
+ │ │ └── type_parameter (token type, e.g., 0x2::wow::WOW)
46
+ │ ├── revenue (recipient and amount array, required)
47
+ │ │ └── [] (each item has recipient + amount)
48
+ │ └── info (payment information, required)
49
+ │ ├── remark (payment remark)
50
+ │ ├── index (payment index)
51
+ │ ├── for_object (optional, related object)
52
+ │ └── for_guard (optional, Guard verification)
53
+ └── env (optional, execution environment)
54
+ ├── account (string, optional) - account name or address, empty string for default
55
+ ├── network (string, optional) - "testnet" or "localnet"
56
+ ├── permission_guard (array, optional) - list of permission guard IDs
57
+ ├── no_cache (boolean, optional) - disable caching
58
+ └── referrer (string, optional) - referrer ID
59
+ ```
60
+
61
+ ---
62
+
63
+ ## Sub-feature 1: Create Single Recipient Payment
64
+
65
+ ### Feature Description
66
+
67
+ Create a Payment object to send tokens to a single recipient. Payment is an immutable object and cannot be modified after creation.
68
+
69
+ ### Parameter Description
70
+
71
+ | Parameter Path | Type | Required | Description | Constraints |
72
+ |----------|------|------|------|------|
73
+ | `operation_type` | string | Yes | Operation type | Fixed value "payment" |
74
+ | `data.object` | object | Yes | Object configuration | Must include type_parameter |
75
+ | `data.object.type_parameter` | string | Yes | Token type | e.g., "0x2::wow::WOW" |
76
+ | `data.object.name` | string | No | Payment name | Max 64 bcs characters |
77
+ | `data.revenue` | array | Yes | Recipient and amount array | At least one recipient, max 200 |
78
+ | `data.revenue[].recipient` | object | Yes | Recipient | AccountOrMark_Address with name_or_address |
79
+ | `data.revenue[].amount` | object | Yes | Amount | CoinParam with balance field |
80
+ | `data.revenue[].amount.balance` | string/number | Yes | Amount value | Minimum unit, no decimals or negatives |
81
+ | `data.info` | object | Yes | Payment information | Must include remark and index |
82
+ | `data.info.remark` | string | Yes | Payment remark | Description of the payment |
83
+ | `data.info.index` | number/string | Yes | Payment index | Numeric identifier for this payment |
84
+
85
+ ### Important Notes
86
+
87
+ ⚠️ **Payment is an immutable object!** Can only be created, not modified.
88
+
89
+ ⚠️ **Transfer is irreversible!** Please confirm recipient address is correct.
90
+
91
+ ⚠️ **Ensure sufficient balance!**
92
+
93
+ ⚠️ **Maximum 200 recipients per payment!**
94
+
95
+ ---
96
+
97
+ ### Examples
98
+
99
+ #### Example 1.1: Minimal Single Recipient Payment
100
+
101
+ **Prompt**: Create a Payment to send 5000000000 minimum unit WOW tokens to "alice", add remark "Thanks for the help!", set index 1.
102
+
103
+ ```json
104
+ {
105
+ "operation_type": "payment",
106
+ "data": {
107
+ "object": {
108
+ "type_parameter": "0x2::wow::WOW"
109
+ },
110
+ "revenue": [
111
+ {
112
+ "recipient": { "name_or_address": "alice" },
113
+ "amount": { "balance": "5000000000" }
114
+ }
115
+ ],
116
+ "info": {
117
+ "remark": "Thanks for the help!",
118
+ "index": 1
119
+ }
120
+ }
121
+ }
122
+
123
+ **Execution Result**:
124
+ ```json
125
+ {
126
+ "status": "success",
127
+ "object": "0xc8e8...1bb4",
128
+ "type": "Payment",
129
+ "version": "30128",
130
+ "change": "created",
131
+ "objects": [
132
+ {
133
+ "type": "WReceivedObject",
134
+ "object": "0x1a88...9649",
135
+ "change": "created"
136
+ },
137
+ {
138
+ "type": "Payment",
139
+ "object": "0xc8e8...1bb4",
140
+ "change": "created"
141
+ }
142
+ ]
143
+ }
144
+ ```
145
+
146
+ ---
147
+
148
+ #### Example 1.2: Named Single Recipient Payment
149
+
150
+ **Prompt**: Create a Payment named "payment_to_alice" to send to "alice", add tags "personal", "payment", use WOW token, remark "Birthday gift", index 2.
151
+
152
+ ```json
153
+ {
154
+ "operation_type": "payment",
155
+ "data": {
156
+ "object": {
157
+ "name": "payment_to_alice",
158
+ "tags": ["personal", "payment"],
159
+ "type_parameter": "0x2::wow::WOW"
160
+ },
161
+ "revenue": [
162
+ {
163
+ "recipient": { "name_or_address": "alice" },
164
+ "amount": { "balance": "10000000000" }
165
+ }
166
+ ],
167
+ "info": {
168
+ "remark": "Birthday gift",
169
+ "index": 2
170
+ }
171
+ }
172
+ }
173
+
174
+ **Execution Result**:
175
+ ```json
176
+ {
177
+ "status": "success",
178
+ "object": "0x...",
179
+ "type": "Payment",
180
+ "version": "...",
181
+ "change": "created"
182
+ }
183
+ ```
184
+
185
+ ---
186
+
187
+ ## Sub-feature 2: Create Multi-Recipient Payment
188
+
189
+ ### Feature Description
190
+
191
+ Create a Payment object to send tokens to multiple recipients in a single transaction. This is efficient for bulk transfers.
192
+
193
+ ---
194
+
195
+ ### Examples
196
+
197
+ #### Example 2.1: Two Recipients Payment
198
+
199
+ **Prompt**: Create a Payment to send to "alice" and "bob" simultaneously: "alice" gets 3000000000, "bob" gets 2000000000, add remark "Team bonus", index 10.
200
+
201
+ ```json
202
+ {
203
+ "operation_type": "payment",
204
+ "data": {
205
+ "object": {
206
+ "type_parameter": "0x2::wow::WOW"
207
+ },
208
+ "revenue": [
209
+ {
210
+ "recipient": { "name_or_address": "alice" },
211
+ "amount": { "balance": "3000000000" }
212
+ },
213
+ {
214
+ "recipient": { "name_or_address": "bob" },
215
+ "amount": { "balance": "2000000000" }
216
+ }
217
+ ],
218
+ "info": {
219
+ "remark": "Team bonus",
220
+ "index": 10
221
+ }
222
+ }
223
+ }
224
+
225
+ **Execution Result**:
226
+ ```json
227
+ {
228
+ "status": "success"
229
+ }
230
+ ```
231
+
232
+ ---
233
+
234
+ #### Example 2.2: Named Multi-Recipient Payment
235
+
236
+ **Prompt**: Create a Payment named "q1_bonus_payment" with tags "payroll", "q1-2025", send to three team members: "charlie" gets 5000000000, "dave" gets 4000000000, "eve" gets 3500000000, remark "Q1 2025 performance bonus", index 15.
237
+
238
+ ```json
239
+ {
240
+ "operation_type": "payment",
241
+ "data": {
242
+ "object": {
243
+ "name": "q1_bonus_payment",
244
+ "tags": ["payroll", "q1-2025"],
245
+ "type_parameter": "0x2::wow::WOW"
246
+ },
247
+ "revenue": [
248
+ {
249
+ "recipient": { "name_or_address": "charlie" },
250
+ "amount": { "balance": "5000000000" }
251
+ },
252
+ {
253
+ "recipient": { "name_or_address": "dave" },
254
+ "amount": { "balance": "4000000000" }
255
+ },
256
+ {
257
+ "recipient": { "name_or_address": "eve" },
258
+ "amount": { "balance": "3500000000" }
259
+ }
260
+ ],
261
+ "info": {
262
+ "remark": "Q1 2025 performance bonus",
263
+ "index": 15
264
+ }
265
+ }
266
+ }
267
+
268
+ **Execution Result**:
269
+ ```json
270
+ {
271
+ "status": "success"
272
+ }
273
+ ```
274
+
275
+ ---
276
+
277
+ ## Sub-feature 3: Payment with Additional Info
278
+
279
+ ### Feature Description
280
+
281
+ Create a Payment with additional metadata, such as linking to a specific object or Guard for verification purposes.
282
+
283
+ ---
284
+
285
+ ### Examples
286
+
287
+ #### Example 3.1: Payment Linked to Object
288
+
289
+ **Prompt**: Create a Payment linked to "my_service_order", send 8000000000 to "service_provider", remark "Service order payment", index 100, set for_object to "my_service_order".
290
+
291
+ ```json
292
+ {
293
+ "operation_type": "payment",
294
+ "data": {
295
+ "object": {
296
+ "type_parameter": "0x2::wow::WOW"
297
+ },
298
+ "revenue": [
299
+ {
300
+ "recipient": { "name_or_address": "service_provider" },
301
+ "amount": { "balance": "8000000000" }
302
+ }
303
+ ],
304
+ "info": {
305
+ "remark": "Service order payment",
306
+ "index": 100,
307
+ "for_object": "my_service_order"
308
+ }
309
+ }
310
+ }
311
+
312
+ **Execution Result**:
313
+ ```json
314
+ {
315
+ "status": "success"
316
+ }
317
+ ```
318
+
319
+ **Note**: The `for_object` parameter accepts any WoWok protocol object (such as Permission, Repository, Service, Demand, Order, etc.). The referenced object must be a WoWok object type (type must start with the WoWok package address).
320
+
321
+ **To use this feature**:
322
+ 1. Create a WoWok object (e.g., Permission, Repository, Service, Demand) first
323
+ 2. Use that object's ID/name as `for_object`
324
+ 3. The Payment will be linked to that object for tracking purposes
325
+
326
+ ---
327
+
328
+ #### Example 3.2: Payment with Guard Verification
329
+
330
+ **Prompt**: Create a Payment that requires Guard verification: send 25000000000 to "merchant", remark "Purchase payment", index 200, set for_guard to "purchase_guard".
331
+
332
+ ```json
333
+ {
334
+ "operation_type": "payment",
335
+ "data": {
336
+ "object": {
337
+ "name": "purchase_payment",
338
+ "type_parameter": "0x2::wow::WOW"
339
+ },
340
+ "revenue": [
341
+ {
342
+ "recipient": { "name_or_address": "merchant" },
343
+ "amount": { "balance": "25000000000" }
344
+ }
345
+ ],
346
+ "info": {
347
+ "remark": "Purchase payment",
348
+ "index": 200,
349
+ "for_guard": "purchase_guard"
350
+ }
351
+ }
352
+ }
353
+
354
+ **Execution Result**:
355
+ ```json
356
+ {
357
+ "status": "success"
358
+ }
359
+ ```
360
+
361
+ ---
362
+
363
+ #### Example 3.3: Full Payment with Object and Guard
364
+
365
+ **Prompt**: Create a complete Payment with all fields: named "order_500_payment", tags "service", "order-500", send 15000000000 to "vendor_alice", link to "service_order_500", use "service_guard" for verification, remark "Payment for service order #500", index 500, use WOW token.
366
+
367
+ ```json
368
+ {
369
+ "operation_type": "payment",
370
+ "data": {
371
+ "object": {
372
+ "name": "order_500_payment",
373
+ "tags": ["service", "order-500"],
374
+ "type_parameter": "0x2::wow::WOW"
375
+ },
376
+ "revenue": [
377
+ {
378
+ "recipient": { "name_or_address": "vendor_alice" },
379
+ "amount": { "balance": "15000000000" }
380
+ }
381
+ ],
382
+ "info": {
383
+ "remark": "Payment for service order #500",
384
+ "index": 500,
385
+ "for_object": "service_order_500",
386
+ "for_guard": "service_guard"
387
+ }
388
+ }
389
+ }
390
+
391
+ **Execution Result**:
392
+ ```json
393
+ {
394
+ "status": "success"
395
+ }
396
+ ```
397
+
398
+ ---
399
+
400
+ ## Sub-feature 4: Payment with Environment Configuration
401
+
402
+ ### Feature Description
403
+
404
+ Create a Payment with custom environment settings, such as specifying network or account.
405
+
406
+ ---
407
+
408
+ ### Examples
409
+
410
+ #### Example 4.1: Payment on Testnet
411
+
412
+ **Prompt**: On testnet network, create a Payment to send to "test_recipient", 1000000000 WOW, remark "Test payment", index 1, use default account.
413
+
414
+ ```json
415
+ {
416
+ "operation_type": "payment",
417
+ "data": {
418
+ "object": {
419
+ "type_parameter": "0x2::wow::WOW"
420
+ },
421
+ "revenue": [
422
+ {
423
+ "recipient": { "name_or_address": "test_recipient" },
424
+ "amount": { "balance": "1000000000" }
425
+ }
426
+ ],
427
+ "info": {
428
+ "remark": "Test payment",
429
+ "index": 1
430
+ }
431
+ },
432
+ "env": {
433
+ "network": "testnet"
434
+ }
435
+ }
436
+
437
+ **Execution Result**:
438
+ ```json
439
+ {
440
+ "status": "success"
441
+ }
442
+ ```
443
+
444
+ ---
445
+
446
+ #### Example 4.2: Payment with Specific Account
447
+
448
+ **Prompt**: Use account "payment_manager" to create a Payment to send 6000000000 to "recipient_bob", remark "Project milestone payment", index 88.
449
+
450
+ ```json
451
+ {
452
+ "operation_type": "payment",
453
+ "data": {
454
+ "object": {
455
+ "type_parameter": "0x2::wow::WOW"
456
+ },
457
+ "revenue": [
458
+ {
459
+ "recipient": { "name_or_address": "recipient_bob" },
460
+ "amount": { "balance": "6000000000" }
461
+ }
462
+ ],
463
+ "info": {
464
+ "remark": "Project milestone payment",
465
+ "index": 88
466
+ }
467
+ },
468
+ "env": {
469
+ "account": "payment_manager"
470
+ }
471
+ }
472
+
473
+ **Execution Result**:
474
+ ```json
475
+ {
476
+ "status": "success"
477
+ }
478
+ ```
479
+
480
+ ---
481
+
482
+ ## Important Notes
483
+
484
+ ⚠️ **Payment is an immutable object!** Can only be created, not modified.
485
+
486
+ ⚠️ **Transfer is irreversible!** Please confirm recipient address is correct.
487
+
488
+ ⚠️ **Ensure sufficient balance!**
489
+
490
+ ⚠️ **Maximum 200 recipients per payment!**
491
+
492
+ ⚠️ **type_parameter is required!** Specify token type inside object.
493
+
494
+ ⚠️ **All amount values must be positive integers!** No decimals or negative values.
495
+
496
+ ⚠️ **info.remark and info.index are required!** Must provide both for every payment.
497
+
498
+ ⚠️ **Use names instead of addresses in prompts for better readability.**
499
+
500
+ ---
501
+
502
+ ## Related Components
503
+
504
+ | Component | Description |
505
+ |-----------|-------------|
506
+ | **[Treasury](treasury.md)** | Team fund management |
507
+ | **[Reward](reward.md)** | Marketing incentives |
508
+ | **[Allocation](allocation.md)** | Automatic fund distribution |
509
+ | **[Service](service.md)** | WYSIWYG product trading |
510
+ | **[Order](order.md)** | Order management |
511
+ | **[Guard](guard.md)** | Trust verification engine |
512
+