Stream Chat icon

Stream Chat

Server-side Stream Chat operations

Channel → Delete

AI-generated

Summary

Delete a specific channel by its type and ID, with an option to permanently remove it (hard delete).

Inputs

  • Channel Type — The type of the channel to delete (e.g., "messaging" for 1-on-1 chats, "team" for group channels, or "livestream" for broadcast channels). Defaults to "messaging".
  • Channel ID (required) — The unique identifier of the channel to delete (e.g., "general", "random", "team-alpha"). Combined with the channel type to identify the channel.
  • Hard Delete — Boolean flag to specify whether to permanently delete the channel. Defaults to false, meaning the channel may be soft deleted or archived instead of permanently removed.

Output shape

A single JSON object representing the response from the Stream Chat API after the delete operation.

If hard delete is true, the channel is permanently removed; otherwise, it may be marked as deleted softly according to the Stream Chat server behavior. The output contains the API response details and may include error information if the delete operation fails.

Examples

Example 1: Delete a channel with type "messaging" and ID "general" without hard delete

Channel Type: messaging (default), Channel ID: general, Hard Delete: false

Example 2: Hard delete a channel with type "team" and ID "team-alpha"

Channel Type: team, Channel ID: team-alpha, Hard Delete: true

Discussion