Skip to content

fix(web-api): add broadcast_delete argument to chat.delete - #2816

Open
kai-at-momos wants to merge 1 commit into
slackapi:mainfrom
kai-at-momos:feat/chat-delete-broadcast-delete
Open

kai-at-momos wants to merge 1 commit into
slackapi:mainfrom
kai-at-momos:feat/chat-delete-broadcast-delete

Conversation

@kai-at-momos

Copy link
Copy Markdown

Summary

Adds the optional broadcast_delete argument to ChatDeleteArguments.

chat.delete with broadcast_delete: true on a thread reply that was also sent to the channel (subtype: thread_broadcast) removes it from the channel only. The reply stays in its thread with the same ts. This is what the Slack client sends for "Remove from channel", and it works with a bot token too.

It is the only way to reverse reply_broadcast. chat.update with reply_broadcast: false returns ok: true and changes nothing.

Verified against the live API with a bot token:

  1. chat.postMessage with thread_ts + reply_broadcast: true -> thread_broadcast in conversations.history
  2. chat.delete with broadcast_delete: true -> ok: true
  3. the message is gone from conversations.history and still in conversations.replies with the same ts, now a plain reply

The argument is not on the chat.delete reference page yet, so the JSDoc describes the observed behaviour.

Changes:

  • packages/web-api/src/types/request/chat.ts: broadcast_delete?: boolean on ChatDeleteArguments
  • packages/web-api/test/types/methods/chat.test-d.ts: happy-path type test
  • changeset: @slack/web-api patch

tsd reports 6 errors on main before and after this change (files.upload, rtm.start), none in chat.

Related: #2815

Requirements

@kai-at-momos
kai-at-momos requested a review from a team as a code owner November 5, 2026 13:52
@salesforce-cla

salesforce-cla Bot commented Nov 5, 2026

Copy link
Copy Markdown

Thanks for the contribution! Before we can merge this, we need @kai-at-momos to sign the Salesforce Inc. Contributor License Agreement.

@changeset-bot

changeset-bot Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: a045a6f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@slack/web-api Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@kai-at-momos
kai-at-momos force-pushed the feat/chat-delete-broadcast-delete branch from 5151504 to a045a6f Compare November 5, 2026 16:37
@mwbrooks mwbrooks added enhancement M-T: A feature request for new functionality semver:patch area:typescript issues that specifically impact using the package from typescript projects labels Nov 5, 2026
@mwbrooks mwbrooks added this to the web-api@8.3.1 milestone Nov 5, 2026
@mwbrooks mwbrooks added the pkg:web-api applies to `@slack/web-api` label Nov 5, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:typescript issues that specifically impact using the package from typescript projects cla:signed enhancement M-T: A feature request for new functionality pkg:web-api applies to `@slack/web-api` semver:patch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants