lemmy-js-client 0.19.0-rc.11 → 0.19.0-rc.12

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/dist/http.d.ts CHANGED
@@ -126,6 +126,8 @@ import { VerifyEmail } from "./types/VerifyEmail";
126
126
  import { VerifyEmailResponse } from "./types/VerifyEmailResponse";
127
127
  import { UploadImage, UploadImageResponse } from "./types/others";
128
128
  import { HideCommunity } from "./types/HideCommunity";
129
+ import { BlockInstance } from "./types/BlockInstance";
130
+ import { BlockInstanceResponse } from "./types/BlockInstanceResponse";
129
131
  /**
130
132
  * Helps build lemmy HTTP requests.
131
133
  */
@@ -658,6 +660,12 @@ export declare class LemmyHttp {
658
660
  * `HTTP.Get /federated_instances`
659
661
  */
660
662
  getFederatedInstances(): Promise<GetFederatedInstancesResponse>;
663
+ /**
664
+ * Block an instance.
665
+ *
666
+ * `HTTP.Post /site/block`
667
+ */
668
+ blockInstance(form: BlockInstance): Promise<BlockInstanceResponse>;
661
669
  /**
662
670
  * Upload an image to the server.
663
671
  */
package/dist/http.js CHANGED
@@ -746,6 +746,14 @@ class LemmyHttp {
746
746
  getFederatedInstances() {
747
747
  return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Get, "/federated_instances", {});
748
748
  }
749
+ /**
750
+ * Block an instance.
751
+ *
752
+ * `HTTP.Post /site/block`
753
+ */
754
+ blockInstance(form) {
755
+ return __classPrivateFieldGet(this, _LemmyHttp_instances, "m", _LemmyHttp_wrapper).call(this, HttpType.Post, "/site/block", form);
756
+ }
749
757
  /**
750
758
  * Upload an image to the server.
751
759
  */
@@ -2,5 +2,4 @@ import type { InstanceId } from "./InstanceId";
2
2
  export interface BlockInstance {
3
3
  instance_id: InstanceId;
4
4
  block: boolean;
5
- auth: string;
6
5
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lemmy-js-client",
3
- "version": "0.19.0-rc.11",
3
+ "version": "0.19.0-rc.12",
4
4
  "description": "A javascript / typescript client for Lemmy",
5
5
  "repository": "https://github.com/LemmyNet/lemmy-js-client",
6
6
  "license": "AGPL-3.0",