@agentrix/shared 2.1.0 → 2.2.1
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/index.cjs +137 -12
- package/dist/index.d.cts +270 -9
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -283,8 +283,8 @@ const StartTaskResponseSchema = zod.z.object({
|
|
|
283
283
|
});
|
|
284
284
|
const TaskItemSchema = zod.z.object({
|
|
285
285
|
id: IdSchema,
|
|
286
|
-
type: zod.z.enum(["chat", "work"]).default("work"),
|
|
287
|
-
// Task type: "chat" (virtual
|
|
286
|
+
type: zod.z.enum(["chat", "work", "shadow"]).default("work"),
|
|
287
|
+
// Task type: "chat" (virtual) | "work" (real work) | "shadow" (companion heartbeat/shadow)
|
|
288
288
|
chatId: IdSchema,
|
|
289
289
|
userId: zod.z.string(),
|
|
290
290
|
state: zod.z.string(),
|
|
@@ -540,6 +540,25 @@ const SubTaskSummarySchema = zod.z.object({
|
|
|
540
540
|
const ListSubTasksResponseSchema = zod.z.object({
|
|
541
541
|
tasks: zod.z.array(SubTaskSummarySchema)
|
|
542
542
|
});
|
|
543
|
+
const ListRecentTasksRequestSchema = zod.z.object({
|
|
544
|
+
chatId: zod.z.string(),
|
|
545
|
+
limit: zod.z.coerce.number().int().min(1).max(50).optional().default(10),
|
|
546
|
+
status: zod.z.enum(["all", "active", "completed"]).optional().default("all")
|
|
547
|
+
});
|
|
548
|
+
const RecentTaskSummarySchema = zod.z.object({
|
|
549
|
+
taskId: IdSchema,
|
|
550
|
+
type: zod.z.enum(["chat", "work", "shadow"]),
|
|
551
|
+
state: zod.z.string(),
|
|
552
|
+
agentId: zod.z.string(),
|
|
553
|
+
title: zod.z.string().nullable(),
|
|
554
|
+
totalDuration: zod.z.number().nullable(),
|
|
555
|
+
createdAt: zod.z.string(),
|
|
556
|
+
updatedAt: zod.z.string()
|
|
557
|
+
});
|
|
558
|
+
const ListRecentTasksResponseSchema = zod.z.object({
|
|
559
|
+
tasks: zod.z.array(RecentTaskSummarySchema),
|
|
560
|
+
hasMore: zod.z.boolean()
|
|
561
|
+
});
|
|
543
562
|
const FindTaskByAgentRequestSchema = zod.z.object({
|
|
544
563
|
parentTaskId: zod.z.string(),
|
|
545
564
|
agentId: zod.z.string()
|
|
@@ -586,7 +605,10 @@ const ChatMemberInputSchema = zod.z.object({
|
|
|
586
605
|
const CreateChatRequestSchema = zod.z.object({
|
|
587
606
|
type: ChatTypeSchema.default("direct"),
|
|
588
607
|
// Optional, defaults to 'direct'
|
|
589
|
-
members: zod.z.array(ChatMemberInputSchema)
|
|
608
|
+
members: zod.z.array(ChatMemberInputSchema),
|
|
609
|
+
// Encryption keys for companion chat tasks (generated by App, stored on virtual task)
|
|
610
|
+
dataEncryptionKey: zod.z.string().optional(),
|
|
611
|
+
ownerEncryptedDataKey: zod.z.string().optional()
|
|
590
612
|
});
|
|
591
613
|
const CreateChatResponseSchema = ChatWithMembersSchema;
|
|
592
614
|
const ListChatsQuerySchema = zod.z.object({
|
|
@@ -624,7 +646,7 @@ const UpdateChatContextRequestSchema = zod.z.object({
|
|
|
624
646
|
});
|
|
625
647
|
const UpdateChatContextResponseSchema = ChatSchema;
|
|
626
648
|
|
|
627
|
-
const AgentTypeSchema = zod.z.enum(["claude", "codex"]);
|
|
649
|
+
const AgentTypeSchema = zod.z.enum(["claude", "codex", "companion"]);
|
|
628
650
|
const DisplayConfigKeysSchema = zod.z.object({
|
|
629
651
|
// PR Actions
|
|
630
652
|
createPR: zod.z.string().optional(),
|
|
@@ -648,7 +670,9 @@ const DisplayConfigKeysSchema = zod.z.object({
|
|
|
648
670
|
});
|
|
649
671
|
const DisplayConfigSchema = zod.z.record(zod.z.string(), DisplayConfigKeysSchema);
|
|
650
672
|
const AgentCustomConfigSchema = zod.z.object({
|
|
651
|
-
displayConfig: DisplayConfigSchema.optional()
|
|
673
|
+
displayConfig: DisplayConfigSchema.optional(),
|
|
674
|
+
machineId: zod.z.string().optional(),
|
|
675
|
+
heartbeatTaskId: zod.z.string().optional()
|
|
652
676
|
});
|
|
653
677
|
const AgentPermissionsSchema = zod.z.object({
|
|
654
678
|
role: zod.z.string(),
|
|
@@ -659,6 +683,7 @@ const AgentPermissionsSchema = zod.z.object({
|
|
|
659
683
|
const AgentSchema = zod.z.object({
|
|
660
684
|
id: IdSchema,
|
|
661
685
|
name: zod.z.string(),
|
|
686
|
+
displayName: zod.z.string().nullable(),
|
|
662
687
|
type: AgentTypeSchema,
|
|
663
688
|
avatar: zod.z.string().nullable(),
|
|
664
689
|
userId: zod.z.string(),
|
|
@@ -695,6 +720,7 @@ const CreateAgentRequestSchema = zod.z.object({
|
|
|
695
720
|
const CreateAgentResponseSchema = AgentSchema;
|
|
696
721
|
const UpdateAgentRequestSchema = zod.z.object({
|
|
697
722
|
name: zod.z.string().min(1).optional(),
|
|
723
|
+
displayName: zod.z.string().nullable().optional(),
|
|
698
724
|
type: AgentTypeSchema.optional(),
|
|
699
725
|
avatar: zod.z.string().nullable().optional(),
|
|
700
726
|
description: zod.z.string().nullable().optional(),
|
|
@@ -1229,7 +1255,7 @@ const AskUserResponseMessageSchema = zod.z.object({
|
|
|
1229
1255
|
const TaskAgentInfoSchema = zod.z.object({
|
|
1230
1256
|
id: zod.z.string(),
|
|
1231
1257
|
name: zod.z.string(),
|
|
1232
|
-
type:
|
|
1258
|
+
type: AgentTypeSchema.optional().default("claude"),
|
|
1233
1259
|
description: zod.z.string().optional()
|
|
1234
1260
|
});
|
|
1235
1261
|
function isAskUserMessage(message) {
|
|
@@ -1238,8 +1264,14 @@ function isAskUserMessage(message) {
|
|
|
1238
1264
|
function isAskUserResponseMessage(message) {
|
|
1239
1265
|
return typeof message === "object" && message !== null && "type" in message && message.type === "ask_user_response";
|
|
1240
1266
|
}
|
|
1267
|
+
function isCompanionHeartbeatMessage(message) {
|
|
1268
|
+
return typeof message === "object" && message !== null && "type" in message && message.type === "companion_heartbeat";
|
|
1269
|
+
}
|
|
1270
|
+
function isCompanionReminderMessage(message) {
|
|
1271
|
+
return typeof message === "object" && message !== null && "type" in message && message.type === "companion_reminder";
|
|
1272
|
+
}
|
|
1241
1273
|
function isSDKMessage(message) {
|
|
1242
|
-
return typeof message === "object" && message !== null && "type" in message && message.type !== "ask_user" && message.type !== "ask_user_response";
|
|
1274
|
+
return typeof message === "object" && message !== null && "type" in message && message.type !== "ask_user" && message.type !== "ask_user_response" && message.type !== "companion_heartbeat" && message.type !== "companion_reminder";
|
|
1243
1275
|
}
|
|
1244
1276
|
function isSDKUserMessage(message) {
|
|
1245
1277
|
return isSDKMessage(message) && message.type === "user";
|
|
@@ -1376,8 +1408,8 @@ const baseTaskSchema = EventBaseSchema.extend({
|
|
|
1376
1408
|
// Agents available for this task
|
|
1377
1409
|
todos: zod.z.array(TaskTodoSchema).optional(),
|
|
1378
1410
|
// Structured todos for group tasks
|
|
1379
|
-
taskType: zod.z.enum(["chat", "work"]).optional().default("work"),
|
|
1380
|
-
// Task type: 'chat' for main chat, 'work' for task execution
|
|
1411
|
+
taskType: zod.z.enum(["chat", "work", "shadow"]).optional().default("work"),
|
|
1412
|
+
// Task type: 'chat' for main chat, 'work' for task execution, 'shadow' for companion shadow
|
|
1381
1413
|
customTitle: zod.z.string().min(1).max(200).optional()
|
|
1382
1414
|
// Custom task title (set by user/tool)
|
|
1383
1415
|
});
|
|
@@ -1452,6 +1484,8 @@ const TaskMessageSchema = EventBaseSchema.extend({
|
|
|
1452
1484
|
message: "Invalid TaskMessagePayload format"
|
|
1453
1485
|
}
|
|
1454
1486
|
).optional(),
|
|
1487
|
+
messageType: zod.z.string().optional(),
|
|
1488
|
+
// Message type metadata (for encrypted payload routing)
|
|
1455
1489
|
encryptedMessage: zod.z.string().optional(),
|
|
1456
1490
|
// base64 sealed-box payload (local mode)
|
|
1457
1491
|
// Multi-agent collaboration fields
|
|
@@ -1623,6 +1657,8 @@ const SubTaskResultUpdatedEventSchema = EventBaseSchema.extend({
|
|
|
1623
1657
|
result: zod.z.string(),
|
|
1624
1658
|
is_error: zod.z.boolean().optional()
|
|
1625
1659
|
}),
|
|
1660
|
+
encryptedResultMessage: zod.z.string().optional(),
|
|
1661
|
+
// Encrypted result payload for E2E forwarding
|
|
1626
1662
|
// Optional artifacts summary (for displaying in parent task chat)
|
|
1627
1663
|
artifacts: TaskArtifactsSummarySchema.optional()
|
|
1628
1664
|
});
|
|
@@ -1681,6 +1717,15 @@ const AssociateRepoEventDataSchema = EventBaseSchema.extend({
|
|
|
1681
1717
|
remoteUrl: zod.z.string()
|
|
1682
1718
|
// Original URL for logging
|
|
1683
1719
|
});
|
|
1720
|
+
const UpdateAgentInfoEventSchema = EventBaseSchema.extend({
|
|
1721
|
+
taskId: zod.z.string(),
|
|
1722
|
+
agentId: zod.z.string(),
|
|
1723
|
+
displayName: zod.z.string().optional(),
|
|
1724
|
+
avatar: zod.z.string().optional(),
|
|
1725
|
+
// emoji or URL (fileId)
|
|
1726
|
+
signature: zod.z.string().optional()
|
|
1727
|
+
// status line / tagline
|
|
1728
|
+
});
|
|
1684
1729
|
const IdOnlySchema = zod.z.object({
|
|
1685
1730
|
id: zod.z.string()
|
|
1686
1731
|
});
|
|
@@ -1705,6 +1750,7 @@ const SystemMessageSchema = EventBaseSchema.extend({
|
|
|
1705
1750
|
"repo-removed",
|
|
1706
1751
|
"pr-state-changed",
|
|
1707
1752
|
"draft-agent-added",
|
|
1753
|
+
"agent-updated",
|
|
1708
1754
|
"task-added"
|
|
1709
1755
|
]),
|
|
1710
1756
|
data: zod.z.union([
|
|
@@ -1722,6 +1768,8 @@ const SystemMessageSchema = EventBaseSchema.extend({
|
|
|
1722
1768
|
// pr-state-changed
|
|
1723
1769
|
DraftAgentSchema,
|
|
1724
1770
|
// draft-agent-added
|
|
1771
|
+
AgentSchema,
|
|
1772
|
+
// agent-updated
|
|
1725
1773
|
TaskItemSchema
|
|
1726
1774
|
// task-added
|
|
1727
1775
|
]),
|
|
@@ -1733,6 +1781,7 @@ const DaemonGitlabOperationSchema = zod.z.enum([
|
|
|
1733
1781
|
"createMergeRequest",
|
|
1734
1782
|
"getMergeRequest",
|
|
1735
1783
|
"listMergeRequests",
|
|
1784
|
+
"requestGitlabApi",
|
|
1736
1785
|
"resolveGitAuthContext"
|
|
1737
1786
|
]);
|
|
1738
1787
|
const DaemonGitlabRequestSchema = EventBaseSchema.extend({
|
|
@@ -1753,6 +1802,20 @@ const DaemonGitlabResponseSchema = EventBaseSchema.extend({
|
|
|
1753
1802
|
machineId: zod.z.string(),
|
|
1754
1803
|
executionTimeMs: zod.z.number()
|
|
1755
1804
|
});
|
|
1805
|
+
const CompanionHeartbeatRequestSchema = EventBaseSchema.extend({
|
|
1806
|
+
machineId: zod.z.string(),
|
|
1807
|
+
agentId: zod.z.string(),
|
|
1808
|
+
chatId: zod.z.string(),
|
|
1809
|
+
userId: zod.z.string(),
|
|
1810
|
+
timestamp: zod.z.string()
|
|
1811
|
+
});
|
|
1812
|
+
const CompanionHeartbeatResponseSchema = EventBaseSchema.extend({
|
|
1813
|
+
taskId: zod.z.string(),
|
|
1814
|
+
chatId: zod.z.string()
|
|
1815
|
+
});
|
|
1816
|
+
const ResetTaskSessionSchema = EventBaseSchema.extend({
|
|
1817
|
+
taskId: zod.z.string()
|
|
1818
|
+
});
|
|
1756
1819
|
const EventSchemaMap = {
|
|
1757
1820
|
// App events
|
|
1758
1821
|
"app-alive": AppAliveEventSchema,
|
|
@@ -1793,6 +1856,8 @@ const EventSchemaMap = {
|
|
|
1793
1856
|
"sub-task-result-updated": SubTaskResultUpdatedEventSchema,
|
|
1794
1857
|
// Repository association events
|
|
1795
1858
|
"associate-repo": AssociateRepoEventDataSchema,
|
|
1859
|
+
// Agent info update events
|
|
1860
|
+
"update-agent-info": UpdateAgentInfoEventSchema,
|
|
1796
1861
|
// System message events
|
|
1797
1862
|
"system-message": SystemMessageSchema,
|
|
1798
1863
|
// Billing events
|
|
@@ -1811,6 +1876,10 @@ const EventSchemaMap = {
|
|
|
1811
1876
|
// Daemon GitLab proxy events
|
|
1812
1877
|
"daemon-gitlab-request": DaemonGitlabRequestSchema,
|
|
1813
1878
|
"daemon-gitlab-response": DaemonGitlabResponseSchema,
|
|
1879
|
+
// Companion heartbeat events
|
|
1880
|
+
"request-companion-heartbeat": CompanionHeartbeatRequestSchema,
|
|
1881
|
+
"companion-heartbeat-response": CompanionHeartbeatResponseSchema,
|
|
1882
|
+
"reset-task-session": ResetTaskSessionSchema,
|
|
1814
1883
|
// Ack events
|
|
1815
1884
|
"event-ack": EventAckSchema
|
|
1816
1885
|
};
|
|
@@ -1822,9 +1891,11 @@ const workerTaskEvents = [
|
|
|
1822
1891
|
"worker-exit",
|
|
1823
1892
|
"change-task-title",
|
|
1824
1893
|
"update-task-agent-session-id",
|
|
1894
|
+
"reset-task-session",
|
|
1825
1895
|
"merge-request",
|
|
1826
1896
|
"merge-pr",
|
|
1827
|
-
"associate-repo"
|
|
1897
|
+
"associate-repo",
|
|
1898
|
+
"update-agent-info"
|
|
1828
1899
|
];
|
|
1829
1900
|
|
|
1830
1901
|
function userAuth(token) {
|
|
@@ -2116,10 +2187,51 @@ async function loadSystemPrompt(claudeDir, promptFile) {
|
|
|
2116
2187
|
);
|
|
2117
2188
|
}
|
|
2118
2189
|
}
|
|
2119
|
-
function replacePromptPlaceholders(template, cwd) {
|
|
2120
|
-
|
|
2190
|
+
function replacePromptPlaceholders(template, cwd, extra) {
|
|
2191
|
+
const vars = {
|
|
2192
|
+
WORKING_DIR: cwd,
|
|
2193
|
+
PLATFORM: process.platform,
|
|
2194
|
+
OS_VERSION: `${os__namespace.type()} ${os__namespace.release()}`,
|
|
2195
|
+
DATE: (/* @__PURE__ */ new Date()).toISOString().split("T")[0],
|
|
2196
|
+
...extra
|
|
2197
|
+
};
|
|
2198
|
+
let result = template.replace(
|
|
2199
|
+
/\{\{#if\s+(\w+)\s*(==|!=)\s*(\w+)\}\}([\s\S]*?)\{\{\/if\}\}/g,
|
|
2200
|
+
(_match, key, op, expected, content) => {
|
|
2201
|
+
const actual = vars[key] ?? "";
|
|
2202
|
+
const matches = op === "==" ? actual === expected : actual !== expected;
|
|
2203
|
+
return matches ? content : "";
|
|
2204
|
+
}
|
|
2205
|
+
);
|
|
2206
|
+
for (const [key, value] of Object.entries(vars)) {
|
|
2207
|
+
result = result.replace(new RegExp(`\\{\\{${key}\\}\\}`, "g"), value);
|
|
2208
|
+
}
|
|
2209
|
+
return result;
|
|
2121
2210
|
}
|
|
2122
2211
|
|
|
2212
|
+
const CompanionWorkspaceFileSchema = zod.z.object({
|
|
2213
|
+
name: zod.z.string(),
|
|
2214
|
+
path: zod.z.string(),
|
|
2215
|
+
// relative to workspace root
|
|
2216
|
+
size: zod.z.number(),
|
|
2217
|
+
modifiedAt: zod.z.number(),
|
|
2218
|
+
isDirectory: zod.z.boolean()
|
|
2219
|
+
});
|
|
2220
|
+
const RegisterCompanionRequestSchema = zod.z.object({
|
|
2221
|
+
machineId: zod.z.string().min(1)
|
|
2222
|
+
});
|
|
2223
|
+
const RegisterCompanionResponseSchema = zod.z.object({
|
|
2224
|
+
agentId: zod.z.string(),
|
|
2225
|
+
userId: zod.z.string(),
|
|
2226
|
+
chatId: zod.z.string(),
|
|
2227
|
+
created: zod.z.boolean()
|
|
2228
|
+
// true = newly created, false = already existed
|
|
2229
|
+
});
|
|
2230
|
+
const CompanionEnsureResponseSchema = zod.z.object({
|
|
2231
|
+
agentDir: zod.z.string(),
|
|
2232
|
+
workspaceDir: zod.z.string()
|
|
2233
|
+
});
|
|
2234
|
+
|
|
2123
2235
|
const cryptoModule = typeof globalThis.crypto !== "undefined" ? globalThis.crypto : (async () => {
|
|
2124
2236
|
try {
|
|
2125
2237
|
const nodeCrypto = await import('node:crypto');
|
|
@@ -2754,6 +2866,10 @@ exports.CloudJoinResultQuerySchema = CloudJoinResultQuerySchema;
|
|
|
2754
2866
|
exports.CloudJoinStatusQuerySchema = CloudJoinStatusQuerySchema;
|
|
2755
2867
|
exports.CloudMachineSchema = CloudMachineSchema;
|
|
2756
2868
|
exports.CloudSchema = CloudSchema;
|
|
2869
|
+
exports.CompanionEnsureResponseSchema = CompanionEnsureResponseSchema;
|
|
2870
|
+
exports.CompanionHeartbeatRequestSchema = CompanionHeartbeatRequestSchema;
|
|
2871
|
+
exports.CompanionHeartbeatResponseSchema = CompanionHeartbeatResponseSchema;
|
|
2872
|
+
exports.CompanionWorkspaceFileSchema = CompanionWorkspaceFileSchema;
|
|
2757
2873
|
exports.ConfirmUploadRequestSchema = ConfirmUploadRequestSchema;
|
|
2758
2874
|
exports.ConfirmUploadResponseSchema = ConfirmUploadResponseSchema;
|
|
2759
2875
|
exports.ConsumeTransactionSchema = ConsumeTransactionSchema;
|
|
@@ -2831,6 +2947,8 @@ exports.ListOAuthServersQuerySchema = ListOAuthServersQuerySchema;
|
|
|
2831
2947
|
exports.ListOAuthServersResponseSchema = ListOAuthServersResponseSchema;
|
|
2832
2948
|
exports.ListPackagesQuerySchema = ListPackagesQuerySchema;
|
|
2833
2949
|
exports.ListPackagesResponseSchema = ListPackagesResponseSchema;
|
|
2950
|
+
exports.ListRecentTasksRequestSchema = ListRecentTasksRequestSchema;
|
|
2951
|
+
exports.ListRecentTasksResponseSchema = ListRecentTasksResponseSchema;
|
|
2834
2952
|
exports.ListRepositoriesResponseSchema = ListRepositoriesResponseSchema;
|
|
2835
2953
|
exports.ListSubTasksRequestSchema = ListSubTasksRequestSchema;
|
|
2836
2954
|
exports.ListSubTasksResponseSchema = ListSubTasksResponseSchema;
|
|
@@ -2874,11 +2992,15 @@ exports.PublishDraftAgentResponseSchema = PublishDraftAgentResponseSchema;
|
|
|
2874
2992
|
exports.QueryEventsRequestSchema = QueryEventsRequestSchema;
|
|
2875
2993
|
exports.RELEVANT_DEPENDENCIES = RELEVANT_DEPENDENCIES;
|
|
2876
2994
|
exports.RTC_CHUNK_HEADER_SIZE = RTC_CHUNK_HEADER_SIZE;
|
|
2995
|
+
exports.RecentTaskSummarySchema = RecentTaskSummarySchema;
|
|
2877
2996
|
exports.RechargeResponseSchema = RechargeResponseSchema;
|
|
2997
|
+
exports.RegisterCompanionRequestSchema = RegisterCompanionRequestSchema;
|
|
2998
|
+
exports.RegisterCompanionResponseSchema = RegisterCompanionResponseSchema;
|
|
2878
2999
|
exports.RemoveChatMemberRequestSchema = RemoveChatMemberRequestSchema;
|
|
2879
3000
|
exports.RepositorySchema = RepositorySchema;
|
|
2880
3001
|
exports.ResetSecretRequestSchema = ResetSecretRequestSchema;
|
|
2881
3002
|
exports.ResetSecretResponseSchema = ResetSecretResponseSchema;
|
|
3003
|
+
exports.ResetTaskSessionSchema = ResetTaskSessionSchema;
|
|
2882
3004
|
exports.ResumeTaskRequestSchema = ResumeTaskRequestSchema;
|
|
2883
3005
|
exports.ResumeTaskResponseSchema = ResumeTaskResponseSchema;
|
|
2884
3006
|
exports.RpcCallEventSchema = RpcCallEventSchema;
|
|
@@ -2930,6 +3052,7 @@ exports.ToggleOAuthServerResponseSchema = ToggleOAuthServerResponseSchema;
|
|
|
2930
3052
|
exports.TransactionSchema = TransactionSchema;
|
|
2931
3053
|
exports.UnarchiveTaskRequestSchema = UnarchiveTaskRequestSchema;
|
|
2932
3054
|
exports.UnarchiveTaskResponseSchema = UnarchiveTaskResponseSchema;
|
|
3055
|
+
exports.UpdateAgentInfoEventSchema = UpdateAgentInfoEventSchema;
|
|
2933
3056
|
exports.UpdateAgentRequestSchema = UpdateAgentRequestSchema;
|
|
2934
3057
|
exports.UpdateAgentResponseSchema = UpdateAgentResponseSchema;
|
|
2935
3058
|
exports.UpdateChatContextRequestSchema = UpdateChatContextRequestSchema;
|
|
@@ -2992,6 +3115,8 @@ exports.getAgentContext = getAgentContext;
|
|
|
2992
3115
|
exports.getRandomBytes = getRandomBytes;
|
|
2993
3116
|
exports.isAskUserMessage = isAskUserMessage;
|
|
2994
3117
|
exports.isAskUserResponseMessage = isAskUserResponseMessage;
|
|
3118
|
+
exports.isCompanionHeartbeatMessage = isCompanionHeartbeatMessage;
|
|
3119
|
+
exports.isCompanionReminderMessage = isCompanionReminderMessage;
|
|
2995
3120
|
exports.isSDKMessage = isSDKMessage;
|
|
2996
3121
|
exports.isSDKUserMessage = isSDKUserMessage;
|
|
2997
3122
|
exports.loadAgentConfig = loadAgentConfig;
|
package/dist/index.d.cts
CHANGED
|
@@ -493,6 +493,7 @@ declare const TaskItemSchema: z.ZodObject<{
|
|
|
493
493
|
type: z.ZodDefault<z.ZodEnum<{
|
|
494
494
|
chat: "chat";
|
|
495
495
|
work: "work";
|
|
496
|
+
shadow: "shadow";
|
|
496
497
|
}>>;
|
|
497
498
|
chatId: z.ZodString;
|
|
498
499
|
userId: z.ZodString;
|
|
@@ -564,6 +565,7 @@ declare const ListTasksResponseSchema: z.ZodObject<{
|
|
|
564
565
|
type: z.ZodDefault<z.ZodEnum<{
|
|
565
566
|
chat: "chat";
|
|
566
567
|
work: "work";
|
|
568
|
+
shadow: "shadow";
|
|
567
569
|
}>>;
|
|
568
570
|
chatId: z.ZodString;
|
|
569
571
|
userId: z.ZodString;
|
|
@@ -863,6 +865,7 @@ declare const ArchiveTaskResponseSchema: z.ZodObject<{
|
|
|
863
865
|
type: z.ZodDefault<z.ZodEnum<{
|
|
864
866
|
chat: "chat";
|
|
865
867
|
work: "work";
|
|
868
|
+
shadow: "shadow";
|
|
866
869
|
}>>;
|
|
867
870
|
chatId: z.ZodString;
|
|
868
871
|
userId: z.ZodString;
|
|
@@ -931,6 +934,7 @@ declare const UnarchiveTaskResponseSchema: z.ZodObject<{
|
|
|
931
934
|
type: z.ZodDefault<z.ZodEnum<{
|
|
932
935
|
chat: "chat";
|
|
933
936
|
work: "work";
|
|
937
|
+
shadow: "shadow";
|
|
934
938
|
}>>;
|
|
935
939
|
chatId: z.ZodString;
|
|
936
940
|
userId: z.ZodString;
|
|
@@ -1001,6 +1005,7 @@ declare const UpdateTaskTitleResponseSchema: z.ZodObject<{
|
|
|
1001
1005
|
type: z.ZodDefault<z.ZodEnum<{
|
|
1002
1006
|
chat: "chat";
|
|
1003
1007
|
work: "work";
|
|
1008
|
+
shadow: "shadow";
|
|
1004
1009
|
}>>;
|
|
1005
1010
|
chatId: z.ZodString;
|
|
1006
1011
|
userId: z.ZodString;
|
|
@@ -1144,6 +1149,59 @@ declare const ListSubTasksResponseSchema: z.ZodObject<{
|
|
|
1144
1149
|
}, z.core.$strip>>;
|
|
1145
1150
|
}, z.core.$strip>;
|
|
1146
1151
|
type ListSubTasksResponse = z.infer<typeof ListSubTasksResponseSchema>;
|
|
1152
|
+
/**
|
|
1153
|
+
* GET /v1/tasks/recent - Query parameters schema
|
|
1154
|
+
* Lists recent tasks in a chat for agent consumption (lightweight summary)
|
|
1155
|
+
*/
|
|
1156
|
+
declare const ListRecentTasksRequestSchema: z.ZodObject<{
|
|
1157
|
+
chatId: z.ZodString;
|
|
1158
|
+
limit: z.ZodDefault<z.ZodOptional<z.ZodCoercedNumber<unknown>>>;
|
|
1159
|
+
status: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
1160
|
+
all: "all";
|
|
1161
|
+
active: "active";
|
|
1162
|
+
completed: "completed";
|
|
1163
|
+
}>>>;
|
|
1164
|
+
}, z.core.$strip>;
|
|
1165
|
+
type ListRecentTasksRequest = z.infer<typeof ListRecentTasksRequestSchema>;
|
|
1166
|
+
/**
|
|
1167
|
+
* Recent task summary schema (lightweight, for agent review)
|
|
1168
|
+
*/
|
|
1169
|
+
declare const RecentTaskSummarySchema: z.ZodObject<{
|
|
1170
|
+
taskId: z.ZodString;
|
|
1171
|
+
type: z.ZodEnum<{
|
|
1172
|
+
chat: "chat";
|
|
1173
|
+
work: "work";
|
|
1174
|
+
shadow: "shadow";
|
|
1175
|
+
}>;
|
|
1176
|
+
state: z.ZodString;
|
|
1177
|
+
agentId: z.ZodString;
|
|
1178
|
+
title: z.ZodNullable<z.ZodString>;
|
|
1179
|
+
totalDuration: z.ZodNullable<z.ZodNumber>;
|
|
1180
|
+
createdAt: z.ZodString;
|
|
1181
|
+
updatedAt: z.ZodString;
|
|
1182
|
+
}, z.core.$strip>;
|
|
1183
|
+
type RecentTaskSummary = z.infer<typeof RecentTaskSummarySchema>;
|
|
1184
|
+
/**
|
|
1185
|
+
* GET /v1/tasks/recent - Response schema
|
|
1186
|
+
*/
|
|
1187
|
+
declare const ListRecentTasksResponseSchema: z.ZodObject<{
|
|
1188
|
+
tasks: z.ZodArray<z.ZodObject<{
|
|
1189
|
+
taskId: z.ZodString;
|
|
1190
|
+
type: z.ZodEnum<{
|
|
1191
|
+
chat: "chat";
|
|
1192
|
+
work: "work";
|
|
1193
|
+
shadow: "shadow";
|
|
1194
|
+
}>;
|
|
1195
|
+
state: z.ZodString;
|
|
1196
|
+
agentId: z.ZodString;
|
|
1197
|
+
title: z.ZodNullable<z.ZodString>;
|
|
1198
|
+
totalDuration: z.ZodNullable<z.ZodNumber>;
|
|
1199
|
+
createdAt: z.ZodString;
|
|
1200
|
+
updatedAt: z.ZodString;
|
|
1201
|
+
}, z.core.$strip>>;
|
|
1202
|
+
hasMore: z.ZodBoolean;
|
|
1203
|
+
}, z.core.$strip>;
|
|
1204
|
+
type ListRecentTasksResponse = z.infer<typeof ListRecentTasksResponseSchema>;
|
|
1147
1205
|
/**
|
|
1148
1206
|
* GET /v1/tasks/find-by-agent - Query parameters schema
|
|
1149
1207
|
* Finds a task by parentTaskId and agentId
|
|
@@ -1266,6 +1324,8 @@ declare const CreateChatRequestSchema: z.ZodObject<{
|
|
|
1266
1324
|
agent: "agent";
|
|
1267
1325
|
}>;
|
|
1268
1326
|
}, z.core.$strip>>;
|
|
1327
|
+
dataEncryptionKey: z.ZodOptional<z.ZodString>;
|
|
1328
|
+
ownerEncryptedDataKey: z.ZodOptional<z.ZodString>;
|
|
1269
1329
|
}, z.core.$strip>;
|
|
1270
1330
|
type CreateChatRequest = z.infer<typeof CreateChatRequestSchema>;
|
|
1271
1331
|
/**
|
|
@@ -1449,6 +1509,7 @@ declare const ListChatTasksResponseSchema: z.ZodObject<{
|
|
|
1449
1509
|
type: z.ZodDefault<z.ZodEnum<{
|
|
1450
1510
|
chat: "chat";
|
|
1451
1511
|
work: "work";
|
|
1512
|
+
shadow: "shadow";
|
|
1452
1513
|
}>>;
|
|
1453
1514
|
chatId: z.ZodString;
|
|
1454
1515
|
userId: z.ZodString;
|
|
@@ -1544,6 +1605,7 @@ type UpdateChatContextResponse = z.infer<typeof UpdateChatContextResponseSchema>
|
|
|
1544
1605
|
declare const AgentTypeSchema: z.ZodEnum<{
|
|
1545
1606
|
claude: "claude";
|
|
1546
1607
|
codex: "codex";
|
|
1608
|
+
companion: "companion";
|
|
1547
1609
|
}>;
|
|
1548
1610
|
type AgentType = z.infer<typeof AgentTypeSchema>;
|
|
1549
1611
|
/**
|
|
@@ -1618,6 +1680,8 @@ declare const AgentCustomConfigSchema: z.ZodObject<{
|
|
|
1618
1680
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1619
1681
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1620
1682
|
}, z.core.$strip>>>;
|
|
1683
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1684
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1621
1685
|
}, z.core.$strip>;
|
|
1622
1686
|
type AgentCustomConfig = z.infer<typeof AgentCustomConfigSchema>;
|
|
1623
1687
|
/**
|
|
@@ -1631,9 +1695,11 @@ type AgentPermissions = z.infer<typeof AgentPermissionsSchema>;
|
|
|
1631
1695
|
declare const AgentSchema: z.ZodObject<{
|
|
1632
1696
|
id: z.ZodString;
|
|
1633
1697
|
name: z.ZodString;
|
|
1698
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
1634
1699
|
type: z.ZodEnum<{
|
|
1635
1700
|
claude: "claude";
|
|
1636
1701
|
codex: "codex";
|
|
1702
|
+
companion: "companion";
|
|
1637
1703
|
}>;
|
|
1638
1704
|
avatar: z.ZodNullable<z.ZodString>;
|
|
1639
1705
|
userId: z.ZodString;
|
|
@@ -1666,6 +1732,8 @@ declare const AgentSchema: z.ZodObject<{
|
|
|
1666
1732
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1667
1733
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1668
1734
|
}, z.core.$strip>>>;
|
|
1735
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1736
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1669
1737
|
}, z.core.$strip>>;
|
|
1670
1738
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
1671
1739
|
role: z.ZodString;
|
|
@@ -1680,9 +1748,11 @@ declare const ListAgentsResponseSchema: z.ZodObject<{
|
|
|
1680
1748
|
agents: z.ZodArray<z.ZodObject<{
|
|
1681
1749
|
id: z.ZodString;
|
|
1682
1750
|
name: z.ZodString;
|
|
1751
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
1683
1752
|
type: z.ZodEnum<{
|
|
1684
1753
|
claude: "claude";
|
|
1685
1754
|
codex: "codex";
|
|
1755
|
+
companion: "companion";
|
|
1686
1756
|
}>;
|
|
1687
1757
|
avatar: z.ZodNullable<z.ZodString>;
|
|
1688
1758
|
userId: z.ZodString;
|
|
@@ -1715,6 +1785,8 @@ declare const ListAgentsResponseSchema: z.ZodObject<{
|
|
|
1715
1785
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1716
1786
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1717
1787
|
}, z.core.$strip>>>;
|
|
1788
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1789
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1718
1790
|
}, z.core.$strip>>;
|
|
1719
1791
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
1720
1792
|
role: z.ZodString;
|
|
@@ -1729,9 +1801,11 @@ type ListAgentsResponse = z.infer<typeof ListAgentsResponseSchema>;
|
|
|
1729
1801
|
declare const GetAgentResponseSchema: z.ZodObject<{
|
|
1730
1802
|
id: z.ZodString;
|
|
1731
1803
|
name: z.ZodString;
|
|
1804
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
1732
1805
|
type: z.ZodEnum<{
|
|
1733
1806
|
claude: "claude";
|
|
1734
1807
|
codex: "codex";
|
|
1808
|
+
companion: "companion";
|
|
1735
1809
|
}>;
|
|
1736
1810
|
avatar: z.ZodNullable<z.ZodString>;
|
|
1737
1811
|
userId: z.ZodString;
|
|
@@ -1764,6 +1838,8 @@ declare const GetAgentResponseSchema: z.ZodObject<{
|
|
|
1764
1838
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1765
1839
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1766
1840
|
}, z.core.$strip>>>;
|
|
1841
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1842
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1767
1843
|
}, z.core.$strip>>;
|
|
1768
1844
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
1769
1845
|
role: z.ZodString;
|
|
@@ -1779,6 +1855,7 @@ declare const CreateAgentRequestSchema: z.ZodObject<{
|
|
|
1779
1855
|
type: z.ZodEnum<{
|
|
1780
1856
|
claude: "claude";
|
|
1781
1857
|
codex: "codex";
|
|
1858
|
+
companion: "companion";
|
|
1782
1859
|
}>;
|
|
1783
1860
|
avatar: z.ZodOptional<z.ZodString>;
|
|
1784
1861
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -1807,6 +1884,8 @@ declare const CreateAgentRequestSchema: z.ZodObject<{
|
|
|
1807
1884
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1808
1885
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1809
1886
|
}, z.core.$strip>>>;
|
|
1887
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1888
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1810
1889
|
}, z.core.$strip>>>;
|
|
1811
1890
|
isSystem: z.ZodOptional<z.ZodBoolean>;
|
|
1812
1891
|
}, z.core.$strip>;
|
|
@@ -1817,9 +1896,11 @@ type CreateAgentRequest = z.infer<typeof CreateAgentRequestSchema>;
|
|
|
1817
1896
|
declare const CreateAgentResponseSchema: z.ZodObject<{
|
|
1818
1897
|
id: z.ZodString;
|
|
1819
1898
|
name: z.ZodString;
|
|
1899
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
1820
1900
|
type: z.ZodEnum<{
|
|
1821
1901
|
claude: "claude";
|
|
1822
1902
|
codex: "codex";
|
|
1903
|
+
companion: "companion";
|
|
1823
1904
|
}>;
|
|
1824
1905
|
avatar: z.ZodNullable<z.ZodString>;
|
|
1825
1906
|
userId: z.ZodString;
|
|
@@ -1852,6 +1933,8 @@ declare const CreateAgentResponseSchema: z.ZodObject<{
|
|
|
1852
1933
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1853
1934
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1854
1935
|
}, z.core.$strip>>>;
|
|
1936
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1937
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1855
1938
|
}, z.core.$strip>>;
|
|
1856
1939
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
1857
1940
|
role: z.ZodString;
|
|
@@ -1864,9 +1947,11 @@ type CreateAgentResponse = z.infer<typeof CreateAgentResponseSchema>;
|
|
|
1864
1947
|
*/
|
|
1865
1948
|
declare const UpdateAgentRequestSchema: z.ZodObject<{
|
|
1866
1949
|
name: z.ZodOptional<z.ZodString>;
|
|
1950
|
+
displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1867
1951
|
type: z.ZodOptional<z.ZodEnum<{
|
|
1868
1952
|
claude: "claude";
|
|
1869
1953
|
codex: "codex";
|
|
1954
|
+
companion: "companion";
|
|
1870
1955
|
}>>;
|
|
1871
1956
|
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1872
1957
|
description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -1895,6 +1980,8 @@ declare const UpdateAgentRequestSchema: z.ZodObject<{
|
|
|
1895
1980
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1896
1981
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1897
1982
|
}, z.core.$strip>>>;
|
|
1983
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
1984
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1898
1985
|
}, z.core.$strip>>>;
|
|
1899
1986
|
}, z.core.$strip>;
|
|
1900
1987
|
type UpdateAgentRequest = z.infer<typeof UpdateAgentRequestSchema>;
|
|
@@ -1904,9 +1991,11 @@ type UpdateAgentRequest = z.infer<typeof UpdateAgentRequestSchema>;
|
|
|
1904
1991
|
declare const UpdateAgentResponseSchema: z.ZodObject<{
|
|
1905
1992
|
id: z.ZodString;
|
|
1906
1993
|
name: z.ZodString;
|
|
1994
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
1907
1995
|
type: z.ZodEnum<{
|
|
1908
1996
|
claude: "claude";
|
|
1909
1997
|
codex: "codex";
|
|
1998
|
+
companion: "companion";
|
|
1910
1999
|
}>;
|
|
1911
2000
|
avatar: z.ZodNullable<z.ZodString>;
|
|
1912
2001
|
userId: z.ZodString;
|
|
@@ -1939,6 +2028,8 @@ declare const UpdateAgentResponseSchema: z.ZodObject<{
|
|
|
1939
2028
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
1940
2029
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
1941
2030
|
}, z.core.$strip>>>;
|
|
2031
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
2032
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
1942
2033
|
}, z.core.$strip>>;
|
|
1943
2034
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
1944
2035
|
role: z.ZodString;
|
|
@@ -2021,6 +2112,7 @@ declare const CreateDraftAgentRequestSchema: z.ZodObject<{
|
|
|
2021
2112
|
type: z.ZodDefault<z.ZodEnum<{
|
|
2022
2113
|
claude: "claude";
|
|
2023
2114
|
codex: "codex";
|
|
2115
|
+
companion: "companion";
|
|
2024
2116
|
}>>;
|
|
2025
2117
|
avatar: z.ZodOptional<z.ZodString>;
|
|
2026
2118
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -2075,6 +2167,7 @@ declare const DraftAgentSchema: z.ZodObject<{
|
|
|
2075
2167
|
type: z.ZodEnum<{
|
|
2076
2168
|
claude: "claude";
|
|
2077
2169
|
codex: "codex";
|
|
2170
|
+
companion: "companion";
|
|
2078
2171
|
}>;
|
|
2079
2172
|
avatar: z.ZodNullable<z.ZodString>;
|
|
2080
2173
|
userId: z.ZodString;
|
|
@@ -2181,6 +2274,7 @@ declare const UpdateDraftAgentResponseSchema: z.ZodObject<{
|
|
|
2181
2274
|
type: z.ZodEnum<{
|
|
2182
2275
|
claude: "claude";
|
|
2183
2276
|
codex: "codex";
|
|
2277
|
+
companion: "companion";
|
|
2184
2278
|
}>;
|
|
2185
2279
|
avatar: z.ZodNullable<z.ZodString>;
|
|
2186
2280
|
userId: z.ZodString;
|
|
@@ -2239,9 +2333,11 @@ declare const GetUserAgentsResponseSchema: z.ZodObject<{
|
|
|
2239
2333
|
agents: z.ZodArray<z.ZodObject<{
|
|
2240
2334
|
id: z.ZodString;
|
|
2241
2335
|
name: z.ZodString;
|
|
2336
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
2242
2337
|
type: z.ZodEnum<{
|
|
2243
2338
|
claude: "claude";
|
|
2244
2339
|
codex: "codex";
|
|
2340
|
+
companion: "companion";
|
|
2245
2341
|
}>;
|
|
2246
2342
|
avatar: z.ZodNullable<z.ZodString>;
|
|
2247
2343
|
userId: z.ZodString;
|
|
@@ -2274,6 +2370,8 @@ declare const GetUserAgentsResponseSchema: z.ZodObject<{
|
|
|
2274
2370
|
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
2275
2371
|
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
2276
2372
|
}, z.core.$strip>>>;
|
|
2373
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
2374
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
2277
2375
|
}, z.core.$strip>>;
|
|
2278
2376
|
permissions: z.ZodNullable<z.ZodObject<{
|
|
2279
2377
|
role: z.ZodString;
|
|
@@ -2288,6 +2386,7 @@ declare const GetUserAgentsResponseSchema: z.ZodObject<{
|
|
|
2288
2386
|
type: z.ZodEnum<{
|
|
2289
2387
|
claude: "claude";
|
|
2290
2388
|
codex: "codex";
|
|
2389
|
+
companion: "companion";
|
|
2291
2390
|
}>;
|
|
2292
2391
|
avatar: z.ZodNullable<z.ZodString>;
|
|
2293
2392
|
userId: z.ZodString;
|
|
@@ -3387,13 +3486,35 @@ declare const AskUserResponseMessageSchema: z.ZodObject<{
|
|
|
3387
3486
|
}>>;
|
|
3388
3487
|
}, z.core.$strip>;
|
|
3389
3488
|
type AskUserResponseMessage = z.infer<typeof AskUserResponseMessageSchema>;
|
|
3489
|
+
/**
|
|
3490
|
+
* Companion heartbeat message payload (System → Worker)
|
|
3491
|
+
* Sent by the platform scheduler to wake up companion for autonomous work
|
|
3492
|
+
*/
|
|
3493
|
+
interface CompanionHeartbeatMessage {
|
|
3494
|
+
type: 'companion_heartbeat';
|
|
3495
|
+
timestamp: string;
|
|
3496
|
+
}
|
|
3497
|
+
/**
|
|
3498
|
+
* Companion reminder message payload (Shadow → Main)
|
|
3499
|
+
* Sent by the heartbeat task (shadow) to remind the main companion worker.
|
|
3500
|
+
* Invisible to the user — only wakes up the main worker to act.
|
|
3501
|
+
* Keep content concise; use filePath for detailed analysis.
|
|
3502
|
+
*/
|
|
3503
|
+
interface CompanionReminderMessage {
|
|
3504
|
+
type: 'companion_reminder';
|
|
3505
|
+
content: string;
|
|
3506
|
+
filePath?: string;
|
|
3507
|
+
timestamp: string;
|
|
3508
|
+
}
|
|
3390
3509
|
/**
|
|
3391
3510
|
* Union type for task message payload
|
|
3392
3511
|
* - SDKMessage: Normal agent messages
|
|
3393
3512
|
* - AskUserMessage: Worker asking user questions
|
|
3394
3513
|
* - AskUserResponseMessage: User responding to questions
|
|
3514
|
+
* - CompanionHeartbeatMessage: Scheduled heartbeat to wake up companion
|
|
3515
|
+
* - CompanionReminderMessage: Shadow companion reminding main companion
|
|
3395
3516
|
*/
|
|
3396
|
-
type TaskMessagePayload = SDKMessage | AskUserMessage | AskUserResponseMessage;
|
|
3517
|
+
type TaskMessagePayload = SDKMessage | AskUserMessage | AskUserResponseMessage | CompanionHeartbeatMessage | CompanionReminderMessage;
|
|
3397
3518
|
|
|
3398
3519
|
declare const TaskAgentInfoSchema: z.ZodObject<{
|
|
3399
3520
|
id: z.ZodString;
|
|
@@ -3401,6 +3522,7 @@ declare const TaskAgentInfoSchema: z.ZodObject<{
|
|
|
3401
3522
|
type: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3402
3523
|
claude: "claude";
|
|
3403
3524
|
codex: "codex";
|
|
3525
|
+
companion: "companion";
|
|
3404
3526
|
}>>>;
|
|
3405
3527
|
description: z.ZodOptional<z.ZodString>;
|
|
3406
3528
|
}, z.core.$strip>;
|
|
@@ -3414,7 +3536,15 @@ declare function isAskUserMessage(message: TaskMessagePayload): message is AskUs
|
|
|
3414
3536
|
*/
|
|
3415
3537
|
declare function isAskUserResponseMessage(message: TaskMessagePayload): message is AskUserResponseMessage;
|
|
3416
3538
|
/**
|
|
3417
|
-
* Type guard to check if message is
|
|
3539
|
+
* Type guard to check if message is CompanionHeartbeatMessage
|
|
3540
|
+
*/
|
|
3541
|
+
declare function isCompanionHeartbeatMessage(message: TaskMessagePayload): message is CompanionHeartbeatMessage;
|
|
3542
|
+
/**
|
|
3543
|
+
* Type guard to check if message is CompanionReminderMessage
|
|
3544
|
+
*/
|
|
3545
|
+
declare function isCompanionReminderMessage(message: TaskMessagePayload): message is CompanionReminderMessage;
|
|
3546
|
+
/**
|
|
3547
|
+
* Type guard to check if message is SDKMessage (not ask_user related, not companion_heartbeat, not companion_reminder)
|
|
3418
3548
|
*/
|
|
3419
3549
|
declare function isSDKMessage(message: TaskMessagePayload): message is SDKMessage;
|
|
3420
3550
|
/**
|
|
@@ -3585,6 +3715,7 @@ declare const baseTaskSchema: z.ZodObject<{
|
|
|
3585
3715
|
type: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3586
3716
|
claude: "claude";
|
|
3587
3717
|
codex: "codex";
|
|
3718
|
+
companion: "companion";
|
|
3588
3719
|
}>>>;
|
|
3589
3720
|
description: z.ZodOptional<z.ZodString>;
|
|
3590
3721
|
}, z.core.$strip>>>;
|
|
@@ -3596,6 +3727,7 @@ declare const baseTaskSchema: z.ZodObject<{
|
|
|
3596
3727
|
taskType: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3597
3728
|
chat: "chat";
|
|
3598
3729
|
work: "work";
|
|
3730
|
+
shadow: "shadow";
|
|
3599
3731
|
}>>>;
|
|
3600
3732
|
customTitle: z.ZodOptional<z.ZodString>;
|
|
3601
3733
|
}, z.core.$strip>;
|
|
@@ -3634,6 +3766,7 @@ declare const createTaskSchema: z.ZodObject<{
|
|
|
3634
3766
|
type: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3635
3767
|
claude: "claude";
|
|
3636
3768
|
codex: "codex";
|
|
3769
|
+
companion: "companion";
|
|
3637
3770
|
}>>>;
|
|
3638
3771
|
description: z.ZodOptional<z.ZodString>;
|
|
3639
3772
|
}, z.core.$strip>>>;
|
|
@@ -3645,6 +3778,7 @@ declare const createTaskSchema: z.ZodObject<{
|
|
|
3645
3778
|
taskType: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3646
3779
|
chat: "chat";
|
|
3647
3780
|
work: "work";
|
|
3781
|
+
shadow: "shadow";
|
|
3648
3782
|
}>>>;
|
|
3649
3783
|
customTitle: z.ZodOptional<z.ZodString>;
|
|
3650
3784
|
event: z.ZodString;
|
|
@@ -3686,6 +3820,7 @@ declare const resumeTaskSchema: z.ZodObject<{
|
|
|
3686
3820
|
type: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3687
3821
|
claude: "claude";
|
|
3688
3822
|
codex: "codex";
|
|
3823
|
+
companion: "companion";
|
|
3689
3824
|
}>>>;
|
|
3690
3825
|
description: z.ZodOptional<z.ZodString>;
|
|
3691
3826
|
}, z.core.$strip>>>;
|
|
@@ -3697,6 +3832,7 @@ declare const resumeTaskSchema: z.ZodObject<{
|
|
|
3697
3832
|
taskType: z.ZodDefault<z.ZodOptional<z.ZodEnum<{
|
|
3698
3833
|
chat: "chat";
|
|
3699
3834
|
work: "work";
|
|
3835
|
+
shadow: "shadow";
|
|
3700
3836
|
}>>>;
|
|
3701
3837
|
customTitle: z.ZodOptional<z.ZodString>;
|
|
3702
3838
|
agentSessionId: z.ZodString;
|
|
@@ -3831,7 +3967,8 @@ declare const TaskMessageSchema: z.ZodObject<{
|
|
|
3831
3967
|
opCode: z.ZodOptional<z.ZodString>;
|
|
3832
3968
|
groupId: z.ZodOptional<z.ZodString>;
|
|
3833
3969
|
sequence: z.ZodOptional<z.ZodNumber>;
|
|
3834
|
-
message: z.ZodOptional<z.ZodCustom<
|
|
3970
|
+
message: z.ZodOptional<z.ZodCustom<any, any>>;
|
|
3971
|
+
messageType: z.ZodOptional<z.ZodString>;
|
|
3835
3972
|
encryptedMessage: z.ZodOptional<z.ZodString>;
|
|
3836
3973
|
agentId: z.ZodOptional<z.ZodString>;
|
|
3837
3974
|
senderType: z.ZodEnum<{
|
|
@@ -4061,6 +4198,7 @@ declare const SubTaskResultUpdatedEventSchema: z.ZodObject<{
|
|
|
4061
4198
|
result: z.ZodString;
|
|
4062
4199
|
is_error: z.ZodOptional<z.ZodBoolean>;
|
|
4063
4200
|
}, z.core.$strip>;
|
|
4201
|
+
encryptedResultMessage: z.ZodOptional<z.ZodString>;
|
|
4064
4202
|
artifacts: z.ZodOptional<z.ZodObject<{
|
|
4065
4203
|
commitHash: z.ZodString;
|
|
4066
4204
|
stats: z.ZodObject<{
|
|
@@ -4158,11 +4296,20 @@ declare const AssociateRepoEventDataSchema: z.ZodObject<{
|
|
|
4158
4296
|
repo: z.ZodString;
|
|
4159
4297
|
remoteUrl: z.ZodString;
|
|
4160
4298
|
}, z.core.$strip>;
|
|
4299
|
+
declare const UpdateAgentInfoEventSchema: z.ZodObject<{
|
|
4300
|
+
eventId: z.ZodString;
|
|
4301
|
+
taskId: z.ZodString;
|
|
4302
|
+
agentId: z.ZodString;
|
|
4303
|
+
displayName: z.ZodOptional<z.ZodString>;
|
|
4304
|
+
avatar: z.ZodOptional<z.ZodString>;
|
|
4305
|
+
signature: z.ZodOptional<z.ZodString>;
|
|
4306
|
+
}, z.core.$strip>;
|
|
4307
|
+
type UpdateAgentInfoEventData = z.infer<typeof UpdateAgentInfoEventSchema>;
|
|
4161
4308
|
type AssociateRepoEventData = z.infer<typeof AssociateRepoEventDataSchema>;
|
|
4162
4309
|
/**
|
|
4163
4310
|
* System message type
|
|
4164
4311
|
*/
|
|
4165
|
-
type SystemMessageType = "machine-online" | "machine-offline" | "chat-added" | "chat-removed" | "chat-member-added" | "chat-member-removed" | "repo-added" | "repo-removed" | "pr-state-changed" | "draft-agent-added";
|
|
4312
|
+
type SystemMessageType = "machine-online" | "machine-offline" | "chat-added" | "chat-removed" | "chat-member-added" | "chat-member-removed" | "repo-added" | "repo-removed" | "pr-state-changed" | "draft-agent-added" | "agent-updated";
|
|
4166
4313
|
/**
|
|
4167
4314
|
* PR state changed schema
|
|
4168
4315
|
*/
|
|
@@ -4202,6 +4349,7 @@ declare const SystemMessageSchema: z.ZodObject<{
|
|
|
4202
4349
|
"repo-removed": "repo-removed";
|
|
4203
4350
|
"pr-state-changed": "pr-state-changed";
|
|
4204
4351
|
"draft-agent-added": "draft-agent-added";
|
|
4352
|
+
"agent-updated": "agent-updated";
|
|
4205
4353
|
"task-added": "task-added";
|
|
4206
4354
|
}>;
|
|
4207
4355
|
data: z.ZodUnion<readonly [z.ZodObject<{
|
|
@@ -4268,6 +4416,7 @@ declare const SystemMessageSchema: z.ZodObject<{
|
|
|
4268
4416
|
type: z.ZodEnum<{
|
|
4269
4417
|
claude: "claude";
|
|
4270
4418
|
codex: "codex";
|
|
4419
|
+
companion: "companion";
|
|
4271
4420
|
}>;
|
|
4272
4421
|
avatar: z.ZodNullable<z.ZodString>;
|
|
4273
4422
|
userId: z.ZodString;
|
|
@@ -4317,11 +4466,59 @@ declare const SystemMessageSchema: z.ZodObject<{
|
|
|
4317
4466
|
sourceTaskId: z.ZodNullable<z.ZodString>;
|
|
4318
4467
|
createdAt: z.ZodString;
|
|
4319
4468
|
updatedAt: z.ZodString;
|
|
4469
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
4470
|
+
id: z.ZodString;
|
|
4471
|
+
name: z.ZodString;
|
|
4472
|
+
displayName: z.ZodNullable<z.ZodString>;
|
|
4473
|
+
type: z.ZodEnum<{
|
|
4474
|
+
claude: "claude";
|
|
4475
|
+
codex: "codex";
|
|
4476
|
+
companion: "companion";
|
|
4477
|
+
}>;
|
|
4478
|
+
avatar: z.ZodNullable<z.ZodString>;
|
|
4479
|
+
userId: z.ZodString;
|
|
4480
|
+
description: z.ZodNullable<z.ZodString>;
|
|
4481
|
+
signature: z.ZodNullable<z.ZodString>;
|
|
4482
|
+
guildMsg: z.ZodString;
|
|
4483
|
+
placeholderMsg: z.ZodString;
|
|
4484
|
+
developerName: z.ZodString;
|
|
4485
|
+
developerEmail: z.ZodNullable<z.ZodString>;
|
|
4486
|
+
gitRepoId: z.ZodNullable<z.ZodString>;
|
|
4487
|
+
supportLocal: z.ZodBoolean;
|
|
4488
|
+
enable: z.ZodBoolean;
|
|
4489
|
+
config: z.ZodNullable<z.ZodObject<{
|
|
4490
|
+
displayConfig: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
4491
|
+
createPR: z.ZodOptional<z.ZodString>;
|
|
4492
|
+
viewPR: z.ZodOptional<z.ZodString>;
|
|
4493
|
+
mergePR: z.ZodOptional<z.ZodString>;
|
|
4494
|
+
approvePR: z.ZodOptional<z.ZodString>;
|
|
4495
|
+
merged: z.ZodOptional<z.ZodString>;
|
|
4496
|
+
closed: z.ZodOptional<z.ZodString>;
|
|
4497
|
+
recreatePR: z.ZodOptional<z.ZodString>;
|
|
4498
|
+
permissionCanSendMessage: z.ZodOptional<z.ZodString>;
|
|
4499
|
+
permissionCanSendMessageDesc: z.ZodOptional<z.ZodString>;
|
|
4500
|
+
permissionCanCreatePr: z.ZodOptional<z.ZodString>;
|
|
4501
|
+
permissionCanCreatePrDesc: z.ZodOptional<z.ZodString>;
|
|
4502
|
+
permissionCanApprovePr: z.ZodOptional<z.ZodString>;
|
|
4503
|
+
permissionCanApprovePrDesc: z.ZodOptional<z.ZodString>;
|
|
4504
|
+
permissionCanViewPr: z.ZodOptional<z.ZodString>;
|
|
4505
|
+
permissionCanViewPrDesc: z.ZodOptional<z.ZodString>;
|
|
4506
|
+
permissionCanMergePr: z.ZodOptional<z.ZodString>;
|
|
4507
|
+
permissionCanMergePrDesc: z.ZodOptional<z.ZodString>;
|
|
4508
|
+
}, z.core.$strip>>>;
|
|
4509
|
+
machineId: z.ZodOptional<z.ZodString>;
|
|
4510
|
+
heartbeatTaskId: z.ZodOptional<z.ZodString>;
|
|
4511
|
+
}, z.core.$strip>>;
|
|
4512
|
+
permissions: z.ZodNullable<z.ZodObject<{
|
|
4513
|
+
role: z.ZodString;
|
|
4514
|
+
paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4515
|
+
}, z.core.$strip>>;
|
|
4320
4516
|
}, z.core.$strip>, z.ZodObject<{
|
|
4321
4517
|
id: z.ZodString;
|
|
4322
4518
|
type: z.ZodDefault<z.ZodEnum<{
|
|
4323
4519
|
chat: "chat";
|
|
4324
4520
|
work: "work";
|
|
4521
|
+
shadow: "shadow";
|
|
4325
4522
|
}>>;
|
|
4326
4523
|
chatId: z.ZodString;
|
|
4327
4524
|
userId: z.ZodString;
|
|
@@ -4382,6 +4579,7 @@ declare const DaemonGitlabOperationSchema: z.ZodEnum<{
|
|
|
4382
4579
|
createMergeRequest: "createMergeRequest";
|
|
4383
4580
|
getMergeRequest: "getMergeRequest";
|
|
4384
4581
|
listMergeRequests: "listMergeRequests";
|
|
4582
|
+
requestGitlabApi: "requestGitlabApi";
|
|
4385
4583
|
resolveGitAuthContext: "resolveGitAuthContext";
|
|
4386
4584
|
}>;
|
|
4387
4585
|
type DaemonGitlabOperation = z.infer<typeof DaemonGitlabOperationSchema>;
|
|
@@ -4399,6 +4597,7 @@ declare const DaemonGitlabRequestSchema: z.ZodObject<{
|
|
|
4399
4597
|
createMergeRequest: "createMergeRequest";
|
|
4400
4598
|
getMergeRequest: "getMergeRequest";
|
|
4401
4599
|
listMergeRequests: "listMergeRequests";
|
|
4600
|
+
requestGitlabApi: "requestGitlabApi";
|
|
4402
4601
|
resolveGitAuthContext: "resolveGitAuthContext";
|
|
4403
4602
|
}>;
|
|
4404
4603
|
payload: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
@@ -4420,7 +4619,27 @@ declare const DaemonGitlabResponseSchema: z.ZodObject<{
|
|
|
4420
4619
|
executionTimeMs: z.ZodNumber;
|
|
4421
4620
|
}, z.core.$strip>;
|
|
4422
4621
|
type DaemonGitlabResponseEventData = z.infer<typeof DaemonGitlabResponseSchema>;
|
|
4423
|
-
|
|
4622
|
+
declare const CompanionHeartbeatRequestSchema: z.ZodObject<{
|
|
4623
|
+
eventId: z.ZodString;
|
|
4624
|
+
machineId: z.ZodString;
|
|
4625
|
+
agentId: z.ZodString;
|
|
4626
|
+
chatId: z.ZodString;
|
|
4627
|
+
userId: z.ZodString;
|
|
4628
|
+
timestamp: z.ZodString;
|
|
4629
|
+
}, z.core.$strip>;
|
|
4630
|
+
type CompanionHeartbeatRequestData = z.infer<typeof CompanionHeartbeatRequestSchema>;
|
|
4631
|
+
declare const CompanionHeartbeatResponseSchema: z.ZodObject<{
|
|
4632
|
+
eventId: z.ZodString;
|
|
4633
|
+
taskId: z.ZodString;
|
|
4634
|
+
chatId: z.ZodString;
|
|
4635
|
+
}, z.core.$strip>;
|
|
4636
|
+
type CompanionHeartbeatResponseData = z.infer<typeof CompanionHeartbeatResponseSchema>;
|
|
4637
|
+
declare const ResetTaskSessionSchema: z.ZodObject<{
|
|
4638
|
+
eventId: z.ZodString;
|
|
4639
|
+
taskId: z.ZodString;
|
|
4640
|
+
}, z.core.$strip>;
|
|
4641
|
+
type ResetTaskSessionEventData = z.infer<typeof ResetTaskSessionSchema>;
|
|
4642
|
+
type EventData = AppAliveEventData | ApiServerAliveEventData | MachineAliveEventData | ShutdownMachineData | WorkerInitializingEventData | WorkerInitializedEventData | WorkerReadyEventData | WorkerAliveEventData | WorkerExitEventData | WorkerRunningEventData | WorkerStatusRequestEventData | ChatWorkersStatusRequestEventData | ChatWorkersStatusResponseEventData | CreateTaskEventData | ResumeTaskEventData | CancelTaskEventData | StopTaskEventData | TaskMessageEventData | ChangeTaskTitleEventData | TaskStateChangeEventData | UpdateTaskAgentSessionIdEventData | TaskInfoUpdateEventData | MergeRequestEventData | TaskStoppedEventData | SubTaskResultUpdatedEventData | SystemMessageEventData | CreditExhaustedEventData | RtcIceServersRequestEventData | RtcIceServersResponseEventData | MachineRtcRequestEventData | MachineRtcResponseEventData | RtcSignalEventData | WorkspaceFileRequestEventData | WorkspaceFileResponseEventData | UpdateAgentInfoEventData | DaemonGitlabRequestEventData | DaemonGitlabResponseEventData | CompanionHeartbeatRequestData | CompanionHeartbeatResponseData | ResetTaskSessionEventData;
|
|
4424
4643
|
type EventMap = {
|
|
4425
4644
|
"app-alive": AppAliveEventData;
|
|
4426
4645
|
"api-server-alive": ApiServerAliveEventData;
|
|
@@ -4451,6 +4670,7 @@ type EventMap = {
|
|
|
4451
4670
|
"task-stopped": TaskStoppedEventData;
|
|
4452
4671
|
"sub-task-result-updated": SubTaskResultUpdatedEventData;
|
|
4453
4672
|
"associate-repo": AssociateRepoEventData;
|
|
4673
|
+
"update-agent-info": UpdateAgentInfoEventData;
|
|
4454
4674
|
"system-message": SystemMessageEventData;
|
|
4455
4675
|
"credit-exhausted": CreditExhaustedEventData;
|
|
4456
4676
|
"rtc-ice-servers-request": RtcIceServersRequestEventData;
|
|
@@ -4463,6 +4683,9 @@ type EventMap = {
|
|
|
4463
4683
|
"rpc-call": RpcCallEventData;
|
|
4464
4684
|
"daemon-gitlab-request": DaemonGitlabRequestEventData;
|
|
4465
4685
|
"daemon-gitlab-response": DaemonGitlabResponseEventData;
|
|
4686
|
+
"request-companion-heartbeat": CompanionHeartbeatRequestData;
|
|
4687
|
+
"companion-heartbeat-response": CompanionHeartbeatResponseData;
|
|
4688
|
+
"reset-task-session": ResetTaskSessionEventData;
|
|
4466
4689
|
"event-ack": EventAckData;
|
|
4467
4690
|
};
|
|
4468
4691
|
type EventName = keyof EventMap;
|
|
@@ -4470,7 +4693,7 @@ declare const EventSchemaMap: Record<EventName, z.ZodType<any>>;
|
|
|
4470
4693
|
/**
|
|
4471
4694
|
* only sent by worker and which need to send to human in chat room
|
|
4472
4695
|
*/
|
|
4473
|
-
type WorkerTaskEvent = "worker-initializing" | "worker-initialized" | "worker-ready" | "worker-exit" | "worker-running" | "change-task-title" | "update-task-agent-session-id" | "merge-request" | "merge-pr" | "associate-repo";
|
|
4696
|
+
type WorkerTaskEvent = "worker-initializing" | "worker-initialized" | "worker-ready" | "worker-exit" | "worker-running" | "change-task-title" | "update-task-agent-session-id" | "reset-task-session" | "merge-request" | "merge-pr" | "associate-repo" | "update-agent-info";
|
|
4474
4697
|
declare const workerTaskEvents: WorkerTaskEvent[];
|
|
4475
4698
|
|
|
4476
4699
|
type ClientType = 'user' | 'worker' | 'machine';
|
|
@@ -4654,6 +4877,14 @@ interface AgentrixContext {
|
|
|
4654
4877
|
* List direct sub tasks under the current task
|
|
4655
4878
|
*/
|
|
4656
4879
|
listSubTasks(): Promise<SubTaskSummary[]>;
|
|
4880
|
+
/**
|
|
4881
|
+
* List recent tasks in the current chat
|
|
4882
|
+
* Used by companion to review recent task activity
|
|
4883
|
+
*/
|
|
4884
|
+
listTasks(params?: {
|
|
4885
|
+
limit?: number;
|
|
4886
|
+
status?: 'all' | 'active' | 'completed';
|
|
4887
|
+
}): Promise<RecentTaskSummary[]>;
|
|
4657
4888
|
/**
|
|
4658
4889
|
* Upload a file to the agent's storage
|
|
4659
4890
|
*/
|
|
@@ -4885,7 +5116,7 @@ declare class MissingAgentFileError extends AgentError {
|
|
|
4885
5116
|
*/
|
|
4886
5117
|
|
|
4887
5118
|
declare function loadAgentConfig(options: LoadAgentOptions): Promise<AgentConfig>;
|
|
4888
|
-
declare function replacePromptPlaceholders(template: string, cwd: string): string;
|
|
5119
|
+
declare function replacePromptPlaceholders(template: string, cwd: string, extra?: Record<string, string>): string;
|
|
4889
5120
|
|
|
4890
5121
|
/**
|
|
4891
5122
|
* Agent directory structure and configuration validation
|
|
@@ -4926,6 +5157,36 @@ declare function assertAgentExists(agentDir: string, agentId: string): void;
|
|
|
4926
5157
|
*/
|
|
4927
5158
|
declare function discoverPlugins(pluginsDir: string): string[];
|
|
4928
5159
|
|
|
5160
|
+
/**
|
|
5161
|
+
* Companion agent types
|
|
5162
|
+
* Types for the self-evolving companion agent system
|
|
5163
|
+
*/
|
|
5164
|
+
|
|
5165
|
+
declare const CompanionWorkspaceFileSchema: z.ZodObject<{
|
|
5166
|
+
name: z.ZodString;
|
|
5167
|
+
path: z.ZodString;
|
|
5168
|
+
size: z.ZodNumber;
|
|
5169
|
+
modifiedAt: z.ZodNumber;
|
|
5170
|
+
isDirectory: z.ZodBoolean;
|
|
5171
|
+
}, z.core.$strip>;
|
|
5172
|
+
type CompanionWorkspaceFile = z.infer<typeof CompanionWorkspaceFileSchema>;
|
|
5173
|
+
declare const RegisterCompanionRequestSchema: z.ZodObject<{
|
|
5174
|
+
machineId: z.ZodString;
|
|
5175
|
+
}, z.core.$strip>;
|
|
5176
|
+
type RegisterCompanionRequest = z.infer<typeof RegisterCompanionRequestSchema>;
|
|
5177
|
+
declare const RegisterCompanionResponseSchema: z.ZodObject<{
|
|
5178
|
+
agentId: z.ZodString;
|
|
5179
|
+
userId: z.ZodString;
|
|
5180
|
+
chatId: z.ZodString;
|
|
5181
|
+
created: z.ZodBoolean;
|
|
5182
|
+
}, z.core.$strip>;
|
|
5183
|
+
type RegisterCompanionResponse = z.infer<typeof RegisterCompanionResponseSchema>;
|
|
5184
|
+
declare const CompanionEnsureResponseSchema: z.ZodObject<{
|
|
5185
|
+
agentDir: z.ZodString;
|
|
5186
|
+
workspaceDir: z.ZodString;
|
|
5187
|
+
}, z.core.$strip>;
|
|
5188
|
+
type CompanionEnsureResponse = z.infer<typeof CompanionEnsureResponseSchema>;
|
|
5189
|
+
|
|
4929
5190
|
declare function encodeBase64(buffer: Uint8Array, variant?: 'base64' | 'base64url'): string;
|
|
4930
5191
|
declare function encodeBase64Url(buffer: Uint8Array): string;
|
|
4931
5192
|
declare function decodeBase64(base64: string, variant?: 'base64' | 'base64url'): Uint8Array;
|
|
@@ -5116,5 +5377,5 @@ declare const RELEVANT_DEPENDENCIES: readonly ["react", "react-dom", "vue", "vit
|
|
|
5116
5377
|
*/
|
|
5117
5378
|
declare function detectPreview(fs: FileSystemAdapter): Promise<PreviewMetadata | null>;
|
|
5118
5379
|
|
|
5119
|
-
export { ActiveAgentSchema, AddChatMemberRequestSchema, AddChatMemberResponseSchema, AgentConfigValidationError, AgentCustomConfigSchema, AgentError, AgentLoadError, AgentMetadataSchema, AgentNotFoundError, AgentPermissionsSchema, AgentSchema, AgentTypeSchema, ApiErrorSchema, ApiServerAliveEventSchema, AppAliveEventSchema, ApprovalStatusResponseSchema, ApprovePrRequestSchema, ApprovePrResponseSchema, ArchiveTaskRequestSchema, ArchiveTaskResponseSchema, AskUserMessageSchema, AskUserOptionSchema, AskUserQuestionSchema, AskUserResponseMessageSchema, AskUserResponseReasonSchema, AskUserResponseStatusSchema, AssociateRepoEventDataSchema, BillingStatsResponseSchema, BranchSchema, CONFIG_FILES, CancelTaskRequestSchema, CancelTaskResponseSchema, ChangeTaskTitleEventSchema, ChargeTransactionSchema, ChatMemberInputSchema, ChatMemberSchema, ChatSchema, ChatTypeSchema, ChatWithMembersSchema, ChatWorkersStatusRequestSchema, ChatWorkersStatusResponseSchema, ClaudeConfigSchema, CloudJoinApprovalRequestSchema, CloudJoinRequestSchema, CloudJoinResultQuerySchema, CloudJoinStatusQuerySchema, CloudMachineSchema, CloudSchema, ConfirmUploadRequestSchema, ConfirmUploadResponseSchema, ConsumeTransactionSchema, CreateAgentRequestSchema, CreateAgentResponseSchema, CreateChatRequestSchema, CreateChatResponseSchema, CreateCloudRequestSchema, CreateCloudResponseSchema, CreateDraftAgentRequestSchema, CreateMergeRequestResponseSchema, CreateMergeRequestSchema, CreateOAuthServerRequestSchema, CreateOAuthServerResponseSchema, CreateTaskShareResponseSchema, CreateTaskShareSchema, CreditExhaustedEventSchema, CreditsPackageSchema, DaemonGitlabOperationSchema, DaemonGitlabRequestSchema, DaemonGitlabResponseSchema, DateSchema, DeleteAgentResponseSchema, DeleteOAuthServerResponseSchema, DeployAgentCompleteEventSchema, DeployAgentEventSchema, DisplayConfigKeysSchema, DisplayConfigSchema, DraftAgentConfigSchema, DraftAgentSchema, ENTRY_FILE_PATTERNS, EnvironmentVariableSchema, EventAckSchema, EventSchemaMap, FRAMEWORK_TYPES, FileItemSchema, FileStatsSchema, FileVisibilitySchema, FillEventsRequestSchema, FindTaskByAgentRequestSchema, FindTaskByAgentResponseSchema, FrameworkNotSupportedError, GetAgentResponseSchema, GetChatResponseSchema, GetEnvironmentVariablesResponseSchema, GetGitServerResponseSchema, GetGitUrlQuerySchema, GetGitUrlResponseSchema, GetInstallUrlResponseSchema, GetOAuthServerResponseSchema, GetRepositoryResponseSchema, GetTaskSessionResponseSchema, GetUploadUrlsRequestSchema, GetUploadUrlsResponseSchema, GetUserAgentsResponseSchema, GitHubIssueListItemSchema, GitHubIssueSchema, GitServerSchema, IGNORED_DIRECTORIES, IdSchema, ListAgentsResponseSchema, ListBranchesResponseSchema, ListChatMembersResponseSchema, ListChatTasksResponseSchema, ListChatsQuerySchema, ListChatsResponseSchema, ListFilesQuerySchema, ListFilesResponseSchema, ListGitServersResponseSchema, ListIssuesQuerySchema, ListIssuesResponseSchema, ListMachinesResponseSchema, ListOAuthServersPublicResponseSchema, ListOAuthServersQuerySchema, ListOAuthServersResponseSchema, ListPackagesQuerySchema, ListPackagesResponseSchema, ListRepositoriesResponseSchema, ListSubTasksRequestSchema, ListSubTasksResponseSchema, ListTasksRequestSchema, ListTasksResponseSchema, ListTransactionsQuerySchema, ListTransactionsResponseSchema, LocalMachineSchema, LogoutResponseSchema, MachineAliveEventSchema, MachineApprovalRequestSchema, MachineApprovalStatusQuerySchema, MachineAuthAuthorizedResponseSchema, MachineAuthRequestSchema, MachineAuthResultQuerySchema, MachineRtcRequestSchema, MachineRtcResponseSchema, MergePullRequestEventSchema, MergeRequestEventSchema, MissingAgentFileError, OAuthAccountInfoSchema, OAuthBindCallbackResponseSchema, OAuthBindQuerySchema, OAuthBindResponseSchema, OAuthCallbackQuerySchema, OAuthCallbackResponseSchema, OAuthLoginQuerySchema, OAuthServerPublicSchema, OAuthServerSchema, OAuthUnbindResponseSchema, PaginatedResponseSchema, PermissionResponseRequestSchema, PermissionResponseResponseSchema, PreviewMetadataSchema, PreviewMethodSchema, PreviewProjectTypeSchema, ProjectDirectoryResponseSchema, ProjectEntrySchema, PublishDraftAgentRequestSchema, PublishDraftAgentResponseSchema, QueryEventsRequestSchema, RELEVANT_DEPENDENCIES, RTC_CHUNK_HEADER_SIZE, RechargeResponseSchema, RemoveChatMemberRequestSchema, RepositorySchema, ResetSecretRequestSchema, ResetSecretResponseSchema, ResumeTaskRequestSchema, ResumeTaskResponseSchema, RpcCallEventSchema, RpcResponseSchema, RtcChunkFlags, RtcIceServerSchema, RtcIceServersRequestSchema, RtcIceServersResponseSchema, RtcSignalSchema, STATIC_FILE_EXTENSIONS, SendTaskMessageRequestSchema, SendTaskMessageResponseSchema, SenderTypeSchema, SetEnvironmentVariablesRequestSchema, ShareAuthQuerySchema, ShareAuthResponseSchema, ShowModalEventDataSchema, ShowModalRequestSchema, ShowModalResponseSchema, ShutdownMachineSchema, SignatureAuthRequestSchema, SignatureAuthResponseSchema, SimpleSuccessSchema, StartTaskRequestSchema, StartTaskResponseSchema, StatsQuerySchema, StopTaskRequestSchema, StopTaskResponseSchema, StopTaskSchema, SubTaskResultUpdatedEventSchema, SubTaskSummarySchema, SyncCloudMachineResponseSchema, SyncLocalMachineResponseSchema, SyncMachineRequestSchema, SystemMessageSchema, TaskAgentInfoSchema, TaskArtifactsStatsSchema, TaskArtifactsSummarySchema, TaskInfoUpdateEventDataSchema, TaskItemSchema, TaskMessageSchema, TaskSharePermissionsSchema, TaskStateChangeEventSchema, TaskStoppedEventSchema, TaskTodoSchema, TaskTransactionsResponseSchema, ToggleOAuthServerRequestSchema, ToggleOAuthServerResponseSchema, TransactionSchema, UnarchiveTaskRequestSchema, UnarchiveTaskResponseSchema, UpdateAgentRequestSchema, UpdateAgentResponseSchema, UpdateChatContextRequestSchema, UpdateChatContextResponseSchema, UpdateDraftAgentRequestSchema, UpdateDraftAgentResponseSchema, UpdateOAuthServerRequestSchema, UpdateOAuthServerResponseSchema, UpdateTaskAgentSessionIdEventSchema, UpdateTaskTitleRequestSchema, UpdateTaskTitleResponseSchema, UpdateUserProfileRequestSchema, UpdateUserProfileResponseSchema, UploadUrlResultSchema, UserBalanceResponseSchema, UserBasicInfoSchema, UserProfileResponseSchema, UserWithOAuthAccountsSchema, WorkerAliveEventSchema, WorkerExitSchema, WorkerInitializedSchema, WorkerInitializingSchema, WorkerReadySchema, WorkerRunningSchema, WorkerStatusRequestSchema, WorkerStatusValueSchema, WorkspaceFileRequestSchema, WorkspaceFileResponseSchema, assertAgentExists, assertFileExists, baseTaskSchema, buildRtcChunkFrame, cancelTaskRequestSchema, cancelTaskSchema, createEventId, createKeyPair, createKeyPairWithUit8Array, createMergeRequestSchema, createTaskSchema, decodeBase64, decodeRtcChunkHeader, decryptAES, decryptFileContent, decryptMachineEncryptionKey, decryptSdkMessage, decryptWithEphemeralKey, detectPreview, discoverPlugins, encodeBase64, encodeBase64Url, encodeRtcChunkHeader, encryptAES, encryptFileContent, encryptMachineEncryptionKey, encryptSdkMessage, encryptWithEphemeralKey, generateAESKey, generateAESKeyBase64, getAgentContext, getRandomBytes, isAskUserMessage, isAskUserResponseMessage, isSDKMessage, isSDKUserMessage, loadAgentConfig, machineAuth, permissionResponseRequestSchema, replacePromptPlaceholders, resumeTaskRequestSchema, resumeTaskSchema, setAgentContext, splitRtcChunkFrame, startTaskSchema, stopTaskRequestSchema, userAuth, validateAgentDirectory, validateFrameworkDirectory, workerAuth, workerTaskEvents };
|
|
5120
|
-
export type { ActiveAgent, AddChatMemberRequest, AddChatMemberResponse, Agent, AgentConfig, AgentContext, AgentCustomConfig, AgentMetadata, AgentPermissions, AgentType, AgentrixContext, ApiError, ApiServerAliveEventData, AppAliveEventData, ApprovalStatusResponse, ApprovePrRequest, ApprovePrResponse, ArchiveTaskRequest, ArchiveTaskResponse, AskUserMessage, AskUserOption, AskUserQuestion, AskUserResponseMessage, AskUserResponseReason, AskUserResponseStatus, AssociateRepoEventData, AuthPayload, BillingStatsResponse, Branch, CancelTaskEventData, CancelTaskRequest, CancelTaskResponse, ChangeTaskTitleEventData, ChargeTransaction, Chat, ChatMember, ChatMemberInput, ChatType, ChatWithMembers, ChatWorkersStatusRequestEventData, ChatWorkersStatusResponseEventData, ClaudeAgentConfig, ClientType, Cloud, CloudJoinApprovalRequest, CloudJoinRequest, CloudJoinResultQuery, CloudJoinStatusQuery, CloudMachine, ConfirmUploadRequest, ConfirmUploadResponse, ConsumeTransaction, CreateAgentRequest, CreateAgentResponse, CreateChatRequest, CreateChatResponse, CreateCloudRequest, CreateCloudResponse, CreateDraftAgentRequest, CreateMergeRequestRequest, CreateMergeRequestResponse, CreateOAuthServerRequest, CreateOAuthServerResponse, CreateTaskEventData, CreateTaskShareRequest, CreateTaskShareResponse, CreditExhaustedEventData, CreditsPackage, DaemonGitlabOperation, DaemonGitlabRequestEventData, DaemonGitlabResponseEventData, DeleteAgentResponse, DeleteOAuthServerResponse, DeployAgentCompleteEventData, DeployAgentEventData, DisplayConfig, DisplayConfigKeys, DraftAgent, DraftAgentConfig, EnvironmentVariable, EventAckData, EventData, EventMap, EventName, FileItem, FileStats, FileSystemAdapter, FileVisibility, FillEventsRequest, FillEventsResponse, FindTaskByAgentRequest, FindTaskByAgentResponse, FrameworkType, GetAgentResponse, GetChatResponse, GetEnvironmentVariablesResponse, GetGitServerResponse, GetGitUrlQuery, GetGitUrlResponse, GetInstallUrlResponse, GetOAuthServerResponse, GetRepositoryResponse, GetTaskSessionResponse, GetUploadUrlsRequest, GetUploadUrlsResponse, GetUserAgentsResponse, GitHubIssue, GitHubIssueListItem, GitServer, HookFactory, ListAgentsResponse, ListBranchesResponse, ListChatMembersResponse, ListChatTasksResponse, ListChatsQuery, ListChatsResponse, ListFilesQuery, ListFilesResponse, ListGitServersResponse, ListIssuesQuery, ListIssuesResponse, ListMachinesResponse, ListOAuthServersPublicResponse, ListOAuthServersQuery, ListOAuthServersResponse, ListPackagesQuery, ListPackagesResponse, ListRepositoriesResponse, ListSubTasksRequest, ListSubTasksResponse, ListTasksRequest, ListTasksResponse, ListTransactionsQuery, ListTransactionsResponse, LoadAgentOptions, LocalMachine, LogoutResponse, MachineAliveEventData, MachineApprovalRequest, MachineApprovalStatusQuery, MachineAuthAuthorizedResponse, MachineAuthRequest, MachineAuthResultQuery, MachineEncryptionKey, MachineRtcRequestEventData, MachineRtcResponseEventData, MergePullRequestAck, MergePullRequestEventData, MergeRequestEventData, OAuthAccountInfo, OAuthBindCallbackResponse, OAuthBindQuery, OAuthBindResponse, OAuthCallbackQuery, OAuthCallbackResponse, OAuthLoginQuery, OAuthServer, OAuthServerPublic, OAuthUnbindResponse, PermissionResponseRequest, PermissionResponseResponse, PrStateChangedData, PreviewMetadata, PreviewMethod, PreviewProjectType, ProjectDirectoryResponse, ProjectEntry, PublishDraftAgentRequest, PublishDraftAgentResponse, QueryEventsRequest, QueryEventsResponse, RechargeResponse, RemoveChatMemberRequest, Repository, RepositoryInitHookInput, ResetSecretRequest, ResetSecretResponse, ResumeTaskEventData, ResumeTaskRequest, ResumeTaskResponse, RpcCallEventData, RpcResponseData, RtcChunkFrame, RtcChunkHeader, RtcControlChannel, RtcControlMessage, RtcIceServer, RtcIceServersRequestEventData, RtcIceServersResponseEventData, RtcSignalEventData, SendMessageTarget, SendTaskMessageRequest, SendTaskMessageResponse, SenderType, SetEnvironmentVariablesRequest, ShareAuthQuery, ShareAuthResponse, ShowModalEventData, ShowModalRequest, ShowModalResponse, ShutdownMachineData, SignatureAuthRequest, SignatureAuthResponse, SimpleSuccess, StartTaskRequest, StartTaskResponse, StatsQuery, StopTaskEventData, StopTaskRequest, StopTaskResponse, SubTaskResultUpdatedEventData, SubTaskSummary, SyncCloudMachineResponse, SyncLocalMachineResponse, SyncMachineRequest, SystemMessageEventData, SystemMessageType, TaskAgentInfo, TaskArtifactsStats, TaskArtifactsSummary, TaskEvent, TaskInfoUpdateEventData, TaskItem, TaskMessageEventData, TaskMessagePayload, TaskSharePermissions, TaskState, TaskStateChangeEventData, TaskStoppedEventData, TaskTodo, TaskTransactionsResponse, ToggleOAuthServerRequest, ToggleOAuthServerResponse, Transaction, UnarchiveTaskRequest, UnarchiveTaskResponse, UpdateAgentRequest, UpdateAgentResponse, UpdateChatContextRequest, UpdateChatContextResponse, UpdateDraftAgentRequest, UpdateDraftAgentResponse, UpdateOAuthServerRequest, UpdateOAuthServerResponse, UpdateTaskAgentSessionIdEventData, UpdateTaskTitleRequest, UpdateTaskTitleResponse, UpdateUserProfileRequest, UpdateUserProfileResponse, UploadUrlResult, UserBalanceResponse, UserBasicInfo, UserProfileResponse, UserWithOAuthAccounts, ValidationResult, WorkerAliveEventData, WorkerExitEventData, WorkerInitializedEventData, WorkerInitializingEventData, WorkerReadyEventData, WorkerRunningEventData, WorkerStatusRequestEventData, WorkerStatusValue, WorkerTaskEvent, WorkspaceFileRequestEventData, WorkspaceFileResponseEventData };
|
|
5380
|
+
export { ActiveAgentSchema, AddChatMemberRequestSchema, AddChatMemberResponseSchema, AgentConfigValidationError, AgentCustomConfigSchema, AgentError, AgentLoadError, AgentMetadataSchema, AgentNotFoundError, AgentPermissionsSchema, AgentSchema, AgentTypeSchema, ApiErrorSchema, ApiServerAliveEventSchema, AppAliveEventSchema, ApprovalStatusResponseSchema, ApprovePrRequestSchema, ApprovePrResponseSchema, ArchiveTaskRequestSchema, ArchiveTaskResponseSchema, AskUserMessageSchema, AskUserOptionSchema, AskUserQuestionSchema, AskUserResponseMessageSchema, AskUserResponseReasonSchema, AskUserResponseStatusSchema, AssociateRepoEventDataSchema, BillingStatsResponseSchema, BranchSchema, CONFIG_FILES, CancelTaskRequestSchema, CancelTaskResponseSchema, ChangeTaskTitleEventSchema, ChargeTransactionSchema, ChatMemberInputSchema, ChatMemberSchema, ChatSchema, ChatTypeSchema, ChatWithMembersSchema, ChatWorkersStatusRequestSchema, ChatWorkersStatusResponseSchema, ClaudeConfigSchema, CloudJoinApprovalRequestSchema, CloudJoinRequestSchema, CloudJoinResultQuerySchema, CloudJoinStatusQuerySchema, CloudMachineSchema, CloudSchema, CompanionEnsureResponseSchema, CompanionHeartbeatRequestSchema, CompanionHeartbeatResponseSchema, CompanionWorkspaceFileSchema, ConfirmUploadRequestSchema, ConfirmUploadResponseSchema, ConsumeTransactionSchema, CreateAgentRequestSchema, CreateAgentResponseSchema, CreateChatRequestSchema, CreateChatResponseSchema, CreateCloudRequestSchema, CreateCloudResponseSchema, CreateDraftAgentRequestSchema, CreateMergeRequestResponseSchema, CreateMergeRequestSchema, CreateOAuthServerRequestSchema, CreateOAuthServerResponseSchema, CreateTaskShareResponseSchema, CreateTaskShareSchema, CreditExhaustedEventSchema, CreditsPackageSchema, DaemonGitlabOperationSchema, DaemonGitlabRequestSchema, DaemonGitlabResponseSchema, DateSchema, DeleteAgentResponseSchema, DeleteOAuthServerResponseSchema, DeployAgentCompleteEventSchema, DeployAgentEventSchema, DisplayConfigKeysSchema, DisplayConfigSchema, DraftAgentConfigSchema, DraftAgentSchema, ENTRY_FILE_PATTERNS, EnvironmentVariableSchema, EventAckSchema, EventSchemaMap, FRAMEWORK_TYPES, FileItemSchema, FileStatsSchema, FileVisibilitySchema, FillEventsRequestSchema, FindTaskByAgentRequestSchema, FindTaskByAgentResponseSchema, FrameworkNotSupportedError, GetAgentResponseSchema, GetChatResponseSchema, GetEnvironmentVariablesResponseSchema, GetGitServerResponseSchema, GetGitUrlQuerySchema, GetGitUrlResponseSchema, GetInstallUrlResponseSchema, GetOAuthServerResponseSchema, GetRepositoryResponseSchema, GetTaskSessionResponseSchema, GetUploadUrlsRequestSchema, GetUploadUrlsResponseSchema, GetUserAgentsResponseSchema, GitHubIssueListItemSchema, GitHubIssueSchema, GitServerSchema, IGNORED_DIRECTORIES, IdSchema, ListAgentsResponseSchema, ListBranchesResponseSchema, ListChatMembersResponseSchema, ListChatTasksResponseSchema, ListChatsQuerySchema, ListChatsResponseSchema, ListFilesQuerySchema, ListFilesResponseSchema, ListGitServersResponseSchema, ListIssuesQuerySchema, ListIssuesResponseSchema, ListMachinesResponseSchema, ListOAuthServersPublicResponseSchema, ListOAuthServersQuerySchema, ListOAuthServersResponseSchema, ListPackagesQuerySchema, ListPackagesResponseSchema, ListRecentTasksRequestSchema, ListRecentTasksResponseSchema, ListRepositoriesResponseSchema, ListSubTasksRequestSchema, ListSubTasksResponseSchema, ListTasksRequestSchema, ListTasksResponseSchema, ListTransactionsQuerySchema, ListTransactionsResponseSchema, LocalMachineSchema, LogoutResponseSchema, MachineAliveEventSchema, MachineApprovalRequestSchema, MachineApprovalStatusQuerySchema, MachineAuthAuthorizedResponseSchema, MachineAuthRequestSchema, MachineAuthResultQuerySchema, MachineRtcRequestSchema, MachineRtcResponseSchema, MergePullRequestEventSchema, MergeRequestEventSchema, MissingAgentFileError, OAuthAccountInfoSchema, OAuthBindCallbackResponseSchema, OAuthBindQuerySchema, OAuthBindResponseSchema, OAuthCallbackQuerySchema, OAuthCallbackResponseSchema, OAuthLoginQuerySchema, OAuthServerPublicSchema, OAuthServerSchema, OAuthUnbindResponseSchema, PaginatedResponseSchema, PermissionResponseRequestSchema, PermissionResponseResponseSchema, PreviewMetadataSchema, PreviewMethodSchema, PreviewProjectTypeSchema, ProjectDirectoryResponseSchema, ProjectEntrySchema, PublishDraftAgentRequestSchema, PublishDraftAgentResponseSchema, QueryEventsRequestSchema, RELEVANT_DEPENDENCIES, RTC_CHUNK_HEADER_SIZE, RecentTaskSummarySchema, RechargeResponseSchema, RegisterCompanionRequestSchema, RegisterCompanionResponseSchema, RemoveChatMemberRequestSchema, RepositorySchema, ResetSecretRequestSchema, ResetSecretResponseSchema, ResetTaskSessionSchema, ResumeTaskRequestSchema, ResumeTaskResponseSchema, RpcCallEventSchema, RpcResponseSchema, RtcChunkFlags, RtcIceServerSchema, RtcIceServersRequestSchema, RtcIceServersResponseSchema, RtcSignalSchema, STATIC_FILE_EXTENSIONS, SendTaskMessageRequestSchema, SendTaskMessageResponseSchema, SenderTypeSchema, SetEnvironmentVariablesRequestSchema, ShareAuthQuerySchema, ShareAuthResponseSchema, ShowModalEventDataSchema, ShowModalRequestSchema, ShowModalResponseSchema, ShutdownMachineSchema, SignatureAuthRequestSchema, SignatureAuthResponseSchema, SimpleSuccessSchema, StartTaskRequestSchema, StartTaskResponseSchema, StatsQuerySchema, StopTaskRequestSchema, StopTaskResponseSchema, StopTaskSchema, SubTaskResultUpdatedEventSchema, SubTaskSummarySchema, SyncCloudMachineResponseSchema, SyncLocalMachineResponseSchema, SyncMachineRequestSchema, SystemMessageSchema, TaskAgentInfoSchema, TaskArtifactsStatsSchema, TaskArtifactsSummarySchema, TaskInfoUpdateEventDataSchema, TaskItemSchema, TaskMessageSchema, TaskSharePermissionsSchema, TaskStateChangeEventSchema, TaskStoppedEventSchema, TaskTodoSchema, TaskTransactionsResponseSchema, ToggleOAuthServerRequestSchema, ToggleOAuthServerResponseSchema, TransactionSchema, UnarchiveTaskRequestSchema, UnarchiveTaskResponseSchema, UpdateAgentInfoEventSchema, UpdateAgentRequestSchema, UpdateAgentResponseSchema, UpdateChatContextRequestSchema, UpdateChatContextResponseSchema, UpdateDraftAgentRequestSchema, UpdateDraftAgentResponseSchema, UpdateOAuthServerRequestSchema, UpdateOAuthServerResponseSchema, UpdateTaskAgentSessionIdEventSchema, UpdateTaskTitleRequestSchema, UpdateTaskTitleResponseSchema, UpdateUserProfileRequestSchema, UpdateUserProfileResponseSchema, UploadUrlResultSchema, UserBalanceResponseSchema, UserBasicInfoSchema, UserProfileResponseSchema, UserWithOAuthAccountsSchema, WorkerAliveEventSchema, WorkerExitSchema, WorkerInitializedSchema, WorkerInitializingSchema, WorkerReadySchema, WorkerRunningSchema, WorkerStatusRequestSchema, WorkerStatusValueSchema, WorkspaceFileRequestSchema, WorkspaceFileResponseSchema, assertAgentExists, assertFileExists, baseTaskSchema, buildRtcChunkFrame, cancelTaskRequestSchema, cancelTaskSchema, createEventId, createKeyPair, createKeyPairWithUit8Array, createMergeRequestSchema, createTaskSchema, decodeBase64, decodeRtcChunkHeader, decryptAES, decryptFileContent, decryptMachineEncryptionKey, decryptSdkMessage, decryptWithEphemeralKey, detectPreview, discoverPlugins, encodeBase64, encodeBase64Url, encodeRtcChunkHeader, encryptAES, encryptFileContent, encryptMachineEncryptionKey, encryptSdkMessage, encryptWithEphemeralKey, generateAESKey, generateAESKeyBase64, getAgentContext, getRandomBytes, isAskUserMessage, isAskUserResponseMessage, isCompanionHeartbeatMessage, isCompanionReminderMessage, isSDKMessage, isSDKUserMessage, loadAgentConfig, machineAuth, permissionResponseRequestSchema, replacePromptPlaceholders, resumeTaskRequestSchema, resumeTaskSchema, setAgentContext, splitRtcChunkFrame, startTaskSchema, stopTaskRequestSchema, userAuth, validateAgentDirectory, validateFrameworkDirectory, workerAuth, workerTaskEvents };
|
|
5381
|
+
export type { ActiveAgent, AddChatMemberRequest, AddChatMemberResponse, Agent, AgentConfig, AgentContext, AgentCustomConfig, AgentMetadata, AgentPermissions, AgentType, AgentrixContext, ApiError, ApiServerAliveEventData, AppAliveEventData, ApprovalStatusResponse, ApprovePrRequest, ApprovePrResponse, ArchiveTaskRequest, ArchiveTaskResponse, AskUserMessage, AskUserOption, AskUserQuestion, AskUserResponseMessage, AskUserResponseReason, AskUserResponseStatus, AssociateRepoEventData, AuthPayload, BillingStatsResponse, Branch, CancelTaskEventData, CancelTaskRequest, CancelTaskResponse, ChangeTaskTitleEventData, ChargeTransaction, Chat, ChatMember, ChatMemberInput, ChatType, ChatWithMembers, ChatWorkersStatusRequestEventData, ChatWorkersStatusResponseEventData, ClaudeAgentConfig, ClientType, Cloud, CloudJoinApprovalRequest, CloudJoinRequest, CloudJoinResultQuery, CloudJoinStatusQuery, CloudMachine, CompanionEnsureResponse, CompanionHeartbeatMessage, CompanionHeartbeatRequestData, CompanionHeartbeatResponseData, CompanionReminderMessage, CompanionWorkspaceFile, ConfirmUploadRequest, ConfirmUploadResponse, ConsumeTransaction, CreateAgentRequest, CreateAgentResponse, CreateChatRequest, CreateChatResponse, CreateCloudRequest, CreateCloudResponse, CreateDraftAgentRequest, CreateMergeRequestRequest, CreateMergeRequestResponse, CreateOAuthServerRequest, CreateOAuthServerResponse, CreateTaskEventData, CreateTaskShareRequest, CreateTaskShareResponse, CreditExhaustedEventData, CreditsPackage, DaemonGitlabOperation, DaemonGitlabRequestEventData, DaemonGitlabResponseEventData, DeleteAgentResponse, DeleteOAuthServerResponse, DeployAgentCompleteEventData, DeployAgentEventData, DisplayConfig, DisplayConfigKeys, DraftAgent, DraftAgentConfig, EnvironmentVariable, EventAckData, EventData, EventMap, EventName, FileItem, FileStats, FileSystemAdapter, FileVisibility, FillEventsRequest, FillEventsResponse, FindTaskByAgentRequest, FindTaskByAgentResponse, FrameworkType, GetAgentResponse, GetChatResponse, GetEnvironmentVariablesResponse, GetGitServerResponse, GetGitUrlQuery, GetGitUrlResponse, GetInstallUrlResponse, GetOAuthServerResponse, GetRepositoryResponse, GetTaskSessionResponse, GetUploadUrlsRequest, GetUploadUrlsResponse, GetUserAgentsResponse, GitHubIssue, GitHubIssueListItem, GitServer, HookFactory, ListAgentsResponse, ListBranchesResponse, ListChatMembersResponse, ListChatTasksResponse, ListChatsQuery, ListChatsResponse, ListFilesQuery, ListFilesResponse, ListGitServersResponse, ListIssuesQuery, ListIssuesResponse, ListMachinesResponse, ListOAuthServersPublicResponse, ListOAuthServersQuery, ListOAuthServersResponse, ListPackagesQuery, ListPackagesResponse, ListRecentTasksRequest, ListRecentTasksResponse, ListRepositoriesResponse, ListSubTasksRequest, ListSubTasksResponse, ListTasksRequest, ListTasksResponse, ListTransactionsQuery, ListTransactionsResponse, LoadAgentOptions, LocalMachine, LogoutResponse, MachineAliveEventData, MachineApprovalRequest, MachineApprovalStatusQuery, MachineAuthAuthorizedResponse, MachineAuthRequest, MachineAuthResultQuery, MachineEncryptionKey, MachineRtcRequestEventData, MachineRtcResponseEventData, MergePullRequestAck, MergePullRequestEventData, MergeRequestEventData, OAuthAccountInfo, OAuthBindCallbackResponse, OAuthBindQuery, OAuthBindResponse, OAuthCallbackQuery, OAuthCallbackResponse, OAuthLoginQuery, OAuthServer, OAuthServerPublic, OAuthUnbindResponse, PermissionResponseRequest, PermissionResponseResponse, PrStateChangedData, PreviewMetadata, PreviewMethod, PreviewProjectType, ProjectDirectoryResponse, ProjectEntry, PublishDraftAgentRequest, PublishDraftAgentResponse, QueryEventsRequest, QueryEventsResponse, RecentTaskSummary, RechargeResponse, RegisterCompanionRequest, RegisterCompanionResponse, RemoveChatMemberRequest, Repository, RepositoryInitHookInput, ResetSecretRequest, ResetSecretResponse, ResetTaskSessionEventData, ResumeTaskEventData, ResumeTaskRequest, ResumeTaskResponse, RpcCallEventData, RpcResponseData, RtcChunkFrame, RtcChunkHeader, RtcControlChannel, RtcControlMessage, RtcIceServer, RtcIceServersRequestEventData, RtcIceServersResponseEventData, RtcSignalEventData, SendMessageTarget, SendTaskMessageRequest, SendTaskMessageResponse, SenderType, SetEnvironmentVariablesRequest, ShareAuthQuery, ShareAuthResponse, ShowModalEventData, ShowModalRequest, ShowModalResponse, ShutdownMachineData, SignatureAuthRequest, SignatureAuthResponse, SimpleSuccess, StartTaskRequest, StartTaskResponse, StatsQuery, StopTaskEventData, StopTaskRequest, StopTaskResponse, SubTaskResultUpdatedEventData, SubTaskSummary, SyncCloudMachineResponse, SyncLocalMachineResponse, SyncMachineRequest, SystemMessageEventData, SystemMessageType, TaskAgentInfo, TaskArtifactsStats, TaskArtifactsSummary, TaskEvent, TaskInfoUpdateEventData, TaskItem, TaskMessageEventData, TaskMessagePayload, TaskSharePermissions, TaskState, TaskStateChangeEventData, TaskStoppedEventData, TaskTodo, TaskTransactionsResponse, ToggleOAuthServerRequest, ToggleOAuthServerResponse, Transaction, UnarchiveTaskRequest, UnarchiveTaskResponse, UpdateAgentInfoEventData, UpdateAgentRequest, UpdateAgentResponse, UpdateChatContextRequest, UpdateChatContextResponse, UpdateDraftAgentRequest, UpdateDraftAgentResponse, UpdateOAuthServerRequest, UpdateOAuthServerResponse, UpdateTaskAgentSessionIdEventData, UpdateTaskTitleRequest, UpdateTaskTitleResponse, UpdateUserProfileRequest, UpdateUserProfileResponse, UploadUrlResult, UserBalanceResponse, UserBasicInfo, UserProfileResponse, UserWithOAuthAccounts, ValidationResult, WorkerAliveEventData, WorkerExitEventData, WorkerInitializedEventData, WorkerInitializingEventData, WorkerReadyEventData, WorkerRunningEventData, WorkerStatusRequestEventData, WorkerStatusValue, WorkerTaskEvent, WorkspaceFileRequestEventData, WorkspaceFileResponseEventData };
|