@harness-control/protocol 0.4.0 → 0.4.2

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 CHANGED
@@ -14,3 +14,13 @@ const message = parseHcpMessage(JSON.parse(wireMessage));
14
14
  Use `@harness-control/protocol/schema.json` for validators in Python or other languages. Use `@harness-control/sdk` for app-side commands and request correlation, and `@harness-control/runner` on the local machine.
15
15
 
16
16
  The package includes `hcp-protocol-conformance` and conformance fixtures. See [HCP documentation](https://github.com/qazisaad/harness-control-protocol#readme) for wire semantics and compatibility. Package versions and the wire protocol version (`hcp.v0`) are separate.
17
+
18
+ ### MCP review extension v1
19
+
20
+ HCP owns `io.harness-control/review-v1`. Tool metadata under this key contains a policy (`always`, or `argument` with a name and allowed values). Call metadata under the same key contains `{request_id, action_json}`. These are review hints and a bound grant, not independent authorization: the control plane still validates its current user, tool policy, lease, decision and dispatch claim.
21
+
22
+ Import `mcpReviewActionSchema`, `mcpReviewGrantSchema`, `mcpReviewPolicySchema`, `mcpReviewActionBytes`, and `hashMcpReviewAction` from `@harness-control/protocol`. Action JSON is a closed `{kind: "mcp_tool", attachment_name, tool_name, arguments}` object. The immutable action string is limited to 65,536 UTF-8 bytes; the hash is lowercase hexadecimal SHA-256 of those exact bytes, without whitespace or Unicode normalization. Do not parse and reserialize it before hashing or forwarding.
23
+
24
+ Non-TypeScript consumers use `@harness-control/protocol/mcp-review.json` and the shared `mcp-review-fixtures.json`. In addition to JSON Schema validation, enforce the manifest's UTF-8 byte limit and validate the grant's embedded action JSON against the action schema. The versioned key intentionally has no application-specific alias.
25
+
26
+ Durable continuation is an adapter capability (`durableMcpContinuation: true`), not a restriction in the persisted operation contract. Only adapters that can restore their native execution context should declare it. The built-in Codex adapter currently does; other built-ins do not. Application authorization and supported-provider policy remain the control plane's responsibility. See `examples/mcp-review-consumer.mjs` for approval and restart recovery using public APIs with an independent adapter.
@@ -58,8 +58,8 @@ export declare const accountUsageUnavailableSchema: z.ZodObject<{
58
58
  observed_at: z.ZodISODateTime;
59
59
  reason: z.ZodEnum<{
60
60
  disabled: "disabled";
61
- unsupported: "unsupported";
62
61
  unauthenticated: "unauthenticated";
62
+ unsupported: "unsupported";
63
63
  not_applicable: "not_applicable";
64
64
  timeout: "timeout";
65
65
  provider_error: "provider_error";
@@ -101,8 +101,8 @@ export declare const accountUsageObservationSchema: z.ZodDiscriminatedUnion<[z.Z
101
101
  observed_at: z.ZodISODateTime;
102
102
  reason: z.ZodEnum<{
103
103
  disabled: "disabled";
104
- unsupported: "unsupported";
105
104
  unauthenticated: "unauthenticated";
105
+ unsupported: "unsupported";
106
106
  not_applicable: "not_applicable";
107
107
  timeout: "timeout";
108
108
  provider_error: "provider_error";
@@ -151,8 +151,8 @@ export declare const accountProviderReadingSchema: z.ZodObject<{
151
151
  observed_at: z.ZodISODateTime;
152
152
  reason: z.ZodEnum<{
153
153
  disabled: "disabled";
154
- unsupported: "unsupported";
155
154
  unauthenticated: "unauthenticated";
155
+ unsupported: "unsupported";
156
156
  not_applicable: "not_applicable";
157
157
  timeout: "timeout";
158
158
  provider_error: "provider_error";
@@ -201,8 +201,8 @@ export declare const hcpAccountsSnapshotPayloadSchema: z.ZodObject<{
201
201
  observed_at: z.ZodISODateTime;
202
202
  reason: z.ZodEnum<{
203
203
  disabled: "disabled";
204
- unsupported: "unsupported";
205
204
  unauthenticated: "unauthenticated";
205
+ unsupported: "unsupported";
206
206
  not_applicable: "not_applicable";
207
207
  timeout: "timeout";
208
208
  provider_error: "provider_error";
@@ -250,8 +250,8 @@ export declare const accountSourceStateSchema: z.ZodObject<{
250
250
  observed_at: z.ZodISODateTime;
251
251
  reason: z.ZodEnum<{
252
252
  disabled: "disabled";
253
- unsupported: "unsupported";
254
253
  unauthenticated: "unauthenticated";
254
+ unsupported: "unsupported";
255
255
  not_applicable: "not_applicable";
256
256
  timeout: "timeout";
257
257
  provider_error: "provider_error";
@@ -9,4 +9,6 @@ const schemaJson = `${JSON.stringify(createHcpMessageJsonSchema(), null, 2)}\n`;
9
9
  await mkdir(dirname(outputPath), { recursive: true });
10
10
  await writeFile(outputPath, schemaJson, "utf8");
11
11
  process.stdout.write(`${outputPath}\n`);
12
+ const { createMcpReviewContract } = await import("../mcp-review.js");
13
+ await writeFile(fileURLToPath(new URL("../../schemas/mcp-review.json", import.meta.url)), `${JSON.stringify(createMcpReviewContract(), null, 2)}\n`, "utf8");
12
14
  //# sourceMappingURL=generate-json-schema.js.map
package/dist/index.d.ts CHANGED
@@ -6788,4 +6788,5 @@ export declare function parseLocalActionErrorPayload(input: unknown): LocalActio
6788
6788
  export declare function parseHcpHarnessEventPayload(input: unknown): HcpHarnessEventPayload;
6789
6789
  export { HcpSessionEventReducer, type HcpEventApplyResult, type HcpSnapshotApplyResult, } from "./session-reducer.js";
6790
6790
  export * from "./pairing.js";
6791
+ export * from "./mcp-review.js";
6791
6792
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -1462,6 +1462,7 @@ const inputRequestedEventDataSchema = z
1462
1462
  turn_id: nonEmptyStringSchema,
1463
1463
  prompt: z.string(),
1464
1464
  input_kind: z.enum(["text", "choice", "multi_choice", "form"]),
1465
+ form_schema: z.record(z.string(), z.json()).optional(),
1465
1466
  choices: z
1466
1467
  .array(z
1467
1468
  .object({
@@ -1932,4 +1933,5 @@ export function parseHcpHarnessEventPayload(input) {
1932
1933
  }
1933
1934
  export { HcpSessionEventReducer, } from "./session-reducer.js";
1934
1935
  export * from "./pairing.js";
1936
+ export * from "./mcp-review.js";
1935
1937
  //# sourceMappingURL=index.js.map
@@ -26,10 +26,10 @@ function cloneJsonSchema(schema) {
26
26
  function toRootJsonSchema(schema) {
27
27
  return asJsonSchema(z.toJSONSchema(schema), "generated JSON Schema");
28
28
  }
29
- function toEmbeddedJsonSchema(schema) {
29
+ function toEmbeddedJsonSchema(schema, name) {
30
30
  const jsonSchema = cloneJsonSchema(toRootJsonSchema(schema));
31
31
  delete jsonSchema.$schema;
32
- delete jsonSchema.$id;
32
+ jsonSchema.$id = `https://schemas.harness-control.local/${HCP_VERSION}/events/${name}.schema.json`;
33
33
  return jsonSchema;
34
34
  }
35
35
  function hasMessageTypeConst(schema, messageType) {
@@ -74,13 +74,12 @@ function createHarnessEventMessageSchema(baseMessageSchema, payloadSchema) {
74
74
  function createHarnessEventMessageSchemas(baseMessageSchema) {
75
75
  const basePayloadSchema = getObjectProperty(baseMessageSchema, "payload", "harness.event message schema");
76
76
  const knownEventSchemas = KNOWN_HCP_EVENT_TYPES.map((eventType) => {
77
- const dataSchema = toEmbeddedJsonSchema(knownHcpEventDataSchemas[eventType]);
77
+ const dataSchema = toEmbeddedJsonSchema(knownHcpEventDataSchemas[eventType], eventType);
78
78
  const payloadSchema = createHarnessEventPayloadSchema(basePayloadSchema, createEventTypeSchema(eventType), dataSchema, eventType.startsWith("local_capability.action."));
79
79
  return createHarnessEventMessageSchema(baseMessageSchema, payloadSchema);
80
80
  });
81
- const extensionEventDataSchema = toEmbeddedJsonSchema(hcpExtensionEventDataSchema);
82
81
  const extensionEventSchemas = ["provider", "extension"].map((prefix) => {
83
- const payloadSchema = createHarnessEventPayloadSchema(basePayloadSchema, createExtensionEventTypeSchema(prefix), extensionEventDataSchema, false);
82
+ const payloadSchema = createHarnessEventPayloadSchema(basePayloadSchema, createExtensionEventTypeSchema(prefix), toEmbeddedJsonSchema(hcpExtensionEventDataSchema, prefix), false);
84
83
  return createHarnessEventMessageSchema(baseMessageSchema, payloadSchema);
85
84
  });
86
85
  return [...knownEventSchemas, ...extensionEventSchemas];
@@ -0,0 +1,54 @@
1
+ import { z } from "zod";
2
+ /** HCP extension v1; unrelated to the upstream MCP protocol version. */
3
+ export declare const MCP_REVIEW_META_KEY = "io.harness-control/review-v1";
4
+ export declare const MCP_REVIEW_MAX_ACTION_BYTES: number;
5
+ export declare const MCP_REVIEW_MAX_REQUEST_ID_LENGTH = 256;
6
+ export declare const mcpReviewActionSchema: z.ZodObject<{
7
+ kind: z.ZodLiteral<"mcp_tool">;
8
+ attachment_name: z.ZodString;
9
+ tool_name: z.ZodString;
10
+ arguments: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
11
+ }, z.core.$strict>;
12
+ export type McpReviewAction = z.infer<typeof mcpReviewActionSchema>;
13
+ export declare function mcpReviewActionBytes(json: string): Uint8Array;
14
+ export declare function hashMcpReviewAction(json: string): Promise<string>;
15
+ export declare const mcpReviewGrantSchema: z.ZodObject<{
16
+ request_id: z.ZodString;
17
+ action_json: z.ZodString;
18
+ }, z.core.$strict>;
19
+ export type McpReviewGrant = z.infer<typeof mcpReviewGrantSchema>;
20
+ export declare const mcpReviewPolicySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
21
+ kind: z.ZodLiteral<"always">;
22
+ }, z.core.$strict>, z.ZodObject<{
23
+ kind: z.ZodLiteral<"argument">;
24
+ argument: z.ZodString;
25
+ values: z.ZodArray<z.ZodString>;
26
+ }, z.core.$strict>], "kind">;
27
+ export type McpReviewPolicy = z.infer<typeof mcpReviewPolicySchema>;
28
+ /** JSON Schema consumers must also enforce the embedded action and UTF-8 limit. */
29
+ export declare function createMcpReviewContract(): {
30
+ version: number;
31
+ metadata_key: string;
32
+ max_action_bytes: number;
33
+ hashing: string;
34
+ schemas: {
35
+ action: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
36
+ kind: z.ZodLiteral<"mcp_tool">;
37
+ attachment_name: z.ZodString;
38
+ tool_name: z.ZodString;
39
+ arguments: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
40
+ }, z.core.$strict>>;
41
+ grant: z.core.ZodStandardJSONSchemaPayload<z.ZodObject<{
42
+ request_id: z.ZodString;
43
+ action_json: z.ZodString;
44
+ }, z.core.$strict>>;
45
+ policy: z.core.ZodStandardJSONSchemaPayload<z.ZodDiscriminatedUnion<[z.ZodObject<{
46
+ kind: z.ZodLiteral<"always">;
47
+ }, z.core.$strict>, z.ZodObject<{
48
+ kind: z.ZodLiteral<"argument">;
49
+ argument: z.ZodString;
50
+ values: z.ZodArray<z.ZodString>;
51
+ }, z.core.$strict>], "kind">>;
52
+ };
53
+ };
54
+ //# sourceMappingURL=mcp-review.d.ts.map
@@ -0,0 +1,44 @@
1
+ import { z } from "zod";
2
+ /** HCP extension v1; unrelated to the upstream MCP protocol version. */
3
+ export const MCP_REVIEW_META_KEY = "io.harness-control/review-v1";
4
+ export const MCP_REVIEW_MAX_ACTION_BYTES = 64 * 1024;
5
+ export const MCP_REVIEW_MAX_REQUEST_ID_LENGTH = 256;
6
+ export const mcpReviewActionSchema = z.object({
7
+ kind: z.literal("mcp_tool"), attachment_name: z.string().min(1),
8
+ tool_name: z.string().min(1), arguments: z.record(z.string(), z.json()),
9
+ }).strict();
10
+ export function mcpReviewActionBytes(json) {
11
+ const bytes = new TextEncoder().encode(json);
12
+ if (bytes.length === 0 || bytes.length > MCP_REVIEW_MAX_ACTION_BYTES)
13
+ throw new Error("MCP review action exceeds its UTF-8 byte limit.");
14
+ mcpReviewActionSchema.parse(JSON.parse(json));
15
+ return bytes;
16
+ }
17
+ export async function hashMcpReviewAction(json) {
18
+ const bytes = mcpReviewActionBytes(json);
19
+ const hash = await crypto.subtle.digest("SHA-256", Uint8Array.from(bytes));
20
+ return Array.from(new Uint8Array(hash), byte => byte.toString(16).padStart(2, "0")).join("");
21
+ }
22
+ export const mcpReviewGrantSchema = z.object({
23
+ request_id: z.string().min(1).max(MCP_REVIEW_MAX_REQUEST_ID_LENGTH),
24
+ action_json: z.string().min(1).max(MCP_REVIEW_MAX_ACTION_BYTES),
25
+ }).strict().superRefine((value, context) => {
26
+ try {
27
+ mcpReviewActionBytes(value.action_json);
28
+ }
29
+ catch {
30
+ context.addIssue({ code: "custom", path: ["action_json"], message: "Invalid or oversized MCP review action." });
31
+ }
32
+ });
33
+ export const mcpReviewPolicySchema = z.discriminatedUnion("kind", [
34
+ z.object({ kind: z.literal("always") }).strict(),
35
+ z.object({ kind: z.literal("argument"), argument: z.string().min(1), values: z.array(z.string().min(1)).min(1) }).strict(),
36
+ ]);
37
+ /** JSON Schema consumers must also enforce the embedded action and UTF-8 limit. */
38
+ export function createMcpReviewContract() {
39
+ return { version: 1, metadata_key: MCP_REVIEW_META_KEY, max_action_bytes: MCP_REVIEW_MAX_ACTION_BYTES,
40
+ hashing: "sha256-exact-utf8-lowercase-hex", schemas: {
41
+ action: z.toJSONSchema(mcpReviewActionSchema), grant: z.toJSONSchema(mcpReviewGrantSchema), policy: z.toJSONSchema(mcpReviewPolicySchema),
42
+ } };
43
+ }
44
+ //# sourceMappingURL=mcp-review.js.map
@@ -0,0 +1,20 @@
1
+ [
2
+ {
3
+ "action_json": "{\"kind\":\"mcp_tool\",\"attachment_name\":\"server\",\"tool_name\":\"write\",\"arguments\":{\"text\":\"é🙂\"}}",
4
+ "valid": true,
5
+ "sha256": "f56beacaa38c8377403c751206b8c1998b45d6cc9a146d84c3e1ede2652ce7c4"
6
+ },
7
+ {
8
+ "action_json": "{\"kind\":\"mcp_tool\",\"attachment_name\":\"server\",\"tool_name\":\"write\",\"arguments\":{}}",
9
+ "valid": true,
10
+ "sha256": "3a571ac3eec173ae039bedda0a3c015b7e3577af92efce1b6c1b6949d06cf8c0"
11
+ },
12
+ {
13
+ "action_json": "{\"kind\":\"mcp_tool\",\"attachment_name\":\"\",\"tool_name\":\"write\",\"arguments\":{}}",
14
+ "valid": false
15
+ },
16
+ {
17
+ "action_json": "{}",
18
+ "valid": false
19
+ }
20
+ ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harness-control/protocol",
3
- "version": "0.4.0",
3
+ "version": "0.4.2",
4
4
  "license": "Apache-2.0",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -24,7 +24,13 @@
24
24
  "./schema.json": {
25
25
  "default": "./schemas/hcp-message.schema.json"
26
26
  },
27
- "./package.json": "./package.json"
27
+ "./package.json": "./package.json",
28
+ "./mcp-review.json": {
29
+ "default": "./schemas/mcp-review.json"
30
+ },
31
+ "./mcp-review-fixtures.json": {
32
+ "default": "./fixtures/mcp-review.json"
33
+ }
28
34
  },
29
35
  "scripts": {
30
36
  "build": "tsc -b && npm run schema:generate",
@@ -56,6 +62,7 @@
56
62
  "README.md",
57
63
  "LICENSE",
58
64
  "schemas",
59
- "fixtures/conformance"
65
+ "fixtures/conformance",
66
+ "fixtures/mcp-review.json"
60
67
  ]
61
68
  }
@@ -7970,7 +7970,8 @@
7970
7970
  "type": "string"
7971
7971
  }
7972
7972
  },
7973
- "additionalProperties": false
7973
+ "additionalProperties": false,
7974
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/session.started.schema.json"
7974
7975
  },
7975
7976
  "raw": {
7976
7977
  "type": "object",
@@ -8163,7 +8164,8 @@
8163
8164
  "type": "string"
8164
8165
  }
8165
8166
  },
8166
- "additionalProperties": false
8167
+ "additionalProperties": false,
8168
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/session.configured.schema.json"
8167
8169
  },
8168
8170
  "raw": {
8169
8171
  "type": "object",
@@ -8356,7 +8358,8 @@
8356
8358
  "type": "string"
8357
8359
  }
8358
8360
  },
8359
- "additionalProperties": false
8361
+ "additionalProperties": false,
8362
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/session.state.changed.schema.json"
8360
8363
  },
8361
8364
  "raw": {
8362
8365
  "type": "object",
@@ -8549,7 +8552,8 @@
8549
8552
  "type": "string"
8550
8553
  }
8551
8554
  },
8552
- "additionalProperties": false
8555
+ "additionalProperties": false,
8556
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/session.exited.schema.json"
8553
8557
  },
8554
8558
  "raw": {
8555
8559
  "type": "object",
@@ -8721,7 +8725,8 @@
8721
8725
  "additionalProperties": false
8722
8726
  }
8723
8727
  },
8724
- "additionalProperties": false
8728
+ "additionalProperties": false,
8729
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.started.schema.json"
8725
8730
  },
8726
8731
  "raw": {
8727
8732
  "type": "object",
@@ -8893,7 +8898,8 @@
8893
8898
  "additionalProperties": false
8894
8899
  }
8895
8900
  },
8896
- "additionalProperties": false
8901
+ "additionalProperties": false,
8902
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.state.changed.schema.json"
8897
8903
  },
8898
8904
  "raw": {
8899
8905
  "type": "object",
@@ -9065,7 +9071,8 @@
9065
9071
  "additionalProperties": false
9066
9072
  }
9067
9073
  },
9068
- "additionalProperties": false
9074
+ "additionalProperties": false,
9075
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.metadata.updated.schema.json"
9069
9076
  },
