@open-wa/wa-automate 4.57.0 → 4.58.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.
@@ -549,6 +549,16 @@ export declare class Client {
549
549
  * @param mentions You can optionally add an array of contact IDs to tag only specific people
550
550
  */
551
551
  sendTextWithMentions(to: ChatId, content: Content, hideTags?: boolean, mentions?: ContactId[]): Promise<boolean | MessageId>;
552
+ /**
553
+ * NOTE: This is experimental, most accounts do not have access to this feature in their apps.
554
+ *
555
+ * Edit an existing message
556
+ *
557
+ * @param messageId The message ID to edit
558
+ * @param text The new text content
559
+ * @returns
560
+ */
561
+ editMessage(messageId: MessageId, text: Content): Promise<boolean | MessageId>;
552
562
  /**
553
563
  * [UNTESTED - REQUIRES FEEDBACK]
554
564
  * Sends a payment request message to given chat
@@ -1476,6 +1476,22 @@ class Client {
1476
1476
  }, { to, content, hideTags, mentions });
1477
1477
  });
1478
1478
  }
1479
+ /**
1480
+ * NOTE: This is experimental, most accounts do not have access to this feature in their apps.
1481
+ *
1482
+ * Edit an existing message
1483
+ *
1484
+ * @param messageId The message ID to edit
1485
+ * @param text The new text content
1486
+ * @returns
1487
+ */
1488
+ editMessage(messageId, text) {
1489
+ return __awaiter(this, void 0, void 0, function* () {
1490
+ return yield this.pup(({ messageId, text }) => {
1491
+ return WAPI.editMessage(messageId, text);
1492
+ }, { messageId, text });
1493
+ });
1494
+ }
1479
1495
  /**
1480
1496
  * [UNTESTED - REQUIRES FEEDBACK]
1481
1497
  * Sends a payment request message to given chat
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-wa/wa-automate",
3
- "version": "4.57.0",
3
+ "version": "4.58.0",
4
4
  "licenseCheckUrl": "https://funcs.openwa.dev/license-check",
5
5
  "brokenMethodReportUrl": "https://funcs.openwa.dev/report-bm",
6
6
  "patches": "https://cdn.openwa.dev/patches.json",