@open-wa/wa-automate 4.75.0 → 4.76.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.
@@ -1540,6 +1540,24 @@ export declare class Client {
1540
1540
  * @returns
1541
1541
  */
1542
1542
  inviteInfo(link: string): Promise<any>;
1543
+ /**
1544
+ * Set/Unset a sticker as a fav.
1545
+ * @param msgId The message Id related to the sticker you want to fav
1546
+ * @param fav set this to true to fav a sticker, set it to false to remove the sticker from favorites. default true
1547
+ * @returns favId The ID (filehash) of the fav sticker
1548
+ */
1549
+ favSticker(msgId: MessageId, fav?: boolean): Promise<string>;
1550
+ /**
1551
+ * Set/Unset a sticker as a fav.
1552
+ * @param chatId The chat in which you want to send the sticker
1553
+ * @param favId set this to true to favourite a sticker, set it to false to remove the sticker from favorites
1554
+ * @returns MessageId of the sent sticker message
1555
+ */
1556
+ sendFavSticker(chatId: ChatId, favId: string): Promise<MessageId>;
1557
+ /**
1558
+ * Get an array of fav'ed stickers
1559
+ */
1560
+ getFavStickers(): Promise<Partial<Message>>;
1543
1561
  /**
1544
1562
  * Revokes the current invite link for a group chat. Any previous links will stop working
1545
1563
  * @param chatId
@@ -3105,6 +3105,36 @@ class Client {
3105
3105
  return yield this.pup(link => WAPI.inviteInfo(link), link);
3106
3106
  });
3107
3107
  }
3108
+ /**
3109
+ * Set/Unset a sticker as a fav.
3110
+ * @param msgId The message Id related to the sticker you want to fav
3111
+ * @param fav set this to true to fav a sticker, set it to false to remove the sticker from favorites. default true
3112
+ * @returns favId The ID (filehash) of the fav sticker
3113
+ */
3114
+ favSticker(msgId, fav = true) {
3115
+ return __awaiter(this, void 0, void 0, function* () {
3116
+ return yield this.pup(({ msgId, fav }) => WAPI.favSticker(msgId, fav), { msgId, fav });
3117
+ });
3118
+ }
3119
+ /**
3120
+ * Set/Unset a sticker as a fav.
3121
+ * @param chatId The chat in which you want to send the sticker
3122
+ * @param favId set this to true to favourite a sticker, set it to false to remove the sticker from favorites
3123
+ * @returns MessageId of the sent sticker message
3124
+ */
3125
+ sendFavSticker(chatId, favId) {
3126
+ return __awaiter(this, void 0, void 0, function* () {
3127
+ return yield this.pup(({ chatId, favId }) => WAPI.sendFavSticker(chatId, favId), { chatId, favId });
3128
+ });
3129
+ }
3130
+ /**
3131
+ * Get an array of fav'ed stickers
3132
+ */
3133
+ getFavStickers() {
3134
+ return __awaiter(this, void 0, void 0, function* () {
3135
+ return yield this.pup(() => WAPI.getFavStickers());
3136
+ });
3137
+ }
3108
3138
  /**
3109
3139
  * Revokes the current invite link for a group chat. Any previous links will stop working
3110
3140
  * @param chatId
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-wa/wa-automate",
3
- "version": "4.75.0",
3
+ "version": "4.76.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",