trompot 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +560 -0
- package/lib/bot/BotBase.d.ts +82 -0
- package/lib/bot/BotBase.js +144 -0
- package/lib/bot/BotBase.js.map +1 -0
- package/lib/bot/BotEvents.d.ts +87 -0
- package/lib/bot/BotEvents.js +51 -0
- package/lib/bot/BotEvents.js.map +1 -0
- package/lib/bot/BotServer.d.ts +34 -0
- package/lib/bot/BotServer.js +118 -0
- package/lib/bot/BotServer.js.map +1 -0
- package/lib/bot/BotStatus.d.ts +4 -0
- package/lib/bot/BotStatus.js +9 -0
- package/lib/bot/BotStatus.js.map +1 -0
- package/lib/bot/IBot.d.ts +292 -0
- package/lib/bot/IBot.js +3 -0
- package/lib/bot/IBot.js.map +1 -0
- package/lib/bot/index.d.ts +5 -0
- package/lib/bot/index.js +13 -0
- package/lib/bot/index.js.map +1 -0
- package/lib/client/Client.d.ts +120 -0
- package/lib/client/Client.js +687 -0
- package/lib/client/Client.js.map +1 -0
- package/lib/client/ClientEvents.d.ts +147 -0
- package/lib/client/ClientEvents.js +93 -0
- package/lib/client/ClientEvents.js.map +1 -0
- package/lib/client/ClientFunctionHandler.d.ts +15 -0
- package/lib/client/ClientFunctionHandler.js +70 -0
- package/lib/client/ClientFunctionHandler.js.map +1 -0
- package/lib/client/ConnectionType.d.ts +4 -0
- package/lib/client/ConnectionType.js +3 -0
- package/lib/client/ConnectionType.js.map +1 -0
- package/lib/client/IAuth.d.ts +9 -0
- package/lib/client/IAuth.js +3 -0
- package/lib/client/IAuth.js.map +1 -0
- package/lib/client/IClient.d.ts +358 -0
- package/lib/client/IClient.js +3 -0
- package/lib/client/IClient.js.map +1 -0
- package/lib/client/index.d.ts +7 -0
- package/lib/client/index.js +13 -0
- package/lib/client/index.js.map +1 -0
- package/lib/cluster/ClientCluster.d.ts +428 -0
- package/lib/cluster/ClientCluster.js +1746 -0
- package/lib/cluster/ClientCluster.js.map +1 -0
- package/lib/cluster/WorkerMessage.d.ts +99 -0
- package/lib/cluster/WorkerMessage.js +84 -0
- package/lib/cluster/WorkerMessage.js.map +1 -0
- package/lib/cluster/index.d.ts +5 -0
- package/lib/cluster/index.js +27 -0
- package/lib/cluster/index.js.map +1 -0
- package/lib/configs/ConnectionConfig.d.ts +22 -0
- package/lib/configs/ConnectionConfig.js +3 -0
- package/lib/configs/ConnectionConfig.js.map +1 -0
- package/lib/configs/Defaults.d.ts +2 -0
- package/lib/configs/Defaults.js +16 -0
- package/lib/configs/Defaults.js.map +1 -0
- package/lib/configs/WAConfigs.d.ts +1 -0
- package/lib/configs/WAConfigs.js +5 -0
- package/lib/configs/WAConfigs.js.map +1 -0
- package/lib/configs/index.d.ts +3 -0
- package/lib/configs/index.js +18 -0
- package/lib/configs/index.js.map +1 -0
- package/lib/errors/ChatNotDefinedError.d.ts +4 -0
- package/lib/errors/ChatNotDefinedError.js +9 -0
- package/lib/errors/ChatNotDefinedError.js.map +1 -0
- package/lib/errors/ClientNotDefinedError.d.ts +4 -0
- package/lib/errors/ClientNotDefinedError.js +9 -0
- package/lib/errors/ClientNotDefinedError.js.map +1 -0
- package/lib/errors/UserNotDefinedError.d.ts +4 -0
- package/lib/errors/UserNotDefinedError.js +9 -0
- package/lib/errors/UserNotDefinedError.js.map +1 -0
- package/lib/index.d.ts +17 -0
- package/lib/index.js +60 -0
- package/lib/index.js.map +1 -0
- package/lib/messages/AudioMessage.d.ts +42 -0
- package/lib/messages/AudioMessage.js +66 -0
- package/lib/messages/AudioMessage.js.map +1 -0
- package/lib/messages/ButtonMessage.d.ts +88 -0
- package/lib/messages/ButtonMessage.js +137 -0
- package/lib/messages/ButtonMessage.js.map +1 -0
- package/lib/messages/ContactMessage.d.ts +37 -0
- package/lib/messages/ContactMessage.js +93 -0
- package/lib/messages/ContactMessage.js.map +1 -0
- package/lib/messages/CustomMessage.d.ts +35 -0
- package/lib/messages/CustomMessage.js +88 -0
- package/lib/messages/CustomMessage.js.map +1 -0
- package/lib/messages/EmptyMessage.d.ts +25 -0
- package/lib/messages/EmptyMessage.js +78 -0
- package/lib/messages/EmptyMessage.js.map +1 -0
- package/lib/messages/ErrorMessage.d.ts +35 -0
- package/lib/messages/ErrorMessage.js +86 -0
- package/lib/messages/ErrorMessage.js.map +1 -0
- package/lib/messages/FileMessage.d.ts +36 -0
- package/lib/messages/FileMessage.js +60 -0
- package/lib/messages/FileMessage.js.map +1 -0
- package/lib/messages/ImageMessage.d.ts +41 -0
- package/lib/messages/ImageMessage.js +65 -0
- package/lib/messages/ImageMessage.js.map +1 -0
- package/lib/messages/ListMessage.d.ts +91 -0
- package/lib/messages/ListMessage.js +126 -0
- package/lib/messages/ListMessage.js.map +1 -0
- package/lib/messages/LocationMessage.d.ts +48 -0
- package/lib/messages/LocationMessage.js +107 -0
- package/lib/messages/LocationMessage.js.map +1 -0
- package/lib/messages/MediaMessage.d.ts +54 -0
- package/lib/messages/MediaMessage.js +113 -0
- package/lib/messages/MediaMessage.js.map +1 -0
- package/lib/messages/Message.d.ts +144 -0
- package/lib/messages/Message.js +223 -0
- package/lib/messages/Message.js.map +1 -0
- package/lib/messages/PollMessage.d.ts +87 -0
- package/lib/messages/PollMessage.js +145 -0
- package/lib/messages/PollMessage.js.map +1 -0
- package/lib/messages/PollUpdateMessage.d.ts +40 -0
- package/lib/messages/PollUpdateMessage.js +98 -0
- package/lib/messages/PollUpdateMessage.js.map +1 -0
- package/lib/messages/ReactionMessage.d.ts +36 -0
- package/lib/messages/ReactionMessage.js +91 -0
- package/lib/messages/ReactionMessage.js.map +1 -0
- package/lib/messages/StickerMessage.d.ts +49 -0
- package/lib/messages/StickerMessage.js +73 -0
- package/lib/messages/StickerMessage.js.map +1 -0
- package/lib/messages/TextMessage.d.ts +33 -0
- package/lib/messages/TextMessage.js +84 -0
- package/lib/messages/TextMessage.js.map +1 -0
- package/lib/messages/VideoMessage.d.ts +42 -0
- package/lib/messages/VideoMessage.js +66 -0
- package/lib/messages/VideoMessage.js.map +1 -0
- package/lib/messages/index.d.ts +19 -0
- package/lib/messages/index.js +81 -0
- package/lib/messages/index.js.map +1 -0
- package/lib/models/Address.d.ts +11 -0
- package/lib/models/Address.js +18 -0
- package/lib/models/Address.js.map +1 -0
- package/lib/models/Call.d.ts +68 -0
- package/lib/models/Call.js +127 -0
- package/lib/models/Call.js.map +1 -0
- package/lib/modules/chat/Chat.d.ts +142 -0
- package/lib/modules/chat/Chat.js +246 -0
- package/lib/modules/chat/Chat.js.map +1 -0
- package/lib/modules/chat/ChatAction.d.ts +3 -0
- package/lib/modules/chat/ChatAction.js +3 -0
- package/lib/modules/chat/ChatAction.js.map +1 -0
- package/lib/modules/chat/ChatStatus.d.ts +9 -0
- package/lib/modules/chat/ChatStatus.js +13 -0
- package/lib/modules/chat/ChatStatus.js.map +1 -0
- package/lib/modules/chat/ChatType.d.ts +7 -0
- package/lib/modules/chat/ChatType.js +11 -0
- package/lib/modules/chat/ChatType.js.map +1 -0
- package/lib/modules/chat/index.d.ts +5 -0
- package/lib/modules/chat/index.js +13 -0
- package/lib/modules/chat/index.js.map +1 -0
- package/lib/modules/command/Command.d.ts +67 -0
- package/lib/modules/command/Command.js +139 -0
- package/lib/modules/command/Command.js.map +1 -0
- package/lib/modules/command/CommandController.d.ts +50 -0
- package/lib/modules/command/CommandController.js +119 -0
- package/lib/modules/command/CommandController.js.map +1 -0
- package/lib/modules/command/CommandControllerEvent.d.ts +9 -0
- package/lib/modules/command/CommandControllerEvent.js +25 -0
- package/lib/modules/command/CommandControllerEvent.js.map +1 -0
- package/lib/modules/command/CommandEnums.d.ts +14 -0
- package/lib/modules/command/CommandEnums.js +20 -0
- package/lib/modules/command/CommandEnums.js.map +1 -0
- package/lib/modules/command/CommandKey.d.ts +17 -0
- package/lib/modules/command/CommandKey.js +67 -0
- package/lib/modules/command/CommandKey.js.map +1 -0
- package/lib/modules/command/CommandPermission.d.ts +9 -0
- package/lib/modules/command/CommandPermission.js +35 -0
- package/lib/modules/command/CommandPermission.js.map +1 -0
- package/lib/modules/command/ICommandControllerConfig.d.ts +7 -0
- package/lib/modules/command/ICommandControllerConfig.js +3 -0
- package/lib/modules/command/ICommandControllerConfig.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommand.d.ts +23 -0
- package/lib/modules/command/advanced/AdvancedCommand.js +131 -0
- package/lib/modules/command/advanced/AdvancedCommand.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandContext.d.ts +10 -0
- package/lib/modules/command/advanced/AdvancedCommandContext.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandContext.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandController.d.ts +29 -0
- package/lib/modules/command/advanced/AdvancedCommandController.js +118 -0
- package/lib/modules/command/advanced/AdvancedCommandController.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandData.d.ts +6 -0
- package/lib/modules/command/advanced/AdvancedCommandData.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandData.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandJob.d.ts +12 -0
- package/lib/modules/command/advanced/AdvancedCommandJob.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandJob.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandNext.d.ts +4 -0
- package/lib/modules/command/advanced/AdvancedCommandNext.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandNext.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandOptions.d.ts +8 -0
- package/lib/modules/command/advanced/AdvancedCommandOptions.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandOptions.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandStart.d.ts +11 -0
- package/lib/modules/command/advanced/AdvancedCommandStart.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandStart.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandStop.d.ts +3 -0
- package/lib/modules/command/advanced/AdvancedCommandStop.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandStop.js.map +1 -0
- package/lib/modules/command/advanced/AdvancedCommandTask.d.ts +2 -0
- package/lib/modules/command/advanced/AdvancedCommandTask.js +3 -0
- package/lib/modules/command/advanced/AdvancedCommandTask.js.map +1 -0
- package/lib/modules/command/defaults.d.ts +2 -0
- package/lib/modules/command/defaults.js +8 -0
- package/lib/modules/command/defaults.js.map +1 -0
- package/lib/modules/command/index.d.ts +12 -0
- package/lib/modules/command/index.js +36 -0
- package/lib/modules/command/index.js.map +1 -0
- package/lib/modules/command/keys.d.ts +9 -0
- package/lib/modules/command/keys.js +27 -0
- package/lib/modules/command/keys.js.map +1 -0
- package/lib/modules/command/perms.d.ts +2 -0
- package/lib/modules/command/perms.js +11 -0
- package/lib/modules/command/perms.js.map +1 -0
- package/lib/modules/quickResponse/QuickResponse.d.ts +49 -0
- package/lib/modules/quickResponse/QuickResponse.js +64 -0
- package/lib/modules/quickResponse/QuickResponse.js.map +1 -0
- package/lib/modules/quickResponse/QuickResponseController.d.ts +55 -0
- package/lib/modules/quickResponse/QuickResponseController.js +125 -0
- package/lib/modules/quickResponse/QuickResponseController.js.map +1 -0
- package/lib/modules/quickResponse/QuickResponseOptions.d.ts +56 -0
- package/lib/modules/quickResponse/QuickResponseOptions.js +76 -0
- package/lib/modules/quickResponse/QuickResponseOptions.js.map +1 -0
- package/lib/modules/quickResponse/QuickResponsePattern.d.ts +28 -0
- package/lib/modules/quickResponse/QuickResponsePattern.js +3 -0
- package/lib/modules/quickResponse/QuickResponsePattern.js.map +1 -0
- package/lib/modules/quickResponse/QuickResponseReply.d.ts +6 -0
- package/lib/modules/quickResponse/QuickResponseReply.js +3 -0
- package/lib/modules/quickResponse/QuickResponseReply.js.map +1 -0
- package/lib/modules/quickResponse/index.d.ts +6 -0
- package/lib/modules/quickResponse/index.js +13 -0
- package/lib/modules/quickResponse/index.js.map +1 -0
- package/lib/modules/user/User.d.ts +91 -0
- package/lib/modules/user/User.js +173 -0
- package/lib/modules/user/User.js.map +1 -0
- package/lib/modules/user/UserAction.d.ts +4 -0
- package/lib/modules/user/UserAction.js +3 -0
- package/lib/modules/user/UserAction.js.map +1 -0
- package/lib/modules/user/UserEvent.d.ts +3 -0
- package/lib/modules/user/UserEvent.js +3 -0
- package/lib/modules/user/UserEvent.js.map +1 -0
- package/lib/modules/user/index.d.ts +4 -0
- package/lib/modules/user/index.js +9 -0
- package/lib/modules/user/index.js.map +1 -0
- package/lib/routes/botServer/api/v1/emitEvent.d.ts +3 -0
- package/lib/routes/botServer/api/v1/emitEvent.js +17 -0
- package/lib/routes/botServer/api/v1/emitEvent.js.map +1 -0
- package/lib/routes/botServer/api/v1/function.d.ts +3 -0
- package/lib/routes/botServer/api/v1/function.js +22 -0
- package/lib/routes/botServer/api/v1/function.js.map +1 -0
- package/lib/routes/botServer/api/v1/ping.d.ts +3 -0
- package/lib/routes/botServer/api/v1/ping.js +12 -0
- package/lib/routes/botServer/api/v1/ping.js.map +1 -0
- package/lib/routes/botServer/api/v1/register.d.ts +3 -0
- package/lib/routes/botServer/api/v1/register.js +23 -0
- package/lib/routes/botServer/api/v1/register.js.map +1 -0
- package/lib/routes/botServer/api/v1/setValue.d.ts +3 -0
- package/lib/routes/botServer/api/v1/setValue.js +18 -0
- package/lib/routes/botServer/api/v1/setValue.js.map +1 -0
- package/lib/routes/botServer/api/v1/unregister.d.ts +3 -0
- package/lib/routes/botServer/api/v1/unregister.js +22 -0
- package/lib/routes/botServer/api/v1/unregister.js.map +1 -0
- package/lib/routes/botServer/middlewares/setBotServer.d.ts +4 -0
- package/lib/routes/botServer/middlewares/setBotServer.js +16 -0
- package/lib/routes/botServer/middlewares/setBotServer.js.map +1 -0
- package/lib/routes/botServer/routes.d.ts +8 -0
- package/lib/routes/botServer/routes.js +33 -0
- package/lib/routes/botServer/routes.js.map +1 -0
- package/lib/services/AddressService.d.ts +12 -0
- package/lib/services/AddressService.js +51 -0
- package/lib/services/AddressService.js.map +1 -0
- package/lib/services/BaseService.d.ts +5 -0
- package/lib/services/BaseService.js +19 -0
- package/lib/services/BaseService.js.map +1 -0
- package/lib/services/index.d.ts +3 -0
- package/lib/services/index.js +11 -0
- package/lib/services/index.js.map +1 -0
- package/lib/telegram/TelegramAuth.d.ts +17 -0
- package/lib/telegram/TelegramAuth.js +96 -0
- package/lib/telegram/TelegramAuth.js.map +1 -0
- package/lib/telegram/TelegramBot.d.ts +88 -0
- package/lib/telegram/TelegramBot.js +345 -0
- package/lib/telegram/TelegramBot.js.map +1 -0
- package/lib/telegram/TelegramEvents.d.ts +13 -0
- package/lib/telegram/TelegramEvents.js +131 -0
- package/lib/telegram/TelegramEvents.js.map +1 -0
- package/lib/telegram/TelegramSendingController.d.ts +36 -0
- package/lib/telegram/TelegramSendingController.js +213 -0
- package/lib/telegram/TelegramSendingController.js.map +1 -0
- package/lib/telegram/TelegramToRompotConverter.d.ts +22 -0
- package/lib/telegram/TelegramToRompotConverter.js +226 -0
- package/lib/telegram/TelegramToRompotConverter.js.map +1 -0
- package/lib/telegram/TelegramUtils.d.ts +14 -0
- package/lib/telegram/TelegramUtils.js +98 -0
- package/lib/telegram/TelegramUtils.js.map +1 -0
- package/lib/telegram/index.d.ts +7 -0
- package/lib/telegram/index.js +19 -0
- package/lib/telegram/index.js.map +1 -0
- package/lib/utils/ClientUtils.d.ts +27 -0
- package/lib/utils/ClientUtils.js +62 -0
- package/lib/utils/ClientUtils.js.map +1 -0
- package/lib/utils/Generic.d.ts +47 -0
- package/lib/utils/Generic.js +173 -0
- package/lib/utils/Generic.js.map +1 -0
- package/lib/utils/Libs.d.ts +10 -0
- package/lib/utils/Libs.js +55 -0
- package/lib/utils/Libs.js.map +1 -0
- package/lib/utils/MessageHandler.d.ts +54 -0
- package/lib/utils/MessageHandler.js +81 -0
- package/lib/utils/MessageHandler.js.map +1 -0
- package/lib/utils/MessageUtils.d.ts +3 -0
- package/lib/utils/MessageUtils.js +114 -0
- package/lib/utils/MessageUtils.js.map +1 -0
- package/lib/utils/index.d.ts +6 -0
- package/lib/utils/index.js +27 -0
- package/lib/utils/index.js.map +1 -0
- package/lib/utils/nonce.d.ts +1 -0
- package/lib/utils/nonce.js +16 -0
- package/lib/utils/nonce.js.map +1 -0
- package/lib/utils/server.d.ts +33 -0
- package/lib/utils/server.js +75 -0
- package/lib/utils/server.js.map +1 -0
- package/lib/wa/Auth.d.ts +19 -0
- package/lib/wa/Auth.js +123 -0
- package/lib/wa/Auth.js.map +1 -0
- package/lib/wa/ConfigWAEvents.d.ts +22 -0
- package/lib/wa/ConfigWAEvents.js +526 -0
- package/lib/wa/ConfigWAEvents.js.map +1 -0
- package/lib/wa/ConvertToWAMessage.d.ts +67 -0
- package/lib/wa/ConvertToWAMessage.js +403 -0
- package/lib/wa/ConvertToWAMessage.js.map +1 -0
- package/lib/wa/ConvertWAMessage.d.ts +108 -0
- package/lib/wa/ConvertWAMessage.js +527 -0
- package/lib/wa/ConvertWAMessage.js.map +1 -0
- package/lib/wa/ID.d.ts +4 -0
- package/lib/wa/ID.js +19 -0
- package/lib/wa/ID.js.map +1 -0
- package/lib/wa/WAMessage.d.ts +3 -0
- package/lib/wa/WAMessage.js +8 -0
- package/lib/wa/WAMessage.js.map +1 -0
- package/lib/wa/WAModule.d.ts +3 -0
- package/lib/wa/WAModule.js +3 -0
- package/lib/wa/WAModule.js.map +1 -0
- package/lib/wa/WAStatus.d.ts +3 -0
- package/lib/wa/WAStatus.js +15 -0
- package/lib/wa/WAStatus.js.map +1 -0
- package/lib/wa/WhatsAppBot.d.ts +188 -0
- package/lib/wa/WhatsAppBot.js +980 -0
- package/lib/wa/WhatsAppBot.js.map +1 -0
- package/lib/wa/index.d.ts +12 -0
- package/lib/wa/index.js +37 -0
- package/lib/wa/index.js.map +1 -0
- package/lib/wa/makeInMemoryStore.d.ts +43 -0
- package/lib/wa/makeInMemoryStore.js +430 -0
- package/lib/wa/makeInMemoryStore.js.map +1 -0
- package/package.json +79 -0
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
import ReactionMessage from "../messages/ReactionMessage";
|
|
2
|
+
import { Media } from "../messages/MediaMessage";
|
|
3
|
+
import ChatStatus from "../modules/chat/ChatStatus";
|
|
4
|
+
import Message from "../messages/Message";
|
|
5
|
+
import { BotStatus } from "./BotStatus";
|
|
6
|
+
import IAuth from "../client/IAuth";
|
|
7
|
+
import BotEvents from "./BotEvents";
|
|
8
|
+
import User from "../modules/user/User";
|
|
9
|
+
import Chat from "../modules/chat/Chat";
|
|
10
|
+
import Call from "../models/Call";
|
|
11
|
+
/** Interface do bot */
|
|
12
|
+
export default interface IBot extends BotEvents {
|
|
13
|
+
/** ID do bot */
|
|
14
|
+
id: string;
|
|
15
|
+
/** Status do Client */
|
|
16
|
+
status: BotStatus;
|
|
17
|
+
/** Número do bot */
|
|
18
|
+
phoneNumber: string;
|
|
19
|
+
/** Nome do bot */
|
|
20
|
+
name: string;
|
|
21
|
+
/** URL da imagem de perfil do bot */
|
|
22
|
+
profileUrl: string;
|
|
23
|
+
/** Conectar bot
|
|
24
|
+
* @param auth Autenticação do bot
|
|
25
|
+
*/
|
|
26
|
+
connect(auth: IAuth | string): Promise<void>;
|
|
27
|
+
/** Reconectar bot
|
|
28
|
+
* @param alert Alerta que está reconectando
|
|
29
|
+
*/
|
|
30
|
+
reconnect(alert?: boolean): Promise<void>;
|
|
31
|
+
/** Parar bot
|
|
32
|
+
* @param reason Razão por parar o bot
|
|
33
|
+
*/
|
|
34
|
+
stop(reason?: any): Promise<void>;
|
|
35
|
+
/**
|
|
36
|
+
* Desconecta o bot
|
|
37
|
+
*/
|
|
38
|
+
logout(): Promise<void>;
|
|
39
|
+
/** Marca uma mensagem como visualizada
|
|
40
|
+
* @param message Mensagem que será visualizada
|
|
41
|
+
*/
|
|
42
|
+
readMessage(message: Message): Promise<void>;
|
|
43
|
+
/** Adiciona uma reação na mensagem
|
|
44
|
+
* @param message Mensagem
|
|
45
|
+
* @param reaction Reação
|
|
46
|
+
*/
|
|
47
|
+
addReaction(message: ReactionMessage): Promise<void>;
|
|
48
|
+
/** Remove a reação da mensagem
|
|
49
|
+
* @param Mensagem que terá sua reação removida
|
|
50
|
+
*/
|
|
51
|
+
removeReaction(message: ReactionMessage): Promise<void>;
|
|
52
|
+
/** Edita o texto de uma mensagem enviada
|
|
53
|
+
* @param message Mensagem com o texto editado
|
|
54
|
+
*/
|
|
55
|
+
editMessage(message: Message): Promise<void>;
|
|
56
|
+
/** Enviar mensagem
|
|
57
|
+
* @param message Mensagem que será enviada
|
|
58
|
+
*/
|
|
59
|
+
send(message: Message): Promise<Message>;
|
|
60
|
+
/** Remover mensagem
|
|
61
|
+
* @param message Mensagem que será removida da sala de bate-papo
|
|
62
|
+
*/
|
|
63
|
+
removeMessage(message: Message): Promise<void>;
|
|
64
|
+
/** Deletar mensagem
|
|
65
|
+
* @param message Mensagem que será deletada da sala de bate-papos
|
|
66
|
+
*/
|
|
67
|
+
deleteMessage(message: Message): Promise<void>;
|
|
68
|
+
/** Retorna a stream da mídia
|
|
69
|
+
* @param message Mídia que será baixada
|
|
70
|
+
* @returns Stream da mídia
|
|
71
|
+
*/
|
|
72
|
+
downloadStreamMessage(media: Media): Promise<Buffer>;
|
|
73
|
+
/** @returns Retorna o nome do bot */
|
|
74
|
+
getBotName(): Promise<string>;
|
|
75
|
+
/** Define o nome do bot
|
|
76
|
+
* @param name Nome do bot
|
|
77
|
+
*/
|
|
78
|
+
setBotName(name: string): Promise<void>;
|
|
79
|
+
/** @returns Retorna a descrição do bot */
|
|
80
|
+
getBotDescription(): Promise<string>;
|
|
81
|
+
/** Define a descrição do bot
|
|
82
|
+
* @param description Descrição do bot
|
|
83
|
+
*/
|
|
84
|
+
setBotDescription(description: string): Promise<void>;
|
|
85
|
+
/** @returns Retorna foto de perfil do bot */
|
|
86
|
+
getBotProfile(lowQuality?: boolean): Promise<Buffer>;
|
|
87
|
+
/**
|
|
88
|
+
* Obter URL da imagem de perfil do bot.
|
|
89
|
+
* @returns URL da imagem de perfil do bot.
|
|
90
|
+
*/
|
|
91
|
+
getBotProfileUrl(lowQuality?: boolean): Promise<string>;
|
|
92
|
+
/** Define foto de perfil do bot
|
|
93
|
+
* @param image Foto de perfil do bot
|
|
94
|
+
*/
|
|
95
|
+
setBotProfile(image: Buffer): Promise<void>;
|
|
96
|
+
/**
|
|
97
|
+
* @param chat Sala de bate-papo
|
|
98
|
+
* @returns Retorna uma sala de bate-papo
|
|
99
|
+
*/
|
|
100
|
+
getChat(chat: Chat): Promise<Chat | null>;
|
|
101
|
+
/**
|
|
102
|
+
* Atualiza os dados de um chat.
|
|
103
|
+
* @param chat - Dados do chat que será atualizado.
|
|
104
|
+
*/
|
|
105
|
+
updateChat(chat: {
|
|
106
|
+
id: string;
|
|
107
|
+
} & Partial<Chat>): Promise<void>;
|
|
108
|
+
/** Remove uma sala de bate-papo
|
|
109
|
+
* @param chat Sala de bate-papo
|
|
110
|
+
*/
|
|
111
|
+
removeChat(chat: Chat): Promise<void>;
|
|
112
|
+
/** Adiciona um novo usuário a uma sala de bate-papo
|
|
113
|
+
* @param chat Sala de bate-papo
|
|
114
|
+
* @param user Usuário
|
|
115
|
+
*/
|
|
116
|
+
addUserInChat(chat: Chat, user: User): Promise<void>;
|
|
117
|
+
/** Adiciona um novo usuário a uma sala de bate-papo
|
|
118
|
+
* @param chat Sala de bate-papo
|
|
119
|
+
* @param user Usuário
|
|
120
|
+
*/
|
|
121
|
+
removeUserInChat(chat: Chat, user: User): Promise<void>;
|
|
122
|
+
/** Promove há administrador um usuário da sala de bate-papo
|
|
123
|
+
* @param chat Sala de bate-papo
|
|
124
|
+
* @param user Usuário
|
|
125
|
+
*/
|
|
126
|
+
promoteUserInChat(chat: Chat, user: User): Promise<void>;
|
|
127
|
+
/** Remove a administração um usuário da sala de bate-papo
|
|
128
|
+
* @param chat Sala de bate-papo
|
|
129
|
+
* @param user Usuário
|
|
130
|
+
*/
|
|
131
|
+
demoteUserInChat(chat: Chat, user: User): Promise<void>;
|
|
132
|
+
/** Altera o status da sala de bate-papo
|
|
133
|
+
* @param chat Sala de bate-papo
|
|
134
|
+
* @param status Status da sala de bate-papo
|
|
135
|
+
*/
|
|
136
|
+
changeChatStatus(chat: Chat, status: ChatStatus): Promise<void>;
|
|
137
|
+
/** Cria uma sala de bate-papo
|
|
138
|
+
* @param chat Sala de bate-papo
|
|
139
|
+
*/
|
|
140
|
+
createChat(chat: Chat): Promise<void>;
|
|
141
|
+
/** Sai de uma sala de bate-papo
|
|
142
|
+
* @param chat Sala de bate-papo
|
|
143
|
+
*/
|
|
144
|
+
leaveChat(chat: Chat): Promise<void>;
|
|
145
|
+
/**
|
|
146
|
+
* @param chat Sala de bate-papo
|
|
147
|
+
* @returns Retorna o nome da sala de bate-papo
|
|
148
|
+
*/
|
|
149
|
+
getChatName(chat: Chat): Promise<string>;
|
|
150
|
+
/** Define o nome da sala de bate-papo
|
|
151
|
+
* @param chat Sala de bate-papo
|
|
152
|
+
* @param name Nome da sala de bate-papo
|
|
153
|
+
*/
|
|
154
|
+
setChatName(chat: Chat, name: string): Promise<void>;
|
|
155
|
+
/**
|
|
156
|
+
* @param chat Sala de bate-papo
|
|
157
|
+
* @returns Retorna a descrição da sala de bate-papo
|
|
158
|
+
*/
|
|
159
|
+
getChatDescription(chat: Chat): Promise<string>;
|
|
160
|
+
/** Define a descrição da sala de bate-papo
|
|
161
|
+
* @param chat Sala de bate-papo
|
|
162
|
+
* @param description Descrição da sala de bate-papo
|
|
163
|
+
*/
|
|
164
|
+
setChatDescription(chat: Chat, description: string): Promise<void>;
|
|
165
|
+
/**
|
|
166
|
+
* @param chat Sala de bate-papo
|
|
167
|
+
* @returns Retorna a imagem de perfil da sala de bate-papo
|
|
168
|
+
*/
|
|
169
|
+
getChatProfile(chat: Chat, lowQuality?: boolean): Promise<Buffer>;
|
|
170
|
+
/**
|
|
171
|
+
* Obter URL da imagem de perfil do chat.
|
|
172
|
+
* @param chat - Chat que será obtido a URL da imagem de perfil.
|
|
173
|
+
* @returns URL da imagem de perfil do chat.
|
|
174
|
+
*/
|
|
175
|
+
getChatProfileUrl(chat: Chat, lowQuality?: boolean): Promise<string>;
|
|
176
|
+
/** Define a imagem de perfil da sala de bate-papo
|
|
177
|
+
* @param chat Sala de bate-papo
|
|
178
|
+
* @param profile Imagem de perfil da sala de bate-papo
|
|
179
|
+
*/
|
|
180
|
+
setChatProfile(chat: Chat, profile: Buffer): Promise<void>;
|
|
181
|
+
/**
|
|
182
|
+
* @param chat Sala de bate-papo
|
|
183
|
+
* @returns Retorna os usuários de uma sala de bate-papo
|
|
184
|
+
*/
|
|
185
|
+
getChatUsers(chat: Chat): Promise<string[]>;
|
|
186
|
+
/**
|
|
187
|
+
* @param chat Sala de bate-papo
|
|
188
|
+
* @returns Retorna os administradores de uma sala de bate-papo
|
|
189
|
+
*/
|
|
190
|
+
getChatAdmins(chat: Chat): Promise<string[]>;
|
|
191
|
+
/**
|
|
192
|
+
* @param chat Sala de bate-papo
|
|
193
|
+
* @returns Retorna o lider da sala de bate-papo
|
|
194
|
+
*/
|
|
195
|
+
getChatLeader(chat: Chat): Promise<string>;
|
|
196
|
+
/**
|
|
197
|
+
* @returns Retorna as sala de bate-papo que o bot está
|
|
198
|
+
*/
|
|
199
|
+
getChats(): Promise<string[]>;
|
|
200
|
+
/** Define as salas de bate-papo que o bot está
|
|
201
|
+
* @param chats Salas de bate-papo
|
|
202
|
+
*/
|
|
203
|
+
setChats(chats: Chat[]): Promise<void>;
|
|
204
|
+
/**
|
|
205
|
+
* Entra no chat pelo código de convite.
|
|
206
|
+
* @param code - Código de convite do chat.
|
|
207
|
+
*/
|
|
208
|
+
joinChat(code: string): Promise<void>;
|
|
209
|
+
/**
|
|
210
|
+
* Obtem o código de convite do chat.
|
|
211
|
+
* @param chat - Chat que será obtido o código de convite.
|
|
212
|
+
* @returns O código de convite do chat.
|
|
213
|
+
*/
|
|
214
|
+
getChatInvite(chat: Chat): Promise<string>;
|
|
215
|
+
/**
|
|
216
|
+
* Revoga o código de convite do chat.
|
|
217
|
+
* @param chat - Chat que terá seu código de convite revogado.
|
|
218
|
+
* @returns O novo código de convite do chat.
|
|
219
|
+
*/
|
|
220
|
+
revokeChatInvite(chat: Chat): Promise<string>;
|
|
221
|
+
/**
|
|
222
|
+
* Rejeita uma chamada.
|
|
223
|
+
* @param call - A chamada que será rejeitada.
|
|
224
|
+
*/
|
|
225
|
+
rejectCall(call: Call): Promise<void>;
|
|
226
|
+
/**
|
|
227
|
+
* @param user Usuário
|
|
228
|
+
* @returns Retorna um usuário
|
|
229
|
+
*/
|
|
230
|
+
getUser(user: User): Promise<User | null>;
|
|
231
|
+
/**
|
|
232
|
+
* Atualiza os dados de um usuário.
|
|
233
|
+
* @param user - Dados do usuário que será atualizado.
|
|
234
|
+
*/
|
|
235
|
+
updateUser(user: {
|
|
236
|
+
id: string;
|
|
237
|
+
} & Partial<User>): Promise<void>;
|
|
238
|
+
/** Remove um usuário
|
|
239
|
+
* @param user Usuário
|
|
240
|
+
*/
|
|
241
|
+
removeUser(user: User): Promise<void>;
|
|
242
|
+
/**
|
|
243
|
+
* @param user Usuário
|
|
244
|
+
* @returns Retorna o nome do usuário
|
|
245
|
+
*/
|
|
246
|
+
getUserName(user: User): Promise<string>;
|
|
247
|
+
/** Define o nome do usuário
|
|
248
|
+
* @param user Usuário
|
|
249
|
+
* @param name Nome do usuário
|
|
250
|
+
*/
|
|
251
|
+
setUserName(user: User, name: string): Promise<void>;
|
|
252
|
+
/**
|
|
253
|
+
* @param user Usuário
|
|
254
|
+
* @returns Retorna a descrição do usuário
|
|
255
|
+
*/
|
|
256
|
+
getUserDescription(user: User): Promise<string>;
|
|
257
|
+
/** Define a descrição do usuário
|
|
258
|
+
* @param user Usuário
|
|
259
|
+
* @param description Descrição do usuário
|
|
260
|
+
*/
|
|
261
|
+
setUserDescription(user: User, description: string): Promise<void>;
|
|
262
|
+
/**
|
|
263
|
+
* @param user Usuário
|
|
264
|
+
* @returns Retorna a foto de perfil do usuário
|
|
265
|
+
*/
|
|
266
|
+
getUserProfile(user: User, lowQuality?: boolean): Promise<Buffer>;
|
|
267
|
+
/**
|
|
268
|
+
* Obter URL da imagem de perfil do user.
|
|
269
|
+
* @param user - Usuário que será obtido a URL da imagem de perfil.
|
|
270
|
+
* @returns URL da imagem de perfil do usuário.
|
|
271
|
+
*/
|
|
272
|
+
getUserProfileUrl(user: User, lowQuality?: boolean): Promise<string>;
|
|
273
|
+
/** Define a foto de perfil do usuário
|
|
274
|
+
* @param user Usuário
|
|
275
|
+
* @param profile Imagem de perfil do usuário
|
|
276
|
+
*/
|
|
277
|
+
setUserProfile(user: User, profile: Buffer): Promise<void>;
|
|
278
|
+
/** Desbloqueia um usuário
|
|
279
|
+
* @param user Usuário
|
|
280
|
+
*/
|
|
281
|
+
unblockUser(user: User): Promise<void>;
|
|
282
|
+
/** Bloqueia um usuário
|
|
283
|
+
* @param user Usuário
|
|
284
|
+
*/
|
|
285
|
+
blockUser(user: User): Promise<void>;
|
|
286
|
+
/** @returns Retorna a lista de usuários do bot */
|
|
287
|
+
getUsers(): Promise<string[]>;
|
|
288
|
+
/** Define a lista de usuários do bot
|
|
289
|
+
* @param users Usuários
|
|
290
|
+
*/
|
|
291
|
+
setUsers(users: User[]): Promise<void>;
|
|
292
|
+
}
|
package/lib/bot/IBot.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IBot.js","sourceRoot":"","sources":["../../src/bot/IBot.ts"],"names":[],"mappings":""}
|
package/lib/bot/index.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.BotStatus = exports.BotEvents = exports.BotBase = void 0;
|
|
7
|
+
const BotStatus_1 = require("./BotStatus");
|
|
8
|
+
Object.defineProperty(exports, "BotStatus", { enumerable: true, get: function () { return BotStatus_1.BotStatus; } });
|
|
9
|
+
const BotEvents_1 = __importDefault(require("./BotEvents"));
|
|
10
|
+
exports.BotEvents = BotEvents_1.default;
|
|
11
|
+
const BotBase_1 = __importDefault(require("./BotBase"));
|
|
12
|
+
exports.BotBase = BotBase_1.default;
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/bot/index.ts"],"names":[],"mappings":";;;;;;AAAA,2CAAwC;AAKL,0FAL1B,qBAAS,OAK0B;AAJ5C,4DAAoC;AAIZ,oBAJjB,mBAAS,CAIiB;AAHjC,wDAAgC;AAGjB,kBAHR,iBAAO,CAGQ"}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { Buffer } from 'buffer';
|
|
2
|
+
import ConnectionConfig from '../configs/ConnectionConfig';
|
|
3
|
+
import Message from '../messages/Message';
|
|
4
|
+
import MediaMessage from '../messages/MediaMessage';
|
|
5
|
+
import QuickResponseController from '../modules/quickResponse/QuickResponseController';
|
|
6
|
+
import ChatStatus from '../modules/chat/ChatStatus';
|
|
7
|
+
import Chat from '../modules/chat/Chat';
|
|
8
|
+
import User from '../modules/user/User';
|
|
9
|
+
import Command from '../modules/command/Command';
|
|
10
|
+
import CommandController from '../modules/command/CommandController';
|
|
11
|
+
import ClientEvents, { ClientEventsMap } from './ClientEvents';
|
|
12
|
+
import IAuth from './IAuth';
|
|
13
|
+
import IClient from './IClient';
|
|
14
|
+
import IBot from '../bot/IBot';
|
|
15
|
+
import MessageHandler, { MessageHandlerConfig } from '../utils/MessageHandler';
|
|
16
|
+
import { QuickResponseOptions, QuickResponsePattern, QuickResponseReply } from '../modules/quickResponse';
|
|
17
|
+
import QuickResponse from '../modules/quickResponse/QuickResponse';
|
|
18
|
+
import AdvancedCommandController from '../modules/command/advanced/AdvancedCommandController';
|
|
19
|
+
import AdvancedCommand from '../modules/command/advanced/AdvancedCommand';
|
|
20
|
+
import Call from '../models/Call';
|
|
21
|
+
export default class Client<Bot extends IBot = IBot> extends ClientEvents implements IClient {
|
|
22
|
+
funcHandler: any;
|
|
23
|
+
commandController: CommandController;
|
|
24
|
+
advancedCommandController: AdvancedCommandController;
|
|
25
|
+
quickResponseController: QuickResponseController;
|
|
26
|
+
messageHandler: MessageHandler;
|
|
27
|
+
reconnectTimes: number;
|
|
28
|
+
config: ConnectionConfig;
|
|
29
|
+
bot: Bot;
|
|
30
|
+
id: string;
|
|
31
|
+
constructor(bot: Bot, config?: Partial<ConnectionConfig>);
|
|
32
|
+
configEvents(): void;
|
|
33
|
+
connect(auth: IAuth | string): Promise<void>;
|
|
34
|
+
reconnect(alert?: boolean): Promise<void>;
|
|
35
|
+
stop(reason?: any): Promise<void>;
|
|
36
|
+
logout(): Promise<void>;
|
|
37
|
+
awaitEvent<T extends keyof ClientEventsMap>(eventName: T, maxTimeout?: number): Promise<ClientEventsMap[T]>;
|
|
38
|
+
awaitConnectionOpen(): Promise<void>;
|
|
39
|
+
getCommandController(): CommandController;
|
|
40
|
+
setCommandController(controller: CommandController): void;
|
|
41
|
+
setCommands(commands: Command[]): void;
|
|
42
|
+
getCommands(): Command[];
|
|
43
|
+
addCommand(command: Command): void;
|
|
44
|
+
removeCommand(command: Command): boolean;
|
|
45
|
+
searchCommand(text: string): Command | null;
|
|
46
|
+
runCommand(command: Command, message: Message, type?: string): Promise<any>;
|
|
47
|
+
setAdvancedCommandController(advancedCommandController: AdvancedCommandController): void;
|
|
48
|
+
getAdvancedCommandController(): AdvancedCommandController;
|
|
49
|
+
setAdvancedCommands(commands: AdvancedCommand[]): void;
|
|
50
|
+
getAdvancedCommands(): AdvancedCommand<object>[];
|
|
51
|
+
createAdvancedCommand<T extends object>(id: string, context: T): AdvancedCommand<T>;
|
|
52
|
+
addAdvancedCommand(command: AdvancedCommand): void;
|
|
53
|
+
removeAdvancedCommand(command: AdvancedCommand): boolean;
|
|
54
|
+
execAdvancedCommand(command: AdvancedCommand | string, message: Message): Promise<void>;
|
|
55
|
+
addQuickResponse(pattern: QuickResponse): QuickResponse;
|
|
56
|
+
addQuickResponse(pattern: QuickResponsePattern, reply: QuickResponseReply, options?: Partial<QuickResponseOptions>): QuickResponse;
|
|
57
|
+
addQuickResponse(pattern: QuickResponsePattern[], reply: QuickResponseReply, options?: Partial<QuickResponseOptions>): QuickResponse;
|
|
58
|
+
removeQuickResponse(quickResponse: QuickResponse | string): void;
|
|
59
|
+
deleteMessage(message: Message): Promise<void>;
|
|
60
|
+
removeMessage(message: Message): Promise<void>;
|
|
61
|
+
readMessage(message: Message): Promise<void>;
|
|
62
|
+
editMessage(message: Message, text: string): Promise<void>;
|
|
63
|
+
addReaction(message: Message, reaction: string): Promise<void>;
|
|
64
|
+
removeReaction(message: Message): Promise<void>;
|
|
65
|
+
addAnimatedReaction(message: Message, reactions: string[], interval?: number, maxTimeout?: number): (reactionStop?: string) => Promise<void>;
|
|
66
|
+
send(message: Message): Promise<Message>;
|
|
67
|
+
sendMessage(chat: Chat | string, message: string | Message, mention?: Message): Promise<Message>;
|
|
68
|
+
awaitMessage(chat: Chat | string, config?: Partial<MessageHandlerConfig>): Promise<Message>;
|
|
69
|
+
downloadStreamMessage(message: MediaMessage): Promise<Buffer>;
|
|
70
|
+
getBotName(): Promise<string>;
|
|
71
|
+
setBotName(name: string): any;
|
|
72
|
+
getBotDescription(): any;
|
|
73
|
+
setBotDescription(description: string): any;
|
|
74
|
+
getBotProfile(lowQuality?: boolean): any;
|
|
75
|
+
setBotProfile(profile: Buffer): any;
|
|
76
|
+
getChat(chat: Chat | string): Promise<Chat | null>;
|
|
77
|
+
updateChat(id: string, chat: Partial<Chat>): Promise<void>;
|
|
78
|
+
getChats(): Promise<Chat[]>;
|
|
79
|
+
setChats(chats: Chat[]): Promise<void>;
|
|
80
|
+
removeChat(chat: string | Chat): Promise<void>;
|
|
81
|
+
createChat(chat: Chat): any;
|
|
82
|
+
leaveChat(chat: Chat | string): any;
|
|
83
|
+
getChatName(chat: Chat | string): any;
|
|
84
|
+
setChatName(chat: Chat | string, name: string): any;
|
|
85
|
+
getChatDescription(chat: Chat | string): any;
|
|
86
|
+
setChatDescription(chat: Chat | string, description: string): any;
|
|
87
|
+
getChatProfile(chat: Chat | string, lowQuality?: boolean): any;
|
|
88
|
+
setChatProfile(chat: Chat | string, profile: Buffer): any;
|
|
89
|
+
getChatLeader(chat: Chat | string): Promise<User>;
|
|
90
|
+
getChatUsers(chat: Chat | string): Promise<string[]>;
|
|
91
|
+
getChatAdmins(chat: Chat | string): Promise<string[]>;
|
|
92
|
+
addUserInChat(chat: Chat | string, user: User | string): any;
|
|
93
|
+
removeUserInChat(chat: Chat | string, user: User | string): any;
|
|
94
|
+
promoteUserInChat(chat: Chat | string, user: User | string): any;
|
|
95
|
+
demoteUserInChat(chat: Chat | string, user: User | string): any;
|
|
96
|
+
changeChatStatus(chat: Chat | string, status: ChatStatus): Promise<void>;
|
|
97
|
+
joinChat(code: string): Promise<void>;
|
|
98
|
+
getChatInvite(chat: Chat | string): Promise<string>;
|
|
99
|
+
revokeChatInvite(chat: Chat | string): Promise<string>;
|
|
100
|
+
rejectCall(call: Call | string): Promise<void>;
|
|
101
|
+
getUsers(): Promise<User[]>;
|
|
102
|
+
getSavedUsers(): Promise<User[]>;
|
|
103
|
+
setUsers(users: User[]): any;
|
|
104
|
+
getUser(user: User | string): Promise<User | null>;
|
|
105
|
+
updateUser(id: string, user: Partial<User>): Promise<void>;
|
|
106
|
+
removeUser(user: User | string): any;
|
|
107
|
+
getUserName(user: User | string): any;
|
|
108
|
+
setUserName(user: User | string, name: string): any;
|
|
109
|
+
getUserDescription(user: User | string): any;
|
|
110
|
+
setUserDescription(user: User | string, description: string): any;
|
|
111
|
+
getUserProfile(user: User | string, lowQuality?: boolean): any;
|
|
112
|
+
setUserProfile(user: User | string, profile: Buffer): any;
|
|
113
|
+
unblockUser(user: User | string): any;
|
|
114
|
+
blockUser(user: User | string): any;
|
|
115
|
+
static getClients(): Record<string, Client<IBot>>;
|
|
116
|
+
static saveClients(clients: Record<string, Client<IBot>>): void;
|
|
117
|
+
static getClient(id: string): Client<IBot>;
|
|
118
|
+
static saveClient(client: Client<IBot>): void;
|
|
119
|
+
static generateId(): string;
|
|
120
|
+
}
|