@wppconnect/wa-js 3.18.0 → 3.18.1

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/CHANGELOG.md CHANGED
@@ -1,4 +1,4 @@
1
- # 3.18.0 (2025-07-23)
1
+ ## 3.18.1 (2025-08-26)
2
2
 
3
3
 
4
4
 
@@ -164,7 +164,7 @@ export interface VideoMessageOptions extends FileMessageOptions, MessageButtonsO
164
164
  * // A simple video
165
165
  * WPP.chat.sendFileMessage(
166
166
  * '[number]@c.us',
167
- * 'data:application/msword;base64,<a long base64 file...>',
167
+ * 'data:video/mp4;base64,<a long base64 file...>',
168
168
  * {
169
169
  * type: 'video',
170
170
  * }
@@ -173,7 +173,7 @@ export interface VideoMessageOptions extends FileMessageOptions, MessageButtonsO
173
173
  * // A PTV Video (micro video)
174
174
  * WPP.chat.sendFileMessage(
175
175
  * '[number]@c.us',
176
- * 'data:application/msword;base64,<a long base64 file...>',
176
+ * 'data:video/mp4;base64,<a long base64 file...>',
177
177
  * {
178
178
  * type: 'video',
179
179
  * isPtv: true,
@@ -23,11 +23,11 @@ import { BusinessProfileModel } from '../../whatsapp';
23
23
  * ```
24
24
  *
25
25
  * ```javascript
26
- * await WPP.profile.editBusinessProfile({categories: {
26
+ * await WPP.profile.editBusinessProfile({categories: [{
27
27
  id: "133436743388217",
28
28
  localized_display_name: "Artes e entretenimento",
29
29
  not_a_biz: false,
30
- }});
30
+ }]});
31
31
  * ```
32
32
  *
33
33
  * ```javascript
@@ -144,31 +144,65 @@ import { BusinessProfileModel } from '../../whatsapp';
144
144
  *
145
145
  * Change businessHours for Appointment Only
146
146
  * ```javascript
147
- * await WPP.profile.editBusinessProfile({ businessHours: { {
148
- mon: {
149
- mode: "appointment_only",
147
+ * await WPP.profile.editBusinessProfile({ {
148
+ "config": {
149
+ "mon": {
150
+ "mode": "specific_hours",
151
+ "hours": [
152
+ [
153
+ 480,
154
+ 1260
155
+ ]
156
+ ]
157
+ },
158
+ "tue": {
159
+ "mode": "specific_hours",
160
+ "hours": [
161
+ [
162
+ 480,
163
+ 1260
164
+ ]
165
+ ]
166
+ },
167
+ "wed": {
168
+ "mode": "specific_hours",
169
+ "hours": [
170
+ [
171
+ 480,
172
+ 1260
173
+ ]
174
+ ]
175
+ },
176
+ "thu": {
177
+ "mode": "specific_hours",
178
+ "hours": [
179
+ [
180
+ 480,
181
+ 1260
182
+ ]
183
+ ]
184
+ },
185
+ "fri": {
186
+ "mode": "specific_hours",
187
+ "hours": [
188
+ [
189
+ 480,
190
+ 1260
191
+ ]
192
+ ]
193
+ },
194
+ "sat": {
195
+ "mode": "specific_hours",
196
+ "hours": [
197
+ [
198
+ 660,
199
+ 1320
200
+ ]
201
+ ]
202
+ }
150
203
  },
151
- tue: {
152
- mode: "appointment_only",
153
- },
154
- wed: {
155
- mode: "appointment_only",
156
- },
157
- thu: {
158
- mode: "appointment_only",
159
- },
160
- fri: {
161
- mode: "appointment_only",
162
- },
163
- sat: {
164
- mode: "appointment_only",
165
- },
166
- sun: {
167
- mode: "appointment_only",
168
- },
169
- }
170
- timezone: "America/Sao_Paulo"
171
- });
204
+ "timezone": "America/Sao_Paulo"
205
+ });
172
206
  *
173
207
  *
174
208
  * ```
@@ -18,4 +18,4 @@ export interface ProductVisibilitySetParams {
18
18
  productId: number;
19
19
  }
20
20
  /** @whatsapp 621374 >= 2.2228.14 */
21
- export declare function productVisibilitySet(params: ProductVisibilitySetParams[]): any;
21
+ export declare function productVisibilitySet(productId: string, isHidden: boolean): any;
@@ -29,5 +29,8 @@ export declare namespace WidFactory {
29
29
  function isWidlike(wid: any): wid is Wid;
30
30
  function toChatWid(wid: Wid): Wid;
31
31
  function toUserWid(wid: Wid): Wid;
32
+ function toGroupWid(wid: Wid): Wid;
32
33
  function userJidToUserWid(wid: string): Wid;
34
+ function toUserLidOrThrow(wid: Wid): Wid;
35
+ function toUserWidOrThrow(wid: Wid): Wid;
33
36
  }