@imaentity/selfjs 3.1.0 → 3.2.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.
package/changelog.log CHANGED
@@ -26,4 +26,8 @@ V3.1.0
26
26
  Client.createServer to create a server
27
27
 
28
28
  Changed:
29
- Client.getUser now gets the actual user instead of their profile
29
+ Client.getUser now gets the actual user instead of their profile
30
+
31
+ V3.2.0
32
+ Added:
33
+ Client.refreshURL to refresh expired urls
package/docs.md CHANGED
@@ -468,4 +468,13 @@ Welcome To SelfJS Documentation
468
468
  <br>Example:
469
469
  ```javascript
470
470
  client.transferOwnership("01234567891011121314", "41312111019876543210");
471
+ ```
472
+
473
+ + ### 🔁 refreshURL
474
+ Refreshes an expired attachment url.
475
+ >Paramaters: url (String)
476
+
477
+ <br>Example:
478
+ ```javascript
479
+ client.refreshURL();
471
480
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@imaentity/selfjs",
3
- "version": "3.1.0",
3
+ "version": "3.2.0",
4
4
  "description": "Breaking Discord's TOS to bot user accounts.",
5
5
  "main": "self.js",
6
6
  "repository": {
package/self.js CHANGED
@@ -2,7 +2,7 @@
2
2
  * @name SelfJS
3
3
  * @description Breaking Discord's TOS to bot user accounts.
4
4
  * @author Эмберс
5
- * @version 3.1.0
5
+ * @version 3.2.0
6
6
  */
7
7
 
8
8
  const https = require("https");
@@ -777,5 +777,15 @@ module.exports = {
777
777
  }
778
778
  });
779
779
  }
780
+
781
+ async refreshURL(url) {
782
+ return await this.makeRequest({
783
+ method: "POST",
784
+ path: "/api/v10/attachments/refresh-urls",
785
+ body: {
786
+ attachment_urls: [url]
787
+ }
788
+ });
789
+ }
780
790
  }
781
791
  };