import { r as KlawConfig } from "../../types.klaw-xKUw_Rz7.js"; import { t as DEFAULT_ACCOUNT_ID } from "../../account-id-CVLVRlKQ.js"; import { E as resolveChannelMediaMaxBytes } from "../../media-runtime-B9hAmRsC.js"; import { n as RuntimeEnv } from "../../runtime-BPmgxFyD.js"; import { N as MessageReceipt } from "../../types-CPrjYzuc.js"; import { y as ChannelMessageActionAdapter } from "../../types.core-BSyOg0vX.js"; import { n as ChannelPlugin } from "../../types.public-BSMobFik.js"; import { n as PluginRuntime } from "../../types-yybOtwsl.js"; import { r as buildChannelConfigSchema } from "../../config-schema-DMh8Tifh.js"; import { d as getChatChannelMeta } from "../../core-Due-k0ZL.js"; import { t as PAIRING_APPROVED_MESSAGE } from "../../pairing-message-DURX64z_.js"; import { c as collectStatusIssuesFromLastError, r as buildComputedAccountStatusSnapshot } from "../../status-helpers-CfDgvxsn.js"; import { i as IMessageConfigSchema } from "../../bundled-channel-config-schema-IgHPvQmp.js"; import { g as formatTrimmedAllowFromEntries } from "../../channel-config-helpers-BipAUHMQ.js"; import { t as chunkTextForOutbound } from "../../text-chunking-CZXnONdJ.js"; import { a as looksLikeIMessageTargetId, o as normalizeIMessageMessagingTarget, r as probeIMessage, s as ResolvedIMessageAccount, t as IMessageProbe } from "../../probe-C4IS30Om.js"; import { d as resolveIMessageGroupRequireMention, f as resolveIMessageGroupToolPolicy, n as IMessageService } from "../../targets-Bd0EYy3T.js"; //#region extensions/imessage/src/config-accessors.d.ts declare function resolveIMessageConfigAllowFrom(params: { cfg: KlawConfig; accountId?: string | null; }): string[]; declare function resolveIMessageConfigDefaultTo(params: { cfg: KlawConfig; accountId?: string | null; }): string | undefined; //#endregion //#region extensions/imessage/src/monitor/types.d.ts type MonitorIMessageOpts = { runtime?: RuntimeEnv; abortSignal?: AbortSignal; cliPath?: string; dbPath?: string; accountId?: string; config?: KlawConfig; allowFrom?: Array; groupAllowFrom?: Array; includeAttachments?: boolean; mediaMaxMb?: number; requireMention?: boolean; }; //#endregion //#region extensions/imessage/src/monitor/monitor-provider.d.ts declare function monitorIMessageProvider(opts?: MonitorIMessageOpts): Promise; //#endregion //#region extensions/imessage/src/client.d.ts type IMessageRpcNotification = { method: string; params?: unknown; }; type IMessageRpcClientOptions = { cliPath?: string; dbPath?: string; runtime?: RuntimeEnv; onNotification?: (msg: IMessageRpcNotification) => void; }; declare class IMessageRpcClient { private readonly cliPath; private readonly dbPath?; private readonly runtime?; private readonly onNotification?; private readonly pending; private readonly closed; private closedResolve; private child; private reader; private nextId; private publicProcessError; constructor(opts?: IMessageRpcClientOptions); start(): Promise; stop(): Promise; waitForClose(): Promise; request(method: string, params?: Record, opts?: { timeoutMs?: number; }): Promise; private handleLine; private recordProcessDiagnostic; private buildCloseError; private failAll; } //#endregion //#region extensions/imessage/src/send.d.ts type IMessageSendOpts = { cliPath?: string; dbPath?: string; service?: IMessageService; region?: string; accountId?: string; replyToId?: string; mediaUrl?: string; mediaLocalRoots?: readonly string[]; mediaReadFile?: (filePath: string) => Promise; maxBytes?: number; timeoutMs?: number; chatId?: number; client?: IMessageRpcClient; config: KlawConfig; account?: ResolvedIMessageAccount; resolveAttachmentImpl?: (mediaUrl: string, maxBytes: number, options?: { localRoots?: readonly string[]; readFile?: (filePath: string) => Promise; }) => Promise<{ path: string; contentType?: string; }>; createClient?: (params: { cliPath: string; dbPath?: string; }) => Promise; }; type IMessageSendResult = { messageId: string; sentText: string; echoText?: string; receipt: MessageReceipt; }; declare function sendMessageIMessage(to: string, text: string, opts: IMessageSendOpts): Promise; //#endregion //#region extensions/imessage/src/actions.d.ts declare const imessageMessageActions: ChannelMessageActionAdapter; //#endregion //#region extensions/imessage/src/runtime.d.ts declare const setIMessageRuntime: (next: PluginRuntime) => void; //#endregion //#region extensions/imessage/runtime-api.d.ts type IMessageAccountConfig = Omit["imessage"]>, "accounts" | "defaultAccount">; //#endregion export { type ChannelPlugin, DEFAULT_ACCOUNT_ID, IMessageAccountConfig, IMessageConfigSchema, type IMessageProbe, type MonitorIMessageOpts, PAIRING_APPROVED_MESSAGE, buildChannelConfigSchema, buildComputedAccountStatusSnapshot, chunkTextForOutbound, collectStatusIssuesFromLastError, formatTrimmedAllowFromEntries, getChatChannelMeta, imessageMessageActions, looksLikeIMessageTargetId, monitorIMessageProvider, normalizeIMessageMessagingTarget, probeIMessage, resolveChannelMediaMaxBytes, resolveIMessageConfigAllowFrom, resolveIMessageConfigDefaultTo, resolveIMessageGroupRequireMention, resolveIMessageGroupToolPolicy, sendMessageIMessage, setIMessageRuntime };