@dexto/server 1.6.20 → 1.6.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/a2a/jsonrpc/methods.cjs +1 -1
- package/dist/a2a/jsonrpc/methods.d.ts +14 -4
- package/dist/a2a/jsonrpc/methods.d.ts.map +1 -1
- package/dist/a2a/jsonrpc/methods.js +1 -1
- package/dist/hono/index.cjs +39 -8
- package/dist/hono/index.d.ts +43 -4531
- package/dist/hono/index.d.ts.map +1 -1
- package/dist/hono/index.js +42 -9
- package/dist/hono/routes/a2a-jsonrpc.d.ts.map +1 -1
- package/dist/hono/routes/a2a-tasks.cjs +158 -32
- package/dist/hono/routes/a2a-tasks.d.ts +1 -502
- package/dist/hono/routes/a2a-tasks.d.ts.map +1 -1
- package/dist/hono/routes/a2a-tasks.js +162 -32
- package/dist/hono/routes/a2a.d.ts.map +1 -1
- package/dist/hono/routes/agents.cjs +410 -329
- package/dist/hono/routes/agents.d.ts +16043 -68
- package/dist/hono/routes/agents.d.ts.map +1 -1
- package/dist/hono/routes/agents.js +418 -330
- package/dist/hono/routes/approvals.cjs +102 -88
- package/dist/hono/routes/approvals.d.ts +2089 -142
- package/dist/hono/routes/approvals.d.ts.map +1 -1
- package/dist/hono/routes/approvals.js +108 -89
- package/dist/hono/routes/dexto-auth.cjs +40 -33
- package/dist/hono/routes/dexto-auth.d.ts +401 -2
- package/dist/hono/routes/dexto-auth.d.ts.map +1 -1
- package/dist/hono/routes/dexto-auth.js +40 -33
- package/dist/hono/routes/discovery.cjs +16 -14
- package/dist/hono/routes/discovery.d.ts +586 -1
- package/dist/hono/routes/discovery.d.ts.map +1 -1
- package/dist/hono/routes/discovery.js +16 -14
- package/dist/hono/routes/greeting.cjs +26 -22
- package/dist/hono/routes/greeting.d.ts +787 -3
- package/dist/hono/routes/greeting.d.ts.map +1 -1
- package/dist/hono/routes/greeting.js +26 -22
- package/dist/hono/routes/health.d.ts +1 -1
- package/dist/hono/routes/key.cjs +60 -52
- package/dist/hono/routes/key.d.ts +1597 -1
- package/dist/hono/routes/key.d.ts.map +1 -1
- package/dist/hono/routes/key.js +60 -52
- package/dist/hono/routes/llm.cjs +381 -348
- package/dist/hono/routes/llm.d.ts +12136 -86
- package/dist/hono/routes/llm.d.ts.map +1 -1
- package/dist/hono/routes/llm.js +385 -348
- package/dist/hono/routes/mcp.cjs +257 -226
- package/dist/hono/routes/mcp.d.ts +6605 -309
- package/dist/hono/routes/mcp.d.ts.map +1 -1
- package/dist/hono/routes/mcp.js +263 -225
- package/dist/hono/routes/memory.cjs +102 -89
- package/dist/hono/routes/memory.d.ts +5368 -4
- package/dist/hono/routes/memory.d.ts.map +1 -1
- package/dist/hono/routes/memory.js +108 -90
- package/dist/hono/routes/messages.cjs +147 -139
- package/dist/hono/routes/messages.d.ts +3900 -11
- package/dist/hono/routes/messages.d.ts.map +1 -1
- package/dist/hono/routes/messages.js +150 -139
- package/dist/hono/routes/models.cjs +106 -64
- package/dist/hono/routes/models.d.ts +2874 -1
- package/dist/hono/routes/models.d.ts.map +1 -1
- package/dist/hono/routes/models.js +108 -64
- package/dist/hono/routes/openrouter.cjs +79 -65
- package/dist/hono/routes/openrouter.d.ts +854 -1
- package/dist/hono/routes/openrouter.d.ts.map +1 -1
- package/dist/hono/routes/openrouter.js +79 -65
- package/dist/hono/routes/prompts.cjs +136 -109
- package/dist/hono/routes/prompts.d.ts +2818 -10
- package/dist/hono/routes/prompts.d.ts.map +1 -1
- package/dist/hono/routes/prompts.js +138 -109
- package/dist/hono/routes/queue.cjs +133 -120
- package/dist/hono/routes/queue.d.ts +5144 -9
- package/dist/hono/routes/queue.d.ts.map +1 -1
- package/dist/hono/routes/queue.js +136 -120
- package/dist/hono/routes/resources.cjs +65 -46
- package/dist/hono/routes/resources.d.ts +1982 -4
- package/dist/hono/routes/resources.d.ts.map +1 -1
- package/dist/hono/routes/resources.js +72 -47
- package/dist/hono/routes/schedules.cjs +233 -226
- package/dist/hono/routes/schedules.d.ts +4198 -22
- package/dist/hono/routes/schedules.d.ts.map +1 -1
- package/dist/hono/routes/schedules.js +233 -226
- package/dist/hono/routes/search.cjs +34 -30
- package/dist/hono/routes/search.d.ts +2835 -12
- package/dist/hono/routes/search.d.ts.map +1 -1
- package/dist/hono/routes/search.js +40 -31
- package/dist/hono/routes/sessions.cjs +403 -396
- package/dist/hono/routes/sessions.d.ts +16582 -27
- package/dist/hono/routes/sessions.d.ts.map +1 -1
- package/dist/hono/routes/sessions.js +407 -397
- package/dist/hono/routes/static.d.ts.map +1 -1
- package/dist/hono/routes/system-prompt.cjs +57 -61
- package/dist/hono/routes/system-prompt.d.ts +1228 -2
- package/dist/hono/routes/system-prompt.d.ts.map +1 -1
- package/dist/hono/routes/system-prompt.js +58 -62
- package/dist/hono/routes/tools.cjs +29 -34
- package/dist/hono/routes/tools.d.ts +1755 -6
- package/dist/hono/routes/tools.d.ts.map +1 -1
- package/dist/hono/routes/tools.js +33 -33
- package/dist/hono/routes/webhooks.cjs +115 -123
- package/dist/hono/routes/webhooks.d.ts +2501 -11
- package/dist/hono/routes/webhooks.d.ts.map +1 -1
- package/dist/hono/routes/webhooks.js +120 -124
- package/dist/hono/routes/workspaces.cjs +84 -79
- package/dist/hono/routes/workspaces.d.ts +2093 -2
- package/dist/hono/routes/workspaces.d.ts.map +1 -1
- package/dist/hono/routes/workspaces.js +89 -80
- package/dist/hono/schemas/responses.cjs +406 -259
- package/dist/hono/schemas/responses.d.ts +1246 -123
- package/dist/hono/schemas/responses.d.ts.map +1 -1
- package/dist/hono/schemas/responses.js +144 -10
- package/dist/hono/types.d.ts +11 -0
- package/dist/hono/types.d.ts.map +1 -1
- package/package.json +7 -7
|
@@ -21,16 +21,23 @@ __export(responses_exports, {
|
|
|
21
21
|
AgentCardSchema: () => import_core4.AgentCardSchema,
|
|
22
22
|
AgentRegistryEntrySchema: () => AgentRegistryEntrySchema,
|
|
23
23
|
ApiErrorResponseSchema: () => ApiErrorResponseSchema,
|
|
24
|
+
BadRequestErrorResponse: () => BadRequestErrorResponse,
|
|
24
25
|
CatalogModelInfoSchema: () => CatalogModelInfoSchema,
|
|
26
|
+
ConflictErrorResponse: () => ConflictErrorResponse,
|
|
25
27
|
ContentPartSchema: () => ContentPartSchema,
|
|
26
28
|
DeleteResponseSchema: () => DeleteResponseSchema,
|
|
27
29
|
ErrorResponseSchema: () => ErrorResponseSchema,
|
|
28
30
|
ExecutionLogSchema: () => ExecutionLogSchema,
|
|
29
31
|
FilePartSchema: () => FilePartSchema,
|
|
32
|
+
ForbiddenErrorResponse: () => ForbiddenErrorResponse,
|
|
30
33
|
HttpServerConfigSchema: () => import_core5.HttpServerConfigSchema,
|
|
31
34
|
ImagePartSchema: () => ImagePartSchema,
|
|
35
|
+
InternalErrorResponse: () => InternalErrorResponse,
|
|
32
36
|
InternalMessageSchema: () => InternalMessageSchema,
|
|
33
37
|
IssueSchema: () => IssueSchema,
|
|
38
|
+
JsonObjectSchema: () => JsonObjectSchema,
|
|
39
|
+
JsonSchemaPropertySchema: () => JsonSchemaPropertySchema,
|
|
40
|
+
JsonValueSchema: () => JsonValueSchema,
|
|
34
41
|
LLMConfigBaseSchema: () => import_core3.LLMConfigBaseSchema,
|
|
35
42
|
LLMConfigResponseSchema: () => LLMConfigResponseSchema,
|
|
36
43
|
LLMConfigSchema: () => LLMConfigSchema,
|
|
@@ -39,7 +46,9 @@ __export(responses_exports, {
|
|
|
39
46
|
MessageSearchResponseSchema: () => MessageSearchResponseSchema,
|
|
40
47
|
ModelFlatSchema: () => ModelFlatSchema,
|
|
41
48
|
ModelStatisticsSchema: () => ModelStatisticsSchema,
|
|
49
|
+
NotFoundErrorResponse: () => NotFoundErrorResponse,
|
|
42
50
|
OkResponseSchema: () => OkResponseSchema,
|
|
51
|
+
PaymentRequiredErrorResponse: () => PaymentRequiredErrorResponse,
|
|
43
52
|
PermissionsConfigSchema: () => import_core6.PermissionsConfigSchema,
|
|
44
53
|
PricingStatusSchema: () => PricingStatusSchema,
|
|
45
54
|
PromptArgumentSchema: () => PromptArgumentSchema,
|
|
@@ -47,6 +56,7 @@ __export(responses_exports, {
|
|
|
47
56
|
PromptInfoSchema: () => PromptInfoSchema,
|
|
48
57
|
PromptSchema: () => PromptSchema,
|
|
49
58
|
ProviderCatalogSchema: () => ProviderCatalogSchema,
|
|
59
|
+
RateLimitErrorResponse: () => RateLimitErrorResponse,
|
|
50
60
|
RequestContentPartSchema: () => RequestContentPartSchema,
|
|
51
61
|
RequestContentSchema: () => RequestContentSchema,
|
|
52
62
|
ResourceConfigSchema: () => import_core7.ResourceConfigSchema,
|
|
@@ -65,10 +75,13 @@ __export(responses_exports, {
|
|
|
65
75
|
StatusResponseSchema: () => StatusResponseSchema,
|
|
66
76
|
StdioServerConfigSchema: () => import_core5.StdioServerConfigSchema,
|
|
67
77
|
TextPartSchema: () => TextPartSchema,
|
|
78
|
+
TimeoutErrorResponse: () => TimeoutErrorResponse,
|
|
68
79
|
TokenUsageSchema: () => TokenUsageSchema,
|
|
69
80
|
ToolCallSchema: () => ToolCallSchema,
|
|
81
|
+
ToolInputSchema: () => ToolInputSchema,
|
|
70
82
|
ToolSchema: () => ToolSchema,
|
|
71
83
|
UIResourcePartSchema: () => UIResourcePartSchema,
|
|
84
|
+
UpstreamErrorResponse: () => UpstreamErrorResponse,
|
|
72
85
|
UsageSummarySchema: () => UsageSummarySchema,
|
|
73
86
|
WebhookSchema: () => WebhookSchema,
|
|
74
87
|
WorkspaceSchema: () => WorkspaceSchema,
|
|
@@ -76,7 +89,7 @@ __export(responses_exports, {
|
|
|
76
89
|
toContentInput: () => toContentInput
|
|
77
90
|
});
|
|
78
91
|
module.exports = __toCommonJS(responses_exports);
|
|
79
|
-
var
|
|
92
|
+
var import_zod_openapi = require("@hono/zod-openapi");
|
|
80
93
|
var import_core = require("@dexto/core");
|
|
81
94
|
var import_core2 = require("@dexto/core");
|
|
82
95
|
var import_core3 = require("@dexto/core");
|
|
@@ -84,69 +97,174 @@ var import_core4 = require("@dexto/core");
|
|
|
84
97
|
var import_core5 = require("@dexto/core");
|
|
85
98
|
var import_core6 = require("@dexto/core");
|
|
86
99
|
var import_core7 = require("@dexto/core");
|
|
87
|
-
const
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
100
|
+
const JsonValueOpenApiPlaceholder = {
|
|
101
|
+
type: "object",
|
|
102
|
+
additionalProperties: true,
|
|
103
|
+
description: "Any JSON-serializable value"
|
|
104
|
+
};
|
|
105
|
+
const JsonValueSchema = import_zod_openapi.z.lazy(
|
|
106
|
+
() => import_zod_openapi.z.union([
|
|
107
|
+
import_zod_openapi.z.string(),
|
|
108
|
+
import_zod_openapi.z.number(),
|
|
109
|
+
import_zod_openapi.z.boolean(),
|
|
110
|
+
import_zod_openapi.z.null(),
|
|
111
|
+
import_zod_openapi.z.array(JsonValueSchema),
|
|
112
|
+
import_zod_openapi.z.record(import_zod_openapi.z.string(), JsonValueSchema)
|
|
113
|
+
])
|
|
114
|
+
).openapi("JsonValue", JsonValueOpenApiPlaceholder).describe("Any JSON-serializable value");
|
|
115
|
+
const JsonObjectSchema = import_zod_openapi.z.record(import_zod_openapi.z.string(), JsonValueSchema).openapi("JsonObject", {
|
|
116
|
+
type: "object",
|
|
117
|
+
additionalProperties: true
|
|
118
|
+
}).describe("JSON object with arbitrary serializable values");
|
|
119
|
+
const JsonSchemaPrimitiveTypeSchema = import_zod_openapi.z.enum(["string", "number", "integer", "boolean", "object", "array"]).describe("JSON Schema primitive type");
|
|
120
|
+
const JsonSchemaEnumValueSchema = import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.number(), import_zod_openapi.z.boolean(), import_zod_openapi.z.null()]).describe("Allowed JSON Schema enum value");
|
|
121
|
+
const JsonSchemaPropertySchema = import_zod_openapi.z.object({
|
|
122
|
+
type: JsonSchemaPrimitiveTypeSchema.optional().describe("Property type"),
|
|
123
|
+
description: import_zod_openapi.z.string().optional().describe("Property description"),
|
|
124
|
+
enum: import_zod_openapi.z.array(JsonSchemaEnumValueSchema).optional().describe("Enum values"),
|
|
125
|
+
default: JsonValueSchema.optional().describe("Default value"),
|
|
126
|
+
format: import_zod_openapi.z.string().optional().describe("JSON Schema format hint")
|
|
127
|
+
}).passthrough().describe("JSON Schema property definition");
|
|
128
|
+
const ToolInputSchema = import_zod_openapi.z.object({
|
|
129
|
+
type: import_zod_openapi.z.literal("object").optional().describe('Schema type, always "object" when present'),
|
|
130
|
+
properties: import_zod_openapi.z.record(import_zod_openapi.z.string(), JsonSchemaPropertySchema).optional().describe("Property definitions"),
|
|
131
|
+
required: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Required property names")
|
|
132
|
+
}).passthrough().describe("JSON Schema for tool input parameters");
|
|
133
|
+
const IssueSchema = import_zod_openapi.z.object({
|
|
134
|
+
code: import_zod_openapi.z.string().describe("Machine-readable issue code"),
|
|
135
|
+
message: import_zod_openapi.z.string().describe("Human-readable issue message"),
|
|
136
|
+
scope: import_zod_openapi.z.string().describe("Domain that produced the issue"),
|
|
137
|
+
type: import_zod_openapi.z.string().describe("Error type used for HTTP status mapping"),
|
|
138
|
+
severity: import_zod_openapi.z.enum(["error", "warning"]).describe("Issue severity"),
|
|
139
|
+
path: import_zod_openapi.z.array(import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.number()])).optional().describe("Optional location for the issue"),
|
|
140
|
+
context: JsonValueSchema.optional().describe("Optional structured issue context")
|
|
95
141
|
}).strict().describe("Structured validation or runtime issue");
|
|
96
|
-
const ApiErrorResponseSchema =
|
|
97
|
-
name:
|
|
98
|
-
message:
|
|
99
|
-
code:
|
|
100
|
-
scope:
|
|
101
|
-
type:
|
|
102
|
-
severity:
|
|
103
|
-
endpoint:
|
|
104
|
-
method:
|
|
105
|
-
traceId:
|
|
106
|
-
recovery:
|
|
107
|
-
context:
|
|
108
|
-
issues:
|
|
109
|
-
errorCount:
|
|
110
|
-
warningCount:
|
|
111
|
-
stack:
|
|
142
|
+
const ApiErrorResponseSchema = import_zod_openapi.z.object({
|
|
143
|
+
name: import_zod_openapi.z.string().optional().describe("Optional error class name"),
|
|
144
|
+
message: import_zod_openapi.z.string().describe("Human-readable error message"),
|
|
145
|
+
code: import_zod_openapi.z.string().optional().describe("Machine-readable error code"),
|
|
146
|
+
scope: import_zod_openapi.z.string().optional().describe("Domain that produced the error"),
|
|
147
|
+
type: import_zod_openapi.z.string().optional().describe("Error type used for HTTP status mapping"),
|
|
148
|
+
severity: import_zod_openapi.z.enum(["error", "warning"]).optional().describe("Optional error severity for lightweight failures"),
|
|
149
|
+
endpoint: import_zod_openapi.z.string().describe("Request path that failed"),
|
|
150
|
+
method: import_zod_openapi.z.string().describe("HTTP method for the failed request"),
|
|
151
|
+
traceId: import_zod_openapi.z.string().optional().describe("Optional trace identifier"),
|
|
152
|
+
recovery: import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.array(import_zod_openapi.z.string())]).optional().describe("Optional recovery guidance"),
|
|
153
|
+
context: JsonValueSchema.optional().describe("Optional structured error context"),
|
|
154
|
+
issues: import_zod_openapi.z.array(IssueSchema).optional().describe("Validation issues when present"),
|
|
155
|
+
errorCount: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of errors"),
|
|
156
|
+
warningCount: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of warnings"),
|
|
157
|
+
stack: import_zod_openapi.z.string().optional().describe("Development-only stack trace")
|
|
112
158
|
}).strict().describe("Standard API error response");
|
|
113
|
-
const
|
|
114
|
-
|
|
115
|
-
|
|
159
|
+
const BadRequestErrorResponse = {
|
|
160
|
+
description: "Validation or request error",
|
|
161
|
+
content: {
|
|
162
|
+
"application/json": {
|
|
163
|
+
schema: ApiErrorResponseSchema
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
};
|
|
167
|
+
const PaymentRequiredErrorResponse = {
|
|
168
|
+
description: "Payment required",
|
|
169
|
+
content: {
|
|
170
|
+
"application/json": {
|
|
171
|
+
schema: ApiErrorResponseSchema
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
};
|
|
175
|
+
const ForbiddenErrorResponse = {
|
|
176
|
+
description: "Forbidden",
|
|
177
|
+
content: {
|
|
178
|
+
"application/json": {
|
|
179
|
+
schema: ApiErrorResponseSchema
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
const NotFoundErrorResponse = {
|
|
184
|
+
description: "Resource not found",
|
|
185
|
+
content: {
|
|
186
|
+
"application/json": {
|
|
187
|
+
schema: ApiErrorResponseSchema
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
};
|
|
191
|
+
const TimeoutErrorResponse = {
|
|
192
|
+
description: "Request timed out",
|
|
193
|
+
content: {
|
|
194
|
+
"application/json": {
|
|
195
|
+
schema: ApiErrorResponseSchema
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
};
|
|
199
|
+
const ConflictErrorResponse = {
|
|
200
|
+
description: "Conflict",
|
|
201
|
+
content: {
|
|
202
|
+
"application/json": {
|
|
203
|
+
schema: ApiErrorResponseSchema
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
const RateLimitErrorResponse = {
|
|
208
|
+
description: "Rate limited",
|
|
209
|
+
content: {
|
|
210
|
+
"application/json": {
|
|
211
|
+
schema: ApiErrorResponseSchema
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
};
|
|
215
|
+
const InternalErrorResponse = {
|
|
216
|
+
description: "Internal server error",
|
|
217
|
+
content: {
|
|
218
|
+
"application/json": {
|
|
219
|
+
schema: ApiErrorResponseSchema
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
};
|
|
223
|
+
const UpstreamErrorResponse = {
|
|
224
|
+
description: "Upstream service failure",
|
|
225
|
+
content: {
|
|
226
|
+
"application/json": {
|
|
227
|
+
schema: ApiErrorResponseSchema
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
};
|
|
231
|
+
const TextPartSchema = import_zod_openapi.z.object({
|
|
232
|
+
type: import_zod_openapi.z.literal("text").describe("Part type: text"),
|
|
233
|
+
text: import_zod_openapi.z.string().describe("Text content")
|
|
116
234
|
}).strict().describe("Text content part");
|
|
117
|
-
const ImagePartSchema =
|
|
118
|
-
type:
|
|
119
|
-
image:
|
|
120
|
-
mimeType:
|
|
235
|
+
const ImagePartSchema = import_zod_openapi.z.object({
|
|
236
|
+
type: import_zod_openapi.z.literal("image").describe("Part type: image"),
|
|
237
|
+
image: import_zod_openapi.z.string().describe("Base64-encoded image data"),
|
|
238
|
+
mimeType: import_zod_openapi.z.string().optional().describe("MIME type of the image")
|
|
121
239
|
}).strict().describe("Image content part");
|
|
122
|
-
const FilePartSchema =
|
|
123
|
-
type:
|
|
124
|
-
data:
|
|
125
|
-
mimeType:
|
|
126
|
-
filename:
|
|
240
|
+
const FilePartSchema = import_zod_openapi.z.object({
|
|
241
|
+
type: import_zod_openapi.z.literal("file").describe("Part type: file"),
|
|
242
|
+
data: import_zod_openapi.z.string().describe("Base64-encoded file data"),
|
|
243
|
+
mimeType: import_zod_openapi.z.string().describe("MIME type of the file"),
|
|
244
|
+
filename: import_zod_openapi.z.string().optional().describe("Optional filename")
|
|
127
245
|
}).strict().describe("File content part");
|
|
128
|
-
const UIResourcePartSchema =
|
|
129
|
-
type:
|
|
130
|
-
uri:
|
|
131
|
-
mimeType:
|
|
132
|
-
content:
|
|
133
|
-
blob:
|
|
134
|
-
metadata:
|
|
135
|
-
title:
|
|
136
|
-
preferredSize:
|
|
137
|
-
width:
|
|
138
|
-
height:
|
|
246
|
+
const UIResourcePartSchema = import_zod_openapi.z.object({
|
|
247
|
+
type: import_zod_openapi.z.literal("ui-resource").describe("Part type: ui-resource"),
|
|
248
|
+
uri: import_zod_openapi.z.string().describe("URI identifying the UI resource (must start with ui://)"),
|
|
249
|
+
mimeType: import_zod_openapi.z.string().describe("MIME type: text/html, text/uri-list, or application/vnd.mcp-ui.remote-dom"),
|
|
250
|
+
content: import_zod_openapi.z.string().optional().describe("Inline HTML content or URL"),
|
|
251
|
+
blob: import_zod_openapi.z.string().optional().describe("Base64-encoded content (alternative to content)"),
|
|
252
|
+
metadata: import_zod_openapi.z.object({
|
|
253
|
+
title: import_zod_openapi.z.string().optional().describe("Display title for the UI resource"),
|
|
254
|
+
preferredSize: import_zod_openapi.z.object({
|
|
255
|
+
width: import_zod_openapi.z.number().describe("Preferred width in pixels"),
|
|
256
|
+
height: import_zod_openapi.z.number().describe("Preferred height in pixels")
|
|
139
257
|
}).strict().optional().describe("Preferred rendering size")
|
|
140
258
|
}).strict().optional().describe("Optional metadata for the UI resource")
|
|
141
259
|
}).strict().describe("UI Resource content part for MCP-UI interactive components");
|
|
142
|
-
const ContentPartSchema =
|
|
260
|
+
const ContentPartSchema = import_zod_openapi.z.discriminatedUnion("type", [
|
|
143
261
|
TextPartSchema,
|
|
144
262
|
ImagePartSchema,
|
|
145
263
|
FilePartSchema,
|
|
146
264
|
UIResourcePartSchema
|
|
147
265
|
]).describe("Message content part (text, image, file, or UI resource)");
|
|
148
|
-
const RequestContentPartSchema =
|
|
149
|
-
const RequestContentSchema =
|
|
266
|
+
const RequestContentPartSchema = import_zod_openapi.z.discriminatedUnion("type", [TextPartSchema, ImagePartSchema, FilePartSchema]).describe("Request message content part (text, image, or file)");
|
|
267
|
+
const RequestContentSchema = import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.array(RequestContentPartSchema)]).describe("Message content - string for text, or ContentPart[] for multimodal");
|
|
150
268
|
function serializeBinaryValue(value) {
|
|
151
269
|
if (typeof value === "string") {
|
|
152
270
|
return value;
|
|
@@ -217,300 +335,323 @@ function toApiContentPart(part) {
|
|
|
217
335
|
};
|
|
218
336
|
}
|
|
219
337
|
}
|
|
220
|
-
const ToolCallSchema =
|
|
221
|
-
id:
|
|
222
|
-
type:
|
|
223
|
-
function:
|
|
224
|
-
name:
|
|
225
|
-
arguments:
|
|
338
|
+
const ToolCallSchema = import_zod_openapi.z.object({
|
|
339
|
+
id: import_zod_openapi.z.string().describe("Unique identifier for this tool call"),
|
|
340
|
+
type: import_zod_openapi.z.literal("function").describe("Tool call type (currently only function is supported)"),
|
|
341
|
+
function: import_zod_openapi.z.object({
|
|
342
|
+
name: import_zod_openapi.z.string().describe("Name of the function to call"),
|
|
343
|
+
arguments: import_zod_openapi.z.string().describe("Arguments for the function in JSON string format")
|
|
226
344
|
}).strict().describe("Function call details")
|
|
227
345
|
}).strict().describe("Tool call made by the assistant");
|
|
228
|
-
const TokenUsageSchema =
|
|
229
|
-
inputTokens:
|
|
230
|
-
outputTokens:
|
|
231
|
-
reasoningTokens:
|
|
232
|
-
cacheReadTokens:
|
|
233
|
-
cacheWriteTokens:
|
|
234
|
-
totalTokens:
|
|
346
|
+
const TokenUsageSchema = import_zod_openapi.z.object({
|
|
347
|
+
inputTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of input tokens"),
|
|
348
|
+
outputTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of output tokens"),
|
|
349
|
+
reasoningTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of reasoning tokens"),
|
|
350
|
+
cacheReadTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of cache read tokens"),
|
|
351
|
+
cacheWriteTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Number of cache write tokens"),
|
|
352
|
+
totalTokens: import_zod_openapi.z.number().int().nonnegative().optional().describe("Total tokens used")
|
|
235
353
|
}).strict().describe("Token usage accounting");
|
|
236
|
-
const PricingStatusSchema =
|
|
237
|
-
const InternalMessageSchema =
|
|
238
|
-
id:
|
|
239
|
-
role:
|
|
240
|
-
timestamp:
|
|
241
|
-
content:
|
|
242
|
-
reasoning:
|
|
354
|
+
const PricingStatusSchema = import_zod_openapi.z.enum(import_core.LLM_PRICING_STATUSES).describe("Whether pricing was resolved for this response");
|
|
355
|
+
const InternalMessageSchema = import_zod_openapi.z.object({
|
|
356
|
+
id: import_zod_openapi.z.string().uuid().optional().describe("Unique message identifier (UUID)"),
|
|
357
|
+
role: import_zod_openapi.z.enum(["system", "user", "assistant", "tool"]).describe("Role of the message sender"),
|
|
358
|
+
timestamp: import_zod_openapi.z.number().int().positive().optional().describe("Creation timestamp (Unix ms)"),
|
|
359
|
+
content: import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.null(), import_zod_openapi.z.array(ContentPartSchema)]).describe("Message content (string, null, or array of parts)"),
|
|
360
|
+
reasoning: import_zod_openapi.z.string().optional().describe("Optional model reasoning text"),
|
|
243
361
|
tokenUsage: TokenUsageSchema.optional().describe("Optional token usage accounting"),
|
|
244
|
-
estimatedCost:
|
|
362
|
+
estimatedCost: import_zod_openapi.z.number().nonnegative().optional().describe("Estimated cost in USD for this response"),
|
|
245
363
|
pricingStatus: PricingStatusSchema.optional().describe(
|
|
246
364
|
"Whether pricing was resolved for this response"
|
|
247
365
|
),
|
|
248
|
-
usageScopeId:
|
|
249
|
-
model:
|
|
250
|
-
provider:
|
|
251
|
-
toolCalls:
|
|
252
|
-
toolCallId:
|
|
253
|
-
name:
|
|
254
|
-
success:
|
|
366
|
+
usageScopeId: import_zod_openapi.z.string().optional().describe("Optional usage scope identifier for runtime-scoped metering"),
|
|
367
|
+
model: import_zod_openapi.z.string().optional().describe("Model identifier for assistant messages"),
|
|
368
|
+
provider: import_zod_openapi.z.enum(import_core.LLM_PROVIDERS).optional().describe("Provider identifier for assistant messages"),
|
|
369
|
+
toolCalls: import_zod_openapi.z.array(ToolCallSchema).optional().describe("Tool calls made by the assistant"),
|
|
370
|
+
toolCallId: import_zod_openapi.z.string().optional().describe("ID of the tool call this message responds to"),
|
|
371
|
+
name: import_zod_openapi.z.string().optional().describe("Name of the tool that produced this result"),
|
|
372
|
+
success: import_zod_openapi.z.boolean().optional().describe("Whether tool execution succeeded (present for role=tool messages)")
|
|
255
373
|
}).strict().describe("Internal message representation");
|
|
256
374
|
const LLMConfigResponseSchema = import_core.LLMConfigBaseSchema.omit({ apiKey: true }).extend({
|
|
257
|
-
hasApiKey:
|
|
375
|
+
hasApiKey: import_zod_openapi.z.boolean().optional().describe("Whether an API key is configured")
|
|
258
376
|
}).describe("LLM configuration (apiKey omitted for security)");
|
|
259
377
|
const LLMConfigSchema = import_core.LLMConfigBaseSchema.describe("LLM configuration with API key");
|
|
260
378
|
const SessionTokenUsageSchema = TokenUsageSchema.required().describe(
|
|
261
379
|
"Session-level token usage (all fields required for cumulative totals)"
|
|
262
380
|
);
|
|
263
|
-
const SessionUsageTrackingSchema =
|
|
264
|
-
hasUntrackedChatGPTLoginUsage:
|
|
381
|
+
const SessionUsageTrackingSchema = import_zod_openapi.z.object({
|
|
382
|
+
hasUntrackedChatGPTLoginUsage: import_zod_openapi.z.boolean().optional().describe("Whether this session includes known untracked ChatGPT Login usage")
|
|
265
383
|
}).strict().describe("Usage tracking caveats for a session");
|
|
266
|
-
const ModelStatisticsSchema =
|
|
267
|
-
provider:
|
|
268
|
-
model:
|
|
269
|
-
messageCount:
|
|
384
|
+
const ModelStatisticsSchema = import_zod_openapi.z.object({
|
|
385
|
+
provider: import_zod_openapi.z.string().describe("LLM provider identifier"),
|
|
386
|
+
model: import_zod_openapi.z.string().describe("Model identifier"),
|
|
387
|
+
messageCount: import_zod_openapi.z.number().int().nonnegative().describe("Number of messages using this model"),
|
|
270
388
|
tokenUsage: SessionTokenUsageSchema.describe("Token usage for this model"),
|
|
271
|
-
estimatedCost:
|
|
272
|
-
firstUsedAt:
|
|
273
|
-
lastUsedAt:
|
|
389
|
+
estimatedCost: import_zod_openapi.z.number().nonnegative().describe("Estimated cost in USD for this model"),
|
|
390
|
+
firstUsedAt: import_zod_openapi.z.number().int().positive().describe("First use timestamp (Unix ms)"),
|
|
391
|
+
lastUsedAt: import_zod_openapi.z.number().int().positive().describe("Last use timestamp (Unix ms)")
|
|
274
392
|
}).strict().describe("Per-model statistics within a session");
|
|
275
|
-
const UsageSummarySchema =
|
|
393
|
+
const UsageSummarySchema = import_zod_openapi.z.object({
|
|
276
394
|
tokenUsage: SessionTokenUsageSchema.describe(
|
|
277
395
|
"Aggregate token usage for the selected scope"
|
|
278
396
|
),
|
|
279
|
-
estimatedCost:
|
|
280
|
-
hasUnpricedResponses:
|
|
397
|
+
estimatedCost: import_zod_openapi.z.number().nonnegative().describe("Total estimated cost in USD for the selected scope"),
|
|
398
|
+
hasUnpricedResponses: import_zod_openapi.z.boolean().describe(
|
|
281
399
|
"Whether any response in the selected scope has usage but no resolved pricing"
|
|
282
400
|
),
|
|
283
|
-
modelStats:
|
|
284
|
-
|
|
285
|
-
provider:
|
|
286
|
-
model:
|
|
287
|
-
messageCount:
|
|
401
|
+
modelStats: import_zod_openapi.z.array(
|
|
402
|
+
import_zod_openapi.z.object({
|
|
403
|
+
provider: import_zod_openapi.z.string().describe("LLM provider identifier"),
|
|
404
|
+
model: import_zod_openapi.z.string().describe("Model identifier"),
|
|
405
|
+
messageCount: import_zod_openapi.z.number().int().nonnegative().describe("Number of responses using this model in the selected scope"),
|
|
288
406
|
tokenUsage: SessionTokenUsageSchema.describe(
|
|
289
407
|
"Token usage for this model in the selected scope"
|
|
290
408
|
),
|
|
291
|
-
estimatedCost:
|
|
409
|
+
estimatedCost: import_zod_openapi.z.number().nonnegative().describe("Estimated cost in USD for this model in the selected scope")
|
|
292
410
|
}).strict()
|
|
293
411
|
).optional().describe("Per-model usage statistics within the selected scope")
|
|
294
412
|
}).strict().describe("Usage summary for a session or session scope");
|
|
295
413
|
const ScopedUsageSummarySchema = UsageSummarySchema.extend({
|
|
296
|
-
scopeId:
|
|
414
|
+
scopeId: import_zod_openapi.z.string().describe("Usage scope identifier")
|
|
297
415
|
}).strict().describe("Usage summary for a specific scope within a session");
|
|
298
|
-
const SessionMetadataSchema =
|
|
299
|
-
id:
|
|
300
|
-
createdAt:
|
|
301
|
-
lastActivity:
|
|
302
|
-
messageCount:
|
|
303
|
-
title:
|
|
416
|
+
const SessionMetadataSchema = import_zod_openapi.z.object({
|
|
417
|
+
id: import_zod_openapi.z.string().describe("Unique session identifier"),
|
|
418
|
+
createdAt: import_zod_openapi.z.number().int().positive().nullable().describe("Creation timestamp (Unix ms, null if unavailable)"),
|
|
419
|
+
lastActivity: import_zod_openapi.z.number().int().positive().nullable().describe("Last activity timestamp (Unix ms, null if unavailable)"),
|
|
420
|
+
messageCount: import_zod_openapi.z.number().int().nonnegative().describe("Total number of messages in session"),
|
|
421
|
+
title: import_zod_openapi.z.string().optional().nullable().describe("Optional session title"),
|
|
304
422
|
tokenUsage: SessionTokenUsageSchema.optional().describe(
|
|
305
423
|
"Aggregate token usage across all models"
|
|
306
424
|
),
|
|
307
|
-
estimatedCost:
|
|
308
|
-
modelStats:
|
|
425
|
+
estimatedCost: import_zod_openapi.z.number().nonnegative().optional().describe("Total estimated cost in USD across all models"),
|
|
426
|
+
modelStats: import_zod_openapi.z.array(ModelStatisticsSchema).optional().describe("Per-model usage statistics (for multi-model sessions)"),
|
|
309
427
|
usageTracking: SessionUsageTrackingSchema.optional().describe(
|
|
310
428
|
"Known caveats or gaps in usage tracking for this session"
|
|
311
429
|
),
|
|
312
|
-
workspaceId:
|
|
313
|
-
parentSessionId:
|
|
430
|
+
workspaceId: import_zod_openapi.z.string().optional().nullable().describe("Associated workspace ID, if any"),
|
|
431
|
+
parentSessionId: import_zod_openapi.z.string().optional().nullable().describe("Parent session ID if this session was forked, otherwise null")
|
|
314
432
|
}).strict().describe("Session metadata");
|
|
315
|
-
const WorkspaceSchema =
|
|
316
|
-
id:
|
|
317
|
-
path:
|
|
318
|
-
name:
|
|
319
|
-
createdAt:
|
|
320
|
-
lastActiveAt:
|
|
433
|
+
const WorkspaceSchema = import_zod_openapi.z.object({
|
|
434
|
+
id: import_zod_openapi.z.string().describe("Workspace identifier"),
|
|
435
|
+
path: import_zod_openapi.z.string().describe("Workspace root path"),
|
|
436
|
+
name: import_zod_openapi.z.string().optional().nullable().describe("Optional workspace display name"),
|
|
437
|
+
createdAt: import_zod_openapi.z.number().int().positive().describe("Creation timestamp (Unix ms)"),
|
|
438
|
+
lastActiveAt: import_zod_openapi.z.number().int().positive().describe("Last active timestamp (Unix ms)")
|
|
321
439
|
}).strict().describe("Workspace metadata");
|
|
322
|
-
const ScheduleTaskSchema =
|
|
323
|
-
instruction:
|
|
324
|
-
metadata:
|
|
440
|
+
const ScheduleTaskSchema = import_zod_openapi.z.object({
|
|
441
|
+
instruction: import_zod_openapi.z.string().describe("Instruction to execute"),
|
|
442
|
+
metadata: JsonObjectSchema.optional().describe("Optional task metadata")
|
|
325
443
|
}).strict().describe("Schedule task definition");
|
|
326
|
-
const ScheduleSchema =
|
|
327
|
-
id:
|
|
328
|
-
name:
|
|
329
|
-
cronExpression:
|
|
330
|
-
timezone:
|
|
331
|
-
enabled:
|
|
444
|
+
const ScheduleSchema = import_zod_openapi.z.object({
|
|
445
|
+
id: import_zod_openapi.z.string().describe("Schedule ID"),
|
|
446
|
+
name: import_zod_openapi.z.string().describe("Schedule name"),
|
|
447
|
+
cronExpression: import_zod_openapi.z.string().describe("Cron expression"),
|
|
448
|
+
timezone: import_zod_openapi.z.string().describe("Timezone for schedule"),
|
|
449
|
+
enabled: import_zod_openapi.z.boolean().describe("Whether the schedule is enabled"),
|
|
332
450
|
task: ScheduleTaskSchema.describe("Schedule task configuration"),
|
|
333
|
-
sessionMode:
|
|
334
|
-
sessionId:
|
|
335
|
-
workspacePath:
|
|
336
|
-
createdAt:
|
|
337
|
-
updatedAt:
|
|
338
|
-
lastRunAt:
|
|
339
|
-
nextRunAt:
|
|
340
|
-
runCount:
|
|
341
|
-
successCount:
|
|
342
|
-
failureCount:
|
|
343
|
-
lastError:
|
|
451
|
+
sessionMode: import_zod_openapi.z.enum(["ephemeral", "dedicated", "inherit", "fixed"]).describe("Session context mode"),
|
|
452
|
+
sessionId: import_zod_openapi.z.string().optional().describe("Session ID when using fixed/inherit mode"),
|
|
453
|
+
workspacePath: import_zod_openapi.z.string().optional().describe("Workspace path override"),
|
|
454
|
+
createdAt: import_zod_openapi.z.number().int().positive().describe("Creation timestamp (Unix ms)"),
|
|
455
|
+
updatedAt: import_zod_openapi.z.number().int().positive().describe("Last update timestamp (Unix ms)"),
|
|
456
|
+
lastRunAt: import_zod_openapi.z.number().int().positive().optional().describe("Last run timestamp (Unix ms)"),
|
|
457
|
+
nextRunAt: import_zod_openapi.z.number().int().positive().optional().describe("Next run timestamp (Unix ms)"),
|
|
458
|
+
runCount: import_zod_openapi.z.number().int().nonnegative().describe("Total executions"),
|
|
459
|
+
successCount: import_zod_openapi.z.number().int().nonnegative().describe("Successful executions"),
|
|
460
|
+
failureCount: import_zod_openapi.z.number().int().nonnegative().describe("Failed executions"),
|
|
461
|
+
lastError: import_zod_openapi.z.string().optional().describe("Last execution error, if any")
|
|
344
462
|
}).strict().describe("Automation schedule");
|
|
345
|
-
const ExecutionLogSchema =
|
|
346
|
-
id:
|
|
347
|
-
scheduleId:
|
|
348
|
-
triggeredAt:
|
|
349
|
-
completedAt:
|
|
350
|
-
status:
|
|
351
|
-
duration:
|
|
352
|
-
error:
|
|
353
|
-
result:
|
|
463
|
+
const ExecutionLogSchema = import_zod_openapi.z.object({
|
|
464
|
+
id: import_zod_openapi.z.string().describe("Execution log ID"),
|
|
465
|
+
scheduleId: import_zod_openapi.z.string().describe("Schedule ID"),
|
|
466
|
+
triggeredAt: import_zod_openapi.z.number().int().positive().describe("Trigger timestamp (Unix ms)"),
|
|
467
|
+
completedAt: import_zod_openapi.z.number().int().positive().optional().describe("Completion timestamp (Unix ms)"),
|
|
468
|
+
status: import_zod_openapi.z.enum(["pending", "success", "failed", "timeout"]).describe("Execution status"),
|
|
469
|
+
duration: import_zod_openapi.z.number().int().nonnegative().optional().describe("Execution duration in ms"),
|
|
470
|
+
error: import_zod_openapi.z.string().optional().describe("Execution error, if any"),
|
|
471
|
+
result: import_zod_openapi.z.string().optional().describe("Execution result, if any")
|
|
354
472
|
}).strict().describe("Schedule execution log");
|
|
355
|
-
const SearchResultSchema =
|
|
356
|
-
sessionId:
|
|
473
|
+
const SearchResultSchema = import_zod_openapi.z.object({
|
|
474
|
+
sessionId: import_zod_openapi.z.string().describe("Session ID where the message was found"),
|
|
357
475
|
message: InternalMessageSchema.describe("The message that matched the search"),
|
|
358
|
-
matchedText:
|
|
359
|
-
context:
|
|
360
|
-
messageIndex:
|
|
476
|
+
matchedText: import_zod_openapi.z.string().describe("The specific text that matched the search query"),
|
|
477
|
+
context: import_zod_openapi.z.string().describe("Context around the match for preview"),
|
|
478
|
+
messageIndex: import_zod_openapi.z.number().int().nonnegative().describe("Index of the message within the session")
|
|
361
479
|
}).strict().describe("Result of a message search");
|
|
362
|
-
const SessionSearchResultSchema =
|
|
363
|
-
sessionId:
|
|
364
|
-
matchCount:
|
|
480
|
+
const SessionSearchResultSchema = import_zod_openapi.z.object({
|
|
481
|
+
sessionId: import_zod_openapi.z.string().describe("Session ID"),
|
|
482
|
+
matchCount: import_zod_openapi.z.number().int().nonnegative().describe("Number of messages that matched in this session"),
|
|
365
483
|
firstMatch: SearchResultSchema.describe("Preview of the first matching message"),
|
|
366
|
-
metadata:
|
|
367
|
-
createdAt:
|
|
368
|
-
lastActivity:
|
|
369
|
-
messageCount:
|
|
484
|
+
metadata: import_zod_openapi.z.object({
|
|
485
|
+
createdAt: import_zod_openapi.z.number().int().positive().describe("Session creation timestamp"),
|
|
486
|
+
lastActivity: import_zod_openapi.z.number().int().positive().describe("Last activity timestamp"),
|
|
487
|
+
messageCount: import_zod_openapi.z.number().int().nonnegative().describe("Total messages in session")
|
|
370
488
|
}).strict().describe("Session metadata")
|
|
371
489
|
}).strict().describe("Result of a session search");
|
|
372
|
-
const MessageSearchResponseSchema =
|
|
373
|
-
results:
|
|
374
|
-
total:
|
|
375
|
-
hasMore:
|
|
376
|
-
query:
|
|
490
|
+
const MessageSearchResponseSchema = import_zod_openapi.z.object({
|
|
491
|
+
results: import_zod_openapi.z.array(SearchResultSchema).describe("Array of search results"),
|
|
492
|
+
total: import_zod_openapi.z.number().int().nonnegative().describe("Total number of results available"),
|
|
493
|
+
hasMore: import_zod_openapi.z.boolean().describe("Whether there are more results beyond the current page"),
|
|
494
|
+
query: import_zod_openapi.z.string().describe("Query that was searched")
|
|
377
495
|
}).strict().describe("Message search response");
|
|
378
|
-
const SessionSearchResponseSchema =
|
|
379
|
-
results:
|
|
380
|
-
total:
|
|
381
|
-
hasMore:
|
|
496
|
+
const SessionSearchResponseSchema = import_zod_openapi.z.object({
|
|
497
|
+
results: import_zod_openapi.z.array(SessionSearchResultSchema).describe("Array of session search results"),
|
|
498
|
+
total: import_zod_openapi.z.number().int().nonnegative().describe("Total number of sessions with matches"),
|
|
499
|
+
hasMore: import_zod_openapi.z.boolean().describe(
|
|
382
500
|
"Always false - session search returns all matching sessions without pagination"
|
|
383
501
|
),
|
|
384
|
-
query:
|
|
502
|
+
query: import_zod_openapi.z.string().describe("Query that was searched")
|
|
385
503
|
}).strict().describe("Session search response");
|
|
386
|
-
const WebhookSchema =
|
|
387
|
-
id:
|
|
388
|
-
url:
|
|
389
|
-
events:
|
|
390
|
-
createdAt:
|
|
504
|
+
const WebhookSchema = import_zod_openapi.z.object({
|
|
505
|
+
id: import_zod_openapi.z.string().describe("Unique webhook identifier"),
|
|
506
|
+
url: import_zod_openapi.z.string().url().describe("Webhook URL to send events to"),
|
|
507
|
+
events: import_zod_openapi.z.array(import_zod_openapi.z.string()).describe("Array of event types this webhook subscribes to"),
|
|
508
|
+
createdAt: import_zod_openapi.z.number().int().positive().describe("Creation timestamp (Unix ms)")
|
|
391
509
|
}).strict().describe("Webhook subscription");
|
|
392
|
-
const CatalogModelInfoSchema =
|
|
393
|
-
name:
|
|
394
|
-
maxInputTokens:
|
|
395
|
-
default:
|
|
396
|
-
supportedFileTypes:
|
|
397
|
-
displayName:
|
|
398
|
-
pricing:
|
|
399
|
-
inputPerM:
|
|
400
|
-
outputPerM:
|
|
401
|
-
cacheReadPerM:
|
|
402
|
-
cacheWritePerM:
|
|
403
|
-
currency:
|
|
404
|
-
unit:
|
|
510
|
+
const CatalogModelInfoSchema = import_zod_openapi.z.object({
|
|
511
|
+
name: import_zod_openapi.z.string().describe("Model name identifier"),
|
|
512
|
+
maxInputTokens: import_zod_openapi.z.number().int().positive().describe("Maximum input tokens"),
|
|
513
|
+
default: import_zod_openapi.z.boolean().optional().describe("Whether this is a default model"),
|
|
514
|
+
supportedFileTypes: import_zod_openapi.z.array(import_zod_openapi.z.enum(["audio", "pdf", "image"])).describe("File types this model supports"),
|
|
515
|
+
displayName: import_zod_openapi.z.string().optional().describe("Human-readable display name"),
|
|
516
|
+
pricing: import_zod_openapi.z.object({
|
|
517
|
+
inputPerM: import_zod_openapi.z.number().describe("Input cost per million tokens (USD)"),
|
|
518
|
+
outputPerM: import_zod_openapi.z.number().describe("Output cost per million tokens (USD)"),
|
|
519
|
+
cacheReadPerM: import_zod_openapi.z.number().optional().describe("Cache read cost per million tokens"),
|
|
520
|
+
cacheWritePerM: import_zod_openapi.z.number().optional().describe("Cache write cost per million tokens"),
|
|
521
|
+
currency: import_zod_openapi.z.literal("USD").optional().describe("Currency"),
|
|
522
|
+
unit: import_zod_openapi.z.literal("per_million_tokens").optional().describe("Unit")
|
|
405
523
|
}).optional().describe("Pricing information in USD per million tokens")
|
|
406
524
|
}).strict().describe("Model information from LLM registry");
|
|
407
|
-
const ProviderCatalogSchema =
|
|
408
|
-
name:
|
|
409
|
-
hasApiKey:
|
|
410
|
-
primaryEnvVar:
|
|
411
|
-
supportsBaseURL:
|
|
412
|
-
models:
|
|
413
|
-
supportedFileTypes:
|
|
525
|
+
const ProviderCatalogSchema = import_zod_openapi.z.object({
|
|
526
|
+
name: import_zod_openapi.z.string().describe("Provider display name"),
|
|
527
|
+
hasApiKey: import_zod_openapi.z.boolean().describe("Whether API key is configured"),
|
|
528
|
+
primaryEnvVar: import_zod_openapi.z.string().describe("Primary environment variable for API key"),
|
|
529
|
+
supportsBaseURL: import_zod_openapi.z.boolean().describe("Whether custom base URLs are supported"),
|
|
530
|
+
models: import_zod_openapi.z.array(CatalogModelInfoSchema).describe("Models available from this provider"),
|
|
531
|
+
supportedFileTypes: import_zod_openapi.z.array(import_zod_openapi.z.enum(["audio", "pdf", "image"])).describe("Provider-level file type support")
|
|
414
532
|
}).strict().describe("Provider catalog entry with models and capabilities");
|
|
415
533
|
const ModelFlatSchema = CatalogModelInfoSchema.extend({
|
|
416
|
-
provider:
|
|
534
|
+
provider: import_zod_openapi.z.string().describe("Provider identifier for this model")
|
|
417
535
|
}).describe("Flattened model entry with provider information");
|
|
418
|
-
const AgentRegistryEntrySchema =
|
|
419
|
-
id:
|
|
420
|
-
name:
|
|
421
|
-
description:
|
|
422
|
-
author:
|
|
423
|
-
tags:
|
|
424
|
-
type:
|
|
536
|
+
const AgentRegistryEntrySchema = import_zod_openapi.z.object({
|
|
537
|
+
id: import_zod_openapi.z.string().describe("Unique agent identifier"),
|
|
538
|
+
name: import_zod_openapi.z.string().describe("Agent name"),
|
|
539
|
+
description: import_zod_openapi.z.string().describe("Agent description"),
|
|
540
|
+
author: import_zod_openapi.z.string().optional().describe("Agent author"),
|
|
541
|
+
tags: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Agent tags"),
|
|
542
|
+
type: import_zod_openapi.z.enum(["builtin", "custom"]).describe("Agent type")
|
|
425
543
|
}).strict().describe("Agent registry entry");
|
|
426
|
-
const ResourceSchema =
|
|
427
|
-
uri:
|
|
428
|
-
name:
|
|
429
|
-
description:
|
|
430
|
-
mimeType:
|
|
431
|
-
source:
|
|
432
|
-
serverName:
|
|
433
|
-
size:
|
|
434
|
-
lastModified:
|
|
435
|
-
metadata:
|
|
544
|
+
const ResourceSchema = import_zod_openapi.z.object({
|
|
545
|
+
uri: import_zod_openapi.z.string().describe("Resource URI"),
|
|
546
|
+
name: import_zod_openapi.z.string().optional().describe("Resource name"),
|
|
547
|
+
description: import_zod_openapi.z.string().optional().describe("Resource description"),
|
|
548
|
+
mimeType: import_zod_openapi.z.string().optional().describe("MIME type of the resource"),
|
|
549
|
+
source: import_zod_openapi.z.enum(["mcp", "internal"]).describe("Source system that provides this resource"),
|
|
550
|
+
serverName: import_zod_openapi.z.string().optional().describe("Original server/provider name (for MCP resources)"),
|
|
551
|
+
size: import_zod_openapi.z.number().optional().describe("Size of the resource in bytes (if known)"),
|
|
552
|
+
lastModified: import_zod_openapi.z.string().datetime().optional().describe("Last modified timestamp (ISO 8601 string)"),
|
|
553
|
+
metadata: import_zod_openapi.z.record(import_zod_openapi.z.string(), JsonValueSchema).optional().describe("Additional metadata specific to the resource type")
|
|
436
554
|
}).strict().describe("Resource metadata");
|
|
437
|
-
const ToolSchema =
|
|
438
|
-
name:
|
|
439
|
-
description:
|
|
440
|
-
inputSchema:
|
|
555
|
+
const ToolSchema = import_zod_openapi.z.object({
|
|
556
|
+
name: import_zod_openapi.z.string().describe("Tool name"),
|
|
557
|
+
description: import_zod_openapi.z.string().describe("Tool description"),
|
|
558
|
+
inputSchema: ToolInputSchema.describe("JSON Schema for tool input parameters")
|
|
441
559
|
}).strict().describe("Tool metadata");
|
|
442
|
-
const PromptArgumentSchema =
|
|
443
|
-
name:
|
|
444
|
-
description:
|
|
445
|
-
required:
|
|
560
|
+
const PromptArgumentSchema = import_zod_openapi.z.object({
|
|
561
|
+
name: import_zod_openapi.z.string().describe("Argument name"),
|
|
562
|
+
description: import_zod_openapi.z.string().optional().describe("Argument description"),
|
|
563
|
+
required: import_zod_openapi.z.boolean().optional().describe("Whether the argument is required")
|
|
446
564
|
}).strict().describe("Prompt argument definition");
|
|
447
|
-
const PromptDefinitionSchema =
|
|
448
|
-
name:
|
|
449
|
-
title:
|
|
450
|
-
description:
|
|
451
|
-
arguments:
|
|
565
|
+
const PromptDefinitionSchema = import_zod_openapi.z.object({
|
|
566
|
+
name: import_zod_openapi.z.string().describe("Prompt name"),
|
|
567
|
+
title: import_zod_openapi.z.string().optional().describe("Prompt title"),
|
|
568
|
+
description: import_zod_openapi.z.string().optional().describe("Prompt description"),
|
|
569
|
+
arguments: import_zod_openapi.z.array(PromptArgumentSchema).optional().describe("Array of argument definitions"),
|
|
570
|
+
disableModelInvocation: import_zod_openapi.z.boolean().optional().describe("Exclude from auto-invocation list in system prompt"),
|
|
571
|
+
userInvocable: import_zod_openapi.z.boolean().optional().describe("Whether to show in slash command menu"),
|
|
572
|
+
allowedTools: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Tools to auto-approve when this prompt is active"),
|
|
573
|
+
toolkits: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Toolkits to load when invoked"),
|
|
574
|
+
model: import_zod_openapi.z.string().optional().describe("Model to use when this prompt is invoked"),
|
|
575
|
+
context: import_zod_openapi.z.enum(["inline", "fork"]).optional().describe("Execution context for this prompt"),
|
|
576
|
+
agent: import_zod_openapi.z.string().optional().describe("Agent ID to use for fork execution")
|
|
452
577
|
}).strict().describe("Prompt definition (MCP-compliant)");
|
|
453
|
-
const PromptInfoSchema =
|
|
454
|
-
name:
|
|
455
|
-
title:
|
|
456
|
-
description:
|
|
457
|
-
arguments:
|
|
458
|
-
|
|
459
|
-
|
|
578
|
+
const PromptInfoSchema = import_zod_openapi.z.object({
|
|
579
|
+
name: import_zod_openapi.z.string().describe("Prompt name"),
|
|
580
|
+
title: import_zod_openapi.z.string().optional().describe("Prompt title"),
|
|
581
|
+
description: import_zod_openapi.z.string().optional().describe("Prompt description"),
|
|
582
|
+
arguments: import_zod_openapi.z.array(PromptArgumentSchema).optional().describe("Array of argument definitions"),
|
|
583
|
+
disableModelInvocation: import_zod_openapi.z.boolean().optional().describe("Exclude from auto-invocation list in system prompt"),
|
|
584
|
+
userInvocable: import_zod_openapi.z.boolean().optional().describe("Whether to show in slash command menu"),
|
|
585
|
+
allowedTools: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Tools to auto-approve when this prompt is active"),
|
|
586
|
+
toolkits: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("Toolkits to load when invoked"),
|
|
587
|
+
model: import_zod_openapi.z.string().optional().describe("Model to use when this prompt is invoked"),
|
|
588
|
+
context: import_zod_openapi.z.enum(["inline", "fork"]).optional().describe("Execution context for this prompt"),
|
|
589
|
+
agent: import_zod_openapi.z.string().optional().describe("Agent ID to use for fork execution"),
|
|
590
|
+
source: import_zod_openapi.z.enum(["mcp", "config", "custom"]).describe("Source of the prompt"),
|
|
591
|
+
displayName: import_zod_openapi.z.string().optional().describe("Base display name set by provider"),
|
|
592
|
+
commandName: import_zod_openapi.z.string().optional().describe("Collision-resolved slash command name"),
|
|
593
|
+
metadata: JsonObjectSchema.optional().describe("Additional metadata")
|
|
460
594
|
}).strict().describe("Enhanced prompt information");
|
|
461
|
-
const PromptSchema =
|
|
462
|
-
id:
|
|
463
|
-
name:
|
|
464
|
-
description:
|
|
465
|
-
content:
|
|
466
|
-
variables:
|
|
595
|
+
const PromptSchema = import_zod_openapi.z.object({
|
|
596
|
+
id: import_zod_openapi.z.string().describe("Unique prompt identifier"),
|
|
597
|
+
name: import_zod_openapi.z.string().describe("Prompt name"),
|
|
598
|
+
description: import_zod_openapi.z.string().optional().describe("Prompt description"),
|
|
599
|
+
content: import_zod_openapi.z.string().describe("Prompt template content"),
|
|
600
|
+
variables: import_zod_openapi.z.array(import_zod_openapi.z.string()).optional().describe("List of variable placeholders in the prompt")
|
|
467
601
|
}).strict().describe("Prompt template");
|
|
468
|
-
const OkResponseSchema = (dataSchema) =>
|
|
469
|
-
ok:
|
|
602
|
+
const OkResponseSchema = (dataSchema) => import_zod_openapi.z.object({
|
|
603
|
+
ok: import_zod_openapi.z.literal(true).describe("Indicates successful response"),
|
|
470
604
|
data: dataSchema.describe("Response data")
|
|
471
605
|
}).strict().describe("Successful API response");
|
|
472
|
-
const ErrorResponseSchema =
|
|
473
|
-
ok:
|
|
474
|
-
error:
|
|
475
|
-
message:
|
|
476
|
-
code:
|
|
477
|
-
details:
|
|
606
|
+
const ErrorResponseSchema = import_zod_openapi.z.object({
|
|
607
|
+
ok: import_zod_openapi.z.literal(false).describe("Indicates failed response"),
|
|
608
|
+
error: import_zod_openapi.z.object({
|
|
609
|
+
message: import_zod_openapi.z.string().describe("Error message"),
|
|
610
|
+
code: import_zod_openapi.z.string().optional().describe("Error code"),
|
|
611
|
+
details: JsonValueSchema.optional().describe("Additional error details")
|
|
478
612
|
}).strict().describe("Error details")
|
|
479
613
|
}).strict().describe("Error API response");
|
|
480
|
-
const StandardErrorEnvelopeSchema =
|
|
481
|
-
code:
|
|
482
|
-
message:
|
|
483
|
-
scope:
|
|
484
|
-
type:
|
|
485
|
-
context:
|
|
486
|
-
recovery:
|
|
487
|
-
traceId:
|
|
488
|
-
endpoint:
|
|
489
|
-
method:
|
|
614
|
+
const StandardErrorEnvelopeSchema = import_zod_openapi.z.object({
|
|
615
|
+
code: import_zod_openapi.z.string().describe("Error code"),
|
|
616
|
+
message: import_zod_openapi.z.string().describe("Error message"),
|
|
617
|
+
scope: import_zod_openapi.z.string().describe("Error scope"),
|
|
618
|
+
type: import_zod_openapi.z.string().describe("Error type"),
|
|
619
|
+
context: JsonValueSchema.optional().describe("Error context"),
|
|
620
|
+
recovery: import_zod_openapi.z.union([import_zod_openapi.z.string(), import_zod_openapi.z.array(import_zod_openapi.z.string())]).optional().describe("Recovery guidance"),
|
|
621
|
+
traceId: import_zod_openapi.z.string().describe("Trace identifier"),
|
|
622
|
+
endpoint: import_zod_openapi.z.string().describe("Request endpoint"),
|
|
623
|
+
method: import_zod_openapi.z.string().describe("HTTP method")
|
|
490
624
|
}).strict().describe("Standard API error envelope");
|
|
491
|
-
const StatusResponseSchema =
|
|
492
|
-
status:
|
|
493
|
-
message:
|
|
625
|
+
const StatusResponseSchema = import_zod_openapi.z.object({
|
|
626
|
+
status: import_zod_openapi.z.string().describe("Operation status"),
|
|
627
|
+
message: import_zod_openapi.z.string().optional().describe("Optional status message")
|
|
494
628
|
}).strict().describe("Status response");
|
|
495
|
-
const DeleteResponseSchema =
|
|
496
|
-
status:
|
|
497
|
-
id:
|
|
629
|
+
const DeleteResponseSchema = import_zod_openapi.z.object({
|
|
630
|
+
status: import_zod_openapi.z.literal("deleted").describe("Indicates successful deletion"),
|
|
631
|
+
id: import_zod_openapi.z.string().optional().describe("ID of the deleted resource")
|
|
498
632
|
}).strict().describe("Delete operation response");
|
|
499
633
|
// Annotate the CommonJS export names for ESM import in node:
|
|
500
634
|
0 && (module.exports = {
|
|
501
635
|
AgentCardSchema,
|
|
502
636
|
AgentRegistryEntrySchema,
|
|
503
637
|
ApiErrorResponseSchema,
|
|
638
|
+
BadRequestErrorResponse,
|
|
504
639
|
CatalogModelInfoSchema,
|
|
640
|
+
ConflictErrorResponse,
|
|
505
641
|
ContentPartSchema,
|
|
506
642
|
DeleteResponseSchema,
|
|
507
643
|
ErrorResponseSchema,
|
|
508
644
|
ExecutionLogSchema,
|
|
509
645
|
FilePartSchema,
|
|
646
|
+
ForbiddenErrorResponse,
|
|
510
647
|
HttpServerConfigSchema,
|
|
511
648
|
ImagePartSchema,
|
|
649
|
+
InternalErrorResponse,
|
|
512
650
|
InternalMessageSchema,
|
|
513
651
|
IssueSchema,
|
|
652
|
+
JsonObjectSchema,
|
|
653
|
+
JsonSchemaPropertySchema,
|
|
654
|
+
JsonValueSchema,
|
|
514
655
|
LLMConfigBaseSchema,
|
|
515
656
|
LLMConfigResponseSchema,
|
|
516
657
|
LLMConfigSchema,
|
|
@@ -519,7 +660,9 @@ const DeleteResponseSchema = import_zod.z.object({
|
|
|
519
660
|
MessageSearchResponseSchema,
|
|
520
661
|
ModelFlatSchema,
|
|
521
662
|
ModelStatisticsSchema,
|
|
663
|
+
NotFoundErrorResponse,
|
|
522
664
|
OkResponseSchema,
|
|
665
|
+
PaymentRequiredErrorResponse,
|
|
523
666
|
PermissionsConfigSchema,
|
|
524
667
|
PricingStatusSchema,
|
|
525
668
|
PromptArgumentSchema,
|
|
@@ -527,6 +670,7 @@ const DeleteResponseSchema = import_zod.z.object({
|
|
|
527
670
|
PromptInfoSchema,
|
|
528
671
|
PromptSchema,
|
|
529
672
|
ProviderCatalogSchema,
|
|
673
|
+
RateLimitErrorResponse,
|
|
530
674
|
RequestContentPartSchema,
|
|
531
675
|
RequestContentSchema,
|
|
532
676
|
ResourceConfigSchema,
|
|
@@ -545,10 +689,13 @@ const DeleteResponseSchema = import_zod.z.object({
|
|
|
545
689
|
StatusResponseSchema,
|
|
546
690
|
StdioServerConfigSchema,
|
|
547
691
|
TextPartSchema,
|
|
692
|
+
TimeoutErrorResponse,
|
|
548
693
|
TokenUsageSchema,
|
|
549
694
|
ToolCallSchema,
|
|
695
|
+
ToolInputSchema,
|
|
550
696
|
ToolSchema,
|
|
551
697
|
UIResourcePartSchema,
|
|
698
|
+
UpstreamErrorResponse,
|
|
552
699
|
UsageSummarySchema,
|
|
553
700
|
WebhookSchema,
|
|
554
701
|
WorkspaceSchema,
|