@openclaw/acpx 2026.9.4 → 2026.9.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/activity.svg +3 -0
- package/assets/icon.png +0 -0
- package/dist/{config-D2FTk0K7.js → .setup/config-DvCm0_Dp.mjs} +37 -2
- package/dist/{pi-session-catalog-runtime-BrPX6xQV.js → .setup/pi-session-catalog-runtime-CbLyvshh.mjs} +2 -2
- package/dist/{register.runtime-CksaMeEx.js → .setup/register.runtime-CTfxhkFm.mjs} +4 -1
- package/dist/{runtime-CSNBTQIs.js → .setup/runtime-Du-YvDnr.mjs} +533 -402
- package/dist/{service-BAf6nuci.js → .setup/service-DZYyo6-7.mjs} +14 -8
- package/dist/{session-owner-migration-D36AH9RC.js → .setup/session-owner-migration-BuKHYP6F.mjs} +4 -4
- package/dist/{session-resource-UWe7qD3m.js → .setup/session-resource-Dzl0U7kK.mjs} +2 -2
- package/dist/doctor-contract-api.js +3 -3
- package/dist/index.js +4 -28
- package/dist/register.runtime.js +1 -1
- package/openclaw.plugin.json +27 -1
- package/package.json +10 -8
- package/skills/acp-router/SKILL.md +2 -2
- package/dist/config-schema-DN_uAi4R.js +0 -37
- /package/dist/{pi-session-paths-EMbd4Hkz.js → .setup/pi-session-paths-EMbd4Hkz.mjs} +0 -0
- /package/dist/{process-lease-B83BGiLj.js → .setup/process-lease-B83BGiLj.mjs} +0 -0
- /package/dist/{rolldown-runtime-8H4AJuhK.js → .setup/rolldown-runtime-8H4AJuhK.mjs} +0 -0
package/assets/icon.png
ADDED
|
Binary file
|
|
@@ -1,11 +1,46 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { _ as splitCommandParts } from "./process-lease-B83BGiLj.js";
|
|
1
|
+
import { _ as splitCommandParts } from "./process-lease-B83BGiLj.mjs";
|
|
3
2
|
import { createRequire } from "node:module";
|
|
4
3
|
import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
5
4
|
import fs from "node:fs";
|
|
6
5
|
import path from "node:path";
|
|
7
6
|
import { fileURLToPath } from "node:url";
|
|
8
7
|
import { formatPluginConfigIssue } from "openclaw/plugin-sdk/extension-shared";
|
|
8
|
+
import { z } from "zod";
|
|
9
|
+
//#region extensions/acpx/src/config-schema.ts
|
|
10
|
+
/**
|
|
11
|
+
* ACPX plugin configuration schema and public config types. Runtime setup uses
|
|
12
|
+
* this file as the single source of truth for validation and defaulting.
|
|
13
|
+
*/
|
|
14
|
+
const ACPX_PERMISSION_MODES = [
|
|
15
|
+
"approve-all",
|
|
16
|
+
"approve-reads",
|
|
17
|
+
"deny-all"
|
|
18
|
+
];
|
|
19
|
+
const ACPX_NON_INTERACTIVE_POLICIES = ["deny", "fail"];
|
|
20
|
+
const nonEmptyTrimmedString = (message) => z.string({ error: message }).trim().min(1, { error: message });
|
|
21
|
+
const McpServerConfigSchema = z.object({
|
|
22
|
+
command: nonEmptyTrimmedString("command must be a non-empty string").describe("Command to run the MCP server"),
|
|
23
|
+
args: z.array(z.string({ error: "args must be an array of strings" }), { error: "args must be an array of strings" }).optional().describe("Arguments to pass to the command"),
|
|
24
|
+
env: z.record(z.string(), z.string({ error: "env values must be strings" }), { error: "env must be an object of strings" }).optional().describe("Environment variables for the MCP server")
|
|
25
|
+
});
|
|
26
|
+
/** Zod schema for validating raw ACPX plugin config from OpenClaw config. */
|
|
27
|
+
const AcpxPluginConfigSchema = z.strictObject({
|
|
28
|
+
cwd: nonEmptyTrimmedString("cwd must be a non-empty string").optional(),
|
|
29
|
+
stateDir: nonEmptyTrimmedString("stateDir must be a non-empty string").optional(),
|
|
30
|
+
probeAgent: nonEmptyTrimmedString("probeAgent must be a non-empty string").optional(),
|
|
31
|
+
permissionMode: z.enum(ACPX_PERMISSION_MODES, { error: `permissionMode must be one of: ${ACPX_PERMISSION_MODES.join(", ")}` }).optional(),
|
|
32
|
+
nonInteractivePermissions: z.enum(ACPX_NON_INTERACTIVE_POLICIES, { error: `nonInteractivePermissions must be one of: ${ACPX_NON_INTERACTIVE_POLICIES.join(", ")}` }).optional(),
|
|
33
|
+
pluginToolsMcpBridge: z.boolean({ error: "pluginToolsMcpBridge must be a boolean" }).optional(),
|
|
34
|
+
openClawToolsMcpBridge: z.boolean({ error: "openClawToolsMcpBridge must be a boolean" }).optional(),
|
|
35
|
+
timeoutSeconds: z.number({ error: "timeoutSeconds must be a number >= 0.001" }).min(.001, { error: "timeoutSeconds must be a number >= 0.001" }).default(120),
|
|
36
|
+
piSessionCatalog: z.strictObject({ enabled: z.boolean({ error: "piSessionCatalog.enabled must be a boolean" }).default(true) }).optional(),
|
|
37
|
+
mcpServers: z.record(z.string(), McpServerConfigSchema).optional(),
|
|
38
|
+
agents: z.record(z.string(), z.strictObject({
|
|
39
|
+
command: nonEmptyTrimmedString("agents.<id>.command must be a non-empty string"),
|
|
40
|
+
args: z.array(z.string({ error: "args must be an array of strings" })).optional()
|
|
41
|
+
})).optional()
|
|
42
|
+
});
|
|
43
|
+
//#endregion
|
|
9
44
|
//#region extensions/acpx/src/config.ts
|
|
10
45
|
/**
|
|
11
46
|
* Resolves ACPX plugin config from raw user configuration. It locates the
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { c as PI_SESSION_READ_COMMAND, i as PI_LOCAL_SESSION_HOST_ID, l as PI_TERMINAL_RESUME_COMMAND, n as piSessionStore, o as PI_SESSIONS_LIST_COMMAND, r as piSessionStoreAvailable, s as PI_SESSION_ID_PATTERN, t as piAcpSessionStoreRoot } from "./pi-session-paths-EMbd4Hkz.
|
|
2
|
-
import { parseDateFirstTimestampMs } from "openclaw/plugin-sdk/number-runtime";
|
|
1
|
+
import { c as PI_SESSION_READ_COMMAND, i as PI_LOCAL_SESSION_HOST_ID, l as PI_TERMINAL_RESUME_COMMAND, n as piSessionStore, o as PI_SESSIONS_LIST_COMMAND, r as piSessionStoreAvailable, s as PI_SESSION_ID_PATTERN, t as piAcpSessionStoreRoot } from "./pi-session-paths-EMbd4Hkz.mjs";
|
|
3
2
|
import { resolveNodeHostExecutable } from "openclaw/plugin-sdk/node-host";
|
|
4
3
|
import { createSessionCatalogFamily, importSessionCatalogHistory, isExternalUserText, listAdoptedSessionCatalogSessions, sessionCatalogAdoptedSessionKey } from "openclaw/plugin-sdk/session-catalog";
|
|
5
4
|
import { isRecord, normalizeBoundedOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -13,6 +12,7 @@ import { sessionCatalogPaging } from "openclaw/plugin-sdk/session-catalog-paging
|
|
|
13
12
|
import { truncateUtf16Safe } from "openclaw/plugin-sdk/text-utility-runtime";
|
|
14
13
|
import { runTasksWithConcurrency } from "openclaw/plugin-sdk/concurrency-runtime";
|
|
15
14
|
import { isPathStrictlyInside, readFileRangeAsync } from "openclaw/plugin-sdk/file-access-runtime";
|
|
15
|
+
import { parseDateFirstTimestampMs } from "openclaw/plugin-sdk/number-runtime";
|
|
16
16
|
//#region extensions/acpx/src/pi-session-timestamp.ts
|
|
17
17
|
/** Preserve Pi JSONL's date-first string contract while accepting numeric millisecond values. */
|
|
18
18
|
function parsePiSessionTimestampMs(value) {
|
|
@@ -25,6 +25,9 @@ function lazyStartRuntimeTurn(resolveRuntime, input) {
|
|
|
25
25
|
function createLazyAcpRuntimeProxy(resolveRuntime) {
|
|
26
26
|
return {
|
|
27
27
|
ownerAwareSessions: 1,
|
|
28
|
+
async shutdown() {
|
|
29
|
+
await (await resolveRuntime()).shutdown();
|
|
30
|
+
},
|
|
28
31
|
async ensureSession(input) {
|
|
29
32
|
return await (await resolveRuntime()).ensureSession(input);
|
|
30
33
|
},
|
|
@@ -67,7 +70,7 @@ function createLazyAcpRuntimeProxy(resolveRuntime) {
|
|
|
67
70
|
* immediately, then imports the heavier service only when a session needs it.
|
|
68
71
|
*/
|
|
69
72
|
const ACPX_BACKEND_ID = "acpx";
|
|
70
|
-
const loadServiceModule = createLazyRuntimeModule(() => import("./service-
|
|
73
|
+
const loadServiceModule = createLazyRuntimeModule(() => import("./service-DZYyo6-7.mjs").then((n) => n.t));
|
|
71
74
|
function unregisterOwnedRuntime(runtime) {
|
|
72
75
|
if (runtime && getAcpRuntimeBackend(ACPX_BACKEND_ID)?.runtime === runtime) unregisterAcpRuntimeBackend(ACPX_BACKEND_ID);
|
|
73
76
|
}
|