@wowok/agent-mcp 2.3.16 → 2.3.18

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 (106) hide show
  1. package/dist/customer/index.d.ts +9 -0
  2. package/dist/customer/index.js +9 -0
  3. package/dist/customer/industry-risks.d.ts +4 -0
  4. package/dist/customer/industry-risks.js +14 -0
  5. package/dist/customer/user-preferences.d.ts +3 -0
  6. package/dist/customer/user-preferences.js +9 -0
  7. package/dist/experience/realtime-feedback.js +17 -0
  8. package/dist/index.js +360 -273
  9. package/dist/knowledge/acquisition-flywheel.d.ts +3 -0
  10. package/dist/knowledge/acquisition-flywheel.js +9 -0
  11. package/dist/knowledge/guard-ledger.d.ts +19 -0
  12. package/dist/knowledge/guard-ledger.js +219 -0
  13. package/dist/knowledge/guard-puzzle.d.ts +93 -0
  14. package/dist/knowledge/guard-puzzle.js +278 -0
  15. package/dist/knowledge/guard-risk.d.ts +60 -0
  16. package/dist/knowledge/guard-risk.js +474 -0
  17. package/dist/knowledge/guard-translation.d.ts +46 -0
  18. package/dist/knowledge/guard-translation.js +487 -0
  19. package/dist/knowledge/index.d.ts +13 -0
  20. package/dist/knowledge/index.js +13 -0
  21. package/dist/knowledge/industry-registry.d.ts +1 -2
  22. package/dist/knowledge/industry-registry.js +23 -3
  23. package/dist/knowledge/safety-rules.js +61 -0
  24. package/dist/knowledge/tool-constraints.js +12 -22
  25. package/dist/safety/confirm-gate.d.ts +4 -2
  26. package/dist/safety/confirm-gate.js +48 -4
  27. package/dist/schema/call/allocation.d.ts +24 -14
  28. package/dist/schema/call/arbitration.d.ts +142 -132
  29. package/dist/schema/call/base.d.ts +901 -43
  30. package/dist/schema/call/base.js +66 -2
  31. package/dist/schema/call/bridge-handler.js +15 -2
  32. package/dist/schema/call/bridge.d.ts +769 -1
  33. package/dist/schema/call/bridge.js +37 -0
  34. package/dist/schema/call/contact.d.ts +10 -0
  35. package/dist/schema/call/demand.d.ts +10 -0
  36. package/dist/schema/call/guard.d.ts +76 -46
  37. package/dist/schema/call/handler.js +46 -14
  38. package/dist/schema/call/machine.d.ts +158 -138
  39. package/dist/schema/call/order.d.ts +10 -0
  40. package/dist/schema/call/payment.d.ts +10 -0
  41. package/dist/schema/call/permission.d.ts +232 -222
  42. package/dist/schema/call/personal.d.ts +10 -0
  43. package/dist/schema/call/progress.d.ts +10 -0
  44. package/dist/schema/call/proof.d.ts +20 -0
  45. package/dist/schema/call/repository.d.ts +32 -22
  46. package/dist/schema/call/reward.d.ts +10 -0
  47. package/dist/schema/call/semantic.d.ts +9 -2
  48. package/dist/schema/call/semantic.js +409 -21
  49. package/dist/schema/call/service.d.ts +20 -10
  50. package/dist/schema/call/treasury.d.ts +10 -0
  51. package/dist/schema/config/index.d.ts +18 -0
  52. package/dist/schema/config/index.js +17 -0
  53. package/dist/schema/index.d.ts +6 -0
  54. package/dist/schema/index.js +5 -0
  55. package/dist/schema/local/index.d.ts +9 -9
  56. package/dist/schema/local/index.js +9 -0
  57. package/dist/schema/messenger/index.d.ts +350 -29
  58. package/dist/schema/messenger/index.js +17 -17
  59. package/dist/schema/operations.d.ts +1667 -545
  60. package/dist/schema/operations.js +91 -96
  61. package/dist/schema/project/index.d.ts +21 -0
  62. package/dist/schema/project/index.js +32 -0
  63. package/dist/schema/query/index.d.ts +1074 -168
  64. package/dist/schema/query/index.js +8 -8
  65. package/dist/schema/schema-query/index.d.ts +33 -0
  66. package/dist/schema/schema-query/index.js +36 -0
  67. package/dist/schema/schema-version.d.ts +25 -0
  68. package/dist/schema/schema-version.js +76 -0
  69. package/dist/schema/trust/index.d.ts +407 -0
  70. package/dist/schema/trust/index.js +113 -0
  71. package/dist/schemas/bridge_operation.output.json +224 -0
  72. package/dist/schemas/bridge_operation.schema.json +67 -8
  73. package/dist/schemas/config_operation.output.json +18 -0
  74. package/dist/schemas/config_operation.schema.json +34 -0
  75. package/dist/schemas/guard-node-schema.json +82 -0
  76. package/dist/schemas/guard2file.schema.json +8 -0
  77. package/dist/schemas/index.json +19 -1
  78. package/dist/schemas/machineNode2file.schema.json +8 -0
  79. package/dist/schemas/messenger_operation.output.json +224 -0
  80. package/dist/schemas/onchain_events.output.json +718 -0
  81. package/dist/schemas/onchain_operations.output.json +277 -2
  82. package/dist/schemas/onchain_operations.schema.json +19 -16
  83. package/dist/schemas/onchain_operations_allocation.schema.json +8 -0
  84. package/dist/schemas/onchain_operations_arbitration.schema.json +8 -0
  85. package/dist/schemas/onchain_operations_contact.schema.json +8 -0
  86. package/dist/schemas/onchain_operations_demand.schema.json +8 -0
  87. package/dist/schemas/onchain_operations_gen_passport.schema.json +16 -0
  88. package/dist/schemas/onchain_operations_guard.schema.json +11 -16
  89. package/dist/schemas/onchain_operations_machine.schema.json +8 -0
  90. package/dist/schemas/onchain_operations_order.schema.json +8 -0
  91. package/dist/schemas/onchain_operations_payment.schema.json +8 -0
  92. package/dist/schemas/onchain_operations_permission.schema.json +8 -0
  93. package/dist/schemas/onchain_operations_personal.schema.json +8 -0
  94. package/dist/schemas/onchain_operations_progress.schema.json +8 -0
  95. package/dist/schemas/onchain_operations_repository.schema.json +8 -0
  96. package/dist/schemas/onchain_operations_reward.schema.json +8 -0
  97. package/dist/schemas/onchain_operations_service.schema.json +8 -0
  98. package/dist/schemas/onchain_operations_treasury.schema.json +8 -0
  99. package/dist/schemas/onchain_table_data.output.json +718 -0
  100. package/dist/schemas/project_operation.output.json +18 -0
  101. package/dist/schemas/project_operation.schema.json +42 -0
  102. package/dist/schemas/query_toolkit.schema.json +360 -368
  103. package/dist/schemas/schema_query.schema.json +6 -3
  104. package/dist/schemas/trust_score.output.json +327 -0
  105. package/dist/schemas/trust_score.schema.json +46 -0
  106. package/package.json +2 -2
