openmates 0.18.0-alpha.16 → 0.18.0-alpha.18
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.
|
@@ -11,6 +11,102 @@ import {
|
|
|
11
11
|
uploadFile
|
|
12
12
|
} from "./chunk-BBKJZ23O.js";
|
|
13
13
|
|
|
14
|
+
// src/codexConnection.ts
|
|
15
|
+
import { execFile, spawn } from "child_process";
|
|
16
|
+
import { promisify } from "util";
|
|
17
|
+
import { isAbsolute } from "path";
|
|
18
|
+
import WebSocket from "ws";
|
|
19
|
+
var execFileAsync = promisify(execFile);
|
|
20
|
+
var CONNECTION_TIMEOUT_MS = 1e4;
|
|
21
|
+
var MAX_RESPONSE_BYTES = 4 * 1024 * 1024;
|
|
22
|
+
var THREAD_ID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
23
|
+
function codexResumeArguments(context) {
|
|
24
|
+
if (context.provider !== "codex") throw new Error("Legacy OpenCode links are read-only. Connect this Task to a Codex thread explicitly.");
|
|
25
|
+
if (!THREAD_ID.test(context.id)) throw new Error("Codex connection requires a valid thread UUID.");
|
|
26
|
+
return ["resume", context.id];
|
|
27
|
+
}
|
|
28
|
+
async function daemonSocket() {
|
|
29
|
+
let result;
|
|
30
|
+
try {
|
|
31
|
+
result = await execFileAsync("codex", ["app-server", "daemon", "version"], {
|
|
32
|
+
timeout: CONNECTION_TIMEOUT_MS,
|
|
33
|
+
maxBuffer: 64 * 1024
|
|
34
|
+
});
|
|
35
|
+
} catch {
|
|
36
|
+
throw new Error("The installed Codex daemon is unavailable. Start Codex explicitly before connecting a Task.");
|
|
37
|
+
}
|
|
38
|
+
const metadata = JSON.parse(result.stdout);
|
|
39
|
+
if (metadata.status !== "running" || typeof metadata.socketPath !== "string" || !isAbsolute(metadata.socketPath)) {
|
|
40
|
+
throw new Error("The installed Codex CLI did not report a running local daemon.");
|
|
41
|
+
}
|
|
42
|
+
return metadata.socketPath;
|
|
43
|
+
}
|
|
44
|
+
async function readCodexThread(threadId, socketPath) {
|
|
45
|
+
codexResumeArguments({ provider: "codex", id: threadId });
|
|
46
|
+
const socket = socketPath ?? await daemonSocket();
|
|
47
|
+
if (!isAbsolute(socket) || socket.includes(":")) throw new Error("Codex requires an absolute local socket path.");
|
|
48
|
+
return new Promise((resolve11, reject) => {
|
|
49
|
+
const ws = new WebSocket(`ws+unix://${socket}:/`, {
|
|
50
|
+
perMessageDeflate: false,
|
|
51
|
+
handshakeTimeout: CONNECTION_TIMEOUT_MS,
|
|
52
|
+
maxPayload: MAX_RESPONSE_BYTES
|
|
53
|
+
});
|
|
54
|
+
let settled = false;
|
|
55
|
+
const finish = (error, value) => {
|
|
56
|
+
if (settled) return;
|
|
57
|
+
settled = true;
|
|
58
|
+
clearTimeout(timer);
|
|
59
|
+
if (ws.readyState === WebSocket.OPEN) ws.close();
|
|
60
|
+
else if (ws.readyState !== WebSocket.CLOSED) ws.terminate();
|
|
61
|
+
if (error) reject(error);
|
|
62
|
+
else resolve11(value);
|
|
63
|
+
};
|
|
64
|
+
const timer = setTimeout(() => finish(new Error("Codex connection timed out.")), CONNECTION_TIMEOUT_MS);
|
|
65
|
+
ws.on("error", () => finish(new Error("Could not connect to the local Codex daemon.")));
|
|
66
|
+
ws.on("close", () => finish(new Error("Codex closed the connection before returning thread metadata.")));
|
|
67
|
+
ws.on("open", () => ws.send(JSON.stringify({
|
|
68
|
+
id: 1,
|
|
69
|
+
method: "initialize",
|
|
70
|
+
params: { clientInfo: { name: "openmates-tasks", version: "1.0.0" } }
|
|
71
|
+
})));
|
|
72
|
+
ws.on("message", (raw) => {
|
|
73
|
+
try {
|
|
74
|
+
const message = JSON.parse(raw.toString());
|
|
75
|
+
if (message.id !== 1 && message.id !== 2) return;
|
|
76
|
+
if (message.error) return finish(new Error("Codex rejected the thread metadata request."));
|
|
77
|
+
if (message.id === 1) {
|
|
78
|
+
ws.send(JSON.stringify({ method: "initialized" }));
|
|
79
|
+
ws.send(JSON.stringify({ id: 2, method: "thread/read", params: { threadId, includeTurns: false } }));
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
const thread = message.result?.thread;
|
|
83
|
+
if (thread?.id !== threadId || typeof thread?.status?.type !== "string") {
|
|
84
|
+
return finish(new Error("Codex returned invalid thread metadata."));
|
|
85
|
+
}
|
|
86
|
+
finish(void 0, {
|
|
87
|
+
provider: "codex",
|
|
88
|
+
id: thread.id,
|
|
89
|
+
title: typeof thread.name === "string" ? thread.name : "",
|
|
90
|
+
status: thread.status.type,
|
|
91
|
+
url: `codex://threads/${thread.id}`
|
|
92
|
+
});
|
|
93
|
+
} catch {
|
|
94
|
+
finish(new Error("Codex returned malformed connection data."));
|
|
95
|
+
}
|
|
96
|
+
});
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
async function resumeCodexTask(context) {
|
|
100
|
+
const args = codexResumeArguments(context);
|
|
101
|
+
if (!process.stdin.isTTY || !process.stdout.isTTY) throw new Error("Task resume requires an interactive terminal; status and connect never launch work.");
|
|
102
|
+
await readCodexThread(context.id);
|
|
103
|
+
await new Promise((resolve11, reject) => {
|
|
104
|
+
const child = spawn("codex", args, { stdio: "inherit" });
|
|
105
|
+
child.once("error", () => reject(new Error("Could not open the installed Codex CLI.")));
|
|
106
|
+
child.once("exit", (code) => code === 0 ? resolve11() : reject(new Error(`Codex resume exited with status ${code ?? "interrupted"}.`)));
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
|
|
14
110
|
// src/client.ts
|
|
15
111
|
import { createHash as createHash10, randomBytes as randomBytes4, randomUUID as randomUUID6 } from "crypto";
|
|
16
112
|
import { arch, platform as platform2, release } from "os";
|
|
@@ -1204,7 +1300,7 @@ import {
|
|
|
1204
1300
|
import lockfile from "proper-lockfile";
|
|
1205
1301
|
import { createHash as createHash4 } from "crypto";
|
|
1206
1302
|
import { homedir as homedir2 } from "os";
|
|
1207
|
-
import { isAbsolute, join, resolve } from "path";
|
|
1303
|
+
import { isAbsolute as isAbsolute2, join, resolve } from "path";
|
|
1208
1304
|
|
|
1209
1305
|
// src/keychain.ts
|
|
1210
1306
|
import { execFileSync } from "child_process";
|
|
@@ -1432,7 +1528,7 @@ function resolveStateDir(options = {}) {
|
|
|
1432
1528
|
const homeDir = options.homeDir ?? homedir2();
|
|
1433
1529
|
const stateDir2 = options.stateDir ?? process.env.OPENMATES_STATE_DIR?.trim();
|
|
1434
1530
|
if (stateDir2) {
|
|
1435
|
-
if (!
|
|
1531
|
+
if (!isAbsolute2(stateDir2)) throw new Error("OPENMATES_STATE_DIR must be an absolute path.");
|
|
1436
1532
|
return resolve(stateDir2);
|
|
1437
1533
|
}
|
|
1438
1534
|
const profile = options.profile ?? process.env.OPENMATES_PROFILE?.trim();
|
|
@@ -1876,7 +1972,7 @@ function resolveServerPath(flags) {
|
|
|
1876
1972
|
// src/ws.ts
|
|
1877
1973
|
import { createRequire } from "module";
|
|
1878
1974
|
var require2 = createRequire(import.meta.url);
|
|
1879
|
-
var
|
|
1975
|
+
var WebSocket2 = require2("ws");
|
|
1880
1976
|
var DEFAULT_ASYNC_EMBED_WAIT_MS = 3e5;
|
|
1881
1977
|
var SUB_CHAT_EVENT_TYPES = /* @__PURE__ */ new Set([
|
|
1882
1978
|
"spawn_sub_chats",
|
|
@@ -2056,7 +2152,7 @@ var OpenMatesWsClient = class {
|
|
|
2056
2152
|
wsHeaders.Cookie = cookieStr;
|
|
2057
2153
|
}
|
|
2058
2154
|
}
|
|
2059
|
-
this.socket = new
|
|
2155
|
+
this.socket = new WebSocket2(`${wsBase}/v1/ws?${query.toString()}`, {
|
|
2060
2156
|
headers: wsHeaders
|
|
2061
2157
|
});
|
|
2062
2158
|
this.socket.on("message", (rawData) => {
|
|
@@ -4527,7 +4623,7 @@ function summarizeAssistantSpeech(chatId, results) {
|
|
|
4527
4623
|
}
|
|
4528
4624
|
|
|
4529
4625
|
// src/protonBridgeConnector.ts
|
|
4530
|
-
import { spawn } from "child_process";
|
|
4626
|
+
import { spawn as spawn2 } from "child_process";
|
|
4531
4627
|
import { existsSync as existsSync5 } from "fs";
|
|
4532
4628
|
import { connect as connectTcp } from "net";
|
|
4533
4629
|
import { arch as nodeArch, platform as nodePlatform } from "os";
|
|
@@ -5170,7 +5266,7 @@ async function waitForSocketText(socket, getBuffer, done, timeoutMs) {
|
|
|
5170
5266
|
});
|
|
5171
5267
|
}
|
|
5172
5268
|
function startProtonBridgeProcess(command, args) {
|
|
5173
|
-
const child =
|
|
5269
|
+
const child = spawn2(command, args, { stdio: "pipe" });
|
|
5174
5270
|
child.stdout.on("data", () => void 0);
|
|
5175
5271
|
child.stderr.on("data", () => void 0);
|
|
5176
5272
|
return {
|
|
@@ -5279,7 +5375,7 @@ async function captureOrPromptBridgeCredentials(command, args) {
|
|
|
5279
5375
|
}
|
|
5280
5376
|
async function captureProtonBridgeInfo(command, args) {
|
|
5281
5377
|
return await new Promise((resolve11, reject) => {
|
|
5282
|
-
const child =
|
|
5378
|
+
const child = spawn2(command, args, { stdio: "pipe" });
|
|
5283
5379
|
let output = "";
|
|
5284
5380
|
let errorOutput = "";
|
|
5285
5381
|
const timer = setTimeout(() => {
|
|
@@ -5409,7 +5505,7 @@ var DEFAULT_STANDALONE_PREFIX = "TASK";
|
|
|
5409
5505
|
var PRIORITY_LEVELS = ["none", "low", "medium", "high", "urgent"];
|
|
5410
5506
|
var LABEL_INDEX_INFO = "openmates-task-label-index-v1";
|
|
5411
5507
|
var EXTERNAL_CHAT_INDEX_INFO = "openmates-task-external-chat-index-v1";
|
|
5412
|
-
var
|
|
5508
|
+
var EXTERNAL_CHAT_PROVIDERS = ["codex", "opencode"];
|
|
5413
5509
|
var BLOCKED_REASON_CODES = [
|
|
5414
5510
|
"needs_user_input",
|
|
5415
5511
|
"waiting_for_approval",
|
|
@@ -5442,8 +5538,8 @@ function parseExternalChatRef(value) {
|
|
|
5442
5538
|
const provider = value.slice(0, separator2).trim().toLowerCase();
|
|
5443
5539
|
const id = value.slice(separator2 + 1).trim();
|
|
5444
5540
|
if (separator2 <= 0 || !id) throw new Error("--external-chat requires provider:id.");
|
|
5445
|
-
if (provider
|
|
5446
|
-
return { provider
|
|
5541
|
+
if (!EXTERNAL_CHAT_PROVIDERS.includes(provider)) throw new Error(`Unsupported external chat provider '${provider}'. Use codex; opencode is retained for legacy records.`);
|
|
5542
|
+
return { provider, id };
|
|
5447
5543
|
}
|
|
5448
5544
|
function externalChatLookupHash(masterKey, context) {
|
|
5449
5545
|
const indexKey = Buffer.from(hkdfSync2("sha256", Buffer.from(masterKey), Buffer.alloc(0), EXTERNAL_CHAT_INDEX_INFO, 32));
|
|
@@ -5465,7 +5561,8 @@ function parseAssignee(value) {
|
|
|
5465
5561
|
const normalized = value?.trim().toLowerCase().replace(/-/g, "_");
|
|
5466
5562
|
if (!normalized || normalized === "user") return { assigneeType: "user", assigneeIdentity: null, assigneeHash: null };
|
|
5467
5563
|
if (normalized === "openmates") return { assigneeType: "openmates", assigneeIdentity: "openmates", assigneeHash: null };
|
|
5468
|
-
if (normalized === "external_ai" || normalized === "
|
|
5564
|
+
if (normalized === "external_ai" || normalized === "codex") return { assigneeType: "external_ai", assigneeIdentity: "codex", assigneeHash: null };
|
|
5565
|
+
if (normalized === "opencode") return { assigneeType: "external_ai", assigneeIdentity: "opencode", assigneeHash: null };
|
|
5469
5566
|
if (normalized === "unassigned") return { assigneeType: "unassigned", assigneeIdentity: null, assigneeHash: null };
|
|
5470
5567
|
return { assigneeType: "user", assigneeIdentity: null, assigneeHash: value };
|
|
5471
5568
|
}
|
|
@@ -12729,12 +12826,12 @@ var OpenMatesClient = class _OpenMatesClient {
|
|
|
12729
12826
|
}
|
|
12730
12827
|
return response.data.tasks ?? [];
|
|
12731
12828
|
}
|
|
12732
|
-
async createUserTask(input) {
|
|
12829
|
+
async createUserTask(input, context = {}) {
|
|
12733
12830
|
this.requireSession();
|
|
12734
12831
|
const response = await this.http.post(
|
|
12735
12832
|
"/v1/user-tasks",
|
|
12736
12833
|
input,
|
|
12737
|
-
this.getCliRequestHeaders()
|
|
12834
|
+
{ ...this.getCliRequestHeaders(), ...context.creator ? { "X-OpenMates-Task-Actor": "assignee", "X-OpenMates-Task-Creator": context.creator } : {} }
|
|
12738
12835
|
);
|
|
12739
12836
|
if (!response.ok || !response.data.task) {
|
|
12740
12837
|
throw new Error(`User task create failed with HTTP ${response.status}`);
|
|
@@ -24503,7 +24600,7 @@ import { basename as basename4, dirname as dirname10 } from "path";
|
|
|
24503
24600
|
import { createHash as createHash15, randomBytes as randomBytes9, randomUUID as randomUUID15 } from "crypto";
|
|
24504
24601
|
import { arch as arch2, platform as platform3 } from "os";
|
|
24505
24602
|
import { parse as parseYaml } from "yaml";
|
|
24506
|
-
import
|
|
24603
|
+
import WebSocket3 from "ws";
|
|
24507
24604
|
|
|
24508
24605
|
// ../secret-scanner/src/registry.ts
|
|
24509
24606
|
import { createRequire as createRequire2 } from "module";
|
|
@@ -27404,11 +27501,9 @@ function validateServerEnvironmentTarget(command, environment) {
|
|
|
27404
27501
|
if (!environmentCommands.has(command) || environment === void 0) return;
|
|
27405
27502
|
if (environment === "shared-dev") return;
|
|
27406
27503
|
if (environment === "task") {
|
|
27407
|
-
throw new Error(
|
|
27408
|
-
"Task environments are not enabled: verified storage limits and the runtime broker are required. Shared dev was not changed."
|
|
27409
|
-
);
|
|
27504
|
+
throw new Error("Task Docker environments were replaced by GitHub CI. Use scripts/tests.py run --spec <spec>.");
|
|
27410
27505
|
}
|
|
27411
|
-
throw new Error("Unknown server environment target; use shared-dev
|
|
27506
|
+
throw new Error("Unknown server environment target; use shared-dev for explicit server administration.");
|
|
27412
27507
|
}
|
|
27413
27508
|
|
|
27414
27509
|
// src/serverBackupArchive.ts
|
|
@@ -73735,7 +73830,7 @@ import {
|
|
|
73735
73830
|
statSync as statSync2,
|
|
73736
73831
|
writeFileSync as writeFileSync8
|
|
73737
73832
|
} from "fs";
|
|
73738
|
-
import { spawn as
|
|
73833
|
+
import { spawn as spawn3, spawnSync as spawnSync2 } from "child_process";
|
|
73739
73834
|
import { join as join10, resolve as resolve9, relative as relative2 } from "path";
|
|
73740
73835
|
|
|
73741
73836
|
// src/projectFileRisk.ts
|
|
@@ -74333,7 +74428,7 @@ function binaryRgGlobs() {
|
|
|
74333
74428
|
}
|
|
74334
74429
|
async function runRgCommand(args, cwd, maxOutputMatches) {
|
|
74335
74430
|
return new Promise((resolvePromise, reject) => {
|
|
74336
|
-
const child =
|
|
74431
|
+
const child = spawn3("rg", args, {
|
|
74337
74432
|
cwd,
|
|
74338
74433
|
stdio: ["ignore", "pipe", "pipe"]
|
|
74339
74434
|
});
|
|
@@ -75714,6 +75809,32 @@ async function handleTasks(client, subcommand, rest, flags, redactor) {
|
|
|
75714
75809
|
}
|
|
75715
75810
|
const masterKey = client.getMasterKeyBytes();
|
|
75716
75811
|
const scope = await resolveTaskScope(client, masterKey, flags, taskScopeFromFlags(flags, masterKey));
|
|
75812
|
+
if (["connect", "connection", "resume"].includes(subcommand)) {
|
|
75813
|
+
const task = await requiredResolvedTask(client, masterKey, rest[0], scope, subcommand);
|
|
75814
|
+
if (task.source === "workflow_run") throw new Error("Workflow projections cannot connect to external agents.");
|
|
75815
|
+
if (subcommand === "connect") {
|
|
75816
|
+
if (typeof flags.thread !== "string") throw new Error("Usage: openmates tasks connect <task-id> --thread <codex-thread-uuid>");
|
|
75817
|
+
if (task.primaryChatId) throw new Error("This Task has a native chat. Clear that link explicitly before connecting Codex.");
|
|
75818
|
+
const connection2 = await readCodexThread(flags.thread);
|
|
75819
|
+
const patch = await buildUpdateUserTaskInput(task, masterKey, {
|
|
75820
|
+
assign: "codex",
|
|
75821
|
+
externalChat: { provider: "codex", id: connection2.id, title: connection2.title }
|
|
75822
|
+
});
|
|
75823
|
+
const updated = await client.updateUserTask(task.taskId, patch);
|
|
75824
|
+
printTaskOutput(await decryptUserTask(updated, masterKey), flags);
|
|
75825
|
+
return;
|
|
75826
|
+
}
|
|
75827
|
+
if (!task.externalChat) throw new Error("This Task has no external connection. Use tasks connect first.");
|
|
75828
|
+
codexResumeArguments(task.externalChat);
|
|
75829
|
+
if (subcommand === "resume") {
|
|
75830
|
+
await resumeCodexTask(task.externalChat);
|
|
75831
|
+
return;
|
|
75832
|
+
}
|
|
75833
|
+
const connection = await readCodexThread(task.externalChat.id);
|
|
75834
|
+
if (flags.json === true) printJson2({ task_id: task.taskId, connection });
|
|
75835
|
+
else console.log(`${task.shortId}: Codex ${connection.status} \u2014 ${connection.url}`);
|
|
75836
|
+
return;
|
|
75837
|
+
}
|
|
75717
75838
|
if (subcommand === "activity") {
|
|
75718
75839
|
const action = rest[0] ?? "list";
|
|
75719
75840
|
const task = await requiredResolvedTask(client, masterKey, rest[1], scope, `activity ${action}`);
|
|
@@ -75917,7 +76038,14 @@ async function handleTasks(client, subcommand, rest, flags, redactor) {
|
|
|
75917
76038
|
priority: typeof flags.priority === "string" ? normalizeTaskPriority(flags.priority) : void 0,
|
|
75918
76039
|
slug: typeof flags.slug === "string" ? flags.slug : void 0
|
|
75919
76040
|
}));
|
|
75920
|
-
|
|
76041
|
+
let creator;
|
|
76042
|
+
if (flags["as-assignee"] === true) {
|
|
76043
|
+
const external = externalChatFromFlags(flags);
|
|
76044
|
+
if (!external || external.provider !== "codex") throw new Error("Codex creator attribution requires --external-chat codex:<thread-uuid>.");
|
|
76045
|
+
await readCodexThread(external.id);
|
|
76046
|
+
creator = "codex";
|
|
76047
|
+
}
|
|
76048
|
+
const created = await client.createUserTask(input, { creator });
|
|
75921
76049
|
printTaskOutput(await decryptUserTask(created, masterKey), flags);
|
|
75922
76050
|
return;
|
|
75923
76051
|
}
|
|
@@ -75968,6 +76096,7 @@ The scheduled projection could not be skipped: ${error instanceof Error ? error.
|
|
|
75968
76096
|
}
|
|
75969
76097
|
if (subcommand === "start") {
|
|
75970
76098
|
const task = await requiredResolvedTask(client, masterKey, rest[0], scope, "start");
|
|
76099
|
+
if (task.assigneeType === "external_ai") throw new Error("Use tasks resume for an explicitly connected Codex Task; tasks start runs OpenMates AI.");
|
|
75971
76100
|
const started = await client.startUserTaskWithAI(task.taskId, {
|
|
75972
76101
|
version: task.version,
|
|
75973
76102
|
primary_chat_id: task.primaryChatId ?? void 0,
|
|
@@ -81490,7 +81619,7 @@ async function handleCodeRun(client, flags, apiKey) {
|
|
|
81490
81619
|
}
|
|
81491
81620
|
async function streamCodeRunToTerminal(url, jsonMode) {
|
|
81492
81621
|
return await new Promise((resolve11, reject) => {
|
|
81493
|
-
const ws = new
|
|
81622
|
+
const ws = new WebSocket3(url);
|
|
81494
81623
|
let lastStatus = {};
|
|
81495
81624
|
ws.on("message", (data) => {
|
|
81496
81625
|
try {
|
|
@@ -86357,18 +86486,21 @@ Examples:
|
|
|
86357
86486
|
}
|
|
86358
86487
|
function printTasksHelp() {
|
|
86359
86488
|
console.log(`Tasks commands:
|
|
86360
|
-
openmates tasks list [--status <status>] [--chat <id>|--external-chat
|
|
86361
|
-
openmates tasks board [--chat <id>|--external-chat
|
|
86489
|
+
openmates tasks list [--status <status>] [--chat <id>|--external-chat codex:<thread-uuid>] [--project <id>] [--label <label>] [--priority <level>] [--json]
|
|
86490
|
+
openmates tasks board [--chat <id>|--external-chat codex:<thread-uuid>] [--project <id>] [--label <label>] [--priority <level>] [--json]
|
|
86362
86491
|
openmates tasks show <task-id|short-id> [--json]
|
|
86363
86492
|
openmates tasks <task-id|short-id> add-to-project <project-id> [--json]
|
|
86364
86493
|
openmates tasks <task-id|short-id> remove-from-project <project-id> [--json]
|
|
86365
86494
|
openmates tasks history <task-id|short-id> [--limit <n>] [--json]
|
|
86366
86495
|
openmates tasks restore <task-id|short-id> --entry <history-entry-id> [--state before|after] [--json]
|
|
86367
|
-
openmates tasks create --title <title> [--description <text>] [--assign user|openmates|external-ai|unassigned] [--chat <id>|--external-chat
|
|
86368
|
-
openmates tasks edit <task-id|short-id> [--title <title>] [--description <text>] [--chat <id>|--external-chat
|
|
86496
|
+
openmates tasks create --title <title> [--description <text>] [--assign user|openmates|external-ai|unassigned] [--chat <id>|--external-chat codex:<thread-uuid> [--external-chat-title <title>]] [--project <id>] [--label <label>] [--priority <level>] [--status <status>] [--due <date>] [--json]
|
|
86497
|
+
openmates tasks edit <task-id|short-id> [--title <title>] [--description <text>] [--chat <id>|--external-chat codex:<thread-uuid> [--external-chat-title <title>]] [--label <label>] [--add-label <label>] [--remove-label <label>] [--priority <level>] [--assign user|openmates|external-ai|unassigned] [--status <status>] [--json]
|
|
86369
86498
|
openmates tasks delete <task-id|short-id> --confirm [--json]
|
|
86370
86499
|
openmates tasks start <task-id|short-id> [--json]
|
|
86371
86500
|
openmates tasks status [<task-id|short-id>] [--json]
|
|
86501
|
+
openmates tasks connect <task-id|short-id> --thread <codex-thread-uuid> [--json]
|
|
86502
|
+
openmates tasks connection <task-id|short-id> [--json]
|
|
86503
|
+
openmates tasks resume <task-id|short-id>
|
|
86372
86504
|
openmates tasks block <task-id|short-id> --reason-code <code> [--reason-text <private-text>] [--json]
|
|
86373
86505
|
openmates tasks unblock <task-id|short-id> [--json]
|
|
86374
86506
|
openmates tasks skip <task-id|short-id> [--json]
|
|
@@ -762,7 +762,7 @@ interface WorkflowNodeRun {
|
|
|
762
762
|
}
|
|
763
763
|
type UserTaskStatus = "backlog" | "todo" | "in_progress" | "blocked" | "done";
|
|
764
764
|
type UserTaskAssigneeType = "user" | "openmates" | "external_ai" | "unassigned";
|
|
765
|
-
type UserTaskAssigneeIdentity = "openmates" | "opencode";
|
|
765
|
+
type UserTaskAssigneeIdentity = "openmates" | "codex" | "opencode";
|
|
766
766
|
type ProjectSourceType = "local_folder" | "local_git_repository" | "remote_folder" | "remote_git_repository";
|
|
767
767
|
type ProjectSourceCapability = "read" | "search" | "import" | "write_request";
|
|
768
768
|
type ProjectSourceStatus = "connected" | "offline" | "permission_required" | "revoked";
|
|
@@ -895,7 +895,7 @@ interface UserTaskRecord {
|
|
|
895
895
|
assignee_identity?: UserTaskAssigneeIdentity | null;
|
|
896
896
|
assignee_hash?: string | null;
|
|
897
897
|
primary_chat_id?: string | null;
|
|
898
|
-
external_chat_provider?: "opencode" | null;
|
|
898
|
+
external_chat_provider?: "codex" | "opencode" | null;
|
|
899
899
|
external_chat_lookup_hash?: string | null;
|
|
900
900
|
encrypted_external_chat_id?: string | null;
|
|
901
901
|
encrypted_external_chat_title?: string | null;
|
|
@@ -2426,14 +2426,16 @@ declare class OpenMatesClient {
|
|
|
2426
2426
|
chatId?: string;
|
|
2427
2427
|
projectId?: string;
|
|
2428
2428
|
labelHashes?: string[];
|
|
2429
|
-
externalChatProvider?: "opencode";
|
|
2429
|
+
externalChatProvider?: "codex" | "opencode";
|
|
2430
2430
|
externalChatLookupHash?: string;
|
|
2431
2431
|
priority?: number;
|
|
2432
2432
|
limit?: number;
|
|
2433
2433
|
teamId?: string | null;
|
|
2434
2434
|
personal?: boolean;
|
|
2435
2435
|
}): Promise<UserTaskRecord[]>;
|
|
2436
|
-
createUserTask(input: UserTaskCreateInput
|
|
2436
|
+
createUserTask(input: UserTaskCreateInput, context?: {
|
|
2437
|
+
creator?: "codex";
|
|
2438
|
+
}): Promise<UserTaskRecord>;
|
|
2437
2439
|
askUserTasks(input: {
|
|
2438
2440
|
instruction: string;
|
|
2439
2441
|
encryptedCreate?: UserTaskCreateInput;
|
package/dist/cli.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
export { aa as ImagesAiDetectionClassification, ab as ImagesAiDetectionSummary, aA as assertTrustedAccountCommandAllowed, aB as assertTrustedAccountGuardEnvironment, as as buildImagesAiDetectionSummary, aC as buildTravelConnectionsRequest, at as classifyImagesAiDetection, av as formatImagesAiDetectionLabel, aw as getExtForLang, aD as requireExactConfirmation, aE as resolveProjectContext, az as serializeToYaml, aF as shouldRequireTrustedAccountGuard } from './cli-
|
|
2
|
+
export { aa as ImagesAiDetectionClassification, ab as ImagesAiDetectionSummary, aA as assertTrustedAccountCommandAllowed, aB as assertTrustedAccountGuardEnvironment, as as buildImagesAiDetectionSummary, aC as buildTravelConnectionsRequest, at as classifyImagesAiDetection, av as formatImagesAiDetectionLabel, aw as getExtForLang, aD as requireExactConfirmation, aE as resolveProjectContext, az as serializeToYaml, aF as shouldRequireTrustedAccountGuard } from './cli-DcPaR7zQ.js';
|
package/dist/cli.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { U as UserTaskStatus, a as UserTaskAssigneeType, b as UserTaskAssigneeIdentity, c as UserTaskRecord, d as UserTaskActivityRecord, e as UserPlanStatus, f as UserPlanRecord, g as UserPlanVerificationStatus, h as UserPlanLearningType, i as UserPlanLearningTargetKind, j as UserPlanLearningStatus, k as UserPlanLearningLevel, l as UserPlanLearningRecord, m as UserPlanCriterionRecord, n as UserPlanVerificationRecord, o as UserPlanCreateInput, p as UserPlanUpdateInput, P as ProjectItemRecord, q as UserPlanLearningCreateTasksInput, r as UserPlanLearningCreateTasksResult, s as UserTaskReorderInput, W as WorkflowSummary, t as WorkflowCapability, u as WorkflowDetail, v as WorkflowInputStartParams, w as WorkflowInputSessionResult, x as WorkflowInputSessionDetail, y as WorkflowInputEvent, z as WorkflowGraph, A as WorkflowRunContentRetention, B as WorkflowRunDetail, C as WorkflowRunCancellationResult, D as WorkflowTemplateProjectionUpsertParams, E as WorkflowTemplateProjectionResult, F as PublicWorkflowTemplateProjection, G as WorkflowTemplateProjectionRevocationResult, H as WorkflowTemplateBindingCompletionParams, I as WorkflowTemplateBindingCompletionResult, J as WorkflowTemplateShortUrlParams, K as WorkflowTemplateShortUrlResult, S as ShortUrlRevokeResult, L as WorkflowTemplateImportPayload, M as ImportedWorkflowTemplate } from './cli-
|
|
2
|
-
export { N as AuthMethodsStatus, O as AuthoritativeChatReconciliation, Q as BackupCodesResult, R as BankTransferOrderDetails, T as BankTransferStatus, V as CachedChat, X as CachedNewChatSuggestion, Y as ChatListPage, Z as CliSignupResult, _ as DecryptedDraft, $ as DecryptedEmbed, a0 as DecryptedMemoryEntry, a1 as DecryptedMessage, a2 as DecryptedNewChatSuggestion, a3 as DocsFile, a4 as DocsFolder, a5 as DocsSearchResult, a6 as DocsTree, a7 as EncryptedDraft, a8 as GiftCardBankTransferStatus, a9 as INTEREST_TAG_IDS, aa as ImagesAiDetectionClassification, ab as ImagesAiDetectionSummary, ac as InterestTagId, ad as MATE_NAMES, ae as MEMORY_TYPE_REGISTRY, af as MemoryFieldDef, ag as MemoryTypeDef, ah as OpenMatesClient, ai as OpenMatesClientOptions, aj as OpenMatesSession, ak as SyncCache, al as TopicPreferencesPayload, am as TotpSetupStartResult, an as WorkflowEdge, ao as WorkflowNode, ap as WorkflowNodeRun, aq as WorkflowNodeType, ar as WorkflowRunContentStorage, as as buildImagesAiDetectionSummary, at as classifyImagesAiDetection, au as deriveAppUrl, av as formatImagesAiDetectionLabel, aw as getExtForLang, ax as normalizeInterestTagIds, ay as reconcileAuthoritativeChats, az as serializeToYaml } from './cli-
|
|
1
|
+
import { U as UserTaskStatus, a as UserTaskAssigneeType, b as UserTaskAssigneeIdentity, c as UserTaskRecord, d as UserTaskActivityRecord, e as UserPlanStatus, f as UserPlanRecord, g as UserPlanVerificationStatus, h as UserPlanLearningType, i as UserPlanLearningTargetKind, j as UserPlanLearningStatus, k as UserPlanLearningLevel, l as UserPlanLearningRecord, m as UserPlanCriterionRecord, n as UserPlanVerificationRecord, o as UserPlanCreateInput, p as UserPlanUpdateInput, P as ProjectItemRecord, q as UserPlanLearningCreateTasksInput, r as UserPlanLearningCreateTasksResult, s as UserTaskReorderInput, W as WorkflowSummary, t as WorkflowCapability, u as WorkflowDetail, v as WorkflowInputStartParams, w as WorkflowInputSessionResult, x as WorkflowInputSessionDetail, y as WorkflowInputEvent, z as WorkflowGraph, A as WorkflowRunContentRetention, B as WorkflowRunDetail, C as WorkflowRunCancellationResult, D as WorkflowTemplateProjectionUpsertParams, E as WorkflowTemplateProjectionResult, F as PublicWorkflowTemplateProjection, G as WorkflowTemplateProjectionRevocationResult, H as WorkflowTemplateBindingCompletionParams, I as WorkflowTemplateBindingCompletionResult, J as WorkflowTemplateShortUrlParams, K as WorkflowTemplateShortUrlResult, S as ShortUrlRevokeResult, L as WorkflowTemplateImportPayload, M as ImportedWorkflowTemplate } from './cli-DcPaR7zQ.js';
|
|
2
|
+
export { N as AuthMethodsStatus, O as AuthoritativeChatReconciliation, Q as BackupCodesResult, R as BankTransferOrderDetails, T as BankTransferStatus, V as CachedChat, X as CachedNewChatSuggestion, Y as ChatListPage, Z as CliSignupResult, _ as DecryptedDraft, $ as DecryptedEmbed, a0 as DecryptedMemoryEntry, a1 as DecryptedMessage, a2 as DecryptedNewChatSuggestion, a3 as DocsFile, a4 as DocsFolder, a5 as DocsSearchResult, a6 as DocsTree, a7 as EncryptedDraft, a8 as GiftCardBankTransferStatus, a9 as INTEREST_TAG_IDS, aa as ImagesAiDetectionClassification, ab as ImagesAiDetectionSummary, ac as InterestTagId, ad as MATE_NAMES, ae as MEMORY_TYPE_REGISTRY, af as MemoryFieldDef, ag as MemoryTypeDef, ah as OpenMatesClient, ai as OpenMatesClientOptions, aj as OpenMatesSession, ak as SyncCache, al as TopicPreferencesPayload, am as TotpSetupStartResult, an as WorkflowEdge, ao as WorkflowNode, ap as WorkflowNodeRun, aq as WorkflowNodeType, ar as WorkflowRunContentStorage, as as buildImagesAiDetectionSummary, at as classifyImagesAiDetection, au as deriveAppUrl, av as formatImagesAiDetectionLabel, aw as getExtForLang, ax as normalizeInterestTagIds, ay as reconcileAuthoritativeChats, az as serializeToYaml } from './cli-DcPaR7zQ.js';
|
|
3
3
|
|
|
4
4
|
interface ProjectedAssistantSpeechSegment {
|
|
5
5
|
sequence: number;
|
|
@@ -4006,7 +4006,7 @@ interface TaskUpdateOptions {
|
|
|
4006
4006
|
slug?: string;
|
|
4007
4007
|
}
|
|
4008
4008
|
interface ExternalChatRef {
|
|
4009
|
-
provider: "opencode";
|
|
4009
|
+
provider: "codex" | "opencode";
|
|
4010
4010
|
id: string;
|
|
4011
4011
|
}
|
|
4012
4012
|
interface ExternalChatContext extends ExternalChatRef {
|
package/dist/index.js
CHANGED