fix(extensions): split account config type seams

This commit is contained in:
Vincent Koc
2026-04-10 07:30:03 +01:00
parent 1c78822a1f
commit 6784cc692c
7 changed files with 17 additions and 14 deletions

View File

@@ -1,5 +1,3 @@
import type { OpenClawConfig as RuntimeApiOpenClawConfig } from "openclaw/plugin-sdk/core";
export {
DEFAULT_ACCOUNT_ID,
getChatChannelMeta,
@@ -31,8 +29,4 @@ export type { IMessageProbe } from "./src/probe.js";
export { sendMessageIMessage } from "./src/send.js";
export { setIMessageRuntime } from "./src/runtime.js";
export { chunkTextForOutbound } from "./src/channel-api.js";
export type IMessageAccountConfig = Omit<
NonNullable<NonNullable<RuntimeApiOpenClawConfig["channels"]>["imessage"]>,
"accounts" | "defaultAccount"
>;
export type { IMessageAccountConfig } from "./src/account-types.js";

View File

@@ -0,0 +1,6 @@
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-runtime";
export type IMessageAccountConfig = Omit<
NonNullable<NonNullable<OpenClawConfig["channels"]>["imessage"]>,
"accounts" | "defaultAccount"
>;

View File

@@ -5,7 +5,7 @@ import {
type OpenClawConfig,
} from "openclaw/plugin-sdk/account-resolution";
import { normalizeOptionalString } from "openclaw/plugin-sdk/text-runtime";
import type { IMessageAccountConfig } from "../runtime-api.js";
import type { IMessageAccountConfig } from "./account-types.js";
export type ResolvedIMessageAccount = {
accountId: string;

View File

@@ -1,5 +1,5 @@
import type { ReplyPayload } from "openclaw/plugin-sdk/reply-runtime";
import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/text-runtime";
import type { ReplyPayload } from "../runtime-api.js";
import {
createAgendaCard,
createAppleTvRemoteCard,

View File

@@ -0,0 +1,6 @@
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-runtime";
export type SignalAccountConfig = Omit<
Exclude<NonNullable<OpenClawConfig["channels"]>["signal"], undefined>,
"accounts"
>;

View File

@@ -5,7 +5,7 @@ import {
type OpenClawConfig,
} from "openclaw/plugin-sdk/account-resolution";
import { normalizeOptionalString } from "openclaw/plugin-sdk/text-runtime";
import type { SignalAccountConfig } from "./runtime-api.js";
import type { SignalAccountConfig } from "./account-types.js";
export type ResolvedSignalAccount = {
accountId: string;

View File

@@ -49,7 +49,4 @@ export { removeReactionSignal, sendReactionSignal } from "./send-reactions.js";
export { sendMessageSignal } from "./send.js";
export { signalMessageActions } from "./message-actions.js";
export type { ResolvedSignalAccount } from "./accounts.js";
export type SignalAccountConfig = Omit<
Exclude<NonNullable<RuntimeOpenClawConfig["channels"]>["signal"], undefined>,
"accounts"
>;
export type { SignalAccountConfig } from "./account-types.js";