@@ -1,7 +1,7 @@
1
1
  import { z } from "zod";
2
2
  import { TokenTypeInfoSchema, QueryLocalMarkListResultSchema, QueryAccountListResultSchema, QueryLocalInfoListResultSchema, QueryLocalTokenListResultSchema, QueryAccountResultSchema } from "../local/index.js";
3
3
  import { AccountOrMark_AddressSchema, BalanceTypeSchema, CacheExpireTypeSchema, EntrypointSchema, GuardIdentifierSchema, GuardTableItemSchema, NameOrAddressSchema, ObjectBaseSchema, ObjectTypeSchema, QueryIdSchema, SupportedValueSchema, ValueTypeSchema, QueryReceivedResultSchema, LongNameSchema, DescriptionSchema } from "../common/index.js";
4
- const SemanticSummarySchema = z.any();
4
+ import { SemanticSummarySchema } from "../call/index.js";
5
5
  import { isValidPermissionIndex } from '../utils/permission-index-utils.js';
6
6
  import { isValidGuardQueryId, isValidGuardQueryIdOrName } from '../utils/guard-query-utils.js';
7
7
  import { ENTITY_LINKER_ADDRESS, ENTITY_REGISTRAR_ADDRESS, isWitnessType, } from "@wowok/wowok";
