mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 11:30:44 +00:00
* feat(codex): add native plugin config schema * feat(codex): add native plugin inventory activation * feat(codex): configure native plugin apps for threads * feat(codex): enforce plugin elicitation policy * feat(codex): migrate native plugins * docs(codex): document native plugin support * fix(codex): harden plugin migration refresh * fix(codex): satisfy plugin activation lint * fix: stabilize codex plugin app config * fix: address codex plugin review feedback * fix: key codex plugin app cache by websocket credentials * fix: keep codex plugin app fingerprints stable * fix: refresh codex plugin cache test fixtures * fix: refresh plugin app readiness after activation * fix: support remote codex plugin activation * fix: recover plugin app bindings after cache refresh * fix: force codex app refresh after plugin activation * fix: recover partial codex plugin app bindings * fix: sync codex plugin selection config * fix: keep codex plugin activation fail closed * fix: align codex plugin protocol types with main * fix: refresh partial codex plugin app bindings * fix: key codex app cache by env api key * fix: skip failed codex plugin migration config * test: update codex prompt snapshots * fix: fail closed on missing codex app inventory entries * fix(codex): enforce native plugin policy gates * fix(codex): normalize native plugin policy types * fix(codex): fail closed on plugin refresh errors * fix(codex): use native plugin destructive policy * fix(codex): key plugin cache by api-key profiles * fix(codex): drop unshipped plugin fingerprint compat * fix(codex): let native app policy gate plugin tools * fix(codex): allow open-world plugin app tools * fix(codex): revalidate native plugin app bindings * fix(codex): preserve plugin binding on recheck failure * docs(codex): clarify plugin harness scope * fix(codex): return activation report state exhaustively * test(codex): refresh prompt snapshots after rebase * fix(codex): match namespaced plugin ids
42 lines
1.9 KiB
TypeScript
42 lines
1.9 KiB
TypeScript
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-types";
|
|
import { resolveLivePluginConfigObject } from "openclaw/plugin-sdk/plugin-config-runtime";
|
|
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
|
import { createCodexAppServerAgentHarness } from "./harness.js";
|
|
import { buildCodexMediaUnderstandingProvider } from "./media-understanding-provider.js";
|
|
import { buildCodexProvider } from "./provider.js";
|
|
import { createCodexCommand } from "./src/commands.js";
|
|
import {
|
|
handleCodexConversationBindingResolved,
|
|
handleCodexConversationInboundClaim,
|
|
} from "./src/conversation-binding.js";
|
|
import { buildCodexMigrationProvider } from "./src/migration/provider.js";
|
|
|
|
export default definePluginEntry({
|
|
id: "codex",
|
|
name: "Codex",
|
|
description: "Codex app-server harness and Codex-managed GPT model catalog.",
|
|
register(api) {
|
|
const resolveCurrentPluginConfig = () =>
|
|
resolveLivePluginConfigObject(
|
|
api.runtime.config?.current
|
|
? () => api.runtime.config.current() as OpenClawConfig
|
|
: undefined,
|
|
"codex",
|
|
api.pluginConfig as Record<string, unknown>,
|
|
) ?? api.pluginConfig;
|
|
api.registerAgentHarness(createCodexAppServerAgentHarness({ pluginConfig: api.pluginConfig }));
|
|
api.registerProvider(buildCodexProvider({ pluginConfig: api.pluginConfig }));
|
|
api.registerMediaUnderstandingProvider(
|
|
buildCodexMediaUnderstandingProvider({ pluginConfig: api.pluginConfig }),
|
|
);
|
|
api.registerMigrationProvider(buildCodexMigrationProvider({ runtime: api.runtime }));
|
|
api.registerCommand(createCodexCommand({ pluginConfig: api.pluginConfig }));
|
|
api.on("inbound_claim", (event, ctx) =>
|
|
handleCodexConversationInboundClaim(event, ctx, {
|
|
pluginConfig: resolveCurrentPluginConfig(),
|
|
}),
|
|
);
|
|
api.onConversationBindingResolved?.(handleCodexConversationBindingResolved);
|
|
},
|
|
});
|