9070
9077
  "raw": {
9071
9078
  "type": "object",
@@ -9237,7 +9244,8 @@
9237
9244
  "additionalProperties": false
9238
9245
  }
9239
9246
  },
9240
- "additionalProperties": false
9247
+ "additionalProperties": false,
9248
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.token_usage.updated.schema.json"
9241
9249
  },
9242
9250
  "raw": {
9243
9251
  "type": "object",
@@ -9409,7 +9417,8 @@
9409
9417
  "additionalProperties": false
9410
9418
  }
9411
9419
  },
9412
- "additionalProperties": false
9420
+ "additionalProperties": false,
9421
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.realtime.started.schema.json"
9413
9422
  },
9414
9423
  "raw": {
9415
9424
  "type": "object",
@@ -9581,7 +9590,8 @@
9581
9590
  "additionalProperties": false
9582
9591
  }
9583
9592
  },
9584
- "additionalProperties": false
9593
+ "additionalProperties": false,
9594
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.realtime.item_added.schema.json"
9585
9595
  },
9586
9596
  "raw": {
9587
9597
  "type": "object",
@@ -9753,7 +9763,8 @@
9753
9763
  "additionalProperties": false
9754
9764
  }
9755
9765
  },
9756
- "additionalProperties": false
9766
+ "additionalProperties": false,
9767
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.realtime.audio_delta.schema.json"
9757
9768
  },
