Skip to main content

Private subchannel overview

Community channels support private subchannels for scenarios where only designated users should be able to communicate within a subchannel.

Before using private subchannels, read the Community channel overview to understand how subchannels work.

Known limitations

warning

If a user is not on the private subchannel member list but sends a message to the subchannel, the message cannot be delivered to the server. However, it is stored in the local database and may generate a local channel record.

Recommended workaround: Maintain a private subchannel member list on your app server. Prevent users who are not on the list from sending messages to the private subchannel.

Understanding private subchannels

tip

The client SDK does not provide APIs for creating private subchannels or changing subchannel types. Use the Server API for these operations.

Community subchannels are categorized as public or private:

  • Public subchannels are open to all community members. All members receive messages from public subchannels.
  • Private subchannels are restricted to the subchannel's member list. Only members can send and receive messages and receive status notifications.

Public subchannels can be switched to private, and vice versa.

For example, an admin can create a new subchannel as private, then invite specific community members. Only invited members can view the subchannel, receive messages, and send messages.

Changing the subchannel type affects remote message retrieval permissions:

  • Public → Private: Only users on the current private subchannel member list can retrieve historical messages (including messages from when the subchannel was public).
  • Private → Public: All community members can retrieve historical messages (including messages from when the subchannel was private).

Management APIs

FeatureClient APIServer API
Create a private subchannelNot availableCreate a subchannel
Delete a private subchannelNot availableDelete a subchannel
List subchannelsNot availableList subchannels
Change subchannel typeNot availableChange subchannel type

Understanding the private subchannel member list

tip

The client SDK does not provide APIs for managing private subchannel member lists. Use the Server API to query, add, or remove members.

When a subchannel is private, only users on the member list can send and receive messages and receive status notifications.

When a private subchannel is switched to public, it becomes open to all community members. The member list data is preserved — if the subchannel is switched back to private, the list takes effect again.

You can also pre-create a member list for a public subchannel. The list takes effect when the subchannel is switched to private.

tip
  • Deleting a subchannel also clears its private member list.
  • When a user leaves the community, the server automatically removes them from all private subchannel member lists.

Management APIs

FeatureClient APIServer API
Add membersNot availableAdd private subchannel members
Remove membersNot availableRemove private subchannel members
Query member listNot availableQuery private subchannel members