2017-05-27 19:45:07 -04:00
|
|
|
export interface ScalarResponse {
|
|
|
|
action: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ScalarRoomResponse extends ScalarResponse {
|
|
|
|
room_id: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ScalarUserResponse extends ScalarRoomResponse {
|
|
|
|
user_id: string;
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ScalarErrorResponse extends ScalarResponse {
|
|
|
|
response: {error: {message: string, _error: Error}};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface ScalarSuccessResponse extends ScalarResponse {
|
|
|
|
response: {success: boolean};
|
|
|
|
}
|
|
|
|
|
|
|
|
export interface MembershipStateResponse extends ScalarUserResponse {
|
|
|
|
response: {
|
|
|
|
membership: string;
|
|
|
|
avatar_url: string;
|
|
|
|
displayname: string;
|
|
|
|
};
|
2017-06-04 23:31:31 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
export interface JoinRuleStateResponse extends ScalarRoomResponse {
|
|
|
|
response: {
|
|
|
|
join_rule: string;
|
|
|
|
};
|
2017-05-27 19:45:07 -04:00
|
|
|
}
|