9758
9769
  "raw": {
9759
9770
  "type": "object",
@@ -9925,7 +9936,8 @@
9925
9936
  "additionalProperties": false
9926
9937
  }
9927
9938
  },
9928
- "additionalProperties": false
9939
+ "additionalProperties": false,
9940
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.realtime.error.schema.json"
9929
9941
  },
9930
9942
  "raw": {
9931
9943
  "type": "object",
@@ -10097,7 +10109,8 @@
10097
10109
  "additionalProperties": false
10098
10110
  }
10099
10111
  },
10100
- "additionalProperties": false
10112
+ "additionalProperties": false,
10113
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/thread.realtime.closed.schema.json"
10101
10114
  },
10102
10115
  "raw": {
10103
10116
  "type": "object",
@@ -10250,7 +10263,8 @@
10250
10263
  "type": "string"
10251
10264
  }
10252
10265
  },
10253
- "additionalProperties": false
10266
+ "additionalProperties": false,
10267
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/auth.status.schema.json"
10254
10268
  },
10255
10269
  "raw": {
10256
10270
  "type": "object",
@@ -10403,7 +10417,8 @@
10403
10417
  "type": "string"
10404
10418
  }
10405
10419
  },
10406
- "additionalProperties": false
10420
+ "additionalProperties": false,
10421
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/account.updated.schema.json"
10407
10422
  },
