Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 70 additions & 1 deletion schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -3697,7 +3697,7 @@
"const": "model"
},
{
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nModel-related configuration parameter.",
"description": "Model-related configuration parameter.",
"type": "string",
"const": "model_config"
},
Expand Down Expand Up @@ -5856,6 +5856,18 @@
"type": "boolean",
"default": false
},
"session": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nSession-related capabilities supported by the client.",
"anyOf": [
{
"$ref": "#/$defs/ClientSessionCapabilities"
},
{
"type": "null"
}
],
"x-deserialize-default-on-error": true
},
"plan": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nWhether the client supports `plan_update` and `plan_removed` session updates.\n\nOptional. Omitted means the client does not advertise support.\nSupplying `{}` means the client can receive both update types.",
"anyOf": [
Expand Down Expand Up @@ -5940,6 +5952,63 @@
}
}
},
"ClientSessionCapabilities": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nSession-related capabilities supported by the client.",
"type": "object",
"properties": {
"configOptions": {
"description": "Config option capabilities supported by the client.\n\nOmitted or `null` means the client does not advertise support for any\nconfig option extensions.",
"anyOf": [
{
"$ref": "#/$defs/SessionConfigOptionsCapabilities"
},
{
"type": "null"
}
],
"x-deserialize-default-on-error": true
},
"_meta": {
"description": "The _meta property is reserved by ACP to allow clients and agents to attach additional\nmetadata to their interactions. Implementations MUST NOT make assumptions about values at\nthese keys.\n\nSee protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)",
"type": ["object", "null"],
"additionalProperties": true
}
}
},
"SessionConfigOptionsCapabilities": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nSession configuration option capabilities supported by the client.",
"type": "object",
"properties": {
"boolean": {
"description": "Whether the client supports boolean session configuration options.\n\nOmitted or `null` means the client does not advertise support.\nSupplying `{}` means agents may include `type: \"boolean\"` entries in\n`configOptions`, and the client may send `session/set_config_option`\nrequests with `type: \"boolean\"` and a boolean `value`.",
"anyOf": [
{
"$ref": "#/$defs/BooleanConfigOptionCapabilities"
},
{
"type": "null"
}
],
"x-deserialize-default-on-error": true
},
"_meta": {
"description": "The _meta property is reserved by ACP to allow clients and agents to attach additional\nmetadata to their interactions. Implementations MUST NOT make assumptions about values at\nthese keys.\n\nSee protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)",
"type": ["object", "null"],
"additionalProperties": true
}
}
},
"BooleanConfigOptionCapabilities": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nCapabilities for boolean session configuration options.\n\nSupplying `{}` means the client supports boolean session configuration options.",
"type": "object",
"properties": {
"_meta": {
"description": "The _meta property is reserved by ACP to allow clients and agents to attach additional\nmetadata to their interactions. Implementations MUST NOT make assumptions about values at\nthese keys.\n\nSee protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)",
"type": ["object", "null"],
"additionalProperties": true
}
}
},
"PlanCapabilities": {
"description": "**UNSTABLE**\n\nThis capability is not part of the spec yet, and may be removed or changed at any point.\n\nCapabilities for receiving `plan_update` and `plan_removed` session updates.",
"type": "object",
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import * as fs from "fs/promises";
import { dirname } from "path";
import * as prettier from "prettier";

const CURRENT_SCHEMA_RELEASE = "schema-v1.14.0";
const CURRENT_SCHEMA_RELEASE = "schema-v1.16.0";

await main();

Expand Down
3 changes: 3 additions & 0 deletions src/schema/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export type {
AvailableCommandInput,
AvailableCommandsUpdate,
BlobResourceContents,
BooleanConfigOptionCapabilities,
BooleanPropertySchema,
CancelNotification,
CancelRequestNotification,
Expand All @@ -30,6 +31,7 @@ export type {
ClientNotification,
ClientRequest,
ClientResponse,
ClientSessionCapabilities,
CloseNesRequest,
CloseNesResponse,
CloseSessionRequest,
Expand Down Expand Up @@ -203,6 +205,7 @@ export type {
SessionConfigId,
SessionConfigOption,
SessionConfigOptionCategory,
SessionConfigOptionsCapabilities,
SessionConfigSelect,
SessionConfigSelectGroup,
SessionConfigSelectOption,
Expand Down
94 changes: 94 additions & 0 deletions src/schema/types.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4403,6 +4403,16 @@ export type ClientCapabilities = {
* Whether the Client support all `terminal*` methods.
*/
terminal?: boolean;
/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Session-related capabilities supported by the client.
*
* @experimental
*/
session?: ClientSessionCapabilities | null;
/**
* **UNSTABLE**
*
Expand Down Expand Up @@ -4497,6 +4507,90 @@ export type FileSystemCapabilities = {
} | null;
};

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Session-related capabilities supported by the client.
*
* @experimental
*/
export type ClientSessionCapabilities = {
/**
* Config option capabilities supported by the client.
*
* Omitted or `null` means the client does not advertise support for any
* config option extensions.
*/
configOptions?: SessionConfigOptionsCapabilities | null;
/**
* The _meta property is reserved by ACP to allow clients and agents to attach additional
* metadata to their interactions. Implementations MUST NOT make assumptions about values at
* these keys.
*
* See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
*/
_meta?: {
[key: string]: unknown;
} | null;
};

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Session configuration option capabilities supported by the client.
*
* @experimental
*/
export type SessionConfigOptionsCapabilities = {
/**
* Whether the client supports boolean session configuration options.
*
* Omitted or `null` means the client does not advertise support.
* Supplying `{}` means agents may include `type: "boolean"` entries in
* `configOptions`, and the client may send `session/set_config_option`
* requests with `type: "boolean"` and a boolean `value`.
*/
boolean?: BooleanConfigOptionCapabilities | null;
/**
* The _meta property is reserved by ACP to allow clients and agents to attach additional
* metadata to their interactions. Implementations MUST NOT make assumptions about values at
* these keys.
*
* See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
*/
_meta?: {
[key: string]: unknown;
} | null;
};

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Capabilities for boolean session configuration options.
*
* Supplying `{}` means the client supports boolean session configuration options.
*
* @experimental
*/
export type BooleanConfigOptionCapabilities = {
/**
* The _meta property is reserved by ACP to allow clients and agents to attach additional
* metadata to their interactions. Implementations MUST NOT make assumptions about values at
* these keys.
*
* See protocol docs: [Extensibility](https://agentclientprotocol.com/protocol/extensibility)
*/
_meta?: {
[key: string]: unknown;
} | null;
};

/**
* **UNSTABLE**
*
Expand Down
53 changes: 53 additions & 0 deletions src/schema/zod.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2446,6 +2446,55 @@ export const zFileSystemCapabilities = z.object({
_meta: z.record(z.string(), z.unknown()).nullish(),
});

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Capabilities for boolean session configuration options.
*
* Supplying `{}` means the client supports boolean session configuration options.
*
* @experimental
*/
export const zBooleanConfigOptionCapabilities = z.object({
_meta: z.record(z.string(), z.unknown()).nullish(),
});

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Session configuration option capabilities supported by the client.
*
* @experimental
*/
export const zSessionConfigOptionsCapabilities = z.object({
boolean: defaultOnError(
zBooleanConfigOptionCapabilities.nullish(),
() => undefined,
),
_meta: z.record(z.string(), z.unknown()).nullish(),
});

/**
* **UNSTABLE**
*
* This capability is not part of the spec yet, and may be removed or changed at any point.
*
* Session-related capabilities supported by the client.
*
* @experimental
*/
export const zClientSessionCapabilities = z.object({
configOptions: defaultOnError(
zSessionConfigOptionsCapabilities.nullish(),
() => undefined,
),
_meta: z.record(z.string(), z.unknown()).nullish(),
});

/**
* **UNSTABLE**
*
Expand Down Expand Up @@ -2565,6 +2614,10 @@ export const zClientCapabilities = z.object({
.optional()
.default({ readTextFile: false, writeTextFile: false }),
terminal: z.boolean().optional().default(false),
session: defaultOnError(
zClientSessionCapabilities.nullish(),
() => undefined,
),
plan: defaultOnError(zPlanCapabilities.nullish(), () => undefined),
auth: zAuthCapabilities.optional().default({ terminal: false }),
elicitation: defaultOnError(
Expand Down