Skip to content

chore: release#2653

Merged
WilliamBergamin merged 1 commit into
mainfrom
changeset-release/main
Jul 14, 2026
Merged

chore: release#2653
WilliamBergamin merged 1 commit into
mainfrom
changeset-release/main

Conversation

@github-actions

@github-actions github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or setup this action to publish automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@slack/cli-hooks@2.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

@slack/cli-test@5.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

@slack/logger@5.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

@slack/oauth@4.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

  • fc98c8c: Error classes now extend a new SlackOAuthError abstract base class (which extends Error), bringing @slack/oauth in line with the error handling in @slack/web-api and @slack/webhook. You can catch any error thrown by this package with if (error instanceof SlackOAuthError), in addition to the existing per-class instanceof checks (AuthorizationError, InstallerInitializationError, etc.).

    AuthorizationError now populates the standard Error.cause property with the underlying error when one is available (for example, the failure that caused authorize() to reject). The existing original property is still present and carries the same value.

    import { AuthorizationError } from "@slack/oauth";
    
    try {
      await installer.authorize({ teamId, enterpriseId });
    } catch (error) {
      if (error instanceof AuthorizationError) {
        console.log(error.cause); // the underlying error
        console.log(error.original); // same value — kept for backward compat
      }
    }

    The error.code property and ErrorCode enum values are unchanged, so existing error.code checks continue to work. The CodedError interface is retained (it is part of the public CallbackOptions#failure callback signature), but for new code we recommend instanceof checks against SlackOAuthError or a specific subclass.

    Note: error.name now reflects the specific class name (e.g. 'AuthorizationError') instead of the generic 'Error'. If you branch on error.name, update those checks accordingly.

  • fc98c8c: Updated the internal @slack/web-api dependency from ^7 to ^8. If you pass clientOptions to InstallProvider, the following options are no longer available:

    • clientOptions.agent — Use clientOptions.fetch with a custom fetch implementation instead.
    • clientOptions.tls — Configure TLS via clientOptions.fetch or the NODE_EXTRA_CA_CERTS environment variable.
    import { InstallProvider } from "@slack/oauth";
    import { fetch, Agent } from "undici";
    
    const installer = new InstallProvider({
      clientId: process.env.SLACK_CLIENT_ID,
      clientSecret: process.env.SLACK_CLIENT_SECRET,
      stateSecret: "my-secret",
      clientOptions: {
        fetch: (url, init) =>
          fetch(url, {
            ...init,
            dispatcher: new Agent({ connect: { ca: myCA } }),
          }),
      },
    });

    See the @slack/web-api v8 changelog for the full list of breaking changes that affect clientOptions.

Patch Changes

  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [bb49d99]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
    • @slack/logger@5.0.0
    • @slack/web-api@8.0.0

@slack/socket-mode@3.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

  • fc98c8c: Redesigned error handling to use proper Error subclasses instead of plain objects with a code property.

    Migration: Replace if (error.code === ErrorCode.WebsocketError) with if (error instanceof SMWebsocketError).

    New error classes (all extend a common SlackSocketModeError abstract base class, which extends Error):

    • SMPlatformError — Slack platform returned an error event
    • SMWebsocketError — WebSocket connection failure (original error in cause)
    • SMNoReplyReceivedError — Timed out waiting for a reply to an acknowledgement
    • SMSendWhileDisconnectedError — Attempted to send while not connected
    • SMSendWhileNotReadyError — Attempted to send before the connection was ready

    Catch any socket-mode error with if (error instanceof SlackSocketModeError).

    Removed factory functions (use new with the corresponding class instead):

    • websocketErrorWithOriginal()new SMWebsocketError(original)
    • platformErrorFromEvent()new SMPlatformError(event)
    • noReplyReceivedError()new SMNoReplyReceivedError()
    • sendWhileDisconnectedError()new SMSendWhileDisconnectedError()
    • sendWhileNotReadyError()new SMSendWhileNotReadyError()

    The CodedError interface is deprecated — use instanceof checks with specific error classes instead. The error.code property still exists for backward-compatible checks, but error.name values changed from generic 'Error' to descriptive class names (e.g., 'SMWebsocketError').

  • fc98c8c: Replaced the ws WebSocket library with a spec-compliant WebSocket implementation backed by undici. undici@^7 is now a peer dependency that must be installed alongside @slack/socket-mode:

    npm install @slack/socket-mode undici@^7

    Removed options:

    • clientOptions.agent (the httpAgent passed to the underlying web-api client). Use the new top-level dispatcher option instead. The dispatcher handles both the WebSocket connection and HTTP API calls (unless clientOptions.fetch is also provided, in which case dispatcher only applies to WebSocket).

    New dispatcher option:

    import { SocketModeClient } from "@slack/socket-mode";
    import { ProxyAgent } from "undici";
    
    const client = new SocketModeClient({
      appToken: process.env.SLACK_APP_TOKEN,
      dispatcher: new ProxyAgent("http://proxy:3128"),
    });

    For simple proxy use cases, prefer the Node.js built-in proxy support: call http.setGlobalProxyFromEnv() at startup or set NODE_USE_ENV_PROXY=1 (Node.js 24+) with HTTP_PROXY/HTTPS_PROXY environment variables.

    The dispatcher option accepts any object implementing the SocketModeDispatcher interface (structurally compatible with undici's Agent, ProxyAgent, Client, etc.).

    This package now depends on @slack/web-api@^8 — any clientOptions you pass are subject to web-api v8 breaking changes (e.g., the agent and tls options are no longer available; use clientOptions.fetch instead).

Patch Changes

  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [bb49d99]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
    • @slack/logger@5.0.0
    • @slack/web-api@8.0.0

@slack/types@3.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

@slack/web-api@8.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

  • fc98c8c: Redesigned error handling to use proper Error subclasses instead of plain objects with a code property.

    Migration: Replace if (error.code === ErrorCode.PlatformError) with if (error instanceof WebAPIPlatformError). All error classes extend a common SlackError base class (which extends Error), so you can also catch all SDK errors with if (error instanceof SlackError).

    New error class hierarchy:

    • SlackError (abstract base)
      • WebAPIPlatformError — Slack API returned ok: false
      • WebAPIRequestError — Network/transport failure (original error in cause)
      • WebAPIHTTPError — Non-200 HTTP status from Slack
      • WebAPIRateLimitedError — HTTP 429 with retryAfter seconds
      • WebAPIFileUploadInvalidArgumentsError — Invalid file upload arguments
      • WebAPIFileUploadReadFileDataError — Failed to read file data for upload

    Removed factory functions (these were internal but exported — use new with the corresponding class instead):

    • errorWithCode()
    • platformErrorFromResult()new WebAPIPlatformError(...)
    • requestErrorWithOriginal()new WebAPIRequestError(...)
    • httpErrorFromResponse()new WebAPIHTTPError(...)
    • rateLimitedErrorWithDelay()new WebAPIRateLimitedError(...)

    Other breaking type changes:

    • WebAPIHTTPError.headers type changed from IncomingHttpHeaders to Record<string, string>.
    • The CodedError interface is deprecated — use instanceof checks with specific error classes instead.
    • Error .name values changed from generic 'Error' to descriptive class names (e.g., 'WebAPIPlatformError').
  • fc98c8c: Replaced axios with the standard Fetch API for all HTTP transport. The following options and types have been removed from WebClientOptions:

    • agent — Use the new fetch option to provide a custom fetch implementation with proxy or keep-alive support. For proxies, prefer the built-in http.setGlobalProxyFromEnv() or NODE_USE_ENV_PROXY=1 (Node.js 24+). For advanced use cases:
      import { fetch, Agent } from "undici";
      const client = new WebClient(token, {
        fetch: (url, init) =>
          fetch(url, {
            ...init,
            dispatcher: new Agent({ keepAliveTimeout: 60_000 }),
          }),
      });
    • tls and TLSOptions — Configure TLS via a custom fetch implementation with an undici Agent, or use the NODE_EXTRA_CA_CERTS environment variable.
    • requestInterceptor and RequestInterceptor type — Wrap the fetch function to intercept or modify requests before they are sent.
    • adapter and AdapterConfig type — Use the fetch option instead.
    • RequestConfig type (was an alias for Axios' InternalAxiosRequestConfig) — Removed entirely.
    • attachOriginalToWebAPIRequestError option — Removed. The original error is now always available via the standard cause property on WebAPIRequestError.

    The dependencies axios, form-data, is-electron, and is-stream have been removed. The default fetch implementation is globalThis.fetch (available in Node.js 20+).

    New exported types for custom fetch implementations: FetchFunction, FetchResponse, FetchRequestInit, FetchHeaders.

  • fc98c8c: Removed previously-deprecated API methods and their associated request/response types:

    • files.upload — Use filesUploadV2 instead (available since v6.7). The filesUploadV2 method handles the multi-step upload process automatically.
    • rtm.start — Use rtm.connect instead. The rtm.start method was deprecated by Slack in favor of the lighter-weight rtm.connect.
    • workflows.stepCompleted, workflows.stepFailed, workflows.updateStep — These methods supported the retired Steps from Apps feature (deprecated August 2023, retired September 2024). The workflows.featured.* and admin.workflows.* methods for the current Workflow Builder remain available.

Minor Changes

  • fc98c8c: feat: expand app manifest types — add agent_view and assistant_view features, recent agent events (app_context_changed, assistant_thread_started, assistant_thread_context_changed), optional OAuth scopes (bot_optional/user_optional), and event metadata_subscriptions

Patch Changes

  • bb49d99: fix: apply redact() to API response bodies in debug logs and recurse into nested objects, preventing tokens from leaking into logs when debug logging is enabled
  • Updated dependencies [fc98c8c]
  • Updated dependencies [fc98c8c]
    • @slack/logger@5.0.0
    • @slack/types@3.0.0

@slack/webhook@8.0.0

Major Changes

  • fc98c8c: Drop Node.js 18 support. The minimum supported Node.js version is now 20.

  • fc98c8c: Restructured error classes to use proper Error subclasses extending a new SlackWebhookError base class.

    Breaking changes to IncomingWebhookHTTPError:

    • The original property has been removed. HTTP response details are now direct properties:
      • statusCode: number
      • statusMessage: string
      • body: string
    • Migrate from error.original.response.status to error.statusCode, error.original.response.data to error.body, etc.

    Breaking changes to IncomingWebhookRequestError:

    • The original property is now a standard Error (previously it was an AxiosError). The original error is also available via the standard cause property.

    Removed factory functions (use new with the corresponding class instead):

    • requestErrorWithOriginal()new IncomingWebhookRequestError(original)
    • httpErrorWithOriginal()new IncomingWebhookHTTPError(statusCode, statusMessage, body)
    • errorWithCode() — Use the specific error class directly.

    Migration: Replace if (error.code === ErrorCode.HTTPError) with if (error instanceof IncomingWebhookHTTPError). You can also catch all webhook errors with if (error instanceof SlackWebhookError).

    The CodedError interface is deprecated — use instanceof checks with the SlackWebhookError base class or specific error subclasses instead.

  • fc98c8c: Replaced axios with the standard Fetch API for HTTP transport.

    Removed options from IncomingWebhookDefaultArguments:

    • agent — Use the new fetch option to provide a custom fetch implementation with proxy or TLS support. For proxies, prefer the built-in http.setGlobalProxyFromEnv() or NODE_USE_ENV_PROXY=1 (Node.js 24+). For advanced use cases:
      import { fetch, Agent } from "undici";
      const webhook = new IncomingWebhook(url, {
        fetch: (url, init) =>
          fetch(url, {
            ...init,
            dispatcher: new Agent({ connect: { ca: myCA } }),
          }),
      });

    The axios dependency has been removed. The default fetch implementation is globalThis.fetch (available in Node.js 20+). The timeout option remains available and is implemented via AbortController.

Minor Changes

  • fc98c8c: feat: add WebhookTrigger class for Workflow Builder triggers and opt-in retries for IncomingWebhook and WebhookTrigger

    WebhookTrigger surfaces its own WebhookTriggerHTTPError and WebhookTriggerRequestError (subclasses of SlackWebhookError), so trigger failures can be distinguished from IncomingWebhook failures via instanceof.

Patch Changes

  • Updated dependencies [fc98c8c]
    • @slack/types@3.0.0

@github-actions github-actions Bot force-pushed the changeset-release/main branch from dd8a55c to aa7f917 Compare July 13, 2026 19:03
@github-actions github-actions Bot force-pushed the changeset-release/main branch from aa7f917 to 6c2d199 Compare July 14, 2026 17:45
@WilliamBergamin WilliamBergamin marked this pull request as ready for review July 14, 2026 17:49
@WilliamBergamin WilliamBergamin requested review from a team as code owners July 14, 2026 17:49
@WilliamBergamin WilliamBergamin self-assigned this Jul 14, 2026
@codecov

codecov Bot commented Jul 14, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.17%. Comparing base (fc98c8c) to head (6c2d199).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2653   +/-   ##
=======================================
  Coverage   89.17%   89.17%           
=======================================
  Files          65       65           
  Lines       10339    10339           
  Branches      474      474           
=======================================
  Hits         9220     9220           
  Misses       1091     1091           
  Partials       28       28           
Flag Coverage Δ
cli-hooks 89.17% <ø> (ø)
cli-test 89.17% <ø> (ø)
logger 89.17% <ø> (ø)
oauth 89.17% <ø> (ø)
socket-mode 89.17% <ø> (ø)
web-api 89.17% <ø> (ø)
webhook 89.17% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@WilliamBergamin WilliamBergamin added semver:major pkg:web-api applies to `@slack/web-api` pkg:webhook applies to `@slack/webhook` pkg:logger applies to `@slack/logger` pkg:types applies to `@slack/types` pkg:oauth applies to `@slack/oauth` pkg:socket-mode applies to `@slack/socket-mode` release pkg:cli-hooks applies to `@slack/cli-hooks` pkg:cli-test applies to `@slack/cli-test` labels Jul 14, 2026
@WilliamBergamin WilliamBergamin merged commit 70e15b8 into main Jul 14, 2026
12 checks passed
@WilliamBergamin WilliamBergamin deleted the changeset-release/main branch July 14, 2026 17:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg:cli-hooks applies to `@slack/cli-hooks` pkg:cli-test applies to `@slack/cli-test` pkg:logger applies to `@slack/logger` pkg:oauth applies to `@slack/oauth` pkg:socket-mode applies to `@slack/socket-mode` pkg:types applies to `@slack/types` pkg:web-api applies to `@slack/web-api` pkg:webhook applies to `@slack/webhook` release semver:major

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant