refactor: consolidate plugin sdk surface

This commit is contained in:
Peter Steinberger
2026-03-20 18:50:25 +00:00
parent 46854a84a4
commit 62ddc9d9e0
294 changed files with 2071 additions and 1268 deletions

View File

@@ -1,6 +1,83 @@
import type { OpenClawConfig } from "../config/config.js";
import { resolveDmGroupAccessWithLists } from "../security/dm-policy-shared.js";
export {
hasControlCommand,
hasInlineCommandTokens,
isControlCommandMessage,
shouldComputeCommandAuthorized,
} from "../auto-reply/command-detection.js";
export {
buildCommandText,
buildCommandTextFromArgs,
findCommandByNativeName,
getCommandDetection,
isCommandEnabled,
isCommandMessage,
isNativeCommandSurface,
listChatCommands,
listChatCommandsForConfig,
listNativeCommandSpecs,
listNativeCommandSpecsForConfig,
maybeResolveTextAlias,
normalizeCommandBody,
parseCommandArgs,
resolveCommandArgChoices,
resolveCommandArgMenu,
resolveTextCommand,
serializeCommandArgs,
shouldHandleTextCommands,
} from "../auto-reply/commands-registry.js";
export type {
ChatCommandDefinition,
CommandArgChoiceContext,
CommandArgDefinition,
CommandArgMenuSpec,
CommandArgValues,
CommandArgs,
CommandDetection,
CommandNormalizeOptions,
CommandScope,
NativeCommandSpec,
ResolvedCommandArgChoice,
ShouldHandleTextCommandsParams,
} from "../auto-reply/commands-registry.js";
export {
resolveCommandAuthorizedFromAuthorizers,
resolveControlCommandGate,
resolveDualTextControlCommandGate,
type CommandAuthorizer,
type CommandGatingModeWhenAccessGroupsOff,
} from "../channels/command-gating.js";
export {
resolveNativeCommandSessionTargets,
type ResolveNativeCommandSessionTargetsParams,
} from "../channels/native-command-session-targets.js";
export {
resolveCommandAuthorization,
type CommandAuthorization,
} from "../auto-reply/command-auth.js";
export {
listReservedChatSlashCommandNames,
listSkillCommandsForAgents,
listSkillCommandsForWorkspace,
resolveSkillCommandInvocation,
} from "../auto-reply/skill-commands.js";
export { buildCommandsPaginationKeyboard } from "../auto-reply/reply/commands-info.js";
export {
buildModelsProviderData,
formatModelsAvailableHeader,
resolveModelsCommandReply,
} from "../auto-reply/reply/commands-models.js";
export type { ModelsProviderData } from "../auto-reply/reply/commands-models.js";
export { resolveStoredModelOverride } from "../auto-reply/reply/model-selection.js";
export type { StoredModelOverride } from "../auto-reply/reply/model-selection.js";
export {
buildCommandsMessage,
buildCommandsMessagePaginated,
buildHelpMessage,
} from "../auto-reply/status.js";
export type ResolveSenderCommandAuthorizationParams = {
cfg: OpenClawConfig;
rawBody: string;