@openclaw/codex 2026.5.27 → 2026.5.28-beta.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/{client-BVK_jmHW.js → client-TfDda-h3.js} +1 -1
- package/dist/{client-factory-fW4Hh9q_.js → client-factory-BPBvbguy.js} +2 -2
- package/dist/{command-handlers-YXjMla3v.js → command-handlers-B8MXR7fh.js} +11 -11
- package/dist/{compact-DIXx9K0Q.js → compact-Dyz0rQLl.js} +10 -8
- package/dist/{computer-use-CakwWGCR.js → computer-use-BRIifWhE.js} +2 -2
- package/dist/{config-0-UN67Qg.js → config-BW7NPdAQ.js} +10 -3
- package/dist/{conversation-binding-CWaG0k5A.js → conversation-binding-D8OO0S9R.js} +7 -7
- package/dist/harness.js +5 -5
- package/dist/index.js +13 -12
- package/dist/media-understanding-provider.js +6 -6
- package/dist/{models-_XwpqjR8.js → models-Dnasi6LR.js} +1 -1
- package/dist/{vision-tools-DqpLmF5H.js → native-hook-relay-DYOYE3qb.js} +691 -14
- package/dist/{notification-correlation-YINts3PA.js → notification-correlation-BVB6XFQM.js} +44 -3
- package/dist/provider.js +2 -2
- package/dist/{request-Dtg0vQrE.js → request-Cj95iOk6.js} +3 -3
- package/dist/{run-attempt-BIbGYJog.js → run-attempt-D9i99EqV.js} +8098 -7879
- package/dist/{session-binding-4fRldGaa.js → session-binding-DuJisBZB.js} +1 -1
- package/dist/{shared-client-8kIrP817.js → shared-client-DICbgRn5.js} +21 -3
- package/dist/{side-question-v4nixmAs.js → side-question-280VWjeH.js} +7 -8
- package/dist/{thread-lifecycle-DZAfY4d6.js → thread-lifecycle-1u5ogKG_.js} +4 -4
- package/npm-shrinkwrap.json +96 -1771
- package/package.json +4 -5
- package/dist/dynamic-tools-BSZIYzfP.js +0 -560
- package/dist/test-api.js +0 -51
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as resolveCodexAppServerRuntimeOptions } from "./config-
|
|
1
|
+
import { l as resolveCodexAppServerRuntimeOptions } from "./config-BW7NPdAQ.js";
|
|
2
2
|
import { materializeWindowsSpawnProgram, resolveWindowsSpawnProgram } from "openclaw/plugin-sdk/windows-spawn";
|
|
3
3
|
import { OPENCLAW_VERSION, embeddedAgentLog } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
4
4
|
import { createInterface } from "node:readline";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
//#region extensions/codex/src/app-server/client-factory.ts
|
|
2
|
-
const defaultCodexAppServerClientFactory = (startOptions, authProfileId, agentDir, config) => import("./shared-client-
|
|
2
|
+
const defaultCodexAppServerClientFactory = (startOptions, authProfileId, agentDir, config) => import("./shared-client-DICbgRn5.js").then((n) => n.s).then(({ getSharedCodexAppServerClient }) => getSharedCodexAppServerClient({
|
|
3
3
|
startOptions,
|
|
4
4
|
authProfileId,
|
|
5
5
|
agentDir,
|
|
6
6
|
config
|
|
7
7
|
}));
|
|
8
|
-
const defaultLeasedCodexAppServerClientFactory = (startOptions, authProfileId, agentDir, config) => import("./shared-client-
|
|
8
|
+
const defaultLeasedCodexAppServerClientFactory = (startOptions, authProfileId, agentDir, config) => import("./shared-client-DICbgRn5.js").then((n) => n.s).then(({ getLeasedSharedCodexAppServerClient }) => getLeasedSharedCodexAppServerClient({
|
|
9
9
|
startOptions,
|
|
10
10
|
authProfileId,
|
|
11
11
|
agentDir,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { a as isCodexFastServiceTier, l as resolveCodexAppServerRuntimeOptions } from "./config-
|
|
2
|
-
import { n as listCodexAppServerModels, t as listAllCodexAppServerModels } from "./models-
|
|
3
|
-
import { l as isJsonObject } from "./client-
|
|
4
|
-
import { i as readCodexAppServerBinding, o as writeCodexAppServerBinding, t as clearCodexAppServerBinding } from "./session-binding-
|
|
5
|
-
import { i as describeControlFailure, r as CODEX_CONTROL_METHODS, t as requestCodexAppServerJson } from "./request-
|
|
6
|
-
import {
|
|
1
|
+
import { a as isCodexFastServiceTier, l as resolveCodexAppServerRuntimeOptions } from "./config-BW7NPdAQ.js";
|
|
2
|
+
import { n as listCodexAppServerModels, t as listAllCodexAppServerModels } from "./models-Dnasi6LR.js";
|
|
3
|
+
import { l as isJsonObject } from "./client-TfDda-h3.js";
|
|
4
|
+
import { i as readCodexAppServerBinding, o as writeCodexAppServerBinding, t as clearCodexAppServerBinding } from "./session-binding-DuJisBZB.js";
|
|
5
|
+
import { i as describeControlFailure, r as CODEX_CONTROL_METHODS, t as requestCodexAppServerJson } from "./request-Cj95iOk6.js";
|
|
6
|
+
import { a as buildHelp, c as formatCodexStatus, d as formatModels, f as formatSkills, l as formatComputerUseStatus, m as readString$1, o as formatAccount, p as formatThreads, s as formatCodexDisplayText, u as formatList, v as summarizeCodexAccountUsage } from "./notification-correlation-BVB6XFQM.js";
|
|
7
7
|
import { n as resolveCodexNativeExecutionBlock, r as resolveCodexNativeSandboxBlock } from "./sandbox-guard-CTnEWuor.js";
|
|
8
|
-
import { _ as steerCodexConversationTurn, b as readCodexConversationBindingData, d as parseCodexFastModeArg, f as parseCodexPermissionsModeArg, g as setCodexConversationPermissions, h as setCodexConversationModel, m as setCodexConversationFastMode, o as formatCodexCliSessions, p as readCodexConversationActiveTurn, r as startCodexConversationThread, u as formatPermissionsMode, v as stopCodexConversationTurn, x as resolveCodexDefaultWorkspaceDir, y as createCodexCliNodeConversationBindingData } from "./conversation-binding-
|
|
9
|
-
import { n as installCodexComputerUse, r as readCodexComputerUseStatus } from "./computer-use-
|
|
8
|
+
import { _ as steerCodexConversationTurn, b as readCodexConversationBindingData, d as parseCodexFastModeArg, f as parseCodexPermissionsModeArg, g as setCodexConversationPermissions, h as setCodexConversationModel, m as setCodexConversationFastMode, o as formatCodexCliSessions, p as readCodexConversationActiveTurn, r as startCodexConversationThread, u as formatPermissionsMode, v as stopCodexConversationTurn, x as resolveCodexDefaultWorkspaceDir, y as createCodexCliNodeConversationBindingData } from "./conversation-binding-D8OO0S9R.js";
|
|
9
|
+
import { n as installCodexComputerUse, r as readCodexComputerUseStatus } from "./computer-use-BRIifWhE.js";
|
|
10
10
|
import { n as rememberCodexRateLimits } from "./rate-limit-cache-N66I-Rd7.js";
|
|
11
11
|
import crypto from "node:crypto";
|
|
12
12
|
import { normalizeOptionalString, normalizeUniqueStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -536,7 +536,7 @@ async function handleCodexSubcommand(ctx, options) {
|
|
|
536
536
|
}
|
|
537
537
|
if (normalized === "skills") {
|
|
538
538
|
if (rest.length > 0) return { text: "Usage: /codex skills" };
|
|
539
|
-
return { text:
|
|
539
|
+
return { text: formatSkills(await deps.codexControlRequest(options.pluginConfig, CODEX_CONTROL_METHODS.listSkills, {})) };
|
|
540
540
|
}
|
|
541
541
|
if (normalized === "account") {
|
|
542
542
|
if (rest.length > 0) return { text: "Usage: /codex account" };
|
|
@@ -1443,8 +1443,8 @@ function parseCodexCliSessionsArgs(args) {
|
|
|
1443
1443
|
}
|
|
1444
1444
|
if (arg === "--limit") {
|
|
1445
1445
|
const value = readRequiredOptionValue(args, index);
|
|
1446
|
-
const parsedLimit = value ? Number.
|
|
1447
|
-
if (!Number.
|
|
1446
|
+
const parsedLimit = value && /^\+?\d+$/.test(value.trim()) ? Number(value.trim()) : NaN;
|
|
1447
|
+
if (!Number.isSafeInteger(parsedLimit) || parsedLimit <= 0) {
|
|
1448
1448
|
parsed.help = true;
|
|
1449
1449
|
continue;
|
|
1450
1450
|
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { t as defaultCodexAppServerClientFactory } from "./client-factory-
|
|
2
|
-
import { l as resolveCodexAppServerRuntimeOptions } from "./config-
|
|
3
|
-
import { i as readCodexAppServerBinding } from "./session-binding-
|
|
1
|
+
import { t as defaultCodexAppServerClientFactory } from "./client-factory-BPBvbguy.js";
|
|
2
|
+
import { l as resolveCodexAppServerRuntimeOptions } from "./config-BW7NPdAQ.js";
|
|
3
|
+
import { i as readCodexAppServerBinding } from "./session-binding-DuJisBZB.js";
|
|
4
4
|
import { n as resolveCodexNativeExecutionBlock } from "./sandbox-guard-CTnEWuor.js";
|
|
5
|
-
import { asOptionalRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
6
5
|
import { embeddedAgentLog } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
7
6
|
//#region extensions/codex/src/app-server/compact.ts
|
|
8
7
|
const warnedIgnoredCompactionOverrides = /* @__PURE__ */ new Set();
|
|
@@ -35,18 +34,18 @@ function readIgnoredCompactionOverridePaths(params) {
|
|
|
35
34
|
}
|
|
36
35
|
function readCompactionOverrideEntries(params) {
|
|
37
36
|
const entries = [];
|
|
38
|
-
const defaultCompaction =
|
|
39
|
-
const defaultRecord =
|
|
37
|
+
const defaultCompaction = readRecord(readRecord(params.config?.agents)?.defaults)?.compaction;
|
|
38
|
+
const defaultRecord = readRecord(defaultCompaction);
|
|
40
39
|
if (defaultRecord) entries.push({
|
|
41
40
|
path: "agents.defaults",
|
|
42
41
|
record: defaultRecord
|
|
43
42
|
});
|
|
44
43
|
const agentId = readAgentIdFromSessionKey(params.sessionKey ?? params.sandboxSessionKey);
|
|
45
44
|
if (!agentId) return entries;
|
|
46
|
-
const agentCompaction =
|
|
45
|
+
const agentCompaction = readRecord((Array.isArray(params.config?.agents?.list) ? params.config.agents.list : []).find((agent) => {
|
|
47
46
|
return (typeof agent?.id === "string" ? agent.id.trim().toLowerCase() : "") === agentId;
|
|
48
47
|
}))?.compaction;
|
|
49
|
-
const agentRecord =
|
|
48
|
+
const agentRecord = readRecord(agentCompaction);
|
|
50
49
|
if (agentRecord) entries.push({
|
|
51
50
|
path: `agents.list.${agentId}`,
|
|
52
51
|
record: agentRecord,
|
|
@@ -60,6 +59,9 @@ function readAgentIdFromSessionKey(sessionKey) {
|
|
|
60
59
|
if (parts.length < 3 || parts[0] !== "agent") return;
|
|
61
60
|
return parts[1]?.trim() || void 0;
|
|
62
61
|
}
|
|
62
|
+
function readRecord(value) {
|
|
63
|
+
return value && typeof value === "object" && !Array.isArray(value) ? value : void 0;
|
|
64
|
+
}
|
|
63
65
|
async function compactCodexNativeThread(params, options = {}) {
|
|
64
66
|
if (params.trigger !== "manual") {
|
|
65
67
|
embeddedAgentLog.info("skipping codex app-server compaction for non-manual trigger", {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { l as resolveCodexAppServerRuntimeOptions, u as resolveCodexComputerUseConfig } from "./config-
|
|
2
|
-
import { i as describeControlFailure, t as requestCodexAppServerJson } from "./request-
|
|
1
|
+
import { l as resolveCodexAppServerRuntimeOptions, u as resolveCodexComputerUseConfig } from "./config-BW7NPdAQ.js";
|
|
2
|
+
import { i as describeControlFailure, t as requestCodexAppServerJson } from "./request-Cj95iOk6.js";
|
|
3
3
|
import { existsSync } from "node:fs";
|
|
4
4
|
//#region extensions/codex/src/app-server/computer-use.ts
|
|
5
5
|
var CodexComputerUseSetupError = class extends Error {
|
|
@@ -9,6 +9,7 @@ const START_OPTIONS_KEY_SECRET_SYMBOL = Symbol.for("openclaw.codexAppServerStart
|
|
|
9
9
|
const START_OPTIONS_KEY_SECRET = getStartOptionsKeySecret();
|
|
10
10
|
const UNIX_CODEX_REQUIREMENTS_PATH = "/etc/codex/requirements.toml";
|
|
11
11
|
const WINDOWS_CODEX_REQUIREMENTS_SUFFIX = "\\OpenAI\\Codex\\requirements.toml";
|
|
12
|
+
const PLAIN_DECIMAL_NUMBER_RE = /^[+-]?(?:(?:\d+\.?\d*)|(?:\.\d+))$/;
|
|
12
13
|
const CODEX_PLUGINS_MARKETPLACE_NAME = "openai-curated";
|
|
13
14
|
function shouldAutoApproveCodexAppServerApprovals(appServer) {
|
|
14
15
|
return appServer.approvalPolicy === "never" && appServer.sandbox === "danger-full-access";
|
|
@@ -159,6 +160,10 @@ function resolveCodexAppServerRuntimeOptions(params = {}) {
|
|
|
159
160
|
const policyMode = explicitPolicyMode ?? defaultPolicy?.mode ?? "yolo";
|
|
160
161
|
const serviceTier = normalizeCodexServiceTier(config.serviceTier);
|
|
161
162
|
if (transport === "websocket" && !url) throw new Error("plugins.entries.codex.config.appServer.url is required when appServer.transport is websocket");
|
|
163
|
+
const configApprovalPolicy = resolveApprovalPolicy(config.approvalPolicy);
|
|
164
|
+
const envApprovalPolicy = resolveApprovalPolicy(env.OPENCLAW_CODEX_APP_SERVER_APPROVAL_POLICY);
|
|
165
|
+
const approvalPolicy = configApprovalPolicy ?? envApprovalPolicy ?? defaultPolicy?.approvalPolicy ?? (policyMode === "guardian" ? "on-request" : "never");
|
|
166
|
+
const approvalPolicySource = configApprovalPolicy ? "config" : envApprovalPolicy ? "env" : defaultPolicy?.approvalPolicy ? "requirements" : "implicit";
|
|
162
167
|
return {
|
|
163
168
|
start: {
|
|
164
169
|
transport,
|
|
@@ -178,7 +183,8 @@ function resolveCodexAppServerRuntimeOptions(params = {}) {
|
|
|
178
183
|
requestTimeoutMs: normalizePositiveNumber(config.requestTimeoutMs, 6e4),
|
|
179
184
|
turnCompletionIdleTimeoutMs: normalizePositiveNumber(config.turnCompletionIdleTimeoutMs, 6e4),
|
|
180
185
|
...config.postToolRawAssistantCompletionIdleTimeoutMs !== void 0 ? { postToolRawAssistantCompletionIdleTimeoutMs: normalizePositiveNumber(config.postToolRawAssistantCompletionIdleTimeoutMs, 6e4) } : {},
|
|
181
|
-
approvalPolicy
|
|
186
|
+
approvalPolicy,
|
|
187
|
+
approvalPolicySource,
|
|
182
188
|
sandbox: resolveSandbox(config.sandbox) ?? resolveSandbox(env.OPENCLAW_CODEX_APP_SERVER_SANDBOX) ?? defaultPolicy?.sandbox ?? (policyMode === "guardian" ? "workspace-write" : "danger-full-access"),
|
|
183
189
|
approvalsReviewer: resolveApprovalsReviewer(config.approvalsReviewer) ?? defaultPolicy?.approvalsReviewer ?? (policyMode === "guardian" ? "auto_review" : "user"),
|
|
184
190
|
...serviceTier ? { serviceTier } : {}
|
|
@@ -481,8 +487,9 @@ function readBooleanEnv(value) {
|
|
|
481
487
|
].includes(normalized)) return false;
|
|
482
488
|
}
|
|
483
489
|
function readNumberEnv(value) {
|
|
484
|
-
|
|
485
|
-
|
|
490
|
+
const trimmed = value?.trim();
|
|
491
|
+
if (!trimmed || !PLAIN_DECIMAL_NUMBER_RE.test(trimmed)) return;
|
|
492
|
+
const parsed = Number(trimmed);
|
|
486
493
|
return Number.isFinite(parsed) ? parsed : void 0;
|
|
487
494
|
}
|
|
488
495
|
function resolveArgs(configArgs, envArgs) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { a as isCodexFastServiceTier, l as resolveCodexAppServerRuntimeOptions, r as codexSandboxPolicyForTurn } from "./config-
|
|
2
|
-
import { l as isJsonObject } from "./client-
|
|
3
|
-
import { t as CODEX_NATIVE_PERSONALITY_NONE } from "./thread-lifecycle-
|
|
4
|
-
import { i as readCodexAppServerBinding, n as isCodexAppServerNativeAuthProfile, o as writeCodexAppServerBinding, r as normalizeCodexAppServerBindingModelProvider, t as clearCodexAppServerBinding } from "./session-binding-
|
|
5
|
-
import { r as CODEX_CONTROL_METHODS } from "./request-
|
|
6
|
-
import { i as readCodexNotificationTurnId, r as readCodexNotificationThreadId, s as formatCodexDisplayText } from "./notification-correlation-
|
|
7
|
-
import { a as releaseLeasedSharedCodexAppServerClient, f as resolveCodexAppServerAuthProfileIdForAgent, i as getLeasedSharedCodexAppServerClient } from "./shared-client-
|
|
1
|
+
import { a as isCodexFastServiceTier, l as resolveCodexAppServerRuntimeOptions, r as codexSandboxPolicyForTurn } from "./config-BW7NPdAQ.js";
|
|
2
|
+
import { l as isJsonObject } from "./client-TfDda-h3.js";
|
|
3
|
+
import { t as CODEX_NATIVE_PERSONALITY_NONE } from "./thread-lifecycle-1u5ogKG_.js";
|
|
4
|
+
import { i as readCodexAppServerBinding, n as isCodexAppServerNativeAuthProfile, o as writeCodexAppServerBinding, r as normalizeCodexAppServerBindingModelProvider, t as clearCodexAppServerBinding } from "./session-binding-DuJisBZB.js";
|
|
5
|
+
import { r as CODEX_CONTROL_METHODS } from "./request-Cj95iOk6.js";
|
|
6
|
+
import { i as readCodexNotificationTurnId, r as readCodexNotificationThreadId, s as formatCodexDisplayText } from "./notification-correlation-BVB6XFQM.js";
|
|
7
|
+
import { a as releaseLeasedSharedCodexAppServerClient, f as resolveCodexAppServerAuthProfileIdForAgent, i as getLeasedSharedCodexAppServerClient } from "./shared-client-DICbgRn5.js";
|
|
8
8
|
import { n as resolveCodexNativeExecutionBlock, r as resolveCodexNativeSandboxBlock } from "./sandbox-guard-CTnEWuor.js";
|
|
9
9
|
import os from "node:os";
|
|
10
10
|
import { asOptionalRecord, isRecord, normalizeSingleOrTrimmedStringList } from "openclaw/plugin-sdk/string-coerce-runtime";
|
package/dist/harness.js
CHANGED
|
@@ -32,31 +32,31 @@ function createCodexAppServerAgentHarness(options) {
|
|
|
32
32
|
};
|
|
33
33
|
},
|
|
34
34
|
runAttempt: async (params) => {
|
|
35
|
-
const { runCodexAppServerAttempt } = await import("./run-attempt-
|
|
35
|
+
const { runCodexAppServerAttempt } = await import("./run-attempt-D9i99EqV.js");
|
|
36
36
|
return runCodexAppServerAttempt(params, {
|
|
37
37
|
pluginConfig: options?.resolvePluginConfig?.() ?? options?.pluginConfig,
|
|
38
38
|
nativeHookRelay: { enabled: true }
|
|
39
39
|
});
|
|
40
40
|
},
|
|
41
41
|
runSideQuestion: async (params) => {
|
|
42
|
-
const { runCodexAppServerSideQuestion } = await import("./side-question-
|
|
42
|
+
const { runCodexAppServerSideQuestion } = await import("./side-question-280VWjeH.js");
|
|
43
43
|
return runCodexAppServerSideQuestion(params, {
|
|
44
44
|
pluginConfig: options?.resolvePluginConfig?.() ?? options?.pluginConfig,
|
|
45
45
|
nativeHookRelay: { enabled: true }
|
|
46
46
|
});
|
|
47
47
|
},
|
|
48
48
|
compact: async (params) => {
|
|
49
|
-
const { maybeCompactCodexAppServerSession } = await import("./compact-
|
|
49
|
+
const { maybeCompactCodexAppServerSession } = await import("./compact-Dyz0rQLl.js");
|
|
50
50
|
return maybeCompactCodexAppServerSession(params, { pluginConfig: options?.resolvePluginConfig?.() ?? options?.pluginConfig });
|
|
51
51
|
},
|
|
52
52
|
reset: async (params) => {
|
|
53
53
|
if (params.sessionFile) {
|
|
54
|
-
const { clearCodexAppServerBinding } = await import("./session-binding-
|
|
54
|
+
const { clearCodexAppServerBinding } = await import("./session-binding-DuJisBZB.js").then((n) => n.a);
|
|
55
55
|
await clearCodexAppServerBinding(params.sessionFile);
|
|
56
56
|
}
|
|
57
57
|
},
|
|
58
58
|
dispose: async () => {
|
|
59
|
-
const { clearSharedCodexAppServerClientAndWait } = await import("./shared-client-
|
|
59
|
+
const { clearSharedCodexAppServerClientAndWait } = await import("./shared-client-DICbgRn5.js").then((n) => n.s);
|
|
60
60
|
await clearSharedCodexAppServerClientAndWait();
|
|
61
61
|
}
|
|
62
62
|
};
|
package/dist/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { createCodexAppServerAgentHarness } from "./harness.js";
|
|
2
|
-
import { c as readCodexPluginConfig, l as resolveCodexAppServerRuntimeOptions, t as CODEX_PLUGINS_MARKETPLACE_NAME } from "./config-
|
|
2
|
+
import { c as readCodexPluginConfig, l as resolveCodexAppServerRuntimeOptions, t as CODEX_PLUGINS_MARKETPLACE_NAME } from "./config-BW7NPdAQ.js";
|
|
3
3
|
import { buildCodexProvider } from "./provider.js";
|
|
4
|
-
import {
|
|
4
|
+
import { v as ensureCodexPluginActivation, x as defaultCodexAppInventoryCache, y as pluginReadParams } from "./thread-lifecycle-1u5ogKG_.js";
|
|
5
5
|
import { buildCodexMediaUnderstandingProvider } from "./media-understanding-provider.js";
|
|
6
|
-
import { i as describeControlFailure, n as buildCodexPluginAppCacheKey, t as requestCodexAppServerJson } from "./request-
|
|
7
|
-
import { s as formatCodexDisplayText } from "./notification-correlation-
|
|
8
|
-
import { a as releaseLeasedSharedCodexAppServerClient, f as resolveCodexAppServerAuthProfileIdForAgent, i as getLeasedSharedCodexAppServerClient, n as clearSharedCodexAppServerClientIfCurrentAndWait, p as resolveCodexAppServerFallbackApiKeyCacheKey, u as resolveCodexAppServerAuthAccountCacheKey } from "./shared-client-
|
|
9
|
-
import { a as createCodexCliSessionNodeInvokePolicies, c as resolveCodexCliSessionForBindingOnNode, i as createCodexCliSessionNodeHostCommands, l as resumeCodexCliSessionOnNode, n as handleCodexConversationInboundClaim, s as listCodexCliSessionsOnNode, t as handleCodexConversationBindingResolved } from "./conversation-binding-
|
|
6
|
+
import { i as describeControlFailure, n as buildCodexPluginAppCacheKey, t as requestCodexAppServerJson } from "./request-Cj95iOk6.js";
|
|
7
|
+
import { s as formatCodexDisplayText } from "./notification-correlation-BVB6XFQM.js";
|
|
8
|
+
import { a as releaseLeasedSharedCodexAppServerClient, f as resolveCodexAppServerAuthProfileIdForAgent, i as getLeasedSharedCodexAppServerClient, n as clearSharedCodexAppServerClientIfCurrentAndWait, p as resolveCodexAppServerFallbackApiKeyCacheKey, u as resolveCodexAppServerAuthAccountCacheKey } from "./shared-client-DICbgRn5.js";
|
|
9
|
+
import { a as createCodexCliSessionNodeInvokePolicies, c as resolveCodexCliSessionForBindingOnNode, i as createCodexCliSessionNodeHostCommands, l as resumeCodexCliSessionOnNode, n as handleCodexConversationInboundClaim, s as listCodexCliSessionsOnNode, t as handleCodexConversationBindingResolved } from "./conversation-binding-D8OO0S9R.js";
|
|
10
10
|
import { mutateConfigFile } from "openclaw/plugin-sdk/config-mutation";
|
|
11
11
|
import { resolveLivePluginConfigObject } from "openclaw/plugin-sdk/plugin-config-runtime";
|
|
12
12
|
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
|
@@ -18,6 +18,7 @@ import { loadAuthProfileStoreWithoutExternalProfiles, resolveAgentConfig, resolv
|
|
|
18
18
|
import { pathExists } from "openclaw/plugin-sdk/security-runtime";
|
|
19
19
|
import { MIGRATION_REASON_TARGET_EXISTS, applyMigrationManualItem, createMigrationItem, createMigrationManualItem, hasMigrationConfigPatchConflict, markMigrationItemConflict, markMigrationItemError, markMigrationItemSkipped, readMigrationConfigPath, summarizeMigrationItems, writeMigrationConfigPath } from "openclaw/plugin-sdk/migration";
|
|
20
20
|
import { archiveMigrationItem, copyMigrationFileItem, withCachedMigrationConfigRuntime, writeMigrationReport } from "openclaw/plugin-sdk/migration-runtime";
|
|
21
|
+
import { parseStrictNonNegativeInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
21
22
|
import { applyAuthProfileConfig, buildApiKeyCredential, buildOauthProviderAuthResult, readCodexCliCredentialsCached, updateAuthProfileStoreWithLock } from "openclaw/plugin-sdk/provider-auth";
|
|
22
23
|
import { readJsonFileWithFallback } from "openclaw/plugin-sdk/json-store";
|
|
23
24
|
//#region extensions/codex/src/commands.ts
|
|
@@ -28,10 +29,10 @@ function createCodexCommand(options) {
|
|
|
28
29
|
ownership: "reserved",
|
|
29
30
|
agentPromptGuidance: [{
|
|
30
31
|
text: "Native Codex app-server plugin is available (`/codex ...`). For Codex bind/control/thread/resume/steer/stop requests, prefer `/codex bind`, `/codex threads`, `/codex resume`, `/codex steer`, and `/codex stop` over ACP. When OpenClaw sandboxing is active, native Codex execution modes are unavailable; use normal Codex harness turns.",
|
|
31
|
-
surfaces: ["
|
|
32
|
+
surfaces: ["openclaw_main"]
|
|
32
33
|
}, {
|
|
33
34
|
text: "Use ACP for Codex only when the user explicitly asks for ACP/acpx or wants to test the ACP path.",
|
|
34
|
-
surfaces: ["
|
|
35
|
+
surfaces: ["openclaw_main"]
|
|
35
36
|
}],
|
|
36
37
|
acceptsArgs: true,
|
|
37
38
|
requireAuth: true,
|
|
@@ -47,7 +48,7 @@ async function handleCodexCommand(ctx, options = {}) {
|
|
|
47
48
|
}
|
|
48
49
|
}
|
|
49
50
|
async function loadDefaultCodexSubcommandHandler() {
|
|
50
|
-
const { handleCodexSubcommand } = await import("./command-handlers-
|
|
51
|
+
const { handleCodexSubcommand } = await import("./command-handlers-B8MXR7fh.js");
|
|
51
52
|
return handleCodexSubcommand;
|
|
52
53
|
}
|
|
53
54
|
//#endregion
|
|
@@ -1382,9 +1383,9 @@ function hasOpenAiCuratedMarketplace(response) {
|
|
|
1382
1383
|
const marketplaces = response.marketplaces;
|
|
1383
1384
|
return Array.isArray(marketplaces) && marketplaces.some((marketplace) => marketplace && typeof marketplace === "object" && marketplace.name === "openai-curated");
|
|
1384
1385
|
}
|
|
1385
|
-
function targetCodexMarketplaceDiscoveryTimeoutMs() {
|
|
1386
|
-
const configured =
|
|
1387
|
-
if (
|
|
1386
|
+
function targetCodexMarketplaceDiscoveryTimeoutMs(env = process.env) {
|
|
1387
|
+
const configured = parseStrictNonNegativeInteger(env[TARGET_CODEX_MARKETPLACE_DISCOVERY_TIMEOUT_ENV]);
|
|
1388
|
+
if (configured !== void 0) return configured;
|
|
1388
1389
|
return TARGET_CODEX_MARKETPLACE_DISCOVERY_TIMEOUT_MS;
|
|
1389
1390
|
}
|
|
1390
1391
|
function isCodexPluginLoadWarningItem(item) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { CODEX_PROVIDER_ID, FALLBACK_CODEX_MODELS } from "./provider-catalog.js";
|
|
2
|
-
import "./client-factory-
|
|
3
|
-
import { l as resolveCodexAppServerRuntimeOptions } from "./config-
|
|
2
|
+
import "./client-factory-BPBvbguy.js";
|
|
3
|
+
import { l as resolveCodexAppServerRuntimeOptions } from "./config-BW7NPdAQ.js";
|
|
4
4
|
import { i as assertCodexTurnStartResponse, l as readCodexTurnCompletedNotification, o as readCodexErrorNotification, r as assertCodexThreadStartResponse } from "./protocol-validators-DtjYmUw_.js";
|
|
5
|
-
import { i as readModelListResult } from "./models-
|
|
6
|
-
import { l as isJsonObject } from "./client-
|
|
7
|
-
import { r as buildCodexRuntimeThreadConfig } from "./thread-lifecycle-
|
|
5
|
+
import { i as readModelListResult } from "./models-Dnasi6LR.js";
|
|
6
|
+
import { l as isJsonObject } from "./client-TfDda-h3.js";
|
|
7
|
+
import { r as buildCodexRuntimeThreadConfig } from "./thread-lifecycle-1u5ogKG_.js";
|
|
8
8
|
import { validateJsonSchemaValue } from "openclaw/plugin-sdk/json-schema-runtime";
|
|
9
9
|
import "openclaw/plugin-sdk/media-understanding";
|
|
10
10
|
//#region extensions/codex/media-understanding-provider.ts
|
|
@@ -65,7 +65,7 @@ async function runBoundedCodexVisionTurn(params) {
|
|
|
65
65
|
const appServer = resolveCodexAppServerRuntimeOptions({ pluginConfig: params.options.pluginConfig });
|
|
66
66
|
const timeoutMs = Math.max(100, params.timeoutMs);
|
|
67
67
|
const ownsClient = !params.options.clientFactory;
|
|
68
|
-
const client = params.options.clientFactory ? await params.options.clientFactory(appServer.start, params.profile) : await import("./shared-client-
|
|
68
|
+
const client = params.options.clientFactory ? await params.options.clientFactory(appServer.start, params.profile) : await import("./shared-client-DICbgRn5.js").then((n) => n.s).then(({ createIsolatedCodexAppServerClient }) => createIsolatedCodexAppServerClient({
|
|
69
69
|
startOptions: appServer.start,
|
|
70
70
|
timeoutMs,
|
|
71
71
|
authProfileId: params.profile
|
|
@@ -40,7 +40,7 @@ async function listAllCodexAppServerModels(options = {}) {
|
|
|
40
40
|
async function withCodexAppServerModelClient(options, run) {
|
|
41
41
|
const timeoutMs = options.timeoutMs ?? 2500;
|
|
42
42
|
const useSharedClient = options.sharedClient !== false;
|
|
43
|
-
const { createIsolatedCodexAppServerClient, getLeasedSharedCodexAppServerClient, releaseLeasedSharedCodexAppServerClient } = await import("./shared-client-
|
|
43
|
+
const { createIsolatedCodexAppServerClient, getLeasedSharedCodexAppServerClient, releaseLeasedSharedCodexAppServerClient } = await import("./shared-client-DICbgRn5.js").then((n) => n.s);
|
|
44
44
|
const client = useSharedClient ? await getLeasedSharedCodexAppServerClient({
|
|
45
45
|
startOptions: options.startOptions,
|
|
46
46
|
timeoutMs,
|