lemmy-js-client 0.17.0-rc.3 → 0.17.0-rc.30
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/http.d.ts +156 -4
- package/dist/http.js +255 -80
- package/dist/index.d.ts +1 -0
- package/dist/index.js +6 -1
- package/dist/interfaces/api/comment.d.ts +46 -38
- package/dist/interfaces/api/comment.js +326 -0
- package/dist/interfaces/api/community.d.ts +57 -55
- package/dist/interfaces/api/community.js +433 -0
- package/dist/interfaces/api/index.js +5 -1
- package/dist/interfaces/api/person.d.ts +121 -100
- package/dist/interfaces/api/person.js +894 -0
- package/dist/interfaces/api/post.d.ts +68 -51
- package/dist/interfaces/api/post.js +434 -0
- package/dist/interfaces/api/site.d.ts +100 -90
- package/dist/interfaces/api/site.js +893 -0
- package/dist/interfaces/index.js +5 -1
- package/dist/interfaces/others.d.ts +62 -92
- package/dist/interfaces/others.js +118 -55
- package/dist/interfaces/source.d.ts +79 -76
- package/dist/interfaces/source.js +746 -0
- package/dist/interfaces/views.d.ts +37 -37
- package/dist/interfaces/views.js +522 -0
- package/dist/utils.d.ts +9 -0
- package/dist/utils.js +18 -0
- package/dist/websocket.d.ts +13 -2
- package/dist/websocket.js +23 -5
- package/package.json +14 -11
@@ -1,7 +1,8 @@
|
|
1
|
-
|
1
|
+
import { Option } from "@sniptt/monads";
|
2
|
+
export declare class LocalUserSettings {
|
2
3
|
id: number;
|
3
4
|
person_id: number;
|
4
|
-
email
|
5
|
+
email: Option<string>;
|
5
6
|
show_nsfw: boolean;
|
6
7
|
theme: string;
|
7
8
|
default_sort_type: number;
|
@@ -16,50 +17,52 @@ export interface LocalUserSettings {
|
|
16
17
|
email_verified: boolean;
|
17
18
|
accepted_application: boolean;
|
18
19
|
}
|
19
|
-
export
|
20
|
+
export declare class PersonSafe {
|
20
21
|
id: number;
|
21
22
|
name: string;
|
22
|
-
display_name
|
23
|
-
avatar
|
23
|
+
display_name: Option<string>;
|
24
|
+
avatar: Option<string>;
|
24
25
|
banned: boolean;
|
25
26
|
published: string;
|
26
|
-
updated
|
27
|
+
updated: Option<string>;
|
27
28
|
actor_id: string;
|
28
|
-
bio
|
29
|
+
bio: Option<string>;
|
29
30
|
local: boolean;
|
30
|
-
banner
|
31
|
+
banner: Option<string>;
|
31
32
|
deleted: boolean;
|
32
33
|
inbox_url: string;
|
33
34
|
shared_inbox_url: string;
|
34
|
-
matrix_user_id
|
35
|
+
matrix_user_id: Option<string>;
|
35
36
|
admin: boolean;
|
36
37
|
bot_account: boolean;
|
37
|
-
ban_expires
|
38
|
+
ban_expires: Option<string>;
|
38
39
|
}
|
39
|
-
export
|
40
|
+
export declare class Site {
|
40
41
|
id: number;
|
41
42
|
name: string;
|
42
|
-
sidebar
|
43
|
+
sidebar: Option<string>;
|
43
44
|
published: string;
|
44
|
-
updated
|
45
|
+
updated: Option<string>;
|
45
46
|
enable_downvotes: boolean;
|
46
47
|
open_registration: boolean;
|
47
48
|
enable_nsfw: boolean;
|
48
|
-
icon
|
49
|
-
banner
|
50
|
-
description
|
49
|
+
icon: Option<string>;
|
50
|
+
banner: Option<string>;
|
51
|
+
description: Option<string>;
|
51
52
|
community_creation_admin_only: boolean;
|
52
53
|
require_email_verification: boolean;
|
53
54
|
require_application: boolean;
|
54
|
-
application_question
|
55
|
+
application_question: Option<string>;
|
55
56
|
private_instance: boolean;
|
56
57
|
default_theme: string;
|
58
|
+
default_post_listing_type: string;
|
57
59
|
actor_id: string;
|
58
60
|
last_refreshed_at: string;
|
59
61
|
inbox_url: string;
|
60
62
|
public_key: string;
|
63
|
+
legal_information: Option<string>;
|
61
64
|
}
|
62
|
-
export
|
65
|
+
export declare class PrivateMessage {
|
63
66
|
id: number;
|
64
67
|
creator_id: number;
|
65
68
|
recipient_id: number;
|
@@ -67,184 +70,184 @@ export interface PrivateMessage {
|
|
67
70
|
deleted: boolean;
|
68
71
|
read: boolean;
|
69
72
|
published: string;
|
70
|
-
updated
|
73
|
+
updated: Option<string>;
|
71
74
|
ap_id: string;
|
72
75
|
local: boolean;
|
73
76
|
}
|
74
|
-
export
|
77
|
+
export declare class PostReport {
|
75
78
|
id: number;
|
76
79
|
creator_id: number;
|
77
80
|
post_id: number;
|
78
81
|
original_post_name: string;
|
79
|
-
original_post_url
|
80
|
-
original_post_body
|
82
|
+
original_post_url: Option<string>;
|
83
|
+
original_post_body: Option<string>;
|
81
84
|
reason: string;
|
82
85
|
resolved: boolean;
|
83
|
-
resolver_id
|
86
|
+
resolver_id: Option<number>;
|
84
87
|
published: string;
|
85
|
-
updated
|
88
|
+
updated: Option<string>;
|
86
89
|
}
|
87
|
-
export
|
90
|
+
export declare class Post {
|
88
91
|
id: number;
|
89
92
|
name: string;
|
90
|
-
url
|
91
|
-
body
|
93
|
+
url: Option<string>;
|
94
|
+
body: Option<string>;
|
92
95
|
creator_id: number;
|
93
96
|
community_id: number;
|
94
97
|
removed: boolean;
|
95
98
|
locked: boolean;
|
96
99
|
published: string;
|
97
|
-
updated
|
100
|
+
updated: Option<string>;
|
98
101
|
deleted: boolean;
|
99
102
|
nsfw: boolean;
|
100
103
|
stickied: boolean;
|
101
|
-
embed_title
|
102
|
-
embed_description
|
103
|
-
embed_html
|
104
|
-
thumbnail_url
|
104
|
+
embed_title: Option<string>;
|
105
|
+
embed_description: Option<string>;
|
106
|
+
embed_html: Option<string>;
|
107
|
+
thumbnail_url: Option<string>;
|
105
108
|
ap_id: string;
|
106
109
|
local: boolean;
|
107
110
|
}
|
108
|
-
export
|
111
|
+
export declare class PasswordResetRequest {
|
109
112
|
id: number;
|
110
113
|
local_user_id: number;
|
111
114
|
token_encrypted: string;
|
112
115
|
published: string;
|
113
116
|
}
|
114
|
-
export
|
117
|
+
export declare class ModRemovePost {
|
115
118
|
id: number;
|
116
119
|
mod_person_id: number;
|
117
120
|
post_id: number;
|
118
|
-
reason
|
119
|
-
removed
|
121
|
+
reason: Option<string>;
|
122
|
+
removed: Option<boolean>;
|
120
123
|
when_: string;
|
121
124
|
}
|
122
|
-
export
|
125
|
+
export declare class ModLockPost {
|
123
126
|
id: number;
|
124
127
|
mod_person_id: number;
|
125
128
|
post_id: number;
|
126
|
-
locked
|
129
|
+
locked: Option<boolean>;
|
127
130
|
when_: string;
|
128
131
|
}
|
129
|
-
export
|
132
|
+
export declare class ModStickyPost {
|
130
133
|
id: number;
|
131
134
|
mod_person_id: number;
|
132
135
|
post_id: number;
|
133
|
-
stickied
|
136
|
+
stickied: Option<boolean>;
|
134
137
|
when_: string;
|
135
138
|
}
|
136
|
-
export
|
139
|
+
export declare class ModRemoveComment {
|
137
140
|
id: number;
|
138
141
|
mod_person_id: number;
|
139
142
|
comment_id: number;
|
140
|
-
reason
|
141
|
-
removed
|
143
|
+
reason: Option<string>;
|
144
|
+
removed: Option<boolean>;
|
142
145
|
when_: string;
|
143
146
|
}
|
144
|
-
export
|
147
|
+
export declare class ModRemoveCommunity {
|
145
148
|
id: number;
|
146
149
|
mod_person_id: number;
|
147
150
|
community_id: number;
|
148
|
-
reason
|
149
|
-
removed
|
150
|
-
expires
|
151
|
+
reason: Option<string>;
|
152
|
+
removed: Option<boolean>;
|
153
|
+
expires: Option<string>;
|
151
154
|
when_: string;
|
152
155
|
}
|
153
|
-
export
|
156
|
+
export declare class ModBanFromCommunity {
|
154
157
|
id: number;
|
155
158
|
mod_person_id: number;
|
156
159
|
other_person_id: number;
|
157
160
|
community_id: number;
|
158
|
-
reason
|
159
|
-
banned
|
160
|
-
expires
|
161
|
+
reason: Option<string>;
|
162
|
+
banned: Option<boolean>;
|
163
|
+
expires: Option<string>;
|
161
164
|
when_: string;
|
162
165
|
}
|
163
|
-
export
|
166
|
+
export declare class ModBan {
|
164
167
|
id: number;
|
165
168
|
mod_person_id: number;
|
166
169
|
other_person_id: number;
|
167
|
-
reason
|
168
|
-
banned
|
169
|
-
expires
|
170
|
+
reason: Option<string>;
|
171
|
+
banned: Option<boolean>;
|
172
|
+
expires: Option<string>;
|
170
173
|
when_: string;
|
171
174
|
}
|
172
|
-
export
|
175
|
+
export declare class ModAddCommunity {
|
173
176
|
id: number;
|
174
177
|
mod_person_id: number;
|
175
178
|
other_person_id: number;
|
176
179
|
community_id: number;
|
177
|
-
removed
|
180
|
+
removed: Option<boolean>;
|
178
181
|
when_: string;
|
179
182
|
}
|
180
|
-
export
|
183
|
+
export declare class ModTransferCommunity {
|
181
184
|
id: number;
|
182
185
|
mod_person_id: number;
|
183
186
|
other_person_id: number;
|
184
187
|
community_id: number;
|
185
|
-
removed
|
188
|
+
removed: Option<boolean>;
|
186
189
|
when_: string;
|
187
190
|
}
|
188
|
-
export
|
191
|
+
export declare class ModAdd {
|
189
192
|
id: number;
|
190
193
|
mod_person_id: number;
|
191
194
|
other_person_id: number;
|
192
|
-
removed
|
195
|
+
removed: Option<boolean>;
|
193
196
|
when_: string;
|
194
197
|
}
|
195
|
-
export
|
198
|
+
export declare class CommunitySafe {
|
196
199
|
id: number;
|
197
200
|
name: string;
|
198
201
|
title: string;
|
199
|
-
description
|
202
|
+
description: Option<string>;
|
200
203
|
removed: boolean;
|
201
204
|
published: string;
|
202
|
-
updated
|
205
|
+
updated: Option<string>;
|
203
206
|
deleted: boolean;
|
204
207
|
nsfw: boolean;
|
205
208
|
actor_id: string;
|
206
209
|
local: boolean;
|
207
|
-
icon
|
208
|
-
banner
|
210
|
+
icon: Option<string>;
|
211
|
+
banner: Option<string>;
|
209
212
|
posting_restricted_to_mods: boolean;
|
210
213
|
}
|
211
|
-
export
|
214
|
+
export declare class CommentReport {
|
212
215
|
id: number;
|
213
216
|
creator_id: number;
|
214
217
|
comment_id: number;
|
215
218
|
original_comment_text: string;
|
216
219
|
reason: string;
|
217
220
|
resolved: boolean;
|
218
|
-
resolver_id
|
221
|
+
resolver_id: Option<number>;
|
219
222
|
published: string;
|
220
|
-
updated
|
223
|
+
updated: Option<string>;
|
221
224
|
}
|
222
|
-
export
|
225
|
+
export declare class Comment {
|
223
226
|
id: number;
|
224
227
|
creator_id: number;
|
225
228
|
post_id: number;
|
226
|
-
parent_id
|
229
|
+
parent_id: Option<number>;
|
227
230
|
content: string;
|
228
231
|
removed: boolean;
|
229
232
|
read: boolean;
|
230
233
|
published: string;
|
231
|
-
updated
|
234
|
+
updated: Option<string>;
|
232
235
|
deleted: boolean;
|
233
236
|
ap_id: string;
|
234
237
|
local: boolean;
|
235
238
|
}
|
236
|
-
export
|
239
|
+
export declare class PersonMention {
|
237
240
|
id: number;
|
238
241
|
recipient_id: number;
|
239
242
|
comment_id: number;
|
240
243
|
read: boolean;
|
241
244
|
published: string;
|
242
245
|
}
|
243
|
-
export
|
246
|
+
export declare class RegistrationApplication {
|
244
247
|
id: number;
|
245
248
|
local_user_id: number;
|
246
249
|
answer: string;
|
247
|
-
admin_id
|
248
|
-
deny_reason
|
250
|
+
admin_id: Option<number>;
|
251
|
+
deny_reason: Option<string>;
|
249
252
|
published: string;
|
250
253
|
}
|