Chat / JavaScript
Chat JavaScript v4
Chat JavaScript
Chat
JavaScript
Home
/
Chat
/
JavaScript
This is the new Docs for Chat SDK v4 for JavaScript. To see the previous Docs, click here.

Overview

Users can chat with one another by participating in open channels or joining group channels within a Sendbird application. The operator role can be assigned to certain users to moderate other users. They are identified by their own unique ID, and may have a customized nickname and profile image. You can manage various user attributes and actions using the Chat API.


User types

Depending on the type of channel your users are chatting in, they are given different labels as well as access to different actions and information. Users can register other users as friends, interact with them in a private chat, or block specific users from sending direct messages. In some cases, users can be given an operator role and the designated operators can moderate other users who engage in inappropriate activities.

TypeDefinition

User

Scope: Application
Refers to one who can access all the chat features of a Sendbird application with their own unique ID but doesn't have administrative privileges.

Participant

Scope: Open channels
Refers to a specific user who has entered an open channel without an invitation and is staying online in the channel. Open channel participants are provided with limited information only. As opposed to group channel members, relational information such as connection status, typing indicators, and read receipts won't be given to the open channel participants. These participants can enter and exit the channel at all times.

Member

Scope: Group channels
Refers to a specific user who has joined a group channel through an invitation from a channel member or their own choice due to the channel’s characteristics. Relational information such as connection status, typing indicators, and read receipts can be given to the group channel members depending on the channel settings.

Operator

You can assign operators in each channel to moderate participants or members engaging in inappropriate activities by banning or muting them in the channel.

Banned participants or members will be kicked out of the channel. After the ban time set by the operators has expired, they can participate back in or rejoin the channel. On the other hand, muted participants or members are allowed to stay in the channel and view the messages, but can't talk until the operators unmute them.


Functionalities by topic

With the Chat SDK, you can retrieve users in a channel, moderate user activity, and manage user information. The following is a list of functionalities that our SDK supports.

Retrieving users

FunctionalityDescriptionOpen channelGroup channel

Retrieve a list of users in an application

Retrieves a list of all or a specified subset of users in a Sendbird application.

Retrieve a list of users in a channel

Retrieves a list of users in a channel.

Retrieve a list of users and operators

Retrieves a list of users and operators in a channel in an alphabetical order or by another specified order.

Retrieve users who have read a message

Retrieves users who have read a specific message in a channel.

Retrieve a list of operators

Retrieves a list of operators who monitor and control the activities in a channel.

Moderating a user

FunctionalityDescriptionOpen channelGroup channel

Retrieve a list of blocked users

Retrieves a list of all or a specified subset of blocked users in a Sendbird application.

Retrieve a list of banned users

Retrieves a list of users who are banned from a channel.

Retrieve a list of muted users

Retrieves a list of users who are muted in a channel.

Block and unblock other users

Blocks or unblocks specified users for a user in a channel.

Ban and unban a user

Operators can ban or unban users from a channel. Banned users are immediately expelled from a channel and allowed to participate in the channel again after the time period set by the operators.

Mute and unmute a user

Operators can mute or unmute users in a channel. Muted users remain in the channel and are allowed to view the messages, but can't send any messages until the operators unmute them.

Retrieving and updating user information

FunctionalityDescriptionOpen channelGroup channel

Retrieve the online status of a user

Checks if a certain user in a Sendbird application is currently connected to the Sendbird server.

Update user profile

Updates a user's nickname and profile image with a URL.

Retrieve the latest information on users

Retrieves the latest and updated information on each user in a Sendbird application or a channel who is online.

Managing user metadata

FunctionalityDescriptionOpen channelGroup channel

Manage user metadata

Stores additional information to users. You can create, retrieve, update and delete the additional information.