refactor: rename to openclaw

This commit is contained in:
Peter Steinberger
2026-01-30 03:15:10 +01:00
parent 4583f88626
commit 9a7160786a
2357 changed files with 16688 additions and 16788 deletions

View File

@@ -6,7 +6,7 @@ import type {
ChannelMessageActionName,
ChannelPlugin,
} from "../channels/plugins/types.js";
import type { MoltbotConfig } from "../config/config.js";
import type { OpenClawConfig } from "../config/config.js";
import { defaultRuntime } from "../runtime.js";
/**
@@ -14,13 +14,13 @@ import { defaultRuntime } from "../runtime.js";
* Returns an empty array if channel is not found or has no actions configured.
*/
export function listChannelSupportedActions(params: {
cfg?: MoltbotConfig;
cfg?: OpenClawConfig;
channel?: string;
}): ChannelMessageActionName[] {
if (!params.channel) return [];
const plugin = getChannelPlugin(params.channel as Parameters<typeof getChannelPlugin>[0]);
if (!plugin?.actions?.listActions) return [];
const cfg = params.cfg ?? ({} as MoltbotConfig);
const cfg = params.cfg ?? ({} as OpenClawConfig);
return runPluginListActions(plugin, cfg);
}
@@ -28,12 +28,12 @@ export function listChannelSupportedActions(params: {
* Get the list of all supported message actions across all configured channels.
*/
export function listAllChannelSupportedActions(params: {
cfg?: MoltbotConfig;
cfg?: OpenClawConfig;
}): ChannelMessageActionName[] {
const actions = new Set<ChannelMessageActionName>();
for (const plugin of listChannelPlugins()) {
if (!plugin.actions?.listActions) continue;
const cfg = params.cfg ?? ({} as MoltbotConfig);
const cfg = params.cfg ?? ({} as OpenClawConfig);
const channelActions = runPluginListActions(plugin, cfg);
for (const action of channelActions) {
actions.add(action);
@@ -42,7 +42,7 @@ export function listAllChannelSupportedActions(params: {
return Array.from(actions);
}
export function listChannelAgentTools(params: { cfg?: MoltbotConfig }): ChannelAgentTool[] {
export function listChannelAgentTools(params: { cfg?: OpenClawConfig }): ChannelAgentTool[] {
// Channel docking: aggregate channel-owned tools (login, etc.).
const tools: ChannelAgentTool[] = [];
for (const plugin of listChannelPlugins()) {
@@ -55,7 +55,7 @@ export function listChannelAgentTools(params: { cfg?: MoltbotConfig }): ChannelA
}
export function resolveChannelMessageToolHints(params: {
cfg?: MoltbotConfig;
cfg?: OpenClawConfig;
channel?: string | null;
accountId?: string | null;
}): string[] {
@@ -64,7 +64,7 @@ export function resolveChannelMessageToolHints(params: {
const dock = getChannelDock(channelId);
const resolve = dock?.agentPrompt?.messageToolHints;
if (!resolve) return [];
const cfg = params.cfg ?? ({} as MoltbotConfig);
const cfg = params.cfg ?? ({} as OpenClawConfig);
return (resolve({ cfg, accountId: params.accountId }) ?? [])
.map((entry) => entry.trim())
.filter(Boolean);
@@ -74,7 +74,7 @@ const loggedListActionErrors = new Set<string>();
function runPluginListActions(
plugin: ChannelPlugin,
cfg: MoltbotConfig,
cfg: OpenClawConfig,
): ChannelMessageActionName[] {
if (!plugin.actions?.listActions) return [];
try {