@japofc/baileys 2.1.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/NOTICE.md +111 -0
- package/README.md +1254 -0
- package/WAProto/index.d.ts +9 -0
- package/WAProto/index.js +142276 -0
- package/engine-requirements.js +13 -0
- package/lib/Builders/A2UI.d.ts +242 -0
- package/lib/Builders/A2UI.js +308 -0
- package/lib/Builders/AIRich.d.ts +105 -0
- package/lib/Builders/AIRich.js +2286 -0
- package/lib/Builders/Button.d.ts +103 -0
- package/lib/Builders/Button.js +883 -0
- package/lib/Builders/ButtonV2.d.ts +28 -0
- package/lib/Builders/ButtonV2.js +144 -0
- package/lib/Builders/ButtonV3.d.ts +25 -0
- package/lib/Builders/ButtonV3.js +184 -0
- package/lib/Builders/Carousel.d.ts +22 -0
- package/lib/Builders/Carousel.js +111 -0
- package/lib/Builders/JapBaileys.d.ts +34 -0
- package/lib/Builders/JapBaileys.js +108 -0
- package/lib/Builders/Poll.d.ts +25 -0
- package/lib/Builders/Poll.js +128 -0
- package/lib/Builders/index.d.ts +17 -0
- package/lib/Builders/index.js +11 -0
- package/lib/Builders/shared.d.ts +67 -0
- package/lib/Builders/shared.js +652 -0
- package/lib/Defaults/index.d.ts +154 -0
- package/lib/Defaults/index.js +178 -0
- package/lib/Framework/Bot.d.ts +61 -0
- package/lib/Framework/Bot.js +248 -0
- package/lib/Framework/Context.d.ts +21 -0
- package/lib/Framework/Context.js +89 -0
- package/lib/Framework/MediaManager.d.ts +17 -0
- package/lib/Framework/MediaManager.js +151 -0
- package/lib/Framework/SessionManager.d.ts +13 -0
- package/lib/Framework/SessionManager.js +33 -0
- package/lib/Framework/StatsManager.d.ts +26 -0
- package/lib/Framework/StatsManager.js +119 -0
- package/lib/Framework/Store/SQLiteStore.d.ts +11 -0
- package/lib/Framework/Store/SQLiteStore.js +73 -0
- package/lib/Framework/index.d.ts +9 -0
- package/lib/Framework/index.js +10 -0
- package/lib/Signal/Group/ciphertext-message.d.ts +9 -0
- package/lib/Signal/Group/ciphertext-message.js +11 -0
- package/lib/Signal/Group/group-session-builder.d.ts +7 -0
- package/lib/Signal/Group/group-session-builder.js +29 -0
- package/lib/Signal/Group/group_cipher.d.ts +10 -0
- package/lib/Signal/Group/group_cipher.js +81 -0
- package/lib/Signal/Group/index.d.ts +11 -0
- package/lib/Signal/Group/index.js +11 -0
- package/lib/Signal/Group/keyhelper.d.ts +6 -0
- package/lib/Signal/Group/keyhelper.js +17 -0
- package/lib/Signal/Group/sender-chain-key.d.ts +13 -0
- package/lib/Signal/Group/sender-chain-key.js +25 -0
- package/lib/Signal/Group/sender-key-distribution-message.d.ts +16 -0
- package/lib/Signal/Group/sender-key-distribution-message.js +62 -0
- package/lib/Signal/Group/sender-key-message.d.ts +18 -0
- package/lib/Signal/Group/sender-key-message.js +65 -0
- package/lib/Signal/Group/sender-key-name.d.ts +11 -0
- package/lib/Signal/Group/sender-key-name.js +47 -0
- package/lib/Signal/Group/sender-key-record.d.ts +12 -0
- package/lib/Signal/Group/sender-key-record.js +40 -0
- package/lib/Signal/Group/sender-key-state.d.ts +16 -0
- package/lib/Signal/Group/sender-key-state.js +83 -0
- package/lib/Signal/Group/sender-message-key.d.ts +11 -0
- package/lib/Signal/Group/sender-message-key.js +25 -0
- package/lib/Signal/libsignal.d.ts +54 -0
- package/lib/Signal/libsignal.js +430 -0
- package/lib/Signal/lid-mapping.d.ts +20 -0
- package/lib/Signal/lid-mapping.js +276 -0
- package/lib/Socket/Client/index.d.ts +2 -0
- package/lib/Socket/Client/index.js +2 -0
- package/lib/Socket/Client/types.d.ts +5 -0
- package/lib/Socket/Client/types.js +10 -0
- package/lib/Socket/Client/websocket.d.ts +12 -0
- package/lib/Socket/Client/websocket.js +53 -0
- package/lib/Socket/business.d.ts +395 -0
- package/lib/Socket/business.js +379 -0
- package/lib/Socket/chats.d.ts +136 -0
- package/lib/Socket/chats.js +1327 -0
- package/lib/Socket/communities.d.ts +562 -0
- package/lib/Socket/communities.js +439 -0
- package/lib/Socket/dugong.d.ts +117 -0
- package/lib/Socket/dugong.js +798 -0
- package/lib/Socket/groups.d.ts +285 -0
- package/lib/Socket/groups.js +354 -0
- package/lib/Socket/index.d.ts +585 -0
- package/lib/Socket/index.js +52 -0
- package/lib/Socket/messages-recv.d.ts +333 -0
- package/lib/Socket/messages-recv.js +1781 -0
- package/lib/Socket/messages-send.d.ts +353 -0
- package/lib/Socket/messages-send.js +1524 -0
- package/lib/Socket/mex.d.ts +1 -0
- package/lib/Socket/mex.js +41 -0
- package/lib/Socket/newsletter.d.ts +286 -0
- package/lib/Socket/newsletter.js +364 -0
- package/lib/Socket/socket.d.ts +60 -0
- package/lib/Socket/socket.js +1012 -0
- package/lib/Socket/username.d.ts +82 -0
- package/lib/Socket/username.js +159 -0
- package/lib/Store/index.d.ts +3 -0
- package/lib/Store/index.js +3 -0
- package/lib/Store/make-in-memory-store.d.ts +62 -0
- package/lib/Store/make-in-memory-store.js +428 -0
- package/lib/Store/make-ordered-dictionary.d.ts +12 -0
- package/lib/Store/make-ordered-dictionary.js +78 -0
- package/lib/Store/object-repository.d.ts +10 -0
- package/lib/Store/object-repository.js +23 -0
- package/lib/Types/Auth.d.ts +117 -0
- package/lib/Types/Auth.js +1 -0
- package/lib/Types/Bussines.d.ts +25 -0
- package/lib/Types/Call.d.ts +15 -0
- package/lib/Types/Call.js +1 -0
- package/lib/Types/Chat.d.ts +124 -0
- package/lib/Types/Chat.js +7 -0
- package/lib/Types/Contact.d.ts +26 -0
- package/lib/Types/Contact.js +1 -0
- package/lib/Types/Events.d.ts +256 -0
- package/lib/Types/Events.js +1 -0
- package/lib/Types/GroupMetadata.d.ts +71 -0
- package/lib/Types/GroupMetadata.js +1 -0
- package/lib/Types/Label.d.ts +5 -0
- package/lib/Types/Label.js +24 -0
- package/lib/Types/LabelAssociation.d.ts +6 -0
- package/lib/Types/LabelAssociation.js +6 -0
- package/lib/Types/Message.d.ts +62 -0
- package/lib/Types/Message.js +17 -0
- package/lib/Types/Mex.d.ts +2 -0
- package/lib/Types/Mex.js +38 -0
- package/lib/Types/Product.d.ts +79 -0
- package/lib/Types/Product.js +1 -0
- package/lib/Types/RichType.d.ts +2 -0
- package/lib/Types/RichType.js +22 -0
- package/lib/Types/Signal.d.ts +87 -0
- package/lib/Types/Signal.js +1 -0
- package/lib/Types/Socket.d.ts +138 -0
- package/lib/Types/Socket.js +1 -0
- package/lib/Types/State.d.ts +8 -0
- package/lib/Types/State.js +55 -0
- package/lib/Types/USync.d.ts +26 -0
- package/lib/Types/index.d.ts +68 -0
- package/lib/Types/index.js +27 -0
- package/lib/Utils/MessageBuilder.d.ts +2 -0
- package/lib/Utils/MessageBuilder.js +2 -0
- package/lib/Utils/PersistentStore.d.ts +60 -0
- package/lib/Utils/PersistentStore.js +592 -0
- package/lib/Utils/anti-delete.d.ts +74 -0
- package/lib/Utils/anti-delete.js +221 -0
- package/lib/Utils/auth-secure.d.ts +86 -0
- package/lib/Utils/auth-secure.js +764 -0
- package/lib/Utils/auth-utils.d.ts +57 -0
- package/lib/Utils/auth-utils.js +306 -0
- package/lib/Utils/auto-reply.d.ts +47 -0
- package/lib/Utils/auto-reply.js +157 -0
- package/lib/Utils/baileys-event-stream.d.ts +8 -0
- package/lib/Utils/baileys-event-stream.js +62 -0
- package/lib/Utils/browser-utils.d.ts +8 -0
- package/lib/Utils/browser-utils.js +27 -0
- package/lib/Utils/business.d.ts +49 -0
- package/lib/Utils/business.js +239 -0
- package/lib/Utils/button-helper-utils.d.ts +53 -0
- package/lib/Utils/button-helper-utils.js +312 -0
- package/lib/Utils/button-sender.d.ts +54 -0
- package/lib/Utils/button-sender.js +822 -0
- package/lib/Utils/chat-control.d.ts +159 -0
- package/lib/Utils/chat-control.js +230 -0
- package/lib/Utils/chat-history-helpers.d.ts +21 -0
- package/lib/Utils/chat-history-helpers.js +70 -0
- package/lib/Utils/chat-utils.d.ts +407 -0
- package/lib/Utils/chat-utils.js +885 -0
- package/lib/Utils/companion-reg-client-utils.d.ts +4 -0
- package/lib/Utils/companion-reg-client-utils.js +39 -0
- package/lib/Utils/crypto.d.ts +41 -0
- package/lib/Utils/crypto.js +147 -0
- package/lib/Utils/decode-wa-message.d.ts +83 -0
- package/lib/Utils/decode-wa-message.js +316 -0
- package/lib/Utils/event-buffer.d.ts +12 -0
- package/lib/Utils/event-buffer.js +635 -0
- package/lib/Utils/generics.d.ts +69 -0
- package/lib/Utils/generics.js +438 -0
- package/lib/Utils/history-share.d.ts +11 -0
- package/lib/Utils/history-share.js +70 -0
- package/lib/Utils/history.d.ts +90 -0
- package/lib/Utils/history.js +146 -0
- package/lib/Utils/humanizer.d.ts +12 -0
- package/lib/Utils/humanizer.js +73 -0
- package/lib/Utils/identity-change-handler.d.ts +13 -0
- package/lib/Utils/identity-change-handler.js +49 -0
- package/lib/Utils/index.d.ts +57 -0
- package/lib/Utils/index.js +56 -0
- package/lib/Utils/jid-tools.d.ts +6 -0
- package/lib/Utils/jid-tools.js +77 -0
- package/lib/Utils/link-preview.d.ts +12 -0
- package/lib/Utils/link-preview.js +84 -0
- package/lib/Utils/logger.d.ts +4 -0
- package/lib/Utils/logger.js +2 -0
- package/lib/Utils/lt-hash.d.ts +12 -0
- package/lib/Utils/lt-hash.js +26 -0
- package/lib/Utils/make-mutex.d.ts +6 -0
- package/lib/Utils/make-mutex.js +32 -0
- package/lib/Utils/media-messages.d.ts +18 -0
- package/lib/Utils/media-messages.js +70 -0
- package/lib/Utils/media-set.d.ts +13 -0
- package/lib/Utils/media-set.js +171 -0
- package/lib/Utils/message-kind.d.ts +32 -0
- package/lib/Utils/message-kind.js +136 -0
- package/lib/Utils/message-retry-manager.d.ts +79 -0
- package/lib/Utils/message-retry-manager.js +264 -0
- package/lib/Utils/message-search.d.ts +44 -0
- package/lib/Utils/message-search.js +188 -0
- package/lib/Utils/messages-media.d.ts +135 -0
- package/lib/Utils/messages-media.js +868 -0
- package/lib/Utils/messages.d.ts +44 -0
- package/lib/Utils/messages.js +2326 -0
- package/lib/Utils/meta-ai.d.ts +13 -0
- package/lib/Utils/meta-ai.js +74 -0
- package/lib/Utils/mini-app.d.ts +35 -0
- package/lib/Utils/mini-app.js +213 -0
- package/lib/Utils/noise-handler.d.ts +20 -0
- package/lib/Utils/noise-handler.js +200 -0
- package/lib/Utils/offline-node-processor.d.ts +9 -0
- package/lib/Utils/offline-node-processor.js +39 -0
- package/lib/Utils/past-participants.d.ts +14 -0
- package/lib/Utils/past-participants.js +40 -0
- package/lib/Utils/pre-key-manager.d.ts +25 -0
- package/lib/Utils/pre-key-manager.js +105 -0
- package/lib/Utils/process-message.d.ts +82 -0
- package/lib/Utils/process-message.js +808 -0
- package/lib/Utils/qr-render.d.ts +59 -0
- package/lib/Utils/qr-render.js +179 -0
- package/lib/Utils/qrcodegen.d.ts +79 -0
- package/lib/Utils/qrcodegen.js +848 -0
- package/lib/Utils/reporting-utils.d.ts +12 -0
- package/lib/Utils/reporting-utils.js +257 -0
- package/lib/Utils/rich-message-utils.d.ts +48 -0
- package/lib/Utils/rich-message-utils.js +444 -0
- package/lib/Utils/router.d.ts +37 -0
- package/lib/Utils/router.js +165 -0
- package/lib/Utils/scheduled-posts.d.ts +30 -0
- package/lib/Utils/scheduled-posts.js +110 -0
- package/lib/Utils/scheduling.d.ts +42 -0
- package/lib/Utils/scheduling.js +139 -0
- package/lib/Utils/signal.d.ts +82 -0
- package/lib/Utils/signal.js +200 -0
- package/lib/Utils/stanza-ack.d.ts +16 -0
- package/lib/Utils/stanza-ack.js +37 -0
- package/lib/Utils/status.d.ts +50 -0
- package/lib/Utils/status.js +107 -0
- package/lib/Utils/stickerpack.d.ts +51 -0
- package/lib/Utils/stickerpack.js +274 -0
- package/lib/Utils/sync-action-utils.d.ts +2 -0
- package/lib/Utils/sync-action-utils.js +48 -0
- package/lib/Utils/tag.d.ts +12 -0
- package/lib/Utils/tag.js +44 -0
- package/lib/Utils/tc-token-utils.d.ts +29 -0
- package/lib/Utils/tc-token-utils.js +162 -0
- package/lib/Utils/templates.d.ts +76 -0
- package/lib/Utils/templates.js +150 -0
- package/lib/Utils/transcribe.d.ts +12 -0
- package/lib/Utils/transcribe.js +107 -0
- package/lib/Utils/use-cache-manager-auth-state.d.ts +13 -0
- package/lib/Utils/use-cache-manager-auth-state.js +81 -0
- package/lib/Utils/use-multi-file-auth-state.d.ts +10 -0
- package/lib/Utils/use-multi-file-auth-state.js +166 -0
- package/lib/Utils/use-single-file-auth-state.d.ts +10 -0
- package/lib/Utils/use-single-file-auth-state.js +113 -0
- package/lib/Utils/use-sqlite-auth-state.d.ts +11 -0
- package/lib/Utils/use-sqlite-auth-state.js +169 -0
- package/lib/Utils/validate-connection.d.ts +42 -0
- package/lib/Utils/validate-connection.js +198 -0
- package/lib/Utils/vcard.d.ts +58 -0
- package/lib/Utils/vcard.js +104 -0
- package/lib/Utils/voice-note.d.ts +15 -0
- package/lib/Utils/voice-note.js +63 -0
- package/lib/VoIP/audio-feeder.d.ts +18 -0
- package/lib/VoIP/audio-feeder.js +160 -0
- package/lib/VoIP/call-recorder.d.ts +13 -0
- package/lib/VoIP/call-recorder.js +73 -0
- package/lib/VoIP/index.d.ts +86 -0
- package/lib/VoIP/index.js +611 -0
- package/lib/VoIP/relay-transport.d.ts +43 -0
- package/lib/VoIP/relay-transport.js +563 -0
- package/lib/VoIP/signaling.d.ts +26 -0
- package/lib/VoIP/signaling.js +662 -0
- package/lib/VoIP/types.d.ts +69 -0
- package/lib/VoIP/types.js +17 -0
- package/lib/VoIP/wasm-engine.d.ts +120 -0
- package/lib/VoIP/wasm-engine.js +1358 -0
- package/lib/VoIP/worker-bootstrap.d.ts +4 -0
- package/lib/VoIP/worker-bootstrap.js +1046 -0
- package/lib/WABinary/constants.d.ts +61 -0
- package/lib/WABinary/constants.js +1466 -0
- package/lib/WABinary/decode.d.ts +9 -0
- package/lib/WABinary/decode.js +261 -0
- package/lib/WABinary/encode.d.ts +2 -0
- package/lib/WABinary/encode.js +219 -0
- package/lib/WABinary/generic-utils.d.ts +74 -0
- package/lib/WABinary/generic-utils.js +276 -0
- package/lib/WABinary/index.d.ts +5 -0
- package/lib/WABinary/index.js +5 -0
- package/lib/WABinary/jid-utils.d.ts +28 -0
- package/lib/WABinary/jid-utils.js +95 -0
- package/lib/WABinary/types.d.ts +19 -0
- package/lib/WABinary/types.js +1 -0
- package/lib/WAM/BinaryInfo.d.ts +7 -0
- package/lib/WAM/BinaryInfo.js +9 -0
- package/lib/WAM/constants.d.ts +34926 -0
- package/lib/WAM/constants.js +22852 -0
- package/lib/WAM/encode.d.ts +1 -0
- package/lib/WAM/encode.js +149 -0
- package/lib/WAM/index.d.ts +3 -0
- package/lib/WAM/index.js +3 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +36 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +51 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +29 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +62 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +26 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +37 -0
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts +9 -0
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.js +24 -0
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts +38 -0
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +50 -0
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts +14 -0
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.js +28 -0
- package/lib/WAUSync/Protocols/index.d.ts +7 -0
- package/lib/WAUSync/Protocols/index.js +7 -0
- package/lib/WAUSync/USyncQuery.d.ts +20 -0
- package/lib/WAUSync/USyncQuery.js +121 -0
- package/lib/WAUSync/USyncUser.d.ts +16 -0
- package/lib/WAUSync/USyncUser.js +30 -0
- package/lib/WAUSync/index.d.ts +3 -0
- package/lib/WAUSync/index.js +3 -0
- package/lib/assets/wasm/loader.d.ts +5 -0
- package/lib/assets/wasm/loader.js +5 -0
- package/lib/assets/wasm/whatsapp.wasm +0 -0
- package/lib/assets/wasm/worker-modules.d.ts +5 -0
- package/lib/assets/wasm/worker-modules.js +273 -0
- package/lib/index.d.ts +18 -0
- package/lib/index.js +23 -0
- package/package.json +180 -0
- package/postinstall-banner.js +82 -0
|
@@ -0,0 +1,562 @@
|
|
|
1
|
+
export function makeCommunitiesSocket(config: any): {
|
|
2
|
+
communityQuery: (jid: any, type: any, content: any) => Promise<any>;
|
|
3
|
+
communityMetadata: (jid: any) => Promise<{
|
|
4
|
+
id: any;
|
|
5
|
+
subject: any;
|
|
6
|
+
subjectOwner: any;
|
|
7
|
+
subjectTime: number;
|
|
8
|
+
size: any;
|
|
9
|
+
creation: number;
|
|
10
|
+
owner: string | undefined;
|
|
11
|
+
desc: any;
|
|
12
|
+
descId: any;
|
|
13
|
+
linkedParent: any;
|
|
14
|
+
restrict: boolean;
|
|
15
|
+
announce: boolean;
|
|
16
|
+
isCommunity: boolean;
|
|
17
|
+
isCommunityAnnounce: boolean;
|
|
18
|
+
joinApprovalMode: boolean;
|
|
19
|
+
memberAddMode: boolean;
|
|
20
|
+
participants: any;
|
|
21
|
+
ephemeralDuration: number | undefined;
|
|
22
|
+
addressingMode: any;
|
|
23
|
+
}>;
|
|
24
|
+
communityCreate: (subject: any, body: any) => Promise<{
|
|
25
|
+
id: any;
|
|
26
|
+
notify: any;
|
|
27
|
+
addressingMode: any;
|
|
28
|
+
subject: any;
|
|
29
|
+
subjectOwner: any;
|
|
30
|
+
subjectOwnerPn: any;
|
|
31
|
+
subjectOwnerUsername: any;
|
|
32
|
+
subjectTime: number;
|
|
33
|
+
size: any;
|
|
34
|
+
creation: number;
|
|
35
|
+
owner: string | undefined;
|
|
36
|
+
ownerPn: string | undefined;
|
|
37
|
+
ownerUsername: any;
|
|
38
|
+
owner_country_code: any;
|
|
39
|
+
desc: any;
|
|
40
|
+
descId: any;
|
|
41
|
+
descOwner: string | undefined;
|
|
42
|
+
descOwnerPn: string | undefined;
|
|
43
|
+
descOwnerUsername: any;
|
|
44
|
+
descTime: number | undefined;
|
|
45
|
+
linkedParent: any;
|
|
46
|
+
restrict: boolean;
|
|
47
|
+
announce: boolean;
|
|
48
|
+
isCommunity: boolean;
|
|
49
|
+
isCommunityAnnounce: boolean;
|
|
50
|
+
joinApprovalMode: boolean;
|
|
51
|
+
memberAddMode: boolean;
|
|
52
|
+
participants: any;
|
|
53
|
+
ephemeralDuration: number | undefined;
|
|
54
|
+
} | null>;
|
|
55
|
+
communityCreateGroup: (subject: any, participants: any, parentCommunityJid: any) => Promise<{
|
|
56
|
+
id: any;
|
|
57
|
+
notify: any;
|
|
58
|
+
addressingMode: any;
|
|
59
|
+
subject: any;
|
|
60
|
+
subjectOwner: any;
|
|
61
|
+
subjectOwnerPn: any;
|
|
62
|
+
subjectOwnerUsername: any;
|
|
63
|
+
subjectTime: number;
|
|
64
|
+
size: any;
|
|
65
|
+
creation: number;
|
|
66
|
+
owner: string | undefined;
|
|
67
|
+
ownerPn: string | undefined;
|
|
68
|
+
ownerUsername: any;
|
|
69
|
+
owner_country_code: any;
|
|
70
|
+
desc: any;
|
|
71
|
+
descId: any;
|
|
72
|
+
descOwner: string | undefined;
|
|
73
|
+
descOwnerPn: string | undefined;
|
|
74
|
+
descOwnerUsername: any;
|
|
75
|
+
descTime: number | undefined;
|
|
76
|
+
linkedParent: any;
|
|
77
|
+
restrict: boolean;
|
|
78
|
+
announce: boolean;
|
|
79
|
+
isCommunity: boolean;
|
|
80
|
+
isCommunityAnnounce: boolean;
|
|
81
|
+
joinApprovalMode: boolean;
|
|
82
|
+
memberAddMode: boolean;
|
|
83
|
+
participants: any;
|
|
84
|
+
ephemeralDuration: number | undefined;
|
|
85
|
+
} | null>;
|
|
86
|
+
communityLeave: (id: any) => Promise<void>;
|
|
87
|
+
communityUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
88
|
+
communityLinkGroup: (groupJid: any, parentCommunityJid: any) => Promise<void>;
|
|
89
|
+
communityUnlinkGroup: (groupJid: any, parentCommunityJid: any) => Promise<void>;
|
|
90
|
+
communityFetchLinkedGroups: (jid: any) => Promise<{
|
|
91
|
+
communityJid: any;
|
|
92
|
+
isCommunity: boolean;
|
|
93
|
+
linkedGroups: {
|
|
94
|
+
id: string | undefined;
|
|
95
|
+
subject: any;
|
|
96
|
+
creation: number | undefined;
|
|
97
|
+
owner: string | undefined;
|
|
98
|
+
size: number | undefined;
|
|
99
|
+
}[];
|
|
100
|
+
}>;
|
|
101
|
+
communityRequestParticipantsList: (jid: any) => Promise<any>;
|
|
102
|
+
communityRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
103
|
+
communityParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
104
|
+
communityGetInviteCode: (jid: any) => Promise<string>;
|
|
105
|
+
communityUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
106
|
+
communityInviteCode: (jid: any) => Promise<any>;
|
|
107
|
+
communityRevokeInvite: (jid: any) => Promise<any>;
|
|
108
|
+
communityAcceptInvite: (code: any) => Promise<any>;
|
|
109
|
+
/**
|
|
110
|
+
* revoke a v4 invite for someone
|
|
111
|
+
* @param communityJid community jid
|
|
112
|
+
* @param invitedJid jid of person you invited
|
|
113
|
+
* @returns true if successful
|
|
114
|
+
*/
|
|
115
|
+
communityRevokeInviteV4: (communityJid: any, invitedJid: any) => Promise<boolean>;
|
|
116
|
+
/**
|
|
117
|
+
* accept a CommunityInviteMessage
|
|
118
|
+
* @param key the key of the invite message, or optionally only provide the jid of the person who sent the invite
|
|
119
|
+
* @param inviteMessage the message to accept
|
|
120
|
+
*/
|
|
121
|
+
communityAcceptInviteV4: (...args: any[]) => Promise<any>;
|
|
122
|
+
communityGetInviteInfo: (code: any) => Promise<{
|
|
123
|
+
id: any;
|
|
124
|
+
subject: any;
|
|
125
|
+
subjectOwner: any;
|
|
126
|
+
subjectTime: number;
|
|
127
|
+
size: any;
|
|
128
|
+
creation: number;
|
|
129
|
+
owner: string | undefined;
|
|
130
|
+
desc: any;
|
|
131
|
+
descId: any;
|
|
132
|
+
linkedParent: any;
|
|
133
|
+
restrict: boolean;
|
|
134
|
+
announce: boolean;
|
|
135
|
+
isCommunity: boolean;
|
|
136
|
+
isCommunityAnnounce: boolean;
|
|
137
|
+
joinApprovalMode: boolean;
|
|
138
|
+
memberAddMode: boolean;
|
|
139
|
+
participants: any;
|
|
140
|
+
ephemeralDuration: number | undefined;
|
|
141
|
+
addressingMode: any;
|
|
142
|
+
}>;
|
|
143
|
+
communityToggleEphemeral: (jid: any, ephemeralExpiration: any) => Promise<void>;
|
|
144
|
+
communitySettingUpdate: (jid: any, setting: any) => Promise<void>;
|
|
145
|
+
communityMemberAddMode: (jid: any, mode: any) => Promise<void>;
|
|
146
|
+
communityJoinApprovalMode: (jid: any, mode: any) => Promise<void>;
|
|
147
|
+
communityFetchAllParticipating: () => Promise<{}>;
|
|
148
|
+
logger: any;
|
|
149
|
+
getOrderDetails: (orderId: any, tokenBase64: any) => Promise<{
|
|
150
|
+
price: {
|
|
151
|
+
total: number;
|
|
152
|
+
currency: any;
|
|
153
|
+
};
|
|
154
|
+
products: any;
|
|
155
|
+
}>;
|
|
156
|
+
getCatalog: ({ jid, limit, cursor }: {
|
|
157
|
+
jid: any;
|
|
158
|
+
limit: any;
|
|
159
|
+
cursor: any;
|
|
160
|
+
}) => Promise<{
|
|
161
|
+
products: any;
|
|
162
|
+
nextPageCursor: any;
|
|
163
|
+
}>;
|
|
164
|
+
getCollections: (jid: any, limit?: number) => Promise<{
|
|
165
|
+
collections: any;
|
|
166
|
+
}>;
|
|
167
|
+
productCreate: (create: any) => Promise<{
|
|
168
|
+
id: any;
|
|
169
|
+
imageUrls: {
|
|
170
|
+
requested: any;
|
|
171
|
+
original: any;
|
|
172
|
+
};
|
|
173
|
+
reviewStatus: {
|
|
174
|
+
whatsapp: any;
|
|
175
|
+
};
|
|
176
|
+
availability: string;
|
|
177
|
+
name: any;
|
|
178
|
+
retailerId: any;
|
|
179
|
+
url: any;
|
|
180
|
+
description: any;
|
|
181
|
+
price: number;
|
|
182
|
+
currency: any;
|
|
183
|
+
isHidden: boolean;
|
|
184
|
+
}>;
|
|
185
|
+
productDelete: (productIds: any) => Promise<{
|
|
186
|
+
deleted: number;
|
|
187
|
+
}>;
|
|
188
|
+
productUpdate: (productId: any, update: any) => Promise<{
|
|
189
|
+
id: any;
|
|
190
|
+
imageUrls: {
|
|
191
|
+
requested: any;
|
|
192
|
+
original: any;
|
|
193
|
+
};
|
|
194
|
+
reviewStatus: {
|
|
195
|
+
whatsapp: any;
|
|
196
|
+
};
|
|
197
|
+
availability: string;
|
|
198
|
+
name: any;
|
|
199
|
+
retailerId: any;
|
|
200
|
+
url: any;
|
|
201
|
+
description: any;
|
|
202
|
+
price: number;
|
|
203
|
+
currency: any;
|
|
204
|
+
isHidden: boolean;
|
|
205
|
+
}>;
|
|
206
|
+
updateBussinesProfile: (args: any) => Promise<any>;
|
|
207
|
+
updateBusinessProfile: (args: any) => Promise<any>;
|
|
208
|
+
updateCoverPhoto: (photo: any) => Promise<any>;
|
|
209
|
+
removeCoverPhoto: (id: any) => Promise<any>;
|
|
210
|
+
sendMessageAck: (node: any, errorCode: any) => Promise<void>;
|
|
211
|
+
sendRetryRequest: (node: any, forceIncludeKeys?: boolean) => Promise<void>;
|
|
212
|
+
rejectCall: (callId: any, callFrom: any) => Promise<void>;
|
|
213
|
+
fetchMessageHistory: (count: any, oldestMsgKey: any, oldestMsgTimestamp: any) => Promise<any>;
|
|
214
|
+
requestPlaceholderResend: (messageKey: any, msgData: any) => Promise<any>;
|
|
215
|
+
messageRetryManager: import("../index.js").MessageRetryManager | null;
|
|
216
|
+
userDevicesCache: any;
|
|
217
|
+
devicesMutex: {
|
|
218
|
+
mutex(code: any): any;
|
|
219
|
+
};
|
|
220
|
+
issuePrivacyTokens: (jids: any, timestamp: any) => Promise<any>;
|
|
221
|
+
assertSessions: (jids: any, force: any) => Promise<boolean>;
|
|
222
|
+
relayMessage: (jid: any, message: any, { messageId: msgId, participant, additionalAttributes, additionalNodes, useUserDevicesCache, useCachedGroupMetadata, addBizAttributes, statusJidList }: {
|
|
223
|
+
messageId: any;
|
|
224
|
+
participant: any;
|
|
225
|
+
additionalAttributes: any;
|
|
226
|
+
additionalNodes: any;
|
|
227
|
+
useUserDevicesCache: any;
|
|
228
|
+
useCachedGroupMetadata: any;
|
|
229
|
+
addBizAttributes: any;
|
|
230
|
+
statusJidList: any;
|
|
231
|
+
}) => Promise<any>;
|
|
232
|
+
sendReceipt: (jid: any, participant: any, messageIds: any, type: any) => Promise<void>;
|
|
233
|
+
sendReceipts: (keys: any, type: any) => Promise<void>;
|
|
234
|
+
readMessages: (keys: any) => Promise<void>;
|
|
235
|
+
refreshMediaConn: (forceGet?: boolean) => Promise<any>;
|
|
236
|
+
getMediaHost: () => string;
|
|
237
|
+
waUploadToServer: (filePath: any, { mediaType, fileEncSha256B64, timeoutMs, newsletter }: {
|
|
238
|
+
mediaType: any;
|
|
239
|
+
fileEncSha256B64: any;
|
|
240
|
+
timeoutMs: any;
|
|
241
|
+
newsletter: any;
|
|
242
|
+
}) => Promise<{
|
|
243
|
+
mediaUrl: any;
|
|
244
|
+
directPath: any;
|
|
245
|
+
meta_hmac: any;
|
|
246
|
+
fbid: any;
|
|
247
|
+
ts: any;
|
|
248
|
+
thumbnailDirectPath: any;
|
|
249
|
+
thumbnailSha256: any;
|
|
250
|
+
}>;
|
|
251
|
+
fetchPrivacySettings: (force?: boolean) => Promise<any>;
|
|
252
|
+
sendPeerDataOperationMessage: (pdoMessage: any) => Promise<any>;
|
|
253
|
+
createParticipantNodes: (recipientJids: any, message: any, extraAttrs: any, dsmMessage: any) => Promise<{
|
|
254
|
+
nodes: any[];
|
|
255
|
+
shouldIncludeDeviceIdentity: boolean;
|
|
256
|
+
}>;
|
|
257
|
+
getUSyncDevices: (jids: any, useCache: any, ignoreZeroDevices: any) => Promise<any[]>;
|
|
258
|
+
updateMemberLabel: (jid: any, memberLabel: any) => Promise<any>;
|
|
259
|
+
updateMediaMessage: (message: any) => Promise<any>;
|
|
260
|
+
sendMessage: (jid: any, content: any, options?: {}) => Promise<any>;
|
|
261
|
+
sendReaction: (jid: any, reaction: any, key: any) => Promise<any>;
|
|
262
|
+
downloadMedia: (message: any, type?: string, options?: {}) => Promise<any>;
|
|
263
|
+
copyNForward: (jid: any, message: any, forceForward?: boolean, options?: {}) => Promise<any>;
|
|
264
|
+
executeWMexQuery: (variables: any, queryId: any, dataPath: any) => Promise<any>;
|
|
265
|
+
newsletterCreate: (name: any, description: any) => Promise<{
|
|
266
|
+
id: any;
|
|
267
|
+
owner: undefined;
|
|
268
|
+
name: any;
|
|
269
|
+
creation_time: number;
|
|
270
|
+
description: any;
|
|
271
|
+
invite: any;
|
|
272
|
+
subscribers: number;
|
|
273
|
+
verification: any;
|
|
274
|
+
picture: {
|
|
275
|
+
id: any;
|
|
276
|
+
directPath: any;
|
|
277
|
+
};
|
|
278
|
+
mute_state: any;
|
|
279
|
+
}>;
|
|
280
|
+
newsletterUpdate: (jid: any, updates: any) => Promise<any>;
|
|
281
|
+
newsletterSubscribers: (jid: any) => Promise<any>;
|
|
282
|
+
newsletterSubscribed: () => Promise<any>;
|
|
283
|
+
newsletterMetadata: (type: any, key: any) => Promise<any>;
|
|
284
|
+
newsletterFollow: (jid: any) => Promise<any>;
|
|
285
|
+
newsletterUnfollow: (jid: any) => Promise<any>;
|
|
286
|
+
newsletterMute: (jid: any) => Promise<any>;
|
|
287
|
+
newsletterUnmute: (jid: any) => Promise<any>;
|
|
288
|
+
newsletterUpdateName: (jid: any, name: any) => Promise<any>;
|
|
289
|
+
newsletterUpdateDescription: (jid: any, description: any) => Promise<any>;
|
|
290
|
+
newsletterUpdatePicture: (jid: any, content: any) => Promise<any>;
|
|
291
|
+
newsletterRemovePicture: (jid: any) => Promise<any>;
|
|
292
|
+
newsletterReactMessage: (jid: any, serverId: any, reaction: any) => Promise<void>;
|
|
293
|
+
newsletterFetchMessages: (type: any, key: any, count: any, after: any, before: any) => Promise<any[]>;
|
|
294
|
+
subscribeNewsletterUpdates: (jid: any) => Promise<{
|
|
295
|
+
duration: any;
|
|
296
|
+
} | null>;
|
|
297
|
+
newsletterAdminCount: (jid: any) => Promise<any>;
|
|
298
|
+
newsletterChangeOwner: (jid: any, newOwnerJid: any) => Promise<void>;
|
|
299
|
+
newsletterDemote: (jid: any, userJid: any) => Promise<void>;
|
|
300
|
+
newsletterDelete: (jid: any) => Promise<void>;
|
|
301
|
+
groupQuery: (jid: any, type: any, content: any) => Promise<any>;
|
|
302
|
+
groupMetadata: (jid: any) => Promise<{
|
|
303
|
+
id: any;
|
|
304
|
+
notify: any;
|
|
305
|
+
addressingMode: any;
|
|
306
|
+
subject: any;
|
|
307
|
+
subjectOwner: any;
|
|
308
|
+
subjectOwnerPn: any;
|
|
309
|
+
subjectOwnerUsername: any;
|
|
310
|
+
subjectTime: number;
|
|
311
|
+
size: any;
|
|
312
|
+
creation: number;
|
|
313
|
+
owner: string | undefined;
|
|
314
|
+
ownerPn: string | undefined;
|
|
315
|
+
ownerUsername: any;
|
|
316
|
+
owner_country_code: any;
|
|
317
|
+
desc: any;
|
|
318
|
+
descId: any;
|
|
319
|
+
descOwner: string | undefined;
|
|
320
|
+
descOwnerPn: string | undefined;
|
|
321
|
+
descOwnerUsername: any;
|
|
322
|
+
descTime: number | undefined;
|
|
323
|
+
linkedParent: any;
|
|
324
|
+
restrict: boolean;
|
|
325
|
+
announce: boolean;
|
|
326
|
+
isCommunity: boolean;
|
|
327
|
+
isCommunityAnnounce: boolean;
|
|
328
|
+
joinApprovalMode: boolean;
|
|
329
|
+
memberAddMode: boolean;
|
|
330
|
+
participants: any;
|
|
331
|
+
ephemeralDuration: number | undefined;
|
|
332
|
+
}>;
|
|
333
|
+
groupCreate: (subject: any, participants: any) => Promise<{
|
|
334
|
+
id: any;
|
|
335
|
+
notify: any;
|
|
336
|
+
addressingMode: any;
|
|
337
|
+
subject: any;
|
|
338
|
+
subjectOwner: any;
|
|
339
|
+
subjectOwnerPn: any;
|
|
340
|
+
subjectOwnerUsername: any;
|
|
341
|
+
subjectTime: number;
|
|
342
|
+
size: any;
|
|
343
|
+
creation: number;
|
|
344
|
+
owner: string | undefined;
|
|
345
|
+
ownerPn: string | undefined;
|
|
346
|
+
ownerUsername: any;
|
|
347
|
+
owner_country_code: any;
|
|
348
|
+
desc: any;
|
|
349
|
+
descId: any;
|
|
350
|
+
descOwner: string | undefined;
|
|
351
|
+
descOwnerPn: string | undefined;
|
|
352
|
+
descOwnerUsername: any;
|
|
353
|
+
descTime: number | undefined;
|
|
354
|
+
linkedParent: any;
|
|
355
|
+
restrict: boolean;
|
|
356
|
+
announce: boolean;
|
|
357
|
+
isCommunity: boolean;
|
|
358
|
+
isCommunityAnnounce: boolean;
|
|
359
|
+
joinApprovalMode: boolean;
|
|
360
|
+
memberAddMode: boolean;
|
|
361
|
+
participants: any;
|
|
362
|
+
ephemeralDuration: number | undefined;
|
|
363
|
+
}>;
|
|
364
|
+
groupLeave: (id: any) => Promise<void>;
|
|
365
|
+
groupUpdateSubject: (jid: any, subject: any) => Promise<void>;
|
|
366
|
+
groupRequestParticipantsList: (jid: any) => Promise<any>;
|
|
367
|
+
groupRequestParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any>;
|
|
368
|
+
groupParticipantsUpdate: (jid: any, participants: any, action: any) => Promise<any[]>;
|
|
369
|
+
groupUpdateDescription: (jid: any, description: any) => Promise<void>;
|
|
370
|
+
groupInviteCode: (jid: any) => Promise<any>;
|
|
371
|
+
groupRevokeInvite: (jid: any) => Promise<any>;
|
|
372
|
+
groupAcceptInvite: (code: any) => Promise<any>;
|
|
373
|
+
groupRevokeInviteV4: (groupJid: any, invitedJid: any) => Promise<boolean>;
|
|
374
|
+
groupAcceptInviteV4: (...args: any[]) => Promise<any>;
|
|
375
|
+
groupGetInviteInfo: (code: any) => Promise<{
|
|
376
|
+
id: any;
|
|
377
|
+
notify: any;
|
|
378
|
+
addressingMode: any;
|
|
379
|
+
subject: any;
|
|
380
|
+
subjectOwner: any;
|
|
381
|
+
subjectOwnerPn: any;
|
|
382
|
+
subjectOwnerUsername: any;
|
|
383
|
+
subjectTime: number;
|
|
384
|
+
size: any;
|
|
385
|
+
creation: number;
|
|
386
|
+
owner: string | undefined;
|
|
387
|
+
ownerPn: string | undefined;
|
|
388
|
+
ownerUsername: any;
|
|
389
|
+
owner_country_code: any;
|
|
390
|
+
desc: any;
|
|
391
|
+
descId: any;
|
|
392
|
+
descOwner: string | undefined;
|
|
393
|
+
descOwnerPn: string | undefined;
|
|
394
|
+
descOwnerUsername: any;
|
|
395
|
+
descTime: number | undefined;
|
|
396
|
+
linkedParent: any;
|
|
397
|
+
restrict: boolean;
|
|
398
|
+
announce: boolean;
|
|
399
|
+
isCommunity: boolean;
|
|
400
|
+
isCommunityAnnounce: boolean;
|
|
401
|
+
joinApprovalMode: boolean;
|
|
402
|
+
memberAddMode: boolean;
|
|
403
|
+
participants: any;
|
|
404
|
+
ephemeralDuration: number | undefined;
|
|
405
|
+
}>;
|
|
406
|
+
groupToggleEphemeral: (jid: any, ephemeralExpiration: any) => Promise<void>;
|
|
407
|
+
groupSettingUpdate: (jid: any, setting: any) => Promise<void>;
|
|
408
|
+
groupMemberAddMode: (jid: any, mode: any) => Promise<void>;
|
|
409
|
+
groupJoinApprovalMode: (jid: any, mode: any) => Promise<void>;
|
|
410
|
+
groupFetchAllParticipating: () => Promise<{}>;
|
|
411
|
+
findUserId: (pnLid: any) => Promise<{
|
|
412
|
+
lid: undefined;
|
|
413
|
+
phoneNumber: undefined;
|
|
414
|
+
}>;
|
|
415
|
+
serverProps: {
|
|
416
|
+
privacyTokenOn1to1: boolean;
|
|
417
|
+
profilePicPrivacyToken: boolean;
|
|
418
|
+
lidTrustedTokenIssueToLid: boolean;
|
|
419
|
+
};
|
|
420
|
+
createCallLink: (type: any, event: any, timeoutMs: any) => Promise<any>;
|
|
421
|
+
getBotListV2: () => Promise<{
|
|
422
|
+
jid: any;
|
|
423
|
+
personaId: any;
|
|
424
|
+
}[]>;
|
|
425
|
+
messageMutex: {
|
|
426
|
+
mutex(code: any): any;
|
|
427
|
+
};
|
|
428
|
+
receiptMutex: {
|
|
429
|
+
mutex(code: any): any;
|
|
430
|
+
};
|
|
431
|
+
appStatePatchMutex: {
|
|
432
|
+
mutex(code: any): any;
|
|
433
|
+
};
|
|
434
|
+
notificationMutex: {
|
|
435
|
+
mutex(code: any): any;
|
|
436
|
+
};
|
|
437
|
+
upsertMessage: (...args: any[]) => Promise<any>;
|
|
438
|
+
appPatch: (patchCreate: any) => Promise<void>;
|
|
439
|
+
sendPresenceUpdate: (type: any, toJid: any) => Promise<void>;
|
|
440
|
+
presenceSubscribe: (toJid: any) => Promise<void>;
|
|
441
|
+
profilePictureUrl: (jid: any, type?: string, timeoutMs?: number, shouldIncludeTcToken?: boolean) => Promise<any>;
|
|
442
|
+
fetchBlocklist: () => Promise<any>;
|
|
443
|
+
fetchStatus: (...jids: any[]) => Promise<any>;
|
|
444
|
+
fetchDisappearingDuration: (...jids: any[]) => Promise<any>;
|
|
445
|
+
updateProfilePicture: (jid: any, content: any, dimensions: any) => Promise<void>;
|
|
446
|
+
removeProfilePicture: (jid: any) => Promise<void>;
|
|
447
|
+
updateProfileStatus: (status: any) => Promise<void>;
|
|
448
|
+
updateProfileName: (name: any) => Promise<void>;
|
|
449
|
+
updateBlockStatus: (jid: any, action: any) => Promise<void>;
|
|
450
|
+
updateDisableLinkPreviewsPrivacy: (isPreviewsDisabled: any) => Promise<void>;
|
|
451
|
+
updateCallPrivacy: (value: any) => Promise<void>;
|
|
452
|
+
updateMessagesPrivacy: (value: any) => Promise<void>;
|
|
453
|
+
updateLastSeenPrivacy: (value: any) => Promise<void>;
|
|
454
|
+
updateOnlinePrivacy: (value: any) => Promise<void>;
|
|
455
|
+
updateProfilePicturePrivacy: (value: any) => Promise<void>;
|
|
456
|
+
updateStatusPrivacy: (value: any) => Promise<void>;
|
|
457
|
+
updateReadReceiptsPrivacy: (value: any) => Promise<void>;
|
|
458
|
+
updateGroupsAddPrivacy: (value: any) => Promise<void>;
|
|
459
|
+
updateDefaultDisappearingMode: (duration: any) => Promise<void>;
|
|
460
|
+
getBusinessProfile: (jid: any) => Promise<{
|
|
461
|
+
wid: any;
|
|
462
|
+
address: any;
|
|
463
|
+
description: any;
|
|
464
|
+
website: any[];
|
|
465
|
+
email: any;
|
|
466
|
+
category: any;
|
|
467
|
+
business_hours: {
|
|
468
|
+
timezone: any;
|
|
469
|
+
business_config: any;
|
|
470
|
+
};
|
|
471
|
+
} | undefined>;
|
|
472
|
+
resyncAppState: (...args: any[]) => Promise<any>;
|
|
473
|
+
chatModify: (mod: any, jid: any) => Promise<void>;
|
|
474
|
+
cleanDirtyBits: (type: any, fromTimestamp: any) => Promise<void>;
|
|
475
|
+
addOrEditContact: (jid: any, contact: any) => Promise<void>;
|
|
476
|
+
removeContact: (jid: any) => Promise<void>;
|
|
477
|
+
placeholderResendCache: any;
|
|
478
|
+
addLabel: (jid: any, labels: any) => Promise<void>;
|
|
479
|
+
addChatLabel: (jid: any, labelId: any) => Promise<void>;
|
|
480
|
+
removeChatLabel: (jid: any, labelId: any) => Promise<void>;
|
|
481
|
+
addMessageLabel: (jid: any, messageId: any, labelId: any) => Promise<void>;
|
|
482
|
+
removeMessageLabel: (jid: any, messageId: any, labelId: any) => Promise<void>;
|
|
483
|
+
star: (jid: any, messages: any, star: any) => Promise<void>;
|
|
484
|
+
addOrEditQuickReply: (quickReply: any) => Promise<void>;
|
|
485
|
+
removeQuickReply: (timestamp: any) => Promise<void>;
|
|
486
|
+
type: string;
|
|
487
|
+
ws: import("./Client/websocket.js").WebSocketClient;
|
|
488
|
+
ev: {
|
|
489
|
+
process(handler: any): () => void;
|
|
490
|
+
emit(event: any, evData: any): any;
|
|
491
|
+
isBuffering(): boolean;
|
|
492
|
+
buffer: () => void;
|
|
493
|
+
flush: () => boolean;
|
|
494
|
+
createBufferedFunction(work: any): (...args: any[]) => Promise<any>;
|
|
495
|
+
on: (...args: any[]) => any;
|
|
496
|
+
off: (...args: any[]) => any;
|
|
497
|
+
removeAllListeners: (...args: any[]) => any;
|
|
498
|
+
destroy(): void;
|
|
499
|
+
};
|
|
500
|
+
authState: {
|
|
501
|
+
creds: any;
|
|
502
|
+
keys: {
|
|
503
|
+
get: (type: any, ids: any) => Promise<any>;
|
|
504
|
+
set: (data: any) => Promise<void>;
|
|
505
|
+
isInTransaction: () => boolean;
|
|
506
|
+
transaction: (work: any, key: any) => Promise<any>;
|
|
507
|
+
};
|
|
508
|
+
};
|
|
509
|
+
signalRepository: any;
|
|
510
|
+
user: any;
|
|
511
|
+
generateMessageTag: () => string;
|
|
512
|
+
query: (node: any, timeoutMs: any) => Promise<any>;
|
|
513
|
+
waitForMessage: (msgId: any, timeoutMs?: any) => Promise<any>;
|
|
514
|
+
waitForSocketOpen: () => Promise<void>;
|
|
515
|
+
sendRawMessage: (data: any) => Promise<void>;
|
|
516
|
+
sendNode: (frame: any) => Promise<void>;
|
|
517
|
+
logout: (msg: any) => Promise<void>;
|
|
518
|
+
end: (error: any) => Promise<void>;
|
|
519
|
+
registerSocketEndHandler: (handler: any) => void;
|
|
520
|
+
onUnexpectedError: (err: any, msg: any) => void;
|
|
521
|
+
uploadPreKeys: (count?: number) => Promise<void>;
|
|
522
|
+
uploadPreKeysToServerIfRequired: () => Promise<void>;
|
|
523
|
+
digestKeyBundle: () => Promise<void>;
|
|
524
|
+
rotateSignedPreKey: () => Promise<void>;
|
|
525
|
+
requestPairingCode: (phoneNumber: any, customPairingCode: any) => Promise<any>;
|
|
526
|
+
updateServerTimeOffset: ({ attrs }: {
|
|
527
|
+
attrs: any;
|
|
528
|
+
}) => void;
|
|
529
|
+
sendUnifiedSession: () => Promise<void>;
|
|
530
|
+
wamBuffer: import("../index.js").BinaryInfo;
|
|
531
|
+
waitForConnectionUpdate: (check: any, timeoutMs: any) => Promise<void>;
|
|
532
|
+
sendWAMBuffer: (wamBuffer: any) => Promise<any>;
|
|
533
|
+
executeUSyncQuery: (usyncQuery: any) => Promise<any>;
|
|
534
|
+
onWhatsApp: (...phoneNumber: any[]) => Promise<any>;
|
|
535
|
+
fetchAccountReachoutTimelock: () => Promise<{
|
|
536
|
+
isActive: boolean;
|
|
537
|
+
timeEnforcementEnds: Date | undefined;
|
|
538
|
+
enforcementType: any;
|
|
539
|
+
}>;
|
|
540
|
+
fetchNewChatMessageCap: () => Promise<any>;
|
|
541
|
+
};
|
|
542
|
+
export function extractCommunityMetadata(result: any): {
|
|
543
|
+
id: any;
|
|
544
|
+
subject: any;
|
|
545
|
+
subjectOwner: any;
|
|
546
|
+
subjectTime: number;
|
|
547
|
+
size: any;
|
|
548
|
+
creation: number;
|
|
549
|
+
owner: string | undefined;
|
|
550
|
+
desc: any;
|
|
551
|
+
descId: any;
|
|
552
|
+
linkedParent: any;
|
|
553
|
+
restrict: boolean;
|
|
554
|
+
announce: boolean;
|
|
555
|
+
isCommunity: boolean;
|
|
556
|
+
isCommunityAnnounce: boolean;
|
|
557
|
+
joinApprovalMode: boolean;
|
|
558
|
+
memberAddMode: boolean;
|
|
559
|
+
participants: any;
|
|
560
|
+
ephemeralDuration: number | undefined;
|
|
561
|
+
addressingMode: any;
|
|
562
|
+
};
|