@inkeep/agents-core 0.18.1 → 0.19.1
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/README.md +4 -4
- package/dist/{chunk-JTHQYGCX.js → chunk-4FMDWUE4.js} +34 -34
- package/dist/{chunk-ID4CFGVF.js → chunk-B6F3RF4T.js} +87 -120
- package/dist/chunk-E6R6PML7.js +19 -0
- package/dist/chunk-HYS7HUYJ.js +27 -0
- package/dist/{chunk-H6PMWHNV.js → chunk-SLL6V3AE.js} +12 -12
- package/dist/{chunk-E4SFK6AI.js → chunk-VICWT3WO.js} +281 -142
- package/dist/{chunk-R2EERZSW.js → chunk-YECQCT5N.js} +1 -1
- package/dist/client-exports.cjs +390 -283
- package/dist/client-exports.d.cts +13 -14
- package/dist/client-exports.d.ts +13 -14
- package/dist/client-exports.js +10 -10
- package/dist/constants/models.cjs +31 -0
- package/dist/constants/models.d.cts +33 -0
- package/dist/constants/models.d.ts +33 -0
- package/dist/constants/models.js +1 -0
- package/dist/db/schema.cjs +85 -118
- package/dist/db/schema.d.cts +2 -3
- package/dist/db/schema.d.ts +2 -3
- package/dist/db/schema.js +1 -1
- package/dist/index.cjs +214164 -1095
- package/dist/index.d.cts +215 -214
- package/dist/index.d.ts +215 -214
- package/dist/index.js +213657 -767
- package/dist/{schema-ULFEZCOL.d.cts → schema-CcSN2XcZ.d.cts} +54 -52
- package/dist/{schema-wbZXiVWb.d.ts → schema-D8h85qdU.d.ts} +54 -52
- package/dist/{signoz-queries-BuiipZTk.d.cts → signoz-queries-CuWMQh1H.d.cts} +10 -10
- package/dist/{signoz-queries-BuiipZTk.d.ts → signoz-queries-CuWMQh1H.d.ts} +10 -10
- package/dist/types/index.d.cts +2 -3
- package/dist/types/index.d.ts +2 -3
- package/dist/{utility-CyPQ1tC_.d.cts → utility-HqRMF7sM.d.cts} +1775 -320
- package/dist/{utility-CyPQ1tC_.d.ts → utility-HqRMF7sM.d.ts} +1775 -320
- package/dist/utils/schema-conversion.js +1 -1
- package/dist/validation/index.cjs +445 -304
- package/dist/validation/index.d.cts +12 -13
- package/dist/validation/index.d.ts +12 -13
- package/dist/validation/index.js +2 -2
- package/drizzle/0007_mighty_typhoid_mary.sql +227 -0
- package/drizzle/meta/0007_snapshot.json +2766 -0
- package/drizzle/meta/_journal.json +7 -0
- package/package.json +6 -1
- package/dist/chunk-MKBO26DX.js +0 -9
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { subAgents, subAgentRelations,
|
|
1
|
+
import { subAgents, subAgentRelations, agents, tasks, taskRelations, tools, conversations, messages, contextCache, dataComponents, subAgentDataComponents, artifactComponents, subAgentArtifactComponents, externalAgents, apiKeys, credentialReferences, functionTools, functions, contextConfigs, subAgentToolRelations, ledgerArtifacts, projects } from './chunk-B6F3RF4T.js';
|
|
2
2
|
import { VALID_RELATION_TYPES, MCPTransportType, TOOL_STATUS_VALUES, CredentialStoreType, MCPServerType } from './chunk-YFHT5M2R.js';
|
|
3
3
|
import { z } from '@hono/zod-openapi';
|
|
4
4
|
import { createSelectSchema, createInsertSchema } from 'drizzle-zod';
|
|
@@ -7,9 +7,13 @@ import Ajv from 'ajv';
|
|
|
7
7
|
var StopWhenSchema = z.object({
|
|
8
8
|
transferCountIs: z.number().min(1).max(100).optional(),
|
|
9
9
|
stepCountIs: z.number().min(1).max(1e3).optional()
|
|
10
|
-
});
|
|
11
|
-
var
|
|
12
|
-
|
|
10
|
+
}).openapi("StopWhen");
|
|
11
|
+
var AgentStopWhenSchema = StopWhenSchema.pick({ transferCountIs: true }).openapi(
|
|
12
|
+
"AgentStopWhen"
|
|
13
|
+
);
|
|
14
|
+
var SubAgentStopWhenSchema = StopWhenSchema.pick({ stepCountIs: true }).openapi(
|
|
15
|
+
"SubAgentStopWhen"
|
|
16
|
+
);
|
|
13
17
|
var MIN_ID_LENGTH = 1;
|
|
14
18
|
var MAX_ID_LENGTH = 255;
|
|
15
19
|
var URL_SAFE_ID_PATTERN = /^[a-zA-Z0-9\-_.]+$/;
|
|
@@ -22,23 +26,23 @@ var resourceIdSchema = z.string().min(MIN_ID_LENGTH).max(MAX_ID_LENGTH).regex(UR
|
|
|
22
26
|
var ModelSettingsSchema = z.object({
|
|
23
27
|
model: z.string().optional(),
|
|
24
28
|
providerOptions: z.record(z.string(), z.any()).optional()
|
|
25
|
-
});
|
|
29
|
+
}).openapi("ModelSettings");
|
|
26
30
|
var ModelSchema = z.object({
|
|
27
31
|
base: ModelSettingsSchema.optional(),
|
|
28
32
|
structuredOutput: ModelSettingsSchema.optional(),
|
|
29
33
|
summarizer: ModelSettingsSchema.optional()
|
|
30
|
-
});
|
|
34
|
+
}).openapi("Model");
|
|
31
35
|
var ProjectModelSchema = z.object({
|
|
32
36
|
base: ModelSettingsSchema,
|
|
33
37
|
structuredOutput: ModelSettingsSchema.optional(),
|
|
34
38
|
summarizer: ModelSettingsSchema.optional()
|
|
35
|
-
});
|
|
39
|
+
}).openapi("ProjectModel");
|
|
36
40
|
var SandboxConfigSchema = z.object({
|
|
37
41
|
provider: z.enum(["vercel", "local"]),
|
|
38
42
|
runtime: z.enum(["node22", "typescript"]),
|
|
39
43
|
timeout: z.number().min(1e3).max(3e5).optional(),
|
|
40
44
|
vcpus: z.number().min(1).max(8).optional()
|
|
41
|
-
});
|
|
45
|
+
}).openapi("SandboxConfig");
|
|
42
46
|
var FunctionToolConfigSchema = z.object({
|
|
43
47
|
name: z.string(),
|
|
44
48
|
description: z.string(),
|
|
@@ -49,31 +53,37 @@ var FunctionToolConfigSchema = z.object({
|
|
|
49
53
|
var createApiSchema = (schema) => schema.omit({ tenantId: true, projectId: true });
|
|
50
54
|
var createApiInsertSchema = (schema) => schema.omit({ tenantId: true, projectId: true });
|
|
51
55
|
var createApiUpdateSchema = (schema) => schema.omit({ tenantId: true, projectId: true }).partial();
|
|
52
|
-
var
|
|
53
|
-
var
|
|
54
|
-
var
|
|
56
|
+
var createAgentScopedApiSchema = (schema) => schema.omit({ tenantId: true, projectId: true, agentId: true });
|
|
57
|
+
var createAgentScopedApiInsertSchema = (schema) => schema.omit({ tenantId: true, projectId: true, agentId: true });
|
|
58
|
+
var createAgentScopedApiUpdateSchema = (schema) => schema.omit({ tenantId: true, projectId: true, agentId: true }).partial();
|
|
55
59
|
var SubAgentSelectSchema = createSelectSchema(subAgents);
|
|
56
60
|
var SubAgentInsertSchema = createInsertSchema(subAgents).extend({
|
|
57
61
|
id: resourceIdSchema,
|
|
58
62
|
models: ModelSchema.optional()
|
|
59
63
|
});
|
|
60
64
|
var SubAgentUpdateSchema = SubAgentInsertSchema.partial();
|
|
61
|
-
var SubAgentApiSelectSchema =
|
|
62
|
-
|
|
63
|
-
|
|
65
|
+
var SubAgentApiSelectSchema = createAgentScopedApiSchema(SubAgentSelectSchema).openapi(
|
|
66
|
+
"SubAgent"
|
|
67
|
+
);
|
|
68
|
+
var SubAgentApiInsertSchema = createAgentScopedApiInsertSchema(
|
|
69
|
+
SubAgentInsertSchema
|
|
70
|
+
).openapi("SubAgentCreate");
|
|
71
|
+
var SubAgentApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
72
|
+
SubAgentUpdateSchema
|
|
73
|
+
).openapi("SubAgentUpdate");
|
|
64
74
|
var SubAgentRelationSelectSchema = createSelectSchema(subAgentRelations);
|
|
65
75
|
var SubAgentRelationInsertSchema = createInsertSchema(subAgentRelations).extend({
|
|
66
76
|
id: resourceIdSchema,
|
|
67
|
-
|
|
77
|
+
agentId: resourceIdSchema,
|
|
68
78
|
sourceSubAgentId: resourceIdSchema,
|
|
69
79
|
targetSubAgentId: resourceIdSchema.optional(),
|
|
70
80
|
externalSubAgentId: resourceIdSchema.optional()
|
|
71
81
|
});
|
|
72
82
|
var SubAgentRelationUpdateSchema = SubAgentRelationInsertSchema.partial();
|
|
73
|
-
var SubAgentRelationApiSelectSchema =
|
|
83
|
+
var SubAgentRelationApiSelectSchema = createAgentScopedApiSchema(
|
|
74
84
|
SubAgentRelationSelectSchema
|
|
75
|
-
);
|
|
76
|
-
var SubAgentRelationApiInsertSchema =
|
|
85
|
+
).openapi("SubAgentRelation");
|
|
86
|
+
var SubAgentRelationApiInsertSchema = createAgentScopedApiInsertSchema(
|
|
77
87
|
SubAgentRelationInsertSchema
|
|
78
88
|
).extend({
|
|
79
89
|
relationType: z.enum(VALID_RELATION_TYPES)
|
|
@@ -87,8 +97,8 @@ var SubAgentRelationApiInsertSchema = createGraphScopedApiInsertSchema(
|
|
|
87
97
|
message: "Must specify exactly one of targetSubAgentId or externalSubAgentId",
|
|
88
98
|
path: ["targetSubAgentId", "externalSubAgentId"]
|
|
89
99
|
}
|
|
90
|
-
);
|
|
91
|
-
var SubAgentRelationApiUpdateSchema =
|
|
100
|
+
).openapi("SubAgentRelationCreate");
|
|
101
|
+
var SubAgentRelationApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
92
102
|
SubAgentRelationUpdateSchema
|
|
93
103
|
).extend({
|
|
94
104
|
relationType: z.enum(VALID_RELATION_TYPES).optional()
|
|
@@ -105,7 +115,7 @@ var SubAgentRelationApiUpdateSchema = createGraphScopedApiUpdateSchema(
|
|
|
105
115
|
message: "Must specify exactly one of targetSubAgentId or externalSubAgentId when updating sub-agent relationships",
|
|
106
116
|
path: ["targetSubAgentId", "externalSubAgentId"]
|
|
107
117
|
}
|
|
108
|
-
);
|
|
118
|
+
).openapi("SubAgentRelationUpdate");
|
|
109
119
|
var SubAgentRelationQuerySchema = z.object({
|
|
110
120
|
sourceSubAgentId: z.string().optional(),
|
|
111
121
|
targetSubAgentId: z.string().optional(),
|
|
@@ -113,23 +123,25 @@ var SubAgentRelationQuerySchema = z.object({
|
|
|
113
123
|
});
|
|
114
124
|
var ExternalSubAgentRelationInsertSchema = createInsertSchema(subAgentRelations).extend({
|
|
115
125
|
id: resourceIdSchema,
|
|
116
|
-
|
|
126
|
+
agentId: resourceIdSchema,
|
|
117
127
|
sourceSubAgentId: resourceIdSchema,
|
|
118
128
|
externalSubAgentId: resourceIdSchema
|
|
119
129
|
});
|
|
120
130
|
var ExternalSubAgentRelationApiInsertSchema = createApiInsertSchema(
|
|
121
131
|
ExternalSubAgentRelationInsertSchema
|
|
122
132
|
);
|
|
123
|
-
var
|
|
124
|
-
var
|
|
133
|
+
var AgentSelectSchema = createSelectSchema(agents);
|
|
134
|
+
var AgentInsertSchema = createInsertSchema(agents).extend({
|
|
125
135
|
id: resourceIdSchema
|
|
126
136
|
});
|
|
127
|
-
var
|
|
128
|
-
var
|
|
129
|
-
var
|
|
137
|
+
var AgentUpdateSchema = AgentInsertSchema.partial();
|
|
138
|
+
var AgentApiSelectSchema = createApiSchema(AgentSelectSchema).openapi("Agent");
|
|
139
|
+
var AgentApiInsertSchema = createApiInsertSchema(AgentInsertSchema).extend({
|
|
130
140
|
id: resourceIdSchema
|
|
131
|
-
});
|
|
132
|
-
var
|
|
141
|
+
}).openapi("AgentCreate");
|
|
142
|
+
var AgentApiUpdateSchema = createApiUpdateSchema(AgentUpdateSchema).openapi(
|
|
143
|
+
"AgentUpdate"
|
|
144
|
+
);
|
|
133
145
|
var TaskSelectSchema = createSelectSchema(tasks);
|
|
134
146
|
var TaskInsertSchema = createInsertSchema(tasks).extend({
|
|
135
147
|
id: resourceIdSchema,
|
|
@@ -172,9 +184,12 @@ var McpTransportConfigSchema = z.object({
|
|
|
172
184
|
type: z.enum(MCPTransportType),
|
|
173
185
|
requestInit: z.record(z.string(), z.unknown()).optional(),
|
|
174
186
|
eventSourceInit: z.record(z.string(), z.unknown()).optional(),
|
|
175
|
-
reconnectionOptions: z.
|
|
187
|
+
reconnectionOptions: z.any().optional().openapi({
|
|
188
|
+
type: "object",
|
|
189
|
+
description: "Reconnection options for streamable HTTP transport"
|
|
190
|
+
}),
|
|
176
191
|
sessionId: z.string().optional()
|
|
177
|
-
});
|
|
192
|
+
}).openapi("McpTransportConfig");
|
|
178
193
|
var ToolStatusSchema = z.enum(TOOL_STATUS_VALUES);
|
|
179
194
|
var McpToolDefinitionSchema = z.object({
|
|
180
195
|
name: z.string(),
|
|
@@ -189,13 +204,16 @@ var ToolInsertSchema = createInsertSchema(tools).extend({
|
|
|
189
204
|
type: z.literal("mcp"),
|
|
190
205
|
mcp: z.object({
|
|
191
206
|
server: z.object({
|
|
192
|
-
url: z.
|
|
207
|
+
url: z.url()
|
|
193
208
|
}),
|
|
194
209
|
transport: z.object({
|
|
195
210
|
type: z.enum(MCPTransportType),
|
|
196
211
|
requestInit: z.record(z.string(), z.unknown()).optional(),
|
|
197
212
|
eventSourceInit: z.record(z.string(), z.unknown()).optional(),
|
|
198
|
-
reconnectionOptions: z.
|
|
213
|
+
reconnectionOptions: z.any().optional().openapi({
|
|
214
|
+
type: "object",
|
|
215
|
+
description: "Reconnection options for streamable HTTP transport"
|
|
216
|
+
}),
|
|
199
217
|
sessionId: z.string().optional()
|
|
200
218
|
}).optional(),
|
|
201
219
|
activeTools: z.array(z.string()).optional()
|
|
@@ -208,9 +226,15 @@ var ConversationInsertSchema = createInsertSchema(conversations).extend({
|
|
|
208
226
|
contextConfigId: resourceIdSchema.optional()
|
|
209
227
|
});
|
|
210
228
|
var ConversationUpdateSchema = ConversationInsertSchema.partial();
|
|
211
|
-
var ConversationApiSelectSchema = createApiSchema(ConversationSelectSchema)
|
|
212
|
-
|
|
213
|
-
|
|
229
|
+
var ConversationApiSelectSchema = createApiSchema(ConversationSelectSchema).openapi(
|
|
230
|
+
"Conversation"
|
|
231
|
+
);
|
|
232
|
+
var ConversationApiInsertSchema = createApiInsertSchema(ConversationInsertSchema).openapi(
|
|
233
|
+
"ConversationCreate"
|
|
234
|
+
);
|
|
235
|
+
var ConversationApiUpdateSchema = createApiUpdateSchema(ConversationUpdateSchema).openapi(
|
|
236
|
+
"ConversationUpdate"
|
|
237
|
+
);
|
|
214
238
|
var MessageSelectSchema = createSelectSchema(messages);
|
|
215
239
|
var MessageInsertSchema = createInsertSchema(messages).extend({
|
|
216
240
|
id: resourceIdSchema,
|
|
@@ -218,9 +242,13 @@ var MessageInsertSchema = createInsertSchema(messages).extend({
|
|
|
218
242
|
taskId: resourceIdSchema.optional()
|
|
219
243
|
});
|
|
220
244
|
var MessageUpdateSchema = MessageInsertSchema.partial();
|
|
221
|
-
var MessageApiSelectSchema = createApiSchema(MessageSelectSchema);
|
|
222
|
-
var MessageApiInsertSchema = createApiInsertSchema(MessageInsertSchema)
|
|
223
|
-
|
|
245
|
+
var MessageApiSelectSchema = createApiSchema(MessageSelectSchema).openapi("Message");
|
|
246
|
+
var MessageApiInsertSchema = createApiInsertSchema(MessageInsertSchema).openapi(
|
|
247
|
+
"MessageCreate"
|
|
248
|
+
);
|
|
249
|
+
var MessageApiUpdateSchema = createApiUpdateSchema(MessageUpdateSchema).openapi(
|
|
250
|
+
"MessageUpdate"
|
|
251
|
+
);
|
|
224
252
|
var ContextCacheSelectSchema = createSelectSchema(contextCache);
|
|
225
253
|
var ContextCacheInsertSchema = createInsertSchema(contextCache);
|
|
226
254
|
var ContextCacheUpdateSchema = ContextCacheInsertSchema.partial();
|
|
@@ -236,13 +264,19 @@ var DataComponentBaseSchema = DataComponentInsertSchema.omit({
|
|
|
236
264
|
updatedAt: true
|
|
237
265
|
});
|
|
238
266
|
var DataComponentUpdateSchema = DataComponentInsertSchema.partial();
|
|
239
|
-
var DataComponentApiSelectSchema = createApiSchema(
|
|
240
|
-
|
|
241
|
-
|
|
267
|
+
var DataComponentApiSelectSchema = createApiSchema(
|
|
268
|
+
DataComponentSelectSchema
|
|
269
|
+
).openapi("DataComponent");
|
|
270
|
+
var DataComponentApiInsertSchema = createApiInsertSchema(
|
|
271
|
+
DataComponentInsertSchema
|
|
272
|
+
).openapi("DataComponentCreate");
|
|
273
|
+
var DataComponentApiUpdateSchema = createApiUpdateSchema(
|
|
274
|
+
DataComponentUpdateSchema
|
|
275
|
+
).openapi("DataComponentUpdate");
|
|
242
276
|
var SubAgentDataComponentSelectSchema = createSelectSchema(subAgentDataComponents);
|
|
243
277
|
var SubAgentDataComponentInsertSchema = createInsertSchema(subAgentDataComponents);
|
|
244
278
|
var SubAgentDataComponentUpdateSchema = SubAgentDataComponentInsertSchema.partial();
|
|
245
|
-
var SubAgentDataComponentApiSelectSchema =
|
|
279
|
+
var SubAgentDataComponentApiSelectSchema = createAgentScopedApiSchema(
|
|
246
280
|
SubAgentDataComponentSelectSchema
|
|
247
281
|
);
|
|
248
282
|
var SubAgentDataComponentApiInsertSchema = SubAgentDataComponentInsertSchema.omit({
|
|
@@ -251,7 +285,7 @@ var SubAgentDataComponentApiInsertSchema = SubAgentDataComponentInsertSchema.omi
|
|
|
251
285
|
id: true,
|
|
252
286
|
createdAt: true
|
|
253
287
|
});
|
|
254
|
-
var SubAgentDataComponentApiUpdateSchema =
|
|
288
|
+
var SubAgentDataComponentApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
255
289
|
SubAgentDataComponentUpdateSchema
|
|
256
290
|
);
|
|
257
291
|
var ArtifactComponentSelectSchema = createSelectSchema(artifactComponents);
|
|
@@ -259,16 +293,18 @@ var ArtifactComponentInsertSchema = createInsertSchema(artifactComponents).exten
|
|
|
259
293
|
id: resourceIdSchema
|
|
260
294
|
});
|
|
261
295
|
var ArtifactComponentUpdateSchema = ArtifactComponentInsertSchema.partial();
|
|
262
|
-
var ArtifactComponentApiSelectSchema = createApiSchema(
|
|
296
|
+
var ArtifactComponentApiSelectSchema = createApiSchema(
|
|
297
|
+
ArtifactComponentSelectSchema
|
|
298
|
+
).openapi("ArtifactComponent");
|
|
263
299
|
var ArtifactComponentApiInsertSchema = ArtifactComponentInsertSchema.omit({
|
|
264
300
|
tenantId: true,
|
|
265
301
|
projectId: true,
|
|
266
302
|
createdAt: true,
|
|
267
303
|
updatedAt: true
|
|
268
|
-
});
|
|
304
|
+
}).openapi("ArtifactComponentCreate");
|
|
269
305
|
var ArtifactComponentApiUpdateSchema = createApiUpdateSchema(
|
|
270
306
|
ArtifactComponentUpdateSchema
|
|
271
|
-
);
|
|
307
|
+
).openapi("ArtifactComponentUpdate");
|
|
272
308
|
var SubAgentArtifactComponentSelectSchema = createSelectSchema(subAgentArtifactComponents);
|
|
273
309
|
var SubAgentArtifactComponentInsertSchema = createInsertSchema(
|
|
274
310
|
subAgentArtifactComponents
|
|
@@ -278,7 +314,7 @@ var SubAgentArtifactComponentInsertSchema = createInsertSchema(
|
|
|
278
314
|
artifactComponentId: resourceIdSchema
|
|
279
315
|
});
|
|
280
316
|
var SubAgentArtifactComponentUpdateSchema = SubAgentArtifactComponentInsertSchema.partial();
|
|
281
|
-
var SubAgentArtifactComponentApiSelectSchema =
|
|
317
|
+
var SubAgentArtifactComponentApiSelectSchema = createAgentScopedApiSchema(
|
|
282
318
|
SubAgentArtifactComponentSelectSchema
|
|
283
319
|
);
|
|
284
320
|
var SubAgentArtifactComponentApiInsertSchema = SubAgentArtifactComponentInsertSchema.omit({
|
|
@@ -287,7 +323,7 @@ var SubAgentArtifactComponentApiInsertSchema = SubAgentArtifactComponentInsertSc
|
|
|
287
323
|
id: true,
|
|
288
324
|
createdAt: true
|
|
289
325
|
});
|
|
290
|
-
var SubAgentArtifactComponentApiUpdateSchema =
|
|
326
|
+
var SubAgentArtifactComponentApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
291
327
|
SubAgentArtifactComponentUpdateSchema
|
|
292
328
|
);
|
|
293
329
|
var ExternalAgentSelectSchema = createSelectSchema(externalAgents).extend({
|
|
@@ -298,9 +334,15 @@ var ExternalAgentInsertSchema = createInsertSchema(externalAgents).extend({
|
|
|
298
334
|
id: resourceIdSchema
|
|
299
335
|
});
|
|
300
336
|
var ExternalAgentUpdateSchema = ExternalAgentInsertSchema.partial();
|
|
301
|
-
var ExternalAgentApiSelectSchema =
|
|
302
|
-
|
|
303
|
-
|
|
337
|
+
var ExternalAgentApiSelectSchema = createAgentScopedApiSchema(
|
|
338
|
+
ExternalAgentSelectSchema
|
|
339
|
+
).openapi("ExternalAgent");
|
|
340
|
+
var ExternalAgentApiInsertSchema = createAgentScopedApiInsertSchema(
|
|
341
|
+
ExternalAgentInsertSchema
|
|
342
|
+
).openapi("ExternalAgentCreate");
|
|
343
|
+
var ExternalAgentApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
344
|
+
ExternalAgentUpdateSchema
|
|
345
|
+
).openapi("ExternalAgentUpdate");
|
|
304
346
|
var AllAgentSchema = z.discriminatedUnion("type", [
|
|
305
347
|
SubAgentApiSelectSchema.extend({ type: z.literal("internal") }),
|
|
306
348
|
ExternalAgentApiSelectSchema.extend({ type: z.literal("external") })
|
|
@@ -308,7 +350,7 @@ var AllAgentSchema = z.discriminatedUnion("type", [
|
|
|
308
350
|
var ApiKeySelectSchema = createSelectSchema(apiKeys);
|
|
309
351
|
var ApiKeyInsertSchema = createInsertSchema(apiKeys).extend({
|
|
310
352
|
id: resourceIdSchema,
|
|
311
|
-
|
|
353
|
+
agentId: resourceIdSchema
|
|
312
354
|
});
|
|
313
355
|
var ApiKeyUpdateSchema = ApiKeyInsertSchema.partial().omit({
|
|
314
356
|
tenantId: true,
|
|
@@ -324,7 +366,7 @@ var ApiKeyApiSelectSchema = ApiKeySelectSchema.omit({
|
|
|
324
366
|
projectId: true,
|
|
325
367
|
keyHash: true
|
|
326
368
|
// Never expose the hash
|
|
327
|
-
});
|
|
369
|
+
}).openapi("ApiKey");
|
|
328
370
|
var ApiKeyApiCreationResponseSchema = z.object({
|
|
329
371
|
data: z.object({
|
|
330
372
|
apiKey: ApiKeyApiSelectSchema,
|
|
@@ -344,8 +386,8 @@ var ApiKeyApiInsertSchema = ApiKeyInsertSchema.omit({
|
|
|
344
386
|
// Auto-generated
|
|
345
387
|
lastUsedAt: true
|
|
346
388
|
// Not set on creation
|
|
347
|
-
});
|
|
348
|
-
var ApiKeyApiUpdateSchema = ApiKeyUpdateSchema;
|
|
389
|
+
}).openapi("ApiKeyCreate");
|
|
390
|
+
var ApiKeyApiUpdateSchema = ApiKeyUpdateSchema.openapi("ApiKeyUpdate");
|
|
349
391
|
var CredentialReferenceSelectSchema = z.object({
|
|
350
392
|
id: z.string(),
|
|
351
393
|
tenantId: z.string(),
|
|
@@ -368,17 +410,17 @@ var CredentialReferenceApiSelectSchema = createApiSchema(
|
|
|
368
410
|
).extend({
|
|
369
411
|
type: z.enum(CredentialStoreType),
|
|
370
412
|
tools: z.array(ToolSelectSchema).optional()
|
|
371
|
-
});
|
|
413
|
+
}).openapi("CredentialReference");
|
|
372
414
|
var CredentialReferenceApiInsertSchema = createApiInsertSchema(
|
|
373
415
|
CredentialReferenceInsertSchema
|
|
374
416
|
).extend({
|
|
375
417
|
type: z.enum(CredentialStoreType)
|
|
376
|
-
});
|
|
418
|
+
}).openapi("CredentialReferenceCreate");
|
|
377
419
|
var CredentialReferenceApiUpdateSchema = createApiUpdateSchema(
|
|
378
420
|
CredentialReferenceUpdateSchema
|
|
379
421
|
).extend({
|
|
380
422
|
type: z.enum(CredentialStoreType).optional()
|
|
381
|
-
});
|
|
423
|
+
}).openapi("CredentialReferenceUpdate");
|
|
382
424
|
var McpToolSchema = ToolInsertSchema.extend({
|
|
383
425
|
imageUrl: imageUrlSchema,
|
|
384
426
|
availableTools: z.array(McpToolDefinitionSchema).optional(),
|
|
@@ -407,25 +449,35 @@ var MCPToolConfigSchema = McpToolSchema.omit({
|
|
|
407
449
|
credential: CredentialReferenceApiInsertSchema.optional()
|
|
408
450
|
});
|
|
409
451
|
var ToolUpdateSchema = ToolInsertSchema.partial();
|
|
410
|
-
var ToolApiSelectSchema = createApiSchema(ToolSelectSchema);
|
|
411
|
-
var ToolApiInsertSchema = createApiInsertSchema(ToolInsertSchema);
|
|
412
|
-
var ToolApiUpdateSchema = createApiUpdateSchema(ToolUpdateSchema);
|
|
452
|
+
var ToolApiSelectSchema = createApiSchema(ToolSelectSchema).openapi("Tool");
|
|
453
|
+
var ToolApiInsertSchema = createApiInsertSchema(ToolInsertSchema).openapi("ToolCreate");
|
|
454
|
+
var ToolApiUpdateSchema = createApiUpdateSchema(ToolUpdateSchema).openapi("ToolUpdate");
|
|
413
455
|
var FunctionToolSelectSchema = createSelectSchema(functionTools);
|
|
414
456
|
var FunctionToolInsertSchema = createInsertSchema(functionTools).extend({
|
|
415
457
|
id: resourceIdSchema
|
|
416
458
|
});
|
|
417
459
|
var FunctionToolUpdateSchema = FunctionToolInsertSchema.partial();
|
|
418
|
-
var FunctionToolApiSelectSchema = createApiSchema(FunctionToolSelectSchema)
|
|
419
|
-
|
|
420
|
-
|
|
460
|
+
var FunctionToolApiSelectSchema = createApiSchema(FunctionToolSelectSchema).openapi(
|
|
461
|
+
"FunctionTool"
|
|
462
|
+
);
|
|
463
|
+
var FunctionToolApiInsertSchema = createAgentScopedApiInsertSchema(
|
|
464
|
+
FunctionToolInsertSchema
|
|
465
|
+
).openapi("FunctionToolCreate");
|
|
466
|
+
var FunctionToolApiUpdateSchema = createApiUpdateSchema(
|
|
467
|
+
FunctionToolUpdateSchema
|
|
468
|
+
).openapi("FunctionToolUpdate");
|
|
421
469
|
var FunctionSelectSchema = createSelectSchema(functions);
|
|
422
470
|
var FunctionInsertSchema = createInsertSchema(functions).extend({
|
|
423
471
|
id: resourceIdSchema
|
|
424
472
|
});
|
|
425
473
|
var FunctionUpdateSchema = FunctionInsertSchema.partial();
|
|
426
|
-
var FunctionApiSelectSchema = createApiSchema(FunctionSelectSchema);
|
|
427
|
-
var FunctionApiInsertSchema = createApiInsertSchema(FunctionInsertSchema)
|
|
428
|
-
|
|
474
|
+
var FunctionApiSelectSchema = createApiSchema(FunctionSelectSchema).openapi("Function");
|
|
475
|
+
var FunctionApiInsertSchema = createApiInsertSchema(FunctionInsertSchema).openapi(
|
|
476
|
+
"FunctionCreate"
|
|
477
|
+
);
|
|
478
|
+
var FunctionApiUpdateSchema = createApiUpdateSchema(FunctionUpdateSchema).openapi(
|
|
479
|
+
"FunctionUpdate"
|
|
480
|
+
);
|
|
429
481
|
var FetchConfigSchema = z.object({
|
|
430
482
|
url: z.string().min(1, "URL is required"),
|
|
431
483
|
method: z.enum(["GET", "POST", "PUT", "DELETE", "PATCH"]).optional().default("GET"),
|
|
@@ -434,7 +486,7 @@ var FetchConfigSchema = z.object({
|
|
|
434
486
|
transform: z.string().optional(),
|
|
435
487
|
// JSONPath or JS transform function
|
|
436
488
|
timeout: z.number().min(0).optional().default(1e4).optional()
|
|
437
|
-
});
|
|
489
|
+
}).openapi("FetchConfig");
|
|
438
490
|
var FetchDefinitionSchema = z.object({
|
|
439
491
|
id: z.string().min(1, "Fetch definition ID is required"),
|
|
440
492
|
name: z.string().optional(),
|
|
@@ -442,29 +494,41 @@ var FetchDefinitionSchema = z.object({
|
|
|
442
494
|
fetchConfig: FetchConfigSchema,
|
|
443
495
|
responseSchema: z.any().optional(),
|
|
444
496
|
// JSON Schema for validating HTTP response
|
|
445
|
-
defaultValue: z.
|
|
497
|
+
defaultValue: z.any().optional().openapi({
|
|
498
|
+
description: "Default value if fetch fails"
|
|
499
|
+
}),
|
|
446
500
|
credential: CredentialReferenceApiInsertSchema.optional()
|
|
447
|
-
});
|
|
501
|
+
}).openapi("FetchDefinition");
|
|
448
502
|
var ContextConfigSelectSchema = createSelectSchema(contextConfigs).extend({
|
|
449
|
-
headersSchema: z.
|
|
503
|
+
headersSchema: z.any().optional().openapi({
|
|
504
|
+
type: "object",
|
|
505
|
+
description: "JSON Schema for validating request headers"
|
|
506
|
+
})
|
|
450
507
|
});
|
|
451
508
|
var ContextConfigInsertSchema = createInsertSchema(contextConfigs).extend({
|
|
452
509
|
id: resourceIdSchema.optional(),
|
|
453
|
-
headersSchema: z.
|
|
510
|
+
headersSchema: z.any().nullable().optional().openapi({
|
|
511
|
+
type: "object",
|
|
512
|
+
description: "JSON Schema for validating request headers"
|
|
513
|
+
}),
|
|
514
|
+
contextVariables: z.any().nullable().optional().openapi({
|
|
515
|
+
type: "object",
|
|
516
|
+
description: "Context variables configuration with fetch definitions"
|
|
517
|
+
})
|
|
454
518
|
}).omit({
|
|
455
519
|
createdAt: true,
|
|
456
520
|
updatedAt: true
|
|
457
521
|
});
|
|
458
522
|
var ContextConfigUpdateSchema = ContextConfigInsertSchema.partial();
|
|
459
523
|
var ContextConfigApiSelectSchema = createApiSchema(ContextConfigSelectSchema).omit({
|
|
460
|
-
|
|
461
|
-
});
|
|
524
|
+
agentId: true
|
|
525
|
+
}).openapi("ContextConfig");
|
|
462
526
|
var ContextConfigApiInsertSchema = createApiInsertSchema(ContextConfigInsertSchema).omit({
|
|
463
|
-
|
|
464
|
-
});
|
|
527
|
+
agentId: true
|
|
528
|
+
}).openapi("ContextConfigCreate");
|
|
465
529
|
var ContextConfigApiUpdateSchema = createApiUpdateSchema(ContextConfigUpdateSchema).omit({
|
|
466
|
-
|
|
467
|
-
});
|
|
530
|
+
agentId: true
|
|
531
|
+
}).openapi("ContextConfigUpdate");
|
|
468
532
|
var SubAgentToolRelationSelectSchema = createSelectSchema(subAgentToolRelations);
|
|
469
533
|
var SubAgentToolRelationInsertSchema = createInsertSchema(subAgentToolRelations).extend({
|
|
470
534
|
id: resourceIdSchema,
|
|
@@ -474,15 +538,15 @@ var SubAgentToolRelationInsertSchema = createInsertSchema(subAgentToolRelations)
|
|
|
474
538
|
headers: z.record(z.string(), z.string()).nullish()
|
|
475
539
|
});
|
|
476
540
|
var SubAgentToolRelationUpdateSchema = SubAgentToolRelationInsertSchema.partial();
|
|
477
|
-
var SubAgentToolRelationApiSelectSchema =
|
|
541
|
+
var SubAgentToolRelationApiSelectSchema = createAgentScopedApiSchema(
|
|
478
542
|
SubAgentToolRelationSelectSchema
|
|
479
|
-
);
|
|
480
|
-
var SubAgentToolRelationApiInsertSchema =
|
|
543
|
+
).openapi("SubAgentToolRelation");
|
|
544
|
+
var SubAgentToolRelationApiInsertSchema = createAgentScopedApiInsertSchema(
|
|
481
545
|
SubAgentToolRelationInsertSchema
|
|
482
|
-
);
|
|
483
|
-
var SubAgentToolRelationApiUpdateSchema =
|
|
546
|
+
).openapi("SubAgentToolRelationCreate");
|
|
547
|
+
var SubAgentToolRelationApiUpdateSchema = createAgentScopedApiUpdateSchema(
|
|
484
548
|
SubAgentToolRelationUpdateSchema
|
|
485
|
-
);
|
|
549
|
+
).openapi("SubAgentToolRelationUpdate");
|
|
486
550
|
var LedgerArtifactSelectSchema = createSelectSchema(ledgerArtifacts);
|
|
487
551
|
var LedgerArtifactInsertSchema = createInsertSchema(ledgerArtifacts);
|
|
488
552
|
var LedgerArtifactUpdateSchema = LedgerArtifactInsertSchema.partial();
|
|
@@ -497,21 +561,21 @@ var StatusComponentSchema = z.object({
|
|
|
497
561
|
properties: z.record(z.string(), z.any()),
|
|
498
562
|
required: z.array(z.string()).optional()
|
|
499
563
|
}).optional()
|
|
500
|
-
});
|
|
564
|
+
}).openapi("StatusComponent");
|
|
501
565
|
var StatusUpdateSchema = z.object({
|
|
502
566
|
enabled: z.boolean().optional(),
|
|
503
567
|
numEvents: z.number().min(1).max(100).optional(),
|
|
504
568
|
timeInSeconds: z.number().min(1).max(600).optional(),
|
|
505
569
|
prompt: z.string().max(2e3, "Custom prompt cannot exceed 2000 characters").optional(),
|
|
506
570
|
statusComponents: z.array(StatusComponentSchema).optional()
|
|
507
|
-
});
|
|
571
|
+
}).openapi("StatusUpdate");
|
|
508
572
|
var CanUseItemSchema = z.object({
|
|
509
573
|
agentToolRelationId: z.string().optional(),
|
|
510
574
|
toolId: z.string(),
|
|
511
575
|
toolSelection: z.array(z.string()).nullish(),
|
|
512
576
|
headers: z.record(z.string(), z.string()).nullish()
|
|
513
|
-
});
|
|
514
|
-
var
|
|
577
|
+
}).openapi("CanUseItem");
|
|
578
|
+
var FullAgentAgentInsertSchema = SubAgentApiInsertSchema.extend({
|
|
515
579
|
type: z.literal("internal"),
|
|
516
580
|
canUse: z.array(CanUseItemSchema),
|
|
517
581
|
// All tools (both MCP and function tools)
|
|
@@ -520,51 +584,30 @@ var FullGraphAgentInsertSchema = SubAgentApiInsertSchema.extend({
|
|
|
520
584
|
canTransferTo: z.array(z.string()).optional(),
|
|
521
585
|
canDelegateTo: z.array(z.string()).optional()
|
|
522
586
|
});
|
|
523
|
-
var
|
|
587
|
+
var AgentWithinContextOfProjectSchema = AgentApiInsertSchema.extend({
|
|
524
588
|
subAgents: z.record(
|
|
525
589
|
z.string(),
|
|
526
|
-
z.union([
|
|
590
|
+
z.union([FullAgentAgentInsertSchema, ExternalAgentApiInsertSchema])
|
|
527
591
|
),
|
|
528
592
|
// Lookup maps for UI to resolve canUse items
|
|
529
593
|
tools: z.record(z.string(), ToolApiInsertSchema).optional(),
|
|
530
594
|
// MCP tools (project-scoped)
|
|
531
595
|
functionTools: z.record(z.string(), FunctionToolApiInsertSchema).optional(),
|
|
532
|
-
// Function tools (
|
|
596
|
+
// Function tools (agent-scoped)
|
|
533
597
|
functions: z.record(z.string(), FunctionApiInsertSchema).optional(),
|
|
534
598
|
// Get function code for function tools
|
|
535
599
|
contextConfig: z.optional(ContextConfigApiInsertSchema),
|
|
536
600
|
statusUpdates: z.optional(StatusUpdateSchema),
|
|
537
601
|
models: ModelSchema.optional(),
|
|
538
|
-
stopWhen:
|
|
539
|
-
|
|
540
|
-
});
|
|
541
|
-
var GraphWithinContextOfProjectSchema = AgentGraphApiInsertSchema.extend({
|
|
542
|
-
subAgents: z.record(
|
|
543
|
-
z.string(),
|
|
544
|
-
z.discriminatedUnion("type", [
|
|
545
|
-
FullGraphAgentInsertSchema,
|
|
546
|
-
ExternalAgentApiInsertSchema.extend({ type: z.literal("external") })
|
|
547
|
-
])
|
|
548
|
-
),
|
|
549
|
-
// Lookup maps for UI to resolve canUse items
|
|
550
|
-
tools: z.record(z.string(), ToolApiInsertSchema).optional(),
|
|
551
|
-
// MCP tools (project-scoped)
|
|
552
|
-
functionTools: z.record(z.string(), FunctionToolApiInsertSchema).optional(),
|
|
553
|
-
// Function tools (graph-scoped)
|
|
554
|
-
functions: z.record(z.string(), FunctionApiInsertSchema).optional(),
|
|
555
|
-
// Get function code for function tools
|
|
556
|
-
contextConfig: z.optional(ContextConfigApiInsertSchema),
|
|
557
|
-
statusUpdates: z.optional(StatusUpdateSchema),
|
|
558
|
-
models: ModelSchema.optional(),
|
|
559
|
-
stopWhen: GraphStopWhenSchema.optional(),
|
|
560
|
-
graphPrompt: z.string().max(5e3, "Graph prompt cannot exceed 5000 characters").optional()
|
|
602
|
+
stopWhen: AgentStopWhenSchema.optional(),
|
|
603
|
+
prompt: z.string().max(5e3, "Agent prompt cannot exceed 5000 characters").optional()
|
|
561
604
|
});
|
|
562
605
|
var PaginationSchema = z.object({
|
|
563
606
|
page: z.coerce.number().min(1).default(1),
|
|
564
607
|
limit: z.coerce.number().min(1).max(100).default(10),
|
|
565
608
|
total: z.number(),
|
|
566
609
|
pages: z.number()
|
|
567
|
-
});
|
|
610
|
+
}).openapi("Pagination");
|
|
568
611
|
var ListResponseSchema = (itemSchema) => z.object({
|
|
569
612
|
data: z.array(itemSchema),
|
|
570
613
|
pagination: PaginationSchema
|
|
@@ -575,15 +618,17 @@ var SingleResponseSchema = (itemSchema) => z.object({
|
|
|
575
618
|
var ErrorResponseSchema = z.object({
|
|
576
619
|
error: z.string(),
|
|
577
620
|
message: z.string().optional(),
|
|
578
|
-
details: z.
|
|
579
|
-
|
|
621
|
+
details: z.any().optional().openapi({
|
|
622
|
+
description: "Additional error details"
|
|
623
|
+
})
|
|
624
|
+
}).openapi("ErrorResponse");
|
|
580
625
|
var ExistsResponseSchema = z.object({
|
|
581
626
|
exists: z.boolean()
|
|
582
|
-
});
|
|
627
|
+
}).openapi("ExistsResponse");
|
|
583
628
|
var RemovedResponseSchema = z.object({
|
|
584
629
|
message: z.string(),
|
|
585
630
|
removed: z.boolean()
|
|
586
|
-
});
|
|
631
|
+
}).openapi("RemovedResponse");
|
|
587
632
|
var ProjectSelectSchema = createSelectSchema(projects);
|
|
588
633
|
var ProjectInsertSchema = createInsertSchema(projects).extend({
|
|
589
634
|
models: ProjectModelSchema,
|
|
@@ -594,15 +639,19 @@ var ProjectInsertSchema = createInsertSchema(projects).extend({
|
|
|
594
639
|
updatedAt: true
|
|
595
640
|
});
|
|
596
641
|
var ProjectUpdateSchema = ProjectInsertSchema.partial();
|
|
597
|
-
var ProjectApiSelectSchema = ProjectSelectSchema.omit({ tenantId: true })
|
|
598
|
-
|
|
599
|
-
|
|
642
|
+
var ProjectApiSelectSchema = ProjectSelectSchema.omit({ tenantId: true }).openapi(
|
|
643
|
+
"Project"
|
|
644
|
+
);
|
|
645
|
+
var ProjectApiInsertSchema = ProjectInsertSchema.omit({ tenantId: true }).openapi(
|
|
646
|
+
"ProjectCreate"
|
|
647
|
+
);
|
|
648
|
+
var ProjectApiUpdateSchema = ProjectUpdateSchema.omit({ tenantId: true }).openapi(
|
|
649
|
+
"ProjectUpdate"
|
|
650
|
+
);
|
|
600
651
|
var FullProjectDefinitionSchema = ProjectApiInsertSchema.extend({
|
|
601
|
-
|
|
652
|
+
agents: z.record(z.string(), AgentWithinContextOfProjectSchema),
|
|
602
653
|
tools: z.record(z.string(), ToolApiInsertSchema),
|
|
603
|
-
// MCP tools (project-scoped)
|
|
604
654
|
functions: z.record(z.string(), FunctionApiInsertSchema).optional(),
|
|
605
|
-
// Functions (project-scoped)
|
|
606
655
|
dataComponents: z.record(z.string(), DataComponentApiInsertSchema).optional(),
|
|
607
656
|
artifactComponents: z.record(z.string(), ArtifactComponentApiInsertSchema).optional(),
|
|
608
657
|
statusUpdates: z.optional(StatusUpdateSchema),
|
|
@@ -610,6 +659,96 @@ var FullProjectDefinitionSchema = ProjectApiInsertSchema.extend({
|
|
|
610
659
|
createdAt: z.string().optional(),
|
|
611
660
|
updatedAt: z.string().optional()
|
|
612
661
|
});
|
|
662
|
+
var ProjectResponse = z.object({ data: ProjectApiSelectSchema }).openapi("ProjectResponse");
|
|
663
|
+
var SubAgentResponse = z.object({ data: SubAgentApiSelectSchema }).openapi("SubAgentResponse");
|
|
664
|
+
var AgentResponse = z.object({ data: AgentApiSelectSchema }).openapi("AgentResponse");
|
|
665
|
+
var ToolResponse = z.object({ data: ToolApiSelectSchema }).openapi("ToolResponse");
|
|
666
|
+
var ExternalAgentResponse = z.object({ data: ExternalAgentApiSelectSchema }).openapi("ExternalAgentResponse");
|
|
667
|
+
var ContextConfigResponse = z.object({ data: ContextConfigApiSelectSchema }).openapi("ContextConfigResponse");
|
|
668
|
+
var ApiKeyResponse = z.object({ data: ApiKeyApiSelectSchema }).openapi("ApiKeyResponse");
|
|
669
|
+
var CredentialReferenceResponse = z.object({ data: CredentialReferenceApiSelectSchema }).openapi("CredentialReferenceResponse");
|
|
670
|
+
var FunctionResponse = z.object({ data: FunctionApiSelectSchema }).openapi("FunctionResponse");
|
|
671
|
+
var FunctionToolResponse = z.object({ data: FunctionToolApiSelectSchema }).openapi("FunctionToolResponse");
|
|
672
|
+
var DataComponentResponse = z.object({ data: DataComponentApiSelectSchema }).openapi("DataComponentResponse");
|
|
673
|
+
var ArtifactComponentResponse = z.object({ data: ArtifactComponentApiSelectSchema }).openapi("ArtifactComponentResponse");
|
|
674
|
+
var SubAgentRelationResponse = z.object({ data: SubAgentRelationApiSelectSchema }).openapi("SubAgentRelationResponse");
|
|
675
|
+
var SubAgentToolRelationResponse = z.object({ data: SubAgentToolRelationApiSelectSchema }).openapi("SubAgentToolRelationResponse");
|
|
676
|
+
var ConversationResponse = z.object({ data: ConversationApiSelectSchema }).openapi("ConversationResponse");
|
|
677
|
+
var MessageResponse = z.object({ data: MessageApiSelectSchema }).openapi("MessageResponse");
|
|
678
|
+
var ProjectListResponse = z.object({
|
|
679
|
+
data: z.array(ProjectApiSelectSchema),
|
|
680
|
+
pagination: PaginationSchema
|
|
681
|
+
}).openapi("ProjectListResponse");
|
|
682
|
+
var SubAgentListResponse = z.object({
|
|
683
|
+
data: z.array(SubAgentApiSelectSchema),
|
|
684
|
+
pagination: PaginationSchema
|
|
685
|
+
}).openapi("SubAgentListResponse");
|
|
686
|
+
var AgentListResponse = z.object({
|
|
687
|
+
data: z.array(AgentApiSelectSchema),
|
|
688
|
+
pagination: PaginationSchema
|
|
689
|
+
}).openapi("AgentListResponse");
|
|
690
|
+
var ToolListResponse = z.object({
|
|
691
|
+
data: z.array(ToolApiSelectSchema),
|
|
692
|
+
pagination: PaginationSchema
|
|
693
|
+
}).openapi("ToolListResponse");
|
|
694
|
+
var ExternalAgentListResponse = z.object({
|
|
695
|
+
data: z.array(ExternalAgentApiSelectSchema),
|
|
696
|
+
pagination: PaginationSchema
|
|
697
|
+
}).openapi("ExternalAgentListResponse");
|
|
698
|
+
var ContextConfigListResponse = z.object({
|
|
699
|
+
data: z.array(ContextConfigApiSelectSchema),
|
|
700
|
+
pagination: PaginationSchema
|
|
701
|
+
}).openapi("ContextConfigListResponse");
|
|
702
|
+
var ApiKeyListResponse = z.object({
|
|
703
|
+
data: z.array(ApiKeyApiSelectSchema),
|
|
704
|
+
pagination: PaginationSchema
|
|
705
|
+
}).openapi("ApiKeyListResponse");
|
|
706
|
+
var CredentialReferenceListResponse = z.object({
|
|
707
|
+
data: z.array(CredentialReferenceApiSelectSchema),
|
|
708
|
+
pagination: PaginationSchema
|
|
709
|
+
}).openapi("CredentialReferenceListResponse");
|
|
710
|
+
var FunctionListResponse = z.object({
|
|
711
|
+
data: z.array(FunctionApiSelectSchema),
|
|
712
|
+
pagination: PaginationSchema
|
|
713
|
+
}).openapi("FunctionListResponse");
|
|
714
|
+
var FunctionToolListResponse = z.object({
|
|
715
|
+
data: z.array(FunctionToolApiSelectSchema),
|
|
716
|
+
pagination: PaginationSchema
|
|
717
|
+
}).openapi("FunctionToolListResponse");
|
|
718
|
+
var DataComponentListResponse = z.object({
|
|
719
|
+
data: z.array(DataComponentApiSelectSchema),
|
|
720
|
+
pagination: PaginationSchema
|
|
721
|
+
}).openapi("DataComponentListResponse");
|
|
722
|
+
var ArtifactComponentListResponse = z.object({
|
|
723
|
+
data: z.array(ArtifactComponentApiSelectSchema),
|
|
724
|
+
pagination: PaginationSchema
|
|
725
|
+
}).openapi("ArtifactComponentListResponse");
|
|
726
|
+
var SubAgentRelationListResponse = z.object({
|
|
727
|
+
data: z.array(SubAgentRelationApiSelectSchema),
|
|
728
|
+
pagination: PaginationSchema
|
|
729
|
+
}).openapi("SubAgentRelationListResponse");
|
|
730
|
+
var SubAgentToolRelationListResponse = z.object({
|
|
731
|
+
data: z.array(SubAgentToolRelationApiSelectSchema),
|
|
732
|
+
pagination: PaginationSchema
|
|
733
|
+
}).openapi("SubAgentToolRelationListResponse");
|
|
734
|
+
var ConversationListResponse = z.object({
|
|
735
|
+
data: z.array(ConversationApiSelectSchema),
|
|
736
|
+
pagination: PaginationSchema
|
|
737
|
+
}).openapi("ConversationListResponse");
|
|
738
|
+
var MessageListResponse = z.object({
|
|
739
|
+
data: z.array(MessageApiSelectSchema),
|
|
740
|
+
pagination: PaginationSchema
|
|
741
|
+
}).openapi("MessageListResponse");
|
|
742
|
+
var SubAgentDataComponentResponse = z.object({ data: SubAgentDataComponentApiSelectSchema }).openapi("SubAgentDataComponentResponse");
|
|
743
|
+
var SubAgentArtifactComponentResponse = z.object({ data: SubAgentArtifactComponentApiSelectSchema }).openapi("SubAgentArtifactComponentResponse");
|
|
744
|
+
var SubAgentDataComponentListResponse = z.object({
|
|
745
|
+
data: z.array(SubAgentDataComponentApiSelectSchema),
|
|
746
|
+
pagination: PaginationSchema
|
|
747
|
+
}).openapi("SubAgentDataComponentListResponse");
|
|
748
|
+
var SubAgentArtifactComponentListResponse = z.object({
|
|
749
|
+
data: z.array(SubAgentArtifactComponentApiSelectSchema),
|
|
750
|
+
pagination: PaginationSchema
|
|
751
|
+
}).openapi("SubAgentArtifactComponentListResponse");
|
|
613
752
|
var HeadersScopeSchema = z.object({
|
|
614
753
|
"x-inkeep-tenant-id": z.string().optional().openapi({
|
|
615
754
|
description: "Tenant identifier",
|
|
@@ -619,9 +758,9 @@ var HeadersScopeSchema = z.object({
|
|
|
619
758
|
description: "Project identifier",
|
|
620
759
|
example: "project_456"
|
|
621
760
|
}),
|
|
622
|
-
"x-inkeep-
|
|
623
|
-
description: "
|
|
624
|
-
example: "
|
|
761
|
+
"x-inkeep-agent-id": z.string().optional().openapi({
|
|
762
|
+
description: "Agent identifier",
|
|
763
|
+
example: "agent_789"
|
|
625
764
|
})
|
|
626
765
|
});
|
|
627
766
|
var TenantId = z.string().openapi({
|
|
@@ -632,9 +771,9 @@ var ProjectId = z.string().openapi({
|
|
|
632
771
|
description: "Project identifier",
|
|
633
772
|
example: "project_456"
|
|
634
773
|
});
|
|
635
|
-
var
|
|
636
|
-
description: "
|
|
637
|
-
example: "
|
|
774
|
+
var AgentId = z.string().openapi({
|
|
775
|
+
description: "Agent identifier",
|
|
776
|
+
example: "agent_789"
|
|
638
777
|
});
|
|
639
778
|
var SubAgentId = z.string().openapi({
|
|
640
779
|
description: "Sub-agent identifier",
|
|
@@ -652,18 +791,18 @@ var TenantProjectParamsSchema = TenantParamsSchema.extend({
|
|
|
652
791
|
var TenantProjectIdParamsSchema = TenantProjectParamsSchema.extend({
|
|
653
792
|
id: resourceIdSchema
|
|
654
793
|
}).openapi("TenantProjectIdParams");
|
|
655
|
-
var
|
|
656
|
-
|
|
657
|
-
}).openapi("
|
|
658
|
-
var
|
|
794
|
+
var TenantProjectAgentParamsSchema = TenantProjectParamsSchema.extend({
|
|
795
|
+
agentId: AgentId
|
|
796
|
+
}).openapi("TenantProjectAgentParams");
|
|
797
|
+
var TenantProjectAgentIdParamsSchema = TenantProjectAgentParamsSchema.extend({
|
|
659
798
|
id: resourceIdSchema
|
|
660
|
-
}).openapi("
|
|
661
|
-
var
|
|
799
|
+
}).openapi("TenantProjectAgentIdParams");
|
|
800
|
+
var TenantProjectAgentSubAgentParamsSchema = TenantProjectAgentParamsSchema.extend({
|
|
662
801
|
subAgentId: SubAgentId
|
|
663
|
-
}).openapi("
|
|
664
|
-
var
|
|
802
|
+
}).openapi("TenantProjectAgentSubAgentParams");
|
|
803
|
+
var TenantProjectAgentSubAgentIdParamsSchema = TenantProjectAgentSubAgentParamsSchema.extend({
|
|
665
804
|
id: resourceIdSchema
|
|
666
|
-
}).openapi("
|
|
805
|
+
}).openapi("TenantProjectAgentSubAgentIdParams");
|
|
667
806
|
var PaginationQueryParamsSchema = z.object({
|
|
668
807
|
page: z.coerce.number().min(1).default(1),
|
|
669
808
|
limit: z.coerce.number().min(1).max(100).default(10)
|
|
@@ -771,4 +910,4 @@ function validatePropsAsJsonSchema(props) {
|
|
|
771
910
|
}
|
|
772
911
|
}
|
|
773
912
|
|
|
774
|
-
export {
|
|
913
|
+
export { AgentApiInsertSchema, AgentApiSelectSchema, AgentApiUpdateSchema, AgentInsertSchema, AgentListResponse, AgentResponse, AgentSelectSchema, AgentStopWhenSchema, AgentUpdateSchema, AgentWithinContextOfProjectSchema, AllAgentSchema, ApiKeyApiCreationResponseSchema, ApiKeyApiInsertSchema, ApiKeyApiSelectSchema, ApiKeyApiUpdateSchema, ApiKeyInsertSchema, ApiKeyListResponse, ApiKeyResponse, ApiKeySelectSchema, ApiKeyUpdateSchema, ArtifactComponentApiInsertSchema, ArtifactComponentApiSelectSchema, ArtifactComponentApiUpdateSchema, ArtifactComponentInsertSchema, ArtifactComponentListResponse, ArtifactComponentResponse, ArtifactComponentSelectSchema, ArtifactComponentUpdateSchema, CanUseItemSchema, ContextCacheApiInsertSchema, ContextCacheApiSelectSchema, ContextCacheApiUpdateSchema, ContextCacheInsertSchema, ContextCacheSelectSchema, ContextCacheUpdateSchema, ContextConfigApiInsertSchema, ContextConfigApiSelectSchema, ContextConfigApiUpdateSchema, ContextConfigInsertSchema, ContextConfigListResponse, ContextConfigResponse, ContextConfigSelectSchema, ContextConfigUpdateSchema, ConversationApiInsertSchema, ConversationApiSelectSchema, ConversationApiUpdateSchema, ConversationInsertSchema, ConversationListResponse, ConversationResponse, ConversationSelectSchema, ConversationUpdateSchema, CredentialReferenceApiInsertSchema, CredentialReferenceApiSelectSchema, CredentialReferenceApiUpdateSchema, CredentialReferenceInsertSchema, CredentialReferenceListResponse, CredentialReferenceResponse, CredentialReferenceSelectSchema, CredentialReferenceUpdateSchema, DataComponentApiInsertSchema, DataComponentApiSelectSchema, DataComponentApiUpdateSchema, DataComponentBaseSchema, DataComponentInsertSchema, DataComponentListResponse, DataComponentResponse, DataComponentSelectSchema, DataComponentUpdateSchema, ErrorResponseSchema, ExistsResponseSchema, ExternalAgentApiInsertSchema, ExternalAgentApiSelectSchema, ExternalAgentApiUpdateSchema, ExternalAgentInsertSchema, ExternalAgentListResponse, ExternalAgentResponse, ExternalAgentSelectSchema, ExternalAgentUpdateSchema, ExternalSubAgentRelationApiInsertSchema, ExternalSubAgentRelationInsertSchema, FetchConfigSchema, FetchDefinitionSchema, FullAgentAgentInsertSchema, FullProjectDefinitionSchema, FunctionApiInsertSchema, FunctionApiSelectSchema, FunctionApiUpdateSchema, FunctionInsertSchema, FunctionListResponse, FunctionResponse, FunctionSelectSchema, FunctionToolApiInsertSchema, FunctionToolApiSelectSchema, FunctionToolApiUpdateSchema, FunctionToolConfigSchema, FunctionToolInsertSchema, FunctionToolListResponse, FunctionToolResponse, FunctionToolSelectSchema, FunctionToolUpdateSchema, FunctionUpdateSchema, HeadersScopeSchema, LedgerArtifactApiInsertSchema, LedgerArtifactApiSelectSchema, LedgerArtifactApiUpdateSchema, LedgerArtifactInsertSchema, LedgerArtifactSelectSchema, LedgerArtifactUpdateSchema, ListResponseSchema, MAX_ID_LENGTH, MCPToolConfigSchema, MIN_ID_LENGTH, McpToolDefinitionSchema, McpToolSchema, McpTransportConfigSchema, MessageApiInsertSchema, MessageApiSelectSchema, MessageApiUpdateSchema, MessageInsertSchema, MessageListResponse, MessageResponse, MessageSelectSchema, MessageUpdateSchema, ModelSchema, ModelSettingsSchema, PaginationQueryParamsSchema, PaginationSchema, ProjectApiInsertSchema, ProjectApiSelectSchema, ProjectApiUpdateSchema, ProjectInsertSchema, ProjectListResponse, ProjectModelSchema, ProjectResponse, ProjectSelectSchema, ProjectUpdateSchema, RemovedResponseSchema, SandboxConfigSchema, SingleResponseSchema, StatusComponentSchema, StatusUpdateSchema, StopWhenSchema, SubAgentApiInsertSchema, SubAgentApiSelectSchema, SubAgentApiUpdateSchema, SubAgentArtifactComponentApiInsertSchema, SubAgentArtifactComponentApiSelectSchema, SubAgentArtifactComponentApiUpdateSchema, SubAgentArtifactComponentInsertSchema, SubAgentArtifactComponentListResponse, SubAgentArtifactComponentResponse, SubAgentArtifactComponentSelectSchema, SubAgentArtifactComponentUpdateSchema, SubAgentDataComponentApiInsertSchema, SubAgentDataComponentApiSelectSchema, SubAgentDataComponentApiUpdateSchema, SubAgentDataComponentInsertSchema, SubAgentDataComponentListResponse, SubAgentDataComponentResponse, SubAgentDataComponentSelectSchema, SubAgentDataComponentUpdateSchema, SubAgentInsertSchema, SubAgentListResponse, SubAgentRelationApiInsertSchema, SubAgentRelationApiSelectSchema, SubAgentRelationApiUpdateSchema, SubAgentRelationInsertSchema, SubAgentRelationListResponse, SubAgentRelationQuerySchema, SubAgentRelationResponse, SubAgentRelationSelectSchema, SubAgentRelationUpdateSchema, SubAgentResponse, SubAgentSelectSchema, SubAgentStopWhenSchema, SubAgentToolRelationApiInsertSchema, SubAgentToolRelationApiSelectSchema, SubAgentToolRelationApiUpdateSchema, SubAgentToolRelationInsertSchema, SubAgentToolRelationListResponse, SubAgentToolRelationResponse, SubAgentToolRelationSelectSchema, SubAgentToolRelationUpdateSchema, SubAgentUpdateSchema, TaskApiInsertSchema, TaskApiSelectSchema, TaskApiUpdateSchema, TaskInsertSchema, TaskRelationApiInsertSchema, TaskRelationApiSelectSchema, TaskRelationApiUpdateSchema, TaskRelationInsertSchema, TaskRelationSelectSchema, TaskRelationUpdateSchema, TaskSelectSchema, TaskUpdateSchema, TenantIdParamsSchema, TenantParamsSchema, TenantProjectAgentIdParamsSchema, TenantProjectAgentParamsSchema, TenantProjectAgentSubAgentIdParamsSchema, TenantProjectAgentSubAgentParamsSchema, TenantProjectIdParamsSchema, TenantProjectParamsSchema, ToolApiInsertSchema, ToolApiSelectSchema, ToolApiUpdateSchema, ToolInsertSchema, ToolListResponse, ToolResponse, ToolSelectSchema, ToolStatusSchema, ToolUpdateSchema, URL_SAFE_ID_PATTERN, resourceIdSchema, validatePropsAsJsonSchema };
|