10408
10423
  "raw": {
10409
10424
  "type": "object",
@@ -10556,7 +10571,8 @@
10556
10571
  "type": "string"
10557
10572
  }
10558
10573
  },
10559
- "additionalProperties": false
10574
+ "additionalProperties": false,
10575
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/account.rate_limits.updated.schema.json"
10560
10576
  },
10561
10577
  "raw": {
10562
10578
  "type": "object",
@@ -10751,7 +10767,8 @@
10751
10767
  "additionalProperties": false
10752
10768
  }
10753
10769
  },
10754
- "additionalProperties": false
10770
+ "additionalProperties": false,
10771
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.started.schema.json"
10755
10772
  },
10756
10773
  "raw": {
10757
10774
  "type": "object",
@@ -10990,7 +11007,8 @@
10990
11007
  "required": [
10991
11008
  "final_output"
10992
11009
  ],
10993
- "additionalProperties": false
11010
+ "additionalProperties": false,
11011
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.completed.schema.json"
10994
11012
  },
10995
11013
  "raw": {
10996
11014
  "type": "object",
@@ -11229,7 +11247,8 @@
11229
11247
  "required": [
11230
11248
  "final_output"
11231
11249
  ],
11232
- "additionalProperties": false
11250
+ "additionalProperties": false,
11251
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.failed.schema.json"
11233
11252
  },
11234
11253
  "raw": {
11235
11254
  "type": "object",
@@ -11468,7 +11487,8 @@
11468
11487
  "required": [
11469
11488
  "final_output"
11470
11489
  ],
11471
- "additionalProperties": false
11490
+ "additionalProperties": false,
11491
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.aborted.schema.json"
11472
11492
  },
11473
11493
  "raw": {
11474
11494
  "type": "object",
@@ -11707,7 +11727,8 @@
11707
11727
  "required": [
11708
11728
  "final_output"
11709
11729
  ],
11710
- "additionalProperties": false
11730
+ "additionalProperties": false,
11731
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.cancelled.schema.json"
11711
11732
  },
11712
11733
  "raw": {
11713
11734
  "type": "object",
@@ -11902,7 +11923,8 @@
11902
11923
  "additionalProperties": false
11903
11924
  }
11904
11925
  },
11905
- "additionalProperties": false
11926
+ "additionalProperties": false,
11927
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.plan.updated.schema.json"
11906
11928
  },
11907
11929
  "raw": {
11908
11930
  "type": "object",
@@ -12097,7 +12119,8 @@
12097
12119
  "additionalProperties": false
12098
12120
  }
12099
12121
  },
12100
- "additionalProperties": false
12122
+ "additionalProperties": false,
12123
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.proposed.delta.schema.json"
12101
12124
  },
12102
12125
  "raw": {
12103
12126
  "type": "object",
@@ -12292,7 +12315,8 @@
12292
12315
  "additionalProperties": false
12293
12316
  }
12294
12317
  },
12295
- "additionalProperties": false
12318
+ "additionalProperties": false,
12319
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.proposed.completed.schema.json"
12296
12320
  },
12297
12321
  "raw": {
12298
12322
  "type": "object",
@@ -12487,7 +12511,8 @@
12487
12511
  "additionalProperties": false
12488
12512
  }
12489
12513
  },
12490
- "additionalProperties": false
12514
+ "additionalProperties": false,
12515
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/turn.diff.updated.schema.json"
12491
12516
  },
12492
12517
  "raw": {
12493
12518
  "type": "object",
@@ -12602,7 +12627,8 @@
12602
12627
  "type": "string"
12603
12628
  }
12604
12629
  },
12605
- "additionalProperties": false
12630
+ "additionalProperties": false,
12631
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/item.started.schema.json"
12606
12632
  },
12607
12633
  "raw": {
12608
12634
  "type": "object",
@@ -12717,7 +12743,8 @@
12717
12743
  "type": "string"
12718
12744
  }
12719
12745
  },
12720
- "additionalProperties": false
12746
+ "additionalProperties": false,
12747
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/item.updated.schema.json"
12721
12748
  },
12722
12749
  "raw": {
12723
12750
  "type": "object",
@@ -12832,7 +12859,8 @@
12832
12859
  "type": "string"
12833
12860
  }
12834
12861
  },
12835
- "additionalProperties": false
12862
+ "additionalProperties": false,
12863
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/item.completed.schema.json"
12836
12864
  },
12837
12865
  "raw": {
12838
12866
  "type": "object",
@@ -12941,7 +12969,8 @@
12941
12969
  "required": [
12942
12970
  "delta"
12943
12971
  ],
12944
- "additionalProperties": false
12972
+ "additionalProperties": false,
12973
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/content.delta.schema.json"
12945
12974
  },
12946
12975
  "raw": {
12947
12976
  "type": "object",
@@ -13050,7 +13079,8 @@
13050
13079
  "required": [
13051
13080
  "delta"
13052
13081
  ],
13053
- "additionalProperties": false
13082
+ "additionalProperties": false,
13083
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/reasoning.delta.schema.json"
13054
13084
  },
13055
13085
  "raw": {
13056
13086
  "type": "object",
@@ -13209,7 +13239,8 @@
13209
13239
  "additionalProperties": false
13210
13240
  }
13211
13241
  },
13212
- "additionalProperties": false
13242
+ "additionalProperties": false,
13243
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/command.started.schema.json"
13213
13244
  },
13214
13245
  "raw": {
13215
13246
  "type": "object",
@@ -13368,7 +13399,8 @@
13368
13399
  "additionalProperties": false
13369
13400
  }
13370
13401
  },
13371
- "additionalProperties": false
13402
+ "additionalProperties": false,
13403
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/command.completed.schema.json"
13372
13404
  },
13373
13405
  "raw": {
13374
13406
  "type": "object",
@@ -13504,7 +13536,8 @@
13504
13536
  "provider_instance_id",
13505
13537
  "status"
13506
13538
  ],
13507
- "additionalProperties": false
13539
+ "additionalProperties": false,
13540
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.lease.created.schema.json"
13508
13541
  },
13509
13542
  "raw": {
13510
13543
  "type": "object",
@@ -13640,7 +13673,8 @@
13640
13673
  "provider_instance_id",
13641
13674
  "status"
13642
13675
  ],
13643
- "additionalProperties": false
13676
+ "additionalProperties": false,
13677
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.lease.revoked.schema.json"
13644
13678
  },
13645
13679
  "raw": {
13646
13680
  "type": "object",
@@ -13776,7 +13810,8 @@
13776
13810
  "provider_instance_id",
13777
13811
  "status"
13778
13812
  ],
13779
- "additionalProperties": false
13813
+ "additionalProperties": false,
13814
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.lease.expired.schema.json"
13780
13815
  },
13781
13816
  "raw": {
13782
13817
  "type": "object",
@@ -13946,7 +13981,8 @@
13946
13981
  "action",
13947
13982
  "status"
13948
13983
  ],
13949
- "additionalProperties": false
13984
+ "additionalProperties": false,
13985
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.action.started.schema.json"
13950
13986
  },
13951
13987
  "raw": {
13952
13988
  "type": "object",
@@ -14117,7 +14153,8 @@
14117
14153
  "action",
14118
14154
  "status"
14119
14155
  ],
14120
- "additionalProperties": false
14156
+ "additionalProperties": false,
14157
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.action.completed.schema.json"
14121
14158
  },
14122
14159
  "raw": {
14123
14160
  "type": "object",
@@ -14288,7 +14325,8 @@
14288
14325
  "action",
14289
14326
  "status"
14290
14327
  ],
14291
- "additionalProperties": false
14328
+ "additionalProperties": false,
14329
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/local_capability.action.failed.schema.json"
14292
14330
  },
14293
14331
  "raw": {
14294
14332
  "type": "object",
@@ -14448,7 +14486,8 @@
14448
14486
  "additionalProperties": false
14449
14487
  }
14450
14488
  },
14451
- "additionalProperties": false
14489
+ "additionalProperties": false,
14490
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/file_change.started.schema.json"
14452
14491
  },
14453
14492
  "raw": {
14454
14493
  "type": "object",
@@ -14607,7 +14646,8 @@
14607
14646
  "additionalProperties": false
14608
14647
  }
14609
14648
  },
14610
- "additionalProperties": false
14649
+ "additionalProperties": false,
14650
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/file_change.completed.schema.json"
14611
14651
  },
14612
14652
  "raw": {
14613
14653
  "type": "object",
@@ -14766,7 +14806,8 @@
14766
14806
  "required": [
14767
14807
  "tool_name"
14768
14808
  ],
14769
- "additionalProperties": false
14809
+ "additionalProperties": false,
14810
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/mcp_tool.started.schema.json"
14770
14811
  },
14771
14812
  "raw": {
14772
14813
  "type": "object",
@@ -14925,7 +14966,8 @@
14925
14966
  "required": [
14926
14967
  "tool_name"
14927
14968
  ],
14928
- "additionalProperties": false
14969
+ "additionalProperties": false,
14970
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/mcp_tool.completed.schema.json"
14929
14971
  },
14930
14972
  "raw": {
14931
14973
  "type": "object",
@@ -15043,7 +15085,8 @@
15043
15085
  "minLength": 1
15044
15086
  }
15045
15087
  },
15046
- "additionalProperties": false
15088
+ "additionalProperties": false,
15089
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/mcp.status.updated.schema.json"
15047
15090
  },
15048
15091
  "raw": {
15049
15092
  "type": "object",
@@ -15161,7 +15204,8 @@
15161
15204
  "minLength": 1
15162
15205
  }
15163
15206
  },
15164
- "additionalProperties": false
15207
+ "additionalProperties": false,
15208
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/mcp.oauth.completed.schema.json"
15165
15209
  },
15166
15210
  "raw": {
15167
15211
  "type": "object",
@@ -15356,7 +15400,8 @@
15356
15400
  "expires_at",
15357
15401
  "display"
15358
15402
  ],
15359
- "additionalProperties": false
15403
+ "additionalProperties": false,
15404
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/approval.requested.schema.json"
15360
15405
  },
15361
15406
  "raw": {
15362
15407
  "type": "object",
@@ -15497,7 +15542,8 @@
15497
15542
  "decision",
15498
15543
  "actor_id"
15499
15544
  ],
15500
- "additionalProperties": false
15545
+ "additionalProperties": false,
15546
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/approval.resolved.schema.json"
15501
15547
  },
15502
15548
  "raw": {
15503
15549
  "type": "object",
@@ -15619,6 +15665,15 @@
15619
15665
  "form"
15620
15666
  ]
15621
15667
  },
15668
+ "form_schema": {
15669
+ "type": "object",
15670
+ "propertyNames": {
15671
+ "type": "string"
15672
+ },
15673
+ "additionalProperties": {
15674
+ "$ref": "#/$defs/__schema0"
15675
+ }
15676
+ },
15622
15677
  "choices": {
15623
15678
  "type": "array",
15624
15679
  "items": {
@@ -15668,7 +15723,41 @@
15668
15723
  "required",
15669
15724
  "redaction"
15670
15725
  ],
15671
- "additionalProperties": false
15726
+ "additionalProperties": false,
15727
+ "$defs": {
15728
+ "__schema0": {
15729
+ "anyOf": [
15730
+ {
15731
+ "type": "string"
15732
+ },
15733
+ {
15734
+ "type": "number"
15735
+ },
15736
+ {
15737
+ "type": "boolean"
15738
+ },
15739
+ {
15740
+ "type": "null"
15741
+ },
15742
+ {
15743
+ "type": "array",
15744
+ "items": {
15745
+ "$ref": "#/$defs/__schema0"
15746
+ }
15747
+ },
15748
+ {
15749
+ "type": "object",
15750
+ "propertyNames": {
15751
+ "type": "string"
15752
+ },
15753
+ "additionalProperties": {
15754
+ "$ref": "#/$defs/__schema0"
15755
+ }
15756
+ }
15757
+ ]
15758
+ }
15759
+ },
15760
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/input.requested.schema.json"
15672
15761
  },
15673
15762
  "raw": {
15674
15763
  "type": "object",
@@ -15797,7 +15886,8 @@
15797
15886
  "session_id",
15798
15887
  "turn_id"
15799
15888
  ],
15800
- "additionalProperties": false
15889
+ "additionalProperties": false,
15890
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/input.resolved.schema.json"
15801
15891
  },
15802
15892
  "raw": {
15803
15893
  "type": "object",
@@ -15924,7 +16014,8 @@
15924
16014
  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
15925
16015
  }
15926
16016
  },
15927
- "additionalProperties": false
16017
+ "additionalProperties": false,
16018
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/request.opened.schema.json"
15928
16019
  },
