@inkeep/agents-core 0.48.3 → 0.48.5
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 +148 -148
- package/dist/auth/auth.d.ts +18 -18
- package/dist/auth/permissions.d.ts +9 -9
- package/dist/data-access/manage/skills.d.ts +1 -1
- package/dist/data-access/manage/subAgentRelations.d.ts +6 -6
- package/dist/data-access/runtime/conversations.d.ts +4 -4
- package/dist/data-access/runtime/messages.d.ts +9 -9
- package/dist/data-access/runtime/tasks.d.ts +2 -2
- package/dist/db/manage/manage-schema.d.ts +353 -353
- package/dist/db/runtime/runtime-schema.d.ts +262 -262
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/utils/index.d.ts +2 -1
- package/dist/utils/index.js +2 -1
- package/dist/utils/mock-provider.d.ts +41 -0
- package/dist/utils/mock-provider.js +117 -0
- package/dist/utils/model-factory.js +5 -2
- package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
- package/dist/validation/schemas.d.ts +1565 -1565
- package/package.json +2 -1
package/dist/auth/auth.d.ts
CHANGED
|
@@ -880,25 +880,25 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
880
880
|
ac: better_auth_plugins0.AccessControl;
|
|
881
881
|
roles: {
|
|
882
882
|
member: {
|
|
883
|
-
authorize<K_1 extends "
|
|
884
|
-
actions: better_auth_plugins0.Subset<"
|
|
883
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
884
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
885
885
|
connector: "OR" | "AND";
|
|
886
886
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
887
|
-
statements: better_auth_plugins0.Subset<"
|
|
887
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
888
888
|
};
|
|
889
889
|
admin: {
|
|
890
|
-
authorize<K_1 extends "
|
|
891
|
-
actions: better_auth_plugins0.Subset<"
|
|
890
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
891
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
892
892
|
connector: "OR" | "AND";
|
|
893
893
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
894
|
-
statements: better_auth_plugins0.Subset<"
|
|
894
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
895
895
|
};
|
|
896
896
|
owner: {
|
|
897
|
-
authorize<K_1 extends "
|
|
898
|
-
actions: better_auth_plugins0.Subset<"
|
|
897
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
898
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
899
899
|
connector: "OR" | "AND";
|
|
900
900
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
901
|
-
statements: better_auth_plugins0.Subset<"
|
|
901
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
902
902
|
};
|
|
903
903
|
};
|
|
904
904
|
creatorRole: "admin";
|
|
@@ -1203,25 +1203,25 @@ declare function createAuth(config: BetterAuthConfig): better_auth0.Auth<{
|
|
|
1203
1203
|
ac: better_auth_plugins0.AccessControl;
|
|
1204
1204
|
roles: {
|
|
1205
1205
|
member: {
|
|
1206
|
-
authorize<K_1 extends "
|
|
1207
|
-
actions: better_auth_plugins0.Subset<"
|
|
1206
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
1207
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
1208
1208
|
connector: "OR" | "AND";
|
|
1209
1209
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
1210
|
-
statements: better_auth_plugins0.Subset<"
|
|
1210
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
1211
1211
|
};
|
|
1212
1212
|
admin: {
|
|
1213
|
-
authorize<K_1 extends "
|
|
1214
|
-
actions: better_auth_plugins0.Subset<"
|
|
1213
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
1214
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
1215
1215
|
connector: "OR" | "AND";
|
|
1216
1216
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
1217
|
-
statements: better_auth_plugins0.Subset<"
|
|
1217
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
1218
1218
|
};
|
|
1219
1219
|
owner: {
|
|
1220
|
-
authorize<K_1 extends "
|
|
1221
|
-
actions: better_auth_plugins0.Subset<"
|
|
1220
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key] | {
|
|
1221
|
+
actions: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>[key];
|
|
1222
1222
|
connector: "OR" | "AND";
|
|
1223
1223
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins0.AuthorizeResponse;
|
|
1224
|
-
statements: better_auth_plugins0.Subset<"
|
|
1224
|
+
statements: better_auth_plugins0.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins0.Statements>;
|
|
1225
1225
|
};
|
|
1226
1226
|
};
|
|
1227
1227
|
creatorRole: "admin";
|
|
@@ -5,25 +5,25 @@ import { organizationClient } from "better-auth/client/plugins";
|
|
|
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: better_auth_plugins69.Subset<"
|
|
8
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key] | {
|
|
9
|
+
actions: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key];
|
|
10
10
|
connector: "OR" | "AND";
|
|
11
11
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins69.AuthorizeResponse;
|
|
12
|
-
statements: better_auth_plugins69.Subset<"
|
|
12
|
+
statements: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>;
|
|
13
13
|
};
|
|
14
14
|
declare const adminRole: {
|
|
15
|
-
authorize<K_1 extends "
|
|
16
|
-
actions: better_auth_plugins69.Subset<"
|
|
15
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key] | {
|
|
16
|
+
actions: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key];
|
|
17
17
|
connector: "OR" | "AND";
|
|
18
18
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins69.AuthorizeResponse;
|
|
19
|
-
statements: better_auth_plugins69.Subset<"
|
|
19
|
+
statements: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>;
|
|
20
20
|
};
|
|
21
21
|
declare const ownerRole: {
|
|
22
|
-
authorize<K_1 extends "
|
|
23
|
-
actions: better_auth_plugins69.Subset<"
|
|
22
|
+
authorize<K_1 extends "organization" | "member" | "invitation" | "project" | "ac" | "team">(request: K_1 extends infer T extends K ? { [key in T]?: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key] | {
|
|
23
|
+
actions: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>[key];
|
|
24
24
|
connector: "OR" | "AND";
|
|
25
25
|
} | undefined } : never, connector?: "OR" | "AND"): better_auth_plugins69.AuthorizeResponse;
|
|
26
|
-
statements: better_auth_plugins69.Subset<"
|
|
26
|
+
statements: better_auth_plugins69.Subset<"organization" | "member" | "invitation" | "project" | "ac" | "team", better_auth_plugins69.Statements>;
|
|
27
27
|
};
|
|
28
28
|
//#endregion
|
|
29
29
|
export { ac, adminRole, memberRole, organizationClient, ownerRole };
|
|
@@ -98,8 +98,8 @@ declare const upsertSubAgentSkill: (db: AgentsManageDatabaseClient) => (params:
|
|
|
98
98
|
updatedAt: string;
|
|
99
99
|
index: number;
|
|
100
100
|
alwaysLoaded: boolean;
|
|
101
|
-
skillId: string;
|
|
102
101
|
subAgentId: string;
|
|
102
|
+
skillId: string;
|
|
103
103
|
}>;
|
|
104
104
|
declare const deleteSubAgentSkill: (db: AgentsManageDatabaseClient) => (params: {
|
|
105
105
|
scopes: AgentScopeConfig;
|
|
@@ -14,9 +14,9 @@ declare const getAgentRelationById: (db: AgentsManageDatabaseClient) => (params:
|
|
|
14
14
|
agentId: string;
|
|
15
15
|
createdAt: string;
|
|
16
16
|
updatedAt: string;
|
|
17
|
+
relationType: string | null;
|
|
17
18
|
sourceSubAgentId: string;
|
|
18
19
|
targetSubAgentId: string | null;
|
|
19
|
-
relationType: string | null;
|
|
20
20
|
} | undefined>;
|
|
21
21
|
declare const listAgentRelations: (db: AgentsManageDatabaseClient) => (params: {
|
|
22
22
|
scopes: AgentScopeConfig;
|
|
@@ -49,9 +49,9 @@ declare const getAgentRelations: (db: AgentsManageDatabaseClient) => (params: {
|
|
|
49
49
|
agentId: string;
|
|
50
50
|
createdAt: string;
|
|
51
51
|
updatedAt: string;
|
|
52
|
+
relationType: string | null;
|
|
52
53
|
sourceSubAgentId: string;
|
|
53
54
|
targetSubAgentId: string | null;
|
|
54
|
-
relationType: string | null;
|
|
55
55
|
}[]>;
|
|
56
56
|
declare const getAgentRelationsByAgent: (db: AgentsManageDatabaseClient) => (params: {
|
|
57
57
|
scopes: AgentScopeConfig;
|
|
@@ -62,9 +62,9 @@ declare const getAgentRelationsByAgent: (db: AgentsManageDatabaseClient) => (par
|
|
|
62
62
|
agentId: string;
|
|
63
63
|
createdAt: string;
|
|
64
64
|
updatedAt: string;
|
|
65
|
+
relationType: string | null;
|
|
65
66
|
sourceSubAgentId: string;
|
|
66
67
|
targetSubAgentId: string | null;
|
|
67
|
-
relationType: string | null;
|
|
68
68
|
}[]>;
|
|
69
69
|
declare const getAgentRelationsBySource: (db: AgentsManageDatabaseClient) => (params: {
|
|
70
70
|
scopes: AgentScopeConfig;
|
|
@@ -131,9 +131,9 @@ declare const createSubAgentRelation: (db: AgentsManageDatabaseClient) => (param
|
|
|
131
131
|
agentId: string;
|
|
132
132
|
createdAt: string;
|
|
133
133
|
updatedAt: string;
|
|
134
|
+
relationType: string | null;
|
|
134
135
|
sourceSubAgentId: string;
|
|
135
136
|
targetSubAgentId: string | null;
|
|
136
|
-
relationType: string | null;
|
|
137
137
|
}>;
|
|
138
138
|
/**
|
|
139
139
|
* Check if sub-agent relation exists by agent, source, target, and relation type
|
|
@@ -150,9 +150,9 @@ declare const getAgentRelationByParams: (db: AgentsManageDatabaseClient) => (par
|
|
|
150
150
|
agentId: string;
|
|
151
151
|
createdAt: string;
|
|
152
152
|
updatedAt: string;
|
|
153
|
+
relationType: string | null;
|
|
153
154
|
sourceSubAgentId: string;
|
|
154
155
|
targetSubAgentId: string | null;
|
|
155
|
-
relationType: string | null;
|
|
156
156
|
} | undefined>;
|
|
157
157
|
/**
|
|
158
158
|
* Upsert agent relation (create if it doesn't exist, no-op if it does)
|
|
@@ -164,9 +164,9 @@ declare const upsertSubAgentRelation: (db: AgentsManageDatabaseClient) => (param
|
|
|
164
164
|
agentId: string;
|
|
165
165
|
createdAt: string;
|
|
166
166
|
updatedAt: string;
|
|
167
|
+
relationType: string | null;
|
|
167
168
|
sourceSubAgentId: string;
|
|
168
169
|
targetSubAgentId: string | null;
|
|
169
|
-
relationType: string | null;
|
|
170
170
|
}>;
|
|
171
171
|
declare const updateAgentRelation: (db: AgentsManageDatabaseClient) => (params: {
|
|
172
172
|
scopes: AgentScopeConfig;
|
|
@@ -23,12 +23,12 @@ declare const createConversation: (db: AgentsRunDatabaseClient) => (params: Conv
|
|
|
23
23
|
createdAt: string;
|
|
24
24
|
updatedAt: string;
|
|
25
25
|
metadata: ConversationMetadata | null;
|
|
26
|
-
userId: string | null;
|
|
27
26
|
ref: {
|
|
28
27
|
type: "commit" | "tag" | "branch";
|
|
29
28
|
name: string;
|
|
30
29
|
hash: string;
|
|
31
30
|
} | null;
|
|
31
|
+
userId: string | null;
|
|
32
32
|
activeSubAgentId: string;
|
|
33
33
|
lastContextResolution: string | null;
|
|
34
34
|
}>;
|
|
@@ -92,12 +92,12 @@ declare const getConversation: (db: AgentsRunDatabaseClient) => (params: {
|
|
|
92
92
|
createdAt: string;
|
|
93
93
|
updatedAt: string;
|
|
94
94
|
metadata: ConversationMetadata | null;
|
|
95
|
-
userId: string | null;
|
|
96
95
|
ref: {
|
|
97
96
|
type: "commit" | "tag" | "branch";
|
|
98
97
|
name: string;
|
|
99
98
|
hash: string;
|
|
100
99
|
} | null;
|
|
100
|
+
userId: string | null;
|
|
101
101
|
activeSubAgentId: string;
|
|
102
102
|
lastContextResolution: string | null;
|
|
103
103
|
} | undefined>;
|
|
@@ -128,12 +128,12 @@ declare const createOrGetConversation: (db: AgentsRunDatabaseClient) => (input:
|
|
|
128
128
|
createdAt: string;
|
|
129
129
|
updatedAt: string;
|
|
130
130
|
metadata: ConversationMetadata | null;
|
|
131
|
-
userId: string | null;
|
|
132
131
|
ref: {
|
|
133
132
|
type: "commit" | "tag" | "branch";
|
|
134
133
|
name: string;
|
|
135
134
|
hash: string;
|
|
136
135
|
} | null;
|
|
136
|
+
userId: string | null;
|
|
137
137
|
activeSubAgentId: string;
|
|
138
138
|
lastContextResolution: string | null;
|
|
139
139
|
}>;
|
|
@@ -160,12 +160,12 @@ declare const getActiveAgentForConversation: (db: AgentsRunDatabaseClient) => (p
|
|
|
160
160
|
createdAt: string;
|
|
161
161
|
updatedAt: string;
|
|
162
162
|
metadata: ConversationMetadata | null;
|
|
163
|
-
userId: string | null;
|
|
164
163
|
ref: {
|
|
165
164
|
type: "commit" | "tag" | "branch";
|
|
166
165
|
name: string;
|
|
167
166
|
hash: string;
|
|
168
167
|
} | null;
|
|
168
|
+
userId: string | null;
|
|
169
169
|
activeSubAgentId: string;
|
|
170
170
|
lastContextResolution: string | null;
|
|
171
171
|
} | undefined>;
|
|
@@ -17,18 +17,18 @@ declare const getMessageById: (db: AgentsRunDatabaseClient) => (params: {
|
|
|
17
17
|
metadata: MessageMetadata | null;
|
|
18
18
|
content: MessageContent;
|
|
19
19
|
role: string;
|
|
20
|
-
conversationId: string;
|
|
21
20
|
fromSubAgentId: string | null;
|
|
22
21
|
toSubAgentId: string | null;
|
|
23
22
|
fromExternalAgentId: string | null;
|
|
24
23
|
toExternalAgentId: string | null;
|
|
24
|
+
taskId: string | null;
|
|
25
|
+
a2aTaskId: string | null;
|
|
26
|
+
conversationId: string;
|
|
25
27
|
fromTeamAgentId: string | null;
|
|
26
28
|
toTeamAgentId: string | null;
|
|
27
29
|
visibility: string;
|
|
28
30
|
messageType: string;
|
|
29
|
-
taskId: string | null;
|
|
30
31
|
parentMessageId: string | null;
|
|
31
|
-
a2aTaskId: string | null;
|
|
32
32
|
a2aSessionId: string | null;
|
|
33
33
|
} | undefined>;
|
|
34
34
|
declare const listMessages: (db: AgentsRunDatabaseClient) => (params: {
|
|
@@ -148,18 +148,18 @@ declare const createMessage: (db: AgentsRunDatabaseClient) => (params: MessageIn
|
|
|
148
148
|
metadata: MessageMetadata | null;
|
|
149
149
|
content: MessageContent;
|
|
150
150
|
role: string;
|
|
151
|
-
conversationId: string;
|
|
152
151
|
fromSubAgentId: string | null;
|
|
153
152
|
toSubAgentId: string | null;
|
|
154
153
|
fromExternalAgentId: string | null;
|
|
155
154
|
toExternalAgentId: string | null;
|
|
155
|
+
taskId: string | null;
|
|
156
|
+
a2aTaskId: string | null;
|
|
157
|
+
conversationId: string;
|
|
156
158
|
fromTeamAgentId: string | null;
|
|
157
159
|
toTeamAgentId: string | null;
|
|
158
160
|
visibility: string;
|
|
159
161
|
messageType: string;
|
|
160
|
-
taskId: string | null;
|
|
161
162
|
parentMessageId: string | null;
|
|
162
|
-
a2aTaskId: string | null;
|
|
163
163
|
a2aSessionId: string | null;
|
|
164
164
|
}>;
|
|
165
165
|
declare const updateMessage: (db: AgentsRunDatabaseClient) => (params: {
|
|
@@ -201,18 +201,18 @@ declare const deleteMessage: (db: AgentsRunDatabaseClient) => (params: {
|
|
|
201
201
|
metadata: MessageMetadata | null;
|
|
202
202
|
content: MessageContent;
|
|
203
203
|
role: string;
|
|
204
|
-
conversationId: string;
|
|
205
204
|
fromSubAgentId: string | null;
|
|
206
205
|
toSubAgentId: string | null;
|
|
207
206
|
fromExternalAgentId: string | null;
|
|
208
207
|
toExternalAgentId: string | null;
|
|
208
|
+
taskId: string | null;
|
|
209
|
+
a2aTaskId: string | null;
|
|
210
|
+
conversationId: string;
|
|
209
211
|
fromTeamAgentId: string | null;
|
|
210
212
|
toTeamAgentId: string | null;
|
|
211
213
|
visibility: string;
|
|
212
214
|
messageType: string;
|
|
213
|
-
taskId: string | null;
|
|
214
215
|
parentMessageId: string | null;
|
|
215
|
-
a2aTaskId: string | null;
|
|
216
216
|
a2aSessionId: string | null;
|
|
217
217
|
}>;
|
|
218
218
|
declare const countMessagesByConversation: (db: AgentsRunDatabaseClient) => (params: {
|
|
@@ -13,13 +13,13 @@ declare const createTask: (db: AgentsRunDatabaseClient) => (params: TaskInsert)
|
|
|
13
13
|
createdAt: string;
|
|
14
14
|
updatedAt: string;
|
|
15
15
|
metadata: TaskMetadataConfig | null;
|
|
16
|
-
status: string;
|
|
17
|
-
subAgentId: string;
|
|
18
16
|
ref: {
|
|
19
17
|
type: "commit" | "tag" | "branch";
|
|
20
18
|
name: string;
|
|
21
19
|
hash: string;
|
|
22
20
|
} | null;
|
|
21
|
+
status: string;
|
|
22
|
+
subAgentId: string;
|
|
23
23
|
contextId: string;
|
|
24
24
|
}>;
|
|
25
25
|
declare const getTask: (db: AgentsRunDatabaseClient) => (params: {
|