parent
a606fb1790
commit
06a4fd2332
3 changed files with 29 additions and 21 deletions
|
|
@ -1,4 +1,13 @@
|
|||
/* JSON-RPC types */
|
||||
/**
|
||||
* This file is automatically generated from the Model Context Protocol specification.
|
||||
*
|
||||
* Source: https://github.com/modelcontextprotocol/modelcontextprotocol
|
||||
* Pulled from: https://raw.githubusercontent.com/modelcontextprotocol/modelcontextprotocol/main/schema/draft/schema.ts
|
||||
* Last updated from commit: 35fa160caf287a9c48696e3ae452c0645c713669
|
||||
*
|
||||
* DO NOT EDIT THIS FILE MANUALLY. Changes will be overwritten by automated updates.
|
||||
* To update this file, run: npm run fetch:spec-types
|
||||
*//* JSON-RPC types */
|
||||
|
||||
/**
|
||||
* Refers to any valid JSON-RPC object that can be decoded off the wire, or encoded to be sent.
|
||||
|
|
@ -11,7 +20,7 @@ export type JSONRPCMessage =
|
|||
| JSONRPCResponse;
|
||||
|
||||
/** @internal */
|
||||
export const LATEST_PROTOCOL_VERSION = "2025-11-25";
|
||||
export const LATEST_PROTOCOL_VERSION = "DRAFT-2026-v1";
|
||||
/** @internal */
|
||||
export const JSONRPC_VERSION = "2.0";
|
||||
|
||||
|
|
@ -52,7 +61,7 @@ export interface TaskAugmentedRequestParams extends RequestParams {
|
|||
*/
|
||||
export interface RequestParams {
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: {
|
||||
/**
|
||||
|
|
@ -74,7 +83,7 @@ export interface Request {
|
|||
/** @internal */
|
||||
export interface NotificationParams {
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -92,7 +101,7 @@ export interface Notification {
|
|||
*/
|
||||
export interface Result {
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
[key: string]: unknown;
|
||||
|
|
@ -830,7 +839,7 @@ export interface Resource extends BaseMetadata, Icons {
|
|||
size?: number;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -866,7 +875,7 @@ export interface ResourceTemplate extends BaseMetadata, Icons {
|
|||
annotations?: Annotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -889,7 +898,7 @@ export interface ResourceContents {
|
|||
mimeType?: string;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -991,7 +1000,7 @@ export interface Prompt extends BaseMetadata, Icons {
|
|||
arguments?: PromptArgument[];
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1061,7 +1070,7 @@ export interface EmbeddedResource {
|
|||
annotations?: Annotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1289,7 +1298,7 @@ export interface Tool extends BaseMetadata, Icons {
|
|||
annotations?: ToolAnnotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1679,7 +1688,7 @@ export interface SamplingMessage {
|
|||
role: Role;
|
||||
content: SamplingMessageContentBlock | SamplingMessageContentBlock[];
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1756,7 +1765,7 @@ export interface TextContent {
|
|||
annotations?: Annotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1787,7 +1796,7 @@ export interface ImageContent {
|
|||
annotations?: Annotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1818,7 +1827,7 @@ export interface AudioContent {
|
|||
annotations?: Annotations;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1852,7 +1861,7 @@ export interface ToolUseContent {
|
|||
* Optional metadata about the tool use. Clients SHOULD preserve this field when
|
||||
* including tool uses in subsequent sampling requests to enable caching optimizations.
|
||||
*
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -1899,7 +1908,7 @@ export interface ToolResultContent {
|
|||
* Optional metadata about the tool result. Clients SHOULD preserve this field when
|
||||
* including tool results in subsequent sampling requests to enable caching optimizations.
|
||||
*
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -2127,7 +2136,7 @@ export interface Root {
|
|||
name?: string;
|
||||
|
||||
/**
|
||||
* See [General fields: `_meta`](/specification/2025-11-25/basic/index#meta) for notes on `_meta` usage.
|
||||
* See [General fields: `_meta`](/specification/draft/basic/index#meta) for notes on `_meta` usage.
|
||||
*/
|
||||
_meta?: { [key: string]: unknown };
|
||||
}
|
||||
|
|
@ -2575,4 +2584,4 @@ export type ServerResult =
|
|||
| GetTaskResult
|
||||
| GetTaskPayloadResult
|
||||
| ListTasksResult
|
||||
| CancelTaskResult;
|
||||
| CancelTaskResult;
|
||||
|
|
|
|||
|
|
@ -2285,7 +2285,7 @@ describe.each(zodTestMatrix)('$zodVersionLabel', (entry: ZodMatrixEntry) => {
|
|||
|
||||
// Verify we received the notification that was sent while disconnected
|
||||
expect(allText).toContain('Missed while disconnected');
|
||||
}, 15000);
|
||||
}, 10000);
|
||||
});
|
||||
|
||||
// Test onsessionclosed callback
|
||||
|
|
|
|||
|
|
@ -729,7 +729,6 @@ describe('Spec Types', () => {
|
|||
}
|
||||
}
|
||||
|
||||
console.log(missingTests);
|
||||
expect(missingTests).toHaveLength(0);
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue