fix(slack): handle bolt CJS interop (#1191) — thanks @CoreyH

Co-authored-by: Corey Henderson <corey@example.com>
This commit is contained in:
Peter Steinberger
2026-01-18 23:54:50 +00:00
parent 6f5205d826
commit b5e99dad1f
2 changed files with 6 additions and 1 deletions

View File

@@ -18,6 +18,7 @@ Docs: https://docs.clawd.bot
- macOS: suppress usage error text in the menubar cost view.
- Telegram: honor pairing allowlists for native slash commands.
- CLI: keep banners on routed commands, restore config guarding outside fast-path routing, and tighten fast-path flag parsing while skipping console capture for extra speed. (#1195) — thanks @gumadeiras.
- Slack: resolve Bolt import interop for Bun + Node. (#1191) — thanks @CoreyH.
## 2026.1.18-4

View File

@@ -26,7 +26,11 @@ import { normalizeAllowList } from "./allow-list.js";
import type { MonitorSlackOpts } from "./types.js";
const { App, HTTPReceiver } = SlackBolt as typeof import("@slack/bolt");
const slackBoltModule = SlackBolt as typeof import("@slack/bolt") & {
default?: typeof import("@slack/bolt");
};
const slackBolt = slackBoltModule.default ?? slackBoltModule;
const { App, HTTPReceiver } = slackBolt;
function parseApiAppIdFromAppToken(raw?: string) {
const token = raw?.trim();
if (!token) return undefined;