@poucode/baileys 1.0.2 → 2.0.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.
Files changed (32) hide show
  1. package/README.md +21 -2
  2. package/lib/Socket/chats.js +5 -0
  3. package/lib/Socket/graphql.js +716 -0
  4. package/lib/Socket/index.js +10 -2
  5. package/lib/Socket/interop.js +463 -0
  6. package/lib/Socket/luxu.js +1 -1
  7. package/lib/Socket/message-builder.js +475 -0
  8. package/lib/Socket/messages-send.js +29 -4
  9. package/lib/Socket/privacy.js +318 -0
  10. package/lib/Store/make-in-memory-store.js +47 -1
  11. package/lib/Utils/index.js +1 -0
  12. package/lib/Utils/messages-media.js +82 -0
  13. package/lib/Utils/messages.js +137 -3
  14. package/lib/Utils/sticker.js +133 -0
  15. package/lib/Utils/use-sqlite-auth-state.js +162 -0
  16. package/lib/WAUSync/Protocols/USyncBusinessProtocol.js +43 -0
  17. package/lib/WAUSync/Protocols/USyncContactProtocol.js +53 -50
  18. package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +56 -52
  19. package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +29 -25
  20. package/lib/WAUSync/Protocols/USyncFeatureProtocol.js +58 -0
  21. package/lib/WAUSync/Protocols/USyncPictureProtocol.js +32 -0
  22. package/lib/WAUSync/Protocols/USyncSidelistProtocol.js +28 -0
  23. package/lib/WAUSync/Protocols/USyncStatusProtocol.js +38 -36
  24. package/lib/WAUSync/Protocols/USyncTextStatusProtocol.js +38 -0
  25. package/lib/WAUSync/Protocols/USyncUsernameProtocol.js +26 -23
  26. package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +52 -49
  27. package/lib/WAUSync/Protocols/UsyncLIDProtocol.js +29 -27
  28. package/lib/WAUSync/Protocols/index.js +12 -5
  29. package/lib/WAUSync/USyncQuery.js +150 -96
  30. package/lib/WAUSync/USyncUser.js +55 -29
  31. package/lib/WAUSync/index.js +3 -3
  32. package/package.json +5 -3
@@ -1,30 +1,56 @@
1
1
  export class USyncUser {
2
- withId(id) {
3
- this.id = id;
4
- return this;
5
- }
6
- withLid(lid) {
7
- this.lid = lid;
8
- return this;
9
- }
10
- withPhone(phone) {
11
- this.phone = phone;
12
- return this;
13
- }
14
- withUsername(username) {
15
- this.username = username;
16
- return this;
17
- }
18
- withUsernameKey(usernameKey) {
19
- this.usernameKey = usernameKey;
20
- return this;
21
- }
22
- withType(type) {
23
- this.type = type;
24
- return this;
25
- }
26
- withPersonaId(personaId) {
27
- this.personaId = personaId;
28
- return this;
29
- }
30
- }
2
+ withId(id) {
3
+ this.id = id
4
+ return this
5
+ }
6
+
7
+ withLid(lid) {
8
+ this.lid = lid
9
+ return this
10
+ }
11
+
12
+ withPhone(phone) {
13
+ this.phone = phone
14
+ return this
15
+ }
16
+
17
+ withUsername(username) {
18
+ this.username = username
19
+ return this
20
+ }
21
+
22
+ withUsernameKey(usernameKey) {
23
+ this.usernameKey = usernameKey
24
+ return this
25
+ }
26
+
27
+ withType(type) {
28
+ this.type = type
29
+ return this
30
+ }
31
+
32
+ withPersonaId(personaId) {
33
+ this.personaId = personaId
34
+ return this
35
+ }
36
+
37
+ withPictureId(pictureId) {
38
+ this.pictureId = pictureId
39
+ return this
40
+ }
41
+
42
+ withVerifiedNameSerial(serial) {
43
+ this.verifiedNameSerial = serial
44
+ return this
45
+ }
46
+
47
+ withBusinessProfileTag(tag) {
48
+ this.businessProfileTag = tag
49
+ return this
50
+ }
51
+
52
+ withSidelistDelete(del = true) {
53
+ this.sidelistDelete = del
54
+ return this
55
+ }
56
+ }
@@ -1,3 +1,3 @@
1
- export * from './Protocols/index.js';
2
- export * from './USyncQuery.js';
3
- export * from './USyncUser.js';
1
+ export * from './Protocols/index.js'
2
+ export * from './USyncQuery.js'
3
+ export * from './USyncUser.js'
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@poucode/baileys",
3
3
  "type": "module",
4
- "version": "1.0.2",
5
- "description": "A WebSockets library for interacting with WhatsApp Web — PouCode fork of Baileys",
4
+ "version": "2.0.0",
5
+ "description": "WaBail — PouCode fork of Baileys: WhatsApp Web WebSocket library with merged extra socket layers (privacy, interop, GraphQL, message builder), sticker packs and SQLite auth state",
6
6
  "keywords": [
7
7
  "poucode",
8
8
  "baileys",
@@ -10,7 +10,9 @@
10
10
  "whatsapp-api",
11
11
  "whatsapp-web",
12
12
  "wa-bot",
13
- "whatsapp bot"
13
+ "whatsapp bot",
14
+ "wabail",
15
+ "whatsapp-bot"
14
16
  ],
15
17
  "homepage": "https://github.com/pou-code/WaBail",
16
18
  "repository": {