lemmy-js-client 1.0.0-instance-user-blocking.2 → 1.0.0-instance-user-blocking.5

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.
@@ -22,11 +22,10 @@ export type CommentReplyView = {
22
22
  comment_actions?: CommentActions;
23
23
  person_actions?: PersonActions;
24
24
  instance_actions?: InstanceActions;
25
- creator_home_instance_actions?: InstanceActions;
26
- creator_local_instance_actions?: InstanceActions;
27
- creator_community_actions?: CommunityActions;
28
25
  creator_is_admin: boolean;
29
26
  post_tags: TagsView;
30
27
  can_mod: boolean;
31
28
  creator_banned: boolean;
29
+ creator_is_moderator: boolean;
30
+ creator_banned_from_community: boolean;
32
31
  };
@@ -18,7 +18,6 @@ export type CommentReportView = {
18
18
  comment_creator: Person;
19
19
  comment_actions?: CommentActions;
20
20
  resolver?: Person;
21
- creator_community_actions?: CommunityActions;
22
21
  person_actions?: PersonActions;
23
22
  community_actions?: CommunityActions;
24
23
  creator_is_admin: boolean;
@@ -1,6 +1,5 @@
1
1
  import type { Comment } from "./Comment";
2
2
  import type { CommentActions } from "./CommentActions";
3
- import type { CommunityActions } from "./CommunityActions";
4
3
  import type { InstanceActions } from "./InstanceActions";
5
4
  import type { Person } from "./Person";
6
5
  import type { PersonActions } from "./PersonActions";
@@ -12,12 +11,11 @@ export type CommentSlimView = {
12
11
  creator: Person;
13
12
  comment_actions?: CommentActions;
14
13
  person_actions?: PersonActions;
15
- creator_community_actions?: CommunityActions;
16
14
  instance_communities_actions?: InstanceActions;
17
15
  instance_persons_actions?: InstanceActions;
18
- creator_home_instance_actions?: InstanceActions;
19
- creator_local_instance_actions?: InstanceActions;
20
16
  creator_is_admin: boolean;
21
17
  can_mod: boolean;
22
18
  creator_banned: boolean;
19
+ creator_is_moderator: boolean;
20
+ creator_banned_from_community: boolean;
23
21
  };
@@ -20,11 +20,10 @@ export type CommentView = {
20
20
  person_actions?: PersonActions;
21
21
  instance_communities_actions?: InstanceActions;
22
22
  instance_persons_actions?: InstanceActions;
23
- creator_home_instance_actions?: InstanceActions;
24
- creator_local_instance_actions?: InstanceActions;
25
- creator_community_actions?: CommunityActions;
26
23
  creator_is_admin: boolean;
27
24
  post_tags: TagsView;
28
25
  can_mod: boolean;
29
26
  creator_banned: boolean;
27
+ creator_is_moderator: boolean;
28
+ creator_banned_from_community: boolean;
30
29
  };
@@ -28,18 +28,20 @@ export type CreateSite = {
28
28
  discussion_languages?: Array<LanguageId>;
29
29
  slur_filter_regex?: string;
30
30
  actor_name_max_length?: number;
31
- rate_limit_message?: number;
32
- rate_limit_message_per_second?: number;
33
- rate_limit_post?: number;
34
- rate_limit_post_per_second?: number;
35
- rate_limit_register?: number;
36
- rate_limit_register_per_second?: number;
37
- rate_limit_image?: number;
38
- rate_limit_image_per_second?: number;
39
- rate_limit_comment?: number;
40
- rate_limit_comment_per_second?: number;
41
- rate_limit_search?: number;
42
- rate_limit_search_per_second?: number;
31
+ rate_limit_message_max_requests?: number;
32
+ rate_limit_message_interval_seconds?: number;
33
+ rate_limit_post_max_requests?: number;
34
+ rate_limit_post_interval_seconds?: number;
35
+ rate_limit_register_max_requests?: number;
36
+ rate_limit_register_interval_seconds?: number;
37
+ rate_limit_image_max_requests?: number;
38
+ rate_limit_image_interval_seconds?: number;
39
+ rate_limit_comment_max_requests?: number;
40
+ rate_limit_comment_interval_seconds?: number;
41
+ rate_limit_search_max_requests?: number;
42
+ rate_limit_search_interval_seconds?: number;
43
+ rate_limit_import_user_settings_max_requests?: number;
44
+ rate_limit_import_user_settings_interval_seconds?: number;
43
45
  federation_enabled?: boolean;
44
46
  captcha_enabled?: boolean;
45
47
  captcha_difficulty?: string;
@@ -82,33 +82,38 @@ export type EditSite = {
82
82
  /**
83
83
  * The number of messages allowed in a given time frame.
84
84
  */
85
- rate_limit_message?: number;
86
- rate_limit_message_per_second?: number;
85
+ rate_limit_message_max_requests?: number;
86
+ rate_limit_message_interval_seconds?: number;
87
87
  /**
88
88
  * The number of posts allowed in a given time frame.
89
89
  */
90
- rate_limit_post?: number;
91
- rate_limit_post_per_second?: number;
90
+ rate_limit_post_max_requests?: number;
91
+ rate_limit_post_interval_seconds?: number;
92
92
  /**
93
93
  * The number of registrations allowed in a given time frame.
94
94
  */
95
- rate_limit_register?: number;
96
- rate_limit_register_per_second?: number;
95
+ rate_limit_register_max_requests?: number;
96
+ rate_limit_register_interval_seconds?: number;
97
97
  /**
98
98
  * The number of image uploads allowed in a given time frame.
99
99
  */
100
- rate_limit_image?: number;
101
- rate_limit_image_per_second?: number;
100
+ rate_limit_image_max_requests?: number;
101
+ rate_limit_image_interval_seconds?: number;
102
102
  /**
103
103
  * The number of comments allowed in a given time frame.
104
104
  */
105
- rate_limit_comment?: number;
106
- rate_limit_comment_per_second?: number;
105
+ rate_limit_comment_max_requests?: number;
106
+ rate_limit_comment_interval_seconds?: number;
107
107
  /**
108
108
  * The number of searches allowed in a given time frame.
109
109
  */
110
- rate_limit_search?: number;
111
- rate_limit_search_per_second?: number;
110
+ rate_limit_search_max_requests?: number;
111
+ rate_limit_search_interval_seconds?: number;
112
+ /**
113
+ * The number of settings imports or exports allowed in a given time frame.
114
+ */
115
+ rate_limit_import_user_settings_max_requests?: number;
116
+ rate_limit_import_user_settings_interval_seconds?: number;
112
117
  /**
113
118
  * Whether to enable federation.
114
119
  */
@@ -134,8 +134,6 @@ export type LemmyErrorType = {
134
134
  } | {
135
135
  error: "invalid_email_address";
136
136
  message: string;
137
- } | {
138
- error: "rate_limit_error";
139
137
  } | {
140
138
  error: "invalid_name";
141
139
  } | {
@@ -242,9 +240,9 @@ export type LemmyErrorType = {
242
240
  } | {
243
241
  error: "contradicting_filters";
244
242
  } | {
245
- error: "instance_block_communities_already_exists";
243
+ error: "instance_communities_block_error";
246
244
  } | {
247
- error: "instance_block_persons_already_exists";
245
+ error: "instance_persons_block_error";
248
246
  } | {
249
247
  error: "too_many_items";
250
248
  } | {
@@ -3,7 +3,7 @@ import type { PostId } from "./PostId";
3
3
  export type LocalImage = {
4
4
  pictrs_alias: string;
5
5
  published_at: string;
6
- person_id: PersonId;
6
+ person_id?: PersonId;
7
7
  /**
8
8
  * This means the image is an auto-generated thumbnail, for a post.
9
9
  */
@@ -4,20 +4,20 @@ import type { LocalSiteId } from "./LocalSiteId";
4
4
  */
5
5
  export type LocalSiteRateLimit = {
6
6
  local_site_id: LocalSiteId;
7
- message: number;
8
- message_per_second: number;
9
- post: number;
10
- post_per_second: number;
11
- register: number;
12
- register_per_second: number;
13
- image: number;
14
- image_per_second: number;
15
- comment: number;
16
- comment_per_second: number;
17
- search: number;
18
- search_per_second: number;
7
+ message_max_requests: number;
8
+ message_interval_seconds: number;
9
+ post_max_requests: number;
10
+ post_interval_seconds: number;
11
+ register_max_requests: number;
12
+ register_interval_seconds: number;
13
+ image_max_requests: number;
14
+ image_interval_seconds: number;
15
+ comment_max_requests: number;
16
+ comment_interval_seconds: number;
17
+ search_max_requests: number;
18
+ search_interval_seconds: number;
19
19
  published_at: string;
20
20
  updated_at?: string;
21
- import_user_settings: number;
22
- import_user_settings_per_second: number;
21
+ import_user_settings_max_requests: number;
22
+ import_user_settings_interval_seconds: number;
23
23
  };
@@ -1,4 +1,3 @@
1
- import type { InstanceActions } from "./InstanceActions";
2
1
  import type { LocalUser } from "./LocalUser";
3
2
  import type { Person } from "./Person";
4
3
  /**
@@ -7,5 +6,5 @@ import type { Person } from "./Person";
7
6
  export type LocalUserView = {
8
7
  local_user: LocalUser;
9
8
  person: Person;
10
- instance_actions?: InstanceActions;
9
+ banned: boolean;
11
10
  };
@@ -21,10 +21,9 @@ export type PersonCommentMentionView = {
21
21
  comment_actions?: CommentActions;
22
22
  person_actions?: PersonActions;
23
23
  instance_actions?: InstanceActions;
24
- creator_home_instance_actions?: InstanceActions;
25
- creator_local_instance_actions?: InstanceActions;
26
- creator_community_actions?: CommunityActions;
27
24
  creator_is_admin: boolean;
28
25
  can_mod: boolean;
29
26
  creator_banned: boolean;
27
+ creator_is_moderator: boolean;
28
+ creator_banned_from_community: boolean;
30
29
  };
@@ -22,11 +22,10 @@ export type PersonPostMentionView = {
22
22
  person_actions?: PersonActions;
23
23
  post_actions?: PostActions;
24
24
  instance_actions?: InstanceActions;
25
- creator_home_instance_actions?: InstanceActions;
26
- creator_local_instance_actions?: InstanceActions;
27
- creator_community_actions?: CommunityActions;
28
25
  post_tags: TagsView;
29
26
  creator_is_admin: boolean;
30
27
  can_mod: boolean;
31
28
  creator_banned: boolean;
29
+ creator_is_moderator: boolean;
30
+ creator_banned_from_community: boolean;
32
31
  };
@@ -1,4 +1,3 @@
1
- import type { InstanceActions } from "./InstanceActions";
2
1
  import type { Person } from "./Person";
3
2
  import type { PersonActions } from "./PersonActions";
4
3
  /**
@@ -8,7 +7,5 @@ export type PersonView = {
8
7
  person: Person;
9
8
  is_admin: boolean;
10
9
  person_actions?: PersonActions;
11
- home_instance_actions?: InstanceActions;
12
- local_instance_actions?: InstanceActions;
13
10
  creator_banned: boolean;
14
11
  };
@@ -14,7 +14,6 @@ export type PostReportView = {
14
14
  community: Community;
15
15
  creator: Person;
16
16
  post_creator: Person;
17
- creator_community_actions?: CommunityActions;
18
17
  community_actions?: CommunityActions;
19
18
  post_actions?: PostActions;
20
19
  person_actions?: PersonActions;
@@ -20,11 +20,10 @@ export type PostView = {
20
20
  post_actions?: PostActions;
21
21
  instance_communities_actions?: InstanceActions;
22
22
  instance_persons_actions?: InstanceActions;
23
- creator_home_instance_actions?: InstanceActions;
24
- creator_local_instance_actions?: InstanceActions;
25
- creator_community_actions?: CommunityActions;
26
23
  creator_is_admin: boolean;
27
24
  tags: TagsView;
28
25
  can_mod: boolean;
29
26
  creator_banned: boolean;
27
+ creator_is_moderator: boolean;
28
+ creator_banned_from_community: boolean;
30
29
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "lemmy-js-client",
3
3
  "description": "A javascript / typescript client for Lemmy",
4
- "version": "1.0.0-instance-user-blocking.2",
4
+ "version": "1.0.0-instance-user-blocking.5",
5
5
  "author": "Dessalines",
6
6
  "license": "AGPL-3.0",
7
7
  "main": "./dist/index.js",