@inkeep/agents-core 0.58.10 → 0.58.12
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/auth/auth-schema.d.ts +107 -107
- package/dist/auth/auth-validation-schemas.d.ts +152 -152
- package/dist/auth/auth.d.ts +9 -9
- package/dist/auth/permissions.d.ts +9 -9
- package/dist/client-exports.d.ts +2 -2
- package/dist/client-exports.js +2 -2
- package/dist/data-access/manage/credentialReferences.d.ts +2 -2
- package/dist/data-access/manage/credentialReferences.js +46 -18
- package/dist/data-access/manage/tools.d.ts +4 -3
- package/dist/data-access/manage/triggers.d.ts +2 -2
- package/dist/data-access/runtime/apiKeys.d.ts +4 -4
- package/dist/data-access/runtime/conversations.d.ts +7 -7
- package/dist/data-access/runtime/messages.d.ts +12 -12
- package/dist/data-access/runtime/scheduledTriggerInvocations.d.ts +3 -3
- package/dist/data-access/runtime/tasks.d.ts +4 -4
- package/dist/db/manage/manage-schema.d.ts +453 -453
- package/dist/db/runtime/runtime-schema.d.ts +332 -332
- package/dist/validation/dolt-schemas.d.ts +1 -1
- package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
- package/dist/validation/extend-schemas.d.ts +5 -1
- package/dist/validation/schemas.d.ts +2042 -2853
- package/dist/validation/schemas.js +34 -9
- package/package.json +1 -1
|
@@ -201,7 +201,10 @@ const AgentInsertSchema = createInsertSchema(agents, {
|
|
|
201
201
|
});
|
|
202
202
|
const AgentUpdateSchema = AgentInsertSchema.partial();
|
|
203
203
|
const AgentApiSelectSchema = createApiSchema(AgentSelectSchema).openapi("Agent");
|
|
204
|
-
const AgentApiInsertSchema = createApiInsertSchema(AgentInsertSchema).extend({ id: ResourceIdSchema }).
|
|
204
|
+
const AgentApiInsertSchema = createApiInsertSchema(AgentInsertSchema).extend({ id: ResourceIdSchema }).omit({
|
|
205
|
+
createdAt: true,
|
|
206
|
+
updatedAt: true
|
|
207
|
+
}).openapi("AgentCreate");
|
|
205
208
|
const AgentApiUpdateSchema = createApiUpdateSchema(AgentUpdateSchema).openapi("AgentUpdate");
|
|
206
209
|
const TriggerAuthHeaderInputSchema = z.object({
|
|
207
210
|
name: z.string().min(1).describe("Header name (e.g., X-API-Key, Authorization)"),
|
|
@@ -479,7 +482,10 @@ const TriggerInsertSchema = createInsertSchema(triggers, {
|
|
|
479
482
|
});
|
|
480
483
|
const TriggerUpdateSchema = TriggerInsertSchema.extend({ enabled: z.boolean().optional().describe("Whether the trigger is enabled") }).partial();
|
|
481
484
|
const TriggerApiSelectSchema = createAgentScopedApiSchema(TriggerSelectSchema).openapi("Trigger");
|
|
482
|
-
const TriggerApiInsertSchema = createAgentScopedApiInsertSchema(TriggerInsertSchema).extend({ id: ResourceIdSchema.optional() }).
|
|
485
|
+
const TriggerApiInsertSchema = createAgentScopedApiInsertSchema(TriggerInsertSchema).extend({ id: ResourceIdSchema.optional() }).omit({
|
|
486
|
+
createdAt: true,
|
|
487
|
+
updatedAt: true
|
|
488
|
+
}).openapi("TriggerCreate");
|
|
483
489
|
const TriggerApiUpdateSchema = TriggerUpdateSchema.openapi("TriggerUpdate");
|
|
484
490
|
const TriggerWithWebhookUrlSchema = TriggerApiSelectSchema.extend({ webhookUrl: z.string().describe("Fully qualified webhook URL for this trigger") }).openapi("TriggerWithWebhookUrl");
|
|
485
491
|
const TriggerInvocationSelectSchema = createSelectSchema(triggerInvocations);
|
|
@@ -516,6 +522,9 @@ const ScheduledTriggerInsertSchemaBase = createInsertSchema(scheduledTriggers, {
|
|
|
516
522
|
retryDelaySeconds: () => z.number().int().min(10).max(3600).default(60),
|
|
517
523
|
timeoutSeconds: () => z.number().int().min(30).max(780).default(780),
|
|
518
524
|
createdBy: () => UserIdSchema.nullable().optional().describe("User ID of the user who created this trigger")
|
|
525
|
+
}).omit({
|
|
526
|
+
createdAt: true,
|
|
527
|
+
updatedAt: true
|
|
519
528
|
});
|
|
520
529
|
const ScheduledTriggerInsertSchema = ScheduledTriggerInsertSchemaBase.refine((data) => data.cronExpression || data.runAt, { message: "Either cronExpression or runAt must be provided" }).refine((data) => !(data.cronExpression && data.runAt), { message: "Cannot specify both cronExpression and runAt" });
|
|
521
530
|
const ScheduledTriggerUpdateSchema = ScheduledTriggerInsertSchemaBase.extend({
|
|
@@ -647,6 +656,9 @@ const ToolInsertSchema = createInsertSchema(tools).extend({
|
|
|
647
656
|
prompt: z.string().optional()
|
|
648
657
|
})
|
|
649
658
|
})
|
|
659
|
+
}).omit({
|
|
660
|
+
createdAt: true,
|
|
661
|
+
updatedAt: true
|
|
650
662
|
});
|
|
651
663
|
const ConversationSelectSchema = createSelectSchema(conversations);
|
|
652
664
|
const ConversationInsertSchema = createInsertSchema(conversations).extend({
|
|
@@ -819,7 +831,10 @@ const SkillApiSelectSchema = createApiSchema(SkillSelectSchema).openapi("Skill")
|
|
|
819
831
|
const SkillApiInsertSchema = createApiInsertSchema(SkillInsertSchema).openapi("SkillCreate");
|
|
820
832
|
const SkillApiUpdateSchema = createApiUpdateSchema(SkillUpdateSchema).openapi("SkillUpdate");
|
|
821
833
|
const DataComponentSelectSchema = createSelectSchema(dataComponents);
|
|
822
|
-
const DataComponentInsertSchema = createInsertSchema(dataComponents).extend({ id: ResourceIdSchema })
|
|
834
|
+
const DataComponentInsertSchema = createInsertSchema(dataComponents).extend({ id: ResourceIdSchema }).omit({
|
|
835
|
+
createdAt: true,
|
|
836
|
+
updatedAt: true
|
|
837
|
+
});
|
|
823
838
|
const DataComponentUpdateSchema = DataComponentInsertSchema.partial();
|
|
824
839
|
const DataComponentApiSelectSchema = createApiSchema(DataComponentSelectSchema).openapi("DataComponent");
|
|
825
840
|
const DataComponentApiInsertSchema = createApiInsertSchema(DataComponentInsertSchema).extend(DataComponentExtendSchema).openapi("DataComponentCreate");
|
|
@@ -892,6 +907,9 @@ const ExternalAgentInsertSchema = createInsertSchema(externalAgents).extend({
|
|
|
892
907
|
description: DescriptionSchema,
|
|
893
908
|
baseUrl: z.url(),
|
|
894
909
|
credentialReferenceId: z.string().trim().nonempty().max(256).nullish()
|
|
910
|
+
}).omit({
|
|
911
|
+
createdAt: true,
|
|
912
|
+
updatedAt: true
|
|
895
913
|
});
|
|
896
914
|
const ExternalAgentUpdateSchema = ExternalAgentInsertSchema.partial();
|
|
897
915
|
const ExternalAgentApiSelectSchema = createApiSchema(ExternalAgentSelectSchema).openapi("ExternalAgent");
|
|
@@ -976,6 +994,9 @@ const CredentialReferenceInsertSchema = createInsertSchema(credentialReferences)
|
|
|
976
994
|
type: z.string(),
|
|
977
995
|
credentialStoreId: ResourceIdSchema,
|
|
978
996
|
retrievalParams: z.record(z.string(), z.unknown()).nullish()
|
|
997
|
+
}).omit({
|
|
998
|
+
createdAt: true,
|
|
999
|
+
updatedAt: true
|
|
979
1000
|
});
|
|
980
1001
|
const CredentialReferenceUpdateSchema = CredentialReferenceInsertSchema.partial();
|
|
981
1002
|
const CredentialReferenceApiSelectSchema = createApiSchema(CredentialReferenceSelectSchema).extend({
|
|
@@ -1037,8 +1058,6 @@ const MCPToolConfigSchema = McpToolSchema.omit({
|
|
|
1037
1058
|
projectId: true,
|
|
1038
1059
|
status: true,
|
|
1039
1060
|
version: true,
|
|
1040
|
-
createdAt: true,
|
|
1041
|
-
updatedAt: true,
|
|
1042
1061
|
credentialReferenceId: true
|
|
1043
1062
|
}).extend({
|
|
1044
1063
|
tenantId: z.string().optional(),
|
|
@@ -1062,7 +1081,10 @@ const ToolApiSelectSchema = createApiSchema(ToolSelectSchema).openapi("Tool");
|
|
|
1062
1081
|
const ToolApiInsertSchema = createApiInsertSchema(ToolInsertSchema).openapi("ToolCreate");
|
|
1063
1082
|
const ToolApiUpdateSchema = createApiUpdateSchema(ToolUpdateSchema).openapi("ToolUpdate");
|
|
1064
1083
|
const FunctionToolSelectSchema = createSelectSchema(functionTools);
|
|
1065
|
-
const FunctionToolInsertSchema = createInsertSchema(functionTools).extend({ id: ResourceIdSchema })
|
|
1084
|
+
const FunctionToolInsertSchema = createInsertSchema(functionTools).extend({ id: ResourceIdSchema }).omit({
|
|
1085
|
+
createdAt: true,
|
|
1086
|
+
updatedAt: true
|
|
1087
|
+
});
|
|
1066
1088
|
const FunctionToolUpdateSchema = FunctionToolInsertSchema.partial();
|
|
1067
1089
|
const FunctionToolApiSelectSchema = createApiSchema(FunctionToolSelectSchema).extend({ relationshipId: z.string().optional() }).openapi("FunctionTool");
|
|
1068
1090
|
const FunctionToolApiInsertSchema = createAgentScopedApiInsertSchema(FunctionToolInsertSchema).openapi("FunctionToolCreate");
|
|
@@ -1092,8 +1114,8 @@ const validateExecuteCode = (val, ctx) => {
|
|
|
1092
1114
|
if (isAnonymousFunction) val = `(${val})`;
|
|
1093
1115
|
const { body } = parse(val, { sourceType: "module" }).program;
|
|
1094
1116
|
for (const node of body) {
|
|
1095
|
-
if (node.type === "ExportDefaultDeclaration") throw SyntaxError("Export default declarations are not supported. Provide a single function instead.");
|
|
1096
|
-
if (node.type === "ExportNamedDeclaration") throw SyntaxError("Export declarations are not supported. Provide a single function instead.");
|
|
1117
|
+
if (node.type === "ExportDefaultDeclaration") throw new SyntaxError("Export default declarations are not supported. Provide a single function instead.");
|
|
1118
|
+
if (node.type === "ExportNamedDeclaration") throw new SyntaxError("Export declarations are not supported. Provide a single function instead.");
|
|
1097
1119
|
}
|
|
1098
1120
|
const functionsCount = body.filter((node) => {
|
|
1099
1121
|
if (node.type === "FunctionDeclaration") return true;
|
|
@@ -1114,7 +1136,10 @@ const validateExecuteCode = (val, ctx) => {
|
|
|
1114
1136
|
});
|
|
1115
1137
|
}
|
|
1116
1138
|
};
|
|
1117
|
-
const FunctionApiInsertSchema = createApiInsertSchema(FunctionInsertSchema).
|
|
1139
|
+
const FunctionApiInsertSchema = createApiInsertSchema(FunctionInsertSchema).extend({ executeCode: z.string().trim().nonempty().superRefine(validateExecuteCode) }).omit({
|
|
1140
|
+
createdAt: true,
|
|
1141
|
+
updatedAt: true
|
|
1142
|
+
}).openapi("FunctionCreate");
|
|
1118
1143
|
const FunctionApiUpdateSchema = createApiUpdateSchema(FunctionUpdateSchema).openapi("FunctionUpdate");
|
|
1119
1144
|
const FetchConfigSchema = z.object({
|
|
1120
1145
|
url: z.string().min(1, "URL is required"),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inkeep/agents-core",
|
|
3
|
-
"version": "0.58.
|
|
3
|
+
"version": "0.58.12",
|
|
4
4
|
"description": "Agents Core contains the database schema, types, and validation schemas for Inkeep Agent Framework, along with core components.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|