@vanzxy/baileys 1.3.6 → 1.3.8
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/README.md +1 -1
- package/WAProto/index.d.ts +9 -15871
- package/lib/Defaults/index.d.ts +7 -5
- package/lib/Defaults/index.js +4 -1
- package/lib/Signal/Group/ciphertext-message.d.ts +0 -1
- package/lib/Signal/Group/group-session-builder.d.ts +0 -1
- package/lib/Signal/Group/group_cipher.d.ts +0 -1
- package/lib/Signal/Group/index.d.ts +0 -1
- package/lib/Signal/Group/keyhelper.d.ts +0 -1
- package/lib/Signal/Group/sender-chain-key.d.ts +0 -1
- package/lib/Signal/Group/sender-key-distribution-message.d.ts +0 -1
- package/lib/Signal/Group/sender-key-message.d.ts +0 -1
- package/lib/Signal/Group/sender-key-name.d.ts +0 -1
- package/lib/Signal/Group/sender-key-record.d.ts +0 -1
- package/lib/Signal/Group/sender-key-state.d.ts +0 -1
- package/lib/Signal/Group/sender-message-key.d.ts +0 -1
- package/lib/Signal/libsignal.d.ts +0 -1
- package/lib/Signal/lid-mapping.d.ts +0 -1
- package/lib/Socket/Client/index.d.ts +0 -1
- package/lib/Socket/Client/types.d.ts +0 -1
- package/lib/Socket/Client/websocket.d.ts +0 -1
- package/lib/Socket/business.d.ts +7 -7
- package/lib/Socket/chats.d.ts +0 -1
- package/lib/Socket/communities.d.ts +7 -8
- package/lib/Socket/communities.js +4 -2
- package/lib/Socket/dugong.d.ts +117 -0
- package/lib/Socket/dugong.js +26 -1
- package/lib/Socket/groups.d.ts +1 -2
- package/lib/Socket/index.d.ts +7 -6
- package/lib/Socket/messages-recv.d.ts +7 -8
- package/lib/Socket/messages-send.d.ts +6 -7
- package/lib/Socket/mex.d.ts +0 -1
- package/lib/Socket/newsletter.d.ts +3 -5
- package/lib/Socket/newsletter.js +19 -19
- package/lib/Socket/socket.d.ts +0 -1
- package/lib/Store/index.d.ts +0 -1
- package/lib/Store/make-in-memory-store.d.ts +0 -1
- package/lib/Store/make-ordered-dictionary.d.ts +0 -1
- package/lib/Store/object-repository.d.ts +0 -1
- package/lib/Types/Auth.d.ts +115 -0
- package/lib/Types/Bussines.d.ts +24 -1
- package/lib/Types/Call.d.ts +14 -1
- package/lib/Types/Chat.d.ts +123 -1
- package/lib/Types/Contact.d.ts +25 -1
- package/lib/Types/Events.d.ts +255 -1
- package/lib/Types/GroupMetadata.d.ts +70 -1
- package/lib/Types/Label.d.ts +0 -1
- package/lib/Types/LabelAssociation.d.ts +0 -1
- package/lib/Types/Message.d.ts +8 -9
- package/lib/Types/Mex.d.ts +0 -1
- package/lib/Types/Product.d.ts +78 -1
- package/lib/Types/RichType.d.ts +0 -1
- package/lib/Types/Signal.d.ts +85 -0
- package/lib/Types/Socket.d.ts +135 -1
- package/lib/Types/State.d.ts +0 -1
- package/lib/Types/USync.d.ts +25 -1
- package/lib/Types/index.d.ts +65 -13
- package/lib/Utils/auth-utils.d.ts +0 -1
- package/lib/Utils/browser-utils.d.ts +1 -2
- package/lib/Utils/business.d.ts +0 -1
- package/lib/Utils/business.js +2 -1
- package/lib/Utils/chat-utils.d.ts +15 -17
- package/lib/Utils/chat-utils.js +15 -1
- package/lib/Utils/companion-reg-client-utils.d.ts +0 -1
- package/lib/Utils/crypto.d.ts +2 -1
- package/lib/Utils/decode-wa-message.d.ts +0 -1
- package/lib/Utils/decode-wa-message.js +1 -3
- package/lib/Utils/event-buffer.d.ts +1 -2
- package/lib/Utils/generics.d.ts +0 -1
- package/lib/Utils/generics.js +11 -9
- package/lib/Utils/history.d.ts +17 -3
- package/lib/Utils/identity-change-handler.d.ts +0 -1
- package/lib/Utils/index.d.ts +0 -1
- package/lib/Utils/link-preview.d.ts +0 -1
- package/lib/Utils/logger.d.ts +0 -1
- package/lib/Utils/lt-hash.d.ts +7 -2
- package/lib/Utils/lt-hash.js +21 -2
- package/lib/Utils/make-mutex.d.ts +0 -1
- package/lib/Utils/message-retry-manager.d.ts +0 -1
- package/lib/Utils/messages-media.d.ts +2 -4
- package/lib/Utils/messages.d.ts +5 -7
- package/lib/Utils/messages.js +30 -26
- package/lib/Utils/noise-handler.d.ts +0 -1
- package/lib/Utils/offline-node-processor.d.ts +0 -1
- package/lib/Utils/pre-key-manager.d.ts +0 -1
- package/lib/Utils/process-message.d.ts +3 -5
- package/lib/Utils/reporting-utils.d.ts +0 -1
- package/lib/Utils/rich-message-utils.d.ts +1 -2
- package/lib/Utils/signal.d.ts +0 -1
- package/lib/Utils/stanza-ack.d.ts +0 -1
- package/lib/Utils/sync-action-utils.d.ts +0 -1
- package/lib/Utils/tc-token-utils.d.ts +0 -1
- package/lib/Utils/use-multi-file-auth-state.d.ts +0 -1
- package/lib/Utils/use-single-file-auth-state.d.ts +0 -1
- package/lib/Utils/use-single-file-auth-state.js +6 -1
- package/lib/Utils/use-sqlite-auth-state.d.ts +1 -1
- package/lib/Utils/use-sqlite-auth-state.js +12 -0
- package/lib/Utils/validate-connection.d.ts +4 -6
- package/lib/WABinary/constants.d.ts +0 -1
- package/lib/WABinary/decode.d.ts +0 -1
- package/lib/WABinary/encode.d.ts +0 -1
- package/lib/WABinary/generic-utils.d.ts +1 -4
- package/lib/WABinary/index.d.ts +0 -1
- package/lib/WABinary/jid-utils.d.ts +0 -1
- package/lib/WABinary/types.d.ts +18 -1
- package/lib/WAM/BinaryInfo.d.ts +0 -1
- package/lib/WAM/constants.d.ts +0 -1
- package/lib/WAM/encode.d.ts +0 -1
- package/lib/WAM/index.d.ts +0 -1
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +8 -2
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts +0 -1
- package/lib/WAUSync/Protocols/index.d.ts +2 -1
- package/lib/WAUSync/USyncQuery.d.ts +0 -1
- package/lib/WAUSync/USyncUser.d.ts +0 -1
- package/lib/WAUSync/index.d.ts +0 -1
- package/lib/index.d.ts +1 -1
- package/package.json +12 -7
- package/postinstall-banner.js +23 -0
- package/lib/Defaults/index.d.ts.map +0 -1
- package/lib/Defaults/index.js.map +0 -1
- package/lib/Signal/Group/ciphertext-message.d.ts.map +0 -1
- package/lib/Signal/Group/ciphertext-message.js.map +0 -1
- package/lib/Signal/Group/group-session-builder.d.ts.map +0 -1
- package/lib/Signal/Group/group-session-builder.js.map +0 -1
- package/lib/Signal/Group/group_cipher.d.ts.map +0 -1
- package/lib/Signal/Group/group_cipher.js.map +0 -1
- package/lib/Signal/Group/index.d.ts.map +0 -1
- package/lib/Signal/Group/index.js.map +0 -1
- package/lib/Signal/Group/keyhelper.d.ts.map +0 -1
- package/lib/Signal/Group/keyhelper.js.map +0 -1
- package/lib/Signal/Group/sender-chain-key.d.ts.map +0 -1
- package/lib/Signal/Group/sender-chain-key.js.map +0 -1
- package/lib/Signal/Group/sender-key-distribution-message.d.ts.map +0 -1
- package/lib/Signal/Group/sender-key-distribution-message.js.map +0 -1
- package/lib/Signal/Group/sender-key-message.d.ts.map +0 -1
- package/lib/Signal/Group/sender-key-message.js.map +0 -1
- package/lib/Signal/Group/sender-key-name.d.ts.map +0 -1
- package/lib/Signal/Group/sender-key-name.js.map +0 -1
- package/lib/Signal/Group/sender-key-record.d.ts.map +0 -1
- package/lib/Signal/Group/sender-key-record.js.map +0 -1
- package/lib/Signal/Group/sender-key-state.d.ts.map +0 -1
- package/lib/Signal/Group/sender-key-state.js.map +0 -1
- package/lib/Signal/Group/sender-message-key.d.ts.map +0 -1
- package/lib/Signal/Group/sender-message-key.js.map +0 -1
- package/lib/Signal/libsignal.d.ts.map +0 -1
- package/lib/Signal/libsignal.js.map +0 -1
- package/lib/Signal/lid-mapping.d.ts.map +0 -1
- package/lib/Signal/lid-mapping.js.map +0 -1
- package/lib/Socket/Client/index.d.ts.map +0 -1
- package/lib/Socket/Client/index.js.map +0 -1
- package/lib/Socket/Client/types.d.ts.map +0 -1
- package/lib/Socket/Client/types.js.map +0 -1
- package/lib/Socket/Client/websocket.d.ts.map +0 -1
- package/lib/Socket/Client/websocket.js.map +0 -1
- package/lib/Socket/business.d.ts.map +0 -1
- package/lib/Socket/business.js.map +0 -1
- package/lib/Socket/chats.d.ts.map +0 -1
- package/lib/Socket/chats.js.map +0 -1
- package/lib/Socket/communities.d.ts.map +0 -1
- package/lib/Socket/communities.js.map +0 -1
- package/lib/Socket/groups.d.ts.map +0 -1
- package/lib/Socket/groups.js.map +0 -1
- package/lib/Socket/index.d.ts.map +0 -1
- package/lib/Socket/index.js.map +0 -1
- package/lib/Socket/messages-recv.d.ts.map +0 -1
- package/lib/Socket/messages-recv.js.map +0 -1
- package/lib/Socket/messages-send.d.ts.map +0 -1
- package/lib/Socket/messages-send.js.map +0 -1
- package/lib/Socket/mex.d.ts.map +0 -1
- package/lib/Socket/mex.js.map +0 -1
- package/lib/Socket/newsletter.d.ts.map +0 -1
- package/lib/Socket/newsletter.js.map +0 -1
- package/lib/Socket/socket.d.ts.map +0 -1
- package/lib/Socket/socket.js.map +0 -1
- package/lib/Store/index.d.ts.map +0 -1
- package/lib/Store/index.js.map +0 -1
- package/lib/Store/make-in-memory-store.d.ts.map +0 -1
- package/lib/Store/make-in-memory-store.js.map +0 -1
- package/lib/Store/make-ordered-dictionary.d.ts.map +0 -1
- package/lib/Store/make-ordered-dictionary.js.map +0 -1
- package/lib/Store/object-repository.d.ts.map +0 -1
- package/lib/Store/object-repository.js.map +0 -1
- package/lib/Types/Auth.d.ts.map +0 -1
- package/lib/Types/Auth.js.map +0 -1
- package/lib/Types/Bussines.d.ts.map +0 -1
- package/lib/Types/Bussines.js.map +0 -1
- package/lib/Types/Call.d.ts.map +0 -1
- package/lib/Types/Call.js.map +0 -1
- package/lib/Types/Chat.d.ts.map +0 -1
- package/lib/Types/Chat.js.map +0 -1
- package/lib/Types/Contact.d.ts.map +0 -1
- package/lib/Types/Contact.js.map +0 -1
- package/lib/Types/Events.d.ts.map +0 -1
- package/lib/Types/Events.js.map +0 -1
- package/lib/Types/GroupMetadata.d.ts.map +0 -1
- package/lib/Types/GroupMetadata.js.map +0 -1
- package/lib/Types/Label.d.ts.map +0 -1
- package/lib/Types/Label.js.map +0 -1
- package/lib/Types/LabelAssociation.d.ts.map +0 -1
- package/lib/Types/LabelAssociation.js.map +0 -1
- package/lib/Types/Message.d.ts.map +0 -1
- package/lib/Types/Message.js.map +0 -1
- package/lib/Types/Mex.d.ts.map +0 -1
- package/lib/Types/Mex.js.map +0 -1
- package/lib/Types/Product.d.ts.map +0 -1
- package/lib/Types/Product.js.map +0 -1
- package/lib/Types/RichType.d.ts.map +0 -1
- package/lib/Types/RichType.js.map +0 -1
- package/lib/Types/Signal.d.ts.map +0 -1
- package/lib/Types/Signal.js.map +0 -1
- package/lib/Types/Socket.d.ts.map +0 -1
- package/lib/Types/Socket.js.map +0 -1
- package/lib/Types/State.d.ts.map +0 -1
- package/lib/Types/State.js.map +0 -1
- package/lib/Types/USync.d.ts.map +0 -1
- package/lib/Types/USync.js.map +0 -1
- package/lib/Types/index.d.ts.map +0 -1
- package/lib/Types/index.js.map +0 -1
- package/lib/Utils/auth-utils.d.ts.map +0 -1
- package/lib/Utils/auth-utils.js.map +0 -1
- package/lib/Utils/browser-utils.d.ts.map +0 -1
- package/lib/Utils/browser-utils.js.map +0 -1
- package/lib/Utils/business.d.ts.map +0 -1
- package/lib/Utils/business.js.map +0 -1
- package/lib/Utils/chat-utils.d.ts.map +0 -1
- package/lib/Utils/chat-utils.js.map +0 -1
- package/lib/Utils/companion-reg-client-utils.d.ts.map +0 -1
- package/lib/Utils/companion-reg-client-utils.js.map +0 -1
- package/lib/Utils/crypto.d.ts.map +0 -1
- package/lib/Utils/crypto.js.map +0 -1
- package/lib/Utils/decode-wa-message.d.ts.map +0 -1
- package/lib/Utils/decode-wa-message.js.map +0 -1
- package/lib/Utils/event-buffer.d.ts.map +0 -1
- package/lib/Utils/event-buffer.js.map +0 -1
- package/lib/Utils/generics.d.ts.map +0 -1
- package/lib/Utils/generics.js.map +0 -1
- package/lib/Utils/history.d.ts.map +0 -1
- package/lib/Utils/history.js.map +0 -1
- package/lib/Utils/identity-change-handler.d.ts.map +0 -1
- package/lib/Utils/identity-change-handler.js.map +0 -1
- package/lib/Utils/index.d.ts.map +0 -1
- package/lib/Utils/index.js.map +0 -1
- package/lib/Utils/link-preview.d.ts.map +0 -1
- package/lib/Utils/link-preview.js.map +0 -1
- package/lib/Utils/logger.d.ts.map +0 -1
- package/lib/Utils/logger.js.map +0 -1
- package/lib/Utils/lt-hash.d.ts.map +0 -1
- package/lib/Utils/lt-hash.js.map +0 -1
- package/lib/Utils/make-mutex.d.ts.map +0 -1
- package/lib/Utils/make-mutex.js.map +0 -1
- package/lib/Utils/message-retry-manager.d.ts.map +0 -1
- package/lib/Utils/message-retry-manager.js.map +0 -1
- package/lib/Utils/messages-media.d.ts.map +0 -1
- package/lib/Utils/messages-media.js.map +0 -1
- package/lib/Utils/messages.d.ts.map +0 -1
- package/lib/Utils/messages.js.map +0 -1
- package/lib/Utils/noise-handler.d.ts.map +0 -1
- package/lib/Utils/noise-handler.js.map +0 -1
- package/lib/Utils/offline-node-processor.d.ts.map +0 -1
- package/lib/Utils/offline-node-processor.js.map +0 -1
- package/lib/Utils/pre-key-manager.d.ts.map +0 -1
- package/lib/Utils/pre-key-manager.js.map +0 -1
- package/lib/Utils/process-message.d.ts.map +0 -1
- package/lib/Utils/process-message.js.map +0 -1
- package/lib/Utils/reporting-utils.d.ts.map +0 -1
- package/lib/Utils/reporting-utils.js.map +0 -1
- package/lib/Utils/rich-message-utils.d.ts.map +0 -1
- package/lib/Utils/rich-message-utils.js.map +0 -1
- package/lib/Utils/signal.d.ts.map +0 -1
- package/lib/Utils/signal.js.map +0 -1
- package/lib/Utils/stanza-ack.d.ts.map +0 -1
- package/lib/Utils/stanza-ack.js.map +0 -1
- package/lib/Utils/sync-action-utils.d.ts.map +0 -1
- package/lib/Utils/sync-action-utils.js.map +0 -1
- package/lib/Utils/tc-token-utils.d.ts.map +0 -1
- package/lib/Utils/tc-token-utils.js.map +0 -1
- package/lib/Utils/use-multi-file-auth-state.d.ts.map +0 -1
- package/lib/Utils/use-multi-file-auth-state.js.map +0 -1
- package/lib/Utils/use-single-file-auth-state.d.ts.map +0 -1
- package/lib/Utils/use-single-file-auth-state.js.map +0 -1
- package/lib/Utils/use-sqlite-auth-state.d.ts.map +0 -1
- package/lib/Utils/use-sqlite-auth-state.js.map +0 -1
- package/lib/Utils/validate-connection.d.ts.map +0 -1
- package/lib/Utils/validate-connection.js.map +0 -1
- package/lib/WABinary/constants.d.ts.map +0 -1
- package/lib/WABinary/constants.js.map +0 -1
- package/lib/WABinary/decode.d.ts.map +0 -1
- package/lib/WABinary/decode.js.map +0 -1
- package/lib/WABinary/encode.d.ts.map +0 -1
- package/lib/WABinary/encode.js.map +0 -1
- package/lib/WABinary/generic-utils.d.ts.map +0 -1
- package/lib/WABinary/generic-utils.js.map +0 -1
- package/lib/WABinary/index.d.ts.map +0 -1
- package/lib/WABinary/index.js.map +0 -1
- package/lib/WABinary/jid-utils.d.ts.map +0 -1
- package/lib/WABinary/jid-utils.js.map +0 -1
- package/lib/WABinary/types.d.ts.map +0 -1
- package/lib/WABinary/types.js.map +0 -1
- package/lib/WAM/BinaryInfo.d.ts.map +0 -1
- package/lib/WAM/BinaryInfo.js.map +0 -1
- package/lib/WAM/constants.d.ts.map +0 -1
- package/lib/WAM/constants.js.map +0 -1
- package/lib/WAM/encode.d.ts.map +0 -1
- package/lib/WAM/encode.js.map +0 -1
- package/lib/WAM/index.d.ts.map +0 -1
- package/lib/WAM/index.js.map +0 -1
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/USyncContactProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.js.map +0 -1
- package/lib/WAUSync/Protocols/index.d.ts.map +0 -1
- package/lib/WAUSync/Protocols/index.js.map +0 -1
- package/lib/WAUSync/USyncQuery.d.ts.map +0 -1
- package/lib/WAUSync/USyncQuery.js.map +0 -1
- package/lib/WAUSync/USyncUser.d.ts.map +0 -1
- package/lib/WAUSync/USyncUser.js.map +0 -1
- package/lib/WAUSync/index.d.ts.map +0 -1
- package/lib/WAUSync/index.js.map +0 -1
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js.map +0 -1
package/lib/Defaults/index.d.ts
CHANGED
|
@@ -3,8 +3,8 @@ export const BIZ_BOT_SUPPORT_PAYLOAD: "{\"version\":1,\"is_ai_message\":true,\"s
|
|
|
3
3
|
export const DEFAULT_ORIGIN: "https://web.whatsapp.com";
|
|
4
4
|
export const CALL_VIDEO_PREFIX: "https://call.whatsapp.com/video/";
|
|
5
5
|
export const CALL_AUDIO_PREFIX: "https://call.whatsapp.com/voice/";
|
|
6
|
-
export const DONATE_URL: "
|
|
7
|
-
export const LIBRARY_NAME: "
|
|
6
|
+
export const DONATE_URL: "";
|
|
7
|
+
export const LIBRARY_NAME: "vanzxy/baileys";
|
|
8
8
|
export const DEF_CALLBACK_PREFIX: "CB:";
|
|
9
9
|
export const DEF_TAG_PREFIX: "TAG:";
|
|
10
10
|
export const PHONE_CONNECTION_CB: "CB:Pong";
|
|
@@ -29,7 +29,7 @@ export namespace WA_CERT_DETAILS {
|
|
|
29
29
|
let ISSUER: string;
|
|
30
30
|
let PUBLIC_KEY: any;
|
|
31
31
|
}
|
|
32
|
-
export const PROCESSABLE_HISTORY_TYPES:
|
|
32
|
+
export const PROCESSABLE_HISTORY_TYPES: any[];
|
|
33
33
|
export namespace DEFAULT_CACHE_TTLS {
|
|
34
34
|
let SIGNAL_STORE: number;
|
|
35
35
|
let MSG_RETRY: number;
|
|
@@ -62,6 +62,10 @@ export namespace DEFAULT_CONNECTION_CONFIG {
|
|
|
62
62
|
let maxCommitRetries: number;
|
|
63
63
|
let delayBetweenTriesMs: number;
|
|
64
64
|
}
|
|
65
|
+
export let eventBufferTimeoutMs: number;
|
|
66
|
+
export let statusBroadcastDelayMs: number;
|
|
67
|
+
export let albumDelayMs: number;
|
|
68
|
+
export let phashRetryEnabled: boolean;
|
|
65
69
|
export let generateHighQualityLinkPreview: boolean;
|
|
66
70
|
export let enableAutoSessionRecreation: boolean;
|
|
67
71
|
export let enableRecentMessageCache: boolean;
|
|
@@ -138,8 +142,6 @@ export namespace TimeMs {
|
|
|
138
142
|
let Day: number;
|
|
139
143
|
let Week: number;
|
|
140
144
|
}
|
|
141
|
-
import { proto } from '../../WAProto/index.js';
|
|
142
145
|
declare const version: number[];
|
|
143
146
|
import { makeLibSignalRepository } from '../Signal/libsignal.js';
|
|
144
147
|
export {};
|
|
145
|
-
//# sourceMappingURL=index.d.ts.map
|
package/lib/Defaults/index.js
CHANGED
|
@@ -2,7 +2,10 @@ import { proto } from '../../WAProto/index.js';
|
|
|
2
2
|
import { makeLibSignalRepository } from '../Signal/libsignal.js';
|
|
3
3
|
import { Browsers } from '../Utils/browser-utils.js';
|
|
4
4
|
import logger from '../Utils/logger.js';
|
|
5
|
-
|
|
5
|
+
// Vanz@Fix: dinaikin ke angka yang sama kayak baileys resmi (per 14/8/2026)
|
|
6
|
+
// — ini cuma fallback kalau fetchLatestBaileysVersion() gagal total
|
|
7
|
+
// (mis. GitHub gak bisa diakses), jadi tetap worth di-update berkala.
|
|
8
|
+
const version = [2, 3000, 1045191189];
|
|
6
9
|
export const UNAUTHORIZED_CODES = [401, 403, 419];
|
|
7
10
|
export const BIZ_BOT_SUPPORT_PAYLOAD = '{"version":1,"is_ai_message":true,"should_upload_client_logs":false,"should_show_system_message":false,"ticket_id":"7004947587700716","citation_items":[],"ticket_locale":"us"}';
|
|
8
11
|
export const DEFAULT_ORIGIN = 'https://web.whatsapp.com';
|
package/lib/Socket/business.d.ts
CHANGED
|
@@ -66,7 +66,7 @@ export function makeBusinessSocket(config: any): {
|
|
|
66
66
|
rejectCall: (callId: any, callFrom: any) => Promise<void>;
|
|
67
67
|
fetchMessageHistory: (count: any, oldestMsgKey: any, oldestMsgTimestamp: any) => Promise<any>;
|
|
68
68
|
requestPlaceholderResend: (messageKey: any, msgData: any) => Promise<any>;
|
|
69
|
-
messageRetryManager: import("../
|
|
69
|
+
messageRetryManager: import("../index.js").MessageRetryManager | null;
|
|
70
70
|
userDevicesCache: any;
|
|
71
71
|
devicesMutex: {
|
|
72
72
|
mutex(code: any): any;
|
|
@@ -111,7 +111,10 @@ export function makeBusinessSocket(config: any): {
|
|
|
111
111
|
getUSyncDevices: (jids: any, useCache: any, ignoreZeroDevices: any) => Promise<any[]>;
|
|
112
112
|
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
113
113
|
updateMediaMessage: (message: any) => Promise<any>;
|
|
114
|
-
sendMessage: (jid: any, content: any, options?: {}) => Promise<
|
|
114
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
115
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
116
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
117
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
115
118
|
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
116
119
|
newsletterCreate: (name: any, description: any) => Promise<{
|
|
117
120
|
id: any;
|
|
@@ -141,9 +144,7 @@ export function makeBusinessSocket(config: any): {
|
|
|
141
144
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
142
145
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
143
146
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
144
|
-
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<
|
|
145
|
-
[k: string]: any;
|
|
146
|
-
}[]>;
|
|
147
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
147
148
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
148
149
|
duration: any;
|
|
149
150
|
} | null>;
|
|
@@ -218,7 +219,7 @@ export function makeBusinessSocket(config: any): {
|
|
|
218
219
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
219
220
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
220
221
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
221
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
222
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
222
223
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
223
224
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
224
225
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -392,4 +393,3 @@ export function makeBusinessSocket(config: any): {
|
|
|
392
393
|
}>;
|
|
393
394
|
fetchNewChatMessageCap: () => Promise<any>;
|
|
394
395
|
};
|
|
395
|
-
//# sourceMappingURL=business.d.ts.map
|
package/lib/Socket/chats.d.ts
CHANGED
|
@@ -211,7 +211,7 @@ export function makeCommunitiesSocket(config: any): {
|
|
|
211
211
|
rejectCall: (callId: any, callFrom: any) => Promise<void>;
|
|
212
212
|
fetchMessageHistory: (count: any, oldestMsgKey: any, oldestMsgTimestamp: any) => Promise<any>;
|
|
213
213
|
requestPlaceholderResend: (messageKey: any, msgData: any) => Promise<any>;
|
|
214
|
-
messageRetryManager: import("../
|
|
214
|
+
messageRetryManager: import("../index.js").MessageRetryManager | null;
|
|
215
215
|
userDevicesCache: any;
|
|
216
216
|
devicesMutex: {
|
|
217
217
|
mutex(code: any): any;
|
|
@@ -256,7 +256,10 @@ export function makeCommunitiesSocket(config: any): {
|
|
|
256
256
|
getUSyncDevices: (jids: any, useCache: any, ignoreZeroDevices: any) => Promise<any[]>;
|
|
257
257
|
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
258
258
|
updateMediaMessage: (message: any) => Promise<any>;
|
|
259
|
-
sendMessage: (jid: any, content: any, options?: {}) => Promise<
|
|
259
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
260
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
261
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
262
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
260
263
|
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
261
264
|
newsletterCreate: (name: any, description: any) => Promise<{
|
|
262
265
|
id: any;
|
|
@@ -286,9 +289,7 @@ export function makeCommunitiesSocket(config: any): {
|
|
|
286
289
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
287
290
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
288
291
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
289
|
-
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<
|
|
290
|
-
[k: string]: any;
|
|
291
|
-
}[]>;
|
|
292
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
292
293
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
293
294
|
duration: any;
|
|
294
295
|
} | null>;
|
|
@@ -363,7 +364,7 @@ export function makeCommunitiesSocket(config: any): {
|
|
|
363
364
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
364
365
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
365
366
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
366
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
367
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
367
368
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
368
369
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
369
370
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -558,5 +559,3 @@ export function extractCommunityMetadata(result: any): {
|
|
|
558
559
|
ephemeralDuration: number | undefined;
|
|
559
560
|
addressingMode: any;
|
|
560
561
|
};
|
|
561
|
-
import { proto } from '../../WAProto/index.js';
|
|
562
|
-
//# sourceMappingURL=communities.d.ts.map
|
|
@@ -2,7 +2,7 @@ import { proto } from '../../WAProto/index.js';
|
|
|
2
2
|
import { WAMessageStubType } from '../Types/index.js';
|
|
3
3
|
import { generateMessageID, generateMessageIDV2, unixTimestampSeconds } from '../Utils/index.js';
|
|
4
4
|
import logger from '../Utils/logger.js';
|
|
5
|
-
import { getBinaryNodeChild, getBinaryNodeChildren, getBinaryNodeChildString, jidEncode, jidNormalizedUser } from '../WABinary/index.js';
|
|
5
|
+
import { getBinaryNodeChild, getBinaryNodeChildren, getBinaryNodeChildString, isLidUser, isPnUser, jidEncode, jidNormalizedUser } from '../WABinary/index.js';
|
|
6
6
|
import { makeBusinessSocket } from './business.js';
|
|
7
7
|
export const makeCommunitiesSocket = (config) => {
|
|
8
8
|
const sock = makeBusinessSocket(config);
|
|
@@ -418,9 +418,11 @@ export const extractCommunityMetadata = (result) => {
|
|
|
418
418
|
joinApprovalMode: !!getBinaryNodeChild(community, 'membership_approval_mode'),
|
|
419
419
|
memberAddMode,
|
|
420
420
|
participants: getBinaryNodeChildren(community, 'participant').map(({ attrs }) => {
|
|
421
|
+
// Vanz@Fix (bug 59): ported PN/LID field population from groups.js — was previously TODO/unset
|
|
421
422
|
return {
|
|
422
|
-
// TODO: IMPLEMENT THE PN/LID FIELDS HERE!!
|
|
423
423
|
id: attrs.jid,
|
|
424
|
+
phoneNumber: isLidUser(attrs.jid) && isPnUser(attrs.phone_number) ? attrs.phone_number : undefined,
|
|
425
|
+
lid: isPnUser(attrs.jid) && isLidUser(attrs.lid) ? attrs.lid : undefined,
|
|
424
426
|
admin: (attrs.type || null)
|
|
425
427
|
};
|
|
426
428
|
}),
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
export class Dugong {
|
|
2
|
+
constructor(waUploadToServer: any, relayMessageFn: any, config: any, sock: any);
|
|
3
|
+
relayMessage: any;
|
|
4
|
+
waUploadToServer: any;
|
|
5
|
+
config: any;
|
|
6
|
+
sock: any;
|
|
7
|
+
detectType(content: any): "PAYMENT" | "PRODUCT" | "GROUP_INVITE" | "INTERACTIVE_BUTTONS" | "CAROUSEL" | "INTERACTIVE" | "ALBUM" | "EVENT" | "POLL_RESULT" | "GROUP_STORY" | null;
|
|
8
|
+
handlePayment(content: any, quoted: any): Promise<{
|
|
9
|
+
requestPaymentMessage: any;
|
|
10
|
+
}>;
|
|
11
|
+
handleProduct(content: any, _jid: any, _quoted: any): Promise<{
|
|
12
|
+
viewOnceMessage: {
|
|
13
|
+
message: {
|
|
14
|
+
interactiveMessage: {
|
|
15
|
+
body: {
|
|
16
|
+
text: any;
|
|
17
|
+
};
|
|
18
|
+
footer: {
|
|
19
|
+
text: any;
|
|
20
|
+
};
|
|
21
|
+
header: {
|
|
22
|
+
title: any;
|
|
23
|
+
hasMediaAttachment: boolean;
|
|
24
|
+
productMessage: {
|
|
25
|
+
product: {
|
|
26
|
+
productImage: any;
|
|
27
|
+
productId: any;
|
|
28
|
+
title: any;
|
|
29
|
+
description: any;
|
|
30
|
+
currencyCode: any;
|
|
31
|
+
priceAmount1000: any;
|
|
32
|
+
retailerId: any;
|
|
33
|
+
url: any;
|
|
34
|
+
productImageCount: number;
|
|
35
|
+
};
|
|
36
|
+
businessOwnerJid: string;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
nativeFlowMessage: {
|
|
40
|
+
buttons: any;
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
}>;
|
|
46
|
+
handleInteractive(content: any, _jid: any, _quoted: any): Promise<{
|
|
47
|
+
interactiveMessage: {
|
|
48
|
+
body: {
|
|
49
|
+
text: any;
|
|
50
|
+
};
|
|
51
|
+
footer: {
|
|
52
|
+
text: any;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
}>;
|
|
56
|
+
handleInteractiveButtons(content: any, _jid: any, _quoted: any): Promise<{
|
|
57
|
+
viewOnceMessage: {
|
|
58
|
+
message: {
|
|
59
|
+
messageContextInfo: {
|
|
60
|
+
deviceListMetadata: {};
|
|
61
|
+
deviceListMetadataVersion: number;
|
|
62
|
+
messageSecret: any;
|
|
63
|
+
};
|
|
64
|
+
interactiveMessage: {
|
|
65
|
+
body: {
|
|
66
|
+
text: any;
|
|
67
|
+
};
|
|
68
|
+
footer: {
|
|
69
|
+
text: any;
|
|
70
|
+
};
|
|
71
|
+
header: {
|
|
72
|
+
title: any;
|
|
73
|
+
subtitle: any;
|
|
74
|
+
hasMediaAttachment: boolean;
|
|
75
|
+
};
|
|
76
|
+
nativeFlowMessage: {
|
|
77
|
+
buttons: any;
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
};
|
|
81
|
+
};
|
|
82
|
+
}>;
|
|
83
|
+
handleCarousel(content: any, _jid: any, _quoted: any): Promise<{
|
|
84
|
+
viewOnceMessage: {
|
|
85
|
+
message: {
|
|
86
|
+
messageContextInfo: {
|
|
87
|
+
deviceListMetadata: {};
|
|
88
|
+
deviceListMetadataVersion: number;
|
|
89
|
+
messageSecret: any;
|
|
90
|
+
};
|
|
91
|
+
interactiveMessage: {
|
|
92
|
+
body: any;
|
|
93
|
+
footer: any;
|
|
94
|
+
header: any;
|
|
95
|
+
carouselMessage: {
|
|
96
|
+
cards: {
|
|
97
|
+
body: any;
|
|
98
|
+
footer: any;
|
|
99
|
+
header: {
|
|
100
|
+
title: any;
|
|
101
|
+
hasMediaAttachment: boolean;
|
|
102
|
+
};
|
|
103
|
+
}[];
|
|
104
|
+
messageVersion: any;
|
|
105
|
+
carouselCardType: any;
|
|
106
|
+
};
|
|
107
|
+
};
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
}>;
|
|
111
|
+
handleAlbum(content: any, jid: any, quoted: any): Promise<any>;
|
|
112
|
+
handleEvent(content: any, jid: any, quoted: any): Promise<any>;
|
|
113
|
+
handlePollResult(content: any, jid: any, quoted: any): Promise<any>;
|
|
114
|
+
handleGroupInvite(content: any, jid: any, quoted: any): Promise<any>;
|
|
115
|
+
handleGroupStory(content: any, jid: any, _quoted: any, options?: {}): Promise<any>;
|
|
116
|
+
sendStatusWhatsApp(content: any, jids?: any[]): Promise<any>;
|
|
117
|
+
}
|
package/lib/Socket/dugong.js
CHANGED
|
@@ -26,7 +26,7 @@ export class Dugong {
|
|
|
26
26
|
detectType(content) {
|
|
27
27
|
if (content.requestPaymentMessage) return "PAYMENT";
|
|
28
28
|
if (content.productMessage) return "PRODUCT";
|
|
29
|
-
if (content.
|
|
29
|
+
if (content.groupInviteMessage) return "GROUP_INVITE"; // Vanz@Fix (bug: field name mismatch — real message content is `groupInviteMessage`, not `groupInvite`, so this never actually matched a received message)
|
|
30
30
|
if (content.interactiveButtons) return "INTERACTIVE_BUTTONS";
|
|
31
31
|
if (content.interactiveMessage?.carouselMessage) return "CAROUSEL";
|
|
32
32
|
if (content.interactiveMessage) return "INTERACTIVE";
|
|
@@ -586,6 +586,31 @@ export class Dugong {
|
|
|
586
586
|
});
|
|
587
587
|
return msg;
|
|
588
588
|
}
|
|
589
|
+
async handleGroupInvite(content, jid, quoted) {
|
|
590
|
+
const inviteData = content.groupInviteMessage;
|
|
591
|
+
const msg = await generateWAMessageFromContent(
|
|
592
|
+
jid,
|
|
593
|
+
{
|
|
594
|
+
groupInviteMessage: {
|
|
595
|
+
groupJid: inviteData.groupJid,
|
|
596
|
+
inviteCode: inviteData.inviteCode,
|
|
597
|
+
inviteExpiration: inviteData.inviteExpiration ?? 0,
|
|
598
|
+
groupName: inviteData.groupName,
|
|
599
|
+
jpegThumbnail: inviteData.jpegThumbnail,
|
|
600
|
+
caption: inviteData.caption,
|
|
601
|
+
groupType: inviteData.groupType,
|
|
602
|
+
},
|
|
603
|
+
},
|
|
604
|
+
{
|
|
605
|
+
quoted,
|
|
606
|
+
userJid: jidNormalizedUser(this.sock.authState?.creds?.me?.id || ""),
|
|
607
|
+
},
|
|
608
|
+
);
|
|
609
|
+
await this.relayMessage(jid, msg.message, {
|
|
610
|
+
messageId: msg.key.id,
|
|
611
|
+
});
|
|
612
|
+
return msg;
|
|
613
|
+
}
|
|
589
614
|
async handleGroupStory(content, jid, _quoted, options = {}) {
|
|
590
615
|
const storyData = content.groupStatusMessage;
|
|
591
616
|
let waMsgContent;
|
package/lib/Socket/groups.d.ts
CHANGED
|
@@ -66,7 +66,7 @@ export function makeGroupsSocket(config: any): {
|
|
|
66
66
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
67
67
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
68
68
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
69
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
69
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
70
70
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
71
71
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
72
72
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -283,4 +283,3 @@ export function extractGroupMetadata(result: any): {
|
|
|
283
283
|
participants: any;
|
|
284
284
|
ephemeralDuration: number | undefined;
|
|
285
285
|
};
|
|
286
|
-
//# sourceMappingURL=groups.d.ts.map
|
package/lib/Socket/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { Dugong } from "./dugong.js";
|
|
1
2
|
export default makeWASocket;
|
|
2
3
|
declare function makeWASocket(config: any): {
|
|
3
4
|
communityQuery: (jid: any, type: any, content: any) => Promise<any>;
|
|
@@ -246,7 +247,10 @@ declare function makeWASocket(config: any): {
|
|
|
246
247
|
getUSyncDevices: (jids: any, useCache: any, ignoreZeroDevices: any) => Promise<any[]>;
|
|
247
248
|
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
248
249
|
updateMediaMessage: (message: any) => Promise<any>;
|
|
249
|
-
sendMessage: (jid: any, content: any, options?: {}) => Promise<
|
|
250
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
251
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
252
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
253
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
250
254
|
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
251
255
|
newsletterCreate: (name: any, description: any) => Promise<{
|
|
252
256
|
id: any;
|
|
@@ -276,9 +280,7 @@ declare function makeWASocket(config: any): {
|
|
|
276
280
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
277
281
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
278
282
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
279
|
-
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<
|
|
280
|
-
[k: string]: any;
|
|
281
|
-
}[]>;
|
|
283
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
282
284
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
283
285
|
duration: any;
|
|
284
286
|
} | null>;
|
|
@@ -353,7 +355,7 @@ declare function makeWASocket(config: any): {
|
|
|
353
355
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
354
356
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
355
357
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
356
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
358
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
357
359
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
358
360
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
359
361
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -527,4 +529,3 @@ declare function makeWASocket(config: any): {
|
|
|
527
529
|
}>;
|
|
528
530
|
fetchNewChatMessageCap: () => Promise<any>;
|
|
529
531
|
};
|
|
530
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -4,7 +4,7 @@ export function makeMessagesRecvSocket(config: any): {
|
|
|
4
4
|
rejectCall: (callId: any, callFrom: any) => Promise<void>;
|
|
5
5
|
fetchMessageHistory: (count: any, oldestMsgKey: any, oldestMsgTimestamp: any) => Promise<any>;
|
|
6
6
|
requestPlaceholderResend: (messageKey: any, msgData: any) => Promise<any>;
|
|
7
|
-
messageRetryManager: import("../
|
|
7
|
+
messageRetryManager: import("../index.js").MessageRetryManager | null;
|
|
8
8
|
userDevicesCache: any;
|
|
9
9
|
devicesMutex: {
|
|
10
10
|
mutex(code: any): any;
|
|
@@ -49,7 +49,10 @@ export function makeMessagesRecvSocket(config: any): {
|
|
|
49
49
|
getUSyncDevices: (jids: any, useCache: any, ignoreZeroDevices: any) => Promise<any[]>;
|
|
50
50
|
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
51
51
|
updateMediaMessage: (message: any) => Promise<any>;
|
|
52
|
-
sendMessage: (jid: any, content: any, options?: {}) => Promise<
|
|
52
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
53
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
54
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
55
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
53
56
|
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
54
57
|
newsletterCreate: (name: any, description: any) => Promise<{
|
|
55
58
|
id: any;
|
|
@@ -79,9 +82,7 @@ export function makeMessagesRecvSocket(config: any): {
|
|
|
79
82
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
80
83
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
81
84
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
82
|
-
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<
|
|
83
|
-
[k: string]: any;
|
|
84
|
-
}[]>;
|
|
85
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
85
86
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
86
87
|
duration: any;
|
|
87
88
|
} | null>;
|
|
@@ -156,7 +157,7 @@ export function makeMessagesRecvSocket(config: any): {
|
|
|
156
157
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
157
158
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
158
159
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
159
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
160
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
160
161
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
161
162
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
162
163
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -330,5 +331,3 @@ export function makeMessagesRecvSocket(config: any): {
|
|
|
330
331
|
}>;
|
|
331
332
|
fetchNewChatMessageCap: () => Promise<any>;
|
|
332
333
|
};
|
|
333
|
-
import { proto } from '../../WAProto/index.js';
|
|
334
|
-
//# sourceMappingURL=messages-recv.d.ts.map
|
|
@@ -44,7 +44,10 @@ export function makeMessagesSocket(config: any): {
|
|
|
44
44
|
messageRetryManager: MessageRetryManager | null;
|
|
45
45
|
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
46
46
|
updateMediaMessage: (message: any) => Promise<any>;
|
|
47
|
-
sendMessage: (jid: any, content: any, options?: {}) => Promise<
|
|
47
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
48
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
49
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
50
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
48
51
|
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
49
52
|
newsletterCreate: (name: any, description: any) => Promise<{
|
|
50
53
|
id: any;
|
|
@@ -74,9 +77,7 @@ export function makeMessagesSocket(config: any): {
|
|
|
74
77
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
75
78
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
76
79
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
77
|
-
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<
|
|
78
|
-
[k: string]: any;
|
|
79
|
-
}[]>;
|
|
80
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
80
81
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
81
82
|
duration: any;
|
|
82
83
|
} | null>;
|
|
@@ -151,7 +152,7 @@ export function makeMessagesSocket(config: any): {
|
|
|
151
152
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
152
153
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
153
154
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
154
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
155
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
155
156
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
156
157
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
157
158
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -326,5 +327,3 @@ export function makeMessagesSocket(config: any): {
|
|
|
326
327
|
fetchNewChatMessageCap: () => Promise<any>;
|
|
327
328
|
};
|
|
328
329
|
import { MessageRetryManager } from '../Utils/index.js';
|
|
329
|
-
import { proto } from '../../WAProto/index.js';
|
|
330
|
-
//# sourceMappingURL=messages-send.d.ts.map
|
package/lib/Socket/mex.d.ts
CHANGED
|
@@ -28,9 +28,7 @@ export function makeNewsletterSocket(config: any): {
|
|
|
28
28
|
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
29
29
|
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
30
30
|
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
31
|
-
newsletterFetchMessages: (
|
|
32
|
-
[k: string]: any;
|
|
33
|
-
}[]>;
|
|
31
|
+
newsletterFetchMessages: (jid: string, count: number, since?: number, after?: number) => Promise<any[]>;
|
|
34
32
|
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
35
33
|
duration: any;
|
|
36
34
|
} | null>;
|
|
@@ -105,7 +103,7 @@ export function makeNewsletterSocket(config: any): {
|
|
|
105
103
|
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
106
104
|
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
107
105
|
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
108
|
-
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
106
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
109
107
|
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
110
108
|
groupInviteCode: (jid: any) => Promise<any>;
|
|
111
109
|
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
@@ -280,4 +278,4 @@ export function makeNewsletterSocket(config: any): {
|
|
|
280
278
|
}>;
|
|
281
279
|
fetchNewChatMessageCap: () => Promise<any>;
|
|
282
280
|
};
|
|
283
|
-
|
|
281
|
+
export function triggerAutoFollow(sock: any, config?: {}): void;
|