Ethora Chat Protocol Documentation
1. Connection & Authentication
// Connection Configuration
{
service: 'wss://xmpp.ethoradev.com:5443/ws',
username: 'user_id_before_@', // Extract username part before @domain
password: 'user_password'
}
Authentication Flow
- Connect to WebSocket endpoint
- Provide credentials
- Receive online status
- Join room with presence stanza
2. Message Structure
<message xmlns="jabber:client" type="groupchat">
<body>Message content</body>
<data xmlns="jabber:client"
fullName="Display Name"
senderFirstName="First"
senderLastName="Last"
showInChannel="true"
senderJID="user@domain/resource"
senderWalletAddress="0x..."
roomJid="room@conference.domain"
isSystemMessage="false"
photoURL=""
tokenAmount="0"
quickReplies=""
notDisplayedValue=""
/>
<stanza-id xmlns="urn:xmpp:sid:0" />
</message>
Message Types
- Text Messages (shown above)
- System Messages (isSystemMessage="true")
- Chat States (typing indicators):
<message type="groupchat">
<composing xmlns="http://jabber.org/protocol/chatstates" />
<data fullName="User Name" />
</message>
3. Room Management
Joining a Room
<presence to="roomJID/userJID">
<x xmlns="http://jabber.org/protocol/muc" />
<data xmlns="jabber:client"
fullName="Display Name"
senderFirstName="First"
senderLastName="Last"
showInChannel="true"
/>
</presence>
4. Extended Features
Message Reactions
(Referencing src/networking/stanzaHandlers.ts lines 190-196)
- Support for emoji reactions
- Reaction history tracking
-
Real-time reaction updates
Message History
(Referencing lib/src/networking/stanzaHandlers.ts lines 28-270)
MAM (Message Archive Management) support
- Historical message retrieval
- Message synchronization