@inkeep/agents-core 0.0.0-dev-20260227220655 → 0.0.0-dev-20260227232900

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.
Files changed (50) hide show
  1. package/dist/auth/auth-schema.d.ts +107 -107
  2. package/dist/auth/auth-validation-schemas.d.ts +152 -152
  3. package/dist/auth/auth.d.ts +9 -9
  4. package/dist/auth/permissions.d.ts +9 -9
  5. package/dist/client-exports.d.ts +5 -5
  6. package/dist/client-exports.js +2 -2
  7. package/dist/data-access/index.d.ts +2 -2
  8. package/dist/data-access/index.js +3 -3
  9. package/dist/data-access/manage/agents.d.ts +29 -29
  10. package/dist/data-access/manage/agents.js +19 -1
  11. package/dist/data-access/manage/artifactComponents.d.ts +8 -8
  12. package/dist/data-access/manage/contextConfigs.d.ts +4 -4
  13. package/dist/data-access/manage/dataComponents.d.ts +4 -4
  14. package/dist/data-access/manage/functionTools.d.ts +12 -12
  15. package/dist/data-access/manage/skills.d.ts +8 -8
  16. package/dist/data-access/manage/subAgentExternalAgentRelations.d.ts +12 -12
  17. package/dist/data-access/manage/subAgentRelations.d.ts +20 -20
  18. package/dist/data-access/manage/subAgentTeamAgentRelations.d.ts +12 -12
  19. package/dist/data-access/manage/subAgents.d.ts +15 -15
  20. package/dist/data-access/manage/tools.d.ts +18 -18
  21. package/dist/data-access/manage/tools.js +1 -1
  22. package/dist/data-access/manage/triggers.d.ts +1 -1
  23. package/dist/data-access/runtime/apiKeys.d.ts +12 -12
  24. package/dist/data-access/runtime/cascade-delete.d.ts +2 -0
  25. package/dist/data-access/runtime/cascade-delete.js +19 -4
  26. package/dist/data-access/runtime/conversations.d.ts +16 -16
  27. package/dist/data-access/runtime/messages.d.ts +15 -15
  28. package/dist/data-access/runtime/scheduledTriggerInvocations.d.ts +3 -3
  29. package/dist/data-access/runtime/tasks.d.ts +5 -5
  30. package/dist/data-access/runtime/workAppSlack.d.ts +8 -2
  31. package/dist/data-access/runtime/workAppSlack.js +63 -2
  32. package/dist/db/manage/manage-schema.d.ts +449 -449
  33. package/dist/db/runtime/runtime-schema.d.ts +348 -312
  34. package/dist/db/runtime/runtime-schema.js +12 -4
  35. package/dist/index.d.ts +3 -3
  36. package/dist/index.js +4 -4
  37. package/dist/utils/error.d.ts +51 -51
  38. package/dist/validation/drizzle-schema-helpers.d.ts +3 -3
  39. package/dist/validation/index.d.ts +2 -2
  40. package/dist/validation/index.js +2 -2
  41. package/dist/validation/schemas.d.ts +2976 -1888
  42. package/dist/validation/schemas.js +12 -2
  43. package/drizzle/runtime/0016_white_eddie_brock.sql +1 -0
  44. package/drizzle/runtime/0017_remarkable_starfox.sql +3 -0
  45. package/drizzle/runtime/0018_orange_union_jack.sql +6 -0
  46. package/drizzle/runtime/meta/0016_snapshot.json +3766 -0
  47. package/drizzle/runtime/meta/0017_snapshot.json +3785 -0
  48. package/drizzle/runtime/meta/0018_snapshot.json +3929 -0
  49. package/drizzle/runtime/meta/_journal.json +21 -0
  50. package/package.json +1 -1
@@ -10,12 +10,12 @@ declare const getSubAgentTeamAgentRelationById: (db: AgentsManageDatabaseClient)
10
10
  relationId: string;
11
11
  }) => Promise<{
12
12
  tenantId: string;
13
- agentId: string;
14
13
  projectId: string;
14
+ agentId: string;
15
+ subAgentId: string;
15
16
  id: string;
16
17
  createdAt: string;
17
18
  updatedAt: string;
18
- subAgentId: string;
19
19
  headers: Record<string, string> | null;
20
20
  targetAgentId: string;
21
21
  } | undefined>;
