lemmy-js-client 1.0.0-alpha.1 → 1.0.0-comment-lock.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/README.md +6 -0
- package/dist/http.d.ts +92 -36
- package/dist/http.js +248 -66
- package/dist/index.d.ts +48 -20
- package/dist/other_types.d.ts +22 -4
- package/dist/types/AdminAllowInstance.d.ts +1 -1
- package/dist/types/AdminBlockInstance.d.ts +2 -2
- package/dist/types/AdminBlockInstanceParams.d.ts +1 -1
- package/dist/types/AdminListUsers.d.ts +7 -0
- package/dist/types/AdminListUsersResponse.d.ts +10 -0
- package/dist/types/AdminPurgeComment.d.ts +1 -1
- package/dist/types/AdminPurgeCommunity.d.ts +1 -1
- package/dist/types/AdminPurgePerson.d.ts +1 -1
- package/dist/types/AdminPurgePost.d.ts +1 -1
- package/dist/types/BanFromCommunity.d.ts +1 -1
- package/dist/types/BanPerson.d.ts +1 -1
- package/dist/types/Comment.d.ts +6 -2
- package/dist/types/CommentActions.d.ts +2 -6
- package/dist/types/CommentActions.js +1 -0
- package/dist/types/CommentReport.d.ts +2 -2
- package/dist/types/CommentReportView.d.ts +3 -1
- package/dist/types/CommentResponse.d.ts +0 -2
- package/dist/types/CommentSlimView.d.ts +2 -6
- package/dist/types/CommentView.d.ts +2 -5
- package/dist/types/Community.d.ts +2 -2
- package/dist/types/CommunityActions.d.ts +7 -13
- package/dist/types/CommunityIdQuery.d.ts +8 -0
- package/dist/types/CommunityNotificationsMode.d.ts +4 -0
- package/dist/types/CommunityReport.d.ts +2 -2
- package/dist/types/CommunityReportView.d.ts +4 -0
- package/dist/types/CommunityView.d.ts +0 -2
- package/dist/types/CreateCommunityTag.d.ts +3 -1
- package/dist/types/CreateMultiCommunity.d.ts +5 -0
- package/dist/types/CreateOrDeleteMultiCommunityEntry.d.ts +6 -0
- package/dist/types/CreatePost.d.ts +1 -1
- package/dist/types/CreateSite.d.ts +16 -13
- package/dist/types/CustomEmoji.d.ts +2 -2
- package/dist/types/EditPost.d.ts +1 -1
- package/dist/types/EditSite.d.ts +22 -16
- package/dist/types/ExportDataResponse.d.ts +13 -0
- package/dist/types/FederationBlockList.d.ts +3 -3
- package/dist/types/FederationError.d.ts +3 -1
- package/dist/types/FollowMultiCommunity.d.ts +5 -0
- package/dist/types/GetComments.d.ts +0 -2
- package/dist/types/GetMultiCommunity.d.ts +4 -0
- package/dist/types/GetMultiCommunityResponse.d.ts +6 -0
- package/dist/types/GetPosts.d.ts +2 -2
- package/dist/types/Instance.d.ts +4 -3
- package/dist/types/InstanceActions.d.ts +8 -8
- package/dist/types/InstanceActions.js +1 -0
- package/dist/types/InstanceWithFederationState.d.ts +2 -2
- package/dist/types/LemmyErrorType.d.ts +13 -19
- package/dist/types/LikeType.d.ts +4 -0
- package/dist/types/ListMultiCommunities.d.ts +5 -0
- package/dist/types/ListMultiCommunitiesResponse.d.ts +4 -0
- package/dist/types/{ListInbox.d.ts → ListNotifications.d.ts} +3 -3
- package/dist/types/{ListInboxResponse.d.ts → ListNotificationsResponse.d.ts} +3 -3
- package/dist/types/{ListBannedPersons.d.ts → ListPersonHidden.d.ts} +2 -2
- package/dist/types/{BannedPersonsResponse.d.ts → ListPersonHiddenResponse.d.ts} +4 -4
- package/dist/types/ListPersonLiked.d.ts +13 -0
- package/dist/types/ListPersonLikedResponse.d.ts +13 -0
- package/dist/types/ListPersonRead.d.ts +9 -0
- package/dist/types/ListPersonRead.js +2 -0
- package/dist/types/ListPersonReadResponse.d.ts +13 -0
- package/dist/types/ListPersonReadResponse.js +2 -0
- package/dist/types/ListingType.d.ts +1 -1
- package/dist/types/LocalImage.d.ts +8 -3
- package/dist/types/LocalImageView.d.ts +2 -0
- package/dist/types/LocalSite.d.ts +6 -6
- package/dist/types/LocalSiteRateLimit.d.ts +16 -16
- package/dist/types/LocalSiteUrlBlocklist.d.ts +2 -2
- package/dist/types/LocalUser.d.ts +4 -2
- package/dist/types/LocalUserView.d.ts +1 -2
- package/dist/types/LockComment.d.ts +6 -0
- package/dist/types/LockComment.js +2 -0
- package/dist/types/LockPost.d.ts +1 -0
- package/dist/types/Login.d.ts +3 -0
- package/dist/types/LoginToken.d.ts +1 -1
- package/dist/types/MarkNotificationAsRead.d.ts +8 -0
- package/dist/types/MarkNotificationAsRead.js +2 -0
- package/dist/types/ModAdd.d.ts +1 -1
- package/dist/types/ModAddCommunity.d.ts +1 -1
- package/dist/types/ModBan.d.ts +2 -2
- package/dist/types/ModBanFromCommunity.d.ts +2 -2
- package/dist/types/ModChangeCommunityVisibility.d.ts +1 -2
- package/dist/types/ModEditPost.d.ts +10 -0
- package/dist/types/ModEditPost.js +2 -0
- package/dist/types/ModFeaturePost.d.ts +1 -1
- package/dist/types/ModLockComment.d.ts +14 -0
- package/dist/types/ModLockComment.js +2 -0
- package/dist/types/ModLockCommentId.d.ts +1 -0
- package/dist/types/ModLockCommentView.d.ts +14 -0
- package/dist/types/ModLockCommentView.js +2 -0
- package/dist/types/ModLockPost.d.ts +2 -1
- package/dist/types/ModRemoveComment.d.ts +1 -1
- package/dist/types/ModRemoveCommunity.d.ts +1 -1
- package/dist/types/ModRemovePost.d.ts +1 -1
- package/dist/types/ModTransferCommunity.d.ts +1 -1
- package/dist/types/ModlogCombinedView.d.ts +4 -1
- package/dist/types/MultiCommunity.d.ts +17 -0
- package/dist/types/MultiCommunity.js +2 -0
- package/dist/types/MultiCommunityFollow.d.ts +8 -0
- package/dist/types/MultiCommunityFollow.js +2 -0
- package/dist/types/MultiCommunityId.d.ts +1 -0
- package/dist/types/MultiCommunityId.js +3 -0
- package/dist/types/MultiCommunityView.d.ts +6 -0
- package/dist/types/MultiCommunityView.js +2 -0
- package/dist/types/MyUserInfo.d.ts +2 -1
- package/dist/types/NotePerson.d.ts +10 -0
- package/dist/types/NotePerson.js +2 -0
- package/dist/types/Notification.d.ts +16 -0
- package/dist/types/Notification.js +2 -0
- package/dist/types/NotificationData.d.ts +10 -0
- package/dist/types/NotificationData.js +2 -0
- package/dist/types/NotificationDataType.d.ts +4 -0
- package/dist/types/NotificationDataType.js +3 -0
- package/dist/types/NotificationId.d.ts +1 -0
- package/dist/types/NotificationId.js +3 -0
- package/dist/types/NotificationTypes.d.ts +4 -0
- package/dist/types/NotificationTypes.js +3 -0
- package/dist/types/NotificationView.d.ts +6 -0
- package/dist/types/NotificationView.js +2 -0
- package/dist/types/OAuthAccount.d.ts +2 -2
- package/dist/types/OAuthProvider.d.ts +2 -2
- package/dist/types/Person.d.ts +2 -2
- package/dist/types/PersonActions.d.ts +21 -4
- package/dist/types/PersonActions.js +1 -0
- package/dist/types/PersonLikedCombinedView.d.ts +7 -0
- package/dist/types/PersonLikedCombinedView.js +2 -0
- package/dist/types/PersonView.d.ts +2 -3
- package/dist/types/Post.d.ts +4 -4
- package/dist/types/PostActions.d.ts +7 -9
- package/dist/types/PostNotificationsMode.d.ts +4 -0
- package/dist/types/PostNotificationsMode.js +3 -0
- package/dist/types/PostOrCommentOrPrivateMessage.d.ts +10 -0
- package/dist/types/PostOrCommentOrPrivateMessage.js +2 -0
- package/dist/types/PostReport.d.ts +2 -2
- package/dist/types/PostReportView.d.ts +3 -1
- package/dist/types/PostView.d.ts +2 -5
- package/dist/types/PrivateMessage.d.ts +2 -3
- package/dist/types/PrivateMessageReport.d.ts +2 -2
- package/dist/types/PrivateMessageReportView.d.ts +2 -0
- package/dist/types/ReadableFederationState.d.ts +2 -2
- package/dist/types/RegistrationApplication.d.ts +1 -1
- package/dist/types/SaveUserSettings.d.ts +6 -1
- package/dist/types/Search.d.ts +5 -1
- package/dist/types/SearchCombinedView.d.ts +4 -1
- package/dist/types/SearchType.d.ts +1 -1
- package/dist/types/Site.d.ts +4 -3
- package/dist/types/SiteResponse.d.ts +0 -4
- package/dist/types/Tag.d.ts +8 -16
- package/dist/types/Tagline.d.ts +2 -2
- package/dist/types/TagsView.d.ts +1 -1
- package/dist/types/UpdateCommunityNotifications.d.ts +9 -0
- package/dist/types/UpdateCommunityNotifications.js +2 -0
- package/dist/types/UpdateCommunityTag.d.ts +3 -2
- package/dist/types/UpdateMultiCommunity.d.ts +7 -0
- package/dist/types/UpdateMultiCommunity.js +2 -0
- package/dist/types/UpdatePostNotifications.d.ts +9 -0
- package/dist/types/UpdatePostNotifications.js +2 -0
- package/dist/types/UserBlockInstanceCommunitiesParams.d.ts +8 -0
- package/dist/types/UserBlockInstanceCommunitiesParams.js +2 -0
- package/dist/types/{UserBlockInstanceParams.d.ts → UserBlockInstancePersonsParams.d.ts} +2 -2
- package/dist/types/UserBlockInstancePersonsParams.js +2 -0
- package/dist/types/UserSettingsBackup.d.ts +31 -0
- package/dist/types/UserSettingsBackup.js +2 -0
- package/dist/types/VoteShow.d.ts +4 -0
- package/dist/types/VoteShow.js +3 -0
- package/dist/types/VoteView.d.ts +1 -1
- package/package.json +6 -5
- package/dist/types/CommentReply.d.ts +0 -13
- package/dist/types/CommentReplyId.d.ts +0 -4
- package/dist/types/CommentReplyView.d.ts +0 -32
- package/dist/types/InboxCombinedView.d.ts +0 -13
- package/dist/types/InboxDataType.d.ts +0 -4
- package/dist/types/MarkCommentReplyAsRead.d.ts +0 -8
- package/dist/types/MarkPersonCommentMentionAsRead.d.ts +0 -8
- package/dist/types/MarkPersonPostMentionAsRead.d.ts +0 -8
- package/dist/types/PersonCommentMention.d.ts +0 -13
- package/dist/types/PersonCommentMentionId.d.ts +0 -4
- package/dist/types/PersonCommentMentionView.d.ts +0 -30
- package/dist/types/PersonPostMention.d.ts +0 -13
- package/dist/types/PersonPostMentionId.d.ts +0 -4
- package/dist/types/PersonPostMentionView.d.ts +0 -32
- package/dist/types/ResolveObjectResponse.d.ts +0 -13
- /package/dist/types/{BannedPersonsResponse.js → AdminListUsers.js} +0 -0
- /package/dist/types/{CommentReply.js → AdminListUsersResponse.js} +0 -0
- /package/dist/types/{CommentReplyView.js → CommunityIdQuery.js} +0 -0
- /package/dist/types/{CommentReplyId.js → CommunityNotificationsMode.js} +0 -0
- /package/dist/types/{InboxDataType.js → CreateMultiCommunity.js} +0 -0
- /package/dist/types/{InboxCombinedView.js → CreateOrDeleteMultiCommunityEntry.js} +0 -0
- /package/dist/types/{ListBannedPersons.js → ExportDataResponse.js} +0 -0
- /package/dist/types/{ListInbox.js → FollowMultiCommunity.js} +0 -0
- /package/dist/types/{ListInboxResponse.js → GetMultiCommunity.js} +0 -0
- /package/dist/types/{MarkCommentReplyAsRead.js → GetMultiCommunityResponse.js} +0 -0
- /package/dist/types/{PersonCommentMentionId.js → LikeType.js} +0 -0
- /package/dist/types/{MarkPersonCommentMentionAsRead.js → ListMultiCommunities.js} +0 -0
- /package/dist/types/{MarkPersonPostMentionAsRead.js → ListMultiCommunitiesResponse.js} +0 -0
- /package/dist/types/{PersonCommentMention.js → ListNotifications.js} +0 -0
- /package/dist/types/{PersonCommentMentionView.js → ListNotificationsResponse.js} +0 -0
- /package/dist/types/{PersonPostMention.js → ListPersonHidden.js} +0 -0
- /package/dist/types/{PersonPostMentionView.js → ListPersonHiddenResponse.js} +0 -0
- /package/dist/types/{ResolveObjectResponse.js → ListPersonLiked.js} +0 -0
- /package/dist/types/{UserBlockInstanceParams.js → ListPersonLikedResponse.js} +0 -0
- /package/dist/types/{PersonPostMentionId.js → ModLockCommentId.js} +0 -0
package/README.md
CHANGED
@@ -52,6 +52,12 @@ Use `pnpm add` to develop and test changes locally:
|
|
52
52
|
|
53
53
|
`pnpm add path/to/lemmy-js-client`
|
54
54
|
|
55
|
+
Alternatively, use `yalc publish` and `yalc add lemmy-js-client`
|
56
|
+
|
57
|
+
## Generating typescript types from lemmy structs
|
58
|
+
|
59
|
+
Run `./scripts/copy_generated_types_from_lemmy.sh`
|
60
|
+
|
55
61
|
## OpenAPI
|
56
62
|
|
57
63
|
To generate OpenAPI docs, run `pnpm tsoa`
|
package/dist/http.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import { Controller } from "@tsoa/runtime";
|
2
|
-
import { DeleteImageParamsI, GetCommentI, GetCommentsI, GetCommunityI, GetCommunityPendingFollowsCountI, GetModlogI, GetPersonDetailsI, GetPostI, GetPostsI, GetRandomCommunityI, GetRegistrationApplicationI, GetReportCountI, GetSiteMetadataI,
|
2
|
+
import { AdminListUsersI, CommunityIdQueryI, DeleteImageParamsI, GetCommentI, GetCommentsI, GetCommunityI, GetCommunityPendingFollowsCountI, GetModlogI, GetMultiCommunityI, GetPersonDetailsI, GetPostI, GetPostsI, GetRandomCommunityI, GetRegistrationApplicationI, GetReportCountI, GetSiteMetadataI, ListCommentLikesI, ListCommunitiesI, ListCommunityPendingFollowsI, ListCustomEmojisI, ListNotificationsI, ListMediaI, ListMultiCommunitiesI, ListPersonContentI, ListPersonHiddenI, ListPersonLikedI, ListPersonReadI, ListPersonSavedI, ListPostLikesI, ListRegistrationApplicationsI, ListReportsI, ListTaglinesI, ResolveObjectI, SearchI, UploadImage } from "./other_types";
|
3
3
|
import { AddAdmin } from "./types/AddAdmin";
|
4
4
|
import { AddAdminResponse } from "./types/AddAdminResponse";
|
5
5
|
import { AddModToCommunity } from "./types/AddModToCommunity";
|
@@ -10,7 +10,6 @@ import { BanFromCommunityResponse } from "./types/BanFromCommunityResponse";
|
|
10
10
|
import { MarkManyPostsAsRead } from "./types/MarkManyPostsAsRead";
|
11
11
|
import { BanPerson } from "./types/BanPerson";
|
12
12
|
import { BanPersonResponse } from "./types/BanPersonResponse";
|
13
|
-
import { BannedPersonsResponse } from "./types/BannedPersonsResponse";
|
14
13
|
import { BlockCommunity } from "./types/BlockCommunity";
|
15
14
|
import { BlockCommunityResponse } from "./types/BlockCommunityResponse";
|
16
15
|
import { BlockPerson } from "./types/BlockPerson";
|
@@ -18,12 +17,15 @@ import { BlockPersonResponse } from "./types/BlockPersonResponse";
|
|
18
17
|
import { ChangePassword } from "./types/ChangePassword";
|
19
18
|
import { CommentReportResponse } from "./types/CommentReportResponse";
|
20
19
|
import { CommentResponse } from "./types/CommentResponse";
|
20
|
+
import { CommunityReportResponse } from "./types/CommunityReportResponse";
|
21
21
|
import { CommunityResponse } from "./types/CommunityResponse";
|
22
22
|
import { CreateComment } from "./types/CreateComment";
|
23
23
|
import { CreateCommentLike } from "./types/CreateCommentLike";
|
24
24
|
import { CreateCommentReport } from "./types/CreateCommentReport";
|
25
25
|
import { CreateCommunity } from "./types/CreateCommunity";
|
26
|
+
import { CreateCommunityReport } from "./types/CreateCommunityReport";
|
26
27
|
import { CreateCommunityTag } from "./types/CreateCommunityTag";
|
28
|
+
import { UpdateCommunityTag } from "./types/UpdateCommunityTag";
|
27
29
|
import { CreateCustomEmoji } from "./types/CreateCustomEmoji";
|
28
30
|
import { CreateOAuthProvider } from "./types/CreateOAuthProvider";
|
29
31
|
import { CreatePost } from "./types/CreatePost";
|
@@ -68,9 +70,9 @@ import { GetUnreadRegistrationApplicationCountResponse } from "./types/GetUnread
|
|
68
70
|
import { ListCommunitiesResponse } from "./types/ListCommunitiesResponse";
|
69
71
|
import { ListRegistrationApplicationsResponse } from "./types/ListRegistrationApplicationsResponse";
|
70
72
|
import { LockPost } from "./types/LockPost";
|
73
|
+
import { LockComment } from "./types/LockComment";
|
71
74
|
import { Login } from "./types/Login";
|
72
75
|
import { LoginResponse } from "./types/LoginResponse";
|
73
|
-
import { MarkCommentReplyAsRead } from "./types/MarkCommentReplyAsRead";
|
74
76
|
import { MarkPostAsRead } from "./types/MarkPostAsRead";
|
75
77
|
import { MarkPrivateMessageAsRead } from "./types/MarkPrivateMessageAsRead";
|
76
78
|
import { PasswordChangeAfterReset } from "./types/PasswordChangeAfterReset";
|
@@ -89,7 +91,7 @@ import { RemoveComment } from "./types/RemoveComment";
|
|
89
91
|
import { RemoveCommunity } from "./types/RemoveCommunity";
|
90
92
|
import { RemovePost } from "./types/RemovePost";
|
91
93
|
import { ResolveCommentReport } from "./types/ResolveCommentReport";
|
92
|
-
import {
|
94
|
+
import { ResolveCommunityReport } from "./types/ResolveCommunityReport";
|
93
95
|
import { ResolvePostReport } from "./types/ResolvePostReport";
|
94
96
|
import { ResolvePrivateMessageReport } from "./types/ResolvePrivateMessageReport";
|
95
97
|
import { SaveComment } from "./types/SaveComment";
|
@@ -98,14 +100,12 @@ import { SaveUserSettings } from "./types/SaveUserSettings";
|
|
98
100
|
import { SearchResponse } from "./types/SearchResponse";
|
99
101
|
import { SiteResponse } from "./types/SiteResponse";
|
100
102
|
import { TransferCommunity } from "./types/TransferCommunity";
|
101
|
-
import { UpdateCommunityTag } from "./types/UpdateCommunityTag";
|
102
103
|
import { VerifyEmail } from "./types/VerifyEmail";
|
103
104
|
import { HideCommunity } from "./types/HideCommunity";
|
104
105
|
import { GenerateTotpSecretResponse } from "./types/GenerateTotpSecretResponse";
|
105
106
|
import { UpdateTotp } from "./types/UpdateTotp";
|
106
107
|
import { UpdateTotpResponse } from "./types/UpdateTotpResponse";
|
107
108
|
import { SuccessResponse } from "./types/SuccessResponse";
|
108
|
-
import { LoginToken } from "./types/LoginToken";
|
109
109
|
import { ListPostLikesResponse } from "./types/ListPostLikesResponse";
|
110
110
|
import { ListCommentLikesResponse } from "./types/ListCommentLikesResponse";
|
111
111
|
import { HidePost } from "./types/HidePost";
|
@@ -122,18 +122,32 @@ import { GetCommunityPendingFollowsCountResponse } from "./types/GetCommunityPen
|
|
122
122
|
import { ListCommunityPendingFollowsResponse } from "./types/ListCommunityPendingFollowsResponse";
|
123
123
|
import { ListReportsResponse } from "./types/ListReportsResponse";
|
124
124
|
import { MyUserInfo } from "./types/MyUserInfo";
|
125
|
-
import { UserBlockInstanceParams } from "./types/UserBlockInstanceParams";
|
126
125
|
import { AdminAllowInstanceParams } from "./types/AdminAllowInstanceParams";
|
127
126
|
import { AdminBlockInstanceParams } from "./types/AdminBlockInstanceParams";
|
128
127
|
import { ListPersonContentResponse } from "./types/ListPersonContentResponse";
|
129
128
|
import { ListPersonSavedResponse } from "./types/ListPersonSavedResponse";
|
130
129
|
import { UploadImageResponse } from "./types/UploadImageResponse";
|
131
|
-
import { ListInboxResponse } from "./types/ListInboxResponse";
|
132
|
-
import { MarkPersonCommentMentionAsRead } from "./types/MarkPersonCommentMentionAsRead";
|
133
|
-
import { MarkPersonPostMentionAsRead } from "./types/MarkPersonPostMentionAsRead";
|
134
130
|
import { GetCommentsSlimResponse } from "./types/GetCommentsSlimResponse";
|
135
131
|
import { Tag } from "./types/Tag";
|
136
132
|
import { ResendVerificationEmail } from "./types/ResendVerificationEmail";
|
133
|
+
import { ListPersonReadResponse } from "./types/ListPersonReadResponse";
|
134
|
+
import { ListPersonHiddenResponse } from "./types/ListPersonHiddenResponse";
|
135
|
+
import { CommunityIdQuery } from "./types/CommunityIdQuery";
|
136
|
+
import { CreateMultiCommunity } from "./types/CreateMultiCommunity";
|
137
|
+
import { UpdateMultiCommunity } from "./types/UpdateMultiCommunity";
|
138
|
+
import { ListMultiCommunitiesResponse } from "./types/ListMultiCommunitiesResponse";
|
139
|
+
import { AdminListUsersResponse } from "./types/AdminListUsersResponse";
|
140
|
+
import { CreateOrDeleteMultiCommunityEntry } from "./types/CreateOrDeleteMultiCommunityEntry";
|
141
|
+
import { GetMultiCommunityResponse } from "./types/GetMultiCommunityResponse";
|
142
|
+
import { FollowMultiCommunity } from "./types/FollowMultiCommunity";
|
143
|
+
import { ListLoginsResponse } from "./types/ListLoginsResponse";
|
144
|
+
import { ListPersonLikedResponse } from "./types/ListPersonLikedResponse";
|
145
|
+
import { NotePerson } from "./types/NotePerson";
|
146
|
+
import { UserBlockInstanceCommunitiesParams } from "./types/UserBlockInstanceCommunitiesParams";
|
147
|
+
import { UserBlockInstancePersonsParams } from "./types/UserBlockInstancePersonsParams";
|
148
|
+
import { MarkNotificationAsRead } from "./types/MarkNotificationAsRead";
|
149
|
+
import { ListNotificationsResponse } from "./types/ListNotificationsResponse";
|
150
|
+
import { ModEditPost } from "./types/ModEditPost";
|
137
151
|
type RequestOptions = Pick<RequestInit, "signal">;
|
138
152
|
/**
|
139
153
|
* Helps build lemmy HTTP requests.
|
@@ -192,7 +206,7 @@ export declare class LemmyHttp extends Controller {
|
|
192
206
|
/**
|
193
207
|
* @summary List login tokens for your user
|
194
208
|
*/
|
195
|
-
listLogins(options?: RequestOptions): Promise<
|
209
|
+
listLogins(options?: RequestOptions): Promise<ListLoginsResponse>;
|
196
210
|
/**
|
197
211
|
* @summary Returns an error message if your auth token is invalid
|
198
212
|
*/
|
@@ -226,13 +240,13 @@ export declare class LemmyHttp extends Controller {
|
|
226
240
|
*/
|
227
241
|
getModlog(form?: GetModlogI, options?: RequestOptions): Promise<GetModlogResponse>;
|
228
242
|
/**
|
229
|
-
* @summary Search lemmy.
|
243
|
+
* @summary Search lemmy. If `search_term` is a url it also attempts to fetch it, just like `resolve_object`.
|
230
244
|
*/
|
231
245
|
search(form: SearchI, options?: RequestOptions): Promise<SearchResponse>;
|
232
246
|
/**
|
233
247
|
* @summary Fetch a non-local / federated object.
|
234
248
|
*/
|
235
|
-
resolveObject(form: ResolveObjectI, options?: RequestOptions): Promise<
|
249
|
+
resolveObject(form: ResolveObjectI, options?: RequestOptions): Promise<SearchResponse>;
|
236
250
|
/**
|
237
251
|
* @summary Create a new community.
|
238
252
|
*/
|
@@ -297,6 +311,14 @@ export declare class LemmyHttp extends Controller {
|
|
297
311
|
* @summary Get a random community.
|
298
312
|
*/
|
299
313
|
getRandomCommunity(form: GetRandomCommunityI, options?: RequestOptions): Promise<CommunityResponse>;
|
314
|
+
/**
|
315
|
+
* @summary Create a report for a community.
|
316
|
+
*/
|
317
|
+
createCommunityReport(form: CreateCommunityReport, options?: RequestOptions): Promise<CommunityReportResponse>;
|
318
|
+
/**
|
319
|
+
* @summary Resolve a report for a private message.
|
320
|
+
*/
|
321
|
+
resolveCommunityReport(form: ResolveCommunityReport, options?: RequestOptions): Promise<CommunityReportResponse>;
|
300
322
|
/**
|
301
323
|
* @summary Create a post.
|
302
324
|
*/
|
@@ -309,6 +331,10 @@ export declare class LemmyHttp extends Controller {
|
|
309
331
|
* @summary Edit a post.
|
310
332
|
*/
|
311
333
|
editPost(form: EditPost, options?: RequestOptions): Promise<PostResponse>;
|
334
|
+
/**
|
335
|
+
* @summary Mods can change nsfw flag and tags for a post
|
336
|
+
*/
|
337
|
+
modEditPost(form: ModEditPost, options?: RequestOptions): Promise<PostResponse>;
|
312
338
|
/**
|
313
339
|
* @summary Delete a post.
|
314
340
|
*/
|
@@ -320,7 +346,7 @@ export declare class LemmyHttp extends Controller {
|
|
320
346
|
/**
|
321
347
|
* @summary Mark a post as read.
|
322
348
|
*/
|
323
|
-
markPostAsRead(form: MarkPostAsRead, options?: RequestOptions): Promise<
|
349
|
+
markPostAsRead(form: MarkPostAsRead, options?: RequestOptions): Promise<PostResponse>;
|
324
350
|
/**
|
325
351
|
* @summary Mark multiple posts as read.
|
326
352
|
*/
|
@@ -382,11 +408,11 @@ export declare class LemmyHttp extends Controller {
|
|
382
408
|
*/
|
383
409
|
removeComment(form: RemoveComment, options?: RequestOptions): Promise<CommentResponse>;
|
384
410
|
/**
|
385
|
-
* @summary
|
411
|
+
* @summary A moderator can lock a comment (IE disable replies).
|
386
412
|
*/
|
387
|
-
|
413
|
+
lockComment(form: LockComment, options?: RequestOptions): Promise<CommentResponse>;
|
388
414
|
/**
|
389
|
-
* @
|
415
|
+
* @Summary Like / vote on a comment.
|
390
416
|
*/
|
391
417
|
likeComment(form: CreateCommentLike, options?: RequestOptions): Promise<CommentResponse>;
|
392
418
|
/**
|
@@ -466,21 +492,17 @@ export declare class LemmyHttp extends Controller {
|
|
466
492
|
*/
|
467
493
|
listPersonContent(form?: ListPersonContentI, options?: RequestOptions): Promise<ListPersonContentResponse>;
|
468
494
|
/**
|
469
|
-
* @summary
|
495
|
+
* @summary Make a note for a person.
|
470
496
|
*/
|
471
|
-
|
472
|
-
/**
|
473
|
-
* @summary Mark a person post body mention as read.
|
474
|
-
*/
|
475
|
-
markPostMentionAsRead(form: MarkPersonPostMentionAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
497
|
+
notePerson(form: NotePerson, options?: RequestOptions): Promise<SuccessResponse>;
|
476
498
|
/**
|
477
499
|
* @summary Ban a person from your site.
|
478
500
|
*/
|
479
501
|
banPerson(form: BanPerson, options?: RequestOptions): Promise<BanPersonResponse>;
|
480
502
|
/**
|
481
|
-
* @summary Get a list of
|
503
|
+
* @summary Get a list of users.
|
482
504
|
*/
|
483
|
-
|
505
|
+
listUsers(form?: AdminListUsersI, options?: RequestOptions): Promise<AdminListUsersResponse>;
|
484
506
|
/**
|
485
507
|
* @summary Block a person.
|
486
508
|
*/
|
@@ -505,6 +527,10 @@ export declare class LemmyHttp extends Controller {
|
|
505
527
|
* @summary Mark all replies as read.
|
506
528
|
*/
|
507
529
|
markAllNotificationsAsRead(options?: RequestOptions): Promise<SuccessResponse>;
|
530
|
+
/**
|
531
|
+
* @summary Mark a comment as read.
|
532
|
+
*/
|
533
|
+
markNotificationAsRead(form: MarkNotificationAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
508
534
|
/**
|
509
535
|
* @summary Save your user settings.
|
510
536
|
*/
|
@@ -524,7 +550,7 @@ export declare class LemmyHttp extends Controller {
|
|
524
550
|
/**
|
525
551
|
* @summary Get your inbox (replies, comment mentions, post mentions, and messages)
|
526
552
|
*/
|
527
|
-
|
553
|
+
listNotifications(form: ListNotificationsI, options?: RequestOptions): Promise<ListNotificationsResponse>;
|
528
554
|
/**
|
529
555
|
* @summary Verify your email
|
530
556
|
*/
|
@@ -537,6 +563,18 @@ export declare class LemmyHttp extends Controller {
|
|
537
563
|
* @summary List your saved content.
|
538
564
|
*/
|
539
565
|
listPersonSaved(form: ListPersonSavedI, options?: RequestOptions): Promise<ListPersonSavedResponse>;
|
566
|
+
/**
|
567
|
+
* @summary List your read content.
|
568
|
+
*/
|
569
|
+
listPersonRead(form: ListPersonReadI, options?: RequestOptions): Promise<ListPersonReadResponse>;
|
570
|
+
/**
|
571
|
+
* @summary List your hidden content.
|
572
|
+
*/
|
573
|
+
listPersonHidden(form: ListPersonHiddenI, options?: RequestOptions): Promise<ListPersonHiddenResponse>;
|
574
|
+
/**
|
575
|
+
* @summary List your liked content.
|
576
|
+
*/
|
577
|
+
listPersonLiked(form: ListPersonLikedI, options?: RequestOptions): Promise<ListPersonLikedResponse>;
|
540
578
|
/**
|
541
579
|
* @summary Add an admin to your site.
|
542
580
|
*/
|
@@ -610,7 +648,7 @@ export declare class LemmyHttp extends Controller {
|
|
610
648
|
*/
|
611
649
|
createCommunityTag(form: CreateCommunityTag, options?: RequestOptions): Promise<Tag>;
|
612
650
|
/**
|
613
|
-
* @summary
|
651
|
+
* @summary Edit a community post tag.
|
614
652
|
*/
|
615
653
|
updateCommunityTag(form: UpdateCommunityTag, options?: RequestOptions): Promise<Tag>;
|
616
654
|
/**
|
@@ -642,9 +680,13 @@ export declare class LemmyHttp extends Controller {
|
|
642
680
|
*/
|
643
681
|
listReports(form: ListReportsI, options?: RequestOptions): Promise<ListReportsResponse>;
|
644
682
|
/**
|
645
|
-
* @summary Block an instance as user.
|
683
|
+
* @summary Block an instance's communities as a user.
|
646
684
|
*/
|
647
|
-
|
685
|
+
userBlockInstanceCommunities(form: UserBlockInstanceCommunitiesParams, options?: RequestOptions): Promise<SuccessResponse>;
|
686
|
+
/**
|
687
|
+
* @summary Block an instance's persons as a user.
|
688
|
+
*/
|
689
|
+
userBlockInstancePersons(form: UserBlockInstancePersonsParams, options?: RequestOptions): Promise<SuccessResponse>;
|
648
690
|
/**
|
649
691
|
* @summary Globally block an instance as admin.
|
650
692
|
*/
|
@@ -672,19 +714,19 @@ export declare class LemmyHttp extends Controller {
|
|
672
714
|
/**
|
673
715
|
* @summary Upload new community icon.
|
674
716
|
*/
|
675
|
-
uploadCommunityIcon(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
717
|
+
uploadCommunityIcon(query: CommunityIdQueryI, image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
676
718
|
/**
|
677
719
|
* @summary Delete the community icon.
|
678
720
|
*/
|
679
|
-
deleteCommunityIcon(options?: RequestOptions): Promise<SuccessResponse>;
|
721
|
+
deleteCommunityIcon(form: CommunityIdQuery, options?: RequestOptions): Promise<SuccessResponse>;
|
680
722
|
/**
|
681
723
|
* @summary Upload new community banner.
|
682
724
|
*/
|
683
|
-
uploadCommunityBanner(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
725
|
+
uploadCommunityBanner(query: CommunityIdQueryI, image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
684
726
|
/**
|
685
727
|
* @summary Delete the community banner.
|
686
728
|
*/
|
687
|
-
deleteCommunityBanner(options?: RequestOptions): Promise<SuccessResponse>;
|
729
|
+
deleteCommunityBanner(form: CommunityIdQuery, options?: RequestOptions): Promise<SuccessResponse>;
|
688
730
|
/**
|
689
731
|
* @summary Upload new site icon.
|
690
732
|
*/
|
@@ -711,10 +753,15 @@ export declare class LemmyHttp extends Controller {
|
|
711
753
|
imageHealth(options?: RequestOptions): Promise<SuccessResponse>;
|
712
754
|
/**
|
713
755
|
* Mark donation dialog as shown, so it isn't displayed anymore.
|
714
|
-
*
|
715
|
-
* `HTTP.POST /user/donation_dialog_shown`
|
716
756
|
*/
|
717
|
-
|
757
|
+
donationDialogShown(options?: RequestOptions): Promise<SuccessResponse>;
|
758
|
+
createMultiCommunity(form: CreateMultiCommunity, options?: RequestOptions): Promise<GetMultiCommunityResponse>;
|
759
|
+
updateMultiCommunity(form: UpdateMultiCommunity, options?: RequestOptions): Promise<SuccessResponse>;
|
760
|
+
getMultiCommunity(form: GetMultiCommunityI, options?: RequestOptions): Promise<GetMultiCommunityResponse>;
|
761
|
+
createMultiCommunityEntry(form: CreateOrDeleteMultiCommunityEntry, options?: RequestOptions): Promise<SuccessResponse>;
|
762
|
+
deleteMultiCommunityEntry(form: CreateOrDeleteMultiCommunityEntry, options?: RequestOptions): Promise<SuccessResponse>;
|
763
|
+
listMultiCommunities(form: ListMultiCommunitiesI, options?: RequestOptions): Promise<ListMultiCommunitiesResponse>;
|
764
|
+
followMultiCommunity(form: FollowMultiCommunity, options?: RequestOptions): Promise<SuccessResponse>;
|
718
765
|
/**
|
719
766
|
* Set the headers (can be used to set the auth header)
|
720
767
|
*/
|
@@ -722,4 +769,13 @@ export declare class LemmyHttp extends Controller {
|
|
722
769
|
[key: string]: string;
|
723
770
|
}): void;
|
724
771
|
}
|
772
|
+
/**
|
773
|
+
* A Lemmy error type.
|
774
|
+
*
|
775
|
+
* The name is the i18n translatable error code.
|
776
|
+
* The msg is either an empty string, or extra non-translatable info.
|
777
|
+
*/
|
778
|
+
export declare class LemmyError extends Error {
|
779
|
+
constructor(name: string, msg?: string);
|
780
|
+
}
|
725
781
|
export {};
|