@@ -1035,7 +1035,7 @@ export const OnchainEventsInputSchema = z.object({
1035
1035
  order: z.union([z.literal("ascending"), z.literal("descending"), z.null()]).optional().describe("Sort order for results: 'ascending' (oldest first) or 'descending' (newest first). Use null for default order"),
1036
1036
  no_cache: z.boolean().optional().describe("Whether to bypass cache and fetch fresh data from the blockchain"),
1037
1037
  network: EntrypointSchema.optional().describe("Network to query: 'mainnet' or 'testnet'. Uses default network if not specified"),
1038
- }).describe("Input parameters for querying on-chain WOWOK events");
1038
+ }).strict().describe("Input parameters for querying on-chain WOWOK events");
1039
1039
  export const OnchainEventsResultSchema = z.object({
1040
1040
  result: z.union([EventAnswerSchema, z.null()]).describe("Event query result containing list of events and pagination info, or null if no data found"),
1041
1041
  semantic: SemanticSummarySchema.optional().describe("Business semantic summary for the event query"),
@@ -1203,24 +1203,24 @@ export const BridgeTokenInfoSchema = z.object({
1203
1203
  export const ProtocolInfoQuerySchema = z.discriminatedUnion('info', [
1204
1204
  z.object({
1205
1205
  info: z.literal('constants')
1206
- }).describe('Constants query'),
1206
+ }).strict().describe('Constants query'),
1207
1207
  z.object({
1208
1208
  info: z.literal('built-in permissions'),
1209
1209
  filter: z.optional(PermissionFilterSchema).describe('Filter for built-in permissions')
1210
- }).describe('Built-in permissions query'),
1210
+ }).strict().describe('Built-in permissions query'),
1211
1211
  z.object({
1212
1212
  info: z.literal('guard instructions'),
1213
1213
  filter: z.optional(GuardInstructFilterOptionsSchema).describe('Filter for guard instructions')
1214
- }).describe('Guard instructions and wowok object queries'),
1214
+ }).strict().describe('Guard instructions and wowok object queries'),
1215
1215
  z.object({
1216
1216
  info: z.literal('current network')
1217
- }).describe('Current network entrypoint'),
1217
+ }).strict().describe('Current network entrypoint'),
1218
1218
  z.object({
1219
1219
  info: z.literal('value types')
1220
- }).describe('Value types query - returns all supported value types with their numeric and string representations'),
1220
+ }).strict().describe('Value types query - returns all supported value types with their numeric and string representations'),
1221
1221
  z.object({
1222
1222
  info: z.literal('mainnet bridge tokens')
1223
- }).describe('Mainnet Bridge tokens query - returns all tokens deployed on the mainnet bridge with their symbol, WOW-side type tag, EVM address, decimals, and description')
1223
+ }).strict().describe('Mainnet Bridge tokens query - returns all tokens deployed on the mainnet bridge with their symbol, WOW-side type tag, EVM address, decimals, and description')
1224
1224
  ]).describe('WoWok Build-in infomation query');
