Table of Contents

Understanding channels in Sendbird Chat

Understanding channels in Sendbird Chat

Alex Preston
Solutions Engineer
Tutorial Type: Basic Tutorial Reading Time: 5 mins Building Time: 10 mins
ChatAndroidiOSJSSDK

Introduction

This brief guide shows how to get started with another core Sendbird concept: Channels. This guide gives an understanding of the various types of Channels within Sendbird and covers how you can create, update, delete and view Channel objects. Channels are fundamental to a solid understanding and implementation of Sendbird within your app. Please note that while some implementations will vary from platform to platform, the core concepts remain the same across all platforms and SDKs.

We’ll cover:

  • The two main types of Channels and their different use cases.
  • How to create, view, update, and delete Channels.

Let’s get started!

Sendbird Channels are essential to all chat interactions. Users belong to them, and messages are sent in them. Sendbird provides numerous different types of Channels to support various use cases. In this tutorial we will be covering the two main types of Channels: Group Channels and Open Channels, and we will be talking about how you can use them.Sendbird Channels diagram

Group Channels

Group Channels are perhaps the most used Channel type within Sendbird. This Channel allows for close interaction between a smaller group of users. From a developer standpoint this Channel type offers a greater deal of customization and control. This comes in the form of read and delivery receipts, reactions, push notifications, mentions and much more. (For a full list of features check out the docs page). There are two main types of Group Channels, private and public.

Public: A Public Channel is a Channel which can be joined by any user without an invitation.

Private: A Private Channel is a Channel which can only be accessed by invited users.

While Group Channels by default can have up to 100 members in capacity a lot of our customers use them for 1:1 interactions facilitating a more intimate conversation. These use cases range from dating apps, to on-demand, to healthcare.(These conversations should be created as distinct, which means any time that user tries to initiate another conversation with that current user the same Channel will be reused.)

For the full resource representation of a Group Channel please see the docs page.

For use cases where you’d like to use Group Channels with greater capacity than 100 check out SuperGroup Channels which can have over 2,000 members in a Channel.

Open Channels

The other main type of Channel is the Open Channel. Unlike Group Channels, membership for Open Channels is not permanent, and only exists while they are connected. This is a Public Channel which is generally used to host a large number of online users, and allows them to be able to enter and contribute without any permissions. From a developer standpoint this channel offers less customization and control in favor of larger audience sizes.(For a full list of features check out the docs page). There are two different types of Open Channels: Classic and Dynamically partitioned.

Classic: This is the default type of Open Channel. This Channel allows for up to 1,000 participants in a given Channel. (Please note that classic will be deprecated in lieu of dynamic partitioned Channels in March 2021).

Dynamic partitioned: This type of Channel was designed to accommodate truly massive amounts of users. They range anywhere from 2,000 to 20,000 participants, but can go even larger depending on the use case.

Generally Open Channels are used whenever there is a use case for a large number of users in a given Channel at a given point. This ranges from things like live events(Sports), to chatrooms.

For the full resource representation of a group Channel please see the docs page.

How to create, view, update, and delete a Channel

By default Channels can be created updated, reviewed and deleted via SDK or Platform API, or Dashboard.

  • Platform API
  • iOS
  • Android
  • Javascript

Remember that a Channel object contains all of the high level data for the conversation between its members.

The Channel object interacts with the SDKs. Some interactions provide real time communication through websockets and other services automatically contact sendbird to send data or fetch data via secure HTTPS requests.

Creating Channels

Creating new Group Channel

Dashboard
  • Click on either the Open Channel, or Group Channel tab on the left side
  • Click “Create Channel +’
  • Fill out the relevant information
  • Click create
Platform API

Create Channels by Platform API call(how to)

SDK
  • In general Channels are typically created via the Platform API or the SDK
  • For use cases where you wish to limit a users ability to create Channels, you can restrict Channel creation to platform API only

Reviewing Channels

Reviewing Channels

Dashboard(Please note viewing Channels via dashboard is a premium feature)
  • Click on either the Open Channel, or Group Channel tab on the left side
  • Click the Channel you wish to view
  • This view allows you to perform various moderation tasks as well as view Channels
Platform API

Reviewing Channels by Platform API call(how to)

SDK
  • The SDK provides means to view a list of Channels, as well as viewing individual Channels

 

Updating Channels

Updating Channels

Dashboard
  • Click on either the Open Channel, or Group Channel tab on the left side
  • Select the relevant Channel
  • Click the edit button in the top right corner
  • Edit the information needed
  • Click update
Platform API

Updating Channels by Platform API call(how to)

SDK
  • Channels can be updated via the SDK on all platforms
  • If needed this operation can be restricted to be done only via platform API

 

Deleting Channels

Delete Channels

Dashboard
  • Click on either the Open Channel, or Group Channel tab on the left side
  • Click the checkbox next to the Channel(s) you wish to delete
  • Click Delete
Platform API

Deleting Channels by Platform API call(how to)

SDK
  • The SDKs provide a means to delete cChannels via the SDK, this is limited to an operator only action
  • This can also be limited to Platform API only

Congratulations

This tutorial should give you a solid understanding of Channels, types of Channels, their use cases and how they can be manipulated via CRUD operations. From here we recommend checking out the related documentation for both open and Group Channels as there are so many more advanced concepts and features which can help you create a world class application.