@wowok/agent-mcp 2.2.14 → 2.2.16
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.
- package/README.md +19 -11
- package/dist/index.d.ts +4 -4
- package/dist/index.js +9 -6
- package/dist/schema/common/index.d.ts +0 -39
- package/dist/schema/common/index.js +0 -6
- package/dist/schema/messenger/index.d.ts +6 -6
- package/dist/schema/query/index.js +1 -1
- package/dist/schemas/index.json +1 -1
- package/package.json +7 -2
- package/dist/schemas/operations/guard.json +0 -163
- package/dist/schemas/operations/permission.json +0 -22
package/README.md
CHANGED
|
@@ -39,18 +39,26 @@ Skills provide structured guidance for AI assistants:
|
|
|
39
39
|
- **Tool usage failures** — Correct parameter formats, tool selection, error recovery
|
|
40
40
|
- **Safety & authorization** — User confirmation for important operations
|
|
41
41
|
|
|
42
|
-
#### Available Skills
|
|
43
|
-
|
|
44
|
-
| Skill | Purpose |
|
|
45
|
-
|
|
46
|
-
| `wowok-
|
|
47
|
-
| `wowok-
|
|
48
|
-
| `wowok-
|
|
49
|
-
| `wowok-
|
|
50
|
-
| `wowok-
|
|
51
|
-
| `wowok-
|
|
42
|
+
#### Available Skills (Organized by Role)
|
|
43
|
+
|
|
44
|
+
| Skill | Role | Purpose |
|
|
45
|
+
|-------|------|---------|
|
|
46
|
+
| `wowok-order` | 👤 Customer | Order lifecycle — place orders, track progress, submit disputes, claim compensation |
|
|
47
|
+
| `wowok-provider` | 🏪 Provider | Service provider guide — create Service, design Machine, configure Allocators |
|
|
48
|
+
| `wowok-machine` | 🏪 Provider | Workflow design — state machines, node definitions, progress tracking |
|
|
49
|
+
| `wowok-arbitrator` | ⚖️ Arbitrator | Arbitration service — dispute resolution, voting organization, fee management |
|
|
50
|
+
| `wowok-guard` | 🛠️ Shared | Guard design mastery — programmable trust rules, multi-signature authorization |
|
|
51
|
+
| `wowok-tools` | 🛠️ Shared | MCP tool usage mastery — 13+ tools, parameter formats, schema references |
|
|
52
|
+
| `wowok-safety` | 🛠️ Shared | Safety protocol — dry-run validation, user confirmation checkpoints |
|
|
53
|
+
|
|
54
|
+
#### Role-Based Skill Selection
|
|
55
|
+
|
|
56
|
+
- **Use `wowok-order`** when user acts as a customer/buyer placing orders
|
|
57
|
+
- **Use `wowok-provider`** + `wowok-machine` when user is a merchant/service provider
|
|
58
|
+
- **Use `wowok-arbitrator`** when user operates dispute resolution services
|
|
59
|
+
- **Use `wowok-tools`** + `wowok-safety`** (always loaded) for all roles
|
|
60
|
+
- **Use `wowok-guard`** when designing complex validation rules
|
|
52
61
|
|
|
53
62
|
#### Using Skills
|
|
54
63
|
|
|
55
64
|
Once installed, Claude Code will automatically use these skills when working with WoWok tools.
|
|
56
|
-
|
package/dist/index.d.ts
CHANGED
|
@@ -15693,7 +15693,7 @@ declare const WatchQueryOperationsSchema: z.ZodEffects<z.ZodUnion<[z.ZodDiscrimi
|
|
|
15693
15693
|
name_or_address?: string | undefined;
|
|
15694
15694
|
local_mark_first?: boolean | undefined;
|
|
15695
15695
|
}>]>;
|
|
15696
|
-
|
|
15696
|
+
type: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodLiteral<"CoinWrapper">, z.ZodNull]>>;
|
|
15697
15697
|
cursor: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNull]>>;
|
|
15698
15698
|
limit: z.ZodOptional<z.ZodUnion<[z.ZodNumber, z.ZodNull]>>;
|
|
15699
15699
|
no_cache: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -15704,9 +15704,9 @@ declare const WatchQueryOperationsSchema: z.ZodEffects<z.ZodUnion<[z.ZodDiscrimi
|
|
|
15704
15704
|
local_mark_first?: boolean | undefined;
|
|
15705
15705
|
};
|
|
15706
15706
|
query_type: "onchain_received";
|
|
15707
|
+
type?: string | null | undefined;
|
|
15707
15708
|
no_cache?: boolean | undefined;
|
|
15708
15709
|
network?: import("@wowok/wowok").ENTRYPOINT | undefined;
|
|
15709
|
-
all_type?: boolean | undefined;
|
|
15710
15710
|
cursor?: string | null | undefined;
|
|
15711
15711
|
limit?: number | null | undefined;
|
|
15712
15712
|
}, {
|
|
@@ -15715,9 +15715,9 @@ declare const WatchQueryOperationsSchema: z.ZodEffects<z.ZodUnion<[z.ZodDiscrimi
|
|
|
15715
15715
|
local_mark_first?: boolean | undefined;
|
|
15716
15716
|
};
|
|
15717
15717
|
query_type: "onchain_received";
|
|
15718
|
+
type?: string | null | undefined;
|
|
15718
15719
|
no_cache?: boolean | undefined;
|
|
15719
15720
|
network?: import("@wowok/wowok").ENTRYPOINT | undefined;
|
|
15720
|
-
all_type?: boolean | undefined;
|
|
15721
15721
|
cursor?: string | null | undefined;
|
|
15722
15722
|
limit?: number | null | undefined;
|
|
15723
15723
|
}>]>]>, {
|
|
@@ -15803,9 +15803,9 @@ declare const WatchQueryOperationsSchema: z.ZodEffects<z.ZodUnion<[z.ZodDiscrimi
|
|
|
15803
15803
|
local_mark_first?: boolean | undefined;
|
|
15804
15804
|
};
|
|
15805
15805
|
query_type: "onchain_received";
|
|
15806
|
+
type?: string | null | undefined;
|
|
15806
15807
|
no_cache?: boolean | undefined;
|
|
15807
15808
|
network?: import("@wowok/wowok").ENTRYPOINT | undefined;
|
|
15808
|
-
all_type?: boolean | undefined;
|
|
15809
15809
|
cursor?: string | null | undefined;
|
|
15810
15810
|
limit?: number | null | undefined;
|
|
15811
15811
|
}, unknown>;
|
package/dist/index.js
CHANGED
|
@@ -89,7 +89,7 @@ Token amounts are HIGHLY SENSITIVE. Always:
|
|
|
89
89
|
| Send encrypted file via messenger | messenger_operation (send_file) | wip_file |
|
|
90
90
|
| Generate witness timestamp (WTS) | messenger_operation (generate_wts) | wip_file |
|
|
91
91
|
| Query protocol constants | wowok_buildin_info | query_toolkit |
|
|
92
|
-
|
|
|
92
|
+
| Query tool schemas | schema_query | wowok_buildin_info |
|
|
93
93
|
|
|
94
94
|
## Local vs On-chain Operations
|
|
95
95
|
|
|
@@ -107,7 +107,7 @@ Token amounts are HIGHLY SENSITIVE. Always:
|
|
|
107
107
|
- query_toolkit
|
|
108
108
|
- onchain_events
|
|
109
109
|
- wowok_buildin_info
|
|
110
|
-
-
|
|
110
|
+
- schema_query
|
|
111
111
|
- guard2file
|
|
112
112
|
- machineNode2file
|
|
113
113
|
`;
|
|
@@ -598,12 +598,15 @@ const WatchQueryOperationsSchema = z.preprocess((input) => {
|
|
|
598
598
|
z.object({
|
|
599
599
|
query_type: z.literal("onchain_received"),
|
|
600
600
|
name_or_address: AccountOrMark_AddressAISchema.describe("Name or address of the object that received payments/items - can be a string (name/address) or full object"),
|
|
601
|
-
|
|
601
|
+
type: z.union([z.string(), z.literal("CoinWrapper"), z.null()]).optional().describe("Type filter for querying received objects. " +
|
|
602
|
+
"- If undefined or null: query all types (equivalent to the old all_type=true). " +
|
|
603
|
+
"- If 'CoinWrapper': query CoinWrapper type for the object's token (equivalent to the old all_type=false). " +
|
|
604
|
+
"- If string: query specific StructType (e.g., '0x2::payment::CoinWrapper<0x2::wow::WOW>')."),
|
|
602
605
|
cursor: z.union([z.string(), z.null()]).optional().describe("Pagination cursor from previous page"),
|
|
603
606
|
limit: z.union([z.number(), z.null()]).optional().describe("Max records per page"),
|
|
604
607
|
no_cache: z.boolean().optional().describe("Set to true to bypass cache and fetch fresh on-chain data"),
|
|
605
608
|
network: EntrypointSchema.optional(),
|
|
606
|
-
}).describe("Query objects (Payments, Tokens, NFTs) received by a specific object. Use to track incoming payments or items sent to an on-chain object. Supports pagination and
|
|
609
|
+
}).describe("Query objects (Payments, Tokens, NFTs) received by a specific object. Use to track incoming payments or items sent to an on-chain object. Supports pagination and type filter. Returns: ReceivedBalance | ReceivedNormal[]"),
|
|
607
610
|
]),
|
|
608
611
|
]));
|
|
609
612
|
async function handleOnchainOperations(args) {
|
|
@@ -1040,7 +1043,7 @@ async function handleWatchQueryOperations(args) {
|
|
|
1040
1043
|
case "onchain_received": {
|
|
1041
1044
|
const queryResult = await query_received({
|
|
1042
1045
|
name_or_address: normalizeAccountOrMark(validated.name_or_address),
|
|
1043
|
-
|
|
1046
|
+
type: validated.type,
|
|
1044
1047
|
cursor: validated.cursor,
|
|
1045
1048
|
limit: validated.limit,
|
|
1046
1049
|
no_cache: validated.no_cache,
|
|
@@ -1394,7 +1397,7 @@ async function main() {
|
|
|
1394
1397
|
+ "ONCHAIN (blockchain):\n"
|
|
1395
1398
|
+ "7. onchain_personal_profile — Query any user's PUBLIC on-chain profile: social links, reputation (likes/dislikes), personal info records, voting history, referrer.\n"
|
|
1396
1399
|
+ "8. onchain_objects — Batch query on-chain WOWOK objects by ID or name: supports Service, Machine, Order, Treasury, Reward, Arb, Personal, Contact, and more.\n"
|
|
1397
|
-
+ "9. onchain_received — Query objects (Payments, Tokens, NFTs) received by a specific object. Supports pagination and
|
|
1400
|
+
+ "9. onchain_received — Query objects (Payments, Tokens, NFTs) received by a specific object. Supports pagination and type filter.\n\n"
|
|
1398
1401
|
+ "For dynamic table data queries (pagination, table items), use the 'onchain_table_data' tool.",
|
|
1399
1402
|
inputSchema: WatchQueryOperationsSchema,
|
|
1400
1403
|
outputSchema: z.object({
|
|
@@ -568,44 +568,6 @@ export declare const QueryEnvSchema: z.ZodObject<{
|
|
|
568
568
|
no_cache?: boolean | undefined;
|
|
569
569
|
network?: ENTRYPOINT | undefined;
|
|
570
570
|
}>;
|
|
571
|
-
export declare const QueryReceivedSchema: z.ZodObject<{
|
|
572
|
-
no_cache: z.ZodOptional<z.ZodBoolean>;
|
|
573
|
-
network: z.ZodOptional<z.ZodEnum<[ENTRYPOINT.Localnet, ENTRYPOINT.Testnet]>>;
|
|
574
|
-
} & {
|
|
575
|
-
name_or_address: z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
576
|
-
name_or_address: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
|
|
577
|
-
local_mark_first: z.ZodOptional<z.ZodBoolean>;
|
|
578
|
-
}, "strict", z.ZodTypeAny, {
|
|
579
|
-
name_or_address?: string | undefined;
|
|
580
|
-
local_mark_first?: boolean | undefined;
|
|
581
|
-
}, {
|
|
582
|
-
name_or_address?: string | undefined;
|
|
583
|
-
local_mark_first?: boolean | undefined;
|
|
584
|
-
}>]>;
|
|
585
|
-
all_type: z.ZodOptional<z.ZodBoolean>;
|
|
586
|
-
cursor: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNull]>>;
|
|
587
|
-
limit: z.ZodOptional<z.ZodUnion<[z.ZodNumber, z.ZodNull]>>;
|
|
588
|
-
}, "strict", z.ZodTypeAny, {
|
|
589
|
-
name_or_address: string | {
|
|
590
|
-
name_or_address?: string | undefined;
|
|
591
|
-
local_mark_first?: boolean | undefined;
|
|
592
|
-
};
|
|
593
|
-
no_cache?: boolean | undefined;
|
|
594
|
-
network?: ENTRYPOINT | undefined;
|
|
595
|
-
all_type?: boolean | undefined;
|
|
596
|
-
cursor?: string | null | undefined;
|
|
597
|
-
limit?: number | null | undefined;
|
|
598
|
-
}, {
|
|
599
|
-
name_or_address: string | {
|
|
600
|
-
name_or_address?: string | undefined;
|
|
601
|
-
local_mark_first?: boolean | undefined;
|
|
602
|
-
};
|
|
603
|
-
no_cache?: boolean | undefined;
|
|
604
|
-
network?: ENTRYPOINT | undefined;
|
|
605
|
-
all_type?: boolean | undefined;
|
|
606
|
-
cursor?: string | null | undefined;
|
|
607
|
-
limit?: number | null | undefined;
|
|
608
|
-
}>;
|
|
609
571
|
export declare const ReceivedBalanceObjectSchema: z.ZodObject<{
|
|
610
572
|
id: z.ZodString;
|
|
611
573
|
balance: z.ZodUnion<[z.ZodNumber, z.ZodString]>;
|
|
@@ -837,7 +799,6 @@ export type GuardTableItem = z.infer<typeof GuardTableItemSchema>;
|
|
|
837
799
|
export type Entrypoint = z.infer<typeof EntrypointSchema>;
|
|
838
800
|
export type ObjectBase = z.infer<typeof ObjectBaseSchema>;
|
|
839
801
|
export type QueryEnv = z.infer<typeof QueryEnvSchema>;
|
|
840
|
-
export type QueryReceived = z.infer<typeof QueryReceivedSchema>;
|
|
841
802
|
export type ReceivedBalance = z.infer<typeof ReceivedBalanceSchema>;
|
|
842
803
|
export type ReceivedNormal = z.infer<typeof ReceivedNormalSchema>;
|
|
843
804
|
export type QueryReceivedResult = z.infer<typeof QueryReceivedResultSchema>;
|
|
@@ -272,12 +272,6 @@ export const QueryEnvSchema = z.object({
|
|
|
272
272
|
no_cache: z.boolean().optional().describe("Whether to disable cache"),
|
|
273
273
|
network: EntrypointSchema.optional(),
|
|
274
274
|
}).strict().describe("Query environment parameters");
|
|
275
|
-
export const QueryReceivedSchema = QueryEnvSchema.extend({
|
|
276
|
-
name_or_address: AccountOrMark_AddressAISchema,
|
|
277
|
-
all_type: z.boolean().optional().describe("Whether to query all types of received objects"),
|
|
278
|
-
cursor: z.union([z.string(), z.null()]).optional().describe("Pagination cursor"),
|
|
279
|
-
limit: z.union([z.number(), z.null()]).optional().describe("Number of records returned per page"),
|
|
280
|
-
}).strict().describe("Request parameters for querying object's received objects");
|
|
281
275
|
export const ReceivedBalanceObjectSchema = z.object({
|
|
282
276
|
id: z.string().describe("Received CoinWrapper object ID"),
|
|
283
277
|
balance: BalanceTypeSchema,
|
|
@@ -496,8 +496,8 @@ export declare const MessageFilterSchema: z.ZodObject<{
|
|
|
496
496
|
skipAutoMarkViewed: z.ZodOptional<z.ZodBoolean>;
|
|
497
497
|
}, "strip", z.ZodTypeAny, {
|
|
498
498
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
499
|
-
limit?: number | undefined;
|
|
500
499
|
account?: string | undefined;
|
|
500
|
+
limit?: number | undefined;
|
|
501
501
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
502
502
|
direction?: "received" | "sent" | undefined;
|
|
503
503
|
msgType?: 1 | 3 | undefined;
|
|
@@ -538,8 +538,8 @@ export declare const MessageFilterSchema: z.ZodObject<{
|
|
|
538
538
|
viewedAtEnd?: number | undefined;
|
|
539
539
|
}, {
|
|
540
540
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
541
|
-
limit?: number | undefined;
|
|
542
541
|
account?: string | undefined;
|
|
542
|
+
limit?: number | undefined;
|
|
543
543
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
544
544
|
direction?: "received" | "sent" | undefined;
|
|
545
545
|
msgType?: 1 | 3 | undefined;
|
|
@@ -1645,8 +1645,8 @@ export declare const MessengerOperationInputSchema: z.ZodDiscriminatedUnion<"ope
|
|
|
1645
1645
|
skipAutoMarkViewed: z.ZodOptional<z.ZodBoolean>;
|
|
1646
1646
|
}, "strip", z.ZodTypeAny, {
|
|
1647
1647
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
1648
|
-
limit?: number | undefined;
|
|
1649
1648
|
account?: string | undefined;
|
|
1649
|
+
limit?: number | undefined;
|
|
1650
1650
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
1651
1651
|
direction?: "received" | "sent" | undefined;
|
|
1652
1652
|
msgType?: 1 | 3 | undefined;
|
|
@@ -1687,8 +1687,8 @@ export declare const MessengerOperationInputSchema: z.ZodDiscriminatedUnion<"ope
|
|
|
1687
1687
|
viewedAtEnd?: number | undefined;
|
|
1688
1688
|
}, {
|
|
1689
1689
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
1690
|
-
limit?: number | undefined;
|
|
1691
1690
|
account?: string | undefined;
|
|
1691
|
+
limit?: number | undefined;
|
|
1692
1692
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
1693
1693
|
direction?: "received" | "sent" | undefined;
|
|
1694
1694
|
msgType?: 1 | 3 | undefined;
|
|
@@ -1732,8 +1732,8 @@ export declare const MessengerOperationInputSchema: z.ZodDiscriminatedUnion<"ope
|
|
|
1732
1732
|
operation: "watch_messages";
|
|
1733
1733
|
filter?: {
|
|
1734
1734
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
1735
|
-
limit?: number | undefined;
|
|
1736
1735
|
account?: string | undefined;
|
|
1736
|
+
limit?: number | undefined;
|
|
1737
1737
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
1738
1738
|
direction?: "received" | "sent" | undefined;
|
|
1739
1739
|
msgType?: 1 | 3 | undefined;
|
|
@@ -1777,8 +1777,8 @@ export declare const MessengerOperationInputSchema: z.ZodDiscriminatedUnion<"ope
|
|
|
1777
1777
|
operation: "watch_messages";
|
|
1778
1778
|
filter?: {
|
|
1779
1779
|
status?: "pending" | "confirmed" | "read" | "failed" | "rejected" | "decrypted" | "decrypt_failed" | undefined;
|
|
1780
|
-
limit?: number | undefined;
|
|
1781
1780
|
account?: string | undefined;
|
|
1781
|
+
limit?: number | undefined;
|
|
1782
1782
|
contentType?: "text" | "wip" | "zip" | "wts" | undefined;
|
|
1783
1783
|
direction?: "received" | "sent" | undefined;
|
|
1784
1784
|
msgType?: 1 | 3 | undefined;
|
|
@@ -117,7 +117,7 @@ export const ObjectOrderSchema = ObjectBaseSchema.extend({
|
|
|
117
117
|
amount: BalanceTypeSchema.describe("Order amount"),
|
|
118
118
|
builder: z.string().describe("Purchaser ID"),
|
|
119
119
|
service: z.string().describe("Service ID"),
|
|
120
|
-
dispute: z.array(z.string()).describe("
|
|
120
|
+
dispute: z.array(z.string()).describe("Arb object ID list. When unsatisfied with order delivery, dispute objects can be created."),
|
|
121
121
|
agent: z.array(z.string()).describe("Agent ID list. Agents handle all order operations except payment collection."),
|
|
122
122
|
allocation: z.union([z.string(), z.null()]).describe("Order amount allocation object ID"),
|
|
123
123
|
claimed_by: z.union([z.string(), z.null()]).describe("Order dispute object ID that has claimed order arbitration amount."),
|
package/dist/schemas/index.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
3
|
"title": "WoWok MCP Schema Index",
|
|
4
4
|
"description": "Index of all available JSON schemas for WoWok MCP tools",
|
|
5
|
-
"generatedAt": "2026-05-
|
|
5
|
+
"generatedAt": "2026-05-20T13:29:28.773Z",
|
|
6
6
|
"tools": [
|
|
7
7
|
{
|
|
8
8
|
"name": "onchain_operations",
|
package/package.json
CHANGED
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wowok/agent-mcp",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.16",
|
|
4
4
|
"description": "Making It Easy for AI Agents to Communicate, Collaborate, Trade, and Trust.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
7
|
"module": "node",
|
|
8
8
|
"type": "module",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://github.com/wowok-ai/agent.git"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://wowok.net",
|
|
9
14
|
"files": [
|
|
10
15
|
"dist",
|
|
11
16
|
"docs",
|
|
@@ -31,7 +36,7 @@
|
|
|
31
36
|
"license": "Apache-2.0",
|
|
32
37
|
"dependencies": {
|
|
33
38
|
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
34
|
-
"@wowok/wowok": "2.2.
|
|
39
|
+
"@wowok/wowok": "2.2.14",
|
|
35
40
|
"lodash": "^4.18.1",
|
|
36
41
|
"zod": "^3.25.76"
|
|
37
42
|
},
|
|
@@ -1,163 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "https://wowok.net/schemas/operations/guard.json",
|
|
4
|
-
"title": "Guard Operation",
|
|
5
|
-
"description": "On-chain Guard operations",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"properties": {
|
|
8
|
-
"operation_type": {
|
|
9
|
-
"const": "guard"
|
|
10
|
-
},
|
|
11
|
-
"data": {
|
|
12
|
-
"type": "object",
|
|
13
|
-
"description": "On-chain Guard creation. IMPORTANT: All defined data (include all submitted data) must be defined in the 'table' field. USAGE: Set 'namedNew' field with {name, tags?, onChain?} to name the new Guard. The Guard is immutable once created. Define the validation logic in 'root' field. When root.type='file', the file can contain all Guard fields, and any fields defined in the schema will OVERRIDE the file content.",
|
|
14
|
-
"properties": {
|
|
15
|
-
"namedNew": {
|
|
16
|
-
"type": "object",
|
|
17
|
-
"description": "Name and optional tags for the new Guard object. Set 'onChain: true' to create a public on-chain identity. When using root.type='file', this field OVERRIDES namedNew in the file.",
|
|
18
|
-
"properties": {
|
|
19
|
-
"name": {
|
|
20
|
-
"type": "string",
|
|
21
|
-
"description": "The name of the object"
|
|
22
|
-
},
|
|
23
|
-
"tags": {
|
|
24
|
-
"type": "array",
|
|
25
|
-
"items": {
|
|
26
|
-
"type": "string"
|
|
27
|
-
},
|
|
28
|
-
"description": "The tags of the object"
|
|
29
|
-
},
|
|
30
|
-
"onChain": {
|
|
31
|
-
"type": "boolean",
|
|
32
|
-
"description": "CRITICAL: Whether to sync the name to the blockchain. DEFAULT (undefined/false): The name is stored LOCALLY ONLY on your device (PRIVATE). If set to true: The name is published ON-CHAIN and becomes PUBLICLY VISIBLE to everyone."
|
|
33
|
-
},
|
|
34
|
-
"replaceExistName": {
|
|
35
|
-
"type": "boolean",
|
|
36
|
-
"description": "FORCE CLAIM: Set to true ONLY when the user explicitly expresses a STRONG INTENTION to forcefully take over an existing name."
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
"additionalProperties": false
|
|
40
|
-
},
|
|
41
|
-
"description": {
|
|
42
|
-
"type": "string",
|
|
43
|
-
"description": "Guard description. When using root.type='file', this field OVERRIDES description in the file."
|
|
44
|
-
},
|
|
45
|
-
"table": {
|
|
46
|
-
"type": "array",
|
|
47
|
-
"description": "Data table of the Guard object. When using root.type='file', this field OVERRIDES table in the file.",
|
|
48
|
-
"items": {
|
|
49
|
-
"type": "object",
|
|
50
|
-
"properties": {
|
|
51
|
-
"identifier": {
|
|
52
|
-
"type": "integer",
|
|
53
|
-
"minimum": 0,
|
|
54
|
-
"maximum": 255,
|
|
55
|
-
"description": "Identifier index (0-255) for referencing this value in Guard nodes"
|
|
56
|
-
},
|
|
57
|
-
"bWitness": {
|
|
58
|
-
"type": "boolean",
|
|
59
|
-
"description": "Whether this is a witness parameter (provided at runtime)"
|
|
60
|
-
},
|
|
61
|
-
"value_type": {
|
|
62
|
-
"type": "string",
|
|
63
|
-
"description": "Value type: Bool, Address, String, U8, U16, U32, U64, U128, U256, VecBool, VecAddress, VecString, VecU8, VecU16, VecU32, VecU64, VecU128, VecU256, VecVecU8"
|
|
64
|
-
},
|
|
65
|
-
"value": {
|
|
66
|
-
"description": "The actual value (omit if bWitness is true)"
|
|
67
|
-
}
|
|
68
|
-
},
|
|
69
|
-
"required": [
|
|
70
|
-
"identifier",
|
|
71
|
-
"bWitness",
|
|
72
|
-
"value_type"
|
|
73
|
-
]
|
|
74
|
-
}
|
|
75
|
-
},
|
|
76
|
-
"root": {
|
|
77
|
-
"description": "Root definition: either a direct node tree (type='node') or a file reference (type='file'). When type='file', the file can define all Guard fields (namedNew, description, table, root, rely), and schema fields override file content.",
|
|
78
|
-
"oneOf": [
|
|
79
|
-
{
|
|
80
|
-
"type": "object",
|
|
81
|
-
"description": "Direct node tree",
|
|
82
|
-
"properties": {
|
|
83
|
-
"type": {
|
|
84
|
-
"const": "node"
|
|
85
|
-
},
|
|
86
|
-
"node": {
|
|
87
|
-
"type": "object",
|
|
88
|
-
"description": "Guard computational tree root node. MUST return a Bool value (pass/fail). See GuardNode documentation for details.",
|
|
89
|
-
"properties": {
|
|
90
|
-
"type": {
|
|
91
|
-
"type": "string"
|
|
92
|
-
}
|
|
93
|
-
},
|
|
94
|
-
"additionalProperties": true
|
|
95
|
-
}
|
|
96
|
-
},
|
|
97
|
-
"required": [
|
|
98
|
-
"type",
|
|
99
|
-
"node"
|
|
100
|
-
]
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
"type": "object",
|
|
104
|
-
"description": "File reference",
|
|
105
|
-
"properties": {
|
|
106
|
-
"type": {
|
|
107
|
-
"const": "file"
|
|
108
|
-
},
|
|
109
|
-
"file_path": {
|
|
110
|
-
"type": "string",
|
|
111
|
-
"description": "Path to JSON or Markdown file containing Guard definition"
|
|
112
|
-
},
|
|
113
|
-
"format": {
|
|
114
|
-
"type": "string",
|
|
115
|
-
"enum": [
|
|
116
|
-
"json",
|
|
117
|
-
"markdown"
|
|
118
|
-
],
|
|
119
|
-
"default": "json",
|
|
120
|
-
"description": "File format: 'json' or 'markdown'"
|
|
121
|
-
}
|
|
122
|
-
},
|
|
123
|
-
"required": [
|
|
124
|
-
"type",
|
|
125
|
-
"file_path"
|
|
126
|
-
]
|
|
127
|
-
}
|
|
128
|
-
]
|
|
129
|
-
},
|
|
130
|
-
"rely": {
|
|
131
|
-
"type": "object",
|
|
132
|
-
"description": "All Guard objects that the new Guard object depends on.",
|
|
133
|
-
"properties": {
|
|
134
|
-
"guards": {
|
|
135
|
-
"type": "array",
|
|
136
|
-
"items": {
|
|
137
|
-
"type": "string"
|
|
138
|
-
},
|
|
139
|
-
"description": "List of dependent Guard object IDs or names."
|
|
140
|
-
},
|
|
141
|
-
"logic_or": {
|
|
142
|
-
"type": "boolean",
|
|
143
|
-
"description": "Whether to use logical OR operator."
|
|
144
|
-
}
|
|
145
|
-
},
|
|
146
|
-
"required": [
|
|
147
|
-
"guards"
|
|
148
|
-
]
|
|
149
|
-
}
|
|
150
|
-
},
|
|
151
|
-
"required": [
|
|
152
|
-
"root"
|
|
153
|
-
]
|
|
154
|
-
},
|
|
155
|
-
"env": {
|
|
156
|
-
"type": "object"
|
|
157
|
-
}
|
|
158
|
-
},
|
|
159
|
-
"required": [
|
|
160
|
-
"operation_type",
|
|
161
|
-
"data"
|
|
162
|
-
]
|
|
163
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "https://wowok.net/schemas/operations/permission.json",
|
|
4
|
-
"title": "Permission Operation",
|
|
5
|
-
"description": "On-chain Permission operations",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"properties": {
|
|
8
|
-
"operation_type": {
|
|
9
|
-
"const": "permission"
|
|
10
|
-
},
|
|
11
|
-
"data": {
|
|
12
|
-
"$ref": "../onchain_operations_permission.schema.json#/properties/data"
|
|
13
|
-
},
|
|
14
|
-
"env": {
|
|
15
|
-
"type": "object"
|
|
16
|
-
}
|
|
17
|
-
},
|
|
18
|
-
"required": [
|
|
19
|
-
"operation_type",
|
|
20
|
-
"data"
|
|
21
|
-
]
|
|
22
|
-
}
|