@@ -45,12 +45,12 @@ declare const getSubAgentTeamAgentRelations: (db: AgentsManageDatabaseClient) =>
45
45
  scopes: SubAgentScopeConfig;
46
46
  }) => Promise<{
47
47
  tenantId: string;
48
- agentId: string;
49
48
  projectId: string;
49
+ agentId: string;
50
+ subAgentId: string;
50
51
  id: string;
51
52
  createdAt: string;
52
53
  updatedAt: string;
53
- subAgentId: string;
54
54
  headers: Record<string, string> | null;
55
55
  targetAgentId: string;
56
56
  }[]>;
@@ -58,12 +58,12 @@ declare const getSubAgentTeamAgentRelationsByAgent: (db: AgentsManageDatabaseCli
58
58
  scopes: AgentScopeConfig;
59
59
  }) => Promise<{
60
60
  tenantId: string;
61
- agentId: string;
62
61
  projectId: string;
62
+ agentId: string;
63
+ subAgentId: string;
63
64
  id: string;
64
65
  createdAt: string;
65
66
  updatedAt: string;
66
- subAgentId: string;
67
67
  headers: Record<string, string> | null;
68
68
  targetAgentId: string;
69
69
  }[]>;
@@ -211,12 +211,12 @@ declare const createSubAgentTeamAgentRelation: (db: AgentsManageDatabaseClient)
211
211
  };
212
212
  }) => Promise<{
213
213
  tenantId: string;
214
- agentId: string;
215
214
  projectId: string;
215
+ agentId: string;
216
+ subAgentId: string;
216
217
  id: string;
217
218
  createdAt: string;
218
219
  updatedAt: string;
219
- subAgentId: string;
220
220
  headers: Record<string, string> | null;
221
221
  targetAgentId: string;
222
222
  }>;
@@ -228,12 +228,12 @@ declare const getSubAgentTeamAgentRelationByParams: (db: AgentsManageDatabaseCli
228
228
  targetAgentId: string;
229
229
  }) => Promise<{
230
230
  tenantId: string;
231
- agentId: string;
232
231
  projectId: string;
232
+ agentId: string;
233
+ subAgentId: string;
233
234
  id: string;
234
235
  createdAt: string;
235
236
  updatedAt: string;
236
- subAgentId: string;
237
237
  headers: Record<string, string> | null;
238
238
  targetAgentId: string;
239
239
  } | undefined>;
@@ -249,12 +249,12 @@ declare const upsertSubAgentTeamAgentRelation: (db: AgentsManageDatabaseClient)
249
249
  };
250
250
  }) => Promise<{
251
251
  tenantId: string;
252
- agentId: string;
253
252
  projectId: string;
253
+ agentId: string;
254
+ subAgentId: string;
254
255
  id: string;
255
256
  createdAt: string;
256
257
  updatedAt: string;
257
- subAgentId: string;
258
258
  headers: Record<string, string> | null;
259
259
  targetAgentId: string;
260
260
  }>;
