diff --git a/extensions/msteams/src/attachments.test.ts b/extensions/msteams/src/attachments.test.ts index 97ace8819..9f0de1099 100644 --- a/extensions/msteams/src/attachments.test.ts +++ b/extensions/msteams/src/attachments.test.ts @@ -1,4 +1,4 @@ -import type { PluginRuntime, SsrFPolicy } from "openclaw/plugin-sdk"; +import type { PluginRuntime, SsrFPolicy } from "openclaw/plugin-sdk/compat"; import { beforeEach, describe, expect, it, vi } from "vitest"; import { createPluginRuntimeMock } from "../../test-utils/plugin-runtime-mock.js"; import { diff --git a/extensions/msteams/src/attachments/graph.ts b/extensions/msteams/src/attachments/graph.ts index a50356e3c..c9f632c7f 100644 --- a/extensions/msteams/src/attachments/graph.ts +++ b/extensions/msteams/src/attachments/graph.ts @@ -1,4 +1,4 @@ -import { fetchWithSsrFGuard, type SsrFPolicy } from "openclaw/plugin-sdk"; +import { fetchWithSsrFGuard, type SsrFPolicy } from "openclaw/plugin-sdk/compat"; import { getMSTeamsRuntime } from "../runtime.js"; import { downloadMSTeamsAttachments } from "./download.js"; import { downloadAndStoreMSTeamsRemoteMedia } from "./remote-media.js"; diff --git a/extensions/msteams/src/attachments/payload.ts b/extensions/msteams/src/attachments/payload.ts index 2049609d8..2134a382f 100644 --- a/extensions/msteams/src/attachments/payload.ts +++ b/extensions/msteams/src/attachments/payload.ts @@ -1,4 +1,4 @@ -import { buildMediaPayload } from "openclaw/plugin-sdk"; +import { buildMediaPayload } from "openclaw/plugin-sdk/compat"; export function buildMSTeamsMediaPayload( mediaList: Array<{ path: string; contentType?: string }>, diff --git a/extensions/msteams/src/attachments/remote-media.ts b/extensions/msteams/src/attachments/remote-media.ts index 162a797b5..b31b47723 100644 --- a/extensions/msteams/src/attachments/remote-media.ts +++ b/extensions/msteams/src/attachments/remote-media.ts @@ -1,4 +1,4 @@ -import type { SsrFPolicy } from "openclaw/plugin-sdk"; +import type { SsrFPolicy } from "openclaw/plugin-sdk/compat"; import { getMSTeamsRuntime } from "../runtime.js"; import { inferPlaceholder } from "./shared.js"; import type { MSTeamsInboundMedia } from "./types.js"; diff --git a/extensions/msteams/src/attachments/shared.ts b/extensions/msteams/src/attachments/shared.ts index 7897b5280..3222be248 100644 --- a/extensions/msteams/src/attachments/shared.ts +++ b/extensions/msteams/src/attachments/shared.ts @@ -4,8 +4,8 @@ import { isHttpsUrlAllowedByHostnameSuffixAllowlist, isPrivateIpAddress, normalizeHostnameSuffixAllowlist, -} from "openclaw/plugin-sdk"; -import type { SsrFPolicy } from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; +import type { SsrFPolicy } from "openclaw/plugin-sdk/compat"; import type { MSTeamsAttachmentLike } from "./types.js"; type InlineImageCandidate = diff --git a/extensions/msteams/src/channel.directory.test.ts b/extensions/msteams/src/channel.directory.test.ts index 26a9bec2f..97bfd227f 100644 --- a/extensions/msteams/src/channel.directory.test.ts +++ b/extensions/msteams/src/channel.directory.test.ts @@ -1,4 +1,4 @@ -import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk"; +import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk/compat"; import { describe, expect, it } from "vitest"; import { msteamsPlugin } from "./channel.js"; diff --git a/extensions/msteams/src/channel.ts b/extensions/msteams/src/channel.ts index 16c7ad0fb..057f37c83 100644 --- a/extensions/msteams/src/channel.ts +++ b/extensions/msteams/src/channel.ts @@ -1,4 +1,8 @@ -import type { ChannelMessageActionName, ChannelPlugin, OpenClawConfig } from "openclaw/plugin-sdk"; +import type { + ChannelMessageActionName, + ChannelPlugin, + OpenClawConfig, +} from "openclaw/plugin-sdk/compat"; import { buildBaseChannelStatusSummary, buildChannelConfigSchema, @@ -8,7 +12,7 @@ import { PAIRING_APPROVED_MESSAGE, resolveAllowlistProviderRuntimeGroupPolicy, resolveDefaultGroupPolicy, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { listMSTeamsDirectoryGroupsLive, listMSTeamsDirectoryPeersLive } from "./directory-live.js"; import { msteamsOnboardingAdapter } from "./onboarding.js"; import { msteamsOutbound } from "./outbound.js"; diff --git a/extensions/msteams/src/directory-live.ts b/extensions/msteams/src/directory-live.ts index 06b2485eb..0e2464aa0 100644 --- a/extensions/msteams/src/directory-live.ts +++ b/extensions/msteams/src/directory-live.ts @@ -1,4 +1,4 @@ -import type { ChannelDirectoryEntry } from "openclaw/plugin-sdk"; +import type { ChannelDirectoryEntry } from "openclaw/plugin-sdk/compat"; import { searchGraphUsers } from "./graph-users.js"; import { type GraphChannel, diff --git a/extensions/msteams/src/file-lock.ts b/extensions/msteams/src/file-lock.ts index 02bf9aa5b..9c5782b9f 100644 --- a/extensions/msteams/src/file-lock.ts +++ b/extensions/msteams/src/file-lock.ts @@ -1 +1 @@ -export { withFileLock } from "openclaw/plugin-sdk"; +export { withFileLock } from "openclaw/plugin-sdk/compat"; diff --git a/extensions/msteams/src/graph.ts b/extensions/msteams/src/graph.ts index d2c210153..983bfe9ed 100644 --- a/extensions/msteams/src/graph.ts +++ b/extensions/msteams/src/graph.ts @@ -1,4 +1,4 @@ -import type { MSTeamsConfig } from "openclaw/plugin-sdk"; +import type { MSTeamsConfig } from "openclaw/plugin-sdk/compat"; import { GRAPH_ROOT } from "./attachments/shared.js"; import { loadMSTeamsSdkWithAuth } from "./sdk.js"; import { readAccessToken } from "./token-response.js"; diff --git a/extensions/msteams/src/media-helpers.ts b/extensions/msteams/src/media-helpers.ts index bfe113d40..f8a36e55f 100644 --- a/extensions/msteams/src/media-helpers.ts +++ b/extensions/msteams/src/media-helpers.ts @@ -8,7 +8,7 @@ import { extensionForMime, extractOriginalFilename, getFileExtension, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; /** * Detect MIME type from URL extension or data URL. diff --git a/extensions/msteams/src/messenger.test.ts b/extensions/msteams/src/messenger.test.ts index 0857f8d5c..973bbb679 100644 --- a/extensions/msteams/src/messenger.test.ts +++ b/extensions/msteams/src/messenger.test.ts @@ -1,7 +1,7 @@ import { mkdtemp, rm, writeFile } from "node:fs/promises"; import os from "node:os"; import path from "node:path"; -import { SILENT_REPLY_TOKEN, type PluginRuntime } from "openclaw/plugin-sdk"; +import { SILENT_REPLY_TOKEN, type PluginRuntime } from "openclaw/plugin-sdk/compat"; import { beforeEach, describe, expect, it, vi } from "vitest"; import { createPluginRuntimeMock } from "../../test-utils/plugin-runtime-mock.js"; import type { StoredConversationReference } from "./conversation-store.js"; diff --git a/extensions/msteams/src/messenger.ts b/extensions/msteams/src/messenger.ts index 4a9131929..c412c47d0 100644 --- a/extensions/msteams/src/messenger.ts +++ b/extensions/msteams/src/messenger.ts @@ -7,7 +7,7 @@ import { type ReplyPayload, SILENT_REPLY_TOKEN, sleep, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import type { MSTeamsAccessTokenProvider } from "./attachments/types.js"; import type { StoredConversationReference } from "./conversation-store.js"; import { classifyMSTeamsSendError } from "./errors.js"; diff --git a/extensions/msteams/src/monitor-handler.file-consent.test.ts b/extensions/msteams/src/monitor-handler.file-consent.test.ts index 386ffc348..8288668ba 100644 --- a/extensions/msteams/src/monitor-handler.file-consent.test.ts +++ b/extensions/msteams/src/monitor-handler.file-consent.test.ts @@ -1,4 +1,4 @@ -import type { OpenClawConfig, PluginRuntime, RuntimeEnv } from "openclaw/plugin-sdk"; +import type { OpenClawConfig, PluginRuntime, RuntimeEnv } from "openclaw/plugin-sdk/compat"; import { beforeEach, describe, expect, it, vi } from "vitest"; import type { MSTeamsConversationStore } from "./conversation-store.js"; import type { MSTeamsAdapter } from "./messenger.js"; diff --git a/extensions/msteams/src/monitor-handler.ts b/extensions/msteams/src/monitor-handler.ts index ac1b469e8..b64fdee6d 100644 --- a/extensions/msteams/src/monitor-handler.ts +++ b/extensions/msteams/src/monitor-handler.ts @@ -1,4 +1,4 @@ -import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk"; +import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk/compat"; import type { MSTeamsConversationStore } from "./conversation-store.js"; import { buildFileInfoCard, parseFileConsentInvoke, uploadToConsentUrl } from "./file-consent.js"; import { normalizeMSTeamsConversationId } from "./inbound.js"; diff --git a/extensions/msteams/src/monitor-handler/message-handler.authz.test.ts b/extensions/msteams/src/monitor-handler/message-handler.authz.test.ts index 2be36f897..7e8118b56 100644 --- a/extensions/msteams/src/monitor-handler/message-handler.authz.test.ts +++ b/extensions/msteams/src/monitor-handler/message-handler.authz.test.ts @@ -1,4 +1,4 @@ -import type { OpenClawConfig, PluginRuntime, RuntimeEnv } from "openclaw/plugin-sdk"; +import type { OpenClawConfig, PluginRuntime, RuntimeEnv } from "openclaw/plugin-sdk/compat"; import { describe, expect, it, vi } from "vitest"; import type { MSTeamsMessageHandlerDeps } from "../monitor-handler.js"; import { setMSTeamsRuntime } from "../runtime.js"; diff --git a/extensions/msteams/src/monitor-handler/message-handler.ts b/extensions/msteams/src/monitor-handler/message-handler.ts index a85e06348..0bdb91426 100644 --- a/extensions/msteams/src/monitor-handler/message-handler.ts +++ b/extensions/msteams/src/monitor-handler/message-handler.ts @@ -15,7 +15,7 @@ import { resolveEffectiveAllowFromLists, resolveDmGroupAccessWithLists, type HistoryEntry, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { buildMSTeamsAttachmentPlaceholder, buildMSTeamsMediaPayload, diff --git a/extensions/msteams/src/monitor.lifecycle.test.ts b/extensions/msteams/src/monitor.lifecycle.test.ts index 980b0871b..560b2839e 100644 --- a/extensions/msteams/src/monitor.lifecycle.test.ts +++ b/extensions/msteams/src/monitor.lifecycle.test.ts @@ -1,5 +1,5 @@ import { EventEmitter } from "node:events"; -import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk"; +import type { OpenClawConfig, RuntimeEnv } from "openclaw/plugin-sdk/compat"; import { afterEach, describe, expect, it, vi } from "vitest"; import type { MSTeamsConversationStore } from "./conversation-store.js"; import type { MSTeamsPollStore } from "./polls.js"; diff --git a/extensions/msteams/src/monitor.ts b/extensions/msteams/src/monitor.ts index f2adba521..432af67ad 100644 --- a/extensions/msteams/src/monitor.ts +++ b/extensions/msteams/src/monitor.ts @@ -7,7 +7,7 @@ import { summarizeMapping, type OpenClawConfig, type RuntimeEnv, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { createMSTeamsConversationStoreFs } from "./conversation-store-fs.js"; import type { MSTeamsConversationStore } from "./conversation-store.js"; import { formatUnknownError } from "./errors.js"; diff --git a/extensions/msteams/src/onboarding.ts b/extensions/msteams/src/onboarding.ts index c40d88b2b..e5836cc73 100644 --- a/extensions/msteams/src/onboarding.ts +++ b/extensions/msteams/src/onboarding.ts @@ -5,14 +5,14 @@ import type { DmPolicy, WizardPrompter, MSTeamsTeamConfig, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { addWildcardAllowFrom, DEFAULT_ACCOUNT_ID, formatDocsLink, mergeAllowFromEntries, promptChannelAccessConfig, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { parseMSTeamsTeamEntry, resolveMSTeamsChannelAllowlist, diff --git a/extensions/msteams/src/outbound.ts b/extensions/msteams/src/outbound.ts index 3a401f13d..ca2edc398 100644 --- a/extensions/msteams/src/outbound.ts +++ b/extensions/msteams/src/outbound.ts @@ -1,4 +1,4 @@ -import type { ChannelOutboundAdapter } from "openclaw/plugin-sdk"; +import type { ChannelOutboundAdapter } from "openclaw/plugin-sdk/compat"; import { createMSTeamsPollStoreFs } from "./polls.js"; import { getMSTeamsRuntime } from "./runtime.js"; import { sendMessageMSTeams, sendPollMSTeams } from "./send.js"; diff --git a/extensions/msteams/src/policy.test.ts b/extensions/msteams/src/policy.test.ts index 3c7daa58b..81582cb85 100644 --- a/extensions/msteams/src/policy.test.ts +++ b/extensions/msteams/src/policy.test.ts @@ -1,4 +1,4 @@ -import type { MSTeamsConfig } from "openclaw/plugin-sdk"; +import type { MSTeamsConfig } from "openclaw/plugin-sdk/compat"; import { describe, expect, it } from "vitest"; import { isMSTeamsGroupAllowed, diff --git a/extensions/msteams/src/policy.ts b/extensions/msteams/src/policy.ts index a3545c059..c55a8433b 100644 --- a/extensions/msteams/src/policy.ts +++ b/extensions/msteams/src/policy.ts @@ -7,7 +7,7 @@ import type { MSTeamsConfig, MSTeamsReplyStyle, MSTeamsTeamConfig, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import { buildChannelKeyCandidates, normalizeChannelSlug, @@ -15,7 +15,7 @@ import { resolveToolsBySender, resolveChannelEntryMatchWithFallback, resolveNestedAllowlistDecision, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; export type MSTeamsResolvedRouteConfig = { teamConfig?: MSTeamsTeamConfig; diff --git a/extensions/msteams/src/probe.test.ts b/extensions/msteams/src/probe.test.ts index b9c18019a..9ab758b27 100644 --- a/extensions/msteams/src/probe.test.ts +++ b/extensions/msteams/src/probe.test.ts @@ -1,4 +1,4 @@ -import type { MSTeamsConfig } from "openclaw/plugin-sdk"; +import type { MSTeamsConfig } from "openclaw/plugin-sdk/compat"; import { describe, expect, it, vi } from "vitest"; const hostMockState = vi.hoisted(() => ({ diff --git a/extensions/msteams/src/probe.ts b/extensions/msteams/src/probe.ts index 8434fa504..46dd27477 100644 --- a/extensions/msteams/src/probe.ts +++ b/extensions/msteams/src/probe.ts @@ -1,4 +1,4 @@ -import type { BaseProbeResult, MSTeamsConfig } from "openclaw/plugin-sdk"; +import type { BaseProbeResult, MSTeamsConfig } from "openclaw/plugin-sdk/compat"; import { formatUnknownError } from "./errors.js"; import { loadMSTeamsSdkWithAuth } from "./sdk.js"; import { readAccessToken } from "./token-response.js"; diff --git a/extensions/msteams/src/reply-dispatcher.ts b/extensions/msteams/src/reply-dispatcher.ts index 3ddf7b18c..e940fd237 100644 --- a/extensions/msteams/src/reply-dispatcher.ts +++ b/extensions/msteams/src/reply-dispatcher.ts @@ -6,7 +6,7 @@ import { type OpenClawConfig, type MSTeamsReplyStyle, type RuntimeEnv, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import type { MSTeamsAccessTokenProvider } from "./attachments/types.js"; import type { StoredConversationReference } from "./conversation-store.js"; import { diff --git a/extensions/msteams/src/runtime.ts b/extensions/msteams/src/runtime.ts index deb09f3eb..86c8f9a34 100644 --- a/extensions/msteams/src/runtime.ts +++ b/extensions/msteams/src/runtime.ts @@ -1,4 +1,4 @@ -import type { PluginRuntime } from "openclaw/plugin-sdk"; +import type { PluginRuntime } from "openclaw/plugin-sdk/compat"; let runtime: PluginRuntime | null = null; diff --git a/extensions/msteams/src/secret-input.ts b/extensions/msteams/src/secret-input.ts index 0e24edc05..fc64ca00f 100644 --- a/extensions/msteams/src/secret-input.ts +++ b/extensions/msteams/src/secret-input.ts @@ -2,6 +2,6 @@ import { hasConfiguredSecretInput, normalizeResolvedSecretInputString, normalizeSecretInputString, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; export { hasConfiguredSecretInput, normalizeResolvedSecretInputString, normalizeSecretInputString }; diff --git a/extensions/msteams/src/send-context.ts b/extensions/msteams/src/send-context.ts index af617a715..389aed43b 100644 --- a/extensions/msteams/src/send-context.ts +++ b/extensions/msteams/src/send-context.ts @@ -2,7 +2,7 @@ import { resolveChannelMediaMaxBytes, type OpenClawConfig, type PluginRuntime, -} from "openclaw/plugin-sdk"; +} from "openclaw/plugin-sdk/compat"; import type { MSTeamsAccessTokenProvider } from "./attachments/types.js"; import { createMSTeamsConversationStoreFs } from "./conversation-store-fs.js"; import type { diff --git a/extensions/msteams/src/send.test.ts b/extensions/msteams/src/send.test.ts index cbab8459d..3c826310c 100644 --- a/extensions/msteams/src/send.test.ts +++ b/extensions/msteams/src/send.test.ts @@ -1,4 +1,4 @@ -import type { OpenClawConfig } from "openclaw/plugin-sdk"; +import type { OpenClawConfig } from "openclaw/plugin-sdk/compat"; import { beforeEach, describe, expect, it, vi } from "vitest"; import { sendMessageMSTeams } from "./send.js"; diff --git a/extensions/msteams/src/send.ts b/extensions/msteams/src/send.ts index 2ddb12df1..3adb3a143 100644 --- a/extensions/msteams/src/send.ts +++ b/extensions/msteams/src/send.ts @@ -1,5 +1,5 @@ -import type { OpenClawConfig } from "openclaw/plugin-sdk"; -import { loadOutboundMediaFromUrl } from "openclaw/plugin-sdk"; +import type { OpenClawConfig } from "openclaw/plugin-sdk/compat"; +import { loadOutboundMediaFromUrl } from "openclaw/plugin-sdk/compat"; import { createMSTeamsConversationStoreFs } from "./conversation-store-fs.js"; import { classifyMSTeamsSendError, diff --git a/extensions/msteams/src/store-fs.ts b/extensions/msteams/src/store-fs.ts index c13c7dd55..c96e96d89 100644 --- a/extensions/msteams/src/store-fs.ts +++ b/extensions/msteams/src/store-fs.ts @@ -1,5 +1,5 @@ import fs from "node:fs"; -import { readJsonFileWithFallback, writeJsonFileAtomically } from "openclaw/plugin-sdk"; +import { readJsonFileWithFallback, writeJsonFileAtomically } from "openclaw/plugin-sdk/compat"; import { withFileLock as withPathLock } from "./file-lock.js"; const STORE_LOCK_OPTIONS = { diff --git a/extensions/msteams/src/test-runtime.ts b/extensions/msteams/src/test-runtime.ts index e32a8288a..6cc480035 100644 --- a/extensions/msteams/src/test-runtime.ts +++ b/extensions/msteams/src/test-runtime.ts @@ -1,6 +1,6 @@ import os from "node:os"; import path from "node:path"; -import type { PluginRuntime } from "openclaw/plugin-sdk"; +import type { PluginRuntime } from "openclaw/plugin-sdk/compat"; export const msteamsRuntimeStub = { state: { diff --git a/extensions/msteams/src/token.ts b/extensions/msteams/src/token.ts index c55146993..862030ba0 100644 --- a/extensions/msteams/src/token.ts +++ b/extensions/msteams/src/token.ts @@ -1,4 +1,4 @@ -import type { MSTeamsConfig } from "openclaw/plugin-sdk"; +import type { MSTeamsConfig } from "openclaw/plugin-sdk/compat"; import { hasConfiguredSecretInput, normalizeResolvedSecretInputString,