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
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Changelog

## 0.5.1 (2025-10-24)

- Add ability for agents and clients to provide information about their implementation
- Fix incorrectly serialized `_meta` field on `SetSessionModeResponse

## 0.5.0 (2025-10-24)

- Provide access to an `AbortSignal` and `closed` promise on connections so you can wait for the connection to close and handle any other cleanup tasks you need for a graceful shutdown. https://github.com/agentclientprotocol/typescript-sdk/pull/11
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@agentclientprotocol/sdk",
"version": "0.5.0",
"version": "0.5.1",
"publishConfig": {
"access": "public"
},
Expand Down
43 changes: 42 additions & 1 deletion schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -958,6 +958,25 @@
"required": ["name", "value"],
"type": "object"
},
"Implementation": {
"description": "Describes the name and version of an MCP implementation, with an optional\ntitle for UI representation.",
"properties": {
"name": {
"description": "Intended for programmatic or logical use, but can be used as a display\nname fallback if title isn’t present.",
"type": "string"
},
"title": {
"description": "Intended for UI and end-user contexts — optimized to be human-readable\nand easily understood.\n\nIf not provided, the name should be used for display.",
"type": ["string", "null"]
},
"version": {
"description": "Version of the implementation. Can be displayed to the user or used\nfor debugging or metrics purposes.",
"type": "string"
}
},
"required": ["name", "version"],
"type": "object"
},
"InitializeRequest": {
"description": "Request parameters for the initialize method.\n\nSent by the client to establish connection and negotiate capabilities.\n\nSee protocol docs: [Initialization](https://agentclientprotocol.com/protocol/initialization)",
"properties": {
Expand All @@ -975,6 +994,17 @@
},
"description": "Capabilities supported by the client."
},
"clientInfo": {
"anyOf": [
{
"$ref": "#/$defs/Implementation"
},
{
"type": "null"
}
],
"description": "Information about the Client name and version sent to the Agent.\n\nNote: in future versions of the protocol, this will be required."
},
"protocolVersion": {
"$ref": "#/$defs/ProtocolVersion",
"description": "The latest protocol version supported by the client."
Expand Down Expand Up @@ -1007,6 +1037,17 @@
},
"description": "Capabilities supported by the agent."
},
"agentInfo": {
"anyOf": [
{
"$ref": "#/$defs/Implementation"
},
{
"type": "null"
}
],
"description": "Information about the Agent name and version sent to the Client.\n\nNote: in future versions of the protocol, this will be required."
},
"authMethods": {
"default": [],
"description": "Authentication methods supported by the agent.",
Expand Down Expand Up @@ -2050,7 +2091,7 @@
"SetSessionModeResponse": {
"description": "Response to `session/set_mode` method.",
"properties": {
"meta": true
"_meta": true
},
"type": "object",
"x-method": "session/set_mode",
Expand Down
2 changes: 1 addition & 1 deletion scripts/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { generate } from "ts-to-zod";
import * as fs from "fs/promises";
import { dirname } from "path";

const CURRENT_SCHEMA_RELEASE = "v0.5.0";
const CURRENT_SCHEMA_RELEASE = "v0.6.2";

await downloadSchemas(CURRENT_SCHEMA_RELEASE);

Expand Down
48 changes: 46 additions & 2 deletions src/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -870,6 +870,12 @@ export interface InitializeResponse {
[k: string]: unknown;
};
agentCapabilities?: AgentCapabilities;
/**
* Information about the Agent name and version sent to the Client.
*
* Note: in future versions of the protocol, this will be required.
*/
agentInfo?: Implementation | null;
/**
* Authentication methods supported by the agent.
*/
Expand Down Expand Up @@ -944,6 +950,29 @@ export interface PromptCapabilities {
*/
image?: boolean;
}
/**
* Describes the name and version of an MCP implementation, with an optional
* title for UI representation.
*/
export interface Implementation {
/**
* Intended for programmatic or logical use, but can be used as a display
* name fallback if title isn’t present.
*/
name: string;
/**
* Intended for UI and end-user contexts — optimized to be human-readable
* and easily understood.
*
* If not provided, the name should be used for display.
*/
title?: string | null;
/**
* Version of the implementation. Can be displayed to the user or used
* for debugging or metrics purposes.
*/
version: string;
}
/**
* Describes an available authentication method.
*/
Expand Down Expand Up @@ -1125,7 +1154,7 @@ export interface LoadSessionResponse {
* Response to `session/set_mode` method.
*/
export interface SetSessionModeResponse {
meta?: unknown;
_meta?: unknown;
}
/**
* Response from processing a user prompt.
Expand Down Expand Up @@ -1707,6 +1736,12 @@ export interface InitializeRequest {
[k: string]: unknown;
};
clientCapabilities?: ClientCapabilities;
/**
* Information about the Client name and version sent to the Agent.
*
* Note: in future versions of the protocol, this will be required.
*/
clientInfo?: Implementation | null;
/**
* The latest protocol version supported by the client.
*/
Expand Down Expand Up @@ -2284,7 +2319,7 @@ export const authenticateResponseSchema = z.object({

/** @internal */
export const setSessionModeResponseSchema = z.object({
meta: z.unknown().optional(),
_meta: z.unknown().optional(),
});

/** @internal */
Expand Down Expand Up @@ -2516,6 +2551,13 @@ export const envVariableSchema = z.object({
value: z.string(),
});

/** @internal */
export const implementationSchema = z.object({
name: z.string(),
title: z.string().optional().nullable(),
version: z.string(),
});

/** @internal */
export const authMethodSchema = z.object({
_meta: z.record(z.unknown()).optional(),
Expand Down Expand Up @@ -2798,6 +2840,7 @@ export const requestSchema = z.object({
export const initializeResponseSchema = z.object({
_meta: z.record(z.unknown()).optional(),
agentCapabilities: agentCapabilitiesSchema.optional(),
agentInfo: implementationSchema.optional().nullable(),
authMethods: z.array(authMethodSchema).optional(),
protocolVersion: z.number(),
});
Expand Down Expand Up @@ -3005,6 +3048,7 @@ export const sessionNotificationSchema = z.object({
export const initializeRequestSchema = z.object({
_meta: z.record(z.unknown()).optional(),
clientCapabilities: clientCapabilitiesSchema.optional(),
clientInfo: implementationSchema.optional().nullable(),
protocolVersion: z.number(),
});

Expand Down