@builderbot/provider-telegram 1.3.15-alpha.19 → 1.3.15-alpha.20
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/dist/index.cjs +16 -0
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -47991,6 +47991,22 @@ class TelegramProvider extends bot$1.ProviderClass {
|
|
|
47991
47991
|
async markAsRead(from) {
|
|
47992
47992
|
await this.client.markAsRead(from);
|
|
47993
47993
|
}
|
|
47994
|
+
async sendPresenceUpdate(chatId, action = 'typing') {
|
|
47995
|
+
let typingAction;
|
|
47996
|
+
if (action === 'recording') {
|
|
47997
|
+
typingAction = new telegramExports.Api.SendMessageRecordAudioAction();
|
|
47998
|
+
}
|
|
47999
|
+
else if (action === 'cancel') {
|
|
48000
|
+
typingAction = new telegramExports.Api.SendMessageCancelAction();
|
|
48001
|
+
}
|
|
48002
|
+
else {
|
|
48003
|
+
typingAction = new telegramExports.Api.SendMessageTypingAction();
|
|
48004
|
+
}
|
|
48005
|
+
await this.client.invoke(new telegramExports.Api.messages.SetTyping({
|
|
48006
|
+
peer: chatId,
|
|
48007
|
+
action: typingAction,
|
|
48008
|
+
}));
|
|
48009
|
+
}
|
|
47994
48010
|
async sendButtons(chatId, text, buttons) {
|
|
47995
48011
|
return;
|
|
47996
48012
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@builderbot/provider-telegram",
|
|
3
|
-
"version": "1.3.15-alpha.
|
|
3
|
+
"version": "1.3.15-alpha.20",
|
|
4
4
|
"description": "Provider for Telegram",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"author": "",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
},
|
|
30
30
|
"homepage": "https://github.com/codigoencasa/bot-whatsapp#readme",
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@builderbot/bot": "^1.3.15-alpha.
|
|
32
|
+
"@builderbot/bot": "^1.3.15-alpha.20",
|
|
33
33
|
"@hapi/boom": "^10.0.1",
|
|
34
34
|
"@jest/globals": "^30.2.0",
|
|
35
35
|
"@rollup/plugin-commonjs": "^29.0.0",
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"dependencies": {
|
|
50
50
|
"telegram": "^2.23.10"
|
|
51
51
|
},
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "9e42f89f192af0c70931241e820e726f822dd9cc"
|
|
53
53
|
}
|