@inkeep/agents-core 0.50.4 → 0.50.6
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 +83 -83
- package/dist/auth/auth-validation-schemas.d.ts +131 -131
- package/dist/auth/auth.d.ts +53 -53
- package/dist/auth/permissions.d.ts +13 -13
- package/dist/data-access/manage/agents.d.ts +5 -5
- package/dist/data-access/manage/artifactComponents.d.ts +2 -2
- package/dist/data-access/manage/contextConfigs.d.ts +8 -8
- package/dist/data-access/manage/functionTools.d.ts +4 -4
- package/dist/data-access/manage/scope-helpers.d.ts +5 -5
- package/dist/data-access/manage/skills.d.ts +6 -6
- package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +6 -6
- package/dist/data-access/manage/subAgentRelations.d.ts +6 -6
- package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +6 -6
- package/dist/data-access/manage/subAgents.d.ts +3 -3
- package/dist/data-access/manage/tools.d.ts +15 -15
- package/dist/data-access/runtime/apiKeys.d.ts +8 -8
- package/dist/data-access/runtime/conversations.d.ts +24 -24
- package/dist/data-access/runtime/messages.d.ts +15 -15
- package/dist/data-access/runtime/tasks.d.ts +6 -6
- package/dist/db/manage/manage-schema.d.ts +92 -92
- package/dist/db/runtime/runtime-schema.d.ts +28 -28
- package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
- package/dist/validation/schemas.d.ts +414 -414
- package/package.json +1 -1
package/dist/auth/auth.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import * as zod0 from "zod";
|
|
|
3
3
|
import * as _better_auth_sso0 from "@better-auth/sso";
|
|
4
4
|
import * as better_auth0 from "better-auth";
|
|
5
5
|
import { BetterAuthAdvancedOptions } from "better-auth";
|
|
6
|
-
import * as
|
|
6
|
+
import * as better_auth_plugins20 from "better-auth/plugins";
|
|
7
7
|
import { GoogleOptions } from "better-auth/social-providers";
|
|
8
8
|
|
|
9
9
|
//#region src/auth/auth.d.ts
|
|
@@ -247,7 +247,7 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
247
247
|
handler: (inputContext: better_auth0.MiddlewareInputContext<better_auth0.MiddlewareOptions>) => Promise<void>;
|
|
248
248
|
}[];
|
|
249
249
|
};
|
|
250
|
-
options:
|
|
250
|
+
options: better_auth_plugins20.BearerOptions | undefined;
|
|
251
251
|
}, {
|
|
252
252
|
id: "sso";
|
|
253
253
|
endpoints: {
|
|
@@ -875,30 +875,30 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
875
875
|
};
|
|
876
876
|
}, {
|
|
877
877
|
id: "organization";
|
|
878
|
-
endpoints:
|
|
878
|
+
endpoints: better_auth_plugins20.OrganizationEndpoints<{
|
|
879
879
|
allowUserToCreateOrganization: true;
|
|
880
|
-
ac:
|
|
880
|
+
ac: better_auth_plugins20.AccessControl;
|
|
881
881
|
roles: {
|
|
882
882
|
member: {
|
|
883
|
-
authorize<K_1 extends "
|
|
884
|
-
actions:
|
|
883
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
884
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
885
885
|
connector: "OR" | "AND";
|
|
886
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
887
|
-
statements:
|
|
886
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
887
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
888
888
|
};
|
|
889
889
|
admin: {
|
|
890
|
-
authorize<K_1 extends "
|
|
891
|
-
actions:
|
|
890
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
891
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
892
892
|
connector: "OR" | "AND";
|
|
893
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
894
|
-
statements:
|
|
893
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
894
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
895
895
|
};
|
|
896
896
|
owner: {
|
|
897
|
-
authorize<K_1 extends "
|
|
898
|
-
actions:
|
|
897
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
898
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
899
899
|
connector: "OR" | "AND";
|
|
900
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
901
|
-
statements:
|
|
900
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
901
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
902
902
|
};
|
|
903
903
|
};
|
|
904
904
|
creatorRole: "admin";
|
|
@@ -909,9 +909,9 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
909
909
|
id: string;
|
|
910
910
|
role: string;
|
|
911
911
|
email: string;
|
|
912
|
-
organization:
|
|
913
|
-
invitation:
|
|
914
|
-
inviter:
|
|
912
|
+
organization: better_auth_plugins20.Organization;
|
|
913
|
+
invitation: better_auth_plugins20.Invitation;
|
|
914
|
+
inviter: better_auth_plugins20.Member & {
|
|
915
915
|
user: better_auth0.User;
|
|
916
916
|
};
|
|
917
917
|
}): Promise<void>;
|
|
@@ -932,28 +932,28 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
932
932
|
user,
|
|
933
933
|
organization: org
|
|
934
934
|
}: {
|
|
935
|
-
invitation:
|
|
936
|
-
member:
|
|
935
|
+
invitation: better_auth_plugins20.Invitation & Record<string, any>;
|
|
936
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
937
937
|
user: better_auth0.User & Record<string, any>;
|
|
938
|
-
organization:
|
|
938
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
939
939
|
}) => Promise<void>;
|
|
940
940
|
beforeUpdateMemberRole: ({
|
|
941
941
|
member,
|
|
942
942
|
organization: org,
|
|
943
943
|
newRole
|
|
944
944
|
}: {
|
|
945
|
-
member:
|
|
945
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
946
946
|
newRole: string;
|
|
947
947
|
user: better_auth0.User & Record<string, any>;
|
|
948
|
-
organization:
|
|
948
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
949
949
|
}) => Promise<void>;
|
|
950
950
|
beforeRemoveMember: ({
|
|
951
951
|
member,
|
|
952
952
|
organization: org
|
|
953
953
|
}: {
|
|
954
|
-
member:
|
|
954
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
955
955
|
user: better_auth0.User & Record<string, any>;
|
|
956
|
-
organization:
|
|
956
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
957
957
|
}) => Promise<void>;
|
|
958
958
|
};
|
|
959
959
|
}>;
|
|
@@ -1085,7 +1085,7 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1085
1085
|
organizationId: string;
|
|
1086
1086
|
email: string;
|
|
1087
1087
|
role: "member" | "admin" | "owner";
|
|
1088
|
-
status:
|
|
1088
|
+
status: better_auth_plugins20.InvitationStatus;
|
|
1089
1089
|
inviterId: string;
|
|
1090
1090
|
expiresAt: Date;
|
|
1091
1091
|
createdAt: Date;
|
|
@@ -1125,7 +1125,7 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1125
1125
|
organizationId: string;
|
|
1126
1126
|
email: string;
|
|
1127
1127
|
role: "member" | "admin" | "owner";
|
|
1128
|
-
status:
|
|
1128
|
+
status: better_auth_plugins20.InvitationStatus;
|
|
1129
1129
|
inviterId: string;
|
|
1130
1130
|
expiresAt: Date;
|
|
1131
1131
|
createdAt: Date;
|
|
@@ -1200,28 +1200,28 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1200
1200
|
};
|
|
1201
1201
|
options: NoInfer<{
|
|
1202
1202
|
allowUserToCreateOrganization: true;
|
|
1203
|
-
ac:
|
|
1203
|
+
ac: better_auth_plugins20.AccessControl;
|
|
1204
1204
|
roles: {
|
|
1205
1205
|
member: {
|
|
1206
|
-
authorize<K_1 extends "
|
|
1207
|
-
actions:
|
|
1206
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
1207
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
1208
1208
|
connector: "OR" | "AND";
|
|
1209
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
1210
|
-
statements:
|
|
1209
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
1210
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
1211
1211
|
};
|
|
1212
1212
|
admin: {
|
|
1213
|
-
authorize<K_1 extends "
|
|
1214
|
-
actions:
|
|
1213
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
1214
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
1215
1215
|
connector: "OR" | "AND";
|
|
1216
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
1217
|
-
statements:
|
|
1216
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
1217
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
1218
1218
|
};
|
|
1219
1219
|
owner: {
|
|
1220
|
-
authorize<K_1 extends "
|
|
1221
|
-
actions:
|
|
1220
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key] | {
|
|
1221
|
+
actions: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>[key];
|
|
1222
1222
|
connector: "OR" | "AND";
|
|
1223
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
1224
|
-
statements:
|
|
1223
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins20.AuthorizeResponse;
|
|
1224
|
+
statements: better_auth_plugins20.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins20.Statements>;
|
|
1225
1225
|
};
|
|
1226
1226
|
};
|
|
1227
1227
|
creatorRole: "admin";
|
|
@@ -1232,9 +1232,9 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1232
1232
|
id: string;
|
|
1233
1233
|
role: string;
|
|
1234
1234
|
email: string;
|
|
1235
|
-
organization:
|
|
1236
|
-
invitation:
|
|
1237
|
-
inviter:
|
|
1235
|
+
organization: better_auth_plugins20.Organization;
|
|
1236
|
+
invitation: better_auth_plugins20.Invitation;
|
|
1237
|
+
inviter: better_auth_plugins20.Member & {
|
|
1238
1238
|
user: better_auth0.User;
|
|
1239
1239
|
};
|
|
1240
1240
|
}): Promise<void>;
|
|
@@ -1255,28 +1255,28 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1255
1255
|
user,
|
|
1256
1256
|
organization: org
|
|
1257
1257
|
}: {
|
|
1258
|
-
invitation:
|
|
1259
|
-
member:
|
|
1258
|
+
invitation: better_auth_plugins20.Invitation & Record<string, any>;
|
|
1259
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
1260
1260
|
user: better_auth0.User & Record<string, any>;
|
|
1261
|
-
organization:
|
|
1261
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
1262
1262
|
}) => Promise<void>;
|
|
1263
1263
|
beforeUpdateMemberRole: ({
|
|
1264
1264
|
member,
|
|
1265
1265
|
organization: org,
|
|
1266
1266
|
newRole
|
|
1267
1267
|
}: {
|
|
1268
|
-
member:
|
|
1268
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
1269
1269
|
newRole: string;
|
|
1270
1270
|
user: better_auth0.User & Record<string, any>;
|
|
1271
|
-
organization:
|
|
1271
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
1272
1272
|
}) => Promise<void>;
|
|
1273
1273
|
beforeRemoveMember: ({
|
|
1274
1274
|
member,
|
|
1275
1275
|
organization: org
|
|
1276
1276
|
}: {
|
|
1277
|
-
member:
|
|
1277
|
+
member: better_auth_plugins20.Member & Record<string, any>;
|
|
1278
1278
|
user: better_auth0.User & Record<string, any>;
|
|
1279
|
-
organization:
|
|
1279
|
+
organization: better_auth_plugins20.Organization & Record<string, any>;
|
|
1280
1280
|
}) => Promise<void>;
|
|
1281
1281
|
};
|
|
1282
1282
|
}>;
|
|
@@ -1613,8 +1613,8 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1613
1613
|
readonly AUTHENTICATION_REQUIRED: "Authentication required";
|
|
1614
1614
|
};
|
|
1615
1615
|
options: Partial<{
|
|
1616
|
-
expiresIn:
|
|
1617
|
-
interval:
|
|
1616
|
+
expiresIn: better_auth_plugins20.TimeString;
|
|
1617
|
+
interval: better_auth_plugins20.TimeString;
|
|
1618
1618
|
deviceCodeLength: number;
|
|
1619
1619
|
userCodeLength: number;
|
|
1620
1620
|
schema: {
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as better_auth_plugins0 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 "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key] | {
|
|
9
|
+
actions: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key];
|
|
10
10
|
connector: "OR" | "AND";
|
|
11
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
12
|
-
statements:
|
|
11
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
12
|
+
statements: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>;
|
|
13
13
|
};
|
|
14
14
|
declare const adminRole: {
|
|
15
|
-
authorize<K_1 extends "
|
|
16
|
-
actions:
|
|
15
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key] | {
|
|
16
|
+
actions: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key];
|
|
17
17
|
connector: "OR" | "AND";
|
|
18
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
19
|
-
statements:
|
|
18
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
19
|
+
statements: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>;
|
|
20
20
|
};
|
|
21
21
|
declare const ownerRole: {
|
|
22
|
-
authorize<K_1 extends "
|
|
23
|
-
actions:
|
|
22
|
+
authorize<K_1 extends "project" | "organization" | "team" | "member" | "ac" | "invitation">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key] | {
|
|
23
|
+
actions: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>[key];
|
|
24
24
|
connector: "OR" | "AND";
|
|
25
|
-
} | undefined } : never, connector?: "OR" | "AND"):
|
|
26
|
-
statements:
|
|
25
|
+
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
26
|
+
statements: better_auth_plugins0.Subset<"project" | "organization" | "team" | "member" | "ac" | "invitation", better_auth_plugins0.Statements>;
|
|
27
27
|
};
|
|
28
28
|
//#endregion
|
|
29
29
|
export { ac, adminRole, memberRole, organizationClient, ownerRole };
|
|
@@ -8,8 +8,8 @@ import { PgTable } from "drizzle-orm/pg-core";
|
|
|
8
8
|
declare const getAgentById: (db: AgentsManageDatabaseClient) => (params: {
|
|
9
9
|
scopes: AgentScopeConfig;
|
|
10
10
|
}) => Promise<{
|
|
11
|
-
id: string;
|
|
12
11
|
name: string;
|
|
12
|
+
id: string;
|
|
13
13
|
createdAt: string;
|
|
14
14
|
updatedAt: string;
|
|
15
15
|
projectId: string;
|
|
@@ -54,8 +54,8 @@ declare const getAgentById: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
54
54
|
declare const getAgentWithDefaultSubAgent: (db: AgentsManageDatabaseClient) => (params: {
|
|
55
55
|
scopes: AgentScopeConfig;
|
|
56
56
|
}) => Promise<{
|
|
57
|
-
id: string;
|
|
58
57
|
name: string;
|
|
58
|
+
id: string;
|
|
59
59
|
createdAt: string;
|
|
60
60
|
updatedAt: string;
|
|
61
61
|
projectId: string;
|
|
@@ -97,8 +97,8 @@ declare const getAgentWithDefaultSubAgent: (db: AgentsManageDatabaseClient) => (
|
|
|
97
97
|
transferCountIs?: number | undefined;
|
|
98
98
|
} | null;
|
|
99
99
|
defaultSubAgent: {
|
|
100
|
-
id: string;
|
|
101
100
|
name: string;
|
|
101
|
+
id: string;
|
|
102
102
|
createdAt: string;
|
|
103
103
|
updatedAt: string;
|
|
104
104
|
agentId: string;
|
|
@@ -129,8 +129,8 @@ declare const getAgentWithDefaultSubAgent: (db: AgentsManageDatabaseClient) => (
|
|
|
129
129
|
declare const listAgents: (db: AgentsManageDatabaseClient) => (params: {
|
|
130
130
|
scopes: ProjectScopeConfig;
|
|
131
131
|
}) => Promise<{
|
|
132
|
-
id: string;
|
|
133
132
|
name: string;
|
|
133
|
+
id: string;
|
|
134
134
|
createdAt: string;
|
|
135
135
|
updatedAt: string;
|
|
136
136
|
projectId: string;
|
|
@@ -245,8 +245,8 @@ declare function listAgentsAcrossProjectMainBranches(db: AgentsManageDatabaseCli
|
|
|
245
245
|
projectIds: string[];
|
|
246
246
|
}): Promise<AvailableAgentInfo[]>;
|
|
247
247
|
declare const createAgent: (db: AgentsManageDatabaseClient) => (data: AgentInsert) => Promise<{
|
|
248
|
-
id: string;
|
|
249
248
|
name: string;
|
|
249
|
+
id: string;
|
|
250
250
|
createdAt: string;
|
|
251
251
|
updatedAt: string;
|
|
252
252
|
projectId: string;
|
|
@@ -8,8 +8,8 @@ declare const getArtifactComponentById: (db: AgentsManageDatabaseClient) => (par
|
|
|
8
8
|
scopes: ProjectScopeConfig;
|
|
9
9
|
id: string;
|
|
10
10
|
}) => Promise<{
|
|
11
|
-
id: string;
|
|
12
11
|
name: string;
|
|
12
|
+
id: string;
|
|
13
13
|
createdAt: string;
|
|
14
14
|
updatedAt: string;
|
|
15
15
|
projectId: string;
|
|
@@ -64,8 +64,8 @@ declare const listArtifactComponentsPaginated: (db: AgentsManageDatabaseClient)
|
|
|
64
64
|
};
|
|
65
65
|
}>;
|
|
66
66
|
declare const createArtifactComponent: (db: AgentsManageDatabaseClient) => (params: ArtifactComponentInsert) => Promise<{
|
|
67
|
-
id: string;
|
|
68
67
|
name: string;
|
|
68
|
+
id: string;
|
|
69
69
|
createdAt: string;
|
|
70
70
|
updatedAt: string;
|
|
71
71
|
projectId: string;
|
|
@@ -9,10 +9,10 @@ declare const getContextConfigById: (db: AgentsManageDatabaseClient) => (params:
|
|
|
9
9
|
id: string;
|
|
10
10
|
}) => Promise<{
|
|
11
11
|
id: string;
|
|
12
|
-
createdAt: string;
|
|
13
|
-
updatedAt: string;
|
|
14
12
|
headersSchema: unknown;
|
|
15
13
|
contextVariables: Record<string, ContextFetchDefinition> | null;
|
|
14
|
+
createdAt: string;
|
|
15
|
+
updatedAt: string;
|
|
16
16
|
agentId: string;
|
|
17
17
|
projectId: string;
|
|
18
18
|
tenantId: string;
|
|
@@ -21,10 +21,10 @@ declare const listContextConfigs: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
21
21
|
scopes: AgentScopeConfig;
|
|
22
22
|
}) => Promise<{
|
|
23
23
|
id: string;
|
|
24
|
-
createdAt: string;
|
|
25
|
-
updatedAt: string;
|
|
26
24
|
headersSchema: unknown;
|
|
27
25
|
contextVariables: Record<string, ContextFetchDefinition> | null;
|
|
26
|
+
createdAt: string;
|
|
27
|
+
updatedAt: string;
|
|
28
28
|
agentId: string;
|
|
29
29
|
projectId: string;
|
|
30
30
|
tenantId: string;
|
|
@@ -43,10 +43,10 @@ declare const listContextConfigsPaginated: (db: AgentsManageDatabaseClient) => (
|
|
|
43
43
|
}>;
|
|
44
44
|
declare const createContextConfig: (db: AgentsManageDatabaseClient) => (params: ContextConfigInsert) => Promise<{
|
|
45
45
|
id: string;
|
|
46
|
-
createdAt: string;
|
|
47
|
-
updatedAt: string;
|
|
48
46
|
headersSchema: unknown;
|
|
49
47
|
contextVariables: Record<string, ContextFetchDefinition> | null;
|
|
48
|
+
createdAt: string;
|
|
49
|
+
updatedAt: string;
|
|
50
50
|
agentId: string;
|
|
51
51
|
projectId: string;
|
|
52
52
|
tenantId: string;
|
|
@@ -83,10 +83,10 @@ declare const upsertContextConfig: (db: AgentsManageDatabaseClient) => (params:
|
|
|
83
83
|
data: ContextConfigInsert;
|
|
84
84
|
}) => Promise<{
|
|
85
85
|
id: string;
|
|
86
|
-
createdAt: string;
|
|
87
|
-
updatedAt: string;
|
|
88
86
|
headersSchema: unknown;
|
|
89
87
|
contextVariables: Record<string, ContextFetchDefinition> | null;
|
|
88
|
+
createdAt: string;
|
|
89
|
+
updatedAt: string;
|
|
90
90
|
agentId: string;
|
|
91
91
|
projectId: string;
|
|
92
92
|
tenantId: string;
|
|
@@ -53,8 +53,8 @@ declare const createFunctionTool: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
53
53
|
data: FunctionToolApiInsert;
|
|
54
54
|
scopes: AgentScopeConfig;
|
|
55
55
|
}) => Promise<{
|
|
56
|
-
id: string;
|
|
57
56
|
name: string;
|
|
57
|
+
id: string;
|
|
58
58
|
createdAt: string;
|
|
59
59
|
updatedAt: string;
|
|
60
60
|
agentId: string;
|
|
@@ -95,8 +95,8 @@ declare const upsertFunctionTool: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
95
95
|
data: FunctionToolApiInsert;
|
|
96
96
|
scopes: AgentScopeConfig;
|
|
97
97
|
}) => Promise<{
|
|
98
|
-
id: string;
|
|
99
98
|
name: string;
|
|
99
|
+
id: string;
|
|
100
100
|
createdAt: string;
|
|
101
101
|
updatedAt: string;
|
|
102
102
|
agentId: string;
|
|
@@ -168,10 +168,10 @@ declare const addFunctionToolToSubAgent: (db: AgentsManageDatabaseClient) => (pa
|
|
|
168
168
|
projectId: string;
|
|
169
169
|
tenantId: string;
|
|
170
170
|
subAgentId: string;
|
|
171
|
-
functionToolId: string;
|
|
172
171
|
toolPolicies: Record<string, {
|
|
173
172
|
needsApproval?: boolean;
|
|
174
173
|
}> | null;
|
|
174
|
+
functionToolId: string;
|
|
175
175
|
}>;
|
|
176
176
|
/**
|
|
177
177
|
* Update an agent-function tool relation
|
|
@@ -233,10 +233,10 @@ declare const associateFunctionToolWithSubAgent: (db: AgentsManageDatabaseClient
|
|
|
233
233
|
projectId: string;
|
|
234
234
|
tenantId: string;
|
|
235
235
|
subAgentId: string;
|
|
236
|
-
functionToolId: string;
|
|
237
236
|
toolPolicies: Record<string, {
|
|
238
237
|
needsApproval?: boolean;
|
|
239
238
|
}> | null;
|
|
239
|
+
functionToolId: string;
|
|
240
240
|
}>;
|
|
241
241
|
//#endregion
|
|
242
242
|
export { addFunctionToolToSubAgent, associateFunctionToolWithSubAgent, createFunctionTool, deleteFunctionTool, getFunctionToolById, getFunctionToolsForSubAgent, getSubAgentsUsingFunctionTool, isFunctionToolAssociatedWithSubAgent, listFunctionTools, removeFunctionToolFromSubAgent, updateFunctionTool, updateSubAgentFunctionToolRelation, upsertFunctionTool, upsertSubAgentFunctionToolRelation };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AgentScopeConfig, ProjectScopeConfig, SubAgentScopeConfig } from "../../types/utility.js";
|
|
2
|
-
import * as
|
|
2
|
+
import * as drizzle_orm138 from "drizzle-orm";
|
|
3
3
|
|
|
4
4
|
//#region src/data-access/manage/scope-helpers.d.ts
|
|
5
5
|
type TenantScopeConfig = {
|
|
@@ -17,9 +17,9 @@ type AgentScopedColumns = ProjectScopedColumns & {
|
|
|
17
17
|
type SubAgentScopedColumns = AgentScopedColumns & {
|
|
18
18
|
subAgentId: any;
|
|
19
19
|
};
|
|
20
|
-
declare function tenantScopedWhere<T extends TenantScopedColumns>(table: T, scopes: TenantScopeConfig):
|
|
21
|
-
declare function projectScopedWhere<T extends ProjectScopedColumns>(table: T, scopes: ProjectScopeConfig):
|
|
22
|
-
declare function agentScopedWhere<T extends AgentScopedColumns>(table: T, scopes: AgentScopeConfig):
|
|
23
|
-
declare function subAgentScopedWhere<T extends SubAgentScopedColumns>(table: T, scopes: SubAgentScopeConfig):
|
|
20
|
+
declare function tenantScopedWhere<T extends TenantScopedColumns>(table: T, scopes: TenantScopeConfig): drizzle_orm138.SQL<unknown>;
|
|
21
|
+
declare function projectScopedWhere<T extends ProjectScopedColumns>(table: T, scopes: ProjectScopeConfig): drizzle_orm138.SQL<unknown> | undefined;
|
|
22
|
+
declare function agentScopedWhere<T extends AgentScopedColumns>(table: T, scopes: AgentScopeConfig): drizzle_orm138.SQL<unknown> | undefined;
|
|
23
|
+
declare function subAgentScopedWhere<T extends SubAgentScopedColumns>(table: T, scopes: SubAgentScopeConfig): drizzle_orm138.SQL<unknown> | undefined;
|
|
24
24
|
//#endregion
|
|
25
25
|
export { agentScopedWhere, projectScopedWhere, subAgentScopedWhere, tenantScopedWhere };
|
|
@@ -7,14 +7,14 @@ declare const getSkillById: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
7
7
|
scopes: ProjectScopeConfig;
|
|
8
8
|
skillId: string;
|
|
9
9
|
}) => Promise<{
|
|
10
|
-
id: string;
|
|
11
10
|
name: string;
|
|
11
|
+
id: string;
|
|
12
12
|
createdAt: string;
|
|
13
13
|
updatedAt: string;
|
|
14
|
-
metadata: Record<string, string> | null;
|
|
15
14
|
projectId: string;
|
|
16
15
|
tenantId: string;
|
|
17
16
|
description: string;
|
|
17
|
+
metadata: Record<string, string> | null;
|
|
18
18
|
content: string;
|
|
19
19
|
} | null>;
|
|
20
20
|
declare const listSkills: (db: AgentsManageDatabaseClient) => (params: {
|
|
@@ -40,25 +40,25 @@ declare const listSkills: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
40
40
|
};
|
|
41
41
|
}>;
|
|
42
42
|
declare const createSkill: (db: AgentsManageDatabaseClient) => (data: SkillInsert) => Promise<{
|
|
43
|
-
id: string;
|
|
44
43
|
name: string;
|
|
44
|
+
id: string;
|
|
45
45
|
createdAt: string;
|
|
46
46
|
updatedAt: string;
|
|
47
|
-
metadata: Record<string, string> | null;
|
|
48
47
|
projectId: string;
|
|
49
48
|
tenantId: string;
|
|
50
49
|
description: string;
|
|
50
|
+
metadata: Record<string, string> | null;
|
|
51
51
|
content: string;
|
|
52
52
|
}>;
|
|
53
53
|
declare const upsertSkill: (db: AgentsManageDatabaseClient) => (data: SkillInsert) => Promise<{
|
|
54
|
-
id: string;
|
|
55
54
|
name: string;
|
|
55
|
+
id: string;
|
|
56
56
|
createdAt: string;
|
|
57
57
|
updatedAt: string;
|
|
58
|
-
metadata: Record<string, string> | null;
|
|
59
58
|
projectId: string;
|
|
60
59
|
tenantId: string;
|
|
61
60
|
description: string;
|
|
61
|
+
metadata: Record<string, string> | null;
|
|
62
62
|
content: string;
|
|
63
63
|
}>;
|
|
64
64
|
declare const updateSkill: (db: AgentsManageDatabaseClient) => (params: {
|
|
@@ -11,10 +11,10 @@ declare const getSubAgentExternalAgentRelationById: (db: AgentsManageDatabaseCli
|
|
|
11
11
|
id: string;
|
|
12
12
|
createdAt: string;
|
|
13
13
|
updatedAt: string;
|
|
14
|
-
headers: Record<string, string> | null;
|
|
15
14
|
agentId: string;
|
|
16
15
|
projectId: string;
|
|
17
16
|
tenantId: string;
|
|
17
|
+
headers: Record<string, string> | null;
|
|
18
18
|
subAgentId: string;
|
|
19
19
|
externalAgentId: string;
|
|
20
20
|
} | undefined>;
|
|
@@ -46,10 +46,10 @@ declare const getSubAgentExternalAgentRelations: (db: AgentsManageDatabaseClient
|
|
|
46
46
|
id: string;
|
|
47
47
|
createdAt: string;
|
|
48
48
|
updatedAt: string;
|
|
49
|
-
headers: Record<string, string> | null;
|
|
50
49
|
agentId: string;
|
|
51
50
|
projectId: string;
|
|
52
51
|
tenantId: string;
|
|
52
|
+
headers: Record<string, string> | null;
|
|
53
53
|
subAgentId: string;
|
|
54
54
|
externalAgentId: string;
|
|
55
55
|
}[]>;
|
|
@@ -59,10 +59,10 @@ declare const getSubAgentExternalAgentRelationsByAgent: (db: AgentsManageDatabas
|
|
|
59
59
|
id: string;
|
|
60
60
|
createdAt: string;
|
|
61
61
|
updatedAt: string;
|
|
62
|
-
headers: Record<string, string> | null;
|
|
63
62
|
agentId: string;
|
|
64
63
|
projectId: string;
|
|
65
64
|
tenantId: string;
|
|
65
|
+
headers: Record<string, string> | null;
|
|
66
66
|
subAgentId: string;
|
|
67
67
|
externalAgentId: string;
|
|
68
68
|
}[]>;
|
|
@@ -182,10 +182,10 @@ declare const createSubAgentExternalAgentRelation: (db: AgentsManageDatabaseClie
|
|
|
182
182
|
id: string;
|
|
183
183
|
createdAt: string;
|
|
184
184
|
updatedAt: string;
|
|
185
|
-
headers: Record<string, string> | null;
|
|
186
185
|
agentId: string;
|
|
187
186
|
projectId: string;
|
|
188
187
|
tenantId: string;
|
|
188
|
+
headers: Record<string, string> | null;
|
|
189
189
|
subAgentId: string;
|
|
190
190
|
externalAgentId: string;
|
|
191
191
|
}>;
|
|
@@ -199,10 +199,10 @@ declare const getSubAgentExternalAgentRelationByParams: (db: AgentsManageDatabas
|
|
|
199
199
|
id: string;
|
|
200
200
|
createdAt: string;
|
|
201
201
|
updatedAt: string;
|
|
202
|
-
headers: Record<string, string> | null;
|
|
203
202
|
agentId: string;
|
|
204
203
|
projectId: string;
|
|
205
204
|
tenantId: string;
|
|
205
|
+
headers: Record<string, string> | null;
|
|
206
206
|
subAgentId: string;
|
|
207
207
|
externalAgentId: string;
|
|
208
208
|
} | undefined>;
|
|
@@ -220,10 +220,10 @@ declare const upsertSubAgentExternalAgentRelation: (db: AgentsManageDatabaseClie
|
|
|
220
220
|
id: string;
|
|
221
221
|
createdAt: string;
|
|
222
222
|
updatedAt: string;
|
|
223
|
-
headers: Record<string, string> | null;
|
|
224
223
|
agentId: string;
|
|
225
224
|
projectId: string;
|
|
226
225
|
tenantId: string;
|
|
226
|
+
headers: Record<string, string> | null;
|
|
227
227
|
subAgentId: string;
|
|
228
228
|
externalAgentId: string;
|
|
229
229
|
}>;
|
|
@@ -206,16 +206,16 @@ declare const createAgentToolRelation: (db: AgentsManageDatabaseClient) => (para
|
|
|
206
206
|
id: string;
|
|
207
207
|
createdAt: string;
|
|
208
208
|
updatedAt: string;
|
|
209
|
-
headers: Record<string, string> | null;
|
|
210
209
|
agentId: string;
|
|
211
210
|
projectId: string;
|
|
212
211
|
tenantId: string;
|
|
213
|
-
|
|
212
|
+
headers: Record<string, string> | null;
|
|
214
213
|
subAgentId: string;
|
|
214
|
+
toolId: string;
|
|
215
|
+
selectedTools: string[] | null;
|
|
215
216
|
toolPolicies: Record<string, {
|
|
216
217
|
needsApproval?: boolean;
|
|
217
218
|
}> | null;
|
|
218
|
-
selectedTools: string[] | null;
|
|
219
219
|
}>;
|
|
220
220
|
declare const updateAgentToolRelation: (db: AgentsManageDatabaseClient) => (params: {
|
|
221
221
|
scopes: AgentScopeConfig;
|
|
@@ -250,16 +250,16 @@ declare const getAgentToolRelationById: (db: AgentsManageDatabaseClient) => (par
|
|
|
250
250
|
id: string;
|
|
251
251
|
createdAt: string;
|
|
252
252
|
updatedAt: string;
|
|
253
|
-
headers: Record<string, string> | null;
|
|
254
253
|
agentId: string;
|
|
255
254
|
projectId: string;
|
|
256
255
|
tenantId: string;
|
|
257
|
-
|
|
256
|
+
headers: Record<string, string> | null;
|
|
258
257
|
subAgentId: string;
|
|
258
|
+
toolId: string;
|
|
259
|
+
selectedTools: string[] | null;
|
|
259
260
|
toolPolicies: Record<string, {
|
|
260
261
|
needsApproval?: boolean;
|
|
261
262
|
}> | null;
|
|
262
|
-
selectedTools: string[] | null;
|
|
263
263
|
} | undefined>;
|
|
264
264
|
declare const getAgentToolRelationByAgent: (db: AgentsManageDatabaseClient) => (params: {
|
|
265
265
|
scopes: SubAgentScopeConfig;
|