diff --git a/CHANGELOG.md b/CHANGELOG.md index 734ac9e309c..2b09e22af45 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -137,6 +137,7 @@ Docs: https://docs.openclaw.ai - Browser/profiles: drop the auto-created `chrome-relay` browser profile; users who need the Chrome extension relay must now create their own profile via `openclaw browser create-profile`. (#46596) Fixes #45777. Thanks @odysseus0. - CI/channel test routing: move the built-in channel suites into `test:channels` and keep them out of `test:extensions`, so extension CI no longer fails after the channel migration while targeted test routing still sends Slack, Signal, and iMessage suites to the right lane. (#46066) Thanks @scoootscooob. - Docs/Mintlify: fix MDX marker syntax on Perplexity, Model Providers, Moonshot, and exec approvals pages so local docs preview no longer breaks rendering or leaves stale pages unpublished. (#46695) Thanks @velvet-shark. +- Plugins/runtime barrels: route bundled extension runtime imports through public `openclaw/plugin-sdk/*` subpaths and block relative cross-package escapes so packaged extensions stop depending on monorepo-only relative paths. (#51939) Thanks @vincentkoc. - Gateway/config validation: stop treating the implicit default memory slot as a required explicit plugin config, so startup no longer fails with `plugins.slots.memory: plugin not found: memory-core` when `memory-core` was only inferred. (#47494) Thanks @ngutman. - Tlon: honor explicit empty allowlists and defer cite expansion. (#46788) Thanks @zpbrent and @vincentkoc. - Tlon/DM auth: defer cited-message expansion until after DM authorization and owner command handling, so unauthorized DMs and owner approval/admin commands no longer trigger cross-channel cite fetches before the deny or command path. diff --git a/extensions/bluebubbles/package.json b/extensions/bluebubbles/package.json index d89701af44b..ee974b3b81c 100644 --- a/extensions/bluebubbles/package.json +++ b/extensions/bluebubbles/package.json @@ -6,6 +6,17 @@ "dependencies": { "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/bluebubbles/src/runtime-api.ts b/extensions/bluebubbles/src/runtime-api.ts index 4faebbed877..23c09660d96 100644 --- a/extensions/bluebubbles/src/runtime-api.ts +++ b/extensions/bluebubbles/src/runtime-api.ts @@ -1 +1 @@ -export * from "../../../src/plugin-sdk/bluebubbles.js"; +export * from "openclaw/plugin-sdk/bluebubbles"; diff --git a/extensions/bluebubbles/src/targets.ts b/extensions/bluebubbles/src/targets.ts index 833ac88522e..605c5cecc76 100644 --- a/extensions/bluebubbles/src/targets.ts +++ b/extensions/bluebubbles/src/targets.ts @@ -5,7 +5,7 @@ import { type ParsedChatTarget, resolveServicePrefixedAllowTarget, resolveServicePrefixedTarget, -} from "../../imessage/api.js"; +} from "openclaw/plugin-sdk/imessage-core"; export type BlueBubblesService = "imessage" | "sms" | "auto"; diff --git a/extensions/discord/package.json b/extensions/discord/package.json index 589ceed8d21..27404f99f72 100644 --- a/extensions/discord/package.json +++ b/extensions/discord/package.json @@ -10,6 +10,17 @@ "https-proxy-agent": "^8.0.0", "opusscript": "^0.1.1" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/discord/src/runtime-api.ts b/extensions/discord/src/runtime-api.ts index 7d9bc355184..3bbdfd0276c 100644 --- a/extensions/discord/src/runtime-api.ts +++ b/extensions/discord/src/runtime-api.ts @@ -4,7 +4,7 @@ export { PAIRING_APPROVED_MESSAGE, projectCredentialSnapshotFields, resolveConfiguredFromCredentialStatuses, -} from "../../../src/plugin-sdk/discord.js"; +} from "openclaw/plugin-sdk/discord"; export { buildChannelConfigSchema, getChatChannelMeta, @@ -19,15 +19,15 @@ export { type DiscordActionConfig, type DiscordConfig, type OpenClawConfig, -} from "../../../src/plugin-sdk/discord-core.js"; -export { DiscordConfigSchema } from "../../../src/plugin-sdk/discord-core.js"; +} from "openclaw/plugin-sdk/discord-core"; +export { DiscordConfigSchema } from "openclaw/plugin-sdk/discord-core"; export { readBooleanParam } from "openclaw/plugin-sdk/boolean-param"; export { assertMediaNotDataUrl, parseAvailableTags, readReactionParams, withNormalizedTimestamp, -} from "../../../src/plugin-sdk/discord-core.js"; +} from "openclaw/plugin-sdk/discord-core"; export { createHybridChannelConfigAdapter, createScopedChannelConfigAdapter, diff --git a/extensions/feishu/package.json b/extensions/feishu/package.json index a610473f445..7111cf7e54b 100644 --- a/extensions/feishu/package.json +++ b/extensions/feishu/package.json @@ -9,6 +9,17 @@ "https-proxy-agent": "^8.0.0", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/feishu/runtime-api.ts b/extensions/feishu/runtime-api.ts index cde6bbf5569..ece8df41cca 100644 --- a/extensions/feishu/runtime-api.ts +++ b/extensions/feishu/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Feishu extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/feishu.js"; +export * from "openclaw/plugin-sdk/feishu"; diff --git a/extensions/googlechat/package.json b/extensions/googlechat/package.json index b38a23273f7..f94193071f4 100644 --- a/extensions/googlechat/package.json +++ b/extensions/googlechat/package.json @@ -7,8 +7,11 @@ "dependencies": { "google-auth-library": "^10.6.2" }, + "devDependencies": { + "openclaw": "workspace:*" + }, "peerDependencies": { - "openclaw": ">=2026.3.11" + "openclaw": ">=2026.3.14" }, "peerDependenciesMeta": { "openclaw": { diff --git a/extensions/googlechat/runtime-api.ts b/extensions/googlechat/runtime-api.ts index cd47c0e56c7..df946f8ec4a 100644 --- a/extensions/googlechat/runtime-api.ts +++ b/extensions/googlechat/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Google Chat extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/googlechat.js"; +export * from "openclaw/plugin-sdk/googlechat"; diff --git a/extensions/imessage/runtime-api.ts b/extensions/imessage/runtime-api.ts index 22b1e4a21ba..aa6d55c75e5 100644 --- a/extensions/imessage/runtime-api.ts +++ b/extensions/imessage/runtime-api.ts @@ -13,7 +13,7 @@ export { IMessageConfigSchema, type ChannelPlugin, type IMessageAccountConfig, -} from "../../src/plugin-sdk/imessage.js"; +} from "openclaw/plugin-sdk/imessage"; export { resolveIMessageGroupRequireMention, resolveIMessageGroupToolPolicy, diff --git a/extensions/irc/src/runtime-api.ts b/extensions/irc/src/runtime-api.ts index 96e4bdbbe90..40f35e1ad53 100644 --- a/extensions/irc/src/runtime-api.ts +++ b/extensions/irc/src/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled IRC extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../../src/plugin-sdk/irc.js"; +export * from "openclaw/plugin-sdk/irc"; diff --git a/extensions/line/package.json b/extensions/line/package.json index 3fa098460d6..1d82e5bc172 100644 --- a/extensions/line/package.json +++ b/extensions/line/package.json @@ -4,6 +4,17 @@ "private": true, "description": "OpenClaw LINE channel plugin", "type": "module", + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/line/runtime-api.ts b/extensions/line/runtime-api.ts index 675c11a7467..aa873f56796 100644 --- a/extensions/line/runtime-api.ts +++ b/extensions/line/runtime-api.ts @@ -1,7 +1,7 @@ // Private runtime barrel for the bundled LINE extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/line.js"; +export * from "openclaw/plugin-sdk/line"; export { DEFAULT_ACCOUNT_ID, formatDocsLink, @@ -10,4 +10,4 @@ export { splitSetupEntries, type ChannelSetupDmPolicy, type ChannelSetupWizard, -} from "../../src/plugin-sdk/line-core.js"; +} from "openclaw/plugin-sdk/line-core"; diff --git a/extensions/matrix/package.json b/extensions/matrix/package.json index 605751f6ccd..21d7b7a8bac 100644 --- a/extensions/matrix/package.json +++ b/extensions/matrix/package.json @@ -14,6 +14,14 @@ "devDependencies": { "openclaw": "workspace:*" }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/matrix/runtime-api.ts b/extensions/matrix/runtime-api.ts index 751ce70e496..2c52135acf5 100644 --- a/extensions/matrix/runtime-api.ts +++ b/extensions/matrix/runtime-api.ts @@ -16,7 +16,7 @@ export { setMatrixThreadBindingIdleTimeoutBySessionKey, setMatrixThreadBindingMaxAgeBySessionKey, } from "./thread-bindings-runtime.js"; -export { writeJsonFileAtomically } from "../../src/plugin-sdk/json-store.js"; +export { writeJsonFileAtomically } from "openclaw/plugin-sdk/json-store"; export type { ChannelDirectoryEntry, ChannelMessageActionContext, @@ -25,5 +25,5 @@ export type { RuntimeLogger, RuntimeEnv, WizardPrompter, -} from "../../src/plugin-sdk/matrix.js"; -export { formatZonedTimestamp } from "../../src/plugin-sdk/matrix.js"; +} from "openclaw/plugin-sdk/matrix"; +export { formatZonedTimestamp } from "openclaw/plugin-sdk/matrix"; diff --git a/extensions/matrix/src/runtime-api.ts b/extensions/matrix/src/runtime-api.ts index 79a283ac39a..0cb6eb6b42d 100644 --- a/extensions/matrix/src/runtime-api.ts +++ b/extensions/matrix/src/runtime-api.ts @@ -1,4 +1,4 @@ -export * from "../../../src/plugin-sdk/matrix.js"; +export * from "openclaw/plugin-sdk/matrix"; export { assertHttpUrlTargetsPrivateNetwork, closeDispatcher, diff --git a/extensions/mattermost/package.json b/extensions/mattermost/package.json index 3c414f52f29..eaacc6a28bb 100644 --- a/extensions/mattermost/package.json +++ b/extensions/mattermost/package.json @@ -7,6 +7,17 @@ "ws": "^8.19.0", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/mattermost/runtime-api.ts b/extensions/mattermost/runtime-api.ts index 2bc65439262..d4e591c8c1e 100644 --- a/extensions/mattermost/runtime-api.ts +++ b/extensions/mattermost/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Mattermost extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/mattermost.js"; +export * from "openclaw/plugin-sdk/mattermost"; diff --git a/extensions/msteams/package.json b/extensions/msteams/package.json index 5a989be1cc2..a91865b1e7e 100644 --- a/extensions/msteams/package.json +++ b/extensions/msteams/package.json @@ -8,6 +8,17 @@ "express": "^5.2.1", "uuid": "^11.1.0" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/msteams/runtime-api.ts b/extensions/msteams/runtime-api.ts index e2b75780399..d32cb7b65d5 100644 --- a/extensions/msteams/runtime-api.ts +++ b/extensions/msteams/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Microsoft Teams extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/msteams.js"; +export * from "openclaw/plugin-sdk/msteams"; diff --git a/extensions/nextcloud-talk/package.json b/extensions/nextcloud-talk/package.json index 83010363da2..5e887c6adfd 100644 --- a/extensions/nextcloud-talk/package.json +++ b/extensions/nextcloud-talk/package.json @@ -6,6 +6,17 @@ "dependencies": { "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/nextcloud-talk/runtime-api.ts b/extensions/nextcloud-talk/runtime-api.ts index 80bc1b1dc7b..b2093a7a057 100644 --- a/extensions/nextcloud-talk/runtime-api.ts +++ b/extensions/nextcloud-talk/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Nextcloud Talk extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/nextcloud-talk.js"; +export * from "openclaw/plugin-sdk/nextcloud-talk"; diff --git a/extensions/nostr/package.json b/extensions/nostr/package.json index 2335eae85c7..61f3d663896 100644 --- a/extensions/nostr/package.json +++ b/extensions/nostr/package.json @@ -7,6 +7,17 @@ "nostr-tools": "^2.23.3", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/nostr/runtime-api.ts b/extensions/nostr/runtime-api.ts index 602b0ac81b7..29825771891 100644 --- a/extensions/nostr/runtime-api.ts +++ b/extensions/nostr/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Nostr extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/nostr.js"; +export * from "openclaw/plugin-sdk/nostr"; diff --git a/extensions/signal/src/runtime-api.ts b/extensions/signal/src/runtime-api.ts index 172943641f8..6aeeef0adb1 100644 --- a/extensions/signal/src/runtime-api.ts +++ b/extensions/signal/src/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Signal extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../../src/plugin-sdk/signal.js"; +export * from "openclaw/plugin-sdk/signal"; diff --git a/extensions/slack/src/runtime-api.ts b/extensions/slack/src/runtime-api.ts index 84f7b9d480b..5dac68be756 100644 --- a/extensions/slack/src/runtime-api.ts +++ b/extensions/slack/src/runtime-api.ts @@ -9,7 +9,7 @@ export { type ChannelPlugin, type OpenClawConfig, type SlackAccountConfig, -} from "../../../src/plugin-sdk/slack.js"; +} from "openclaw/plugin-sdk/slack"; export { listSlackDirectoryGroupsFromConfig, listSlackDirectoryPeersFromConfig, @@ -25,5 +25,5 @@ export { readStringParam, SlackConfigSchema, withNormalizedTimestamp, -} from "../../../src/plugin-sdk/slack-core.js"; +} from "openclaw/plugin-sdk/slack-core"; export { isSlackInteractiveRepliesEnabled } from "./interactive-replies.js"; diff --git a/extensions/telegram/runtime-api.ts b/extensions/telegram/runtime-api.ts index 28c7788ef9d..c069a35e40e 100644 --- a/extensions/telegram/runtime-api.ts +++ b/extensions/telegram/runtime-api.ts @@ -7,7 +7,7 @@ export type { TelegramAccountConfig, TelegramActionConfig, TelegramNetworkConfig, -} from "../../src/plugin-sdk/telegram.js"; +} from "openclaw/plugin-sdk/telegram"; export type { OpenClawPluginService, OpenClawPluginServiceContext, @@ -37,7 +37,7 @@ export { projectCredentialSnapshotFields, resolveConfiguredFromCredentialStatuses, resolveTelegramPollVisibility, -} from "../../src/plugin-sdk/telegram.js"; +} from "openclaw/plugin-sdk/telegram"; export { buildChannelConfigSchema, getChatChannelMeta, @@ -49,7 +49,7 @@ export { readStringParam, resolvePollMaxSelections, TelegramConfigSchema, -} from "../../src/plugin-sdk/telegram-core.js"; +} from "openclaw/plugin-sdk/telegram-core"; export type { TelegramProbe } from "./src/probe.js"; export { auditTelegramGroupMembership, collectTelegramUnmentionedGroupIds } from "./src/audit.js"; export { telegramMessageActions } from "./src/channel-actions.js"; diff --git a/extensions/tlon/package.json b/extensions/tlon/package.json index c1c718ed4b6..d7082ba05a7 100644 --- a/extensions/tlon/package.json +++ b/extensions/tlon/package.json @@ -10,6 +10,17 @@ "@urbit/aura": "^3.0.0", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/tlon/runtime-api.ts b/extensions/tlon/runtime-api.ts index 3ba9718868f..3c2c83655c5 100644 --- a/extensions/tlon/runtime-api.ts +++ b/extensions/tlon/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Tlon extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/tlon.js"; +export * from "openclaw/plugin-sdk/tlon"; diff --git a/extensions/twitch/runtime-api.ts b/extensions/twitch/runtime-api.ts index 9d055202a39..87433b1997f 100644 --- a/extensions/twitch/runtime-api.ts +++ b/extensions/twitch/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Twitch extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/twitch.js"; +export * from "openclaw/plugin-sdk/twitch"; diff --git a/extensions/voice-call/package.json b/extensions/voice-call/package.json index eac88a77d10..0950adb3198 100644 --- a/extensions/voice-call/package.json +++ b/extensions/voice-call/package.json @@ -9,6 +9,17 @@ "ws": "^8.19.0", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/voice-call/runtime-api.ts b/extensions/voice-call/runtime-api.ts index f0b32548645..9dd4fb0f3bc 100644 --- a/extensions/voice-call/runtime-api.ts +++ b/extensions/voice-call/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Voice Call extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/voice-call.js"; +export * from "openclaw/plugin-sdk/voice-call"; diff --git a/extensions/whatsapp/package.json b/extensions/whatsapp/package.json index 5067598a61f..d19f576417b 100644 --- a/extensions/whatsapp/package.json +++ b/extensions/whatsapp/package.json @@ -6,6 +6,17 @@ "dependencies": { "@whiskeysockets/baileys": "7.0.0-rc.9" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/whatsapp/src/runtime-api.ts b/extensions/whatsapp/src/runtime-api.ts index a98c264b2b2..f2d76706bde 100644 --- a/extensions/whatsapp/src/runtime-api.ts +++ b/extensions/whatsapp/src/runtime-api.ts @@ -16,7 +16,7 @@ export { WhatsAppConfigSchema, type ChannelPlugin, type OpenClawConfig, -} from "../../../src/plugin-sdk/whatsapp-core.js"; +} from "openclaw/plugin-sdk/whatsapp-core"; export { createWhatsAppOutboundBase, @@ -31,6 +31,6 @@ export { type DmPolicy, type GroupPolicy, type WhatsAppAccountConfig, -} from "../../../src/plugin-sdk/whatsapp-shared.js"; +} from "openclaw/plugin-sdk/whatsapp-shared"; export { monitorWebChannel } from "./channel.runtime.js"; diff --git a/extensions/zalo/package.json b/extensions/zalo/package.json index 1dd30038cea..a3418ea0915 100644 --- a/extensions/zalo/package.json +++ b/extensions/zalo/package.json @@ -7,6 +7,17 @@ "undici": "7.24.4", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/zalo/runtime-api.ts b/extensions/zalo/runtime-api.ts index 082f65d43b8..90ced0da803 100644 --- a/extensions/zalo/runtime-api.ts +++ b/extensions/zalo/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Zalo extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/zalo.js"; +export * from "openclaw/plugin-sdk/zalo"; diff --git a/extensions/zalouser/package.json b/extensions/zalouser/package.json index 80c0b80b357..2548ad29075 100644 --- a/extensions/zalouser/package.json +++ b/extensions/zalouser/package.json @@ -8,6 +8,17 @@ "zca-js": "2.1.2", "zod": "^4.3.6" }, + "devDependencies": { + "openclaw": "workspace:*" + }, + "peerDependencies": { + "openclaw": ">=2026.3.14" + }, + "peerDependenciesMeta": { + "openclaw": { + "optional": true + } + }, "openclaw": { "extensions": [ "./index.ts" diff --git a/extensions/zalouser/runtime-api.ts b/extensions/zalouser/runtime-api.ts index 1b63edaea42..7d931f2d118 100644 --- a/extensions/zalouser/runtime-api.ts +++ b/extensions/zalouser/runtime-api.ts @@ -1,4 +1,4 @@ // Private runtime barrel for the bundled Zalo Personal extension. // Keep this barrel thin and aligned with the local extension surface. -export * from "../../src/plugin-sdk/zalouser.js"; +export * from "openclaw/plugin-sdk/zalouser"; diff --git a/package.json b/package.json index 6d60ba721fd..6fb1b4f9013 100644 --- a/package.json +++ b/package.json @@ -221,6 +221,10 @@ "types": "./dist/plugin-sdk/allowlist-config-edit.d.ts", "default": "./dist/plugin-sdk/allowlist-config-edit.js" }, + "./plugin-sdk/bluebubbles": { + "types": "./dist/plugin-sdk/bluebubbles.d.ts", + "default": "./dist/plugin-sdk/bluebubbles.js" + }, "./plugin-sdk/boolean-param": { "types": "./dist/plugin-sdk/boolean-param.d.ts", "default": "./dist/plugin-sdk/boolean-param.js" @@ -245,6 +249,10 @@ "types": "./dist/plugin-sdk/discord.d.ts", "default": "./dist/plugin-sdk/discord.js" }, + "./plugin-sdk/discord-core": { + "types": "./dist/plugin-sdk/discord-core.d.ts", + "default": "./dist/plugin-sdk/discord-core.js" + }, "./plugin-sdk/extension-shared": { "types": "./dist/plugin-sdk/extension-shared.d.ts", "default": "./dist/plugin-sdk/extension-shared.js" @@ -293,6 +301,10 @@ "types": "./dist/plugin-sdk/channel-targets.d.ts", "default": "./dist/plugin-sdk/channel-targets.js" }, + "./plugin-sdk/feishu": { + "types": "./dist/plugin-sdk/feishu.d.ts", + "default": "./dist/plugin-sdk/feishu.js" + }, "./plugin-sdk/group-access": { "types": "./dist/plugin-sdk/group-access.d.ts", "default": "./dist/plugin-sdk/group-access.js" @@ -301,6 +313,42 @@ "types": "./dist/plugin-sdk/directory-runtime.d.ts", "default": "./dist/plugin-sdk/directory-runtime.js" }, + "./plugin-sdk/googlechat": { + "types": "./dist/plugin-sdk/googlechat.d.ts", + "default": "./dist/plugin-sdk/googlechat.js" + }, + "./plugin-sdk/image-generation": { + "types": "./dist/plugin-sdk/image-generation.d.ts", + "default": "./dist/plugin-sdk/image-generation.js" + }, + "./plugin-sdk/imessage": { + "types": "./dist/plugin-sdk/imessage.d.ts", + "default": "./dist/plugin-sdk/imessage.js" + }, + "./plugin-sdk/imessage-core": { + "types": "./dist/plugin-sdk/imessage-core.d.ts", + "default": "./dist/plugin-sdk/imessage-core.js" + }, + "./plugin-sdk/irc": { + "types": "./dist/plugin-sdk/irc.d.ts", + "default": "./dist/plugin-sdk/irc.js" + }, + "./plugin-sdk/reply-history": { + "types": "./dist/plugin-sdk/reply-history.d.ts", + "default": "./dist/plugin-sdk/reply-history.js" + }, + "./plugin-sdk/media-understanding": { + "types": "./dist/plugin-sdk/media-understanding.d.ts", + "default": "./dist/plugin-sdk/media-understanding.js" + }, + "./plugin-sdk/request-url": { + "types": "./dist/plugin-sdk/request-url.d.ts", + "default": "./dist/plugin-sdk/request-url.js" + }, + "./plugin-sdk/runtime-store": { + "types": "./dist/plugin-sdk/runtime-store.d.ts", + "default": "./dist/plugin-sdk/runtime-store.js" + }, "./plugin-sdk/json-store": { "types": "./dist/plugin-sdk/json-store.d.ts", "default": "./dist/plugin-sdk/json-store.js" @@ -309,10 +357,26 @@ "types": "./dist/plugin-sdk/keyed-async-queue.d.ts", "default": "./dist/plugin-sdk/keyed-async-queue.js" }, + "./plugin-sdk/line": { + "types": "./dist/plugin-sdk/line.d.ts", + "default": "./dist/plugin-sdk/line.js" + }, + "./plugin-sdk/line-core": { + "types": "./dist/plugin-sdk/line-core.d.ts", + "default": "./dist/plugin-sdk/line-core.js" + }, "./plugin-sdk/llm-task": { "types": "./dist/plugin-sdk/llm-task.d.ts", "default": "./dist/plugin-sdk/llm-task.js" }, + "./plugin-sdk/matrix": { + "types": "./dist/plugin-sdk/matrix.d.ts", + "default": "./dist/plugin-sdk/matrix.js" + }, + "./plugin-sdk/mattermost": { + "types": "./dist/plugin-sdk/mattermost.d.ts", + "default": "./dist/plugin-sdk/mattermost.js" + }, "./plugin-sdk/memory-core": { "types": "./dist/plugin-sdk/memory-core.d.ts", "default": "./dist/plugin-sdk/memory-core.js" @@ -321,6 +385,18 @@ "types": "./dist/plugin-sdk/memory-lancedb.d.ts", "default": "./dist/plugin-sdk/memory-lancedb.js" }, + "./plugin-sdk/msteams": { + "types": "./dist/plugin-sdk/msteams.d.ts", + "default": "./dist/plugin-sdk/msteams.js" + }, + "./plugin-sdk/nextcloud-talk": { + "types": "./dist/plugin-sdk/nextcloud-talk.d.ts", + "default": "./dist/plugin-sdk/nextcloud-talk.js" + }, + "./plugin-sdk/nostr": { + "types": "./dist/plugin-sdk/nostr.d.ts", + "default": "./dist/plugin-sdk/nostr.js" + }, "./plugin-sdk/provider-auth": { "types": "./dist/plugin-sdk/provider-auth.d.ts", "default": "./dist/plugin-sdk/provider-auth.js" @@ -373,57 +449,25 @@ "types": "./dist/plugin-sdk/provider-zai-endpoint.d.ts", "default": "./dist/plugin-sdk/provider-zai-endpoint.js" }, - "./plugin-sdk/image-generation": { - "types": "./dist/plugin-sdk/image-generation.d.ts", - "default": "./dist/plugin-sdk/image-generation.js" - }, - "./plugin-sdk/reply-history": { - "types": "./dist/plugin-sdk/reply-history.d.ts", - "default": "./dist/plugin-sdk/reply-history.js" - }, - "./plugin-sdk/media-understanding": { - "types": "./dist/plugin-sdk/media-understanding.d.ts", - "default": "./dist/plugin-sdk/media-understanding.js" - }, - "./plugin-sdk/request-url": { - "types": "./dist/plugin-sdk/request-url.d.ts", - "default": "./dist/plugin-sdk/request-url.js" - }, - "./plugin-sdk/webhook-ingress": { - "types": "./dist/plugin-sdk/webhook-ingress.d.ts", - "default": "./dist/plugin-sdk/webhook-ingress.js" - }, - "./plugin-sdk/webhook-path": { - "types": "./dist/plugin-sdk/webhook-path.d.ts", - "default": "./dist/plugin-sdk/webhook-path.js" - }, - "./plugin-sdk/runtime-store": { - "types": "./dist/plugin-sdk/runtime-store.d.ts", - "default": "./dist/plugin-sdk/runtime-store.js" - }, - "./plugin-sdk/status-helpers": { - "types": "./dist/plugin-sdk/status-helpers.d.ts", - "default": "./dist/plugin-sdk/status-helpers.js" - }, "./plugin-sdk/secret-input": { "types": "./dist/plugin-sdk/secret-input.d.ts", "default": "./dist/plugin-sdk/secret-input.js" }, - "./plugin-sdk/thread-ownership": { - "types": "./dist/plugin-sdk/thread-ownership.d.ts", - "default": "./dist/plugin-sdk/thread-ownership.js" + "./plugin-sdk/signal": { + "types": "./dist/plugin-sdk/signal.d.ts", + "default": "./dist/plugin-sdk/signal.js" }, - "./plugin-sdk/web-media": { - "types": "./dist/plugin-sdk/web-media.d.ts", - "default": "./dist/plugin-sdk/web-media.js" + "./plugin-sdk/slack": { + "types": "./dist/plugin-sdk/slack.d.ts", + "default": "./dist/plugin-sdk/slack.js" }, - "./plugin-sdk/zalo": { - "types": "./dist/plugin-sdk/zalo.d.ts", - "default": "./dist/plugin-sdk/zalo.js" + "./plugin-sdk/slack-core": { + "types": "./dist/plugin-sdk/slack-core.d.ts", + "default": "./dist/plugin-sdk/slack-core.js" }, - "./plugin-sdk/zalouser": { - "types": "./dist/plugin-sdk/zalouser.d.ts", - "default": "./dist/plugin-sdk/zalouser.js" + "./plugin-sdk/status-helpers": { + "types": "./dist/plugin-sdk/status-helpers.d.ts", + "default": "./dist/plugin-sdk/status-helpers.js" }, "./plugin-sdk/speech": { "types": "./dist/plugin-sdk/speech.d.ts", @@ -433,10 +477,62 @@ "types": "./dist/plugin-sdk/state-paths.d.ts", "default": "./dist/plugin-sdk/state-paths.js" }, + "./plugin-sdk/telegram": { + "types": "./dist/plugin-sdk/telegram.d.ts", + "default": "./dist/plugin-sdk/telegram.js" + }, + "./plugin-sdk/telegram-core": { + "types": "./dist/plugin-sdk/telegram-core.d.ts", + "default": "./dist/plugin-sdk/telegram-core.js" + }, + "./plugin-sdk/thread-ownership": { + "types": "./dist/plugin-sdk/thread-ownership.d.ts", + "default": "./dist/plugin-sdk/thread-ownership.js" + }, + "./plugin-sdk/tlon": { + "types": "./dist/plugin-sdk/tlon.d.ts", + "default": "./dist/plugin-sdk/tlon.js" + }, "./plugin-sdk/tool-send": { "types": "./dist/plugin-sdk/tool-send.d.ts", "default": "./dist/plugin-sdk/tool-send.js" }, + "./plugin-sdk/twitch": { + "types": "./dist/plugin-sdk/twitch.d.ts", + "default": "./dist/plugin-sdk/twitch.js" + }, + "./plugin-sdk/webhook-ingress": { + "types": "./dist/plugin-sdk/webhook-ingress.d.ts", + "default": "./dist/plugin-sdk/webhook-ingress.js" + }, + "./plugin-sdk/webhook-path": { + "types": "./dist/plugin-sdk/webhook-path.d.ts", + "default": "./dist/plugin-sdk/webhook-path.js" + }, + "./plugin-sdk/web-media": { + "types": "./dist/plugin-sdk/web-media.d.ts", + "default": "./dist/plugin-sdk/web-media.js" + }, + "./plugin-sdk/voice-call": { + "types": "./dist/plugin-sdk/voice-call.d.ts", + "default": "./dist/plugin-sdk/voice-call.js" + }, + "./plugin-sdk/whatsapp-core": { + "types": "./dist/plugin-sdk/whatsapp-core.d.ts", + "default": "./dist/plugin-sdk/whatsapp-core.js" + }, + "./plugin-sdk/whatsapp-shared": { + "types": "./dist/plugin-sdk/whatsapp-shared.d.ts", + "default": "./dist/plugin-sdk/whatsapp-shared.js" + }, + "./plugin-sdk/zalo": { + "types": "./dist/plugin-sdk/zalo.d.ts", + "default": "./dist/plugin-sdk/zalo.js" + }, + "./plugin-sdk/zalouser": { + "types": "./dist/plugin-sdk/zalouser.d.ts", + "default": "./dist/plugin-sdk/zalouser.js" + }, "./extension-api": "./dist/extensionAPI.js", "./cli-entry": "./openclaw.mjs" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b652a803a58..614f30a0420 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -250,6 +250,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/brave: {} @@ -326,6 +330,10 @@ importers: opusscript: specifier: ^0.1.1 version: 0.1.1 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/elevenlabs: {} @@ -345,6 +353,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/firecrawl: {} @@ -357,9 +369,10 @@ importers: google-auth-library: specifier: ^10.6.2 version: 10.6.2 + devDependencies: openclaw: - specifier: '>=2026.3.11' - version: 2026.3.13(@discordjs/opus@0.10.0)(@napi-rs/canvas@0.1.95)(@types/express@5.0.6)(audio-decode@2.2.3)(jimp@1.6.0)(node-llama-cpp@3.16.2(typescript@5.9.3)) + specifier: workspace:* + version: link:../.. extensions/huggingface: {} @@ -375,7 +388,11 @@ importers: extensions/kimi-coding: {} - extensions/line: {} + extensions/line: + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/llm-task: dependencies: @@ -425,6 +442,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/memory-core: dependencies: @@ -465,12 +486,20 @@ importers: uuid: specifier: ^11.1.0 version: 11.1.0 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/nextcloud-talk: dependencies: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/nostr: dependencies: @@ -480,6 +509,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/nvidia: {} @@ -553,6 +586,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/together: {} @@ -591,6 +628,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/volcengine: {} @@ -599,6 +640,10 @@ importers: '@whiskeysockets/baileys': specifier: 7.0.0-rc.9 version: 7.0.0-rc.9(audio-decode@2.2.3)(jimp@1.6.0)(sharp@0.34.5) + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/xai: {} @@ -614,6 +659,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. extensions/zalouser: dependencies: @@ -626,6 +675,10 @@ importers: zod: specifier: ^4.3.6 version: 4.3.6 + devDependencies: + openclaw: + specifier: workspace:* + version: link:../.. packages/clawdbot: dependencies: diff --git a/scripts/check-extension-plugin-sdk-boundary.mjs b/scripts/check-extension-plugin-sdk-boundary.mjs index 1915b80a5da..41461f16450 100644 --- a/scripts/check-extension-plugin-sdk-boundary.mjs +++ b/scripts/check-extension-plugin-sdk-boundary.mjs @@ -354,9 +354,20 @@ export async function runExtensionPluginSdkBoundaryCheck(argv = process.argv.sli return 0; } + writeLine(streams.stdout, formatInventoryHuman(mode, actual)); + if (mode === "relative-outside-package") { + if (actual.length === 0) { + return 0; + } + writeLine( + streams.stderr, + `Relative outside-package violations found (${actual.length}); this mode no longer uses a baseline.`, + ); + return 1; + } + const expected = await readExpectedInventory(mode); const diff = diffInventory(expected, actual); - writeLine(streams.stdout, formatInventoryHuman(mode, actual)); if (diff.missing.length === 0 && diff.unexpected.length === 0) { writeLine(streams.stdout, `Baseline matches (${actual.length} entries).`); return 0; diff --git a/scripts/lib/plugin-sdk-entrypoints.json b/scripts/lib/plugin-sdk-entrypoints.json index f058d53d3cb..87b178dd35f 100644 --- a/scripts/lib/plugin-sdk-entrypoints.json +++ b/scripts/lib/plugin-sdk-entrypoints.json @@ -45,12 +45,14 @@ "account-resolution", "allow-from", "allowlist-config-edit", + "bluebubbles", "boolean-param", "command-auth", "device-bootstrap", "diagnostics-otel", "diffs", "discord", + "discord-core", "extension-shared", "channel-config-helpers", "channel-config-schema", @@ -63,13 +65,30 @@ "channel-policy", "channel-send-result", "channel-targets", + "feishu", "group-access", "directory-runtime", + "googlechat", + "image-generation", + "imessage", + "imessage-core", + "irc", + "reply-history", + "media-understanding", + "request-url", + "runtime-store", "json-store", "keyed-async-queue", + "line", + "line-core", "llm-task", + "matrix", + "mattermost", "memory-core", "memory-lancedb", + "msteams", + "nextcloud-talk", + "nostr", "provider-auth", "provider-auth-api-key", "provider-auth-login", @@ -83,20 +102,25 @@ "provider-usage", "provider-web-search", "provider-zai-endpoint", - "image-generation", - "reply-history", - "media-understanding", - "request-url", - "webhook-ingress", - "webhook-path", - "runtime-store", - "status-helpers", "secret-input", - "thread-ownership", - "web-media", - "zalo", - "zalouser", + "signal", + "slack", + "slack-core", + "status-helpers", "speech", "state-paths", - "tool-send" + "telegram", + "telegram-core", + "thread-ownership", + "tlon", + "tool-send", + "twitch", + "webhook-ingress", + "webhook-path", + "web-media", + "voice-call", + "whatsapp-core", + "whatsapp-shared", + "zalo", + "zalouser" ] diff --git a/scripts/stage-bundled-plugin-runtime-deps.mjs b/scripts/stage-bundled-plugin-runtime-deps.mjs index b4a516d104d..ba6a6a1183c 100644 --- a/scripts/stage-bundled-plugin-runtime-deps.mjs +++ b/scripts/stage-bundled-plugin-runtime-deps.mjs @@ -7,6 +7,10 @@ function readJson(filePath) { return JSON.parse(fs.readFileSync(filePath, "utf8")); } +function writeJson(filePath, value) { + fs.writeFileSync(filePath, `${JSON.stringify(value, null, 2)}\n`, "utf8"); +} + function removePathIfExists(targetPath) { fs.rmSync(targetPath, { recursive: true, force: true }); } @@ -35,7 +39,51 @@ function shouldStageRuntimeDeps(packageJson) { return packageJson.openclaw?.bundle?.stageRuntimeDependencies === true; } +function sanitizeBundledManifestForRuntimeInstall(pluginDir) { + const manifestPath = path.join(pluginDir, "package.json"); + const packageJson = readJson(manifestPath); + let changed = false; + + if (packageJson.peerDependencies?.openclaw) { + const nextPeerDependencies = { ...packageJson.peerDependencies }; + delete nextPeerDependencies.openclaw; + if (Object.keys(nextPeerDependencies).length === 0) { + delete packageJson.peerDependencies; + } else { + packageJson.peerDependencies = nextPeerDependencies; + } + changed = true; + } + + if (packageJson.peerDependenciesMeta?.openclaw) { + const nextPeerDependenciesMeta = { ...packageJson.peerDependenciesMeta }; + delete nextPeerDependenciesMeta.openclaw; + if (Object.keys(nextPeerDependenciesMeta).length === 0) { + delete packageJson.peerDependenciesMeta; + } else { + packageJson.peerDependenciesMeta = nextPeerDependenciesMeta; + } + changed = true; + } + + if (packageJson.devDependencies?.openclaw) { + const nextDevDependencies = { ...packageJson.devDependencies }; + delete nextDevDependencies.openclaw; + if (Object.keys(nextDevDependencies).length === 0) { + delete packageJson.devDependencies; + } else { + packageJson.devDependencies = nextDevDependencies; + } + changed = true; + } + + if (changed) { + writeJson(manifestPath, packageJson); + } +} + function installPluginRuntimeDeps(pluginDir, pluginId) { + sanitizeBundledManifestForRuntimeInstall(pluginDir); const result = spawnSync( "npm", ["install", "--omit=dev", "--silent", "--ignore-scripts", "--package-lock=false"], diff --git a/src/plugin-sdk/runtime-api-guardrails.test.ts b/src/plugin-sdk/runtime-api-guardrails.test.ts index f9e4c411e6a..a8c2eb87e3e 100644 --- a/src/plugin-sdk/runtime-api-guardrails.test.ts +++ b/src/plugin-sdk/runtime-api-guardrails.test.ts @@ -27,25 +27,25 @@ const RUNTIME_API_EXPORT_GUARDS: Record = { 'export * from "./src/send.js";', ], "extensions/imessage/runtime-api.ts": [ - 'export { DEFAULT_ACCOUNT_ID, PAIRING_APPROVED_MESSAGE, buildChannelConfigSchema, collectStatusIssuesFromLastError, formatTrimmedAllowFromEntries, getChatChannelMeta, looksLikeIMessageTargetId, normalizeIMessageMessagingTarget, resolveChannelMediaMaxBytes, resolveIMessageConfigAllowFrom, resolveIMessageConfigDefaultTo, IMessageConfigSchema, type ChannelPlugin, type IMessageAccountConfig } from "../../src/plugin-sdk/imessage.js";', + 'export { DEFAULT_ACCOUNT_ID, PAIRING_APPROVED_MESSAGE, buildChannelConfigSchema, collectStatusIssuesFromLastError, formatTrimmedAllowFromEntries, getChatChannelMeta, looksLikeIMessageTargetId, normalizeIMessageMessagingTarget, resolveChannelMediaMaxBytes, resolveIMessageConfigAllowFrom, resolveIMessageConfigDefaultTo, IMessageConfigSchema, type ChannelPlugin, type IMessageAccountConfig } from "openclaw/plugin-sdk/imessage";', 'export { resolveIMessageGroupRequireMention, resolveIMessageGroupToolPolicy } from "./src/group-policy.js";', 'export { monitorIMessageProvider } from "./src/monitor.js";', 'export type { MonitorIMessageOpts } from "./src/monitor.js";', 'export { probeIMessage } from "./src/probe.js";', 'export { sendMessageIMessage } from "./src/send.js";', ], - "extensions/googlechat/runtime-api.ts": ['export * from "../../src/plugin-sdk/googlechat.js";'], + "extensions/googlechat/runtime-api.ts": ['export * from "openclaw/plugin-sdk/googlechat";'], "extensions/matrix/runtime-api.ts": [ 'export * from "./src/auth-precedence.js";', 'export * from "./helper-api.js";', 'export { assertHttpUrlTargetsPrivateNetwork, closeDispatcher, createPinnedDispatcher, resolvePinnedHostnameWithPolicy, ssrfPolicyFromAllowPrivateNetwork, type LookupFn, type SsrFPolicy } from "openclaw/plugin-sdk/ssrf-runtime";', 'export { setMatrixThreadBindingIdleTimeoutBySessionKey, setMatrixThreadBindingMaxAgeBySessionKey } from "./thread-bindings-runtime.js";', - 'export { writeJsonFileAtomically } from "../../src/plugin-sdk/json-store.js";', - 'export type { ChannelDirectoryEntry, ChannelMessageActionContext, OpenClawConfig, PluginRuntime, RuntimeLogger, RuntimeEnv, WizardPrompter } from "../../src/plugin-sdk/matrix.js";', - 'export { formatZonedTimestamp } from "../../src/plugin-sdk/matrix.js";', + 'export { writeJsonFileAtomically } from "openclaw/plugin-sdk/json-store";', + 'export type { ChannelDirectoryEntry, ChannelMessageActionContext, OpenClawConfig, PluginRuntime, RuntimeLogger, RuntimeEnv, WizardPrompter } from "openclaw/plugin-sdk/matrix";', + 'export { formatZonedTimestamp } from "openclaw/plugin-sdk/matrix";', ], "extensions/nextcloud-talk/runtime-api.ts": [ - 'export * from "../../src/plugin-sdk/nextcloud-talk.js";', + 'export * from "openclaw/plugin-sdk/nextcloud-talk";', ], "extensions/signal/runtime-api.ts": ['export * from "./src/runtime-api.js";'], "extensions/slack/runtime-api.ts": [ @@ -56,12 +56,12 @@ const RUNTIME_API_EXPORT_GUARDS: Record = { 'export * from "./src/resolve-users.js";', ], "extensions/telegram/runtime-api.ts": [ - 'export type { ChannelMessageActionAdapter, ChannelPlugin, OpenClawConfig, OpenClawPluginApi, PluginRuntime, TelegramAccountConfig, TelegramActionConfig, TelegramNetworkConfig } from "../../src/plugin-sdk/telegram.js";', + 'export type { ChannelMessageActionAdapter, ChannelPlugin, OpenClawConfig, OpenClawPluginApi, PluginRuntime, TelegramAccountConfig, TelegramActionConfig, TelegramNetworkConfig } from "openclaw/plugin-sdk/telegram";', 'export type { OpenClawPluginService, OpenClawPluginServiceContext, PluginLogger } from "openclaw/plugin-sdk/core";', 'export type { AcpRuntime, AcpRuntimeCapabilities, AcpRuntimeDoctorReport, AcpRuntimeEnsureInput, AcpRuntimeEvent, AcpRuntimeHandle, AcpRuntimeStatus, AcpRuntimeTurnInput, AcpRuntimeErrorCode, AcpSessionUpdateTag } from "openclaw/plugin-sdk/acp-runtime";', 'export { AcpRuntimeError } from "openclaw/plugin-sdk/acp-runtime";', - 'export { buildTokenChannelStatusSummary, clearAccountEntryFields, DEFAULT_ACCOUNT_ID, normalizeAccountId, PAIRING_APPROVED_MESSAGE, parseTelegramTopicConversation, projectCredentialSnapshotFields, resolveConfiguredFromCredentialStatuses, resolveTelegramPollVisibility } from "../../src/plugin-sdk/telegram.js";', - 'export { buildChannelConfigSchema, getChatChannelMeta, jsonResult, readNumberParam, readReactionParams, readStringArrayParam, readStringOrNumberParam, readStringParam, resolvePollMaxSelections, TelegramConfigSchema } from "../../src/plugin-sdk/telegram-core.js";', + 'export { buildTokenChannelStatusSummary, clearAccountEntryFields, DEFAULT_ACCOUNT_ID, normalizeAccountId, PAIRING_APPROVED_MESSAGE, parseTelegramTopicConversation, projectCredentialSnapshotFields, resolveConfiguredFromCredentialStatuses, resolveTelegramPollVisibility } from "openclaw/plugin-sdk/telegram";', + 'export { buildChannelConfigSchema, getChatChannelMeta, jsonResult, readNumberParam, readReactionParams, readStringArrayParam, readStringOrNumberParam, readStringParam, resolvePollMaxSelections, TelegramConfigSchema } from "openclaw/plugin-sdk/telegram-core";', 'export type { TelegramProbe } from "./src/probe.js";', 'export { auditTelegramGroupMembership, collectTelegramUnmentionedGroupIds } from "./src/audit.js";', 'export { telegramMessageActions } from "./src/channel-actions.js";', diff --git a/src/plugin-sdk/subpaths.test.ts b/src/plugin-sdk/subpaths.test.ts index d1b22bb9e91..a6c0b0ea822 100644 --- a/src/plugin-sdk/subpaths.test.ts +++ b/src/plugin-sdk/subpaths.test.ts @@ -95,44 +95,22 @@ const statusHelpersSdk = await import("openclaw/plugin-sdk/status-helpers"); describe("plugin-sdk subpath exports", () => { it("keeps the curated public list free of internal implementation subpaths", () => { expect(pluginSdkSubpaths).not.toContain("acpx"); - expect(pluginSdkSubpaths).not.toContain("bluebubbles"); expect(pluginSdkSubpaths).not.toContain("compat"); expect(pluginSdkSubpaths).not.toContain("device-pair"); - expect(pluginSdkSubpaths).not.toContain("feishu"); expect(pluginSdkSubpaths).not.toContain("google"); - expect(pluginSdkSubpaths).not.toContain("googlechat"); - expect(pluginSdkSubpaths).not.toContain("imessage"); - expect(pluginSdkSubpaths).not.toContain("irc"); - expect(pluginSdkSubpaths).not.toContain("imessage-core"); - expect(pluginSdkSubpaths).not.toContain("line"); - expect(pluginSdkSubpaths).not.toContain("line-core"); expect(pluginSdkSubpaths).not.toContain("lobster"); - expect(pluginSdkSubpaths).not.toContain("mattermost"); - expect(pluginSdkSubpaths).not.toContain("matrix"); - expect(pluginSdkSubpaths).not.toContain("msteams"); - expect(pluginSdkSubpaths).not.toContain("nextcloud-talk"); - expect(pluginSdkSubpaths).not.toContain("nostr"); expect(pluginSdkSubpaths).not.toContain("pairing-access"); expect(pluginSdkSubpaths).not.toContain("qwen-portal-auth"); expect(pluginSdkSubpaths).not.toContain("reply-prefix"); expect(pluginSdkSubpaths).not.toContain("signal-core"); - expect(pluginSdkSubpaths).not.toContain("slack"); expect(pluginSdkSubpaths).not.toContain("synology-chat"); - expect(pluginSdkSubpaths).not.toContain("telegram"); - expect(pluginSdkSubpaths).not.toContain("telegram-core"); - expect(pluginSdkSubpaths).not.toContain("tlon"); - expect(pluginSdkSubpaths).not.toContain("twitch"); expect(pluginSdkSubpaths).not.toContain("typing"); - expect(pluginSdkSubpaths).not.toContain("voice-call"); expect(pluginSdkSubpaths).not.toContain("whatsapp"); expect(pluginSdkSubpaths).not.toContain("whatsapp-action-runtime"); - expect(pluginSdkSubpaths).not.toContain("whatsapp-core"); expect(pluginSdkSubpaths).not.toContain("whatsapp-login-qr"); - expect(pluginSdkSubpaths).not.toContain("whatsapp-shared"); expect(pluginSdkSubpaths).not.toContain("secret-input-runtime"); expect(pluginSdkSubpaths).not.toContain("secret-input-schema"); expect(pluginSdkSubpaths).not.toContain("zai"); - expect(pluginSdkSubpaths).not.toContain("slack-core"); expect(pluginSdkSubpaths).not.toContain("provider-model-definitions"); }); diff --git a/test/extension-plugin-sdk-boundary.test.ts b/test/extension-plugin-sdk-boundary.test.ts index ebd02eaa2e5..de6708aa9a1 100644 --- a/test/extension-plugin-sdk-boundary.test.ts +++ b/test/extension-plugin-sdk-boundary.test.ts @@ -1,19 +1,9 @@ -import fs from "node:fs"; -import path from "node:path"; import { describe, expect, it } from "vitest"; import { collectExtensionPluginSdkBoundaryInventory, main, } from "../scripts/check-extension-plugin-sdk-boundary.mjs"; -const repoRoot = process.cwd(); -const relativeOutsidePackageBaselinePath = path.join( - repoRoot, - "test", - "fixtures", - "extension-relative-outside-package-inventory.json", -); - function createCapturedIo() { let stdout = ""; let stderr = ""; @@ -88,20 +78,18 @@ describe("extension plugin-sdk-internal boundary inventory", () => { }); describe("extension relative-outside-package boundary inventory", () => { - it("matches the checked-in baseline", async () => { + it("is currently empty", async () => { const inventory = await collectExtensionPluginSdkBoundaryInventory("relative-outside-package"); - const expected = JSON.parse(fs.readFileSync(relativeOutsidePackageBaselinePath, "utf8")); - expect(inventory).toEqual(expected); + expect(inventory).toEqual([]); }); - it("script json output matches the checked-in baseline", async () => { + it("script json output is empty", async () => { const captured = createCapturedIo(); const exitCode = await main(["--mode=relative-outside-package", "--json"], captured.io); - const expected = JSON.parse(fs.readFileSync(relativeOutsidePackageBaselinePath, "utf8")); expect(exitCode).toBe(0); expect(captured.readStderr()).toBe(""); - expect(JSON.parse(captured.readStdout())).toEqual(expected); + expect(JSON.parse(captured.readStdout())).toEqual([]); }); });