Replace mcp_core::content types with rmcp::model types (#3500)

This commit is contained in:
Jack Amadeo
2025-07-18 17:23:25 -04:00
committed by GitHub
parent a2309d9436
commit d5291461ca
66 changed files with 867 additions and 856 deletions
+22 -16
View File
@@ -1,8 +1,8 @@
// This file is auto-generated by @hey-api/openapi-ts
export type Annotations = {
audience?: Array<Role> | null;
priority?: number | null;
audience?: Array<Role>;
priority?: number;
timestamp?: string;
};
@@ -22,13 +22,22 @@ export type ConfigResponse = {
config: {};
};
export type Content = (TextContent & {
type: 'text';
}) | (ImageContent & {
type: 'image';
}) | (EmbeddedResource & {
type: 'resource';
});
export type Content = {
text: string;
type: string;
} | {
data: string;
mimeType: string;
type: string;
} | {
resource: ResourceContents;
type: string;
} | {
annotations?: Annotations;
data: string;
mimeType: string;
type: string;
};
export type ContextLengthExceeded = {
msg: string;
@@ -70,7 +79,7 @@ export type CreateScheduleRequest = {
};
export type EmbeddedResource = {
annotations?: Annotations | null;
annotations?: Annotations;
resource: ResourceContents;
};
@@ -186,7 +195,7 @@ export type FrontendToolRequest = {
};
export type ImageContent = {
annotations?: Annotations | null;
annotations?: Annotations;
data: string;
mimeType: string;
};
@@ -338,10 +347,7 @@ export type ResourceContents = {
uri: string;
};
/**
* A wrapper around rmcp::model::Role that implements ToSchema for utoipa
*/
export type Role = 'user' | 'assistant';
export type Role = string;
export type RunNowResponse = {
session_id: string;
@@ -459,7 +465,7 @@ export type SummarizationRequested = {
};
export type TextContent = {
annotations?: Annotations | null;
annotations?: Annotations;
text: string;
};