Skip to main content

Documentation Index

Fetch the complete documentation index at: https://cometchat-22654f5b-docs-android-v6-beta2.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

// Delete a group (owner only)
await CometChat.deleteGroup("GUID");
Requirement: Logged-in user must be the owner of the group.
Permanently delete a group and all its messages. Only the group owner can perform this operation.
This operation is irreversible. Deleted groups and their messages cannot be recovered.

Delete a Group

Use deleteGroup() with the group’s GUID.
const GUID: string = "GUID";

CometChat.deleteGroup(GUID).then(
  (response: boolean) => {
      console.log("Group deleted successfully:", response);
  }, (error: CometChat.CometChatException) => {
      console.log("Group delete failed with exception:", error);
  }
);
The deleteGroup() method takes the following parameters:
ParameterDescription
GUIDThe GUID of the group you would like to delete
On success, the method resolves with true (boolean).

Next Steps

Create a Group

Create public, private, or password-protected groups

Retrieve Groups

Fetch group lists, search groups, and get group details

Leave a Group

Leave groups and stop receiving updates

Transfer Ownership

Transfer group ownership before leaving