@wppconnect/wa-js 1.0.3 → 1.0.7

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.
Files changed (164) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/README.md +13 -6
  3. package/dist/{src/assert → assert}/assertChat.d.ts +0 -0
  4. package/dist/{src/assert → assert}/assertWid.d.ts +0 -0
  5. package/dist/{src/assert → assert}/index.d.ts +0 -0
  6. package/dist/{src/auth → auth}/Auth.d.ts +2 -1
  7. package/dist/{src/auth → auth}/index.d.ts +0 -0
  8. package/dist/{src/auth → auth}/types.d.ts +1 -0
  9. package/dist/{src/blocklist → blocklist}/Blocklist.d.ts +0 -0
  10. package/dist/{src/blocklist → blocklist}/index.d.ts +0 -0
  11. package/dist/{src/blocklist → blocklist}/types.d.ts +0 -0
  12. package/dist/{src/chat → chat}/Chat.d.ts +10 -0
  13. package/dist/{src/chat → chat}/index.d.ts +0 -0
  14. package/dist/{src/group → chat}/types.d.ts +17 -1
  15. package/dist/{src/config.d.ts → config.d.ts} +5 -1
  16. package/dist/{src/deviceName.d.ts → deviceName.d.ts} +0 -0
  17. package/dist/{src/group → group}/Group.d.ts +0 -0
  18. package/dist/{src/group → group}/index.d.ts +0 -0
  19. package/dist/{src/chat → group}/types.d.ts +0 -0
  20. package/dist/{src/index.d.ts → index.d.ts} +8 -11
  21. package/dist/internal.d.ts +20 -0
  22. package/dist/{src/patch.d.ts → patch.d.ts} +0 -0
  23. package/dist/{src/status → status}/Status.d.ts +0 -0
  24. package/dist/{src/status → status}/index.d.ts +0 -0
  25. package/dist/{src/status → status}/types.d.ts +0 -0
  26. package/dist/{src/util → util}/createWid.d.ts +0 -0
  27. package/dist/{src/util → util}/errors.d.ts +0 -0
  28. package/dist/{src/util → util}/index.d.ts +0 -0
  29. package/dist/{src/util → util}/types.d.ts +0 -0
  30. package/dist/{src/webpack.d.ts → webpack.d.ts} +0 -0
  31. package/dist/{src/whatsapp → whatsapp}/collections/BlocklistCollection.d.ts +1 -1
  32. package/dist/{src/whatsapp → whatsapp}/collections/BusinessCategoriesResultCollection.d.ts +1 -1
  33. package/dist/{src/whatsapp → whatsapp}/collections/BusinessProfileCollection.d.ts +1 -1
  34. package/dist/{src/whatsapp → whatsapp}/collections/ButtonCollection.d.ts +1 -3
  35. package/dist/{src/whatsapp → whatsapp}/collections/CallCollection.d.ts +1 -3
  36. package/dist/{src/whatsapp → whatsapp}/collections/CartCollection.d.ts +1 -3
  37. package/dist/{src/whatsapp → whatsapp}/collections/CartItemCollection.d.ts +1 -3
  38. package/dist/{src/whatsapp → whatsapp}/collections/CatalogCollection.d.ts +1 -3
  39. package/dist/{src/whatsapp → whatsapp}/collections/ChatCollection.d.ts +1 -3
  40. package/dist/{src/whatsapp → whatsapp}/collections/ChatstateCollection.d.ts +1 -3
  41. package/dist/{src/whatsapp → whatsapp}/collections/Collection.d.ts +2 -6
  42. package/dist/{src/whatsapp → whatsapp}/collections/CollectionCache.d.ts +1 -4
  43. package/dist/{src/whatsapp → whatsapp}/collections/ContactCollection.d.ts +1 -3
  44. package/dist/{src/whatsapp → whatsapp}/collections/EmojiVariantCollection.d.ts +1 -3
  45. package/dist/{src/whatsapp → whatsapp}/collections/GroupMetadataCollection.d.ts +1 -3
  46. package/dist/{src/whatsapp → whatsapp}/collections/LabelCollection.d.ts +3 -5
  47. package/dist/{src/whatsapp → whatsapp}/collections/LabelItemCollection.d.ts +1 -3
  48. package/dist/{src/whatsapp → whatsapp}/collections/LiveLocationCollection.d.ts +1 -3
  49. package/dist/{src/whatsapp → whatsapp}/collections/MsgCollection.d.ts +4 -5
  50. package/dist/{src/whatsapp → whatsapp}/collections/MsgInfoCollection.d.ts +1 -3
  51. package/dist/{src/whatsapp → whatsapp}/collections/MuteCollection.d.ts +1 -3
  52. package/dist/{src/whatsapp → whatsapp}/collections/OrderCollection.d.ts +1 -3
  53. package/dist/{src/whatsapp → whatsapp}/collections/OrderItemCollection.d.ts +1 -3
  54. package/dist/{src/whatsapp → whatsapp}/collections/ParticipantCollection.d.ts +1 -3
  55. package/dist/{src/whatsapp → whatsapp}/collections/PresenceCollection.d.ts +1 -3
  56. package/dist/{src/whatsapp → whatsapp}/collections/ProductCollCollection.d.ts +1 -3
  57. package/dist/{src/whatsapp → whatsapp}/collections/ProductCollection.d.ts +1 -3
  58. package/dist/{src/whatsapp → whatsapp}/collections/ProductImageCollection.d.ts +1 -3
  59. package/dist/{src/whatsapp → whatsapp}/collections/ProductMessageListCollection.d.ts +1 -3
  60. package/dist/{src/whatsapp → whatsapp}/collections/ProfilePicThumbCollection.d.ts +1 -3
  61. package/dist/{src/whatsapp → whatsapp}/collections/QuickReplyCollection.d.ts +1 -3
  62. package/dist/{src/whatsapp → whatsapp}/collections/RecentEmojiCollection.d.ts +1 -3
  63. package/dist/{src/whatsapp → whatsapp}/collections/RecentStickerCollection.d.ts +1 -3
  64. package/dist/{src/whatsapp → whatsapp}/collections/StarredMsgCollection.d.ts +1 -3
  65. package/dist/{src/whatsapp → whatsapp}/collections/StarredStickerCollection.d.ts +1 -3
  66. package/dist/{src/whatsapp → whatsapp}/collections/StatusCollection.d.ts +1 -3
  67. package/dist/{src/whatsapp → whatsapp}/collections/StatusV3Collection.d.ts +1 -3
  68. package/dist/{src/whatsapp → whatsapp}/collections/StickerCollection.d.ts +1 -3
  69. package/dist/{src/whatsapp → whatsapp}/collections/StickerPackCollection.d.ts +1 -3
  70. package/dist/{src/whatsapp → whatsapp}/collections/StickerSearchCollection.d.ts +1 -3
  71. package/dist/{src/whatsapp → whatsapp}/collections/TemplateButtonCollection.d.ts +1 -3
  72. package/dist/{src/whatsapp → whatsapp}/collections/index.d.ts +0 -0
  73. package/dist/whatsapp/enums/LogoutReason.d.ts +27 -0
  74. package/dist/{src/whatsapp → whatsapp}/enums/SendMsgResult.d.ts +1 -3
  75. package/dist/{src/whatsapp → whatsapp}/enums/TextFontStyle.d.ts +0 -0
  76. package/dist/{src/whatsapp → whatsapp}/enums/index.d.ts +1 -0
  77. package/dist/{src/whatsapp → whatsapp}/exportModule.d.ts +0 -0
  78. package/dist/{src/whatsapp → whatsapp}/functions/addAndSendMsgToChat.d.ts +1 -3
  79. package/dist/{src/whatsapp → whatsapp}/functions/blockContact.d.ts +2 -6
  80. package/dist/{src/whatsapp → whatsapp}/functions/findChat.d.ts +1 -3
  81. package/dist/{src/whatsapp → whatsapp}/functions/getOrGenerate.d.ts +1 -3
  82. package/dist/{src/whatsapp → whatsapp}/functions/groupParticipants.d.ts +4 -12
  83. package/dist/{src/whatsapp → whatsapp}/functions/index.d.ts +2 -0
  84. package/dist/{src/whatsapp → whatsapp}/functions/isAuthenticated.d.ts +1 -3
  85. package/dist/{src/whatsapp → whatsapp}/functions/msgFindQuery.d.ts +1 -3
  86. package/dist/{src/whatsapp → whatsapp}/functions/randomId.d.ts +2 -6
  87. package/dist/whatsapp/functions/sendClear.d.ts +18 -0
  88. package/dist/whatsapp/functions/sendDelete.d.ts +18 -0
  89. package/dist/{src/whatsapp → whatsapp}/functions/sendTextMsgToChat.d.ts +1 -3
  90. package/dist/{src/whatsapp → whatsapp}/index.d.ts +0 -0
  91. package/dist/{src/whatsapp → whatsapp}/misc/Base64.d.ts +1 -3
  92. package/dist/{src/whatsapp → whatsapp}/misc/Browser.d.ts +1 -3
  93. package/dist/{src/whatsapp → whatsapp}/misc/ClockSkew.d.ts +1 -3
  94. package/dist/whatsapp/misc/Cmd.d.ts +150 -0
  95. package/dist/{src/whatsapp → whatsapp}/misc/Conn.d.ts +1 -3
  96. package/dist/{src/whatsapp → whatsapp}/misc/Constants.d.ts +1 -3
  97. package/dist/{src/whatsapp → whatsapp}/misc/EventEmitter.d.ts +1 -3
  98. package/dist/{src/whatsapp → whatsapp}/misc/Features.d.ts +1 -6
  99. package/dist/{src/whatsapp → whatsapp}/misc/ImageUtils.d.ts +1 -3
  100. package/dist/{src/whatsapp → whatsapp}/misc/MediaUtils.d.ts +1 -3
  101. package/dist/{src/whatsapp → whatsapp}/misc/MsgKey.d.ts +1 -3
  102. package/dist/{src/whatsapp → whatsapp}/misc/MsgLoadState.d.ts +5 -6
  103. package/dist/{src/whatsapp → whatsapp}/misc/State.d.ts +1 -3
  104. package/dist/{src/whatsapp → whatsapp}/misc/Stringable.d.ts +0 -0
  105. package/dist/{src/whatsapp → whatsapp}/misc/UserPrefs.d.ts +1 -3
  106. package/dist/{src/whatsapp → whatsapp}/misc/Wid.d.ts +1 -3
  107. package/dist/{src/whatsapp → whatsapp}/misc/WidFactory.d.ts +1 -3
  108. package/dist/{src/whatsapp → whatsapp}/misc/index.d.ts +1 -0
  109. package/dist/{src/whatsapp → whatsapp}/models/AttachMediaModel.d.ts +2 -6
  110. package/dist/{src/whatsapp → whatsapp}/models/BlocklistModel.d.ts +2 -6
  111. package/dist/{src/whatsapp → whatsapp}/models/BusinessCategoriesResultModel.d.ts +2 -6
  112. package/dist/{src/whatsapp → whatsapp}/models/BusinessProfileModel.d.ts +2 -6
  113. package/dist/{src/whatsapp → whatsapp}/models/CallModel.d.ts +2 -6
  114. package/dist/{src/whatsapp → whatsapp}/models/CallParticipantModel.d.ts +2 -6
  115. package/dist/{src/whatsapp → whatsapp}/models/CartItemModel.d.ts +2 -6
  116. package/dist/{src/whatsapp → whatsapp}/models/CartModel.d.ts +2 -6
  117. package/dist/{src/whatsapp → whatsapp}/models/CatalogModel.d.ts +2 -6
  118. package/dist/{src/whatsapp → whatsapp}/models/ChatModel.d.ts +10 -10
  119. package/dist/{src/whatsapp → whatsapp}/models/ChatPreferenceModel.d.ts +2 -6
  120. package/dist/{src/whatsapp → whatsapp}/models/ChatstateModel.d.ts +2 -6
  121. package/dist/{src/whatsapp → whatsapp}/models/ConnModel.d.ts +2 -6
  122. package/dist/{src/whatsapp → whatsapp}/models/ContactModel.d.ts +2 -6
  123. package/dist/{src/whatsapp → whatsapp}/models/ConversionTupleModel.d.ts +2 -6
  124. package/dist/{src/whatsapp → whatsapp}/models/EmojiVariantModel.d.ts +2 -6
  125. package/dist/{src/whatsapp → whatsapp}/models/GroupMetadataModel.d.ts +2 -6
  126. package/dist/{src/whatsapp → whatsapp}/models/LabelItemModel.d.ts +2 -6
  127. package/dist/{src/whatsapp → whatsapp}/models/LabelModel.d.ts +2 -6
  128. package/dist/{src/whatsapp → whatsapp}/models/LiveLocationModel.d.ts +2 -6
  129. package/dist/{src/whatsapp → whatsapp}/models/LiveLocationParticipantModel.d.ts +2 -6
  130. package/dist/{src/whatsapp → whatsapp}/models/MediaDataModel.d.ts +2 -6
  131. package/dist/{src/whatsapp → whatsapp}/models/Model.d.ts +1 -9
  132. package/dist/{src/whatsapp → whatsapp}/models/ModelChatBase.d.ts +1 -9
  133. package/dist/{src/whatsapp → whatsapp}/models/MsgButtonReplyMsgModel.d.ts +2 -6
  134. package/dist/{src/whatsapp → whatsapp}/models/MsgInfoModel.d.ts +2 -6
  135. package/dist/{src/whatsapp → whatsapp}/models/MsgModel.d.ts +3 -10
  136. package/dist/{src/whatsapp → whatsapp}/models/MuteModel.d.ts +2 -6
  137. package/dist/{src/whatsapp → whatsapp}/models/OrderItemModel.d.ts +2 -6
  138. package/dist/{src/whatsapp → whatsapp}/models/OrderModel.d.ts +2 -6
  139. package/dist/{src/whatsapp → whatsapp}/models/ParticipantModel.d.ts +2 -6
  140. package/dist/{src/whatsapp → whatsapp}/models/ProductCollModel.d.ts +2 -6
  141. package/dist/{src/whatsapp → whatsapp}/models/ProductImageModel.d.ts +2 -6
  142. package/dist/{src/whatsapp → whatsapp}/models/ProductModel.d.ts +2 -6
  143. package/dist/{src/whatsapp → whatsapp}/models/Product_listModel.d.ts +2 -6
  144. package/dist/{src/whatsapp → whatsapp}/models/ProfilePicThumbModel.d.ts +2 -6
  145. package/dist/{src/whatsapp → whatsapp}/models/QuickReplyModel.d.ts +2 -6
  146. package/dist/{src/whatsapp → whatsapp}/models/RecentEmojiModel.d.ts +2 -6
  147. package/dist/{src/whatsapp → whatsapp}/models/RecentStickerModel.d.ts +2 -6
  148. package/dist/{src/whatsapp → whatsapp}/models/ReplyButtonModel.d.ts +2 -15
  149. package/dist/{src/whatsapp → whatsapp}/models/StateModel.d.ts +4 -7
  150. package/dist/{src/whatsapp → whatsapp}/models/StatusModel.d.ts +2 -6
  151. package/dist/{src/whatsapp → whatsapp}/models/StatusV3Model.d.ts +2 -6
  152. package/dist/{src/whatsapp → whatsapp}/models/StickerModel.d.ts +2 -6
  153. package/dist/{src/whatsapp → whatsapp}/models/StickerPackModel.d.ts +2 -6
  154. package/dist/{src/whatsapp → whatsapp}/models/TemplateButtonModel.d.ts +2 -6
  155. package/dist/{src/whatsapp → whatsapp}/models/UnreadMentionModel.d.ts +2 -6
  156. package/dist/{src/whatsapp → whatsapp}/models/WebCallModel.d.ts +2 -6
  157. package/dist/{src/whatsapp → whatsapp}/models/index.d.ts +1 -0
  158. package/dist/{src/whatsapp → whatsapp}/multidevice/adv.d.ts +1 -3
  159. package/dist/{src/whatsapp → whatsapp}/multidevice/index.d.ts +0 -0
  160. package/dist/{src/whatsapp → whatsapp}/multidevice/waNoiseInfo.d.ts +1 -6
  161. package/dist/{src/whatsapp → whatsapp}/multidevice/waSignalStore.d.ts +1 -6
  162. package/dist/{src/whatsapp → whatsapp}/stores.d.ts +29 -87
  163. package/dist/wppconnect-wa.js +1 -1
  164. package/package.json +14 -14
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { RecentEmojiModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:30462
20
- */
18
+ /** @whatsapp 2.2140.7:30462 */
21
19
  export declare class RecentEmojiCollection extends Collection<RecentEmojiModel> {
22
20
  static cachePolicy?: any;
23
21
  static model: RecentEmojiModel;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StickerModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:27686
20
- */
18
+ /** @whatsapp 2.2140.7:27686 */
21
19
  export declare class RecentStickerCollection extends Collection<StickerModel> {
22
20
  static model: StickerModel;
23
21
  enqueue(e?: any): any;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { MsgModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:30118
20
- */
18
+ /** @whatsapp 2.2140.7:30118 */
21
19
  export declare class StarredMsgCollection extends Collection<MsgModel> {
22
20
  static model: MsgModel;
23
21
  syncPromise?: any;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StickerModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:68477
20
- */
18
+ /** @whatsapp 2.2140.7:68477 */
21
19
  export declare class StarredStickerCollection extends Collection<StickerModel> {
22
20
  static model: StickerModel;
23
21
  syncNextPage(): any;
@@ -16,9 +16,7 @@
16
16
  import { Wid } from '../misc';
17
17
  import { StatusModel } from '../models';
18
18
  import { Collection } from './Collection';
19
- /**
20
- * @whatsapp 2.2138.10:22360
21
- */
19
+ /** @whatsapp 2.2140.7:22360 */
22
20
  export declare class StatusCollection extends Collection<StatusModel> {
23
21
  static model: StatusModel;
24
22
  static idClass: typeof Wid;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StatusV3Model } from '../models';
17
17
  import { CollectionCache } from '.';
18
- /**
19
- * @whatsapp 2.2138.10:83125
20
- */
18
+ /** @whatsapp 2.2140.7:83125 */
21
19
  export declare class StatusV3Collection extends CollectionCache<StatusV3Model> {
22
20
  static model: StatusV3Model;
23
21
  loadMore(e?: any, t?: any, r?: any): any;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StickerModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:16482
20
- */
18
+ /** @whatsapp 2.2140.7:16482 */
21
19
  export declare class StickerCollection extends Collection<StickerModel> {
22
20
  static model: StickerModel;
23
21
  fetch(): any;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StickerPackModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:61848
20
- */
18
+ /** @whatsapp 2.2140.7:45822 */
21
19
  export declare class StickerPackCollection extends Collection<StickerPackModel> {
22
20
  static model: StickerPackModel;
23
21
  checksum?: any;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { StickerModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:6009
20
- */
18
+ /** @whatsapp 2.2140.7:6009 */
21
19
  export declare class StickerSearchCollection extends Collection<StickerModel> {
22
20
  static model: StickerModel;
23
21
  isFetchingData(): boolean;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { TemplateButtonModel } from '../models';
17
17
  import { Collection } from './Collection';
18
- /**
19
- * @whatsapp 2.2138.10:95411
20
- */
18
+ /** @whatsapp 2.2140.7:95411 */
21
19
  export declare class TemplateButtonCollection extends Collection<TemplateButtonModel> {
22
20
  static model: TemplateButtonModel;
23
21
  static comparator(): any;
@@ -0,0 +1,27 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /** @whatsapp 2.2140.7:45634 */
17
+ export declare enum LogoutReason {
18
+ USER_INITIATED = "user_initiated",
19
+ SYNCD_FAILURE = "syncd_failure",
20
+ CRITICAL_SYNC_TIMEOUT = "critical_sync_timeout",
21
+ UNKNOWN_COMPANION = "unknown_companion",
22
+ CLIENT_VERSION_OUTDATED = "client_version_outdated",
23
+ SYNCD_ERROR_DURING_BOOTSTRAP = "syncd_error_during_bootstrap",
24
+ ACCOUNT_SYNC_ERROR = "account_sync_error",
25
+ CLIENT_FATAL_ERROR = "client_fatal_error",
26
+ UNKNOWN = "unknown"
27
+ }
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:88300
18
- */
16
+ /** @whatsapp 2.2140.7:88300 */
19
17
  export declare enum SendMsgResult {
20
18
  OK = "OK",
21
19
  ERROR_NETWORK = "ERROR_NETWORK",
@@ -13,5 +13,6 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ export * from './LogoutReason';
16
17
  export * from './SendMsgResult';
17
18
  export * from './TextFontStyle';
@@ -15,7 +15,5 @@
15
15
  */
16
16
  import { SendMsgResult } from '../enums';
17
17
  import { ChatModel, ModelPropertiesContructor, MsgModel } from '../models';
18
- /**
19
- * @whatsapp 2.2138.10:35339
20
- */
18
+ /** @whatsapp 2.2140.7:35339 */
21
19
  export declare function addAndSendMsgToChat(chat: ChatModel, message: ModelPropertiesContructor<MsgModel>): Promise<[Promise<MsgModel>, Promise<SendMsgResult>]>;
@@ -14,11 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import { ContactModel } from '../models';
17
- /**
18
- * @whatsapp 2.2138.10:38512
19
- */
17
+ /** @whatsapp 2.2140.7:38512 */
20
18
  export declare function blockContact(contact: ContactModel): Promise<void>;
21
- /**
22
- * @whatsapp 2.2138.10:38512
23
- */
19
+ /** @whatsapp 2.2140.7:38512 */
24
20
  export declare function unblockContact(contact: ContactModel): Promise<void>;
@@ -15,7 +15,5 @@
15
15
  */
16
16
  import { Wid } from '..';
17
17
  import { ChatModel } from '../models';
18
- /**
19
- * @whatsapp 2.2138.10:62238
20
- */
18
+ /** @whatsapp 2.2140.7:62238 */
21
19
  export declare function findChat(wid: Wid): Promise<ChatModel>;
@@ -13,7 +13,5 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:96403
18
- */
16
+ /** @whatsapp 2.2140.7:96403 */
19
17
  export declare function getOrGenerate(): string;
@@ -14,19 +14,11 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import { ChatModel, ParticipantModel } from '..';
17
- /**
18
- * @whatsapp 2.2138.10:97449
19
- */
17
+ /** @whatsapp 2.2140.7:97449 */
20
18
  export declare function addParticipants(group: ChatModel, participants: ParticipantModel[]): Promise<void>;
21
- /**
22
- * @whatsapp 2.2138.10:97449
23
- */
19
+ /** @whatsapp 2.2140.7:97449 */
24
20
  export declare function removeParticipants(group: ChatModel, participants: ParticipantModel[]): Promise<void>;
25
- /**
26
- * @whatsapp 2.2138.10:97449
27
- */
21
+ /** @whatsapp 2.2140.7:97449 */
28
22
  export declare function promoteParticipants(group: ChatModel, participants: ParticipantModel[]): Promise<void>;
29
- /**
30
- * @whatsapp 2.2138.10:97449
31
- */
23
+ /** @whatsapp 2.2140.7:97449 */
32
24
  export declare function demoteParticipants(group: ChatModel, participants: ParticipantModel[]): Promise<void>;
@@ -21,4 +21,6 @@ export * from './groupParticipants';
21
21
  export * from './isAuthenticated';
22
22
  export * from './msgFindQuery';
23
23
  export * from './randomId';
24
+ export * from './sendClear';
25
+ export * from './sendDelete';
24
26
  export * from './sendTextMsgToChat';
@@ -13,7 +13,5 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:54930
18
- */
16
+ /** @whatsapp 2.2140.7:54930 */
19
17
  export declare function isAuthenticated(): boolean;
@@ -23,7 +23,5 @@ export interface MsgFindQueryParams {
23
23
  id?: string;
24
24
  participant?: any;
25
25
  }
26
- /**
27
- * @whatsapp 2.2138.10:2495
28
- */
26
+ /** @whatsapp 2.2140.7:2495 */
29
27
  export declare function msgFindQuery(direction: 'after' | 'before', params: MsgFindQueryParams): Promise<ModelPropertiesContructor<MsgModel>[]>;
@@ -13,11 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:17754
18
- */
16
+ /** @whatsapp 2.2140.7:17754 */
19
17
  export declare function randomMessageId(): string;
20
- /**
21
- * @whatsapp 2.2138.10:17754
22
- */
18
+ /** @whatsapp 2.2140.7:17754 */
23
19
  export declare function randomId(): string;
@@ -0,0 +1,18 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { ChatModel } from '..';
17
+ /** @whatsapp 2.2140.7:67357 */
18
+ export declare function sendClear(chat: ChatModel, keepStarred?: boolean): Promise<void>;
@@ -0,0 +1,18 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { ChatModel } from '..';
17
+ /** @whatsapp 2.2140.7:61670 */
18
+ export declare function sendDelete(chat: ChatModel): Promise<void>;
@@ -13,7 +13,5 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:30239
18
- */
16
+ /** @whatsapp 2.2140.7:30239 */
19
17
  export declare function sendTextMsgToChat(chat: any, message: any, options: any): Promise<string>;
File without changes
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:42977
18
- */
16
+ /** @whatsapp 2.2140.7:42977 */
19
17
  export declare namespace Base64 {
20
18
  const BASE64_DATA_URL_SCHEME: 'data:image/jpeg;base64,';
21
19
  function encodeB64(data: ArrayLike<number> | ArrayBufferLike): string;
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:94666
18
- */
16
+ /** @whatsapp 2.2140.7:94666 */
19
17
  export declare namespace Browser {
20
18
  let promptUnloadGuards: number;
21
19
  function id(): string;
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:25142
18
- */
16
+ /** @whatsapp 2.2140.7:25142 */
19
17
  export declare namespace ClockSkew {
20
18
  const is24h: boolean;
21
19
  const skew: number;
@@ -0,0 +1,150 @@
1
+ /*!
2
+ * Copyright 2021 WPPConnect Team
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { EventEmitter } from '.';
17
+ /**
18
+ * @whatsapp 2.2140.7:69162
19
+ */
20
+ export declare class CmdClass extends EventEmitter {
21
+ isMainLoaded: boolean;
22
+ uiBusy: number;
23
+ mainLoaded(): void;
24
+ incrementProgress(): void;
25
+ initialLoadReady(): void;
26
+ logSocketSummary(): void;
27
+ muteAll(e?: any, t?: any): void;
28
+ muteAllCall(e?: any, t?: any): void;
29
+ muteChat(e?: any, t?: any): void;
30
+ muteChats(e?: any, t?: any, r?: any): void;
31
+ deleteOrExitChat(e?: any, t?: any): void;
32
+ clearChat(e?: any, t?: any): void;
33
+ archiveChat(e?: any, t?: any): void;
34
+ pinChat(e?: any, t?: any): void;
35
+ pinChats(e?: any, t?: any): void;
36
+ markChatUnread(e?: any, t?: any): void;
37
+ msgInfoDrawer(e?: any): void;
38
+ chatSearch(e?: any): void;
39
+ chatInfoDrawer(e?: any, t?: any, r?: any): void;
40
+ attachMediaDrawer(e?: any): void;
41
+ attachProduct(e?: any): void;
42
+ verificationDrawer(e?: any): void;
43
+ liveLocationDrawer(e?: any, t?: any): void;
44
+ expiredLocationDrawer(e?: any): void;
45
+ mediaViewerModal(e?: any): void;
46
+ openMediaViewerForAlbumMedia(e?: any): void;
47
+ productImageViewerModal(e?: any, t?: any): void;
48
+ ephemeralDrawer(e?: any, t?: any): void;
49
+ sendStarMsgs(e?: any, t?: any, r?: any, n?: any): void;
50
+ sendUnstarMsgs(e?: any, t?: any, r?: any, n?: any): void;
51
+ sendDeleteMsgs(e?: any, t?: any, r?: any, n?: any, i?: any): void;
52
+ sendRevokeMsgs(e?: any, t?: any, r?: any, n?: any, i?: any): void;
53
+ _openChat(e?: any, t?: any): void;
54
+ openChatAt(e?: any, t?: any): void;
55
+ openChatFromUnread(e?: any): void;
56
+ openChatBottom(e?: any): void;
57
+ scrollToPtt(e?: any): void;
58
+ _scrollToFocusedMsg(e?: any): void;
59
+ _scrollChatToBottom(): void;
60
+ flashFocusedMsg(e?: any): void;
61
+ updateChatlistSelection(e?: any): void;
62
+ closeChat(e?: any): void;
63
+ focusChatTextInput(e?: any): void;
64
+ setChatCtwaContextLinkData(e?: any, t?: any): void;
65
+ focusShowMsg(e?: any): void;
66
+ enterChatTextInput(e?: any): void;
67
+ focusNextChat(e?: any): void;
68
+ focusPrevChat(e?: any): void;
69
+ focusChatList(): void;
70
+ focusChatSearch(): void;
71
+ pasteChatTextInput(e?: any, t?: any): void;
72
+ startGroupCall(e?: any, t?: any): void;
73
+ closeStatusViewer(): void;
74
+ sendPasteToCompose(e?: any, t?: any): void;
75
+ openComposeBoxPanel(e?: any): void;
76
+ login(e?: any): void;
77
+ logout(): void;
78
+ openContextMenu(e?: any, t?: any): void;
79
+ closeContextMenu(e?: any): void;
80
+ openTooltip(e?: any, t?: any): void;
81
+ closeTooltip(e?: any): void;
82
+ openToast(e?: any): void;
83
+ closeToast(e?: any): void;
84
+ alertNewMsg(e?: any): void;
85
+ newMediaMsg(e?: any): void;
86
+ alertCall(e?: any, t?: any, r?: any, n?: any, i?: any): void;
87
+ cancelCall(e?: any): void;
88
+ windowError(): void;
89
+ cannotReachPhone(): void;
90
+ sentPing(): void;
91
+ openModal(e?: any, t?: any): void;
92
+ closeModal(e?: any): void;
93
+ openModalMedia(e?: any, t?: any): void;
94
+ closeModalMedia(): void;
95
+ setDrawerContext(e?: any, t?: any): void;
96
+ openDrawerRight(e?: any, t?: any, r?: any, n?: any, i?: any): void;
97
+ openDrawerMid(e?: any, t?: any, r?: any, n?: any, i?: any, a?: any): void;
98
+ openDrawerLeft(e?: any, t?: any, r?: any, n?: any, i?: any): void;
99
+ existsDrawerRight(e?: any): void;
100
+ existsDrawerMid(e?: any): void;
101
+ existsDrawerLeft(e?: any): void;
102
+ closeDrawerRight(): void;
103
+ closeDrawerMid(): void;
104
+ closeDrawerLeft(): void;
105
+ onPanesWillChange(e?: any): void;
106
+ onPanesDidChange(e?: any): void;
107
+ openGroupInviteModal(e?: any): void;
108
+ openGroupV4InviteRequestFlow(e?: any, t?: any, r?: any, n?: any): void;
109
+ mediaPlaying(e?: any): void;
110
+ pttRecording(): void;
111
+ pttPlaying(e?: any): void;
112
+ uiResize(): void;
113
+ setUiBusy(e?: any): void;
114
+ windowMouseDown(e?: any): void;
115
+ windowClick(e?: any): void;
116
+ midnight(): void;
117
+ textsizeChange(e?: any): void;
118
+ scrollMessages(): void;
119
+ getConversationHeaderOffset(e?: any): void;
120
+ floaterEscapeOverlap(e?: any, t?: any): void;
121
+ autoplayPTT(e?: any): void;
122
+ refreshMessages(): void;
123
+ serverPropsUpdated(): void;
124
+ storageInitializationError(): void;
125
+ restartBackend(): void;
126
+ downgradeWebclient(): void;
127
+ upgradeToMDInternal(): void;
128
+ upgradeToMDProd(): void;
129
+ refreshQR(): void;
130
+ setSocketState(e?: any): void;
131
+ socketStreamDisconnected(): void;
132
+ openSocketStream(): void;
133
+ readyForMainStreamMode(): void;
134
+ onInitialChatHistorySynced(): void;
135
+ onRecentChatHistorySynced(): void;
136
+ onFullChatHistorySynced(): void;
137
+ onHistorySyncChunkProcessed(e?: any): void;
138
+ handleOfflineProgressUpdate(): void;
139
+ criticalSyncDone(): void;
140
+ onTemporaryBan(e?: any): void;
141
+ onStartingLogout(): void;
142
+ handleFatalError(): void;
143
+ merchantDetailsDrawer(e?: any): void;
144
+ showMerchantDetailsEntityTypePopup(e?: any, t?: any): void;
145
+ showCountrySelector(e?: any, t?: any, r?: any): void;
146
+ toggleStickerMaker(): void;
147
+ }
148
+ /** @whatsapp 2.2140.7:69162 */
149
+ export declare const Cmd: CmdClass;
150
+ export declare const APP_STATE_SYNC_COMPLETED: string;
@@ -14,7 +14,5 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import { ConnModel } from '../models';
17
- /**
18
- * @whatsapp 2.2138.10:9322
19
- */
17
+ /** @whatsapp 2.2140.7:9322 */
20
18
  export declare const Conn: ConnModel;
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:55454
18
- */
16
+ /** @whatsapp 2.2140.7:55454 */
19
17
  export declare const Constants: {
20
18
  ARCHIVE_NUX_MAX_VIEWS: number;
21
19
  IMG_THUMB_MAX_EDGE: number;
@@ -21,9 +21,7 @@ declare type Event = string | symbol;
21
21
  * The callback function.
22
22
  */
23
23
  declare type Listener = (...args: any[]) => void;
24
- /**
25
- * @whatsapp 2.2138.10:95863
26
- */
24
+ /** @whatsapp 2.2140.7:95863 */
27
25
  export declare class EventEmitter {
28
26
  /**
29
27
  * Adds the listener function to the end of the listeners array for the event named eventName.
@@ -15,9 +15,6 @@
15
15
  */
16
16
  import { EventEmitter } from './EventEmitter';
17
17
  declare type FeaturesNames = 'RESEND_ICON' | 'DELETE_MSG_CLEAR_MEDIA' | 'DEBUG_COMMANDS' | 'MD_BACKEND' | 'MD_ADV' | 'MD_PAYMENT' | 'MD_E2E' | 'MD_VOIP_GROUP' | 'MD_SYNCD_ANTI_TAMPERING' | 'CATALOG_MANAGER' | 'WEB_VOIP_VOICE_CALL' | 'WEB_VOIP_VIDEO_CALL' | 'MEDIA_AUTO_DOWNLOAD' | 'DOWNLOAD_STATUS_THUMB_MMS' | 'MEDIA_EXISTENCE_CHECK' | 'LOG_MISSING_REQUIRED_PROPERTIES' | 'HIGH_QUALITY_VIDEO_THUMBNAILS' | 'HIGH_QUALITY_LINK_PREVIEWS' | 'YOUTUBE_VIDEO_PREVIEW_WITHOUT_BLUR' | 'GROUP_CONVERSATIONS_MEDIA_TOOLTIPS' | 'DROP_LAST_NAME_MENTIONS' | 'RICH_TEXT_INPUT' | 'PTT_DRAFT_ENABLED' | 'PTT_WAVEFORM_SEND' | 'PTT_CONVERSATION_WAVEFORM' | 'SEE_STATUS_VIEWERS' | 'GROUP_CATCH_UP' | 'FORMAT_BULLETED_MSG' | 'ARCHIVE_V2_MD_SUPPORTED' | 'MEDIA_GALLERY_HEADERS' | 'PIP_VIDEO_REDESIGN' | 'LABELS_DISPLAY' | 'VOIP_INDIVIDUAL_OUTGOING' | 'GROUPS_V_3' | 'GROUPS_V_3_CREATE' | 'CHANGE_NUMBER_V_2' | 'QUERY_STATUS_V_3_THUMBNAIL' | 'LIVE_LOCATIONS' | 'QUERY_VNAME' | 'VOIP_INDIVIDUAL_INCOMING' | 'QUICK_REPLIES_QUERY' | 'PAYMENTS' | 'STICKER_PACK_QUERY' | 'LIVE_LOCATIONS_FINAL' | 'LABELS_EDIT' | 'MEDIA_UPLOAD' | 'MEDIA_UPLOAD_RICH_QUICK_REPLIES' | 'VNAME_V_2' | 'VIDEO_PLAYBACK_URL' | 'STATUS_RANKING' | 'VOIP_INDIVIDUAL_VIDEO' | 'THIRD_PARTY_STICKERS' | 'FREQUENTLY_FORWARDED_SETTING' | 'GROUPS_V_4_JOIN_PERMISSION' | 'RECENT_STICKERS' | 'CATALOG' | 'STARRED_STICKERS' | 'VOIP_GROUP_CALL' | 'TEMPLATE_MESSAGE' | 'TEMPLATE_MESSAGE_INTERACTIVITY' | 'EPHEMERAL_MESSAGES' | 'E_2_E_NOTIFICATION_SYNC' | 'RECENT_STICKERS_V_2' | 'RECENT_STICKERS_V_3' | 'USER_NOTICE' | 'SUPPORT' | 'GROUP_UII_CLEANUP' | 'GROUP_DOGFOODING_INTERNAL_ONLY' | 'SETTINGS_SYNC' | 'ARCHIVE_V_2' | 'EPHEMERAL_ALLOW_GROUP_MEMBERS' | 'EPHEMERAL_24_H_DURATION' | 'MD_FORCE_UPGRADE' | 'DISAPPEARING_MODE' | 'EXTERNAL_MD_OPT_IN_AVAILABLE' | 'ARCHIVE_BROADCAST' | 'RECENT_EMOJI_SYNC' | 'STARRED_GIFS' | 'INDEX_RECEIVED_VCARD' | 'STATUS_V3_UI_SENDING' | 'MEDIAS_COUNT' | 'VOIP_VOICE_CALL' | 'DESKTOP_VOIP_VOICE_CALL' | 'DESKTOP_VOIP_VIDEO_CALL' | 'DESKTOP_VOIP_GROUP_VOICE_CALL' | 'DESKTOP_VOIP_GROUP_VIDEO_CALL' | 'KEY_PARTICIPANT' | 'RICH_TEXT';
18
- /**
19
- * @whatsapp 2.2132.6:77188
20
- */
21
18
  declare class FeatureClass extends EventEmitter {
22
19
  FEATURE_CHANGE_EVENT: string;
23
20
  F: {
@@ -63,8 +60,6 @@ declare class FeatureClass extends EventEmitter {
63
60
  isGroupCatchUpEnabled(): boolean;
64
61
  isInAppSupportEnabled(): boolean;
65
62
  }
66
- /**
67
- * @whatsapp 2.2138.10:12950
68
- */
63
+ /** @whatsapp 2.2140.7:12950 */
69
64
  export declare const Features: FeatureClass;
70
65
  export {};
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:49288
18
- */
16
+ /** @whatsapp 2.2140.7:49288 */
19
17
  export declare namespace ImageUtils {
20
18
  function rotateAndResize(e: any, t: any, r: any): Promise<{
21
19
  width: number;
@@ -13,9 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- /**
17
- * @whatsapp 2.2138.10:63063
18
- */
16
+ /** @whatsapp 2.2140.7:63063 */
19
17
  export declare namespace MediaUtils {
20
18
  function getImageWidthHeight(): Promise<{
21
19
  width: number;
@@ -14,9 +14,7 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  import { Wid } from './Wid';
17
- /**
18
- * @whatsapp 2.2138.10:77043
19
- */
17
+ /** @whatsapp 2.2140.7:77043 */
20
18
  export declare class MsgKey {
21
19
  constructor(options: {
22
20
  from: Wid;
@@ -15,9 +15,7 @@
15
15
  */
16
16
  import { CollectionCache } from '../collections';
17
17
  import { Model, MsgModel } from '../models';
18
- /**
19
- * @whatsapp 2.2138.10:97490
20
- */
18
+ /** @whatsapp 2.2140.7:97490 */
21
19
  export declare class MsgLoadState extends Model {
22
20
  noEarlierMsgs: any;
23
21
  isLoadingEarlierMsgs: any;
@@ -25,9 +23,10 @@ export declare class MsgLoadState extends Model {
25
23
  isLoadingAroundMsgs: any;
26
24
  contextLoaded: any;
27
25
  }
28
- /**
29
- * @whatsapp 2.2138.10:97490
30
- */
26
+ /** @whatsapp 2.2140.7:97490 */
31
27
  export declare class MsgLoad extends CollectionCache<MsgModel> {
32
28
  msgLoadState: MsgLoadState;
29
+ loadRecentPromise?: Promise<any>;
30
+ loadEarlierPromise?: Promise<any>;
31
+ loadAroundPromise?: Promise<any>;
33
32
  }