Group Overview

Prerequisites#

In order to send messages using the chat sdk , at first you need to establish the connection to the server. sdk provides methods for initializing the connection configuration as well as methods for making connection.

Note: Even if you don't have internet connection, you are still allowed to send messages which will be kept in offline database.Once the user connected to the internet, the messages will be sent automatically when user opens the app.

Preparing Group chat jid#

SDK provieds the below utility method to preparing group JID. FlyUtils.getGroupJid(groupId : String)

Note: The below characters is not allowed in uniqueId: U+0022 (") U+0026 (&) U+0027 (') U+002F (/) U+003A (:) U+003C (<) U+003E (>) U+0040 (@).

ArgumentTypeDescription
groupIdStringunique groupId for preparing group JID
    try FlyUtils.getGroupJid(groupId : String)
    caution

    If group chat feature unavailable for your plan then below methods will throw 403 exception.

    Group messaging#

    Group messaging is very similiar to the single chat messaging. Instead of giving single chat jid , you need to provide group jid. if you don't have group jid, you can prepare that using the above method by giving group id.

    Refer this doc for group messaging