Channel Management

Stream Chat provides a variety of channel management APIs that allow you to control how channels behave within your application. This page provides an overview of the different channel management operations available.

Overview

Channel management operations can be broadly categorized into:

OperationDescriptionUser ImpactData Impact
ArchivingMark a channel as archived for a specific userPer-user stateNo data loss
PinningMark a channel as pinned for a specific userPer-user stateNo data loss
MutingSuppress notifications for a channelPer-user stateNo data loss
HidingHide a channel from query results until new messagesPer-user stateOptional history clear
DisablingPrevent all client-side access to a channelAll users affectedNo data loss
FreezingPrevent new messages and reactionsAll users affectedNo data loss
TruncatingRemove messages from a channelAll users affectedMessage data deleted
DeletingPermanently remove a channelAll users affectedAll data deleted

Choosing the Right Operation

Per-User Operations

These operations only affect the individual user and are ideal for personal organization:

  • Archiving: Use when a user wants to declutter their channel list but keep the channel accessible
  • Pinning: Use when a user wants to prioritize certain channels at the top of their list
  • Muting: Use when a user wants to stay in a channel but not receive notifications
  • Hiding: Use when a user wants to temporarily remove a channel from view

Channel-Wide Operations

These operations affect all users in the channel and typically require admin or moderator permissions:

  • Disabling: Use when you need to completely block access to a channel (e.g., for moderation)
  • Freezing: Use when you want to preserve a channel’s content but prevent new activity (e.g., archived discussions)
  • Truncating: Use when you need to clear message history but keep the channel active
  • Deleting: Use when a channel is no longer needed and should be permanently removed

Server-Side vs Client-Side

Most channel management operations can be performed from both client-side and server-side SDKs, but some operations are restricted to server-side only for security reasons:

OperationClient-SideServer-Side
Archiving
Pinning
Muting
Hiding
Disabling
Freezing
Truncating
DeletingDepends on permissions