sanka-baileyss 2.3.2 → 2.3.3
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/WAProto/BotMetadata/BotMetadata.d.ts +594 -1
- package/WAProto/BotMetadata/BotMetadata.js +1910 -148
- package/WAProto/BotMetadata/BotMetadata.proto +36 -0
- package/WAProto/E2E/E2E.d.ts +570 -6
- package/WAProto/E2E/E2E.js +1591 -26
- package/WAProto/E2E/E2E.proto +10 -1
- package/WAProto/HistorySync/HistorySync.d.ts +806 -6
- package/WAProto/HistorySync/HistorySync.js +2193 -29
- package/WAProto/HistorySync/HistorySync.proto +2 -1
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.d.ts +570 -6
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.js +1591 -26
- package/WAProto/StatusAttributions/StatusAttributions.d.ts +2 -1
- package/WAProto/StatusAttributions/StatusAttributions.js +7 -0
- package/WAProto/StatusAttributions/StatusAttributions.proto +1 -0
- package/WAProto/SyncAction/SyncAction.d.ts +230 -0
- package/WAProto/SyncAction/SyncAction.js +578 -2
- package/WAProto/SyncAction/SyncAction.proto +13 -1
- package/WAProto/Web/Web.d.ts +570 -6
- package/WAProto/Web/Web.js +1591 -26
- package/lib/Defaults/baileys-version.json +2 -2
- package/lib/Defaults/index.d.ts +42 -25
- package/lib/Defaults/index.js +6 -2
- package/lib/Signal/libsignal.d.ts +1 -0
- package/lib/Socket/Client/index.js +13 -9
- package/lib/Socket/Client/types.d.ts +11 -10
- package/lib/Socket/Client/types.js +11 -7
- package/lib/Socket/Client/websocket.d.ts +9 -8
- package/lib/Socket/Client/websocket.js +52 -47
- package/lib/Socket/business.d.ts +185 -182
- package/lib/Socket/business.js +258 -249
- package/lib/Socket/chats.d.ts +90 -87
- package/lib/Socket/chats.js +1095 -888
- package/lib/Socket/community.d.ts +131 -0
- package/lib/Socket/community.js +369 -0
- package/lib/Socket/groups.d.ts +50 -41
- package/lib/Socket/groups.js +10 -3
- package/lib/Socket/index.d.ts +5 -1
- package/lib/Socket/index.js +19 -5
- package/lib/Socket/messages-recv.d.ts +6 -2
- package/lib/Socket/messages-recv.js +31 -8
- package/lib/Socket/messages-send.d.ts +5 -1
- package/lib/Socket/messages-send.js +1293 -1351
- package/lib/Socket/newsletter.d.ts +142 -135
- package/lib/Socket/newsletter.js +274 -230
- package/lib/Socket/socket.d.ts +37 -35
- package/lib/Socket/usync.d.ts +31 -30
- package/lib/Socket/usync.js +74 -62
- package/lib/Types/Auth.d.ts +89 -72
- package/lib/Types/Auth.js +1 -0
- package/lib/Types/Call.d.ts +11 -10
- package/lib/Types/Call.js +1 -0
- package/lib/Types/Chat.d.ts +85 -62
- package/lib/Types/Chat.js +4 -1
- package/lib/Types/Contact.js +1 -0
- package/lib/Types/Events.d.ts +209 -191
- package/lib/Types/Events.js +1 -0
- package/lib/Types/GroupMetadata.d.ts +12 -27
- package/lib/Types/GroupMetadata.js +1 -0
- package/lib/Types/Label.d.ts +41 -39
- package/lib/Types/Label.js +24 -21
- package/lib/Types/LabelAssociation.d.ts +18 -12
- package/lib/Types/LabelAssociation.js +6 -3
- package/lib/Types/Message.d.ts +3 -2
- package/lib/Types/Message.js +7 -3
- package/lib/Types/MexUpdates.d.ts +9 -0
- package/lib/Types/MexUpdates.js +18 -0
- package/lib/Types/Newsletter.d.ts +84 -67
- package/lib/Types/Newsletter.js +30 -23
- package/lib/Types/Product.d.ts +70 -56
- package/lib/Types/Product.js +1 -0
- package/lib/Types/Signal.d.ts +46 -35
- package/lib/Types/Signal.js +1 -0
- package/lib/Types/Socket.d.ts +105 -101
- package/lib/Types/Socket.js +1 -0
- package/lib/Types/State.d.ts +37 -23
- package/lib/Types/State.js +13 -1
- package/lib/Types/USync.d.ts +21 -20
- package/lib/Types/USync.js +1 -0
- package/lib/Types/index.d.ts +51 -42
- package/lib/Types/index.js +25 -19
- package/lib/Utils/auth-utils.d.ts +14 -11
- package/lib/Utils/auth-utils.js +189 -182
- package/lib/Utils/baileys-event-stream.d.ts +12 -10
- package/lib/Utils/baileys-event-stream.js +52 -46
- package/lib/Utils/business.d.ts +15 -8
- package/lib/Utils/business.js +229 -217
- package/lib/Utils/chat-utils.d.ts +22 -12
- package/lib/Utils/chat-utils.js +57 -27
- package/lib/Utils/crypto.d.ts +31 -15
- package/lib/Utils/crypto.js +136 -107
- package/lib/Utils/decode-wa-message.d.ts +34 -245
- package/lib/Utils/decode-wa-message.js +205 -217
- package/lib/Utils/event-buffer.d.ts +30 -26
- package/lib/Utils/event-buffer.js +519 -515
- package/lib/Utils/history.d.ts +2 -8
- package/lib/Utils/index.js +13 -9
- package/lib/Utils/link-preview.d.ts +16 -14
- package/lib/Utils/link-preview.js +100 -92
- package/lib/Utils/logger.d.ts +9 -7
- package/lib/Utils/logger.js +1 -1
- package/lib/Utils/lt-hash.d.ts +10 -8
- package/lib/Utils/lt-hash.js +49 -44
- package/lib/Utils/make-mutex.d.ts +4 -2
- package/lib/Utils/make-mutex.js +43 -39
- package/lib/Utils/messages-media.d.ts +75 -50
- package/lib/Utils/messages.d.ts +60 -35
- package/lib/Utils/messages.js +87 -8
- package/lib/Utils/noise-handler.d.ts +13 -12
- package/lib/Utils/noise-handler.js +143 -138
- package/lib/Utils/process-message.d.ts +32 -24
- package/lib/Utils/process-message.js +387 -367
- package/lib/Utils/signal.d.ts +24 -15
- package/lib/Utils/signal.js +143 -131
- package/lib/Utils/use-mongo-file-auth-state.d.ts +3 -2
- package/lib/Utils/use-mongo-file-auth-state.js +72 -63
- package/lib/Utils/use-multi-file-auth-state.d.ts +9 -8
- package/lib/Utils/use-multi-file-auth-state.js +110 -102
- package/lib/Utils/use-single-file-auth-state.d.ts +8 -7
- package/lib/Utils/use-single-file-auth-state.js +66 -61
- package/lib/Utils/validate-connection.d.ts +5 -2
- package/lib/Utils/validate-connection.js +7 -6
- package/lib/WABinary/constants.d.ts +24 -21
- package/lib/WABinary/constants.js +1302 -31
- package/lib/WABinary/decode.d.ts +4 -1
- package/lib/WABinary/decode.js +267 -234
- package/lib/WABinary/encode.d.ts +1 -0
- package/lib/WABinary/encode.js +248 -226
- package/lib/WABinary/generic-utils.d.ts +13 -1
- package/lib/WABinary/generic-utils.js +113 -96
- package/lib/WABinary/index.js +13 -9
- package/lib/WABinary/jid-utils.d.ts +23 -4
- package/lib/WABinary/jid-utils.js +58 -39
- package/lib/WABinary/types.d.ts +15 -11
- package/lib/WABinary/types.js +1 -0
- package/lib/WAM/BinaryInfo.d.ts +14 -14
- package/lib/WAM/BinaryInfo.js +11 -8
- package/lib/WAM/constants.d.ts +34 -26
- package/lib/WAM/constants.js +15358 -15349
- package/lib/WAM/encode.d.ts +1 -0
- package/lib/WAM/encode.js +153 -144
- package/lib/WAM/index.js +13 -9
- package/lib/index.js +11 -11
- package/package.json +1 -2
- package/WASignalGroup/GroupProtocol.js +0 -1771
- package/WASignalGroup/ciphertext_message.js +0 -10
- package/WASignalGroup/group_cipher.js +0 -103
- package/WASignalGroup/group_session_builder.js +0 -39
- package/WASignalGroup/index.js +0 -5
- package/WASignalGroup/keyhelper.js +0 -17
- package/WASignalGroup/protobufs.js +0 -2
- package/WASignalGroup/queue_job.js +0 -64
- package/WASignalGroup/sender_chain_key.js +0 -38
- package/WASignalGroup/sender_key_distribution_message.js +0 -68
- package/WASignalGroup/sender_key_message.js +0 -79
- package/WASignalGroup/sender_key_name.js +0 -59
- package/WASignalGroup/sender_key_record.js +0 -47
- package/WASignalGroup/sender_key_state.js +0 -110
- package/WASignalGroup/sender_message_key.js +0 -30
package/lib/Socket/business.d.ts
CHANGED
|
@@ -1,183 +1,186 @@
|
|
|
1
|
-
import { GetCatalogOptions, ProductCreate, ProductUpdate, SocketConfig } from '../Types'
|
|
2
|
-
import { BinaryNode } from '../WABinary'
|
|
3
|
-
|
|
4
|
-
export declare const makeBusinessSocket: (config: SocketConfig) => {
|
|
5
|
-
logger: import("../Utils/logger").ILogger
|
|
6
|
-
getOrderDetails: (orderId: string, tokenBase64: string) => Promise<import("../Types").OrderDetails>
|
|
7
|
-
getCatalog: ({ jid, limit, cursor }: GetCatalogOptions) => Promise<{
|
|
8
|
-
products: import("../Types").Product[]
|
|
9
|
-
nextPageCursor: string | undefined
|
|
10
|
-
}>
|
|
11
|
-
getCollections: (jid?: string, limit?: number) => Promise<{
|
|
12
|
-
collections: import("../Types").CatalogCollection[]
|
|
13
|
-
}>
|
|
14
|
-
productCreate: (create: ProductCreate) => Promise<import("../Types").Product>
|
|
15
|
-
productDelete: (productIds: string[]) => Promise<{
|
|
16
|
-
deleted: number
|
|
17
|
-
}>
|
|
18
|
-
productUpdate: (productId: string, update: ProductUpdate) => Promise<import("../Types").Product>
|
|
19
|
-
sendMessageAck: ({ tag, attrs, content }: BinaryNode, errorCode?: number | undefined) => Promise<void>
|
|
20
|
-
sendRetryRequest: (node: BinaryNode, forceIncludeKeys?: boolean) => Promise<void>
|
|
21
|
-
offerCall: (toJid: string, isVideo?: boolean) => Promise<{
|
|
22
|
-
id: any
|
|
23
|
-
to: string
|
|
24
|
-
}>
|
|
25
|
-
rejectCall: (callId: string, callFrom: string) => Promise<void>
|
|
26
|
-
fetchMessageHistory: (count: number, oldestMsgKey: import("../Types").WAProto.IMessageKey, oldestMsgTimestamp: number | import("long").Long) => Promise<string>
|
|
27
|
-
requestPlaceholderResend: (messageKey: import("../Types").WAProto.IMessageKey) => Promise<string | undefined>
|
|
28
|
-
getPrivacyTokens: (jids: string[]) => Promise<BinaryNode>
|
|
29
|
-
assertSessions: (jids: string[], force: boolean) => Promise<boolean>
|
|
30
|
-
relayMessage: (jid: string, message: import("../Types").WAProto.IMessage, { messageId: msgId, participant, additionalAttributes, additionalNodes, useUserDevicesCache, useCachedGroupMetadata, statusJidList }: import("../Types").MessageRelayOptions) => Promise<string>
|
|
31
|
-
sendReceipt: (jid: string, participant: string | undefined, messageIds: string[], type: import("../Types").MessageReceiptType) => Promise<void>
|
|
32
|
-
sendReceipts: (keys: import("../Types").WAProto.IMessageKey[], type: import("../Types").MessageReceiptType) => Promise<void>
|
|
33
|
-
readMessages: (keys: import("../Types").WAProto.IMessageKey[]) => Promise<void>
|
|
34
|
-
refreshMediaConn: (forceGet?: boolean) => Promise<import("../Types").MediaConnInfo>
|
|
35
|
-
waUploadToServer: import("../Types").WAMediaUploadFunction
|
|
36
|
-
fetchPrivacySettings: (force?: boolean) => Promise<{
|
|
37
|
-
[_: string]: string
|
|
38
|
-
}>
|
|
39
|
-
sendPeerDataOperationMessage: (pdoMessage: import("../Types").WAProto.Message.IPeerDataOperationRequestMessage) => Promise<string>
|
|
40
|
-
createParticipantNodes: (jids: string[], message: import("../Types").WAProto.IMessage, extraAttrs?: {
|
|
41
|
-
[key: string]: string
|
|
42
|
-
} | undefined) => Promise<{
|
|
43
|
-
nodes: BinaryNode[]
|
|
44
|
-
shouldIncludeDeviceIdentity: boolean
|
|
45
|
-
}>
|
|
46
|
-
profilePictureUrl: (jid: string) => Promise<string>
|
|
47
|
-
getUSyncDevices: (jids: string[], useCache: boolean, ignoreZeroDevices: boolean) => Promise<import("../WABinary").JidWithDevice[]>
|
|
48
|
-
getEphemeralGroup: (jid: string) => Promise<number>
|
|
49
|
-
updateMediaMessage: (message: import("../Types").WAProto.IWebMessageInfo) => Promise<import("../Types").WAProto.IWebMessageInfo>
|
|
50
|
-
sendStatusMentions: (content: import("../Types").WAProto.IMessage, jid: string, Private?: boolean) => Promise<string>
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
1
|
+
import { GetCatalogOptions, ProductCreate, ProductUpdate, SocketConfig } from '../Types'
|
|
2
|
+
import { BinaryNode } from '../WABinary'
|
|
3
|
+
|
|
4
|
+
export declare const makeBusinessSocket: (config: SocketConfig) => {
|
|
5
|
+
logger: import("../Utils/logger").ILogger
|
|
6
|
+
getOrderDetails: (orderId: string, tokenBase64: string) => Promise<import("../Types").OrderDetails>
|
|
7
|
+
getCatalog: ({ jid, limit, cursor }: GetCatalogOptions) => Promise<{
|
|
8
|
+
products: import("../Types").Product[]
|
|
9
|
+
nextPageCursor: string | undefined
|
|
10
|
+
}>
|
|
11
|
+
getCollections: (jid?: string, limit?: number) => Promise<{
|
|
12
|
+
collections: import("../Types").CatalogCollection[]
|
|
13
|
+
}>
|
|
14
|
+
productCreate: (create: ProductCreate) => Promise<import("../Types").Product>
|
|
15
|
+
productDelete: (productIds: string[]) => Promise<{
|
|
16
|
+
deleted: number
|
|
17
|
+
}>
|
|
18
|
+
productUpdate: (productId: string, update: ProductUpdate) => Promise<import("../Types").Product>
|
|
19
|
+
sendMessageAck: ({ tag, attrs, content }: BinaryNode, errorCode?: number | undefined) => Promise<void>
|
|
20
|
+
sendRetryRequest: (node: BinaryNode, forceIncludeKeys?: boolean) => Promise<void>
|
|
21
|
+
offerCall: (toJid: string, isVideo?: boolean) => Promise<{
|
|
22
|
+
id: any
|
|
23
|
+
to: string
|
|
24
|
+
}>
|
|
25
|
+
rejectCall: (callId: string, callFrom: string) => Promise<void>
|
|
26
|
+
fetchMessageHistory: (count: number, oldestMsgKey: import("../Types").WAProto.IMessageKey, oldestMsgTimestamp: number | import("long").Long) => Promise<string>
|
|
27
|
+
requestPlaceholderResend: (messageKey: import("../Types").WAProto.IMessageKey) => Promise<string | undefined>
|
|
28
|
+
getPrivacyTokens: (jids: string[]) => Promise<BinaryNode>
|
|
29
|
+
assertSessions: (jids: string[], force: boolean) => Promise<boolean>
|
|
30
|
+
relayMessage: (jid: string, message: import("../Types").WAProto.IMessage, { messageId: msgId, participant, additionalAttributes, additionalNodes, useUserDevicesCache, useCachedGroupMetadata, statusJidList }: import("../Types").MessageRelayOptions) => Promise<string>
|
|
31
|
+
sendReceipt: (jid: string, participant: string | undefined, messageIds: string[], type: import("../Types").MessageReceiptType) => Promise<void>
|
|
32
|
+
sendReceipts: (keys: import("../Types").WAProto.IMessageKey[], type: import("../Types").MessageReceiptType) => Promise<void>
|
|
33
|
+
readMessages: (keys: import("../Types").WAProto.IMessageKey[]) => Promise<void>
|
|
34
|
+
refreshMediaConn: (forceGet?: boolean) => Promise<import("../Types").MediaConnInfo>
|
|
35
|
+
waUploadToServer: import("../Types").WAMediaUploadFunction
|
|
36
|
+
fetchPrivacySettings: (force?: boolean) => Promise<{
|
|
37
|
+
[_: string]: string
|
|
38
|
+
}>
|
|
39
|
+
sendPeerDataOperationMessage: (pdoMessage: import("../Types").WAProto.Message.IPeerDataOperationRequestMessage) => Promise<string>
|
|
40
|
+
createParticipantNodes: (jids: string[], message: import("../Types").WAProto.IMessage, extraAttrs?: {
|
|
41
|
+
[key: string]: string
|
|
42
|
+
} | undefined) => Promise<{
|
|
43
|
+
nodes: BinaryNode[]
|
|
44
|
+
shouldIncludeDeviceIdentity: boolean
|
|
45
|
+
}>
|
|
46
|
+
profilePictureUrl: (jid: string) => Promise<string>
|
|
47
|
+
getUSyncDevices: (jids: string[], useCache: boolean, ignoreZeroDevices: boolean) => Promise<import("../WABinary").JidWithDevice[]>
|
|
48
|
+
getEphemeralGroup: (jid: string) => Promise<number>
|
|
49
|
+
updateMediaMessage: (message: import("../Types").WAProto.IWebMessageInfo) => Promise<import("../Types").WAProto.IWebMessageInfo>
|
|
50
|
+
sendStatusMentions: (content: import("../Types").WAProto.IMessage, jid: string, Private?: boolean) => Promise<string>
|
|
51
|
+
sendMessage: (jid: string, content: import("../Types").AnyMessageContent, options?: import("../Types").MiscMessageGenerationOptions) => Promise<import("../Types").WAProto.WebMessageInfo | undefined>
|
|
52
|
+
groupMetadata: (jid: string) => Promise<import("../Types").GroupMetadata>
|
|
53
|
+
groupCreate: (subject: string, participants: string[]) => Promise<import("../Types").GroupMetadata>
|
|
54
|
+
groupLeave: (id: string) => Promise<void>
|
|
55
|
+
groupUpdateSubject: (jid: string, subject: string) => Promise<void>
|
|
56
|
+
groupRequestParticipantsList: (jid: string) => Promise<{
|
|
57
|
+
[key: string]: string
|
|
58
|
+
}[]>
|
|
59
|
+
groupRequestParticipantsUpdate: (jid: string, participants: string[], action: "reject" | "approve") => Promise<{
|
|
60
|
+
status: string
|
|
61
|
+
jid: string
|
|
62
|
+
}[]>
|
|
63
|
+
groupParticipantsUpdate: (jid: string, participants: string[], action: import("../Types").ParticipantAction) => Promise<{
|
|
64
|
+
status: string
|
|
65
|
+
jid: string
|
|
66
|
+
content: BinaryNode
|
|
67
|
+
}[]>
|
|
68
|
+
subscribeNewsletterUpdates: (jid: string) => Promise<{
|
|
69
|
+
duration: string
|
|
70
|
+
}>
|
|
71
|
+
newsletterReactionMode: (jid: string, mode: import("../Types").NewsletterReactionMode) => Promise<void>
|
|
72
|
+
newsletterUpdateDescription: (jid: string, description?: string | undefined) => Promise<void>
|
|
73
|
+
newsletterUpdateName: (jid: string, name: string) => Promise<void>
|
|
74
|
+
newsletterUpdatePicture: (jid: string, content: import("../Types").WAMediaUpload) => Promise<void>
|
|
75
|
+
newsletterRemovePicture: (jid: string) => Promise<void>
|
|
76
|
+
newsletterUnfollow: (jid: string) => Promise<void>
|
|
77
|
+
newsletterFollow: (jid: string) => Promise<void>
|
|
78
|
+
newsletterUnmute: (jid: string) => Promise<void>
|
|
79
|
+
newsletterMute: (jid: string) => Promise<void>
|
|
80
|
+
newsletterCreate: (name: string, description?: string, picture?: import("../Types").WAMediaUpload) => Promise<import("../Types").NewsletterMetadata>
|
|
81
|
+
newsletterQuery: (jid: string, type: string, content: BinaryNode) => Promise<BinaryNode>
|
|
82
|
+
newsletterWMexQuery: (jid?: string | undefined, query_id: number, content: BinaryNode) => Promise<BinaryNode>
|
|
83
|
+
newsletterMetadata: (type: "invite" | "jid", key: string, role?: import("../Types").NewsletterViewRole | undefined) => Promise<import("../Types").NewsletterMetadata>
|
|
84
|
+
newsletterFetchAllParticipating: () => Promise<{
|
|
85
|
+
[_: string]: import("../Types").NewsletterMetadata
|
|
86
|
+
}>
|
|
87
|
+
newsletterAdminCount: (jid: string) => Promise<number>
|
|
88
|
+
newsletterChangeOwner: (jid: string, userLid: string) => Promise<void>
|
|
89
|
+
newsletterDemote: (jid: string, userLid: string) => Promise<void>
|
|
90
|
+
newsletterDelete: (jid: string) => Promise<void>
|
|
91
|
+
newsletterReactMessage: (jid: string, server_id: string, code?: string | undefined) => Promise<void>
|
|
92
|
+
newsletterFetchMessages: (type: "invite" | "jid", key: string, count: number, after?: number | undefined) => Promise<import("../Types").NewsletterFetchedUpdate[]>
|
|
93
|
+
newsletterFetchUpdates: (jid: string, count: number, after?: number | undefined, since?: number | undefined) => Promise<import("../Types").NewsletterFetchedUpdate[]>
|
|
94
|
+
groupQuery: (jid: string, type: string, content: BinaryNode) => Promise<BinaryNode>
|
|
95
|
+
groupUpdateDescription: (jid: string, description?: string | undefined) => Promise<void>
|
|
96
|
+
groupInviteCode: (jid: string) => Promise<string | undefined>
|
|
97
|
+
groupRevokeInvite: (jid: string) => Promise<string | undefined>
|
|
98
|
+
groupAcceptInvite: (code: string) => Promise<string | undefined>
|
|
99
|
+
groupRevokeInviteV4: (groupJid: string, invitedJid: string) => Promise<boolean>
|
|
100
|
+
groupAcceptInviteV4: (key: string | import("../Types").WAProto.IMessageKey, inviteMessage: import("../Types").WAProto.Message.IGroupInviteMessage) => Promise<string>
|
|
101
|
+
groupGetInviteInfo: (code: string) => Promise<import("../Types").GroupMetadata>
|
|
102
|
+
groupToggleEphemeral: (jid: string, ephemeralExpiration: number) => Promise<void>
|
|
103
|
+
groupSettingUpdate: (jid: string, setting: "announcement" | "locked" | "not_announcement" | "unlocked") => Promise<void>
|
|
104
|
+
groupMemberAddMode: (jid: string, mode: "all_member_add" | "admin_add") => Promise<void>
|
|
105
|
+
groupJoinApprovalMode: (jid: string, mode: "on" | "off") => Promise<void>
|
|
106
|
+
groupFetchAllParticipating: () => Promise<{
|
|
107
|
+
[_: string]: import("../Types").GroupMetadata
|
|
108
|
+
}>
|
|
109
|
+
processingMutex: {
|
|
110
|
+
mutex<T>(code: () => T | Promise<T>): Promise<T>
|
|
111
|
+
}
|
|
112
|
+
upsertMessage: (msg: import("../Types").WAProto.IWebMessageInfo, type: import("../Types").MessageUpsertType) => Promise<void>
|
|
113
|
+
appPatch: (patchCreate: import("../Types").WAPatchCreate) => Promise<void>
|
|
114
|
+
sendPresenceUpdate: (type: import("../Types").WAPresence, toJid?: string | undefined) => Promise<void>
|
|
115
|
+
presenceSubscribe: (toJid: string, tcToken?: Buffer | undefined) => Promise<void>
|
|
116
|
+
getBotListV2: () => Promise<BotListInfo[]>
|
|
117
|
+
getLidUser: (jid: string) => Promise<{
|
|
118
|
+
lid: string
|
|
119
|
+
id: string
|
|
120
|
+
}[] | undefined>
|
|
121
|
+
onWhatsApp: (...jids: string[]) => Promise<{
|
|
122
|
+
jid: string
|
|
123
|
+
exists: unknown
|
|
124
|
+
}[] | undefined>
|
|
125
|
+
fetchBlocklist: () => Promise<string[]>
|
|
126
|
+
fetchStatus: (...jids: string[]) => Promise<import("..").USyncQueryResultList[] | undefined>
|
|
127
|
+
fetchDisappearingDuration: (...jids: string[]) => Promise<import("..").USyncQueryResultList[] | undefined>
|
|
128
|
+
updateProfilePicture: (jid: string, content: import("../Types").WAMediaUpload) => Promise<void>
|
|
129
|
+
removeProfilePicture: (jid: string) => Promise<void>
|
|
130
|
+
updateProfileStatus: (status: string) => Promise<void>
|
|
131
|
+
updateProfileName: (name: string) => Promise<void>
|
|
132
|
+
updateBlockStatus: (jid: string, action: "block" | "unblock") => Promise<void>
|
|
133
|
+
updateCallPrivacy: (value: import("../Types").WAPrivacyCallValue) => Promise<void>
|
|
134
|
+
updateLastSeenPrivacy: (value: import("../Types").WAPrivacyValue) => Promise<void>
|
|
135
|
+
updateOnlinePrivacy: (value: import("../Types").WAPrivacyOnlineValue) => Promise<void>
|
|
136
|
+
updateProfilePicturePrivacy: (value: import("../Types").WAPrivacyValue) => Promise<void>
|
|
137
|
+
updateStatusPrivacy: (value: import("../Types").WAPrivacyValue) => Promise<void>
|
|
138
|
+
updateReadReceiptsPrivacy: (value: import("../Types").WAReadReceiptsValue) => Promise<void>
|
|
139
|
+
updateGroupsAddPrivacy: (value: import("../Types").WAPrivacyGroupAddValue) => Promise<void>
|
|
140
|
+
updateDefaultDisappearingMode: (duration: number) => Promise<void>
|
|
141
|
+
updateDisableLinkPreviewsPrivacy: (isPreviewsDisabled: boolean) => Promise<void>
|
|
142
|
+
getBusinessProfile: (jid: string) => Promise<void | import("../Types").WABusinessProfile>
|
|
143
|
+
resyncAppState: (collections: readonly ("critical_block" | "critical_unblock_low" | "regular_high" | "regular_low" | "regular")[], isInitialSync: boolean) => Promise<void>
|
|
144
|
+
chatModify: (mod: import("../Types").ChatModification, jid: string) => Promise<void>
|
|
145
|
+
cleanDirtyBits: (type: "account_sync" | "groups", fromTimestamp?: string | number | undefined) => Promise<void>
|
|
146
|
+
addLabel: (jid: string, labels: import("../Types/Label").LabelActionBody) => Promise<void>
|
|
147
|
+
addChatLabel: (jid: string, labelId: string) => Promise<void>
|
|
148
|
+
removeChatLabel: (jid: string, labelId: string) => Promise<void>
|
|
149
|
+
addMessageLabel: (jid: string, messageId: string, labelId: string) => Promise<void>
|
|
150
|
+
removeMessageLabel: (jid: string, messageId: string, labelId: string) => Promise<void>
|
|
151
|
+
clearMessage: (jid: string, key: import("../Types").WAProto.IMessageKey, timeStamp: number | import("long").Long) => Promise<void>
|
|
152
|
+
star: (jid: string, messages: {
|
|
153
|
+
id: string
|
|
154
|
+
fromMe?: boolean | undefined
|
|
155
|
+
}[], star: boolean) => Promise<void>
|
|
156
|
+
executeUSyncQuery: (usyncQuery: import("..").USyncQuery) => Promise<import("..").USyncQueryResult | undefined>
|
|
157
|
+
type: "md"
|
|
158
|
+
ws: import("./Client").WebSocketClient
|
|
159
|
+
ev: import("../Types").BaileysEventEmitter & {
|
|
160
|
+
process(handler: (events: Partial<import("../Types").BaileysEventMap>) => void | Promise<void>): () => void
|
|
161
|
+
buffer(): void
|
|
162
|
+
createBufferedFunction<A extends any[], T_1>(work: (...args: A) => Promise<T_1>): (...args: A) => Promise<T_1>
|
|
163
|
+
flush(force?: boolean | undefined): boolean
|
|
164
|
+
isBuffering(): boolean
|
|
165
|
+
}
|
|
166
|
+
authState: {
|
|
167
|
+
creds: import("../Types").AuthenticationCreds
|
|
168
|
+
keys: import("../Types").SignalKeyStoreWithTransaction
|
|
169
|
+
}
|
|
170
|
+
signalRepository: import("../Types").SignalRepository
|
|
171
|
+
user: import("../Types").Contact | undefined
|
|
172
|
+
generateMessageTag: () => string
|
|
173
|
+
query: (node: BinaryNode, timeoutMs?: number | undefined) => Promise<BinaryNode>
|
|
174
|
+
waitForMessage: <T_2>(msgId: string, timeoutMs?: number | undefined) => Promise<T_2>
|
|
175
|
+
waitForSocketOpen: () => Promise<void>
|
|
176
|
+
sendRawMessage: (data: Uint8Array | Buffer) => Promise<void>
|
|
177
|
+
sendNode: (frame: BinaryNode) => Promise<void>
|
|
178
|
+
logout: (msg?: string | undefined) => Promise<void>
|
|
179
|
+
end: (error: Error | undefined) => void
|
|
180
|
+
onUnexpectedError: (err: Error | import("@hapi/boom").Boom<any>, msg: string) => void
|
|
181
|
+
uploadPreKeys: (count?: number) => Promise<void>
|
|
182
|
+
uploadPreKeysToServerIfRequired: () => Promise<void>
|
|
183
|
+
requestPairingCode: (phoneNumber: string, code?: string) => Promise<string>
|
|
184
|
+
waitForConnectionUpdate: (check: (u: Partial<import("../Types").ConnectionState>) => boolean | undefined, timeoutMs?: number | undefined) => Promise<void>
|
|
185
|
+
sendWAMBuffer: (wamBuffer: Buffer) => Promise<BinaryNode>
|
|
183
186
|
}
|