File size: 11,197 Bytes
fc93158 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 | type ReadChannelAllowFromStore =
typeof import("../../pairing/pairing-store.js").readChannelAllowFromStore;
type UpsertChannelPairingRequest =
typeof import("../../pairing/pairing-store.js").upsertChannelPairingRequest;
type ReadChannelAllowFromStoreForAccount = (params: {
channel: Parameters<ReadChannelAllowFromStore>[0];
accountId: string;
env?: Parameters<ReadChannelAllowFromStore>[1];
}) => ReturnType<ReadChannelAllowFromStore>;
type UpsertChannelPairingRequestForAccount = (
params: Omit<Parameters<UpsertChannelPairingRequest>[0], "accountId"> & { accountId: string },
) => ReturnType<UpsertChannelPairingRequest>;
export type PluginRuntimeChannel = {
text: {
chunkByNewline: typeof import("../../auto-reply/chunk.js").chunkByNewline;
chunkMarkdownText: typeof import("../../auto-reply/chunk.js").chunkMarkdownText;
chunkMarkdownTextWithMode: typeof import("../../auto-reply/chunk.js").chunkMarkdownTextWithMode;
chunkText: typeof import("../../auto-reply/chunk.js").chunkText;
chunkTextWithMode: typeof import("../../auto-reply/chunk.js").chunkTextWithMode;
resolveChunkMode: typeof import("../../auto-reply/chunk.js").resolveChunkMode;
resolveTextChunkLimit: typeof import("../../auto-reply/chunk.js").resolveTextChunkLimit;
hasControlCommand: typeof import("../../auto-reply/command-detection.js").hasControlCommand;
resolveMarkdownTableMode: typeof import("../../config/markdown-tables.js").resolveMarkdownTableMode;
convertMarkdownTables: typeof import("../../markdown/tables.js").convertMarkdownTables;
};
reply: {
dispatchReplyWithBufferedBlockDispatcher: typeof import("../../auto-reply/reply/provider-dispatcher.js").dispatchReplyWithBufferedBlockDispatcher;
createReplyDispatcherWithTyping: typeof import("../../auto-reply/reply/reply-dispatcher.js").createReplyDispatcherWithTyping;
resolveEffectiveMessagesConfig: typeof import("../../agents/identity.js").resolveEffectiveMessagesConfig;
resolveHumanDelayConfig: typeof import("../../agents/identity.js").resolveHumanDelayConfig;
dispatchReplyFromConfig: typeof import("../../auto-reply/reply/dispatch-from-config.js").dispatchReplyFromConfig;
withReplyDispatcher: typeof import("../../auto-reply/dispatch.js").withReplyDispatcher;
finalizeInboundContext: typeof import("../../auto-reply/reply/inbound-context.js").finalizeInboundContext;
formatAgentEnvelope: typeof import("../../auto-reply/envelope.js").formatAgentEnvelope;
/** @deprecated Prefer `BodyForAgent` + structured user-context blocks (do not build plaintext envelopes for prompts). */
formatInboundEnvelope: typeof import("../../auto-reply/envelope.js").formatInboundEnvelope;
resolveEnvelopeFormatOptions: typeof import("../../auto-reply/envelope.js").resolveEnvelopeFormatOptions;
};
routing: {
buildAgentSessionKey: typeof import("../../routing/resolve-route.js").buildAgentSessionKey;
resolveAgentRoute: typeof import("../../routing/resolve-route.js").resolveAgentRoute;
};
pairing: {
buildPairingReply: typeof import("../../pairing/pairing-messages.js").buildPairingReply;
readAllowFromStore: ReadChannelAllowFromStoreForAccount;
upsertPairingRequest: UpsertChannelPairingRequestForAccount;
};
media: {
fetchRemoteMedia: typeof import("../../media/fetch.js").fetchRemoteMedia;
saveMediaBuffer: typeof import("../../media/store.js").saveMediaBuffer;
};
activity: {
record: typeof import("../../infra/channel-activity.js").recordChannelActivity;
get: typeof import("../../infra/channel-activity.js").getChannelActivity;
};
session: {
resolveStorePath: typeof import("../../config/sessions.js").resolveStorePath;
readSessionUpdatedAt: typeof import("../../config/sessions.js").readSessionUpdatedAt;
recordSessionMetaFromInbound: typeof import("../../config/sessions.js").recordSessionMetaFromInbound;
recordInboundSession: typeof import("../../channels/session.js").recordInboundSession;
updateLastRoute: typeof import("../../config/sessions.js").updateLastRoute;
};
mentions: {
buildMentionRegexes: typeof import("../../auto-reply/reply/mentions.js").buildMentionRegexes;
matchesMentionPatterns: typeof import("../../auto-reply/reply/mentions.js").matchesMentionPatterns;
matchesMentionWithExplicit: typeof import("../../auto-reply/reply/mentions.js").matchesMentionWithExplicit;
};
reactions: {
shouldAckReaction: typeof import("../../channels/ack-reactions.js").shouldAckReaction;
removeAckReactionAfterReply: typeof import("../../channels/ack-reactions.js").removeAckReactionAfterReply;
};
groups: {
resolveGroupPolicy: typeof import("../../config/group-policy.js").resolveChannelGroupPolicy;
resolveRequireMention: typeof import("../../config/group-policy.js").resolveChannelGroupRequireMention;
};
debounce: {
createInboundDebouncer: typeof import("../../auto-reply/inbound-debounce.js").createInboundDebouncer;
resolveInboundDebounceMs: typeof import("../../auto-reply/inbound-debounce.js").resolveInboundDebounceMs;
};
commands: {
resolveCommandAuthorizedFromAuthorizers: typeof import("../../channels/command-gating.js").resolveCommandAuthorizedFromAuthorizers;
isControlCommandMessage: typeof import("../../auto-reply/command-detection.js").isControlCommandMessage;
shouldComputeCommandAuthorized: typeof import("../../auto-reply/command-detection.js").shouldComputeCommandAuthorized;
shouldHandleTextCommands: typeof import("../../auto-reply/commands-registry.js").shouldHandleTextCommands;
};
discord: {
messageActions: typeof import("../../channels/plugins/actions/discord.js").discordMessageActions;
auditChannelPermissions: typeof import("../../discord/audit.js").auditDiscordChannelPermissions;
listDirectoryGroupsLive: typeof import("../../discord/directory-live.js").listDiscordDirectoryGroupsLive;
listDirectoryPeersLive: typeof import("../../discord/directory-live.js").listDiscordDirectoryPeersLive;
probeDiscord: typeof import("../../discord/probe.js").probeDiscord;
resolveChannelAllowlist: typeof import("../../discord/resolve-channels.js").resolveDiscordChannelAllowlist;
resolveUserAllowlist: typeof import("../../discord/resolve-users.js").resolveDiscordUserAllowlist;
sendMessageDiscord: typeof import("../../discord/send.js").sendMessageDiscord;
sendPollDiscord: typeof import("../../discord/send.js").sendPollDiscord;
monitorDiscordProvider: typeof import("../../discord/monitor.js").monitorDiscordProvider;
};
slack: {
listDirectoryGroupsLive: typeof import("../../slack/directory-live.js").listSlackDirectoryGroupsLive;
listDirectoryPeersLive: typeof import("../../slack/directory-live.js").listSlackDirectoryPeersLive;
probeSlack: typeof import("../../slack/probe.js").probeSlack;
resolveChannelAllowlist: typeof import("../../slack/resolve-channels.js").resolveSlackChannelAllowlist;
resolveUserAllowlist: typeof import("../../slack/resolve-users.js").resolveSlackUserAllowlist;
sendMessageSlack: typeof import("../../slack/send.js").sendMessageSlack;
monitorSlackProvider: typeof import("../../slack/index.js").monitorSlackProvider;
handleSlackAction: typeof import("../../agents/tools/slack-actions.js").handleSlackAction;
};
telegram: {
auditGroupMembership: typeof import("../../telegram/audit.js").auditTelegramGroupMembership;
collectUnmentionedGroupIds: typeof import("../../telegram/audit.js").collectTelegramUnmentionedGroupIds;
probeTelegram: typeof import("../../telegram/probe.js").probeTelegram;
resolveTelegramToken: typeof import("../../telegram/token.js").resolveTelegramToken;
sendMessageTelegram: typeof import("../../telegram/send.js").sendMessageTelegram;
sendPollTelegram: typeof import("../../telegram/send.js").sendPollTelegram;
monitorTelegramProvider: typeof import("../../telegram/monitor.js").monitorTelegramProvider;
messageActions: typeof import("../../channels/plugins/actions/telegram.js").telegramMessageActions;
};
signal: {
probeSignal: typeof import("../../signal/probe.js").probeSignal;
sendMessageSignal: typeof import("../../signal/send.js").sendMessageSignal;
monitorSignalProvider: typeof import("../../signal/index.js").monitorSignalProvider;
messageActions: typeof import("../../channels/plugins/actions/signal.js").signalMessageActions;
};
imessage: {
monitorIMessageProvider: typeof import("../../imessage/monitor.js").monitorIMessageProvider;
probeIMessage: typeof import("../../imessage/probe.js").probeIMessage;
sendMessageIMessage: typeof import("../../imessage/send.js").sendMessageIMessage;
};
whatsapp: {
getActiveWebListener: typeof import("../../web/active-listener.js").getActiveWebListener;
getWebAuthAgeMs: typeof import("../../web/auth-store.js").getWebAuthAgeMs;
logoutWeb: typeof import("../../web/auth-store.js").logoutWeb;
logWebSelfId: typeof import("../../web/auth-store.js").logWebSelfId;
readWebSelfId: typeof import("../../web/auth-store.js").readWebSelfId;
webAuthExists: typeof import("../../web/auth-store.js").webAuthExists;
sendMessageWhatsApp: typeof import("../../web/outbound.js").sendMessageWhatsApp;
sendPollWhatsApp: typeof import("../../web/outbound.js").sendPollWhatsApp;
loginWeb: typeof import("../../web/login.js").loginWeb;
startWebLoginWithQr: typeof import("../../web/login-qr.js").startWebLoginWithQr;
waitForWebLogin: typeof import("../../web/login-qr.js").waitForWebLogin;
monitorWebChannel: typeof import("../../channels/web/index.js").monitorWebChannel;
handleWhatsAppAction: typeof import("../../agents/tools/whatsapp-actions.js").handleWhatsAppAction;
createLoginTool: typeof import("../../channels/plugins/agent-tools/whatsapp-login.js").createWhatsAppLoginTool;
};
line: {
listLineAccountIds: typeof import("../../line/accounts.js").listLineAccountIds;
resolveDefaultLineAccountId: typeof import("../../line/accounts.js").resolveDefaultLineAccountId;
resolveLineAccount: typeof import("../../line/accounts.js").resolveLineAccount;
normalizeAccountId: typeof import("../../line/accounts.js").normalizeAccountId;
probeLineBot: typeof import("../../line/probe.js").probeLineBot;
sendMessageLine: typeof import("../../line/send.js").sendMessageLine;
pushMessageLine: typeof import("../../line/send.js").pushMessageLine;
pushMessagesLine: typeof import("../../line/send.js").pushMessagesLine;
pushFlexMessage: typeof import("../../line/send.js").pushFlexMessage;
pushTemplateMessage: typeof import("../../line/send.js").pushTemplateMessage;
pushLocationMessage: typeof import("../../line/send.js").pushLocationMessage;
pushTextMessageWithQuickReplies: typeof import("../../line/send.js").pushTextMessageWithQuickReplies;
createQuickReplyItems: typeof import("../../line/send.js").createQuickReplyItems;
buildTemplateMessageFromPayload: typeof import("../../line/template-messages.js").buildTemplateMessageFromPayload;
monitorLineProvider: typeof import("../../line/monitor.js").monitorLineProvider;
};
};
|