|
@@ -1,30 +1,32 @@
|
|
1
|
+import { WebSocketClient } from './../WebSocketClient';
|
1
|
2
|
import { MsgBase, GroupOption } from '../protocol/MsgBase';
|
2
|
|
-export declare class WsApi {
|
|
3
|
+export declare class WsApi extends WebSocketClient {
|
3
|
4
|
token: string;
|
4
|
5
|
from: string;
|
5
|
|
- sendMsg(msg: Partial<MsgBase>): Promise<void>;
|
6
|
|
- sendGetCmdMsg(action: string, extra?: {}): Promise<void>;
|
7
|
|
- sendPostCmdMsg(action: string, userIds: string[] | null, extra?: {}): Promise<void>;
|
8
|
|
- getRoster(): Promise<void>;
|
9
|
|
- addFriends(userIds: string[]): Promise<void>;
|
10
|
|
- agreeFriends(userIds: string[]): Promise<void>;
|
11
|
|
- rejectFriends(userIds: string[]): Promise<void>;
|
12
|
|
- removeFriends(userIds: string[]): Promise<void>;
|
13
|
|
- getBlacklist(): Promise<void>;
|
14
|
|
- addToBlackList(userIds: string[]): Promise<void>;
|
15
|
|
- removeBlackList(userIds: string[]): Promise<void>;
|
16
|
|
- listGroups(): Promise<void>;
|
17
|
|
- queryGroupInfo(roomId: string): Promise<void>;
|
18
|
|
- queryRoomMember(roomId: string): Promise<void>;
|
19
|
|
- getGroupBlackList(roomId: string): Promise<void>;
|
20
|
|
- createGroup(groupOption: GroupOption): Promise<void>;
|
21
|
|
- changeGroupInfo(groupOption: GroupOption): Promise<void>;
|
22
|
|
- addGroupMembers(roomId: string, userIds: string[]): Promise<void>;
|
23
|
|
- addToGroupBlackList(roomId: string, userIds: string[]): Promise<void>;
|
24
|
|
- destroyGroup(roomId: string): Promise<void>;
|
25
|
|
- leaveGroup(roomId: string): Promise<void>;
|
26
|
|
- createRoom(groupOption: GroupOption): Promise<void>;
|
27
|
|
- listRooms(): Promise<void>;
|
28
|
|
- joinRoom(roomId: string): Promise<void>;
|
29
|
|
- quitRoom(roomId: string): Promise<void>;
|
|
6
|
+ sendMsg(msg: Partial<MsgBase>): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
7
|
+ sendGetCmdMsg(action: string, extra?: {}): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
8
|
+ sendPostCmdMsg(action: string, userIds: string[] | null, extra?: {}): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
9
|
+ getRoster(): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
10
|
+ addFriends(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
11
|
+ agreeFriends(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
12
|
+ rejectFriends(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
13
|
+ removeFriends(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
14
|
+ getBlacklist(): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
15
|
+ addToBlackList(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
16
|
+ removeBlackList(userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
17
|
+ deleteConversation(contactId: string, delete_message?: boolean): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
18
|
+ listGroups(): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
19
|
+ queryGroupInfo(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
20
|
+ queryRoomMember(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
21
|
+ getGroupBlackList(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
22
|
+ createGroup(groupOption: GroupOption): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
23
|
+ changeGroupInfo(groupOption: GroupOption): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
24
|
+ addGroupMembers(roomId: string, userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
25
|
+ addToGroupBlackList(roomId: string, userIds: string[]): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
26
|
+ destroyGroup(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
27
|
+ leaveGroup(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
28
|
+ createRoom(groupOption: GroupOption): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
29
|
+ listRooms(): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
30
|
+ joinRoom(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
|
31
|
+ quitRoom(roomId: string): Promise<import("ts-linker-sdk/dist/types/types").WebSocketResp>;
|
30
|
32
|
}
|