Overview
Private chat is communication between two people through text, files, images, voice messages, friend-request notifications, and other message types. Message history synchronizes when users switch devices. The SDK also synchronizes read status, unread counts, and message updates across a user's devices. Supported message operations include recalling, editing, and replying.
Use Cases
Messages between friends: Users find each other by phone number or user ID, add each other as friends, and exchange messages.
Messages between new contacts: Social applications can match users by profile information, such as shared interests, and let them start a conversation.
Buyer-seller communication: Buyers and sellers communicate through text or images, usually around an order or product for pre-sales and after-sales support.
Host-fan interaction: Live-streaming social products with
KOLhosts let users follow a host and send a limited number of direct messages after following.
More private-chat use cases:
drivers and passengers,one-to-one tutoring,teacher-student communication,school-family communication,couriers and merchants, and...
Key Features
Relationship direction: One-way or mutual friend relationships. Fans can follow hosts one way, and the friend limit can be configured as unlimited.
Online status: Users can subscribe to the online status of friends or followed users as needed. Your application can use this status to display availability or match users.
Blocklists and allowlists: Bidirectional blocklists and allowlists restrict message delivery. Show a prompt when a blocked user sends a message, or allow messages only from allowlisted users.
Profile updates: When a user's information changes, a synchronization mechanism automatically notifies related users.
User information in messages: Messages include user information for easier client rendering and reduced integration complexity.
Related Documentation
Basics: Download the SDK, Integration example
User management: Register a user, Update user information, Ban a user, Mute a user
Messages: Message structure, Send a message, Receive messages, Get message history, Clear message history, Recall a message, Message read receipts, Send a message through the REST API
Conversations: Conversation structure, Get the conversation list, Pin a conversation, Mute Notifications, Get total unread count, Get the conversation list from the server