@inkeep/agents-core 0.0.0-dev-20260408074257 → 0.0.0-dev-20260408163536
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-validation-schemas.d.ts +17 -17
- package/dist/auth/auth.d.ts +6 -6
- package/dist/auth/permissions.d.ts +13 -13
- package/dist/data-access/index.d.ts +3 -3
- package/dist/data-access/manage/agentFull.d.ts +7 -12
- package/dist/data-access/manage/agentFull.js +14 -16
- package/dist/data-access/manage/agents.d.ts +42 -42
- package/dist/data-access/manage/artifactComponents.d.ts +16 -16
- package/dist/data-access/manage/contextConfigs.d.ts +12 -12
- package/dist/data-access/manage/dataComponents.d.ts +6 -6
- package/dist/data-access/manage/functionTools.d.ts +18 -18
- package/dist/data-access/manage/projectFull.d.ts +6 -8
- package/dist/data-access/manage/projectFull.js +18 -18
- package/dist/data-access/manage/skills.d.ts +16 -16
- package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +24 -24
- package/dist/data-access/manage/subAgentRelations.d.ts +28 -28
- package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +24 -24
- package/dist/data-access/manage/subAgents.d.ts +18 -18
- package/dist/data-access/manage/tools.d.ts +30 -30
- package/dist/data-access/manage/triggers.d.ts +4 -4
- package/dist/data-access/runtime/apiKeys.d.ts +16 -16
- package/dist/data-access/runtime/apps.d.ts +12 -12
- package/dist/data-access/runtime/conversations.d.ts +28 -28
- package/dist/data-access/runtime/feedback.d.ts +8 -8
- package/dist/data-access/runtime/messages.d.ts +24 -24
- package/dist/data-access/runtime/scheduledTriggerUsers.d.ts +1 -1
- package/dist/data-access/runtime/tasks.d.ts +8 -8
- package/dist/db/manage/manage-schema.d.ts +8 -8
- package/dist/db/runtime/runtime-schema.d.ts +371 -371
- package/dist/index.d.ts +3 -3
- package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
- package/dist/validation/schemas/skills.d.ts +49 -49
- package/dist/validation/schemas.d.ts +1116 -1116
- package/package.json +1 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { z } from "@hono/zod-openapi";
|
|
2
2
|
import * as drizzle_orm_pg_core84 from "drizzle-orm/pg-core";
|
|
3
|
-
import * as
|
|
3
|
+
import * as drizzle_zod0 from "drizzle-zod";
|
|
4
4
|
|
|
5
5
|
//#region src/auth/auth-validation-schemas.d.ts
|
|
6
|
-
declare const UserSelectSchema:
|
|
6
|
+
declare const UserSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
7
7
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
8
8
|
name: "id";
|
|
9
9
|
tableName: "user";
|
|
@@ -124,7 +124,7 @@ declare const UserSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
124
124
|
generated: undefined;
|
|
125
125
|
}, {}, {}>;
|
|
126
126
|
}, undefined, undefined>;
|
|
127
|
-
declare const UserInsertSchema:
|
|
127
|
+
declare const UserInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
128
128
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
129
129
|
name: "id";
|
|
130
130
|
tableName: "user";
|
|
@@ -245,7 +245,7 @@ declare const UserInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
245
245
|
generated: undefined;
|
|
246
246
|
}, {}, {}>;
|
|
247
247
|
}, undefined, undefined>;
|
|
248
|
-
declare const SessionSelectSchema:
|
|
248
|
+
declare const SessionSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
249
249
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
250
250
|
name: "id";
|
|
251
251
|
tableName: "session";
|
|
@@ -400,7 +400,7 @@ declare const SessionSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
400
400
|
generated: undefined;
|
|
401
401
|
}, {}, {}>;
|
|
402
402
|
}, undefined, undefined>;
|
|
403
|
-
declare const SessionInsertSchema:
|
|
403
|
+
declare const SessionInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
404
404
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
405
405
|
name: "id";
|
|
406
406
|
tableName: "session";
|
|
@@ -555,7 +555,7 @@ declare const SessionInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
555
555
|
generated: undefined;
|
|
556
556
|
}, {}, {}>;
|
|
557
557
|
}, undefined, undefined>;
|
|
558
|
-
declare const AccountSelectSchema:
|
|
558
|
+
declare const AccountSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
559
559
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
560
560
|
name: "id";
|
|
561
561
|
tableName: "account";
|
|
@@ -778,7 +778,7 @@ declare const AccountSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
778
778
|
generated: undefined;
|
|
779
779
|
}, {}, {}>;
|
|
780
780
|
}, undefined, undefined>;
|
|
781
|
-
declare const AccountInsertSchema:
|
|
781
|
+
declare const AccountInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
782
782
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
783
783
|
name: "id";
|
|
784
784
|
tableName: "account";
|
|
@@ -1001,7 +1001,7 @@ declare const AccountInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
1001
1001
|
generated: undefined;
|
|
1002
1002
|
}, {}, {}>;
|
|
1003
1003
|
}, undefined, undefined>;
|
|
1004
|
-
declare const OrganizationSelectSchema:
|
|
1004
|
+
declare const OrganizationSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
1005
1005
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1006
1006
|
name: "id";
|
|
1007
1007
|
tableName: "organization";
|
|
@@ -1156,7 +1156,7 @@ declare const OrganizationSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
1156
1156
|
generated: undefined;
|
|
1157
1157
|
}, {}, {}>;
|
|
1158
1158
|
}, undefined, undefined>;
|
|
1159
|
-
declare const OrganizationInsertSchema:
|
|
1159
|
+
declare const OrganizationInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
1160
1160
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1161
1161
|
name: "id";
|
|
1162
1162
|
tableName: "organization";
|
|
@@ -1311,7 +1311,7 @@ declare const OrganizationInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
1311
1311
|
generated: undefined;
|
|
1312
1312
|
}, {}, {}>;
|
|
1313
1313
|
}, undefined, undefined>;
|
|
1314
|
-
declare const MemberSelectSchema:
|
|
1314
|
+
declare const MemberSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
1315
1315
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1316
1316
|
name: "id";
|
|
1317
1317
|
tableName: "member";
|
|
@@ -1398,7 +1398,7 @@ declare const MemberSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
1398
1398
|
generated: undefined;
|
|
1399
1399
|
}, {}, {}>;
|
|
1400
1400
|
}, undefined, undefined>;
|
|
1401
|
-
declare const MemberInsertSchema:
|
|
1401
|
+
declare const MemberInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
1402
1402
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1403
1403
|
name: "id";
|
|
1404
1404
|
tableName: "member";
|
|
@@ -1485,7 +1485,7 @@ declare const MemberInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
1485
1485
|
generated: undefined;
|
|
1486
1486
|
}, {}, {}>;
|
|
1487
1487
|
}, undefined, undefined>;
|
|
1488
|
-
declare const InvitationSelectSchema:
|
|
1488
|
+
declare const InvitationSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
1489
1489
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1490
1490
|
name: "id";
|
|
1491
1491
|
tableName: "invitation";
|
|
@@ -1640,7 +1640,7 @@ declare const InvitationSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
1640
1640
|
generated: undefined;
|
|
1641
1641
|
}, {}, {}>;
|
|
1642
1642
|
}, undefined, undefined>;
|
|
1643
|
-
declare const InvitationInsertSchema:
|
|
1643
|
+
declare const InvitationInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
1644
1644
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1645
1645
|
name: "id";
|
|
1646
1646
|
tableName: "invitation";
|
|
@@ -1795,7 +1795,7 @@ declare const InvitationInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
1795
1795
|
generated: undefined;
|
|
1796
1796
|
}, {}, {}>;
|
|
1797
1797
|
}, undefined, undefined>;
|
|
1798
|
-
declare const DeviceCodeSelectSchema:
|
|
1798
|
+
declare const DeviceCodeSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
1799
1799
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1800
1800
|
name: "id";
|
|
1801
1801
|
tableName: "device_code";
|
|
@@ -1967,7 +1967,7 @@ declare const DeviceCodeSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
1967
1967
|
generated: undefined;
|
|
1968
1968
|
}, {}, {}>;
|
|
1969
1969
|
}, undefined, undefined>;
|
|
1970
|
-
declare const DeviceCodeInsertSchema:
|
|
1970
|
+
declare const DeviceCodeInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
1971
1971
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
1972
1972
|
name: "id";
|
|
1973
1973
|
tableName: "device_code";
|
|
@@ -2139,7 +2139,7 @@ declare const DeviceCodeInsertSchema: drizzle_zod3.BuildSchema<"insert", {
|
|
|
2139
2139
|
generated: undefined;
|
|
2140
2140
|
}, {}, {}>;
|
|
2141
2141
|
}, undefined, undefined>;
|
|
2142
|
-
declare const VerificationSelectSchema:
|
|
2142
|
+
declare const VerificationSelectSchema: drizzle_zod0.BuildSchema<"select", {
|
|
2143
2143
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
2144
2144
|
name: "id";
|
|
2145
2145
|
tableName: "verification";
|
|
@@ -2243,7 +2243,7 @@ declare const VerificationSelectSchema: drizzle_zod3.BuildSchema<"select", {
|
|
|
2243
2243
|
generated: undefined;
|
|
2244
2244
|
}, {}, {}>;
|
|
2245
2245
|
}, undefined, undefined>;
|
|
2246
|
-
declare const VerificationInsertSchema:
|
|
2246
|
+
declare const VerificationInsertSchema: drizzle_zod0.BuildSchema<"insert", {
|
|
2247
2247
|
id: drizzle_orm_pg_core84.PgColumn<{
|
|
2248
2248
|
name: "id";
|
|
2249
2249
|
tableName: "verification";
|
package/dist/auth/auth.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { BetterAuthConfig, EmailServiceConfig, OIDCProviderConfig, SAMLProviderC
|
|
|
2
2
|
import { extractCookieDomain, hasCredentialAccount } from "./auth-config-utils.js";
|
|
3
3
|
import * as zod0 from "zod";
|
|
4
4
|
import * as better_auth0 from "better-auth";
|
|
5
|
-
import * as
|
|
5
|
+
import * as better_auth_plugins0 from "better-auth/plugins";
|
|
6
6
|
|
|
7
7
|
//#region src/auth/auth.d.ts
|
|
8
8
|
|
|
@@ -38,10 +38,10 @@ declare function _inferAuthType(): better_auth0.Auth<{
|
|
|
38
38
|
handler: (inputContext: better_auth0.MiddlewareInputContext<better_auth0.MiddlewareOptions>) => Promise<void>;
|
|
39
39
|
}[];
|
|
40
40
|
};
|
|
41
|
-
options:
|
|
41
|
+
options: better_auth_plugins0.BearerOptions | undefined;
|
|
42
42
|
}, {
|
|
43
43
|
id: "oauth-proxy";
|
|
44
|
-
options: NoInfer<
|
|
44
|
+
options: NoInfer<better_auth_plugins0.OAuthProxyOptions>;
|
|
45
45
|
endpoints: {
|
|
46
46
|
oAuthProxy: better_auth0.StrictEndpoint<"/oauth-proxy-callback", {
|
|
47
47
|
method: "GET";
|
|
@@ -93,7 +93,7 @@ declare function _inferAuthType(): better_auth0.Auth<{
|
|
|
93
93
|
handler: (inputContext: better_auth0.MiddlewareInputContext<better_auth0.MiddlewareOptions>) => Promise<void>;
|
|
94
94
|
}[];
|
|
95
95
|
};
|
|
96
|
-
},
|
|
96
|
+
}, better_auth_plugins0.DefaultOrganizationPlugin<{
|
|
97
97
|
schema: {
|
|
98
98
|
invitation: {
|
|
99
99
|
additionalFields: {
|
|
@@ -456,8 +456,8 @@ declare function _inferAuthType(): better_auth0.Auth<{
|
|
|
456
456
|
AUTHENTICATION_REQUIRED: better_auth0.RawError<"AUTHENTICATION_REQUIRED">;
|
|
457
457
|
};
|
|
458
458
|
options: Partial<{
|
|
459
|
-
expiresIn:
|
|
460
|
-
interval:
|
|
459
|
+
expiresIn: better_auth_plugins0.TimeString;
|
|
460
|
+
interval: better_auth_plugins0.TimeString;
|
|
461
461
|
deviceCodeLength: number;
|
|
462
462
|
userCodeLength: number;
|
|
463
463
|
schema: {
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as better_auth_plugins4 from "better-auth/plugins";
|
|
2
2
|
import { AccessControl } from "better-auth/plugins/access";
|
|
3
3
|
import { organizationClient } from "better-auth/client/plugins";
|
|
4
4
|
|
|
5
5
|
//#region src/auth/permissions.d.ts
|
|
6
6
|
declare const ac: AccessControl;
|
|
7
7
|
declare const memberRole: {
|
|
8
|
-
authorize<K_1 extends "
|
|
9
|
-
actions:
|
|
8
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "team" | "ac">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key] | {
|
|
9
|
+
actions: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key];
|
|
10
10
|
connector: "OR" | "AND";
|
|
11
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
12
|
-
statements:
|
|
11
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins4.AuthorizeResponse;
|
|
12
|
+
statements: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>;
|
|
13
13
|
};
|
|
14
14
|
declare const adminRole: {
|
|
15
|
-
authorize<K_1 extends "
|
|
16
|
-
actions:
|
|
15
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "team" | "ac">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key] | {
|
|
16
|
+
actions: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key];
|
|
17
17
|
connector: "OR" | "AND";
|
|
18
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
19
|
-
statements:
|
|
18
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins4.AuthorizeResponse;
|
|
19
|
+
statements: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>;
|
|
20
20
|
};
|
|
21
21
|
declare const ownerRole: {
|
|
22
|
-
authorize<K_1 extends "
|
|
23
|
-
actions:
|
|
22
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "team" | "ac">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key] | {
|
|
23
|
+
actions: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>[key];
|
|
24
24
|
connector: "OR" | "AND";
|
|
25
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
26
|
-
statements:
|
|
25
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins4.AuthorizeResponse;
|
|
26
|
+
statements: better_auth_plugins4.Subset<"organization" | "member" | "invitation" | "project" | "team" | "ac", better_auth_plugins4.Statements>;
|
|
27
27
|
};
|
|
28
28
|
//#endregion
|
|
29
29
|
export { ac, adminRole, memberRole, organizationClient, ownerRole };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AgentsRunDatabaseClient, AgentsRunDatabaseConfig, createAgentsRunDatabaseClient } from "../db/runtime/runtime-client.js";
|
|
2
2
|
import { AgentsManageDatabaseClient, AgentsManageDatabaseConfig, createAgentManageDatabaseConnection, createAgentsManageDatabaseClient, createAgentsManageDatabasePool } from "../db/manage/manage-client.js";
|
|
3
|
-
import {
|
|
3
|
+
import { createFullAgentServerSide, deleteFullAgent, getFullAgent, getFullAgentWithRelationIds, updateFullAgentServerSide } from "./manage/agentFull.js";
|
|
4
4
|
import { AvailableAgentInfo, createAgent, deleteAgent, fetchComponentRelationships, getAgentById, getAgentSubAgentInfos, getAgentWithDefaultSubAgent, getFullAgentDefinition, getFullAgentDefinitionWithRelationIds, listAgents, listAgentsAcrossProjectMainBranches, listAgentsPaginated, updateAgent, upsertAgent } from "./manage/agents.js";
|
|
5
5
|
import { agentHasArtifactComponents, associateArtifactComponentWithAgent, countArtifactComponents, countArtifactComponentsForAgent, createArtifactComponent, deleteAgentArtifactComponentRelationByAgent, deleteArtifactComponent, getAgentsUsingArtifactComponent, getArtifactComponentById, getArtifactComponentsForAgent, isArtifactComponentAssociatedWithAgent, listArtifactComponents, listArtifactComponentsPaginated, removeArtifactComponentFromAgent, updateArtifactComponent, upsertAgentArtifactComponentRelation, upsertArtifactComponent } from "./manage/artifactComponents.js";
|
|
6
6
|
import { listAgentIdsByProject, listContextConfigIdsByProject, listToolIdsByProject } from "./manage/audit-queries.js";
|
|
@@ -11,7 +11,7 @@ import { createAgentDatasetRelation, createAgentEvaluatorRelation, createDataset
|
|
|
11
11
|
import { countExternalAgents, createExternalAgent, deleteExternalAgent, externalAgentExists, externalAgentUrlExists, getExternalAgent, getExternalAgentByUrl, listExternalAgents, listExternalAgentsPaginated, updateExternalAgent, upsertExternalAgent } from "./manage/externalAgents.js";
|
|
12
12
|
import { deleteFunction, getFunction, listFunctions, listFunctionsPaginated, upsertFunction } from "./manage/functions.js";
|
|
13
13
|
import { addFunctionToolToSubAgent, associateFunctionToolWithSubAgent, createFunctionTool, deleteFunctionTool, getFunctionToolById, getFunctionToolsForSubAgent, getSubAgentsUsingFunctionTool, isFunctionToolAssociatedWithSubAgent, listFunctionTools, removeFunctionToolFromSubAgent, updateFunctionTool, updateSubAgentFunctionToolRelation, upsertFunctionTool, upsertSubAgentFunctionToolRelation } from "./manage/functionTools.js";
|
|
14
|
-
import {
|
|
14
|
+
import { createFullProjectServerSide, deleteFullProject, getFullProject, getFullProjectWithRelationIds, updateFullProjectServerSide } from "./manage/projectFull.js";
|
|
15
15
|
import { CreateProjectWithBranchParams, CreateProjectWithBranchResult, DeleteProjectAndBranchesParams, ListProjectsWithMetadataResult, ProjectConfigMetadata, ProjectWithMetadata, createProjectMetadataAndBranch, deleteProjectAndBranches, getProjectMainBranchName, getProjectWithBranchInfo, getProjectWithMetadata, listProjectsWithMetadataPaginated } from "./manage/projectLifecycle.js";
|
|
16
16
|
import { countProjects, createProject, deleteProject, getProject, getProjectResourceCounts, listProjects, listProjectsPaginated, projectExists, projectExistsInTable, projectHasResources, updateProject } from "./manage/projects.js";
|
|
17
17
|
import { createSkill, createSkillFileById, deleteSkill, deleteSkillFileById, deleteSubAgentSkill, getSkillById, getSkillByIdWithFiles, getSkillFileById, getSkillFilesBySkillIds, getSkillsForSubAgents, listSkills, listSkillsWithFiles, updateSkill, updateSkillFileById, upsertSkill, upsertSubAgentSkill } from "./manage/skills.js";
|
|
@@ -49,4 +49,4 @@ import { getOrganizationMemberByEmail, getOrganizationMemberByUserId, getUserByE
|
|
|
49
49
|
import { WorkAppSlackChannelAgentConfigInsert, WorkAppSlackChannelAgentConfigSelect, WorkAppSlackUserMappingInsert, WorkAppSlackUserMappingSelect, WorkAppSlackWorkspaceInsert, WorkAppSlackWorkspaceSelect, clearDevConfigWorkspaceDefaultsByAgent, clearDevConfigWorkspaceDefaultsByProject, clearWorkspaceDefaultsByAgent, clearWorkspaceDefaultsByProject, createWorkAppSlackChannelAgentConfig, createWorkAppSlackUserMapping, createWorkAppSlackWorkspace, deleteAllWorkAppSlackChannelAgentConfigsByTeam, deleteAllWorkAppSlackUserMappingsByTeam, deleteWorkAppSlackChannelAgentConfig, deleteWorkAppSlackChannelAgentConfigsByAgent, deleteWorkAppSlackChannelAgentConfigsByProject, deleteWorkAppSlackUserMapping, deleteWorkAppSlackWorkspace, deleteWorkAppSlackWorkspaceByNangoConnectionId, findWorkAppSlackChannelAgentConfig, findWorkAppSlackUserMapping, findWorkAppSlackUserMappingByInkeepUserId, findWorkAppSlackUserMappingBySlackUser, findWorkAppSlackWorkspaceByNangoConnectionId, findWorkAppSlackWorkspaceBySlackTeamId, findWorkAppSlackWorkspaceByTeamId, listWorkAppSlackChannelAgentConfigsByTeam, listWorkAppSlackUserMappingsByTeam, listWorkAppSlackWorkspacesByTenant, updateWorkAppSlackWorkspace, upsertWorkAppSlackChannelAgentConfig } from "./runtime/workAppSlack.js";
|
|
50
50
|
import { createWorkflowExecution, getWorkflowExecution, getWorkflowExecutionByConversation, updateWorkflowExecutionStatus } from "./runtime/workflowExecutions.js";
|
|
51
51
|
import { createValidatedDataAccess, validateProjectExists, withProjectValidation } from "./validation.js";
|
|
52
|
-
export { AgentLogger, AgentsManageDatabaseClient, AgentsManageDatabaseConfig, AgentsRunDatabaseClient, AgentsRunDatabaseConfig, AvailableAgentInfo, CascadeDeleteResult, CreateProjectWithBranchParams, CreateProjectWithBranchResult, CredentialReferenceWithResources, DeleteProjectAndBranchesParams, ListProjectsWithMetadataResult, MethodOption, OrgAuthInfo, ProjectConfigMetadata, ProjectGitHubAccessCascadeDeleteResult, ProjectLogger, ProjectMetadataPaginatedResult, ProjectWithMetadata, SSOProviderLookupResult, ScheduledTriggerRunInfo, SlackMcpToolAccessConfig, SubAgentIsDefaultError, ToolCascadeDeleteResult, UpsertUserProfileData, UserProfile, UserProviderInfo, WorkAppGitHubAccessMode, WorkAppSlackChannelAgentConfigInsert, WorkAppSlackChannelAgentConfigSelect, WorkAppSlackUserMappingInsert, WorkAppSlackUserMappingSelect, WorkAppSlackWorkspaceInsert, WorkAppSlackWorkspaceSelect, addConversationIdToInvocation, addFunctionToolToSubAgent, addLedgerArtifacts, addRepositories, addToolToAgent, addUserToOrganization, advanceScheduledTriggerNextRunAt, agentHasArtifactComponents, allowedMethodsToMethodOptions, associateArtifactComponentWithAgent, associateDataComponentWithAgent, associateFunctionToolWithSubAgent, cancelPastPendingInvocationsForTrigger, cancelPendingInvocationsForTrigger, cascadeDeleteByAgent, cascadeDeleteByBranch, cascadeDeleteByContextConfig, cascadeDeleteByProject, cascadeDeleteBySubAgent, cascadeDeleteByTool, cascadeDeleteGitHubAccessByProject, checkProjectRepositoryAccess, cleanupExpiredStreamChunks, cleanupTenantCache, clearAppDefaultsByAgent, clearAppDefaultsByProject, clearContextConfigCache, clearConversationCache, clearDevConfigWorkspaceDefaultsByAgent, clearDevConfigWorkspaceDefaultsByProject, clearMcpToolRepositoryAccess, clearProjectRepositoryAccess, clearSchedulerState, clearWorkspaceDefaultsByAgent, clearWorkspaceDefaultsByProject, countApiKeys, countArtifactComponents, countArtifactComponentsForAgent, countContextConfigs, countCredentialReferences, countDataComponents, countExternalAgents, countLedgerArtifactsByTask, countMessagesByConversation, countProjects, countProjectsInRuntime, countVisibleMessages, createAgent, createAgentDatasetRelation, createAgentEvaluatorRelation, createAgentManageDatabaseConnection, createAgentToolRelation, createAgentsManageDatabaseClient, createAgentsManageDatabasePool, createAgentsRunDatabaseClient, createApiKey, createApp, createArtifactComponent, createContextConfig, createConversation, createCredentialReference, createDataComponent, createDataset, createDatasetItem, createDatasetItems, createDatasetRun, createDatasetRunConfig, createDatasetRunConfigAgentRelation, createDatasetRunConversationRelation, createDatasetRunConversationRelations, createEvaluationJobConfig, createEvaluationJobConfigEvaluatorRelation, createEvaluationResult, createEvaluationResults, createEvaluationRun, createEvaluationRunConfig, createEvaluationRunConfigEvaluationSuiteConfigRelation, createEvaluationSuiteConfig, createEvaluationSuiteConfigEvaluatorRelation, createEvaluator, createExternalAgent, createFeedback, createFullAgentServerSide, createFullProjectServerSide, createFunctionTool, createInstallation, createInvitationInDb, createMessage, createOrGetConversation, createProject, createProjectMetadata, createProjectMetadataAndBranch, createScheduledTrigger, createScheduledTriggerInvocation, createScheduledTriggerUser, createSkill, createSkillFileById, createSubAgent, createSubAgentExternalAgentRelation, createSubAgentRelation, createSubAgentTeamAgentRelation, createTask, createTool, createTrigger, createTriggerInvocation, createUserProfileIfNotExists, createValidatedDataAccess, createWorkAppSlackChannelAgentConfig, createWorkAppSlackUserMapping, createWorkAppSlackWorkspace, createWorkflowExecution, dalCountMembersByRoleBucket, dalGetServiceAccountUserId, dalResolveEntitlement, dalSumSeatEntitlements, dbResultToMcpTool, dbResultToMcpToolSkeleton, deleteAgent, deleteAgentArtifactComponentRelationByAgent, deleteAgentDataComponentRelationByAgent, deleteAgentDatasetRelation, deleteAgentEvaluatorRelation, deleteAgentRelationsByAgent, deleteAgentToolRelation, deleteAgentToolRelationByAgent, deleteAllSlackMcpToolAccessConfigsByTenant, deleteAllWorkAppSlackChannelAgentConfigsByTeam, deleteAllWorkAppSlackUserMappingsByTeam, deleteApiKey, deleteApp, deleteAppForProject, deleteAppForTenant, deleteAppsByProject, deleteArtifactComponent, deleteContextConfig, deleteConversation, deleteCredentialReference, deleteDataComponent, deleteDataset, deleteDatasetItem, deleteDatasetItemsByDataset, deleteDatasetRun, deleteDatasetRunConfig, deleteDatasetRunConfigAgentRelation, deleteDatasetRunConversationRelation, deleteDatasetRunConversationRelationsByRun, deleteEvaluationJobConfig, deleteEvaluationJobConfigEvaluatorRelation, deleteEvaluationJobConfigEvaluatorRelationsByEvaluator, deleteEvaluationResult, deleteEvaluationResultsByRun, deleteEvaluationRun, deleteEvaluationRunConfig, deleteEvaluationRunConfigEvaluationSuiteConfigRelation, deleteEvaluationSuiteConfig, deleteEvaluationSuiteConfigEvaluatorRelation, deleteEvaluationSuiteConfigEvaluatorRelationsByEvaluator, deleteEvaluator, deleteExternalAgent, deleteFeedback, deleteFullAgent, deleteFullProject, deleteFunction, deleteFunctionTool, deleteInstallation, deleteLedgerArtifactsByContext, deleteLedgerArtifactsByTask, deleteMcpToolAccessMode, deleteMessage, deletePendingInvocationsForTrigger, deleteProject, deleteProjectAccessMode, deleteProjectAndBranches, deleteProjectMetadata, deleteScheduledTrigger, deleteScheduledTriggerUser, deleteScheduledTriggersByRunAsUserId, deleteSkill, deleteSkillFileById, deleteSlackMcpToolAccessConfig, deleteStreamChunks, deleteSubAgent, deleteSubAgentExternalAgentRelation, deleteSubAgentExternalAgentRelationsByAgent, deleteSubAgentExternalAgentRelationsBySubAgent, deleteSubAgentRelation, deleteSubAgentSkill, deleteSubAgentTeamAgentRelation, deleteSubAgentTeamAgentRelationsByAgent, deleteSubAgentTeamAgentRelationsBySubAgent, deleteTool, deleteTrigger, deleteTriggersByRunAsUserId, deleteWorkAppSlackChannelAgentConfig, deleteWorkAppSlackChannelAgentConfigsByAgent, deleteWorkAppSlackChannelAgentConfigsByProject, deleteWorkAppSlackUserMapping, deleteWorkAppSlackWorkspace, deleteWorkAppSlackWorkspaceByNangoConnectionId, disconnectInstallation, externalAgentExists, externalAgentUrlExists, fetchComponentRelationships, filterConversationsForJob, findDueScheduledTriggersAcrossProjects, findWorkAppSlackChannelAgentConfig, findWorkAppSlackUserMapping, findWorkAppSlackUserMappingByInkeepUserId, findWorkAppSlackUserMappingBySlackUser, findWorkAppSlackWorkspaceByNangoConnectionId, findWorkAppSlackWorkspaceBySlackTeamId, findWorkAppSlackWorkspaceByTeamId, generateAndCreateApiKey, getActiveAgentForConversation, getAgentById, getAgentDatasetRelationsByAgent, getAgentDatasetRelationsByDataset, getAgentEvaluatorRelationsByAgent, getAgentEvaluatorRelationsByEvaluator, getAgentIdsForEvaluators, getAgentRelationById, getAgentRelationByParams, getAgentRelations, getAgentRelationsByAgent, getAgentRelationsBySource, getAgentSubAgentInfos, getAgentToolRelationByAgent, getAgentToolRelationById, getAgentToolRelationByTool, getAgentWithDefaultSubAgent, getAgentsForTool, getAgentsUsingArtifactComponent, getAgentsUsingDataComponent, getAllowedAuthMethods, getApiKeyById, getApiKeyByPublicId, getAppAuthKeysForProject, getAppById, getAppByIdForProject, getAppByIdForTenant, getArtifactComponentById, getArtifactComponentsForAgent, getAuthLookupForEmail, getCacheEntry, getContextConfigById, getContextConfigCacheEntries, getConversation, getConversationCacheEntries, getConversationHistory, getCredentialReference, getCredentialReferenceById, getCredentialReferenceWithResources, getDataComponent, getDataComponentsForAgent, getDatasetById, getDatasetItemById, getDatasetRunById, getDatasetRunConfigAgentRelations, getDatasetRunConfigById, getDatasetRunConversationRelationByConversation, getDatasetRunConversationRelations, getEvaluationJobConfigById, getEvaluationJobConfigEvaluatorRelations, getEvaluationResultById, getEvaluationRunById, getEvaluationRunByJobConfigId, getEvaluationRunConfigById, getEvaluationRunConfigEvaluationSuiteConfigRelations, getEvaluationSuiteConfigById, getEvaluationSuiteConfigEvaluatorRelations, getEvaluatorById, getEvaluatorsByIds, getExternalAgent, getExternalAgentByUrl, getExternalAgentsForSubAgent, getFeedbackById, getFilteredAuthMethodsForEmail, getFullAgent, getFullAgentDefinition, getFullAgentDefinitionWithRelationIds, getFullAgentWithRelationIds, getFullProject, getFullProjectWithRelationIds, getFunction, getFunctionToolById, getFunctionToolsForSubAgent, getInstallationByGitHubId, getInstallationById, getInstallationsByTenantId, getLedgerArtifacts, getLedgerArtifactsByContext, getMcpToolAccessMode, getMcpToolById, getMcpToolRepositoryAccess, getMcpToolRepositoryAccessWithDetails, getMessageById, getMessagesByConversation, getMessagesByTask, getOrganizationMemberByEmail, getOrganizationMemberByUserId, getPendingInvitationsByEmail, getProject, getProjectAccessMode, getProjectMainBranchName, getProjectMetadata, getProjectRepositoryAccess, getProjectRepositoryAccessWithDetails, getProjectResourceCounts, getProjectWithBranchInfo, getProjectWithMetadata, getRelatedAgentsForAgent, getRepositoriesByInstallationId, getRepositoriesByTenantId, getRepositoryByFullName, getRepositoryById, getRepositoryCount, getRepositoryCountsByTenantId, getSSOProvidersByDomain, getScheduledTriggerById, getScheduledTriggerInvocationById, getScheduledTriggerInvocationByIdempotencyKey, getScheduledTriggerInvocationStatusSummary, getScheduledTriggerRunInfoBatch, getScheduledTriggerUserCount, getScheduledTriggerUsers, getScheduledTriggerUsersBatch, getSchedulerState, getSkillById, getSkillByIdWithFiles, getSkillFileById, getSkillFilesBySkillIds, getSkillsForSubAgents, getSlackMcpToolAccessConfig, getStreamChunks, getSubAgentById, getSubAgentExternalAgentRelationById, getSubAgentExternalAgentRelationByParams, getSubAgentExternalAgentRelations, getSubAgentExternalAgentRelationsByAgent, getSubAgentExternalAgentRelationsByExternalAgent, getSubAgentRelationsByTarget, getSubAgentTeamAgentRelationById, getSubAgentTeamAgentRelationByParams, getSubAgentTeamAgentRelations, getSubAgentTeamAgentRelationsByAgent, getSubAgentTeamAgentRelationsByTeamAgent, getSubAgentsByIds, getSubAgentsForExternalAgent, getSubAgentsForTeamAgent, getSubAgentsUsingFunctionTool, getTask, getTeamAgentsForSubAgent, getToolById, getToolsForAgent, getTriggerById, getTriggerIdsWithUser, getTriggerInvocationById, getUserByEmail, getUserById, getUserOrganizationsFromDb, getUserProfile, getUserProvidersFromDb, getUserScopedCredentialReference, getVisibleMessages, getWorkflowExecution, getWorkflowExecutionByConversation, hasApiKey, hasContextConfig, hasCredentialReference, insertStreamChunks, invalidateHeadersCache, invalidateInvocationDefinitionsCache, isArtifactComponentAssociatedWithAgent, isDataComponentAssociatedWithAgent, isFunctionToolAssociatedWithSubAgent, isGithubWorkAppTool, isSlackWorkAppTool, linkDatasetRunToEvaluationJobConfig, listAgentIdsByProject, listAgentRelations, listAgentToolRelations, listAgents, listAgentsAcrossProjectMainBranches, listAgentsPaginated, listApiKeys, listApiKeysByProject, listApiKeysPaginated, listAppsPaginated, listArtifactComponents, listArtifactComponentsPaginated, listContextCacheByProject, listContextConfigIdsByProject, listContextConfigs, listContextConfigsPaginated, listConversations, listCredentialReferences, listCredentialReferencesPaginated, listDataComponents, listDataComponentsPaginated, listDatasetItems, listDatasetRunConfigs, listDatasetRuns, listDatasetRunsByConfig, listDatasets, listDatasetsForAgent, listEvaluationJobConfigs, listEvaluationResults, listEvaluationResultsByConversation, listEvaluationResultsByRun, listEvaluationRunConfigs, listEvaluationRunConfigsWithSuiteConfigs, listEvaluationRuns, listEvaluationRunsByJobConfigId, listEvaluationSuiteConfigs, listEvaluators, listEvaluatorsForAgent, listExternalAgents, listExternalAgentsPaginated, listFeedback, listFeedbackByConversation, listFunctionTools, listFunctions, listFunctionsPaginated, listGitHubToolAccessByProject, listGitHubToolAccessModeByProject, listMessages, listOrgEntitlements, listPendingScheduledTriggerInvocations, listProjectScheduledTriggerInvocationsPaginated, listProjects, listProjectsMetadata, listProjectsMetadataPaginated, listProjectsPaginated, listProjectsWithMetadataPaginated, listScheduledTriggerInvocationsByTriggerId, listScheduledTriggerInvocationsPaginated, listScheduledTriggers, listScheduledTriggersPaginated, listSkills, listSkillsWithFiles, listSlackChannelAgentConfigsByProject, listSlackToolAccessConfigByProject, listSubAgentExternalAgentRelations, listSubAgentTeamAgentRelations, listSubAgents, listSubAgentsPaginated, listTaskIdsByContextId, listToolIdsByProject, listTools, listTriggerInvocationsPaginated, listTriggers, listTriggersPaginated, listUpcomingInvocationsForAgentPaginated, listWorkAppSlackChannelAgentConfigsByTeam, listWorkAppSlackUserMappingsByTeam, listWorkAppSlackWorkspacesByTenant, markScheduledTriggerInvocationCancelled, markScheduledTriggerInvocationCompleted, markScheduledTriggerInvocationFailed, markScheduledTriggerInvocationRunning, markStreamComplete, projectExists, projectExistsInTable, projectHasResources, projectsMetadataExists, removeArtifactComponentFromAgent, removeDataComponentFromAgent, removeFunctionToolFromSubAgent, removeRepositories, removeToolFromAgent, removeUserFromProjectScheduledTriggers, resetCancelledInvocationToPending, resolveSlackUserContext, setActiveAgentForConversation, setActiveAgentForThread, setCacheEntry, setMcpToolAccessMode, setMcpToolRepositoryAccess, setProjectAccessMode, setProjectRepositoryAccess, setScheduledTriggerUsers, setSlackMcpToolAccessConfig, syncRepositories, updateAgent, updateAgentRelation, updateAgentToolRelation, updateApiKey, updateApiKeyLastUsed, updateApp, updateAppAuthKeysForProject, updateAppForProject, updateAppForTenant, updateAppLastUsed, updateArtifactComponent, updateContextConfig, updateConversation, updateConversationActiveSubAgent, updateCredentialReference, updateDataComponent, updateDataset, updateDatasetItem, updateDatasetRunConfig, updateEvaluationResult, updateEvaluationRun, updateEvaluationRunConfig, updateEvaluationSuiteConfig, updateEvaluator, updateExternalAgent, updateFeedback, updateFullAgentServerSide, updateFullProjectServerSide, updateFunctionTool, updateInstallationStatus, updateInstallationStatusByGitHubId, updateLedgerArtifactParts, updateMessage, updateProject, updateScheduledTrigger, updateScheduledTriggerInvocationStatus, updateSkill, updateSkillFileById, updateSlackMcpToolAccessChannelIds, updateSubAgent, updateSubAgentExternalAgentRelation, updateSubAgentFunctionToolRelation, updateSubAgentTeamAgentRelation, updateTask, updateTool, updateTrigger, updateTriggerInvocationStatus, updateWorkAppSlackWorkspace, updateWorkflowExecutionStatus, upsertAgent, upsertAgentArtifactComponentRelation, upsertAgentDataComponentRelation, upsertArtifactComponent, upsertContextConfig, upsertCredentialReference, upsertDataComponent, upsertExternalAgent, upsertFunction, upsertFunctionTool, upsertLedgerArtifact, upsertOrganization, upsertScheduledTrigger, upsertSchedulerState, upsertSkill, upsertSubAgent, upsertSubAgentExternalAgentRelation, upsertSubAgentFunctionToolRelation, upsertSubAgentRelation, upsertSubAgentSkill, upsertSubAgentTeamAgentRelation, upsertSubAgentToolRelation, upsertTool, upsertTrigger, upsertUserProfile, upsertWorkAppSlackChannelAgentConfig, validateAndGetApiKey, validateProjectExists, validateRepositoryOwnership, validateSubAgent, withProjectValidation };
|
|
52
|
+
export { AgentsManageDatabaseClient, AgentsManageDatabaseConfig, AgentsRunDatabaseClient, AgentsRunDatabaseConfig, AvailableAgentInfo, CascadeDeleteResult, CreateProjectWithBranchParams, CreateProjectWithBranchResult, CredentialReferenceWithResources, DeleteProjectAndBranchesParams, ListProjectsWithMetadataResult, MethodOption, OrgAuthInfo, ProjectConfigMetadata, ProjectGitHubAccessCascadeDeleteResult, ProjectMetadataPaginatedResult, ProjectWithMetadata, SSOProviderLookupResult, ScheduledTriggerRunInfo, SlackMcpToolAccessConfig, SubAgentIsDefaultError, ToolCascadeDeleteResult, UpsertUserProfileData, UserProfile, UserProviderInfo, WorkAppGitHubAccessMode, WorkAppSlackChannelAgentConfigInsert, WorkAppSlackChannelAgentConfigSelect, WorkAppSlackUserMappingInsert, WorkAppSlackUserMappingSelect, WorkAppSlackWorkspaceInsert, WorkAppSlackWorkspaceSelect, addConversationIdToInvocation, addFunctionToolToSubAgent, addLedgerArtifacts, addRepositories, addToolToAgent, addUserToOrganization, advanceScheduledTriggerNextRunAt, agentHasArtifactComponents, allowedMethodsToMethodOptions, associateArtifactComponentWithAgent, associateDataComponentWithAgent, associateFunctionToolWithSubAgent, cancelPastPendingInvocationsForTrigger, cancelPendingInvocationsForTrigger, cascadeDeleteByAgent, cascadeDeleteByBranch, cascadeDeleteByContextConfig, cascadeDeleteByProject, cascadeDeleteBySubAgent, cascadeDeleteByTool, cascadeDeleteGitHubAccessByProject, checkProjectRepositoryAccess, cleanupExpiredStreamChunks, cleanupTenantCache, clearAppDefaultsByAgent, clearAppDefaultsByProject, clearContextConfigCache, clearConversationCache, clearDevConfigWorkspaceDefaultsByAgent, clearDevConfigWorkspaceDefaultsByProject, clearMcpToolRepositoryAccess, clearProjectRepositoryAccess, clearSchedulerState, clearWorkspaceDefaultsByAgent, clearWorkspaceDefaultsByProject, countApiKeys, countArtifactComponents, countArtifactComponentsForAgent, countContextConfigs, countCredentialReferences, countDataComponents, countExternalAgents, countLedgerArtifactsByTask, countMessagesByConversation, countProjects, countProjectsInRuntime, countVisibleMessages, createAgent, createAgentDatasetRelation, createAgentEvaluatorRelation, createAgentManageDatabaseConnection, createAgentToolRelation, createAgentsManageDatabaseClient, createAgentsManageDatabasePool, createAgentsRunDatabaseClient, createApiKey, createApp, createArtifactComponent, createContextConfig, createConversation, createCredentialReference, createDataComponent, createDataset, createDatasetItem, createDatasetItems, createDatasetRun, createDatasetRunConfig, createDatasetRunConfigAgentRelation, createDatasetRunConversationRelation, createDatasetRunConversationRelations, createEvaluationJobConfig, createEvaluationJobConfigEvaluatorRelation, createEvaluationResult, createEvaluationResults, createEvaluationRun, createEvaluationRunConfig, createEvaluationRunConfigEvaluationSuiteConfigRelation, createEvaluationSuiteConfig, createEvaluationSuiteConfigEvaluatorRelation, createEvaluator, createExternalAgent, createFeedback, createFullAgentServerSide, createFullProjectServerSide, createFunctionTool, createInstallation, createInvitationInDb, createMessage, createOrGetConversation, createProject, createProjectMetadata, createProjectMetadataAndBranch, createScheduledTrigger, createScheduledTriggerInvocation, createScheduledTriggerUser, createSkill, createSkillFileById, createSubAgent, createSubAgentExternalAgentRelation, createSubAgentRelation, createSubAgentTeamAgentRelation, createTask, createTool, createTrigger, createTriggerInvocation, createUserProfileIfNotExists, createValidatedDataAccess, createWorkAppSlackChannelAgentConfig, createWorkAppSlackUserMapping, createWorkAppSlackWorkspace, createWorkflowExecution, dalCountMembersByRoleBucket, dalGetServiceAccountUserId, dalResolveEntitlement, dalSumSeatEntitlements, dbResultToMcpTool, dbResultToMcpToolSkeleton, deleteAgent, deleteAgentArtifactComponentRelationByAgent, deleteAgentDataComponentRelationByAgent, deleteAgentDatasetRelation, deleteAgentEvaluatorRelation, deleteAgentRelationsByAgent, deleteAgentToolRelation, deleteAgentToolRelationByAgent, deleteAllSlackMcpToolAccessConfigsByTenant, deleteAllWorkAppSlackChannelAgentConfigsByTeam, deleteAllWorkAppSlackUserMappingsByTeam, deleteApiKey, deleteApp, deleteAppForProject, deleteAppForTenant, deleteAppsByProject, deleteArtifactComponent, deleteContextConfig, deleteConversation, deleteCredentialReference, deleteDataComponent, deleteDataset, deleteDatasetItem, deleteDatasetItemsByDataset, deleteDatasetRun, deleteDatasetRunConfig, deleteDatasetRunConfigAgentRelation, deleteDatasetRunConversationRelation, deleteDatasetRunConversationRelationsByRun, deleteEvaluationJobConfig, deleteEvaluationJobConfigEvaluatorRelation, deleteEvaluationJobConfigEvaluatorRelationsByEvaluator, deleteEvaluationResult, deleteEvaluationResultsByRun, deleteEvaluationRun, deleteEvaluationRunConfig, deleteEvaluationRunConfigEvaluationSuiteConfigRelation, deleteEvaluationSuiteConfig, deleteEvaluationSuiteConfigEvaluatorRelation, deleteEvaluationSuiteConfigEvaluatorRelationsByEvaluator, deleteEvaluator, deleteExternalAgent, deleteFeedback, deleteFullAgent, deleteFullProject, deleteFunction, deleteFunctionTool, deleteInstallation, deleteLedgerArtifactsByContext, deleteLedgerArtifactsByTask, deleteMcpToolAccessMode, deleteMessage, deletePendingInvocationsForTrigger, deleteProject, deleteProjectAccessMode, deleteProjectAndBranches, deleteProjectMetadata, deleteScheduledTrigger, deleteScheduledTriggerUser, deleteScheduledTriggersByRunAsUserId, deleteSkill, deleteSkillFileById, deleteSlackMcpToolAccessConfig, deleteStreamChunks, deleteSubAgent, deleteSubAgentExternalAgentRelation, deleteSubAgentExternalAgentRelationsByAgent, deleteSubAgentExternalAgentRelationsBySubAgent, deleteSubAgentRelation, deleteSubAgentSkill, deleteSubAgentTeamAgentRelation, deleteSubAgentTeamAgentRelationsByAgent, deleteSubAgentTeamAgentRelationsBySubAgent, deleteTool, deleteTrigger, deleteTriggersByRunAsUserId, deleteWorkAppSlackChannelAgentConfig, deleteWorkAppSlackChannelAgentConfigsByAgent, deleteWorkAppSlackChannelAgentConfigsByProject, deleteWorkAppSlackUserMapping, deleteWorkAppSlackWorkspace, deleteWorkAppSlackWorkspaceByNangoConnectionId, disconnectInstallation, externalAgentExists, externalAgentUrlExists, fetchComponentRelationships, filterConversationsForJob, findDueScheduledTriggersAcrossProjects, findWorkAppSlackChannelAgentConfig, findWorkAppSlackUserMapping, findWorkAppSlackUserMappingByInkeepUserId, findWorkAppSlackUserMappingBySlackUser, findWorkAppSlackWorkspaceByNangoConnectionId, findWorkAppSlackWorkspaceBySlackTeamId, findWorkAppSlackWorkspaceByTeamId, generateAndCreateApiKey, getActiveAgentForConversation, getAgentById, getAgentDatasetRelationsByAgent, getAgentDatasetRelationsByDataset, getAgentEvaluatorRelationsByAgent, getAgentEvaluatorRelationsByEvaluator, getAgentIdsForEvaluators, getAgentRelationById, getAgentRelationByParams, getAgentRelations, getAgentRelationsByAgent, getAgentRelationsBySource, getAgentSubAgentInfos, getAgentToolRelationByAgent, getAgentToolRelationById, getAgentToolRelationByTool, getAgentWithDefaultSubAgent, getAgentsForTool, getAgentsUsingArtifactComponent, getAgentsUsingDataComponent, getAllowedAuthMethods, getApiKeyById, getApiKeyByPublicId, getAppAuthKeysForProject, getAppById, getAppByIdForProject, getAppByIdForTenant, getArtifactComponentById, getArtifactComponentsForAgent, getAuthLookupForEmail, getCacheEntry, getContextConfigById, getContextConfigCacheEntries, getConversation, getConversationCacheEntries, getConversationHistory, getCredentialReference, getCredentialReferenceById, getCredentialReferenceWithResources, getDataComponent, getDataComponentsForAgent, getDatasetById, getDatasetItemById, getDatasetRunById, getDatasetRunConfigAgentRelations, getDatasetRunConfigById, getDatasetRunConversationRelationByConversation, getDatasetRunConversationRelations, getEvaluationJobConfigById, getEvaluationJobConfigEvaluatorRelations, getEvaluationResultById, getEvaluationRunById, getEvaluationRunByJobConfigId, getEvaluationRunConfigById, getEvaluationRunConfigEvaluationSuiteConfigRelations, getEvaluationSuiteConfigById, getEvaluationSuiteConfigEvaluatorRelations, getEvaluatorById, getEvaluatorsByIds, getExternalAgent, getExternalAgentByUrl, getExternalAgentsForSubAgent, getFeedbackById, getFilteredAuthMethodsForEmail, getFullAgent, getFullAgentDefinition, getFullAgentDefinitionWithRelationIds, getFullAgentWithRelationIds, getFullProject, getFullProjectWithRelationIds, getFunction, getFunctionToolById, getFunctionToolsForSubAgent, getInstallationByGitHubId, getInstallationById, getInstallationsByTenantId, getLedgerArtifacts, getLedgerArtifactsByContext, getMcpToolAccessMode, getMcpToolById, getMcpToolRepositoryAccess, getMcpToolRepositoryAccessWithDetails, getMessageById, getMessagesByConversation, getMessagesByTask, getOrganizationMemberByEmail, getOrganizationMemberByUserId, getPendingInvitationsByEmail, getProject, getProjectAccessMode, getProjectMainBranchName, getProjectMetadata, getProjectRepositoryAccess, getProjectRepositoryAccessWithDetails, getProjectResourceCounts, getProjectWithBranchInfo, getProjectWithMetadata, getRelatedAgentsForAgent, getRepositoriesByInstallationId, getRepositoriesByTenantId, getRepositoryByFullName, getRepositoryById, getRepositoryCount, getRepositoryCountsByTenantId, getSSOProvidersByDomain, getScheduledTriggerById, getScheduledTriggerInvocationById, getScheduledTriggerInvocationByIdempotencyKey, getScheduledTriggerInvocationStatusSummary, getScheduledTriggerRunInfoBatch, getScheduledTriggerUserCount, getScheduledTriggerUsers, getScheduledTriggerUsersBatch, getSchedulerState, getSkillById, getSkillByIdWithFiles, getSkillFileById, getSkillFilesBySkillIds, getSkillsForSubAgents, getSlackMcpToolAccessConfig, getStreamChunks, getSubAgentById, getSubAgentExternalAgentRelationById, getSubAgentExternalAgentRelationByParams, getSubAgentExternalAgentRelations, getSubAgentExternalAgentRelationsByAgent, getSubAgentExternalAgentRelationsByExternalAgent, getSubAgentRelationsByTarget, getSubAgentTeamAgentRelationById, getSubAgentTeamAgentRelationByParams, getSubAgentTeamAgentRelations, getSubAgentTeamAgentRelationsByAgent, getSubAgentTeamAgentRelationsByTeamAgent, getSubAgentsByIds, getSubAgentsForExternalAgent, getSubAgentsForTeamAgent, getSubAgentsUsingFunctionTool, getTask, getTeamAgentsForSubAgent, getToolById, getToolsForAgent, getTriggerById, getTriggerIdsWithUser, getTriggerInvocationById, getUserByEmail, getUserById, getUserOrganizationsFromDb, getUserProfile, getUserProvidersFromDb, getUserScopedCredentialReference, getVisibleMessages, getWorkflowExecution, getWorkflowExecutionByConversation, hasApiKey, hasContextConfig, hasCredentialReference, insertStreamChunks, invalidateHeadersCache, invalidateInvocationDefinitionsCache, isArtifactComponentAssociatedWithAgent, isDataComponentAssociatedWithAgent, isFunctionToolAssociatedWithSubAgent, isGithubWorkAppTool, isSlackWorkAppTool, linkDatasetRunToEvaluationJobConfig, listAgentIdsByProject, listAgentRelations, listAgentToolRelations, listAgents, listAgentsAcrossProjectMainBranches, listAgentsPaginated, listApiKeys, listApiKeysByProject, listApiKeysPaginated, listAppsPaginated, listArtifactComponents, listArtifactComponentsPaginated, listContextCacheByProject, listContextConfigIdsByProject, listContextConfigs, listContextConfigsPaginated, listConversations, listCredentialReferences, listCredentialReferencesPaginated, listDataComponents, listDataComponentsPaginated, listDatasetItems, listDatasetRunConfigs, listDatasetRuns, listDatasetRunsByConfig, listDatasets, listDatasetsForAgent, listEvaluationJobConfigs, listEvaluationResults, listEvaluationResultsByConversation, listEvaluationResultsByRun, listEvaluationRunConfigs, listEvaluationRunConfigsWithSuiteConfigs, listEvaluationRuns, listEvaluationRunsByJobConfigId, listEvaluationSuiteConfigs, listEvaluators, listEvaluatorsForAgent, listExternalAgents, listExternalAgentsPaginated, listFeedback, listFeedbackByConversation, listFunctionTools, listFunctions, listFunctionsPaginated, listGitHubToolAccessByProject, listGitHubToolAccessModeByProject, listMessages, listOrgEntitlements, listPendingScheduledTriggerInvocations, listProjectScheduledTriggerInvocationsPaginated, listProjects, listProjectsMetadata, listProjectsMetadataPaginated, listProjectsPaginated, listProjectsWithMetadataPaginated, listScheduledTriggerInvocationsByTriggerId, listScheduledTriggerInvocationsPaginated, listScheduledTriggers, listScheduledTriggersPaginated, listSkills, listSkillsWithFiles, listSlackChannelAgentConfigsByProject, listSlackToolAccessConfigByProject, listSubAgentExternalAgentRelations, listSubAgentTeamAgentRelations, listSubAgents, listSubAgentsPaginated, listTaskIdsByContextId, listToolIdsByProject, listTools, listTriggerInvocationsPaginated, listTriggers, listTriggersPaginated, listUpcomingInvocationsForAgentPaginated, listWorkAppSlackChannelAgentConfigsByTeam, listWorkAppSlackUserMappingsByTeam, listWorkAppSlackWorkspacesByTenant, markScheduledTriggerInvocationCancelled, markScheduledTriggerInvocationCompleted, markScheduledTriggerInvocationFailed, markScheduledTriggerInvocationRunning, markStreamComplete, projectExists, projectExistsInTable, projectHasResources, projectsMetadataExists, removeArtifactComponentFromAgent, removeDataComponentFromAgent, removeFunctionToolFromSubAgent, removeRepositories, removeToolFromAgent, removeUserFromProjectScheduledTriggers, resetCancelledInvocationToPending, resolveSlackUserContext, setActiveAgentForConversation, setActiveAgentForThread, setCacheEntry, setMcpToolAccessMode, setMcpToolRepositoryAccess, setProjectAccessMode, setProjectRepositoryAccess, setScheduledTriggerUsers, setSlackMcpToolAccessConfig, syncRepositories, updateAgent, updateAgentRelation, updateAgentToolRelation, updateApiKey, updateApiKeyLastUsed, updateApp, updateAppAuthKeysForProject, updateAppForProject, updateAppForTenant, updateAppLastUsed, updateArtifactComponent, updateContextConfig, updateConversation, updateConversationActiveSubAgent, updateCredentialReference, updateDataComponent, updateDataset, updateDatasetItem, updateDatasetRunConfig, updateEvaluationResult, updateEvaluationRun, updateEvaluationRunConfig, updateEvaluationSuiteConfig, updateEvaluator, updateExternalAgent, updateFeedback, updateFullAgentServerSide, updateFullProjectServerSide, updateFunctionTool, updateInstallationStatus, updateInstallationStatusByGitHubId, updateLedgerArtifactParts, updateMessage, updateProject, updateScheduledTrigger, updateScheduledTriggerInvocationStatus, updateSkill, updateSkillFileById, updateSlackMcpToolAccessChannelIds, updateSubAgent, updateSubAgentExternalAgentRelation, updateSubAgentFunctionToolRelation, updateSubAgentTeamAgentRelation, updateTask, updateTool, updateTrigger, updateTriggerInvocationStatus, updateWorkAppSlackWorkspace, updateWorkflowExecutionStatus, upsertAgent, upsertAgentArtifactComponentRelation, upsertAgentDataComponentRelation, upsertArtifactComponent, upsertContextConfig, upsertCredentialReference, upsertDataComponent, upsertExternalAgent, upsertFunction, upsertFunctionTool, upsertLedgerArtifact, upsertOrganization, upsertScheduledTrigger, upsertSchedulerState, upsertSkill, upsertSubAgent, upsertSubAgentExternalAgentRelation, upsertSubAgentFunctionToolRelation, upsertSubAgentRelation, upsertSubAgentSkill, upsertSubAgentTeamAgentRelation, upsertSubAgentToolRelation, upsertTool, upsertTrigger, upsertUserProfile, upsertWorkAppSlackChannelAgentConfig, validateAndGetApiKey, validateProjectExists, validateRepositoryOwnership, validateSubAgent, withProjectValidation };
|
|
@@ -4,36 +4,31 @@ import { AgentsManageDatabaseClient } from "../../db/manage/manage-client.js";
|
|
|
4
4
|
import { FullAgentDefinition, FullAgentSelectWithRelationIds } from "../../types/entities.js";
|
|
5
5
|
|
|
6
6
|
//#region src/data-access/manage/agentFull.d.ts
|
|
7
|
-
|
|
8
|
-
info(msg: string): void;
|
|
9
|
-
info(obj: Record<string, any>, msg?: string): void;
|
|
10
|
-
error(msg: string): void;
|
|
11
|
-
error(obj: Record<string, any>, msg?: string): void;
|
|
12
|
-
}
|
|
7
|
+
|
|
13
8
|
/**
|
|
14
9
|
* Server-side implementation of createFullAgent that performs actual database operations.
|
|
15
10
|
* This function creates a complete agent with all agents, tools, and relationships.
|
|
16
11
|
*/
|
|
17
|
-
declare const createFullAgentServerSide: (db: AgentsManageDatabaseClient
|
|
12
|
+
declare const createFullAgentServerSide: (db: AgentsManageDatabaseClient) => (scopes: ProjectScopeConfig, agentData: FullAgentDefinition) => Promise<FullAgentDefinition>;
|
|
18
13
|
/**
|
|
19
14
|
* Server-side implementation of updateFullAgent that performs actual database operations.
|
|
20
15
|
* This function updates a complete agent with all agents, tools, and relationships.
|
|
21
16
|
*/
|
|
22
|
-
declare const updateFullAgentServerSide: (db: AgentsManageDatabaseClient
|
|
17
|
+
declare const updateFullAgentServerSide: (db: AgentsManageDatabaseClient) => (scopes: ProjectScopeConfig, agentData: FullAgentDefinition) => Promise<FullAgentDefinition>;
|
|
23
18
|
/**
|
|
24
19
|
* Get a complete agent definition by ID
|
|
25
20
|
*/
|
|
26
|
-
declare const getFullAgent: (db: AgentsManageDatabaseClient
|
|
21
|
+
declare const getFullAgent: (db: AgentsManageDatabaseClient) => (params: {
|
|
27
22
|
scopes: AgentScopeConfig;
|
|
28
23
|
}) => Promise<FullAgentDefinition | null>;
|
|
29
|
-
declare const getFullAgentWithRelationIds: (db: AgentsManageDatabaseClient
|
|
24
|
+
declare const getFullAgentWithRelationIds: (db: AgentsManageDatabaseClient) => (params: {
|
|
30
25
|
scopes: AgentScopeConfig;
|
|
31
26
|
}) => Promise<FullAgentSelectWithRelationIds | null>;
|
|
32
27
|
/**
|
|
33
28
|
* Delete a complete agent and cascade to all related entities
|
|
34
29
|
*/
|
|
35
|
-
declare const deleteFullAgent: (db: AgentsManageDatabaseClient
|
|
30
|
+
declare const deleteFullAgent: (db: AgentsManageDatabaseClient) => (params: {
|
|
36
31
|
scopes: AgentScopeConfig;
|
|
37
32
|
}) => Promise<boolean>;
|
|
38
33
|
//#endregion
|
|
39
|
-
export {
|
|
34
|
+
export { createFullAgentServerSide, deleteFullAgent, getFullAgent, getFullAgentWithRelationIds, updateFullAgentServerSide };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { projects, subAgentFunctionToolRelations, subAgentSkills, subAgentToolRelations, subAgents } from "../../db/manage/manage-schema.js";
|
|
2
2
|
import { validateAgentStructure, validateAndTypeAgentData } from "../../validation/agentFull.js";
|
|
3
|
+
import { getLogger } from "../../utils/logger.js";
|
|
3
4
|
import { deriveRelationId, generateId } from "../../utils/conversations.js";
|
|
4
5
|
import { agentScopedWhere, subAgentScopedWhere, tenantScopedWhere } from "./scope-helpers.js";
|
|
5
6
|
import { upsertContextConfig } from "./contextConfigs.js";
|
|
@@ -18,11 +19,8 @@ import { associateDataComponentWithAgent, deleteAgentDataComponentRelationByAgen
|
|
|
18
19
|
import { and, eq, inArray, not } from "drizzle-orm";
|
|
19
20
|
|
|
20
21
|
//#region src/data-access/manage/agentFull.ts
|
|
21
|
-
const
|
|
22
|
-
|
|
23
|
-
error: () => {}
|
|
24
|
-
};
|
|
25
|
-
async function syncSubAgentSkills(db, scopes, subAgentsMap, logger) {
|
|
22
|
+
const logger = getLogger("agentFull");
|
|
23
|
+
async function syncSubAgentSkills(db, scopes, subAgentsMap) {
|
|
26
24
|
await db.delete(subAgentSkills).where(agentScopedWhere(subAgentSkills, scopes));
|
|
27
25
|
const skillPromises = [];
|
|
28
26
|
for (const [subAgentId, subAgentData] of Object.entries(subAgentsMap)) {
|
|
@@ -51,7 +49,7 @@ async function syncSubAgentSkills(db, scopes, subAgentsMap, logger) {
|
|
|
51
49
|
/**
|
|
52
50
|
* Apply execution limits inheritance from project to Agents and Sub Agents
|
|
53
51
|
*/
|
|
54
|
-
async function applyExecutionLimitsInheritance(db,
|
|
52
|
+
async function applyExecutionLimitsInheritance(db, scopes, agentData) {
|
|
55
53
|
try {
|
|
56
54
|
const project = await db.query.projects.findFirst({ where: and(tenantScopedWhere(projects, scopes), eq(projects.id, scopes.projectId)) });
|
|
57
55
|
if (!project?.stopWhen) {
|
|
@@ -106,11 +104,11 @@ async function applyExecutionLimitsInheritance(db, logger, scopes, agentData) {
|
|
|
106
104
|
* Server-side implementation of createFullAgent that performs actual database operations.
|
|
107
105
|
* This function creates a complete agent with all agents, tools, and relationships.
|
|
108
106
|
*/
|
|
109
|
-
const createFullAgentServerSide = (db
|
|
107
|
+
const createFullAgentServerSide = (db) => async (scopes, agentData) => {
|
|
110
108
|
const { tenantId, projectId } = scopes;
|
|
111
109
|
const typed = validateAndTypeAgentData(agentData);
|
|
112
110
|
validateAgentStructure(typed);
|
|
113
|
-
await applyExecutionLimitsInheritance(db,
|
|
111
|
+
await applyExecutionLimitsInheritance(db, {
|
|
114
112
|
tenantId,
|
|
115
113
|
projectId
|
|
116
114
|
}, typed);
|
|
@@ -602,7 +600,7 @@ const createFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
602
600
|
tenantId,
|
|
603
601
|
projectId,
|
|
604
602
|
agentId: finalAgentId
|
|
605
|
-
}, typed.subAgents
|
|
603
|
+
}, typed.subAgents);
|
|
606
604
|
logger.info({ subAgentRelationCount: subAgentRelationPromises.length }, "All sub-agent relations created");
|
|
607
605
|
logger.info({ subAgentExternalAgentRelationCount: subAgentExternalAgentRelationPromises.length }, "All sub-agent external agent relations created");
|
|
608
606
|
logger.info({ subAgentTeamAgentRelationCount: subAgentTeamAgentRelationPromises.length }, "All sub-agent team agent relations created");
|
|
@@ -631,7 +629,7 @@ const createFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
631
629
|
* Server-side implementation of updateFullAgent that performs actual database operations.
|
|
632
630
|
* This function updates a complete agent with all agents, tools, and relationships.
|
|
633
631
|
*/
|
|
634
|
-
const updateFullAgentServerSide = (db
|
|
632
|
+
const updateFullAgentServerSide = (db) => async (scopes, agentData) => {
|
|
635
633
|
const { tenantId, projectId } = scopes;
|
|
636
634
|
const typedAgentDefinition = validateAndTypeAgentData(agentData);
|
|
637
635
|
if (!typedAgentDefinition.id) throw new Error("Agent ID is required");
|
|
@@ -641,7 +639,7 @@ const updateFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
641
639
|
agentCount: Object.keys(typedAgentDefinition.subAgents).length
|
|
642
640
|
}, "Updating full agent in database");
|
|
643
641
|
validateAgentStructure(typedAgentDefinition);
|
|
644
|
-
await applyExecutionLimitsInheritance(db,
|
|
642
|
+
await applyExecutionLimitsInheritance(db, {
|
|
645
643
|
tenantId,
|
|
646
644
|
projectId
|
|
647
645
|
}, typedAgentDefinition);
|
|
@@ -653,7 +651,7 @@ const updateFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
653
651
|
} });
|
|
654
652
|
if (!existingAgent) {
|
|
655
653
|
logger.info({ agentId: typedAgentDefinition.id }, "Agent does not exist, creating new agent");
|
|
656
|
-
return createFullAgentServerSide(db
|
|
654
|
+
return createFullAgentServerSide(db)(scopes, agentData);
|
|
657
655
|
}
|
|
658
656
|
const existingAgentModels = existingAgent.models;
|
|
659
657
|
logger.info("CredentialReferences are project-scoped - skipping credential reference update in agent");
|
|
@@ -1422,7 +1420,7 @@ const updateFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
1422
1420
|
tenantId,
|
|
1423
1421
|
projectId,
|
|
1424
1422
|
agentId: typedAgentDefinition.id
|
|
1425
|
-
}, typedAgentDefinition.subAgents
|
|
1423
|
+
}, typedAgentDefinition.subAgents);
|
|
1426
1424
|
const updatedAgent = await getFullAgentDefinition(db)({ scopes: {
|
|
1427
1425
|
tenantId,
|
|
1428
1426
|
projectId,
|
|
@@ -1442,7 +1440,7 @@ const updateFullAgentServerSide = (db, logger = defaultLogger) => async (scopes,
|
|
|
1442
1440
|
/**
|
|
1443
1441
|
* Get a complete agent definition by ID
|
|
1444
1442
|
*/
|
|
1445
|
-
const getFullAgent = (db
|
|
1443
|
+
const getFullAgent = (db) => async (params) => {
|
|
1446
1444
|
const { scopes } = params;
|
|
1447
1445
|
const { tenantId, projectId } = scopes;
|
|
1448
1446
|
logger.info({
|
|
@@ -1477,7 +1475,7 @@ const getFullAgent = (db, logger = defaultLogger) => async (params) => {
|
|
|
1477
1475
|
throw error;
|
|
1478
1476
|
}
|
|
1479
1477
|
};
|
|
1480
|
-
const getFullAgentWithRelationIds = (db
|
|
1478
|
+
const getFullAgentWithRelationIds = (db) => async (params) => {
|
|
1481
1479
|
const { scopes } = params;
|
|
1482
1480
|
const { tenantId, projectId } = scopes;
|
|
1483
1481
|
logger.info({
|
|
@@ -1515,7 +1513,7 @@ const getFullAgentWithRelationIds = (db, logger = defaultLogger) => async (param
|
|
|
1515
1513
|
/**
|
|
1516
1514
|
* Delete a complete agent and cascade to all related entities
|
|
1517
1515
|
*/
|
|
1518
|
-
const deleteFullAgent = (db
|
|
1516
|
+
const deleteFullAgent = (db) => async (params) => {
|
|
1519
1517
|
const { tenantId, projectId, agentId } = params.scopes;
|
|
1520
1518
|
logger.info({
|
|
1521
1519
|
tenantId,
|