15929
16020
  "raw": {
15930
16021
  "type": "object",
@@ -16051,7 +16142,8 @@
16051
16142
  "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
16052
16143
  }
16053
16144
  },
16054
- "additionalProperties": false
16145
+ "additionalProperties": false,
16146
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/request.resolved.schema.json"
16055
16147
  },
16056
16148
  "raw": {
16057
16149
  "type": "object",
@@ -16173,6 +16265,15 @@
16173
16265
  "form"
16174
16266
  ]
16175
16267
  },
16268
+ "form_schema": {
16269
+ "type": "object",
16270
+ "propertyNames": {
16271
+ "type": "string"
16272
+ },
16273
+ "additionalProperties": {
16274
+ "$ref": "#/$defs/__schema0"
16275
+ }
16276
+ },
16176
16277
  "choices": {
16177
16278
  "type": "array",
16178
16279
  "items": {
@@ -16222,7 +16323,41 @@
16222
16323
  "required",
16223
16324
  "redaction"
16224
16325
  ],
16225
- "additionalProperties": false
16326
+ "additionalProperties": false,
16327
+ "$defs": {
16328
+ "__schema0": {
16329
+ "anyOf": [
16330
+ {
16331
+ "type": "string"
16332
+ },
16333
+ {
16334
+ "type": "number"
16335
+ },
16336
+ {
16337
+ "type": "boolean"
16338
+ },
16339
+ {
16340
+ "type": "null"
16341
+ },
16342
+ {
16343
+ "type": "array",
16344
+ "items": {
16345
+ "$ref": "#/$defs/__schema0"
16346
+ }
16347
+ },
16348
+ {
16349
+ "type": "object",
16350
+ "propertyNames": {
16351
+ "type": "string"
16352
+ },
16353
+ "additionalProperties": {
16354
+ "$ref": "#/$defs/__schema0"
16355
+ }
16356
+ }
16357
+ ]
16358
+ }
16359
+ },
16360
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/user_input.requested.schema.json"
16226
16361
  },
16227
16362
  "raw": {
16228
16363
  "type": "object",
@@ -16351,7 +16486,8 @@
16351
16486
  "session_id",
16352
16487
  "turn_id"
16353
16488
  ],
16354
- "additionalProperties": false
16489
+ "additionalProperties": false,
16490
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/user_input.resolved.schema.json"
16355
16491
  },
16356
16492
  "raw": {
16357
16493
  "type": "object",
@@ -16496,7 +16632,8 @@
16496
16632
  "additionalProperties": false
16497
16633
  }
16498
16634
  },
16499
- "additionalProperties": false
16635
+ "additionalProperties": false,
16636
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/task.started.schema.json"
16500
16637
  },
16501
16638
  "raw": {
16502
16639
  "type": "object",
@@ -16641,7 +16778,8 @@
16641
16778
  "additionalProperties": false
16642
16779
  }
16643
16780
  },
16644
- "additionalProperties": false
16781
+ "additionalProperties": false,
16782
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/task.progress.schema.json"
16645
16783
  },
16646
16784
  "raw": {
16647
16785
  "type": "object",
@@ -16786,7 +16924,8 @@
16786
16924
  "additionalProperties": false
16787
16925
  }
16788
16926
  },
16789
- "additionalProperties": false
16927
+ "additionalProperties": false,
16928
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/task.completed.schema.json"
16790
16929
  },
16791
16930
  "raw": {
16792
16931
  "type": "object",
@@ -16935,7 +17074,8 @@
16935
17074
  "additionalProperties": false
16936
17075
  }
16937
17076
  },
16938
- "additionalProperties": false
17077
+ "additionalProperties": false,
17078
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/hook.started.schema.json"
16939
17079
  },
16940
17080
  "raw": {
16941
17081
  "type": "object",
@@ -17084,7 +17224,8 @@
17084
17224
  "additionalProperties": false
17085
17225
  }
17086
17226
  },
17087
- "additionalProperties": false
17227
+ "additionalProperties": false,
17228
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/hook.progress.schema.json"
17088
17229
  },
17089
17230
  "raw": {
17090
17231
  "type": "object",
@@ -17233,7 +17374,8 @@
17233
17374
  "additionalProperties": false
17234
17375
  }
17235
17376
  },
17236
- "additionalProperties": false
17377
+ "additionalProperties": false,
17378
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/hook.completed.schema.json"
17237
17379
  },
17238
17380
  "raw": {
17239
17381
  "type": "object",
@@ -17348,7 +17490,8 @@
17348
17490
  "maximum": 1
17349
17491
  }
17350
17492
  },
17351
- "additionalProperties": false
17493
+ "additionalProperties": false,
17494
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/tool.progress.schema.json"
17352
17495
  },
17353
17496
  "raw": {
17354
17497
  "type": "object",
@@ -17463,7 +17606,8 @@
17463
17606
  "maximum": 1
17464
17607
  }
17465
17608
  },
17466
- "additionalProperties": false
17609
+ "additionalProperties": false,
17610
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/tool.summary.schema.json"
17467
17611
  },
17468
17612
  "raw": {
17469
17613
  "type": "object",
@@ -17573,7 +17717,8 @@
17573
17717
  "type": "string"
17574
17718
  }
17575
17719
  },
17576
- "additionalProperties": false
17720
+ "additionalProperties": false,
17721
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/model.rerouted.schema.json"
17577
17722
  },
17578
17723
  "raw": {
17579
17724
  "type": "object",
@@ -17710,7 +17855,8 @@
17710
17855
  }
17711
17856
  }
17712
17857
  },
17713
- "additionalProperties": false
17858
+ "additionalProperties": false,
17859
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/config.warning.schema.json"
17714
17860
  },
17715
17861
  "raw": {
17716
17862
  "type": "object",
@@ -17847,7 +17993,8 @@
17847
17993
  }
17848
17994
  }
17849
17995
  },
17850
- "additionalProperties": false
17996
+ "additionalProperties": false,
17997
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/deprecation.notice.schema.json"
17851
17998
  },
