Documentation Index
Fetch the complete documentation index at: https://www.cometchat.com/docs/llms.txt
Use this file to discover all available pages before exploring further.
AI Integration Quick Reference
AI Integration Quick Reference
Retrieve List of Groups
UseGroupsRequestBuilder to configure filters, then call fetchNext() to retrieve groups.
Set Limit
Set the number of groups to fetch per request.- Java
- Kotlin
Set Search Keyword
Filter groups by a search string.- Java
- Kotlin
Joined Only
Return only groups the logged-in user has joined.- Java
- Kotlin
Set Tags
Filter groups by tags. Only groups tagged with the specified tags are returned.- Java
- Kotlin
With Tags
Include tag data in the response when set totrue.
- Java
- Kotlin
Fetch Groups
After configuring the builder, callbuild() then fetchNext() to retrieve groups. Public and password-protected groups are always included. Private groups only appear if the user is a member.
- Java
- Kotlin
Retrieve Particular Group Details
UsegetGroup() to fetch details for a specific group by GUID.
- Java
- Kotlin
| Parameter | Description |
|---|---|
GUID | The GUID of the group for whom the details are to be fetched |
Group object containing the details of the group is returned.
Get Online Group Member Count
UsegetOnlineGroupMemberCount() to get the count of online members for specific groups.
- Java
- Kotlin
Hashmap with the GUID of the group as the key and the online member count for that group as the value.
Group Payload Structure
Group Object
Group Object
The
Sample Group Object:
Group object returned by SDK methods contains the following fields:| Parameter | Type | Description |
|---|---|---|
guid | String | Unique identifier of the group |
name | String | Display name of the group |
type | String | Group type. Values: "public", "private", "password" |
password | String | Password for protected groups (null for public/private groups) |
icon | String | URL to group icon image |
description | String | Description of the group |
owner | String | UID of the group owner |
metadata | JSONObject | Custom data set by developer. Can contain any key-value pairs |
createdAt | long | Unix timestamp when group was created |
updatedAt | long | Unix timestamp of last group update |
hasJoined | boolean | Whether the logged-in user has joined this group |
joinedAt | long | Unix timestamp when logged-in user joined the group |
scope | String | Logged-in user’s scope in group. Values: "admin", "moderator", "participant" |
membersCount | int | Total number of members in the group |
tags | Array<String> | List of tags for group identification and filtering |
isBannedFromGroup | boolean | Whether the logged-in user is banned from this group |
Next Steps
Create Group
Create new groups for your users
Join Group
Join groups to participate in conversations
Retrieve Members
Fetch list of group members
Additional Filtering
Learn more about advanced filtering options