Type Definitions
ConnectAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"connect_ack" | Success response type identifier |
user |
string | Connected username |
room |
string | Initial room |
users |
Array.<string> | Users in initial room |
rooms |
Array.<string> | All available rooms |
ConnectErrorResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"connect_error" | Error response type identifier |
message |
string | Error description message |
ConnectResponse
Type:
ConnectionResult
Type:
- Object
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
success |
boolean | Operation status |
|
message |
string |
<optional> |
Optional error message |
JoinAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"join_ack" | Success response type identifier |
user |
string | Connected username |
room |
string | Room name (with # prefix) |
users |
Array.<string> | Array of users in the room |
wasAlreadyInRoom |
boolean | Flag if user was already in room |
allRooms |
Array.<string> | List of all available rooms |
JoinErrorResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"join_error" | Error response type identifier |
message |
string | Error description message |
JoinResponse
Type:
JoinResult
Type:
- Object
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
success |
boolean | Operation status |
|
message |
string |
<optional> |
Optional error message |
users |
Array.<string> | List of users in room |
|
wasAlreadyInRoom |
boolean | Was user already in room |
LeaveRoomResult
Type:
- Object
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
success |
boolean | Operation status |
|
message |
string |
<optional> |
Optional error message |
users |
Array.<string> | Remaining users in room |
|
roomDeleted |
boolean | Whether room was deleted |
|
leftCurrent |
boolean | Whether left current room |
|
disconnected |
boolean | Whether user fully disconnected |
MyRoomsAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"myrooms_ack" | Success response type identifier |
success |
boolean | Operation status |
rooms |
Array.<RoomInfo> | List of rooms with metadata |
MyRoomsErrorResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"myrooms_error" | Error response type identifier |
message |
string | Error description message |
MyRoomsResponse
Type:
PartAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"part_ack" | Success response type identifier |
user |
string | Username who left |
room |
string | Room name that was left |
users |
Array.<string> | Remaining users in room (empty if room deleted) |
leftCurrent |
boolean | Whether user left their current room |
roomDeleted |
boolean | Whether room was deleted (no users left) |
disconnected |
boolean | Whether user fully disconnected (left all rooms) |
PartErrorResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"part_error" | Error response type identifier |
message |
string | Error description message |
PartResponse
Type:
QuitAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"quit_ack" | Success response type identifier |
QuitErrorResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"quit_error" | Error response type identifier |
message |
string | Error description message |
QuitResponse
Type:
RoomInfo
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
name |
string | Room name with # prefix |
userCount |
number | Number of users in room |
isCurrent |
boolean | Whether this is current room |
SendAckResponse
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
type |
"send_ack" | Success response type identifier |
user |
string | Sender username |
text |
string | Acknowledged message |
SendErrorResponse
Type:
- Object
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
type |
"send_error" | Error response type identifier |
|
message |
string | Error description message |
|
originalText |
string |
<optional> |
Original message content |
SendResponse
Type:
UserRoomsResult
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
success |
boolean | Operation status |
rooms |
Array.<RoomInfo> | List of rooms with metadata |