@badzz88/baileys 8.4.7 → 8.5.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 +1055 -337
- package/WAProto/index.js +5 -5
- package/lib/Defaults/index.js +187 -127
- package/lib/Defaults/phonenumber-mcc.json +223 -0
- package/lib/Signal/Group/ciphertext-message.js +14 -11
- package/lib/Signal/Group/group-session-builder.js +91 -29
- package/lib/Signal/Group/group_cipher.js +88 -81
- package/lib/Signal/Group/index.js +136 -12
- package/lib/Signal/Group/keyhelper.js +70 -15
- package/lib/Signal/Group/sender-chain-key.js +31 -25
- package/lib/Signal/Group/sender-key-distribution-message.js +65 -62
- package/lib/Signal/Group/sender-key-message.js +68 -65
- package/lib/Signal/Group/sender-key-name.js +43 -41
- package/lib/Signal/Group/sender-key-record.js +43 -40
- package/lib/Signal/Group/sender-key-state.js +96 -83
- package/lib/Signal/Group/sender-message-key.js +29 -25
- package/lib/Signal/libsignal.js +483 -424
- package/lib/Signal/lid-mapping.js +261 -276
- package/lib/Socket/Client/index.js +30 -3
- package/lib/Socket/Client/types.js +12 -10
- package/lib/Socket/Client/websocket.js +61 -53
- package/lib/Socket/aigroups.js +240 -0
- package/lib/Socket/business.js +422 -379
- package/lib/Socket/chats.js +1816 -1193
- package/lib/Socket/communities.js +549 -431
- package/lib/Socket/graphql.js +656 -0
- package/lib/Socket/groups.js +764 -374
- package/lib/Socket/index.js +38 -11
- package/lib/Socket/interactive-handler.js +522 -0
- package/lib/Socket/interop.js +549 -0
- package/lib/Socket/luxu.js +6 -5
- package/lib/Socket/managed-account.js +183 -0
- package/lib/Socket/messages-recv.js +2439 -1915
- package/lib/Socket/messages-send.js +1642 -1242
- package/lib/Socket/mex.js +59 -40
- package/lib/Socket/newsletter.js +812 -249
- package/lib/Socket/privacy.js +449 -0
- package/lib/Socket/registration.js +427 -0
- package/lib/Socket/socket.js +1077 -965
- package/lib/Socket/text-router.js +83 -0
- package/lib/Socket/username.js +237 -140
- package/lib/Store/index.js +36 -10
- package/lib/Store/make-cache-manager-store.js +85 -80
- package/lib/Store/make-in-memory-store.js +591 -185
- package/lib/Store/make-ordered-dictionary.js +78 -72
- package/lib/Store/object-repository.js +25 -28
- package/lib/Types/Auth.js +38 -2
- package/lib/Types/Bussines.js +2 -2
- package/lib/Types/Call.js +2 -2
- package/lib/Types/Chat.js +4 -8
- package/lib/Types/Contact.js +2 -2
- package/lib/Types/Events.js +2 -2
- package/lib/Types/GroupMetadata.js +2 -2
- package/lib/Types/Label.js +26 -24
- package/lib/Types/LabelAssociation.js +8 -6
- package/lib/Types/Message.js +95 -11
- package/lib/Types/Mex.js +112 -37
- package/lib/Types/Newsletter.js +121 -0
- package/lib/Types/Product.js +2 -2
- package/lib/Types/Signal.js +2 -2
- package/lib/Types/Socket.js +2 -3
- package/lib/Types/State.js +70 -56
- package/lib/Types/USync.js +2 -2
- package/lib/Types/index.js +55 -26
- package/lib/Utils/auth-utils.js +292 -288
- package/lib/Utils/browser-utils.js +113 -48
- package/lib/Utils/business.js +240 -224
- package/lib/Utils/chat-utils.js +1205 -869
- package/lib/Utils/command-loader.d.ts +31 -0
- package/lib/Utils/command-loader.js +100 -0
- package/lib/Utils/companion-reg-client-utils.js +41 -34
- package/lib/Utils/consumer-application.js +107 -0
- package/lib/Utils/crypto.js +144 -107
- package/lib/Utils/curve25519-js.js +275 -0
- package/lib/Utils/decode-wa-message.js +518 -308
- package/lib/Utils/event-buffer.js +596 -611
- package/lib/Utils/generics.js +514 -354
- package/lib/Utils/group-history.js +60 -0
- package/lib/Utils/history.js +244 -134
- package/lib/Utils/identity-change-handler.js +51 -49
- package/lib/Utils/index.js +57 -23
- package/lib/Utils/jid-display-normalization.js +218 -0
- package/lib/Utils/link-preview.js +135 -77
- package/lib/Utils/logger.js +9 -3
- package/lib/Utils/lt-hash.js +37 -6
- package/lib/Utils/make-mutex.js +36 -33
- package/lib/Utils/message-composer.js +439 -233
- package/lib/Utils/message-retry-manager.js +265 -260
- package/lib/Utils/messages-media.js +855 -747
- package/lib/Utils/messages.js +2528 -884
- package/lib/Utils/meta-ai-msmsg.js +262 -0
- package/lib/Utils/native-bridge.js +82 -0
- package/lib/Utils/noise-handler.js +195 -200
- package/lib/Utils/offline-node-processor.js +35 -33
- package/lib/Utils/pre-key-manager.js +103 -102
- package/lib/Utils/process-message.js +978 -560
- package/lib/Utils/reporting-utils.js +257 -253
- package/lib/Utils/session-pool.d.ts +16 -0
- package/lib/Utils/session-pool.js +94 -0
- package/lib/Utils/signal.js +218 -195
- package/lib/Utils/stanza-ack.js +31 -29
- package/lib/Utils/sticker.d.ts +17 -0
- package/lib/Utils/sticker.js +145 -0
- package/lib/Utils/sync-action-utils.js +50 -45
- package/lib/Utils/tc-token-utils.js +137 -139
- package/lib/Utils/use-multi-file-auth-state.js +109 -109
- package/lib/Utils/validate-connection.js +218 -202
- package/lib/Utils/view-once-cache.d.ts +9 -0
- package/lib/Utils/view-once-cache.js +79 -0
- package/lib/Utils/voip-rekey.js +22 -0
- package/lib/WABinary/constants.js +1302 -1299
- package/lib/WABinary/decode.js +343 -262
- package/lib/WABinary/encode.js +12 -4
- package/lib/WABinary/generic-utils.js +223 -187
- package/lib/WABinary/index.js +33 -6
- package/lib/WABinary/jid-utils.js +351 -88
- package/lib/WABinary/types.js +2 -2
- package/lib/WAM/BinaryInfo.js +12 -9
- package/lib/WAM/constants.js +39486 -22853
- package/lib/WAM/encode.js +132 -140
- package/lib/WAM/index.js +31 -4
- package/lib/WAUSync/Protocols/USyncBotProfileProtocol.js +55 -0
- package/lib/WAUSync/Protocols/USyncBusinessProtocol.js +43 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +53 -51
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +56 -53
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +29 -26
- package/lib/WAUSync/Protocols/USyncFeatureProtocol.js +59 -0
- package/lib/WAUSync/Protocols/USyncLIDProtocol.js +31 -0
- package/lib/WAUSync/Protocols/USyncPictureProtocol.js +32 -0
- package/lib/WAUSync/Protocols/USyncSidelistProtocol.js +29 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +38 -37
- package/lib/WAUSync/Protocols/USyncTextStatusProtocol.js +38 -0
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.js +26 -24
- package/lib/WAUSync/Protocols/index.js +39 -6
- package/lib/WAUSync/USyncQuery.js +132 -97
- package/lib/WAUSync/USyncUser.js +49 -30
- package/lib/WAUSync/index.js +31 -4
- package/lib/antiban.js +4637 -0
- package/lib/index.js +48 -15
- package/package.json +55 -92
- package/lib/WAUSync/Protocols/USyncNewsletterProtocol.js +0 -263
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +0 -51
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.js +0 -29
|
@@ -1,75 +1,81 @@
|
|
|
1
|
-
|
|
2
|
-
const array = [];
|
|
3
|
-
const dict = {};
|
|
1
|
+
'use strict'
|
|
4
2
|
|
|
5
|
-
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
6
4
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
5
|
+
function makeOrderedDictionary(idGetter) {
|
|
6
|
+
const array = []
|
|
7
|
+
const dict = {}
|
|
8
|
+
const get = id => dict[id]
|
|
9
|
+
const update = item => {
|
|
10
|
+
const id = idGetter(item)
|
|
11
|
+
const idx = array.findIndex(i => idGetter(i) === id)
|
|
12
|
+
if (idx >= 0) {
|
|
13
|
+
array[idx] = item
|
|
14
|
+
dict[id] = item
|
|
15
|
+
}
|
|
16
|
+
return false
|
|
17
|
+
}
|
|
18
|
+
const upsert = (item, mode) => {
|
|
19
|
+
const id = idGetter(item)
|
|
20
|
+
if (get(id)) {
|
|
21
|
+
update(item)
|
|
22
|
+
} else {
|
|
23
|
+
if (mode === 'append') {
|
|
24
|
+
array.push(item)
|
|
25
|
+
} else {
|
|
26
|
+
array.splice(0, 0, item)
|
|
27
|
+
}
|
|
28
|
+
dict[id] = item
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
const remove = item => {
|
|
32
|
+
const id = idGetter(item)
|
|
33
|
+
const idx = array.findIndex(i => idGetter(i) === id)
|
|
34
|
+
if (idx >= 0) {
|
|
35
|
+
array.splice(idx, 1)
|
|
36
|
+
delete dict[id]
|
|
37
|
+
return true
|
|
38
|
+
}
|
|
39
|
+
return false
|
|
40
|
+
}
|
|
41
|
+
return {
|
|
42
|
+
array,
|
|
43
|
+
get,
|
|
44
|
+
upsert,
|
|
45
|
+
update,
|
|
46
|
+
remove,
|
|
47
|
+
updateAssign: (id, update) => {
|
|
48
|
+
const item = get(id)
|
|
49
|
+
if (item) {
|
|
50
|
+
Object.assign(item, update)
|
|
51
|
+
delete dict[id]
|
|
52
|
+
dict[idGetter(item)] = item
|
|
53
|
+
return true
|
|
54
|
+
}
|
|
55
|
+
return false
|
|
56
|
+
},
|
|
57
|
+
clear: () => {
|
|
58
|
+
array.splice(0, array.length)
|
|
59
|
+
for (const key of Object.keys(dict)) {
|
|
60
|
+
delete dict[key]
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
filter: contain => {
|
|
64
|
+
let i = 0
|
|
65
|
+
while (i < array.length) {
|
|
66
|
+
if (!contain(array[i])) {
|
|
67
|
+
delete dict[idGetter(array[i])]
|
|
68
|
+
array.splice(i, 1)
|
|
69
|
+
} else {
|
|
70
|
+
i += 1
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
toJSON: () => array,
|
|
75
|
+
fromJSON: newItems => {
|
|
76
|
+
array.splice(0, array.length, ...newItems)
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
16
80
|
|
|
17
|
-
|
|
18
|
-
const id = idGetter(item);
|
|
19
|
-
if (get(id)) {
|
|
20
|
-
update(item);
|
|
21
|
-
} else {
|
|
22
|
-
if (mode === 'append') array.push(item);
|
|
23
|
-
else array.unshift(item);
|
|
24
|
-
dict[id] = item;
|
|
25
|
-
}
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
const remove = (item) => {
|
|
29
|
-
const id = idGetter(item);
|
|
30
|
-
const idx = array.findIndex(i => idGetter(i) === id);
|
|
31
|
-
if (idx >= 0) {
|
|
32
|
-
array.splice(idx, 1);
|
|
33
|
-
delete dict[id];
|
|
34
|
-
return true;
|
|
35
|
-
}
|
|
36
|
-
return false;
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
return {
|
|
40
|
-
array,
|
|
41
|
-
get,
|
|
42
|
-
upsert,
|
|
43
|
-
update,
|
|
44
|
-
remove,
|
|
45
|
-
updateAssign: (id, update) => {
|
|
46
|
-
const item = get(id);
|
|
47
|
-
if (item) {
|
|
48
|
-
Object.assign(item, update);
|
|
49
|
-
delete dict[id];
|
|
50
|
-
dict[idGetter(item)] = item;
|
|
51
|
-
return true;
|
|
52
|
-
}
|
|
53
|
-
return false;
|
|
54
|
-
},
|
|
55
|
-
clear: () => {
|
|
56
|
-
array.length = 0;
|
|
57
|
-
for (const key of Object.keys(dict)) delete dict[key];
|
|
58
|
-
},
|
|
59
|
-
filter: (contain) => {
|
|
60
|
-
let i = 0;
|
|
61
|
-
while (i < array.length) {
|
|
62
|
-
if (!contain(array[i])) {
|
|
63
|
-
delete dict[idGetter(array[i])];
|
|
64
|
-
array.splice(i, 1);
|
|
65
|
-
} else {
|
|
66
|
-
i++;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
},
|
|
70
|
-
toJSON: () => array,
|
|
71
|
-
fromJSON: (newItems) => {
|
|
72
|
-
array.splice(0, array.length, ...newItems);
|
|
73
|
-
}
|
|
74
|
-
};
|
|
75
|
-
}
|
|
81
|
+
exports.makeOrderedDictionary = makeOrderedDictionary
|
|
@@ -1,32 +1,29 @@
|
|
|
1
|
-
|
|
2
|
-
constructor(entities = {}) {
|
|
3
|
-
this.entityMap = new Map(Object.entries(entities));
|
|
4
|
-
}
|
|
1
|
+
'use strict'
|
|
5
2
|
|
|
6
|
-
|
|
7
|
-
return this.entityMap.get(id);
|
|
8
|
-
}
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
9
4
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
5
|
+
class ObjectRepository {
|
|
6
|
+
constructor(entities = {}) {
|
|
7
|
+
this.entityMap = new Map(Object.entries(entities))
|
|
8
|
+
}
|
|
9
|
+
findById(id) {
|
|
10
|
+
return this.entityMap.get(id)
|
|
11
|
+
}
|
|
12
|
+
findAll() {
|
|
13
|
+
return Array.from(this.entityMap.values())
|
|
14
|
+
}
|
|
15
|
+
upsertById(id, entity) {
|
|
16
|
+
return this.entityMap.set(id, { ...entity })
|
|
17
|
+
}
|
|
18
|
+
deleteById(id) {
|
|
19
|
+
return this.entityMap.delete(id)
|
|
20
|
+
}
|
|
21
|
+
count() {
|
|
22
|
+
return this.entityMap.size
|
|
23
|
+
}
|
|
24
|
+
toJSON() {
|
|
25
|
+
return this.findAll()
|
|
26
|
+
}
|
|
30
27
|
}
|
|
31
28
|
|
|
32
|
-
|
|
29
|
+
exports.ObjectRepository = ObjectRepository
|
package/lib/Types/Auth.js
CHANGED
|
@@ -1,2 +1,38 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
|
|
4
|
+
// Factory functions for creating auth-related objects
|
|
5
|
+
function createKeyPair(publicKey, privateKey) {
|
|
6
|
+
return {
|
|
7
|
+
public: publicKey,
|
|
8
|
+
private: privateKey
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
function createSignedKeyPair(keyPair, signature, keyId, timestampS) {
|
|
13
|
+
return {
|
|
14
|
+
keyPair,
|
|
15
|
+
signature,
|
|
16
|
+
keyId,
|
|
17
|
+
timestampS
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Export type definitions (for documentation purposes)
|
|
22
|
+
exports.SignalDataTypeMap = {
|
|
23
|
+
'pre-key': 'KeyPair',
|
|
24
|
+
session: 'Uint8Array',
|
|
25
|
+
'sender-key': 'Uint8Array',
|
|
26
|
+
'sender-key-memory': 'object',
|
|
27
|
+
'app-state-sync-key': 'proto.Message.IAppStateSyncKeyData',
|
|
28
|
+
'app-state-sync-version': 'LTHashState',
|
|
29
|
+
'lid-mapping': 'string',
|
|
30
|
+
'device-list': 'Array',
|
|
31
|
+
tctoken: 'object'
|
|
32
|
+
}
|
|
33
|
+
exports.SignalDataSet = undefined
|
|
34
|
+
exports.Awaitable = undefined
|
|
35
|
+
|
|
36
|
+
// Export the factory functions
|
|
37
|
+
exports.createKeyPair = createKeyPair
|
|
38
|
+
exports.createSignedKeyPair = createSignedKeyPair
|
package/lib/Types/Bussines.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
package/lib/Types/Call.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
package/lib/Types/Chat.js
CHANGED
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
'regular_low',
|
|
6
|
-
'regular'
|
|
7
|
-
];
|
|
8
|
-
//# sourceMappingURL=Chat.js.map
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
exports.ALL_WA_PATCH_NAMES = void 0
|
|
4
|
+
exports.ALL_WA_PATCH_NAMES = ['critical_block', 'critical_unblock_low', 'regular_high', 'regular_low', 'regular']
|
package/lib/Types/Contact.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
package/lib/Types/Events.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
package/lib/Types/Label.js
CHANGED
|
@@ -1,25 +1,27 @@
|
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
exports.LabelColor = void 0
|
|
1
4
|
/** WhatsApp has 20 predefined colors */
|
|
2
|
-
|
|
3
|
-
(function (LabelColor) {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
})(LabelColor || (LabelColor = {}))
|
|
25
|
-
//# sourceMappingURL=Label.js.map
|
|
5
|
+
var LabelColor
|
|
6
|
+
;(function (LabelColor) {
|
|
7
|
+
LabelColor[(LabelColor['Color1'] = 0)] = 'Color1'
|
|
8
|
+
LabelColor[(LabelColor['Color2'] = 1)] = 'Color2'
|
|
9
|
+
LabelColor[(LabelColor['Color3'] = 2)] = 'Color3'
|
|
10
|
+
LabelColor[(LabelColor['Color4'] = 3)] = 'Color4'
|
|
11
|
+
LabelColor[(LabelColor['Color5'] = 4)] = 'Color5'
|
|
12
|
+
LabelColor[(LabelColor['Color6'] = 5)] = 'Color6'
|
|
13
|
+
LabelColor[(LabelColor['Color7'] = 6)] = 'Color7'
|
|
14
|
+
LabelColor[(LabelColor['Color8'] = 7)] = 'Color8'
|
|
15
|
+
LabelColor[(LabelColor['Color9'] = 8)] = 'Color9'
|
|
16
|
+
LabelColor[(LabelColor['Color10'] = 9)] = 'Color10'
|
|
17
|
+
LabelColor[(LabelColor['Color11'] = 10)] = 'Color11'
|
|
18
|
+
LabelColor[(LabelColor['Color12'] = 11)] = 'Color12'
|
|
19
|
+
LabelColor[(LabelColor['Color13'] = 12)] = 'Color13'
|
|
20
|
+
LabelColor[(LabelColor['Color14'] = 13)] = 'Color14'
|
|
21
|
+
LabelColor[(LabelColor['Color15'] = 14)] = 'Color15'
|
|
22
|
+
LabelColor[(LabelColor['Color16'] = 15)] = 'Color16'
|
|
23
|
+
LabelColor[(LabelColor['Color17'] = 16)] = 'Color17'
|
|
24
|
+
LabelColor[(LabelColor['Color18'] = 17)] = 'Color18'
|
|
25
|
+
LabelColor[(LabelColor['Color19'] = 18)] = 'Color19'
|
|
26
|
+
LabelColor[(LabelColor['Color20'] = 19)] = 'Color20'
|
|
27
|
+
})(LabelColor || (exports.LabelColor = LabelColor = {}))
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
exports.LabelAssociationType = void 0
|
|
1
4
|
/** Association type */
|
|
2
|
-
|
|
3
|
-
(function (LabelAssociationType) {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
})(LabelAssociationType || (LabelAssociationType = {}))
|
|
7
|
-
//# sourceMappingURL=LabelAssociation.js.map
|
|
5
|
+
var LabelAssociationType
|
|
6
|
+
;(function (LabelAssociationType) {
|
|
7
|
+
LabelAssociationType['Chat'] = 'label_jid'
|
|
8
|
+
LabelAssociationType['Message'] = 'label_message'
|
|
9
|
+
})(LabelAssociationType || (exports.LabelAssociationType = LabelAssociationType = {}))
|
package/lib/Types/Message.js
CHANGED
|
@@ -1,11 +1,95 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
exports.WAMessageAddressingMode =
|
|
4
|
+
exports.WAMessageStatus =
|
|
5
|
+
exports.WAMessageStubType =
|
|
6
|
+
exports.WAProto =
|
|
7
|
+
exports.ScheduledCallType =
|
|
8
|
+
exports.ScheduledCallEditType =
|
|
9
|
+
exports.CallLogOutcome =
|
|
10
|
+
exports.CallLogType =
|
|
11
|
+
exports.SplitPaymentStatus =
|
|
12
|
+
exports.P2PPaymentReminderFrequency =
|
|
13
|
+
exports.P2PPaymentReminderState =
|
|
14
|
+
exports.ConditionalRevealType =
|
|
15
|
+
exports.EventResponseType =
|
|
16
|
+
exports.PrivateProcessingStatus =
|
|
17
|
+
exports.PaymentInfoStatus =
|
|
18
|
+
exports.PaymentInfoTxnStatus =
|
|
19
|
+
exports.VideoQuality =
|
|
20
|
+
exports.MediaVisibility =
|
|
21
|
+
exports.HistorySyncType =
|
|
22
|
+
void 0
|
|
23
|
+
const index_js_1 = require('../../WAProto/index.js')
|
|
24
|
+
Object.defineProperty(exports, 'WAProto', {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function () {
|
|
27
|
+
return index_js_1.proto
|
|
28
|
+
}
|
|
29
|
+
})
|
|
30
|
+
exports.WAMessageStubType = index_js_1.proto.WebMessageInfo.StubType
|
|
31
|
+
exports.WAMessageStatus = index_js_1.proto.WebMessageInfo.Status
|
|
32
|
+
|
|
33
|
+
exports.ScheduledCallType = index_js_1.proto.Message.ScheduledCallCreationMessage.CallType
|
|
34
|
+
exports.ScheduledCallEditType = index_js_1.proto.Message.ScheduledCallEditMessage.EditType
|
|
35
|
+
exports.CallLogOutcome = index_js_1.proto.Message.CallLogMessage.CallOutcome
|
|
36
|
+
exports.CallLogType = index_js_1.proto.Message.CallLogMessage.CallType
|
|
37
|
+
exports.SplitPaymentStatus = index_js_1.proto.Message.SplitPaymentParticipant.SplitPaymentStatus
|
|
38
|
+
exports.P2PPaymentReminderFrequency = index_js_1.proto.Message.P2PPaymentReminderNotification?.ReminderFrequency
|
|
39
|
+
exports.P2PPaymentReminderState = index_js_1.proto.Message.P2PPaymentReminderNotification?.ReminderState
|
|
40
|
+
exports.ConditionalRevealType = index_js_1.proto.Message.ConditionalRevealMessage.ConditionalRevealMessageType
|
|
41
|
+
exports.EventResponseType = index_js_1.proto.Message.EventResponseMessage.EventResponseType
|
|
42
|
+
exports.PrivateProcessingStatus =
|
|
43
|
+
index_js_1.proto.SyncActionValue.PrivateProcessingSettingAction.PrivateProcessingStatus
|
|
44
|
+
exports.PaymentInfoStatus = index_js_1.proto.PaymentInfo.Status
|
|
45
|
+
exports.PaymentInfoTxnStatus = index_js_1.proto.PaymentInfo.TxnStatus
|
|
46
|
+
exports.VideoQuality = index_js_1.proto.ProcessedVideo.VideoQuality
|
|
47
|
+
exports.MediaVisibility = index_js_1.proto.MediaVisibility
|
|
48
|
+
exports.HistorySyncType = index_js_1.proto.HistorySync.HistorySyncType
|
|
49
|
+
exports.KeepType = index_js_1.proto.KeepType
|
|
50
|
+
exports.BotFeedbackKind = index_js_1.proto.BotFeedbackMessage.BotFeedbackKind
|
|
51
|
+
exports.CloudAPIThreadControl = index_js_1.proto.Message.CloudAPIThreadControlNotification.CloudAPIThreadControl
|
|
52
|
+
exports.MessageAddOnType = index_js_1.proto.MessageAddOn.MessageAddOnType
|
|
53
|
+
exports.ProtocolMessageType = index_js_1.proto.Message.ProtocolMessage.Type
|
|
54
|
+
exports.BCallMediaType = index_js_1.proto.Message.BCallMessage.MediaType
|
|
55
|
+
exports.SecretEncType = index_js_1.proto.Message.SecretEncryptedMessage.SecretEncType
|
|
56
|
+
exports.MediaRetryResultType = index_js_1.proto.MediaRetryNotification.ResultType
|
|
57
|
+
exports.StatusAttributionType = index_js_1.proto.StatusAttribution.Type
|
|
58
|
+
exports.ForwardOrigin = index_js_1.proto.ContextInfo.ForwardOrigin
|
|
59
|
+
exports.StatusAudienceType = index_js_1.proto.ContextInfo.StatusAudienceMetadata.AudienceType
|
|
60
|
+
exports.VideoSourceType = index_js_1.proto.Message.VideoMessage.VideoSourceType
|
|
61
|
+
exports.PollType = index_js_1.proto.Message.PollType
|
|
62
|
+
exports.BotCapabilityType = index_js_1.proto.BotCapabilityMetadata.BotCapabilityType
|
|
63
|
+
exports.AssociationType = index_js_1.proto.MessageAssociation.AssociationType
|
|
64
|
+
exports.ThreadType = index_js_1.proto.ThreadID.ThreadType
|
|
65
|
+
exports.CarouselCardType = index_js_1.proto.Message.InteractiveMessage.CarouselMessage.CarouselCardType
|
|
66
|
+
exports.ImageSourceType = index_js_1.proto.Message.ImageMessage.ImageSourceType
|
|
67
|
+
exports.BotSessionSource = index_js_1.proto.BotSessionSource
|
|
68
|
+
exports.BotReminderAction = index_js_1.proto.BotReminderMetadata.ReminderAction
|
|
69
|
+
exports.BotReminderFrequency = index_js_1.proto.BotReminderMetadata.ReminderFrequency
|
|
70
|
+
exports.BotPluginType = index_js_1.proto.BotPluginMetadata.PluginType
|
|
71
|
+
exports.BotPluginSearchProvider = index_js_1.proto.BotPluginMetadata.SearchProvider
|
|
72
|
+
exports.BizInteractionPillType = index_js_1.proto.ContextInfo.BusinessInteractionPills.PillType
|
|
73
|
+
exports.PeerDataOperationRequestType = index_js_1.proto.Message.PeerDataOperationRequestType
|
|
74
|
+
exports.SocialMediaPostType = index_js_1.proto.Message.LinkPreviewMetadata.SocialMediaPostType
|
|
75
|
+
exports.AIRichResponseMessageType = index_js_1.proto.AIRichResponseMessageType
|
|
76
|
+
exports.AIRichResponseSubMessageType = index_js_1.proto.AIRichResponseSubMessageType
|
|
77
|
+
exports.AISubscriptionRequestType = index_js_1.proto.AISubscriptionRequestType
|
|
78
|
+
exports.BotMetricsEntryPoint = index_js_1.proto.BotMetricsEntryPoint
|
|
79
|
+
exports.BotMetricsThreadEntryPoint = index_js_1.proto.BotMetricsThreadEntryPoint
|
|
80
|
+
exports.MediaKeyDomain = index_js_1.proto.MediaKeyDomain
|
|
81
|
+
exports.SessionTransparencyType = index_js_1.proto.SessionTransparencyType
|
|
82
|
+
exports.ADVEncryptionType = index_js_1.proto.ADVEncryptionType
|
|
83
|
+
exports.PlaceholderMessageType = index_js_1.proto.Message.PlaceholderMessage.PlaceholderType
|
|
84
|
+
exports.SecretEncEncType = index_js_1.proto.Message.SecretEncryptedMessage.SecretEncType
|
|
85
|
+
exports.ImageMessageSourceType = index_js_1.proto.Message.ImageMessage.ImageSourceType
|
|
86
|
+
exports.VideoMessageSourceType = index_js_1.proto.Message.VideoMessage.VideoSourceType
|
|
87
|
+
exports.NativeFlowActionType =
|
|
88
|
+
index_js_1.proto.Message.InteractiveResponseMessage?.NativeFlowResponseMessage?.NativeFlowActionType
|
|
89
|
+
exports.InteractiveAnnotationType = index_js_1.proto.HydratedAnnotatedBotMessage?.HydratedAnnotatedMessageType
|
|
90
|
+
|
|
91
|
+
var WAMessageAddressingMode
|
|
92
|
+
;(function (WAMessageAddressingMode) {
|
|
93
|
+
WAMessageAddressingMode['PN'] = 'pn'
|
|
94
|
+
WAMessageAddressingMode['LID'] = 'lid'
|
|
95
|
+
})(WAMessageAddressingMode || (exports.WAMessageAddressingMode = WAMessageAddressingMode = {}))
|
package/lib/Types/Mex.js
CHANGED
|
@@ -1,37 +1,112 @@
|
|
|
1
|
-
|
|
2
|
-
(
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
1
|
+
'use strict'
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true })
|
|
3
|
+
exports.QueryIds = exports.XWAPaths = void 0
|
|
4
|
+
var XWAPaths
|
|
5
|
+
;(function (XWAPaths) {
|
|
6
|
+
XWAPaths['xwa2_newsletter_create'] = 'xwa2_newsletter_create'
|
|
7
|
+
XWAPaths['xwa2_newsletter_subscribers'] = 'xwa2_newsletter_subscribers'
|
|
8
|
+
XWAPaths['xwa2_newsletter_view'] = 'xwa2_newsletter_view'
|
|
9
|
+
XWAPaths['xwa2_newsletter_metadata'] = 'xwa2_newsletter'
|
|
10
|
+
XWAPaths['xwa2_newsletter_admin_count'] = 'xwa2_newsletter_admin'
|
|
11
|
+
XWAPaths['xwa2_newsletter_mute_v2'] = 'xwa2_newsletter_mute_v2'
|
|
12
|
+
XWAPaths['xwa2_newsletter_unmute_v2'] = 'xwa2_newsletter_unmute_v2'
|
|
13
|
+
XWAPaths['xwa2_newsletter_follow'] = 'xwa2_newsletter_follow'
|
|
14
|
+
XWAPaths['xwa2_newsletter_unfollow'] = 'xwa2_newsletter_unfollow'
|
|
15
|
+
XWAPaths['xwa2_newsletter_join_v2'] = 'xwa2_newsletter_join_v2'
|
|
16
|
+
XWAPaths['xwa2_newsletter_leave_v2'] = 'xwa2_newsletter_leave_v2'
|
|
17
|
+
XWAPaths['xwa2_newsletter_change_owner'] = 'xwa2_newsletter_change_owner'
|
|
18
|
+
XWAPaths['xwa2_newsletter_demote'] = 'xwa2_newsletter_demote'
|
|
19
|
+
XWAPaths['xwa2_newsletter_delete_v2'] = 'xwa2_newsletter_delete_v2'
|
|
20
|
+
XWAPaths['xwa2_fetch_account_reachout_timelock'] = 'xwa2_fetch_account_reachout_timelock'
|
|
21
|
+
XWAPaths['xwa2_message_capping_info'] = 'xwa2_message_capping_info'
|
|
22
|
+
XWAPaths['xwa2_newsletter_subscribed'] = 'xwa2_newsletter_subscribed'
|
|
23
|
+
XWAPaths['xwa2_newsletter_update'] = 'xwa2_newsletter_update'
|
|
24
|
+
XWAPaths['xwa2_newsletter_admin'] = 'xwa2_newsletter_admin'
|
|
25
|
+
XWAPaths['xwa2_newsletter_admin_invite_create'] = 'xwa2_newsletter_admin_invite_create'
|
|
26
|
+
XWAPaths['xwa2_newsletter_admin_invite_revoke'] = 'xwa2_newsletter_admin_invite_revoke'
|
|
27
|
+
XWAPaths['xwa2_newsletter_admin_invite_accept'] = 'xwa2_newsletter_admin_invite_accept'
|
|
28
|
+
XWAPaths['xwa2_newsletter_admin_profile_update'] = 'xwa2_newsletter_admin_profile_update'
|
|
29
|
+
XWAPaths['xwa2_newsletter_admin_insights'] = 'xwa2_newsletter_admin_insights'
|
|
30
|
+
XWAPaths['xwa2_newsletter_following'] = 'xwa2_newsletter_following'
|
|
31
|
+
XWAPaths['xwa2_newsletter_create_verified'] = 'xwa2_newsletter_create_verified'
|
|
32
|
+
XWAPaths['xwa2_newsletter_enforcements'] = 'xwa2_newsletter_enforcements'
|
|
33
|
+
XWAPaths['xwa2_newsletter_user_reports'] = 'xwa2_newsletter_user_reports'
|
|
34
|
+
XWAPaths['xwa2_newsletter_create_report_appeal'] = 'xwa2_newsletter_create_report_appeal'
|
|
35
|
+
XWAPaths['xwa2_newsletter_link_preview_check'] = 'xwa2_newsletter_link_preview_check'
|
|
36
|
+
XWAPaths['xwa2_newsletter_update_verification'] = 'xwa2_newsletter_update_verification'
|
|
37
|
+
XWAPaths['xwa2_newsletter_label_paid_partnership'] = 'xwa2_newsletter_label_paid_partnership'
|
|
38
|
+
XWAPaths['xwa2_newsletter_log_exposures'] = 'xwa2_newsletter_log_exposures'
|
|
39
|
+
XWAPaths['xwa2_newsletter_update_user_setting'] = 'xwa2_newsletter_update_user_setting'
|
|
40
|
+
XWAPaths['xwa2_newsletter_ranking_features'] = 'xwa2_newsletter_ranking_features'
|
|
41
|
+
XWAPaths['xwa2_newsletter_block_user'] = 'xwa2_newsletter_block_user'
|
|
42
|
+
XWAPaths['xwa2_newsletters_directory_list'] = 'xwa2_newsletters_directory_list'
|
|
43
|
+
XWAPaths['xwa2_newsletters_directory_search'] = 'xwa2_newsletters_directory_search'
|
|
44
|
+
XWAPaths['xwa2_newsletters_directory_category_preview'] = 'xwa2_newsletters_directory_category_preview'
|
|
45
|
+
XWAPaths['xwa2_newsletters_search'] = 'xwa2_newsletters_search'
|
|
46
|
+
XWAPaths['xwa2_newsletters_recommended'] = 'xwa2_newsletters_recommended'
|
|
47
|
+
XWAPaths['xwa2_newsletters_similar'] = 'xwa2_newsletters_similar'
|
|
48
|
+
XWAPaths['xwa2_newsletters_poll_voter_list'] = 'xwa2_newsletters_poll_voter_list'
|
|
49
|
+
XWAPaths['xwa2_newsletters_reaction_sender_list'] = 'xwa2_newsletters_reaction_sender_list'
|
|
50
|
+
XWAPaths['xwa2_wamo_afs_age_collection'] = 'xwa2_wamo_afs_age_collection'
|
|
51
|
+
XWAPaths['xwa2_wamo_asset_collection'] = 'xwa2_wamo_asset_collection'
|
|
52
|
+
XWAPaths['xwa2_wamo_fetch_adhoc_notice_by_id'] = 'xwa2_wamo_fetch_adhoc_notice_by_id'
|
|
53
|
+
XWAPaths['xwa2_wamo_fetch_identity_token'] = 'xwa2_wamo_fetch_identity_token'
|
|
54
|
+
XWAPaths['xwa2_wamo_sub_get_compliance_info'] = 'xwa2_wamo_sub_get_compliance_info'
|
|
55
|
+
XWAPaths['xwa2_wamo_user_id_version'] = 'xwa2_wamo_user_id_version'
|
|
56
|
+
XWAPaths['xwa2_wamo_set_user_id_version'] = 'xwa2_wamo_set_user_id_version'
|
|
57
|
+
})((XWAPaths = exports.XWAPaths || (exports.XWAPaths = {})))
|
|
58
|
+
var QueryIds
|
|
59
|
+
;(function (QueryIds) {
|
|
60
|
+
QueryIds['CREATE'] = '8823471724422422'
|
|
61
|
+
QueryIds['METADATA'] = '26099060629688646'
|
|
62
|
+
QueryIds['UPDATE_METADATA'] = '25976052865358570'
|
|
63
|
+
QueryIds['SUBSCRIBERS'] = '9783111038412085'
|
|
64
|
+
QueryIds['FOLLOW'] = '24404358912487870'
|
|
65
|
+
QueryIds['UNFOLLOW'] = '9767147403369991'
|
|
66
|
+
QueryIds['MUTE'] = '29766401636284406'
|
|
67
|
+
QueryIds['UNMUTE'] = '9864994326891137'
|
|
68
|
+
QueryIds['ADMIN_COUNT'] = '7130823597031706'
|
|
69
|
+
QueryIds['CHANGE_OWNER'] = '7341777602580933'
|
|
70
|
+
QueryIds['DEMOTE'] = '6551828931592903'
|
|
71
|
+
QueryIds['DELETE'] = '30062808666639665'
|
|
72
|
+
QueryIds['REACHOUT_TIMELOCK'] = '23983697327930364'
|
|
73
|
+
QueryIds['MESSAGE_CAPPING_INFO'] = '24503548349331633'
|
|
74
|
+
QueryIds['FETCH_SUBSCRIBE'] = '6388546374527196'
|
|
75
|
+
QueryIds['LEAVE'] = '9784043202933196'
|
|
76
|
+
QueryIds['ADMIN_INVITE'] = '7148599488585196'
|
|
77
|
+
QueryIds['ADMIN_INVITE_REVOKE'] = '6345824195482235'
|
|
78
|
+
QueryIds['ADMIN_INVITE_ACCEPT'] = '6345824195482236'
|
|
79
|
+
QueryIds['ADMIN_METADATA'] = '6895563180530100'
|
|
80
|
+
QueryIds['ADMIN_PROFILE_UPDATE'] = '6895563180530101'
|
|
81
|
+
QueryIds['INSIGHTS'] = '6243647912368353'
|
|
82
|
+
QueryIds['FOLLOWING_LIST'] = '6388546374527197'
|
|
83
|
+
QueryIds['CREATE_VERIFIED'] = '8823471724422423'
|
|
84
|
+
QueryIds['ENFORCEMENTS'] = '7130823597031707'
|
|
85
|
+
QueryIds['USER_REPORTS'] = '9783111038412086'
|
|
86
|
+
QueryIds['CREATE_REPORT_APPEAL'] = '6551828931592904'
|
|
87
|
+
QueryIds['LINK_PREVIEW_CHECK'] = '24404358912487871'
|
|
88
|
+
QueryIds['UPDATE_VERIFICATION'] = '25976052865358571'
|
|
89
|
+
QueryIds['LABEL_PAID_PARTNERSHIP'] = '7341777602580934'
|
|
90
|
+
QueryIds['LOG_EXPOSURES'] = '9864994326891138'
|
|
91
|
+
QueryIds['UPDATE_USER_SETTING'] = '29766401636284407'
|
|
92
|
+
QueryIds['RANKING_FEATURES'] = '7130823597031708'
|
|
93
|
+
QueryIds['BLOCK_USER'] = '6345824195482237'
|
|
94
|
+
QueryIds['DIRECTORY_LIST'] = '6388546374527198'
|
|
95
|
+
QueryIds['DIRECTORY_SEARCH'] = '6388546374527199'
|
|
96
|
+
QueryIds['DIRECTORY_CATEGORY_PREVIEW'] = '6388546374527200'
|
|
97
|
+
QueryIds['SEARCH'] = '26099060629688647'
|
|
98
|
+
QueryIds['RECOMMENDED'] = '26099060629688648'
|
|
99
|
+
QueryIds['SIMILAR'] = '26099060629688649'
|
|
100
|
+
QueryIds['POLL_VOTER_LIST'] = '9783111038412087'
|
|
101
|
+
QueryIds['REACTION_SENDERS_LIST'] = '9783111038412088'
|
|
102
|
+
QueryIds['WAMO_ENABLE_SUB'] = '7148599488585197'
|
|
103
|
+
QueryIds['WAMO_DISABLE_SUB'] = '7148599488585198'
|
|
104
|
+
QueryIds['WAMO_CHANGE_SUB'] = '7148599488585199'
|
|
105
|
+
QueryIds['WAMO_AFS_AGE_COLLECTION'] = '6895563180530102'
|
|
106
|
+
QueryIds['WAMO_ASSET_COLLECTION'] = '6895563180530103'
|
|
107
|
+
QueryIds['WAMO_FETCH_ADHOC_NOTICE'] = '6895563180530104'
|
|
108
|
+
QueryIds['WAMO_FETCH_IDENTITY_TOKEN'] = '6895563180530105'
|
|
109
|
+
QueryIds['WAMO_SUB_COMPLIANCE_INFO'] = '6895563180530106'
|
|
110
|
+
QueryIds['WAMO_USER_ID_VERSION'] = '6895563180530107'
|
|
111
|
+
QueryIds['WAMO_SET_USER_ID_VERSION'] = '6895563180530108'
|
|
112
|
+
})((QueryIds = exports.QueryIds || (exports.QueryIds = {})))
|