1225
1225
  export const BuiltinPermissionSchema = z.object({
1226
1226
  result: z.array(PermissionInfoTypeSchema).describe('Built-in permissions result')
@@ -0,0 +1,33 @@
1
+ import { z } from "zod";
2
+ export declare const SchemaQueryInputSchema: z.ZodObject<{
3
+ action: z.ZodEnum<["list", "get", "get_output", "search", "list_operations"]>;
4
+ name: z.ZodOptional<z.ZodString>;
5
+ query: z.ZodOptional<z.ZodString>;
6
+ }, "strict", z.ZodTypeAny, {
7
+ action: "get" | "search" | "list" | "get_output" | "list_operations";
8
+ name?: string | undefined;
9
+ query?: string | undefined;
10
+ }, {
11
+ action: "get" | "search" | "list" | "get_output" | "list_operations";
12
+ name?: string | undefined;
13
+ query?: string | undefined;
14
+ }>;
15
+ export declare const SchemaQueryOutputSchema: z.ZodObject<{
16
+ success: z.ZodBoolean;
17
+ action: z.ZodString;
18
+ data: z.ZodAny;
19
+ message: z.ZodString;
20
+ suggestions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
21
+ }, "strict", z.ZodTypeAny, {
22
+ message: string;
23
+ success: boolean;
24
+ action: string;
25
+ data?: any;
26
+ suggestions?: string[] | undefined;
27
+ }, {
28
+ message: string;
29
+ success: boolean;
30
+ action: string;
31
+ data?: any;
32
+ suggestions?: string[] | undefined;
33
+ }>;
@@ -0,0 +1,36 @@
1
+ import { z } from "zod";
2
+ export const SchemaQueryInputSchema = z
3
+ .object({
4
+ action: z
5
+ .enum([
6
+ "list",
7
+ "get",
8
+ "get_output",
9
+ "search",
10
+ "list_operations",
11
+ ])
12
+ .describe("Action to perform: 'list' to see all available schemas, 'get' to retrieve a specific input schema, 'get_output' to retrieve a tool's output schema, 'search' to find schemas by keyword, 'list_operations' to list all on-chain operations"),
13
+ name: z
14
+ .string()
15
+ .optional()
16
+ .describe("Schema/tool name for 'get'/'get_output' action (e.g., 'onchain_operations', 'account_operation', 'onchain_operations_permission')"),
17
+ query: z
18
+ .string()
19
+ .optional()
20
+ .describe("Search query for 'search' action"),
21
+ })
22
+ .strict();
23
+ export const SchemaQueryOutputSchema = z
24
+ .object({
25
+ success: z.boolean().describe("Whether the request was successful"),
26
+ action: z.string().describe("The action that was performed"),
27
+ data: z
28
+ .any()
29
+ .describe("Response data - JSON Schema object for 'get'/'get_output', array of schema info for 'list'/'search'/'list_operations'"),
30
+ message: z.string().describe("Human-readable message describing the result"),
31
+ suggestions: z
32
+ .array(z.string())
33
+ .optional()
34
+ .describe("Suggested next steps or alternatives"),
35
+ })
36
+ .strict();
@@ -0,0 +1,25 @@
1
+ export declare const MCP_SCHEMA_VERSION = "1.0.0";
2
+ export interface SchemaVersions {
3
+ sdk: string;
4
+ mcp: string;
5
+ }
6
+ export declare function getSchemaVersions(): SchemaVersions;
7
+ export type SchemaCompatibilityMode = "warn" | "strict";
8
+ export interface SchemaCheckOptions {
9
+ mode?: SchemaCompatibilityMode;
10
+ }
11
+ export interface SchemaCheckResult {
12
+ compatible: boolean;
13
+ warnings: string[];
14
+ errors: string[];
15
+ versions: SchemaVersions;
16
+ client_version?: string;
17
+ }
18
+ export declare function checkClientSchemaCompatibility(clientSchemaVersion: string | undefined, options?: SchemaCheckOptions): SchemaCheckResult;
19
+ export declare function attachSchemaWarning<T extends {
20
+ result?: unknown;
21
+ message?: string;
22
+ semantic?: {
23
+ warnings?: string[];
24
+ };
25
+ }>(output: T, schemaCheck: SchemaCheckResult): T;
@@ -0,0 +1,76 @@
1
+ import * as wowok from "@wowok/wowok";
2
+ const SDK_SCHEMA_VERSION = wowok.SCHEMA_VERSION ?? "1.0.0";
3
+ const checkSchemaCompatibility = wowok
4
+ .checkSchemaCompatibility ??
5
+ ((_client, _server) => ({ compatible: true }));
6
+ export const MCP_SCHEMA_VERSION = "1.0.0";
7
+ export function getSchemaVersions() {
8
+ return {
9
+ sdk: SDK_SCHEMA_VERSION,
10
+ mcp: MCP_SCHEMA_VERSION,
11
+ };
12
+ }
13
+ export function checkClientSchemaCompatibility(clientSchemaVersion, options = {}) {
14
+ const versions = getSchemaVersions();
15
+ const result = {
16
+ compatible: true,
17
+ warnings: [],
18
+ errors: [],
19
+ versions,
20
+ client_version: clientSchemaVersion,
21
+ };
22
+ if (!clientSchemaVersion) {
23
+ return result;
24
+ }
25
+ const sdkCheck = checkSchemaCompatibility(clientSchemaVersion, versions.sdk);
26
+ if (!sdkCheck.compatible) {
27
+ result.compatible = false;
28
+ const message = `SDK schema incompatibility: ${sdkCheck.reason}`;
29
+ if (options.mode === "strict") {
30
+ result.errors.push(message);
31
+ }
32
+ else {
33
+ result.warnings.push(message);
34
+ }
35
+ }
36
+ const mcpCheck = checkSchemaCompatibility(clientSchemaVersion, versions.mcp);
37
+ if (!mcpCheck.compatible) {
38
+ result.compatible = false;
39
+ const message = `MCP schema incompatibility: ${mcpCheck.reason}`;
40
+ if (options.mode === "strict") {
41
+ result.errors.push(message);
42
+ }
43
+ else {
44
+ result.warnings.push(message);
45
+ }
46
+ }
47
+ return result;
48
+ }
49
+ export function attachSchemaWarning(output, schemaCheck) {
50
+ if (schemaCheck.warnings.length === 0 && schemaCheck.errors.length === 0) {
51
+ return output;
52
+ }
53
+ const warnings = [];
54
+ if (schemaCheck.warnings.length > 0) {
55
+ warnings.push(...schemaCheck.warnings);
56
+ }
57
+ if (schemaCheck.errors.length > 0) {
58
+ warnings.push(...schemaCheck.errors);
59
+ }
60
+ const semantic = output.semantic
61
+ ? {
62
+ ...output.semantic,
63
+ warnings: [...(output.semantic.warnings || []), ...warnings],
64
+ }
65
+ : undefined;
66
+ return {
67
+ ...output,
68
+ semantic,
69
+ schema_warning: {
70
+ compatible: schemaCheck.compatible,
71
+ warnings,
72
+ client_version: schemaCheck.client_version,
73
+ server_versions: schemaCheck.versions,
74
+ },
75
+ };
76
+ }
@@ -0,0 +1,407 @@
1
+ import { z } from "zod";
2
+ export declare const TrustScoreInputSchema: z.ZodObject<{
3
+ service: z.ZodEffects<z.ZodString, string, string>;
4
+ order_amount: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber]>>;
5
+ depth: z.ZodOptional<z.ZodEnum<["browse", "evaluate", "preorder"]>>;
6
+ network: z.ZodOptional<z.ZodString>;
7
+ no_cache: z.ZodOptional<z.ZodBoolean>;
8
+ }, "strict", z.ZodTypeAny, {
9
+ service: string;
10
+ no_cache?: boolean | undefined;
11
+ network?: string | undefined;
12
+ order_amount?: string | number | undefined;
13
+ depth?: "browse" | "evaluate" | "preorder" | undefined;
14
+ }, {
15
+ service: string;
16
+ no_cache?: boolean | undefined;
17
+ network?: string | undefined;
18
+ order_amount?: string | number | undefined;
19
+ depth?: "browse" | "evaluate" | "preorder" | undefined;
20
+ }>;
21
+ export declare const TrustScoreOutputSchema: z.ZodObject<{
22
+ result: z.ZodObject<{
23
+ service_id: z.ZodString;
24
+ service_name: z.ZodString;
25
+ service_basics: z.ZodObject<{
26
+ bPublished: z.ZodBoolean;
27
+ bPaused: z.ZodBoolean;
28
+ sales_count: z.ZodNumber;
29
+ has_machine: z.ZodBoolean;
30
+ has_buy_guard: z.ZodBoolean;
31
+ has_um_contact: z.ZodBoolean;
32
+ arbitrations_count: z.ZodNumber;
33
+ }, "strip", z.ZodTypeAny, {
34
+ bPublished: boolean;
35
+ bPaused: boolean;
36
+ sales_count: number;
37
+ has_machine: boolean;
38
+ has_buy_guard: boolean;
39
+ has_um_contact: boolean;
40
+ arbitrations_count: number;
41
+ }, {
42
+ bPublished: boolean;
43
+ bPaused: boolean;
44
+ sales_count: number;
45
+ has_machine: boolean;
46
+ has_buy_guard: boolean;
47
+ has_um_contact: boolean;
48
+ arbitrations_count: number;
49
+ }>;
50
+ trust_score: z.ZodObject<{
51
+ score: z.ZodNumber;
52
+ level: z.ZodEnum<["high_risk", "caution", "moderate", "trusted"]>;
53
+ summary: z.ZodString;
54
+ warnings: z.ZodArray<z.ZodString, "many">;
55
+ breakdown: z.ZodArray<z.ZodObject<{
56
+ score: z.ZodNumber;
57
+ maxScore: z.ZodNumber;
58
+ description: z.ZodString;
59
+ humanReadable: z.ZodString;
60
+ }, "strip", z.ZodTypeAny, {
61
+ description: string;
62
+ score: number;
63
+ maxScore: number;
64
+ humanReadable: string;
65
+ }, {
66
+ description: string;
67
+ score: number;
68
+ maxScore: number;
69
+ humanReadable: string;
70
+ }>, "many">;
71
+ }, "strip", z.ZodTypeAny, {
72
+ score: number;
73
+ summary: string;
74
+ warnings: string[];
75
+ level: "high_risk" | "caution" | "moderate" | "trusted";
76
+ breakdown: {
77
+ description: string;
78
+ score: number;
79
+ maxScore: number;
80
+ humanReadable: string;
81
+ }[];
82
+ }, {
83
+ score: number;
84
+ summary: string;
85
+ warnings: string[];
86
+ level: "high_risk" | "caution" | "moderate" | "trusted";
87
+ breakdown: {
88
+ description: string;
89
+ score: number;
90
+ maxScore: number;
91
+ humanReadable: string;
92
+ }[];
93
+ }>;
94
+ order_amount: z.ZodString;
95
+ depth: z.ZodEnum<["browse", "evaluate", "preorder"]>;
96
+ risk_score: z.ZodOptional<z.ZodObject<{
97
+ total: z.ZodNumber;
98
+ level: z.ZodEnum<["low", "medium_low", "medium_high", "high"]>;
99
+ red_flags: z.ZodArray<z.ZodString, "many">;
100
+ advice: z.ZodArray<z.ZodString, "many">;
101
+ dimensions: z.ZodArray<z.ZodObject<{
102
+ name: z.ZodEnum<["workflow", "fund", "trust", "behavior"]>;
103
+ score: z.ZodNumber;
104
+ max_score: z.ZodNumber;
105
+ checks: z.ZodArray<z.ZodObject<{
106
+ id: z.ZodString;
107
+ dimension: z.ZodEnum<["workflow", "fund", "trust", "behavior"]>;
108
+ description: z.ZodString;
109
+ weight: z.ZodNumber;
110
+ passed: z.ZodBoolean;
111
+ advice: z.ZodOptional<z.ZodString>;
112
+ }, "strip", z.ZodTypeAny, {
113
+ description: string;
114
+ id: string;
115
+ dimension: "fund" | "workflow" | "trust" | "behavior";
116
+ weight: number;
117
+ passed: boolean;
118
+ advice?: string | undefined;
119
+ }, {
120
+ description: string;
121
+ id: string;
122
+ dimension: "fund" | "workflow" | "trust" | "behavior";
123
+ weight: number;
124
+ passed: boolean;
125
+ advice?: string | undefined;
126
+ }>, "many">;
127
+ }, "strip", z.ZodTypeAny, {
128
+ name: "fund" | "workflow" | "trust" | "behavior";
129
+ score: number;
130
+ max_score: number;
131
+ checks: {
132
+ description: string;
133
+ id: string;
134
+ dimension: "fund" | "workflow" | "trust" | "behavior";
135
+ weight: number;
136
+ passed: boolean;
137
+ advice?: string | undefined;
138
+ }[];
139
+ }, {
140
+ name: "fund" | "workflow" | "trust" | "behavior";
141
+ score: number;
142
+ max_score: number;
143
+ checks: {
144
+ description: string;
145
+ id: string;
146
+ dimension: "fund" | "workflow" | "trust" | "behavior";
147
+ weight: number;
148
+ passed: boolean;
149
+ advice?: string | undefined;
150
+ }[];
151
+ }>, "many">;
152
+ }, "strip", z.ZodTypeAny, {
153
+ advice: string[];
154
+ level: "low" | "medium_low" | "medium_high" | "high";
155
+ total: number;
156
+ red_flags: string[];
157
+ dimensions: {
158
+ name: "fund" | "workflow" | "trust" | "behavior";
159
+ score: number;
160
+ max_score: number;
161
+ checks: {
162
+ description: string;
163
+ id: string;
164
+ dimension: "fund" | "workflow" | "trust" | "behavior";
165
+ weight: number;
166
+ passed: boolean;
167
+ advice?: string | undefined;
168
+ }[];
169
+ }[];
170
+ }, {
171
+ advice: string[];
172
+ level: "low" | "medium_low" | "medium_high" | "high";
173
+ total: number;
174
+ red_flags: string[];
175
+ dimensions: {
176
+ name: "fund" | "workflow" | "trust" | "behavior";
177
+ score: number;
178
+ max_score: number;
179
+ checks: {
180
+ description: string;
181
+ id: string;
182
+ dimension: "fund" | "workflow" | "trust" | "behavior";
183
+ weight: number;
184
+ passed: boolean;
185
+ advice?: string | undefined;
186
+ }[];
187
+ }[];
188
+ }>>;
189
+ info_puzzle: z.ZodOptional<z.ZodObject<{
190
+ completeness: z.ZodNumber;
191
+ gaps: z.ZodArray<z.ZodString, "many">;
192
+ assembled_at: z.ZodNumber;
193
+ }, "strip", z.ZodTypeAny, {
194
+ completeness: number;
195
+ gaps: string[];
196
+ assembled_at: number;
197
+ }, {
198
+ completeness: number;
199
+ gaps: string[];
200
+ assembled_at: number;
201
+ }>>;
202
+ }, "strip", z.ZodTypeAny, {
203
+ trust_score: {
204
+ score: number;
205
+ summary: string;
206
+ warnings: string[];
207
+ level: "high_risk" | "caution" | "moderate" | "trusted";
208
+ breakdown: {
209
+ description: string;
210
+ score: number;
211
+ maxScore: number;
212
+ humanReadable: string;
213
+ }[];
214
+ };
215
+ service_id: string;
216
+ order_amount: string;
217
+ depth: "browse" | "evaluate" | "preorder";
218
+ service_name: string;
219
+ service_basics: {
220
+ bPublished: boolean;
221
+ bPaused: boolean;
222
+ sales_count: number;
223
+ has_machine: boolean;
224
+ has_buy_guard: boolean;
225
+ has_um_contact: boolean;
226
+ arbitrations_count: number;
227
+ };
228
+ risk_score?: {
229
+ advice: string[];
230
+ level: "low" | "medium_low" | "medium_high" | "high";
231
+ total: number;
232
+ red_flags: string[];
233
+ dimensions: {
234
+ name: "fund" | "workflow" | "trust" | "behavior";
235
+ score: number;
236
+ max_score: number;
237
+ checks: {
238
+ description: string;
239
+ id: string;
240
+ dimension: "fund" | "workflow" | "trust" | "behavior";
241
+ weight: number;
242
+ passed: boolean;
243
+ advice?: string | undefined;
244
+ }[];
245
+ }[];
246
+ } | undefined;
247
+ info_puzzle?: {
248
+ completeness: number;
249
+ gaps: string[];
250
+ assembled_at: number;
251
+ } | undefined;
252
+ }, {
253
+ trust_score: {
254
+ score: number;
255
+ summary: string;
256
+ warnings: string[];
257
+ level: "high_risk" | "caution" | "moderate" | "trusted";
258
+ breakdown: {
259
+ description: string;
260
+ score: number;
261
+ maxScore: number;
262
+ humanReadable: string;
263
+ }[];
264
+ };
265
+ service_id: string;
266
+ order_amount: string;
267
+ depth: "browse" | "evaluate" | "preorder";
268
+ service_name: string;
269
+ service_basics: {
270
+ bPublished: boolean;
271
+ bPaused: boolean;
272
+ sales_count: number;
273
+ has_machine: boolean;
274
+ has_buy_guard: boolean;
275
+ has_um_contact: boolean;
276
+ arbitrations_count: number;
277
+ };
278
+ risk_score?: {
279
+ advice: string[];
280
+ level: "low" | "medium_low" | "medium_high" | "high";
281
+ total: number;
282
+ red_flags: string[];
283
+ dimensions: {
284
+ name: "fund" | "workflow" | "trust" | "behavior";
285
+ score: number;
286
+ max_score: number;
287
+ checks: {
288
+ description: string;
289
+ id: string;
290
+ dimension: "fund" | "workflow" | "trust" | "behavior";
291
+ weight: number;
292
+ passed: boolean;
293
+ advice?: string | undefined;
294
+ }[];
295
+ }[];
296
+ } | undefined;
297
+ info_puzzle?: {
298
+ completeness: number;
299
+ gaps: string[];
300
+ assembled_at: number;
301
+ } | undefined;
302
+ }>;
303
+ }, "strip", z.ZodTypeAny, {
304
+ result: {
305
+ trust_score: {
306
+ score: number;
307
+ summary: string;
308
+ warnings: string[];
309
+ level: "high_risk" | "caution" | "moderate" | "trusted";
310
+ breakdown: {
311
+ description: string;
312
+ score: number;
313
+ maxScore: number;
314
+ humanReadable: string;
315
+ }[];
316
+ };
317
+ service_id: string;
318
+ order_amount: string;
319
+ depth: "browse" | "evaluate" | "preorder";
320
+ service_name: string;
321
+ service_basics: {
322
+ bPublished: boolean;
323
+ bPaused: boolean;
324
+ sales_count: number;
325
+ has_machine: boolean;
326
+ has_buy_guard: boolean;
327
+ has_um_contact: boolean;
328
+ arbitrations_count: number;
329
+ };
330
+ risk_score?: {
331
+ advice: string[];
332
+ level: "low" | "medium_low" | "medium_high" | "high";
333
+ total: number;
334
+ red_flags: string[];
335
+ dimensions: {
336
+ name: "fund" | "workflow" | "trust" | "behavior";
337
+ score: number;
338
+ max_score: number;
339
+ checks: {
340
+ description: string;
341
+ id: string;
342
+ dimension: "fund" | "workflow" | "trust" | "behavior";
343
+ weight: number;
344
+ passed: boolean;
345
+ advice?: string | undefined;
346
+ }[];
347
+ }[];
348
+ } | undefined;
349
+ info_puzzle?: {
350
+ completeness: number;
351
+ gaps: string[];
352
+ assembled_at: number;
353
+ } | undefined;
354
+ };
355
+ }, {
356
+ result: {
357
+ trust_score: {
358
+ score: number;
359
+ summary: string;
360
+ warnings: string[];
361
+ level: "high_risk" | "caution" | "moderate" | "trusted";
362
+ breakdown: {
363
+ description: string;
364
+ score: number;
365
+ maxScore: number;
366
+ humanReadable: string;
367
+ }[];
368
+ };
369
+ service_id: string;
370
+ order_amount: string;
371
+ depth: "browse" | "evaluate" | "preorder";
372
+ service_name: string;
373
+ service_basics: {
374
+ bPublished: boolean;
375
+ bPaused: boolean;
376
+ sales_count: number;
377
+ has_machine: boolean;
378
+ has_buy_guard: boolean;
379
+ has_um_contact: boolean;
380
+ arbitrations_count: number;
381
+ };
382
+ risk_score?: {
383
+ advice: string[];
384
+ level: "low" | "medium_low" | "medium_high" | "high";
385
+ total: number;
386
+ red_flags: string[];
387
+ dimensions: {
388
+ name: "fund" | "workflow" | "trust" | "behavior";
389
+ score: number;
390
+ max_score: number;
391
+ checks: {
392
+ description: string;
393
+ id: string;
394
+ dimension: "fund" | "workflow" | "trust" | "behavior";
395
+ weight: number;
396
+ passed: boolean;
397
+ advice?: string | undefined;
398
+ }[];
399
+ }[];
400
+ } | undefined;
401
+ info_puzzle?: {
402
+ completeness: number;
403
+ gaps: string[];
404
+ assembled_at: number;
405
+ } | undefined;
406
+ };
407
+ }>;