17852
17999
  "raw": {
17853
18000
  "type": "object",
@@ -18008,7 +18155,8 @@
18008
18155
  }
18009
18156
  }
18010
18157
  },
18011
- "additionalProperties": false
18158
+ "additionalProperties": false,
18159
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/files.persisted.schema.json"
18012
18160
  },
18013
18161
  "raw": {
18014
18162
  "type": "object",
@@ -18147,7 +18295,8 @@
18147
18295
  "cwd",
18148
18296
  "result"
18149
18297
  ],
18150
- "additionalProperties": false
18298
+ "additionalProperties": false,
18299
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/workspace.preflight.completed.schema.json"
18151
18300
  },
18152
18301
  "raw": {
18153
18302
  "type": "object",
@@ -18265,7 +18414,8 @@
18265
18414
  "minimum": 0
18266
18415
  }
18267
18416
  },
18268
- "additionalProperties": false
18417
+ "additionalProperties": false,
18418
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/usage.updated.schema.json"
18269
18419
  },
18270
18420
  "raw": {
18271
18421
  "type": "object",
@@ -18402,7 +18552,8 @@
18402
18552
  }
18403
18553
  }
18404
18554
  },
18405
- "additionalProperties": false
18555
+ "additionalProperties": false,
18556
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/runtime.warning.schema.json"
18406
18557
  },
18407
18558
  "raw": {
18408
18559
  "type": "object",
@@ -18539,7 +18690,8 @@
18539
18690
  }
18540
18691
  }
18541
18692
  },
18542
- "additionalProperties": false
18693
+ "additionalProperties": false,
18694
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/runtime.error.schema.json"
18543
18695
  },
18544
18696
  "raw": {
18545
18697
  "type": "object",
@@ -18648,7 +18800,8 @@
18648
18800
  "additionalProperties": {}
18649
18801
  }
18650
18802
  },
18651
- "additionalProperties": false
18803
+ "additionalProperties": false,
18804
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/provider.schema.json"
18652
18805
  },
18653
18806
  "raw": {
18654
18807
  "type": "object",
@@ -18757,7 +18910,8 @@
18757
18910
  "additionalProperties": {}
18758
18911
  }
18759
18912
  },
18760
- "additionalProperties": false
18913
+ "additionalProperties": false,
18914
+ "$id": "https://schemas.harness-control.local/hcp.v0/events/extension.schema.json"
18761
18915
  },
18762
18916
  "raw": {
18763
18917
  "type": "object",
@@ -0,0 +1,141 @@
1
+ {
2
+ "version": 1,
3
+ "metadata_key": "io.harness-control/review-v1",
4
+ "max_action_bytes": 65536,
5
+ "hashing": "sha256-exact-utf8-lowercase-hex",
6
+ "schemas": {
7
+ "action": {
8
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
9
+ "type": "object",
10
+ "properties": {
11
+ "kind": {
12
+ "type": "string",
13
+ "const": "mcp_tool"
14
+ },
15
+ "attachment_name": {
16
+ "type": "string",
17
+ "minLength": 1
18
+ },
19
+ "tool_name": {
20
+ "type": "string",
21
+ "minLength": 1
22
+ },
23
+ "arguments": {
24
+ "type": "object",
25
+ "propertyNames": {
26
+ "type": "string"
27
+ },
28
+ "additionalProperties": {
29
+ "$ref": "#/$defs/__schema0"
30
+ }
31
+ }
32
+ },
33
+ "required": [
34
+ "kind",
35
+ "attachment_name",
36
+ "tool_name",
37
+ "arguments"
38
+ ],
39
+ "additionalProperties": false,
40
+ "$defs": {
41
+ "__schema0": {
42
+ "anyOf": [
43
+ {
44
+ "type": "string"
45
+ },
46
+ {
47
+ "type": "number"
48
+ },
49
+ {
50
+ "type": "boolean"
51
+ },
52
+ {
53
+ "type": "null"
54
+ },
55
+ {
56
+ "type": "array",
57
+ "items": {
58
+ "$ref": "#/$defs/__schema0"
59
+ }
60
+ },
61
+ {
62
+ "type": "object",
63
+ "propertyNames": {
64
+ "type": "string"
65
+ },
66
+ "additionalProperties": {
67
+ "$ref": "#/$defs/__schema0"
68
+ }
69
+ }
70
+ ]
71
+ }
72
+ }
73
+ },
74
+ "grant": {
75
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
76
+ "type": "object",
77
+ "properties": {
78
+ "request_id": {
79
+ "type": "string",
80
+ "minLength": 1,
81
+ "maxLength": 256
82
+ },
83
+ "action_json": {
84
+ "type": "string",
85
+ "minLength": 1,
86
+ "maxLength": 65536
87
+ }
88
+ },
89
+ "required": [
90
+ "request_id",
91
+ "action_json"
92
+ ],
93
+ "additionalProperties": false
94
+ },
95
+ "policy": {
96
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
97
+ "oneOf": [
98
+ {
99
+ "type": "object",
100
+ "properties": {
101
+ "kind": {
102
+ "type": "string",
103
+ "const": "always"
104
+ }
105
+ },
106
+ "required": [
107
+ "kind"
108
+ ],
109
+ "additionalProperties": false
110
+ },
111
+ {
112
+ "type": "object",
113
+ "properties": {
114
+ "kind": {
115
+ "type": "string",
116
+ "const": "argument"
117
+ },
118
+ "argument": {
119
+ "type": "string",
120
+ "minLength": 1
121
+ },
122
+ "values": {
123
+ "minItems": 1,
124
+ "type": "array",
125
+ "items": {
126
+ "type": "string",
127
+ "minLength": 1
128
+ }
129
+ }
130
+ },
131
+ "required": [
132
+ "kind",
133
+ "argument",
134
+ "values"
135
+ ],
136
+ "additionalProperties": false
137
+ }
138
+ ]
139
+ }
140
+ }
141
+ }