AI Integration Quick Reference
AI Integration Quick Reference
Message Categories:
- Message: text, image, video, audio, file
- Custom: Developer-defined types (e.g., location)
- Interactive: form, card, customInteractive
- Action: groupMember, message (system-generated)
- Call: audio, video (with status: initiated, ongoing, ended, etc.)
Message Hierarchy

Categories Overview
| Category | Types | Description |
|---|---|---|
message | text, image, video, audio, file | Standard user messages |
custom | Developer-defined | Custom data (location, polls, etc.) |
interactive | form, card, customInteractive | Messages with actionable UI elements |
action | groupMember, message | System-generated events |
call | audio, video | Call-related messages |
Checking Message Category and Type
UsegetCategory() and getType() on a BaseMessage to determine how to handle a received message:
- Java
- Kotlin
Message
Standard user messages. Types:text, image, video, audio, file.
Custom
Developer-defined messages for content that doesn’t fit standard categories (e.g., location sharing, polls). Set your owntype string to identify the custom message.
Interactive
Messages with embedded UI elements users can interact with directly in chat. Types:form, card, customInteractive.
See Interactive Messages for full details.
Action
System-generated messages triggered by actions on group members or messages. Represented asAction objects.
Types: groupMember, message.
The action property specifies what happened:
For groupMember: joined, left, kicked, banned, unbanned, added, scopeChanged
For message: edited, deleted
Call
Call-related messages. Types:audio, video. Represented as Call objects.
The status property indicates the call state: initiated, ongoing, canceled, rejected, unanswered, busy, ended.
Next Steps
Send Message
Send text, media, and custom messages
Receive Messages
Handle incoming messages of all types
Additional Message Filtering
Filter messages by category, type, and other parameters
Interactive Messages
Create and handle interactive form and card messages