lemmy-js-client 1.0.0-post-tags.0 → 1.0.0-post-notifications.1
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 +12 -3
- package/dist/http.d.ts +99 -59
- package/dist/http.js +1002 -870
- package/dist/index.d.ts +55 -30
- package/dist/other_types.d.ts +21 -0
- 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 +16 -2
- package/dist/types/CommentActions.d.ts +14 -0
- package/dist/types/CommentReply.d.ts +1 -1
- package/dist/types/CommentReport.d.ts +3 -2
- package/dist/types/CommentReportView.d.ts +7 -10
- package/dist/types/CommentResponse.d.ts +0 -2
- package/dist/types/CommentSlimView.d.ts +10 -10
- package/dist/types/CommentView.d.ts +14 -10
- package/dist/types/Community.d.ts +27 -8
- package/dist/types/CommunityActions.d.ts +29 -0
- 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/CommunityReportResponse.d.ts +7 -0
- package/dist/types/CommunityReportView.d.ts +0 -4
- package/dist/types/CommunitySortType.d.ts +1 -1
- package/dist/types/CommunityView.d.ts +7 -6
- package/dist/types/CommunityVisibility.d.ts +1 -1
- package/dist/types/CreateCommentReport.d.ts +1 -0
- package/dist/types/CreateCommunityReport.d.ts +8 -0
- package/dist/types/CreateCommunityTag.d.ts +1 -2
- 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/CreatePostReport.d.ts +1 -0
- package/dist/types/CreateSite.d.ts +19 -14
- package/dist/types/CustomEmoji.d.ts +2 -2
- package/dist/types/EditPost.d.ts +3 -1
- package/dist/types/EditSite.d.ts +32 -19
- package/dist/types/ExportDataResponse.d.ts +13 -0
- package/dist/types/FederationBlockList.d.ts +3 -3
- package/dist/types/FederationError.d.ts +1 -1
- package/dist/types/FollowMultiCommunity.d.ts +5 -0
- package/dist/types/GetComments.d.ts +8 -3
- package/dist/types/GetCommentsResponse.d.ts +3 -0
- package/dist/types/GetCommentsSlimResponse.d.ts +3 -0
- package/dist/types/GetModlog.d.ts +27 -2
- package/dist/types/GetModlogResponse.d.ts +6 -0
- package/dist/types/GetMultiCommunity.d.ts +4 -0
- package/dist/types/GetMultiCommunityResponse.d.ts +6 -0
- package/dist/types/GetPostResponse.d.ts +0 -2
- package/dist/types/GetPosts.d.ts +7 -7
- package/dist/types/GetPostsResponse.d.ts +1 -0
- package/dist/types/GetSiteResponse.d.ts +4 -2
- package/dist/types/ImageDetails.d.ts +1 -0
- package/dist/types/InboxDataType.d.ts +1 -1
- package/dist/types/Instance.d.ts +13 -3
- package/dist/types/InstanceActions.d.ts +14 -0
- package/dist/types/InstanceWithFederationState.d.ts +11 -2
- package/dist/types/LemmyErrorType.d.ts +95 -28
- package/dist/types/LikeType.d.ts +4 -0
- package/dist/types/ListCommentLikes.d.ts +3 -1
- package/dist/types/ListCommentLikesResponse.d.ts +6 -0
- package/dist/types/ListCommunities.d.ts +8 -1
- package/dist/types/ListCommunitiesResponse.d.ts +6 -0
- package/dist/types/ListCommunityPendingFollows.d.ts +3 -1
- package/dist/types/ListCommunityPendingFollows.js +0 -1
- package/dist/types/ListCommunityPendingFollowsResponse.d.ts +6 -0
- package/dist/types/ListCustomEmojis.d.ts +0 -3
- package/dist/types/ListInbox.d.ts +3 -2
- package/dist/types/ListInboxResponse.d.ts +8 -2
- package/dist/types/ListMedia.d.ts +3 -1
- package/dist/types/ListMedia.js +0 -1
- package/dist/types/ListMediaResponse.d.ts +6 -0
- package/dist/types/ListMultiCommunities.d.ts +5 -0
- package/dist/types/ListMultiCommunitiesResponse.d.ts +4 -0
- package/dist/types/ListPersonContent.d.ts +3 -2
- package/dist/types/ListPersonContentResponse.d.ts +6 -0
- package/dist/types/ListPersonHidden.d.ts +9 -0
- package/dist/types/ListPersonHiddenResponse.d.ts +13 -0
- 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/ListPersonReadResponse.d.ts +13 -0
- package/dist/types/ListPersonSaved.d.ts +3 -2
- package/dist/types/ListPersonSavedResponse.d.ts +8 -2
- package/dist/types/ListPostLikes.d.ts +3 -1
- package/dist/types/ListPostLikesResponse.d.ts +6 -0
- package/dist/types/ListRegistrationApplications.d.ts +3 -1
- package/dist/types/ListRegistrationApplications.js +0 -1
- package/dist/types/ListRegistrationApplicationsResponse.d.ts +6 -0
- package/dist/types/ListReports.d.ts +11 -2
- package/dist/types/ListReportsResponse.d.ts +6 -0
- package/dist/types/ListTaglines.d.ts +3 -1
- package/dist/types/ListTaglines.js +0 -1
- package/dist/types/ListTaglinesResponse.d.ts +6 -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 +36 -9
- package/dist/types/LocalSiteRateLimit.d.ts +16 -16
- package/dist/types/LocalSiteUrlBlocklist.d.ts +2 -2
- package/dist/types/LocalUser.d.ts +11 -1
- package/dist/types/LocalUserView.d.ts +1 -4
- 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/ModAdd.d.ts +1 -1
- package/dist/types/ModAddCommunity.d.ts +1 -1
- package/dist/types/ModBan.d.ts +4 -2
- package/dist/types/ModBanFromCommunity.d.ts +2 -2
- package/dist/types/ModChangeCommunityVisibility.d.ts +11 -0
- package/dist/types/ModChangeCommunityVisibilityId.d.ts +1 -0
- package/dist/types/ModChangeCommunityVisibilityView.d.ts +11 -0
- package/dist/types/ModChangeCommunityVisibilityView.js +2 -0
- package/dist/types/ModFeaturePost.d.ts +1 -1
- 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/ModlogActionType.d.ts +1 -1
- package/dist/types/ModlogCombinedView.d.ts +3 -3
- 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/MultiCommunityView.d.ts +6 -0
- package/dist/types/MultiCommunityView.js +2 -0
- package/dist/types/MyUserInfo.d.ts +1 -0
- package/dist/types/NotePerson.d.ts +10 -0
- package/dist/types/NotePerson.js +2 -0
- package/dist/types/Notification.d.ts +14 -0
- package/dist/types/Notification.js +2 -0
- package/dist/types/NotificationData.d.ts +17 -0
- package/dist/types/NotificationData.js +2 -0
- package/dist/types/NotificationId.d.ts +1 -0
- package/dist/types/NotificationTypes.d.ts +4 -0
- package/dist/types/NotificationView.d.ts +30 -0
- package/dist/types/NotificationView.js +2 -0
- package/dist/types/NotificationsMode.d.ts +4 -0
- package/dist/types/NotificationsMode.js +3 -0
- package/dist/types/OAuthAccount.d.ts +2 -2
- package/dist/types/OAuthProvider.d.ts +2 -2
- package/dist/types/PaginationCursor.d.ts +1 -4
- package/dist/types/PendingFollow.d.ts +2 -2
- package/dist/types/Person.d.ts +6 -12
- package/dist/types/PersonActions.d.ts +26 -0
- package/dist/types/PersonActions.js +3 -0
- package/dist/types/PersonCommentMention.d.ts +1 -1
- package/dist/types/PersonLikedCombinedView.d.ts +7 -0
- package/dist/types/PersonLikedCombinedView.js +2 -0
- package/dist/types/PersonNotification.d.ts +9 -0
- package/dist/types/PersonNotification.js +2 -0
- package/dist/types/PersonPostMention.d.ts +1 -1
- package/dist/types/PersonSavedCombinedView.d.ts +7 -0
- package/dist/types/PersonSavedCombinedView.js +2 -0
- package/dist/types/PersonView.d.ts +3 -2
- package/dist/types/PluginMetadata.d.ts +5 -0
- package/dist/types/PluginMetadata.js +3 -0
- package/dist/types/Post.d.ts +18 -3
- package/dist/types/PostActions.d.ts +33 -0
- package/dist/types/PostActions.js +2 -0
- 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 +3 -2
- package/dist/types/PostReportView.d.ts +7 -13
- package/dist/types/PostSortType.d.ts +1 -1
- package/dist/types/PostView.d.ts +14 -15
- package/dist/types/PrivateMessage.d.ts +3 -2
- package/dist/types/PrivateMessageReport.d.ts +2 -2
- package/dist/types/PrivateMessageReportView.d.ts +1 -1
- package/dist/types/ReadableFederationState.d.ts +2 -2
- package/dist/types/RegistrationApplication.d.ts +1 -1
- package/dist/types/ResendVerificationEmail.d.ts +7 -0
- package/dist/types/ResendVerificationEmail.js +2 -0
- package/dist/types/ResolveCommunityReport.d.ts +8 -0
- package/dist/types/ResolveCommunityReport.js +2 -0
- package/dist/types/SaveUserSettings.d.ts +11 -1
- package/dist/types/Search.d.ts +13 -3
- package/dist/types/SearchCombinedView.d.ts +4 -1
- package/dist/types/SearchResponse.d.ts +6 -0
- package/dist/types/SearchType.d.ts +1 -1
- package/dist/types/Site.d.ts +6 -5
- package/dist/types/SiteResponse.d.ts +0 -4
- package/dist/types/SiteView.d.ts +2 -2
- package/dist/types/Tag.d.ts +10 -8
- package/dist/types/Tagline.d.ts +4 -3
- package/dist/types/Tagline.js +0 -1
- package/dist/types/{PostTags.d.ts → TagsView.d.ts} +1 -1
- package/dist/types/TagsView.js +2 -0
- package/dist/types/UpdateCommunityNotifications.d.ts +9 -0
- package/dist/types/UpdateCommunityNotifications.js +2 -0
- package/dist/types/UpdateCommunityTag.d.ts +1 -1
- 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/UserSettingsBackup.d.ts +26 -0
- package/dist/types/UserSettingsBackup.js +2 -0
- package/dist/types/VoteShow.d.ts +4 -0
- package/dist/types/VoteShow.js +3 -0
- package/package.json +8 -5
- package/dist/types/BannedPersonsResponse.d.ts +0 -7
- package/dist/types/CommentAggregates.d.ts +0 -17
- package/dist/types/CommentReplyView.d.ts +0 -27
- package/dist/types/CommunityAggregates.d.ts +0 -30
- package/dist/types/CommunityTagResponse.d.ts +0 -7
- package/dist/types/InboxCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/InboxCombinedView.d.ts +0 -13
- package/dist/types/ListCommunityTags.d.ts +0 -7
- package/dist/types/ListCommunityTagsResponse.d.ts +0 -4
- package/dist/types/LocalUserVoteDisplayMode.d.ts +0 -9
- 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/ModHideCommunity.d.ts +0 -14
- package/dist/types/ModHideCommunityId.d.ts +0 -1
- package/dist/types/ModHideCommunityView.d.ts +0 -11
- package/dist/types/ModlogCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/PersonAggregates.d.ts +0 -9
- package/dist/types/PersonCommentMentionView.d.ts +0 -27
- package/dist/types/PersonContentCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/PersonPostMentionView.d.ts +0 -32
- package/dist/types/PersonSavedCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/PostAggregates.d.ts +0 -18
- package/dist/types/ReportCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/ResolveObjectResponse.d.ts +0 -13
- package/dist/types/SearchCombinedPaginationCursor.d.ts +0 -4
- package/dist/types/SiteAggregates.d.ts +0 -27
- package/dist/types/SubscribedType.d.ts +0 -4
- package/dist/types/UpdatePostTags.d.ts +0 -9
- /package/dist/types/{BannedPersonsResponse.js → AdminListUsers.js} +0 -0
- /package/dist/types/{CommentAggregates.js → AdminListUsersResponse.js} +0 -0
- /package/dist/types/{InboxCombinedPaginationCursor.js → CommentActions.js} +0 -0
- /package/dist/types/{CommentReplyView.js → CommunityActions.js} +0 -0
- /package/dist/types/{CommunityAggregates.js → CommunityIdQuery.js} +0 -0
- /package/dist/types/{LocalUserVoteDisplayMode.js → CommunityNotificationsMode.js} +0 -0
- /package/dist/types/{CommunityTagResponse.js → CommunityReportResponse.js} +0 -0
- /package/dist/types/{InboxCombinedView.js → CreateCommunityReport.js} +0 -0
- /package/dist/types/{ModHideCommunityId.js → CreateMultiCommunity.js} +0 -0
- /package/dist/types/{ListCommunityTags.js → CreateOrDeleteMultiCommunityEntry.js} +0 -0
- /package/dist/types/{ListCommunityTagsResponse.js → ExportDataResponse.js} +0 -0
- /package/dist/types/{MarkCommentReplyAsRead.js → FollowMultiCommunity.js} +0 -0
- /package/dist/types/{MarkPersonCommentMentionAsRead.js → GetMultiCommunity.js} +0 -0
- /package/dist/types/{MarkPersonPostMentionAsRead.js → GetMultiCommunityResponse.js} +0 -0
- /package/dist/types/{ModlogCombinedPaginationCursor.js → InstanceActions.js} +0 -0
- /package/dist/types/{PersonContentCombinedPaginationCursor.js → LikeType.js} +0 -0
- /package/dist/types/{ModHideCommunity.js → ListMultiCommunities.js} +0 -0
- /package/dist/types/{ModHideCommunityView.js → ListMultiCommunitiesResponse.js} +0 -0
- /package/dist/types/{PersonAggregates.js → ListPersonHidden.js} +0 -0
- /package/dist/types/{PersonCommentMentionView.js → ListPersonHiddenResponse.js} +0 -0
- /package/dist/types/{PersonPostMentionView.js → ListPersonLiked.js} +0 -0
- /package/dist/types/{PostAggregates.js → ListPersonLikedResponse.js} +0 -0
- /package/dist/types/{PostTags.js → ListPersonRead.js} +0 -0
- /package/dist/types/{ResolveObjectResponse.js → ListPersonReadResponse.js} +0 -0
- /package/dist/types/{SiteAggregates.js → MarkNotificationAsRead.js} +0 -0
- /package/dist/types/{UpdatePostTags.js → ModChangeCommunityVisibility.js} +0 -0
- /package/dist/types/{PersonSavedCombinedPaginationCursor.js → ModChangeCommunityVisibilityId.js} +0 -0
- /package/dist/types/{ReportCombinedPaginationCursor.js → MultiCommunityId.js} +0 -0
- /package/dist/types/{SearchCombinedPaginationCursor.js → NotificationId.js} +0 -0
- /package/dist/types/{SubscribedType.js → NotificationTypes.js} +0 -0
package/README.md
CHANGED
@@ -50,6 +50,15 @@ const posts = await client.getPosts(getPostsForm);
|
|
50
50
|
|
51
51
|
Use `pnpm add` to develop and test changes locally:
|
52
52
|
|
53
|
-
|
54
|
-
|
55
|
-
|
53
|
+
`pnpm add path/to/lemmy-js-client`
|
54
|
+
|
55
|
+
## OpenAPI
|
56
|
+
|
57
|
+
To generate OpenAPI docs, run `pnpm tsoa`
|
58
|
+
|
59
|
+
This creates two files:
|
60
|
+
|
61
|
+
- `redoc-static.html` - A static html rendering of the OpenAPI docs.
|
62
|
+
- `tsoa_build/swagger.json` - An OpenAPI / Swagger json file.
|
63
|
+
|
64
|
+
To contribute, check out the [tsoa docs](https://tsoa-community.github.io/docs/).
|
package/dist/http.d.ts
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
import { Controller } from "@tsoa/runtime";
|
2
|
+
import { AdminListUsersI, CommunityIdQueryI, DeleteImageParamsI, GetCommentI, GetCommentsI, GetCommunityI, GetCommunityPendingFollowsCountI, GetModlogI, GetMultiCommunityI, GetPersonDetailsI, GetPostI, GetPostsI, GetRandomCommunityI, GetRegistrationApplicationI, GetReportCountI, GetSiteMetadataI, ListCommentLikesI, ListCommunitiesI, ListCommunityPendingFollowsI, ListCustomEmojisI, ListInboxI, ListMediaI, ListMultiCommunitiesI, ListPersonContentI, ListPersonHiddenI, ListPersonLikedI, ListPersonReadI, ListPersonSavedI, ListPostLikesI, ListRegistrationApplicationsI, ListReportsI, ListTaglinesI, ResolveObjectI, SearchI, UploadImage } from "./other_types";
|
1
3
|
import { AddAdmin } from "./types/AddAdmin";
|
2
4
|
import { AddAdminResponse } from "./types/AddAdminResponse";
|
3
5
|
import { AddModToCommunity } from "./types/AddModToCommunity";
|
@@ -8,7 +10,6 @@ import { BanFromCommunityResponse } from "./types/BanFromCommunityResponse";
|
|
8
10
|
import { MarkManyPostsAsRead } from "./types/MarkManyPostsAsRead";
|
9
11
|
import { BanPerson } from "./types/BanPerson";
|
10
12
|
import { BanPersonResponse } from "./types/BanPersonResponse";
|
11
|
-
import { BannedPersonsResponse } from "./types/BannedPersonsResponse";
|
12
13
|
import { BlockCommunity } from "./types/BlockCommunity";
|
13
14
|
import { BlockCommunityResponse } from "./types/BlockCommunityResponse";
|
14
15
|
import { BlockPerson } from "./types/BlockPerson";
|
@@ -16,11 +17,13 @@ import { BlockPersonResponse } from "./types/BlockPersonResponse";
|
|
16
17
|
import { ChangePassword } from "./types/ChangePassword";
|
17
18
|
import { CommentReportResponse } from "./types/CommentReportResponse";
|
18
19
|
import { CommentResponse } from "./types/CommentResponse";
|
20
|
+
import { CommunityReportResponse } from "./types/CommunityReportResponse";
|
19
21
|
import { CommunityResponse } from "./types/CommunityResponse";
|
20
22
|
import { CreateComment } from "./types/CreateComment";
|
21
23
|
import { CreateCommentLike } from "./types/CreateCommentLike";
|
22
24
|
import { CreateCommentReport } from "./types/CreateCommentReport";
|
23
25
|
import { CreateCommunity } from "./types/CreateCommunity";
|
26
|
+
import { CreateCommunityReport } from "./types/CreateCommunityReport";
|
24
27
|
import { CreateCommunityTag } from "./types/CreateCommunityTag";
|
25
28
|
import { CreateCustomEmoji } from "./types/CreateCustomEmoji";
|
26
29
|
import { CreateOAuthProvider } from "./types/CreateOAuthProvider";
|
@@ -64,13 +67,10 @@ import { GetSiteResponse } from "./types/GetSiteResponse";
|
|
64
67
|
import { GetUnreadCountResponse } from "./types/GetUnreadCountResponse";
|
65
68
|
import { GetUnreadRegistrationApplicationCountResponse } from "./types/GetUnreadRegistrationApplicationCountResponse";
|
66
69
|
import { ListCommunitiesResponse } from "./types/ListCommunitiesResponse";
|
67
|
-
import { ListCommunityTags } from "./types/ListCommunityTags";
|
68
|
-
import { ListCommunityTagsResponse } from "./types/ListCommunityTagsResponse";
|
69
70
|
import { ListRegistrationApplicationsResponse } from "./types/ListRegistrationApplicationsResponse";
|
70
71
|
import { LockPost } from "./types/LockPost";
|
71
72
|
import { Login } from "./types/Login";
|
72
73
|
import { LoginResponse } from "./types/LoginResponse";
|
73
|
-
import { MarkCommentReplyAsRead } from "./types/MarkCommentReplyAsRead";
|
74
74
|
import { MarkPostAsRead } from "./types/MarkPostAsRead";
|
75
75
|
import { MarkPrivateMessageAsRead } from "./types/MarkPrivateMessageAsRead";
|
76
76
|
import { PasswordChangeAfterReset } from "./types/PasswordChangeAfterReset";
|
@@ -89,7 +89,7 @@ import { RemoveComment } from "./types/RemoveComment";
|
|
89
89
|
import { RemoveCommunity } from "./types/RemoveCommunity";
|
90
90
|
import { RemovePost } from "./types/RemovePost";
|
91
91
|
import { ResolveCommentReport } from "./types/ResolveCommentReport";
|
92
|
-
import {
|
92
|
+
import { ResolveCommunityReport } from "./types/ResolveCommunityReport";
|
93
93
|
import { ResolvePostReport } from "./types/ResolvePostReport";
|
94
94
|
import { ResolvePrivateMessageReport } from "./types/ResolvePrivateMessageReport";
|
95
95
|
import { SaveComment } from "./types/SaveComment";
|
@@ -99,15 +99,12 @@ import { SearchResponse } from "./types/SearchResponse";
|
|
99
99
|
import { SiteResponse } from "./types/SiteResponse";
|
100
100
|
import { TransferCommunity } from "./types/TransferCommunity";
|
101
101
|
import { UpdateCommunityTag } from "./types/UpdateCommunityTag";
|
102
|
-
import { UpdatePostTags } from "./types/UpdatePostTags";
|
103
102
|
import { VerifyEmail } from "./types/VerifyEmail";
|
104
|
-
import { DeleteImageParamsI, GetCommentI, GetCommentsI, GetCommunityI, GetCommunityPendingFollowsCountI, GetModlogI, GetPersonDetailsI, GetPostI, GetPostsI, GetRandomCommunityI, GetRegistrationApplicationI, GetReportCountI, GetSiteMetadataI, ListCommentLikesI, ListCommunitiesI, ListCommunityPendingFollowsI, ListCustomEmojisI, ListInboxI, ListMediaI, ListPersonContentI, ListPersonSavedI, ListPostLikesI, ListRegistrationApplicationsI, ListReportsI, ListTaglinesI, ResolveObjectI, SearchI, UploadImage } from "./other_types";
|
105
103
|
import { HideCommunity } from "./types/HideCommunity";
|
106
104
|
import { GenerateTotpSecretResponse } from "./types/GenerateTotpSecretResponse";
|
107
105
|
import { UpdateTotp } from "./types/UpdateTotp";
|
108
106
|
import { UpdateTotpResponse } from "./types/UpdateTotpResponse";
|
109
107
|
import { SuccessResponse } from "./types/SuccessResponse";
|
110
|
-
import { LoginToken } from "./types/LoginToken";
|
111
108
|
import { ListPostLikesResponse } from "./types/ListPostLikesResponse";
|
112
109
|
import { ListCommentLikesResponse } from "./types/ListCommentLikesResponse";
|
113
110
|
import { HidePost } from "./types/HidePost";
|
@@ -131,11 +128,22 @@ import { ListPersonContentResponse } from "./types/ListPersonContentResponse";
|
|
131
128
|
import { ListPersonSavedResponse } from "./types/ListPersonSavedResponse";
|
132
129
|
import { UploadImageResponse } from "./types/UploadImageResponse";
|
133
130
|
import { ListInboxResponse } from "./types/ListInboxResponse";
|
134
|
-
import { MarkPersonCommentMentionAsRead } from "./types/MarkPersonCommentMentionAsRead";
|
135
|
-
import { MarkPersonPostMentionAsRead } from "./types/MarkPersonPostMentionAsRead";
|
136
131
|
import { GetCommentsSlimResponse } from "./types/GetCommentsSlimResponse";
|
137
|
-
import {
|
138
|
-
import {
|
132
|
+
import { Tag } from "./types/Tag";
|
133
|
+
import { ResendVerificationEmail } from "./types/ResendVerificationEmail";
|
134
|
+
import { ListPersonReadResponse } from "./types/ListPersonReadResponse";
|
135
|
+
import { ListPersonHiddenResponse } from "./types/ListPersonHiddenResponse";
|
136
|
+
import { CommunityIdQuery } from "./types/CommunityIdQuery";
|
137
|
+
import { CreateMultiCommunity } from "./types/CreateMultiCommunity";
|
138
|
+
import { UpdateMultiCommunity } from "./types/UpdateMultiCommunity";
|
139
|
+
import { ListMultiCommunitiesResponse } from "./types/ListMultiCommunitiesResponse";
|
140
|
+
import { AdminListUsersResponse } from "./types/AdminListUsersResponse";
|
141
|
+
import { CreateOrDeleteMultiCommunityEntry } from "./types/CreateOrDeleteMultiCommunityEntry";
|
142
|
+
import { GetMultiCommunityResponse } from "./types/GetMultiCommunityResponse";
|
143
|
+
import { FollowMultiCommunity } from "./types/FollowMultiCommunity";
|
144
|
+
import { ListLoginsResponse } from "./types/ListLoginsResponse";
|
145
|
+
import { ListPersonLikedResponse } from "./types/ListPersonLikedResponse";
|
146
|
+
import { MarkNotificationAsRead } from "./types/MarkNotificationAsRead";
|
139
147
|
type RequestOptions = Pick<RequestInit, "signal">;
|
140
148
|
/**
|
141
149
|
* Helps build lemmy HTTP requests.
|
@@ -194,19 +202,27 @@ export declare class LemmyHttp extends Controller {
|
|
194
202
|
/**
|
195
203
|
* @summary List login tokens for your user
|
196
204
|
*/
|
197
|
-
listLogins(options?: RequestOptions): Promise<
|
205
|
+
listLogins(options?: RequestOptions): Promise<ListLoginsResponse>;
|
198
206
|
/**
|
199
207
|
* @summary Returns an error message if your auth token is invalid
|
200
208
|
*/
|
201
209
|
validateAuth(options?: RequestOptions): Promise<SuccessResponse>;
|
202
210
|
/**
|
203
|
-
* @summary List all the media for your
|
211
|
+
* @summary List all the media for your account.
|
204
212
|
*/
|
205
213
|
listMedia(form?: ListMediaI, options?: RequestOptions): Promise<ListMediaResponse>;
|
214
|
+
/**
|
215
|
+
* @summary Delete media for your account.
|
216
|
+
*/
|
217
|
+
deleteMedia(form: DeleteImageParamsI, options?: RequestOptions): Promise<SuccessResponse>;
|
218
|
+
/**
|
219
|
+
* @summary Delete any media. (Admin only)
|
220
|
+
*/
|
221
|
+
deleteMediaAdmin(form: DeleteImageParamsI, options?: RequestOptions): Promise<SuccessResponse>;
|
206
222
|
/**
|
207
223
|
* @summary List all the media known to your instance.
|
208
224
|
*/
|
209
|
-
|
225
|
+
listMediaAdmin(form?: ListMediaI, options?: RequestOptions): Promise<ListMediaResponse>;
|
210
226
|
/**
|
211
227
|
* @summary Enable / Disable TOTP / two-factor authentication.
|
212
228
|
*
|
@@ -220,13 +236,13 @@ export declare class LemmyHttp extends Controller {
|
|
220
236
|
*/
|
221
237
|
getModlog(form?: GetModlogI, options?: RequestOptions): Promise<GetModlogResponse>;
|
222
238
|
/**
|
223
|
-
* @summary Search lemmy.
|
239
|
+
* @summary Search lemmy. If `search_term` is a url it also attempts to fetch it, just like `resolve_object`.
|
224
240
|
*/
|
225
241
|
search(form: SearchI, options?: RequestOptions): Promise<SearchResponse>;
|
226
242
|
/**
|
227
243
|
* @summary Fetch a non-local / federated object.
|
228
244
|
*/
|
229
|
-
resolveObject(form: ResolveObjectI, options?: RequestOptions): Promise<
|
245
|
+
resolveObject(form: ResolveObjectI, options?: RequestOptions): Promise<SearchResponse>;
|
230
246
|
/**
|
231
247
|
* @summary Create a new community.
|
232
248
|
*/
|
@@ -291,6 +307,14 @@ export declare class LemmyHttp extends Controller {
|
|
291
307
|
* @summary Get a random community.
|
292
308
|
*/
|
293
309
|
getRandomCommunity(form: GetRandomCommunityI, options?: RequestOptions): Promise<CommunityResponse>;
|
310
|
+
/**
|
311
|
+
* @summary Create a report for a community.
|
312
|
+
*/
|
313
|
+
createCommunityReport(form: CreateCommunityReport, options?: RequestOptions): Promise<CommunityReportResponse>;
|
314
|
+
/**
|
315
|
+
* @summary Resolve a report for a private message.
|
316
|
+
*/
|
317
|
+
resolveCommunityReport(form: ResolveCommunityReport, options?: RequestOptions): Promise<CommunityReportResponse>;
|
294
318
|
/**
|
295
319
|
* @summary Create a post.
|
296
320
|
*/
|
@@ -314,7 +338,7 @@ export declare class LemmyHttp extends Controller {
|
|
314
338
|
/**
|
315
339
|
* @summary Mark a post as read.
|
316
340
|
*/
|
317
|
-
markPostAsRead(form: MarkPostAsRead, options?: RequestOptions): Promise<
|
341
|
+
markPostAsRead(form: MarkPostAsRead, options?: RequestOptions): Promise<PostResponse>;
|
318
342
|
/**
|
319
343
|
* @summary Mark multiple posts as read.
|
320
344
|
*/
|
@@ -375,10 +399,6 @@ export declare class LemmyHttp extends Controller {
|
|
375
399
|
* @summary A moderator remove for a comment.
|
376
400
|
*/
|
377
401
|
removeComment(form: RemoveComment, options?: RequestOptions): Promise<CommentResponse>;
|
378
|
-
/**
|
379
|
-
* @summary Mark a comment as read.
|
380
|
-
*/
|
381
|
-
markCommentReplyAsRead(form: MarkCommentReplyAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
382
402
|
/**
|
383
403
|
* @summary Like / vote on a comment.
|
384
404
|
*/
|
@@ -430,7 +450,7 @@ export declare class LemmyHttp extends Controller {
|
|
430
450
|
/**
|
431
451
|
* @summary Mark a private message as read.
|
432
452
|
*/
|
433
|
-
markPrivateMessageAsRead(form: MarkPrivateMessageAsRead, options?: RequestOptions): Promise<
|
453
|
+
markPrivateMessageAsRead(form: MarkPrivateMessageAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
434
454
|
/**
|
435
455
|
* @summary Create a report for a private message.
|
436
456
|
*/
|
@@ -459,22 +479,14 @@ export declare class LemmyHttp extends Controller {
|
|
459
479
|
* @summary List the content for a person.
|
460
480
|
*/
|
461
481
|
listPersonContent(form?: ListPersonContentI, options?: RequestOptions): Promise<ListPersonContentResponse>;
|
462
|
-
/**
|
463
|
-
* @summary Mark a person mention as read.
|
464
|
-
*/
|
465
|
-
markCommentMentionAsRead(form: MarkPersonCommentMentionAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
466
|
-
/**
|
467
|
-
* @summary Mark a person post body mention as read.
|
468
|
-
*/
|
469
|
-
markPostMentionAsRead(form: MarkPersonPostMentionAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
470
482
|
/**
|
471
483
|
* @summary Ban a person from your site.
|
472
484
|
*/
|
473
485
|
banPerson(form: BanPerson, options?: RequestOptions): Promise<BanPersonResponse>;
|
474
486
|
/**
|
475
|
-
* @summary Get a list of
|
487
|
+
* @summary Get a list of users.
|
476
488
|
*/
|
477
|
-
|
489
|
+
listUsers(form?: AdminListUsersI, options?: RequestOptions): Promise<AdminListUsersResponse>;
|
478
490
|
/**
|
479
491
|
* @summary Block a person.
|
480
492
|
*/
|
@@ -499,6 +511,10 @@ export declare class LemmyHttp extends Controller {
|
|
499
511
|
* @summary Mark all replies as read.
|
500
512
|
*/
|
501
513
|
markAllNotificationsAsRead(options?: RequestOptions): Promise<SuccessResponse>;
|
514
|
+
/**
|
515
|
+
* @summary Mark a comment as read.
|
516
|
+
*/
|
517
|
+
markNotificationAsRead(form: MarkNotificationAsRead, options?: RequestOptions): Promise<SuccessResponse>;
|
502
518
|
/**
|
503
519
|
* @summary Save your user settings.
|
504
520
|
*/
|
@@ -523,10 +539,26 @@ export declare class LemmyHttp extends Controller {
|
|
523
539
|
* @summary Verify your email
|
524
540
|
*/
|
525
541
|
verifyEmail(form: VerifyEmail, options?: RequestOptions): Promise<SuccessResponse>;
|
542
|
+
/**
|
543
|
+
* @summary Resend a verification email.
|
544
|
+
*/
|
545
|
+
resendVerificationEmail(form: ResendVerificationEmail, options?: RequestOptions): Promise<SuccessResponse>;
|
526
546
|
/**
|
527
547
|
* @summary List your saved content.
|
528
548
|
*/
|
529
549
|
listPersonSaved(form: ListPersonSavedI, options?: RequestOptions): Promise<ListPersonSavedResponse>;
|
550
|
+
/**
|
551
|
+
* @summary List your read content.
|
552
|
+
*/
|
553
|
+
listPersonRead(form: ListPersonReadI, options?: RequestOptions): Promise<ListPersonReadResponse>;
|
554
|
+
/**
|
555
|
+
* @summary List your hidden content.
|
556
|
+
*/
|
557
|
+
listPersonHidden(form: ListPersonHiddenI, options?: RequestOptions): Promise<ListPersonHiddenResponse>;
|
558
|
+
/**
|
559
|
+
* @summary List your liked content.
|
560
|
+
*/
|
561
|
+
listPersonLiked(form: ListPersonLikedI, options?: RequestOptions): Promise<ListPersonLikedResponse>;
|
530
562
|
/**
|
531
563
|
* @summary Add an admin to your site.
|
532
564
|
*/
|
@@ -596,25 +628,17 @@ export declare class LemmyHttp extends Controller {
|
|
596
628
|
*/
|
597
629
|
listTaglines(form: ListTaglinesI, options?: RequestOptions): Promise<ListTaglinesResponse>;
|
598
630
|
/**
|
599
|
-
* @summary Create a community tag.
|
600
|
-
*/
|
601
|
-
createCommunityTag(form: CreateCommunityTag, options?: RequestOptions): Promise<CommunityTagResponse>;
|
602
|
-
/**
|
603
|
-
* @summary Update a community tag.
|
631
|
+
* @summary Create a community post tag.
|
604
632
|
*/
|
605
|
-
|
633
|
+
createCommunityTag(form: CreateCommunityTag, options?: RequestOptions): Promise<Tag>;
|
606
634
|
/**
|
607
|
-
* @summary
|
635
|
+
* @summary Update a community post tag.
|
608
636
|
*/
|
609
|
-
|
637
|
+
updateCommunityTag(form: UpdateCommunityTag, options?: RequestOptions): Promise<Tag>;
|
610
638
|
/**
|
611
|
-
* @summary Delete a
|
639
|
+
* @summary Delete a post tag in a community.
|
612
640
|
*/
|
613
|
-
deleteCommunityTag(form: DeleteCommunityTag, options?: RequestOptions): Promise<
|
614
|
-
/**
|
615
|
-
* @summary Update post tags.
|
616
|
-
*/
|
617
|
-
updatePostTags(form: UpdatePostTags, options?: RequestOptions): Promise<PostResponse>;
|
641
|
+
deleteCommunityTag(form: DeleteCommunityTag, options?: RequestOptions): Promise<Tag>;
|
618
642
|
/**
|
619
643
|
* @summary Create a new oauth provider method
|
620
644
|
*/
|
@@ -654,7 +678,7 @@ export declare class LemmyHttp extends Controller {
|
|
654
678
|
/**
|
655
679
|
* @summary Upload new user avatar.
|
656
680
|
*/
|
657
|
-
uploadUserAvatar(image: UploadImage, options?: RequestOptions): Promise<
|
681
|
+
uploadUserAvatar(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
658
682
|
/**
|
659
683
|
* @summary Delete the user avatar.
|
660
684
|
*/
|
@@ -662,7 +686,7 @@ export declare class LemmyHttp extends Controller {
|
|
662
686
|
/**
|
663
687
|
* @summary Upload new user banner.
|
664
688
|
*/
|
665
|
-
uploadUserBanner(image: UploadImage, options?: RequestOptions): Promise<
|
689
|
+
uploadUserBanner(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
666
690
|
/**
|
667
691
|
* @summary Delete the user banner.
|
668
692
|
*/
|
@@ -670,23 +694,23 @@ export declare class LemmyHttp extends Controller {
|
|
670
694
|
/**
|
671
695
|
* @summary Upload new community icon.
|
672
696
|
*/
|
673
|
-
uploadCommunityIcon(image: UploadImage, options?: RequestOptions): Promise<
|
697
|
+
uploadCommunityIcon(query: CommunityIdQueryI, image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
674
698
|
/**
|
675
699
|
* @summary Delete the community icon.
|
676
700
|
*/
|
677
|
-
deleteCommunityIcon(options?: RequestOptions): Promise<SuccessResponse>;
|
701
|
+
deleteCommunityIcon(form: CommunityIdQuery, options?: RequestOptions): Promise<SuccessResponse>;
|
678
702
|
/**
|
679
703
|
* @summary Upload new community banner.
|
680
704
|
*/
|
681
|
-
uploadCommunityBanner(image: UploadImage, options?: RequestOptions): Promise<
|
705
|
+
uploadCommunityBanner(query: CommunityIdQueryI, image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
682
706
|
/**
|
683
707
|
* @summary Delete the community banner.
|
684
708
|
*/
|
685
|
-
deleteCommunityBanner(options?: RequestOptions): Promise<SuccessResponse>;
|
709
|
+
deleteCommunityBanner(form: CommunityIdQuery, options?: RequestOptions): Promise<SuccessResponse>;
|
686
710
|
/**
|
687
711
|
* @summary Upload new site icon.
|
688
712
|
*/
|
689
|
-
uploadSiteIcon(image: UploadImage, options?: RequestOptions): Promise<
|
713
|
+
uploadSiteIcon(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
690
714
|
/**
|
691
715
|
* @summary Delete the site icon.
|
692
716
|
*/
|
@@ -694,7 +718,7 @@ export declare class LemmyHttp extends Controller {
|
|
694
718
|
/**
|
695
719
|
* @summary Upload new site banner.
|
696
720
|
*/
|
697
|
-
uploadSiteBanner(image: UploadImage, options?: RequestOptions): Promise<
|
721
|
+
uploadSiteBanner(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
698
722
|
/**
|
699
723
|
* @summary Delete the site banner.
|
700
724
|
*/
|
@@ -703,14 +727,21 @@ export declare class LemmyHttp extends Controller {
|
|
703
727
|
* @summary Upload an image to the server.
|
704
728
|
*/
|
705
729
|
uploadImage(image: UploadImage, options?: RequestOptions): Promise<UploadImageResponse>;
|
706
|
-
/**
|
707
|
-
* @summary Delete a pictrs image
|
708
|
-
*/
|
709
|
-
deleteImage(form: DeleteImageParamsI, options?: RequestOptions): Promise<SuccessResponse>;
|
710
730
|
/**
|
711
731
|
* @summary Health check for image functionality
|
712
732
|
*/
|
713
733
|
imageHealth(options?: RequestOptions): Promise<SuccessResponse>;
|
734
|
+
/**
|
735
|
+
* Mark donation dialog as shown, so it isn't displayed anymore.
|
736
|
+
*/
|
737
|
+
donationDialogShown(options?: RequestOptions): Promise<SuccessResponse>;
|
738
|
+
createMultiCommunity(form: CreateMultiCommunity, options?: RequestOptions): Promise<GetMultiCommunityResponse>;
|
739
|
+
updateMultiCommunity(form: UpdateMultiCommunity, options?: RequestOptions): Promise<SuccessResponse>;
|
740
|
+
getMultiCommunity(form: GetMultiCommunityI, options?: RequestOptions): Promise<GetMultiCommunityResponse>;
|
741
|
+
createMultiCommunityEntry(form: CreateOrDeleteMultiCommunityEntry, options?: RequestOptions): Promise<SuccessResponse>;
|
742
|
+
deleteMultiCommunityEntry(form: CreateOrDeleteMultiCommunityEntry, options?: RequestOptions): Promise<SuccessResponse>;
|
743
|
+
listMultiCommunities(form: ListMultiCommunitiesI, options?: RequestOptions): Promise<ListMultiCommunitiesResponse>;
|
744
|
+
followMultiCommunity(form: FollowMultiCommunity, options?: RequestOptions): Promise<SuccessResponse>;
|
714
745
|
/**
|
715
746
|
* Set the headers (can be used to set the auth header)
|
716
747
|
*/
|
@@ -718,4 +749,13 @@ export declare class LemmyHttp extends Controller {
|
|
718
749
|
[key: string]: string;
|
719
750
|
}): void;
|
720
751
|
}
|
752
|
+
/**
|
753
|
+
* A Lemmy error type.
|
754
|
+
*
|
755
|
+
* The name is the i18n translatable error code.
|
756
|
+
* The msg is either an empty string, or extra non-translatable info.
|
757
|
+
*/
|
758
|
+
export declare class LemmyError extends Error {
|
759
|
+
constructor(name: string, msg?: string);
|
760
|
+
}
|
721
761
|
export {};
|