@@ -9,12 +9,14 @@ declare const getSubAgentById: (db: AgentsManageDatabaseClient) => (params: {
9
9
  scopes: AgentScopeConfig;
10
10
  subAgentId: string;
11
11
  }) => Promise<{
12
- tenantId: string;
12
+ name: string;
13
13
  description: string | null;
14
- agentId: string;
14
+ tenantId: string;
15
15
  projectId: string;
16
+ agentId: string;
16
17
  id: string;
17
- name: string;
18
+ createdAt: string;
19
+ updatedAt: string;
18
20
  models: {
19
21
  base?: {
20
22
  model?: string | undefined;
@@ -32,20 +34,20 @@ declare const getSubAgentById: (db: AgentsManageDatabaseClient) => (params: {
32
34
  stopWhen: {
33
35
  stepCountIs?: number | undefined;
34
36
  } | null;
35
- createdAt: string;
36
- updatedAt: string;
37
37
  prompt: string | null;
38
38
  conversationHistoryConfig: ConversationHistoryConfig | null;
39
39
  } | undefined>;
40
40
  declare const listSubAgents: (db: AgentsManageDatabaseClient) => (params: {
41
41
  scopes: AgentScopeConfig;
42
42
  }) => Promise<{
43
- tenantId: string;
43
+ name: string;
44
44
  description: string | null;
45
- agentId: string;
45
+ tenantId: string;
46
46
  projectId: string;
47
+ agentId: string;
47
48
  id: string;
48
- name: string;
49
+ createdAt: string;
50
+ updatedAt: string;
49
51
  models: {
50
52
  base?: {
51
53
  model?: string | undefined;
@@ -63,8 +65,6 @@ declare const listSubAgents: (db: AgentsManageDatabaseClient) => (params: {
63
65
  stopWhen: {
64
66
  stepCountIs?: number | undefined;
65
67
  } | null;
66
- createdAt: string;
67
- updatedAt: string;
68
68
  prompt: string | null;
69
69
  conversationHistoryConfig: ConversationHistoryConfig | null;
70
70
  }[]>;
@@ -109,12 +109,14 @@ declare const listSubAgentsPaginated: (db: AgentsManageDatabaseClient) => (param
109
109
  };
110
110
  }>;
111
111
  declare const createSubAgent: (db: AgentsManageDatabaseClient) => (params: SubAgentInsert) => Promise<{
112
- tenantId: string;
112
+ name: string;
113
113
  description: string | null;
114
- agentId: string;
114
+ tenantId: string;
115
115
  projectId: string;
116
+ agentId: string;
116
117
  id: string;
117
- name: string;
118
+ createdAt: string;
119
+ updatedAt: string;
118
120
  models: {
119
121
  base?: {
120
122
  model?: string | undefined;
@@ -132,8 +134,6 @@ declare const createSubAgent: (db: AgentsManageDatabaseClient) => (params: SubAg
132
134
  stopWhen: {
133
135
  stepCountIs?: number | undefined;
134
136
  } | null;
135
- createdAt: string;
136
- updatedAt: string;
137
137
  prompt: string | null;
138
138
  conversationHistoryConfig: ConversationHistoryConfig | null;
139
139
  }>;
@@ -19,11 +19,11 @@ declare const getToolById: (db: AgentsManageDatabaseClient) => (params: {
19
19
  scopes: ProjectScopeConfig;
20
20
  toolId: string;
21
21
  }) => Promise<{
22
- tenantId: string;
22
+ name: string;
23
23
  description: string | null;
24
+ tenantId: string;
24
25
  projectId: string;
25
26
  id: string;
26
- name: string;
27
27
  createdAt: string;
28
28
  updatedAt: string;
29
29
  headers: Record<string, string> | null;
@@ -77,11 +77,11 @@ declare const listTools: (db: AgentsManageDatabaseClient) => (params: {
77
77
  };
78
78
  }>;
79
79
  declare const createTool: (db: AgentsManageDatabaseClient) => (params: ToolInsert) => Promise<{
80
- tenantId: string;
80
+ name: string;
81
81
  description: string | null;
82
+ tenantId: string;
82
83
  projectId: string;
83
84
  id: string;
84
- name: string;
85
85
  createdAt: string;
86
86
  updatedAt: string;
87
87
  headers: Record<string, string> | null;
@@ -135,18 +135,18 @@ declare const addToolToAgent: (db: AgentsManageDatabaseClient) => (params: {
135
135
  }> | null;
136
136
  }) => Promise<{
137
137
  tenantId: string;
138
- agentId: string;
139
138
  projectId: string;
139
+ agentId: string;
140
+ subAgentId: string;
140
141
  id: string;
141
142
  createdAt: string;
142
143
  updatedAt: string;
143
- subAgentId: string;
144
- headers: Record<string, string> | null;
145
144
  toolId: string;
145
+ headers: Record<string, string> | null;
146
+ selectedTools: string[] | null;
146
147
  toolPolicies: Record<string, {
147
148
  needsApproval?: boolean;
148
149
  }> | null;
149
- selectedTools: string[] | null;
150
150
  }>;
151
151
  declare const removeToolFromAgent: (db: AgentsManageDatabaseClient) => (params: {
152
152
  scopes: AgentScopeConfig;
@@ -154,18 +154,18 @@ declare const removeToolFromAgent: (db: AgentsManageDatabaseClient) => (params:
154
154
  toolId: string;
155
155
  }) => Promise<{
156
156
  tenantId: string;
157
- agentId: string;
158
157
  projectId: string;
158
+ agentId: string;
159
+ subAgentId: string;
159
160
  id: string;
160
161
  createdAt: string;
161
162
  updatedAt: string;
162
- subAgentId: string;
163
- headers: Record<string, string> | null;
164
163
  toolId: string;
164
+ headers: Record<string, string> | null;
165
+ selectedTools: string[] | null;
165
166
  toolPolicies: Record<string, {
166
167
  needsApproval?: boolean;
167
168
  }> | null;
168
- selectedTools: string[] | null;
169
169
  }>;
170
170
  /**
171
171
  * Upsert agent-tool relation (create if it doesn't exist, update if it does)
@@ -182,18 +182,18 @@ declare const upsertSubAgentToolRelation: (db: AgentsManageDatabaseClient) => (p
182
182
  relationId?: string;
183
183
  }) => Promise<{
184
184
  tenantId: string;
185
- agentId: string;
186
185
  projectId: string;
186
+ agentId: string;
187
+ subAgentId: string;
187
188
  id: string;
188
189
  createdAt: string;
189
190
  updatedAt: string;
190
- subAgentId: string;
191
- headers: Record<string, string> | null;
192
191
  toolId: string;
192
+ headers: Record<string, string> | null;
193
+ selectedTools: string[] | null;
193
194
  toolPolicies: Record<string, {
194
195
  needsApproval?: boolean;
195
196
  }> | null;
196
- selectedTools: string[] | null;
197
197
  }>;
198
198
  /**
199
199
  * Upsert a tool (create if it doesn't exist, update if it does)
@@ -201,11 +201,11 @@ declare const upsertSubAgentToolRelation: (db: AgentsManageDatabaseClient) => (p
201
201
  declare const upsertTool: (db: AgentsManageDatabaseClient) => (params: {
202
202
  data: ToolInsert;
203
203
  }) => Promise<{
204
- tenantId: string;
204
+ name: string;
205
205
  description: string | null;
206
+ tenantId: string;
206
207
  projectId: string;
207
208
  id: string;
208
- name: string;
209
209
  createdAt: string;
210
210
  updatedAt: string;
211
211
  headers: Record<string, string> | null;
@@ -9,13 +9,13 @@ import "../../credential-stuffer/index.js";
9
9
  import { createAgentsRunDatabaseClient } from "../../db/runtime/runtime-client.js";
10
10
  import { generateId } from "../../utils/conversations.js";
11
11
  import { getActiveBranch } from "../../dolt/schema-sync.js";
12
+ import { cascadeDeleteByTool } from "../runtime/cascade-delete.js";
12
13
  import { updateAgentToolRelation } from "./subAgentRelations.js";
13
14
  import { toISODateString } from "../../utils/date.js";
14
15
  import { McpClient } from "../../utils/mcp-client.js";
15
16
  import { configureComposioMCPServer } from "../../utils/third-party-mcp-servers/composio-client.js";
16
17
  import { isThirdPartyMCPServerAuthenticated } from "../../utils/third-party-mcp-servers/third-party-check.js";
17
18
  import "../../utils/index.js";
18
- import { cascadeDeleteByTool } from "../runtime/cascade-delete.js";
19
19
  import { isGithubWorkAppTool } from "../runtime/github-work-app-installations.js";
20
20
  import { getCredentialReference, getUserScopedCredentialReference } from "./credentialReferences.js";
21
21
  import { and, count, desc, eq } from "drizzle-orm";
@@ -46,7 +46,7 @@ declare const listTriggersPaginated: (db: AgentsManageDatabaseClient) => (params
46
46
  regex?: string | undefined;
47
47
  };
48
48
  signedComponents: {
49
- source: "literal" | "header" | "body";
49
+ source: "header" | "literal" | "body";
50
50
  required: boolean;
51
51
  key?: string | undefined;
52
52
  value?: string | undefined;
@@ -8,49 +8,49 @@ declare const getApiKeyById: (db: AgentsRunDatabaseClient) => (params: {
8
8
  scopes: ProjectScopeConfig;
9
9
  id: string;
10
10
  }) => Promise<{
11
+ name: string | null;
11
12
  tenantId: string;
12
- agentId: string;
13
13
  projectId: string;
14
+ agentId: string;
14
15
  id: string;
15
- name: string | null;
16
16
  createdAt: string;
17
17
  updatedAt: string;
18
+ expiresAt: string | null;
18
19
  publicId: string;
19
20
  keyHash: string;
20
21
  keyPrefix: string;
21
22
  lastUsedAt: string | null;
22
- expiresAt: string | null;
23
23
  } | undefined>;
24
24
  declare const getApiKeyByPublicId: (db: AgentsRunDatabaseClient) => (publicId: string) => Promise<{
25
+ name: string | null;
25
26
  tenantId: string;
26
- agentId: string;
27
27
  projectId: string;
28
+ agentId: string;
28
29
  id: string;
29
- name: string | null;
30
30
  createdAt: string;
31
31
  updatedAt: string;
32
+ expiresAt: string | null;
32
33
  publicId: string;
33
34
  keyHash: string;
34
35
  keyPrefix: string;
35
36
  lastUsedAt: string | null;
36
- expiresAt: string | null;
37
37
  } | undefined>;
38
38
  declare const listApiKeys: (db: AgentsRunDatabaseClient) => (params: {
39
39
  scopes: ProjectScopeConfig;
40
40
  agentId?: string;
41
41
  }) => Promise<{
42
+ name: string | null;
42
43
  tenantId: string;
43
- agentId: string;
44
44
  projectId: string;
45
+ agentId: string;
45
46
  id: string;
46
- name: string | null;
47
47
  createdAt: string;
48
48
  updatedAt: string;
49
+ expiresAt: string | null;
49
50
  publicId: string;
50
51
  keyHash: string;
51
52
  keyPrefix: string;
52
53
  lastUsedAt: string | null;
53
- expiresAt: string | null;
54
54
  }[]>;
55
55
  declare const listApiKeysPaginated: (db: AgentsRunDatabaseClient) => (params: {
56
56
  scopes: ProjectScopeConfig;
@@ -66,18 +66,18 @@ declare const listApiKeysPaginated: (db: AgentsRunDatabaseClient) => (params: {
66
66
  };
67
67
  }>;
68
68
  declare const createApiKey: (db: AgentsRunDatabaseClient) => (params: ApiKeyInsert) => Promise<{
69
+ name: string | null;
69
70
  tenantId: string;
70
- agentId: string;
71
71
  projectId: string;
72
+ agentId: string;
72
73
  id: string;
73
- name: string | null;
74
74
  createdAt: string;
75
75
  updatedAt: string;
76
+ expiresAt: string | null;
76
77
  publicId: string;
77
78
  keyHash: string;
78
79
  keyPrefix: string;
79
80
  lastUsedAt: string | null;
80
- expiresAt: string | null;
81
81
  }>;
82
82
  declare const updateApiKey: (db: AgentsRunDatabaseClient) => (params: {
83
83
  scopes: ProjectScopeConfig;
@@ -11,6 +11,8 @@ type CascadeDeleteResult = {
11
11
  tasksDeleted: number;
12
12
  contextCacheDeleted: number;
13
13
  apiKeysDeleted: number;
14
+ slackChannelConfigsDeleted: number;
15
+ slackWorkspaceDefaultsCleared: number;
14
16
  };
15
17
  /**
16
18
  * Delete all runtime entities for a specific branch.
@@ -1,4 +1,5 @@
1
1
  import { apiKeys, contextCache, conversations, tasks, workAppGitHubMcpToolAccessMode, workAppGitHubMcpToolRepositoryAccess, workAppGitHubProjectAccessMode, workAppGitHubProjectRepositoryAccess } from "../../db/runtime/runtime-schema.js";
2
+ import { clearDevConfigWorkspaceDefaultsByAgent, clearDevConfigWorkspaceDefaultsByProject, clearWorkspaceDefaultsByAgent, clearWorkspaceDefaultsByProject, deleteWorkAppSlackChannelAgentConfigsByAgent, deleteWorkAppSlackChannelAgentConfigsByProject } from "./workAppSlack.js";
2
3
  import { and, eq, inArray, sql } from "drizzle-orm";
3
4
 
4
5
  //#region src/data-access/runtime/cascade-delete.ts
@@ -18,7 +19,9 @@ const cascadeDeleteByBranch = (db) => async (params) => {
18
19
  conversationsDeleted: conversationsResult.length,
19
20
  tasksDeleted: tasksResult.length,
20
21
  contextCacheDeleted: contextCacheResult.length,
21
- apiKeysDeleted: 0
22
+ apiKeysDeleted: 0,
23
+ slackChannelConfigsDeleted: 0,
24
+ slackWorkspaceDefaultsCleared: 0
22
25
  };
23
26
  };
24
27
  /**
@@ -39,11 +42,16 @@ const cascadeDeleteByProject = (db) => async (params) => {
39
42
  tenantId: scopes.tenantId,
40
43
  projectId: scopes.projectId
41
44
  });
45
+ const slackChannelConfigsDeleted = await deleteWorkAppSlackChannelAgentConfigsByProject(db)(scopes.tenantId, scopes.projectId);
46
+ const slackWorkspaceDefaultsCleared = await clearWorkspaceDefaultsByProject(db)(scopes.tenantId, scopes.projectId);
47
+ clearDevConfigWorkspaceDefaultsByProject(scopes.projectId);
42
48
  return {
43
49
  conversationsDeleted: conversationsResult.length,
44
50
  tasksDeleted: tasksResult.length,
45
51
  contextCacheDeleted: contextCacheResult.length,
46
- apiKeysDeleted: apiKeysResult.length
52
+ apiKeysDeleted: apiKeysResult.length,
53
+ slackChannelConfigsDeleted,
54
+ slackWorkspaceDefaultsCleared
47
55
  };
48
56
  };
49
57
  /**
@@ -69,11 +77,16 @@ const cascadeDeleteByAgent = (db) => async (params) => {
69
77
  }
70
78
  tasksDeleted = (await db.delete(tasks).where(and(eq(tasks.tenantId, scopes.tenantId), eq(tasks.projectId, scopes.projectId), eq(tasks.agentId, scopes.agentId), sql`${tasks.ref}->>'name' = ${fullBranchName}`)).returning()).length;
71
79
  apiKeysDeleted = (await db.delete(apiKeys).where(and(eq(apiKeys.tenantId, scopes.tenantId), eq(apiKeys.projectId, scopes.projectId), eq(apiKeys.agentId, scopes.agentId))).returning()).length;
80
+ const slackChannelConfigsDeleted = await deleteWorkAppSlackChannelAgentConfigsByAgent(db)(scopes.tenantId, scopes.projectId, scopes.agentId);
81
+ const slackWorkspaceDefaultsCleared = await clearWorkspaceDefaultsByAgent(db)(scopes.tenantId, scopes.projectId, scopes.agentId);
82
+ clearDevConfigWorkspaceDefaultsByAgent(scopes.projectId, scopes.agentId);
72
83
  return {
73
84
  conversationsDeleted,
74
85
  tasksDeleted,
75
86
  contextCacheDeleted,
76
- apiKeysDeleted
87
+ apiKeysDeleted,
88
+ slackChannelConfigsDeleted,
89
+ slackWorkspaceDefaultsCleared
77
90
  };
78
91
  };
79
92
  /**
@@ -96,7 +109,9 @@ const cascadeDeleteBySubAgent = (db) => async (params) => {
96
109
  conversationsDeleted,
97
110
  tasksDeleted: tasksResult.length,
98
111
  contextCacheDeleted,
99
- apiKeysDeleted: 0
112
+ apiKeysDeleted: 0,
113
+ slackChannelConfigsDeleted: 0,
114
+ slackWorkspaceDefaultsCleared: 0
100
115
  };
101
116
  };
102
117
  /**
@@ -16,20 +16,20 @@ declare const listConversations: (db: AgentsRunDatabaseClient) => (params: {
16
16
  total: number;
17
17
  }>;
18
18
  declare const createConversation: (db: AgentsRunDatabaseClient) => (params: ConversationInsert) => Promise<{
19
- tenantId: string;
20
- userId: string | null;
21
19
  title: string | null;
22
- agentId: string | null;
20
+ tenantId: string;
23
21
  projectId: string;
22
+ agentId: string | null;
24
23
  id: string;
25
24
  createdAt: string;
26
25
  updatedAt: string;
27
- metadata: ConversationMetadata | null;
28
26
  ref: {
29
27
  type: "commit" | "tag" | "branch";
30
28
  name: string;
31
29
  hash: string;
32
30
  } | null;
31
+ userId: string | null;
32
+ metadata: ConversationMetadata | null;
33
33
  activeSubAgentId: string;
34
34
  lastContextResolution: string | null;
35
35
  }>;
@@ -85,20 +85,20 @@ declare const getConversation: (db: AgentsRunDatabaseClient) => (params: {
85
85
  scopes: ProjectScopeConfig;
86
86
  conversationId: string;
87
87
  }) => Promise<{
88
- tenantId: string;
89
- userId: string | null;
90
88
  title: string | null;
91
- agentId: string | null;
89
+ tenantId: string;
92
90
  projectId: string;
91
+ agentId: string | null;
93
92
  id: string;
94
93
  createdAt: string;
95
94
  updatedAt: string;
96
- metadata: ConversationMetadata | null;
97
95
  ref: {
98
96
  type: "commit" | "tag" | "branch";
99
97
  name: string;
100
98
  hash: string;
101
99
  } | null;
100
+ userId: string | null;
101
+ metadata: ConversationMetadata | null;
102
102
  activeSubAgentId: string;
103
103
  lastContextResolution: string | null;
104
104
  } | undefined>;
@@ -121,20 +121,20 @@ declare const createOrGetConversation: (db: AgentsRunDatabaseClient) => (input:
121
121
  metadata?: ConversationMetadata | null | undefined;
122
122
  contextConfigId?: string | undefined;
123
123
  } | {
124
- tenantId: string;
125
- userId: string | null;
126
124
  title: string | null;
127
- agentId: string | null;
125
+ tenantId: string;
128
126
  projectId: string;
127
+ agentId: string | null;
129
128
  id: string;
130
129
  createdAt: string;
131
130
  updatedAt: string;
132
- metadata: ConversationMetadata | null;
133
131
  ref: {
134
132
  type: "commit" | "tag" | "branch";
135
133
  name: string;
136
134
  hash: string;
137
135
  } | null;
136
+ userId: string | null;
137
+ metadata: ConversationMetadata | null;
138
138
  activeSubAgentId: string;
139
139
  lastContextResolution: string | null;
140
140
  }>;
@@ -153,20 +153,20 @@ declare const getActiveAgentForConversation: (db: AgentsRunDatabaseClient) => (p
153
153
  scopes: ProjectScopeConfig;
154
154
  conversationId: string;
155
155
  }) => Promise<{
156
- tenantId: string;
157
- userId: string | null;
158
156
  title: string | null;
159
- agentId: string | null;
157
+ tenantId: string;
160
158
  projectId: string;
159
+ agentId: string | null;
161
160
  id: string;
162
161
  createdAt: string;
163
162
  updatedAt: string;
164
- metadata: ConversationMetadata | null;
165
163
  ref: {
166
164
  type: "commit" | "tag" | "branch";
167
165
  name: string;
168
166
  hash: string;
169
167
  } | null;
168
+ userId: string | null;
169
+ metadata: ConversationMetadata | null;
170
170
  activeSubAgentId: string;
171
171
  lastContextResolution: string | null;
172
172
  } | undefined>;
@@ -16,20 +16,20 @@ declare const getMessageById: (db: AgentsRunDatabaseClient) => (params: {
16
16
  createdAt: string;
17
17
  updatedAt: string;
18
18
  metadata: MessageMetadata | null;
19
- content: MessageContent;
19
+ role: string;
20
+ conversationId: string;
20
21
  fromSubAgentId: string | null;
21
22
  toSubAgentId: string | null;
22
23
  fromExternalAgentId: string | null;
23
24
  toExternalAgentId: string | null;
24
- taskId: string | null;
25
- a2aTaskId: string | null;
26
- conversationId: string;
27
- role: string;
28
25
  fromTeamAgentId: string | null;
29
26
  toTeamAgentId: string | null;
27
+ content: MessageContent;
30
28
  visibility: string;
31
29
  messageType: string;
30
+ taskId: string | null;
32
31
  parentMessageId: string | null;
32
+ a2aTaskId: string | null;
33
33
  a2aSessionId: string | null;
34
34
  } | undefined>;
35
35
  declare const listMessages: (db: AgentsRunDatabaseClient) => (params: {
@@ -147,20 +147,20 @@ declare const createMessage: (db: AgentsRunDatabaseClient) => (params: MessageIn
147
147
  createdAt: string;
148
148
  updatedAt: string;
149
149
  metadata: MessageMetadata | null;
150
- content: MessageContent;
150
+ role: string;
151
+ conversationId: string;
151
152
  fromSubAgentId: string | null;
152
153
  toSubAgentId: string | null;
153
154
  fromExternalAgentId: string | null;
154
155
  toExternalAgentId: string | null;
155
- taskId: string | null;
156
- a2aTaskId: string | null;
157
- conversationId: string;
158
- role: string;
159
156
  fromTeamAgentId: string | null;
160
157
  toTeamAgentId: string | null;
158
+ content: MessageContent;
161
159
  visibility: string;
162
160
  messageType: string;
161
+ taskId: string | null;
163
162
  parentMessageId: string | null;
163
+ a2aTaskId: string | null;
164
164
  a2aSessionId: string | null;
165
165
  }>;
166
166
  declare const updateMessage: (db: AgentsRunDatabaseClient) => (params: {
@@ -200,20 +200,20 @@ declare const deleteMessage: (db: AgentsRunDatabaseClient) => (params: {
200
200
  createdAt: string;
201
201
  updatedAt: string;
202
202
  metadata: MessageMetadata | null;
203
- content: MessageContent;
203
+ role: string;
204
+ conversationId: string;
204
205
  fromSubAgentId: string | null;
205
206
  toSubAgentId: string | null;
206
207
  fromExternalAgentId: string | null;
207
208
  toExternalAgentId: string | null;
208
- taskId: string | null;
209
- a2aTaskId: string | null;
210
- conversationId: string;
211
- role: string;
212
209
  fromTeamAgentId: string | null;
213
210
  toTeamAgentId: string | null;
211
+ content: MessageContent;
214
212
  visibility: string;
215
213
  messageType: string;
214
+ taskId: string | null;
216
215
  parentMessageId: string | null;
216
+ a2aTaskId: string | null;
217
217
  a2aSessionId: string | null;
218
218
  }>;
219
219
  declare const countMessagesByConversation: (db: AgentsRunDatabaseClient) => (params: {
@@ -34,7 +34,7 @@ declare const listScheduledTriggerInvocationsPaginated: (db: AgentsRunDatabaseCl
34
34
  }) => Promise<{
35
35
  data: {
36
36
  scheduledTriggerId: string;
37
- status: "pending" | "failed" | "running" | "completed" | "cancelled";
37
+ status: "pending" | "running" | "completed" | "failed" | "cancelled";
38
38
  scheduledFor: string;
39
39
  startedAt: string | null;
40
40
  completedAt: string | null;
@@ -174,7 +174,7 @@ declare const listUpcomingInvocationsForAgentPaginated: (db: AgentsRunDatabaseCl
174
174
  }) => Promise<{
175
175
  data: {
176
176
  scheduledTriggerId: string;
177
- status: "pending" | "failed" | "running" | "completed" | "cancelled";
177
+ status: "pending" | "running" | "completed" | "failed" | "cancelled";
178
178
  scheduledFor: string;
179
179
  startedAt: string | null;
180
180
  completedAt: string | null;
@@ -208,7 +208,7 @@ declare const listProjectScheduledTriggerInvocationsPaginated: (db: AgentsRunDat
208
208
  }) => Promise<{
209
209
  data: {
210
210
  scheduledTriggerId: string;
211
- status: "pending" | "failed" | "running" | "completed" | "cancelled";
211
+ status: "pending" | "running" | "completed" | "failed" | "cancelled";
212
212
  scheduledFor: string;
213
213
  startedAt: string | null;
214
214
  completedAt: string | null;
@@ -7,20 +7,20 @@ import { TaskInsert, TaskSelect } from "../../types/entities.js";
7
7
  //#region src/data-access/runtime/tasks.d.ts
8
8
  declare const createTask: (db: AgentsRunDatabaseClient) => (params: TaskInsert) => Promise<{
9
9
  tenantId: string;
10
- status: string;
11
- agentId: string;
12
10
  projectId: string;
11
+ agentId: string;
12
+ subAgentId: string;
13
13
  id: string;
14
14
  createdAt: string;
15
15
  updatedAt: string;
16
- metadata: TaskMetadataConfig | null;
17
- subAgentId: string;
18
- contextId: string;
19
16
  ref: {
20
17
  type: "commit" | "tag" | "branch";
21
18
  name: string;
22
19
  hash: string;
23
20
  } | null;
21
+ metadata: TaskMetadataConfig | null;
22
+ status: string;
23
+ contextId: string;
24
24
  }>;
25
25
  declare const getTask: (db: AgentsRunDatabaseClient) => (params: {
26
26
  id: string;