Skip to content

Commit be047c4

Browse files
committed
fix(mcp): adding passthrough types
1 parent 17b753c commit be047c4

1 file changed

Lines changed: 8 additions & 23 deletions

File tree

packages/types/src/mcp.ts

Lines changed: 8 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -102,31 +102,16 @@ export type McpResourceResponse = {
102102
export type McpToolCallResponse = {
103103
_meta?: Record<string, any> // eslint-disable-line @typescript-eslint/no-explicit-any
104104
content: Array<
105-
| {
106-
type: "text"
107-
text: string
108-
}
109-
| {
110-
type: "image"
111-
data: string
112-
mimeType: string
113-
}
114-
| {
115-
type: "audio"
116-
data: string
117-
mimeType: string
118-
}
119-
| {
120-
type: "resource"
121-
resource: {
122-
uri: string
123-
mimeType?: string
124-
text?: string
125-
blob?: string
126-
}
127-
}
105+
(
106+
| { type: "text"; text: string }
107+
| { type: "image"; data: string; mimeType: string }
108+
| { type: "audio"; data: string; mimeType: string }
109+
| { type: "resource"; resource: { uri: string; mimeType?: string; text?: string; blob?: string } }
110+
| { type: string; [key: string]: unknown }
111+
) & { [key: string]: unknown }
128112
>
129113
isError?: boolean
114+
[key: string]: unknown
130115
}
131116

132117
export type McpErrorEntry = {

0 commit comments

Comments
 (0)