e621 2.2.6 → 3.0.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/LICENSE +21 -0
- package/README.md +14 -41
- package/dist/lib/Debug.d.ts +1 -0
- package/dist/lib/Debug.js +16 -0
- package/dist/lib/errors.d.ts +8 -0
- package/dist/lib/errors.js +37 -0
- package/dist/lib/generated/client/client.d.ts +2 -0
- package/dist/lib/generated/client/client.js +236 -0
- package/dist/lib/generated/client/index.d.ts +8 -0
- package/dist/lib/generated/client/index.js +7 -0
- package/dist/lib/generated/client/types.d.ts +117 -0
- package/dist/lib/generated/client/types.js +3 -0
- package/dist/lib/generated/client/utils.d.ts +33 -0
- package/dist/lib/generated/client/utils.js +229 -0
- package/dist/lib/generated/client.d.ts +12 -0
- package/dist/lib/generated/client.js +4 -0
- package/dist/lib/generated/core/auth.d.ts +18 -0
- package/dist/lib/generated/core/auth.js +15 -0
- package/dist/lib/generated/core/bodySerializer.d.ts +25 -0
- package/dist/lib/generated/core/bodySerializer.js +58 -0
- package/dist/lib/generated/core/params.d.ts +43 -0
- package/dist/lib/generated/core/params.js +101 -0
- package/dist/lib/generated/core/pathSerializer.d.ts +33 -0
- package/dist/lib/generated/core/pathSerializer.js +107 -0
- package/dist/lib/generated/core/queryKeySerializer.d.ts +18 -0
- package/dist/lib/generated/core/queryKeySerializer.js +93 -0
- package/dist/lib/generated/core/serverSentEvents.d.ts +71 -0
- package/dist/lib/generated/core/serverSentEvents.js +134 -0
- package/dist/lib/generated/core/types.d.ts +78 -0
- package/dist/lib/generated/core/types.js +3 -0
- package/dist/lib/generated/core/utils.d.ts +19 -0
- package/dist/lib/generated/core/utils.js +88 -0
- package/dist/lib/generated/schemas.d.ts +2989 -0
- package/dist/lib/generated/schemas.js +4014 -0
- package/dist/lib/generated/sdk.d.ts +1417 -0
- package/dist/lib/generated/sdk.js +2633 -0
- package/dist/lib/generated/source.json +18815 -0
- package/dist/lib/generated/types.d.ts +9923 -0
- package/dist/lib/generated/types.js +3 -0
- package/dist/lib/generated.d.ts +4 -0
- package/dist/lib/generated.js +5 -0
- package/dist/lib/index.d.ts +58 -0
- package/dist/lib/index.js +74 -0
- package/dist/lib/models/ApiKey.d.ts +14 -0
- package/dist/lib/models/ApiKey.js +17 -0
- package/dist/lib/models/Artist.d.ts +61 -0
- package/dist/lib/models/Artist.js +86 -0
- package/dist/lib/models/ArtistUrl.d.ts +14 -0
- package/dist/lib/models/ArtistUrl.js +17 -0
- package/dist/lib/models/ArtistVersion.d.ts +14 -0
- package/dist/lib/models/ArtistVersion.js +17 -0
- package/dist/lib/models/AvoidPosting.d.ts +63 -0
- package/dist/lib/models/AvoidPosting.js +97 -0
- package/dist/lib/models/AvoidPostingVersion.d.ts +14 -0
- package/dist/lib/models/AvoidPostingVersion.js +17 -0
- package/dist/lib/models/Ban.d.ts +14 -0
- package/dist/lib/models/Ban.js +17 -0
- package/dist/lib/models/Base.d.ts +11 -0
- package/dist/lib/models/Base.js +39 -0
- package/dist/lib/models/Blip.d.ts +79 -0
- package/dist/lib/models/Blip.js +120 -0
- package/dist/lib/models/BulkUpdateRequest.d.ts +49 -0
- package/dist/lib/models/BulkUpdateRequest.js +75 -0
- package/dist/lib/models/Comment.d.ts +101 -0
- package/dist/lib/models/Comment.js +157 -0
- package/dist/lib/models/CurrentUser.d.ts +14 -0
- package/dist/lib/models/CurrentUser.js +17 -0
- package/dist/lib/models/DMail.d.ts +46 -0
- package/dist/lib/models/DMail.js +73 -0
- package/dist/lib/models/EditHistory.d.ts +14 -0
- package/dist/lib/models/EditHistory.js +17 -0
- package/dist/lib/models/EmailBlacklist.d.ts +26 -0
- package/dist/lib/models/EmailBlacklist.js +37 -0
- package/dist/lib/models/ForumPost.d.ts +98 -0
- package/dist/lib/models/ForumPost.js +154 -0
- package/dist/lib/models/ForumPostVote.d.ts +24 -0
- package/dist/lib/models/ForumPostVote.js +35 -0
- package/dist/lib/models/ForumTopic.d.ts +81 -0
- package/dist/lib/models/ForumTopic.js +131 -0
- package/dist/lib/models/FullCurrentUser.d.ts +14 -0
- package/dist/lib/models/FullCurrentUser.js +17 -0
- package/dist/lib/models/FullUser.d.ts +14 -0
- package/dist/lib/models/FullUser.js +17 -0
- package/dist/lib/models/Help.d.ts +39 -0
- package/dist/lib/models/Help.js +57 -0
- package/dist/lib/models/IpBan.d.ts +28 -0
- package/dist/lib/models/IpBan.js +39 -0
- package/dist/lib/models/IqdbPost.d.ts +14 -0
- package/dist/lib/models/IqdbPost.js +17 -0
- package/dist/lib/models/Mascot.d.ts +39 -0
- package/dist/lib/models/Mascot.js +57 -0
- package/dist/lib/models/ModAction.d.ts +14 -0
- package/dist/lib/models/ModAction.js +17 -0
- package/dist/lib/models/NewsUpdate.d.ts +39 -0
- package/dist/lib/models/NewsUpdate.js +57 -0
- package/dist/lib/models/Note.d.ts +45 -0
- package/dist/lib/models/Note.js +71 -0
- package/dist/lib/models/NoteVersion.d.ts +24 -0
- package/dist/lib/models/NoteVersion.js +35 -0
- package/dist/lib/models/Pool.d.ts +67 -0
- package/dist/lib/models/Pool.js +109 -0
- package/dist/lib/models/PoolVersion.d.ts +24 -0
- package/dist/lib/models/PoolVersion.js +35 -0
- package/dist/lib/models/Post.d.ts +175 -0
- package/dist/lib/models/Post.js +287 -0
- package/dist/lib/models/PostApproval.d.ts +26 -0
- package/dist/lib/models/PostApproval.js +37 -0
- package/dist/lib/models/PostDisapproval.d.ts +14 -0
- package/dist/lib/models/PostDisapproval.js +17 -0
- package/dist/lib/models/PostEvent.d.ts +14 -0
- package/dist/lib/models/PostEvent.js +17 -0
- package/dist/lib/models/PostFlag.d.ts +38 -0
- package/dist/lib/models/PostFlag.js +57 -0
- package/dist/lib/models/PostReplacement.d.ts +75 -0
- package/dist/lib/models/PostReplacement.js +117 -0
- package/dist/lib/models/PostSet.d.ts +75 -0
- package/dist/lib/models/PostSet.js +117 -0
- package/dist/lib/models/PostVersion.d.ts +58 -0
- package/dist/lib/models/PostVersion.js +93 -0
- package/dist/lib/models/RisingSearchTrend.d.ts +14 -0
- package/dist/lib/models/RisingSearchTrend.js +17 -0
- package/dist/lib/models/SearchTrend.d.ts +14 -0
- package/dist/lib/models/SearchTrend.js +17 -0
- package/dist/lib/models/SearchTrendBlacklist.d.ts +14 -0
- package/dist/lib/models/SearchTrendBlacklist.js +17 -0
- package/dist/lib/models/StaffNote.d.ts +53 -0
- package/dist/lib/models/StaffNote.js +79 -0
- package/dist/lib/models/Tag.d.ts +59 -0
- package/dist/lib/models/Tag.js +91 -0
- package/dist/lib/models/TagAlias.d.ts +51 -0
- package/dist/lib/models/TagAlias.js +77 -0
- package/dist/lib/models/TagCorrection.d.ts +15 -0
- package/dist/lib/models/TagCorrection.js +20 -0
- package/dist/lib/models/TagImplication.d.ts +51 -0
- package/dist/lib/models/TagImplication.js +77 -0
- package/dist/lib/models/TagPreview.d.ts +14 -0
- package/dist/lib/models/TagPreview.js +17 -0
- package/dist/lib/models/TagTypeVersion.d.ts +14 -0
- package/dist/lib/models/TagTypeVersion.js +17 -0
- package/dist/lib/models/Takedown.d.ts +87 -0
- package/dist/lib/models/Takedown.js +137 -0
- package/dist/lib/models/Ticket.d.ts +51 -0
- package/dist/lib/models/Ticket.js +77 -0
- package/dist/lib/models/Upload.d.ts +14 -0
- package/dist/lib/models/Upload.js +17 -0
- package/dist/lib/models/UploadWhitelist.d.ts +37 -0
- package/dist/lib/models/UploadWhitelist.js +55 -0
- package/dist/lib/models/User.d.ts +97 -0
- package/dist/lib/models/User.js +160 -0
- package/dist/lib/models/UserFeedback.d.ts +63 -0
- package/dist/lib/models/UserFeedback.js +97 -0
- package/dist/lib/models/UserNameChangeRequest.d.ts +26 -0
- package/dist/lib/models/UserNameChangeRequest.js +37 -0
- package/dist/lib/models/WikiPage.d.ts +49 -0
- package/dist/lib/models/WikiPage.js +75 -0
- package/dist/lib/models/WikiPageVersion.d.ts +24 -0
- package/dist/lib/models/WikiPageVersion.js +35 -0
- package/dist/lib/models/index.d.ts +56 -0
- package/dist/lib/models/index.js +57 -0
- package/dist/lib/modules/ArtistUrls.d.ts +18 -0
- package/dist/lib/modules/ArtistUrls.js +28 -0
- package/dist/lib/modules/ArtistVersions.d.ts +18 -0
- package/dist/lib/modules/ArtistVersions.js +28 -0
- package/dist/lib/modules/Artists.d.ts +90 -0
- package/dist/lib/modules/Artists.js +151 -0
- package/dist/lib/modules/AvoidPostingVersions.d.ts +18 -0
- package/dist/lib/modules/AvoidPostingVersions.js +28 -0
- package/dist/lib/modules/AvoidPostings.d.ts +112 -0
- package/dist/lib/modules/AvoidPostings.js +181 -0
- package/dist/lib/modules/Bans.d.ts +26 -0
- package/dist/lib/modules/Bans.js +47 -0
- package/dist/lib/modules/Base.d.ts +20 -0
- package/dist/lib/modules/Base.js +39 -0
- package/dist/lib/modules/Blips.d.ts +108 -0
- package/dist/lib/modules/Blips.js +188 -0
- package/dist/lib/modules/BulkUpdateRequests.d.ts +76 -0
- package/dist/lib/modules/BulkUpdateRequests.js +136 -0
- package/dist/lib/modules/CommentVotes.d.ts +30 -0
- package/dist/lib/modules/CommentVotes.js +56 -0
- package/dist/lib/modules/Comments.d.ts +115 -0
- package/dist/lib/modules/Comments.js +195 -0
- package/dist/lib/modules/DMails.d.ts +70 -0
- package/dist/lib/modules/DMails.js +134 -0
- package/dist/lib/modules/DText.d.ts +22 -0
- package/dist/lib/modules/DText.js +32 -0
- package/dist/lib/modules/EditHistories.d.ts +34 -0
- package/dist/lib/modules/EditHistories.js +56 -0
- package/dist/lib/modules/EmailBlacklists.d.ts +45 -0
- package/dist/lib/modules/EmailBlacklists.js +74 -0
- package/dist/lib/modules/Favorites.d.ts +44 -0
- package/dist/lib/modules/Favorites.js +73 -0
- package/dist/lib/modules/ForumPosts.d.ts +110 -0
- package/dist/lib/modules/ForumPosts.js +190 -0
- package/dist/lib/modules/ForumTopics.d.ts +125 -0
- package/dist/lib/modules/ForumTopics.js +237 -0
- package/dist/lib/modules/HelpPages.d.ts +67 -0
- package/dist/lib/modules/HelpPages.js +118 -0
- package/dist/lib/modules/IpBans.d.ts +47 -0
- package/dist/lib/modules/IpBans.js +76 -0
- package/dist/lib/modules/IqdbQueries.d.ts +36 -0
- package/dist/lib/modules/IqdbQueries.js +63 -0
- package/dist/lib/modules/Mascots.d.ts +60 -0
- package/dist/lib/modules/Mascots.js +98 -0
- package/dist/lib/modules/ModActions.d.ts +34 -0
- package/dist/lib/modules/ModActions.js +55 -0
- package/dist/lib/modules/NewsUpdates.d.ts +60 -0
- package/dist/lib/modules/NewsUpdates.js +98 -0
- package/dist/lib/modules/NoteVersions.d.ts +18 -0
- package/dist/lib/modules/NoteVersions.js +28 -0
- package/dist/lib/modules/Notes.d.ts +72 -0
- package/dist/lib/modules/Notes.js +133 -0
- package/dist/lib/modules/PoolVersions.d.ts +18 -0
- package/dist/lib/modules/PoolVersions.js +28 -0
- package/dist/lib/modules/Pools.d.ts +107 -0
- package/dist/lib/modules/Pools.js +197 -0
- package/dist/lib/modules/Popular.d.ts +18 -0
- package/dist/lib/modules/Popular.js +31 -0
- package/dist/lib/modules/PostApprovals.d.ts +42 -0
- package/dist/lib/modules/PostApprovals.js +77 -0
- package/dist/lib/modules/PostDisapprovals.d.ts +37 -0
- package/dist/lib/modules/PostDisapprovals.js +55 -0
- package/dist/lib/modules/PostEvents.d.ts +20 -0
- package/dist/lib/modules/PostEvents.js +30 -0
- package/dist/lib/modules/PostFlags.d.ts +53 -0
- package/dist/lib/modules/PostFlags.js +93 -0
- package/dist/lib/modules/PostReplacements.d.ts +97 -0
- package/dist/lib/modules/PostReplacements.js +167 -0
- package/dist/lib/modules/PostSets.d.ts +119 -0
- package/dist/lib/modules/PostSets.js +211 -0
- package/dist/lib/modules/PostVersions.d.ts +51 -0
- package/dist/lib/modules/PostVersions.js +94 -0
- package/dist/lib/modules/PostVotes.d.ts +28 -0
- package/dist/lib/modules/PostVotes.js +54 -0
- package/dist/lib/modules/Posts.d.ts +193 -0
- package/dist/lib/modules/Posts.js +395 -0
- package/dist/lib/modules/RelatedTags.d.ts +22 -0
- package/dist/lib/modules/RelatedTags.js +29 -0
- package/dist/lib/modules/SearchTrendBlacklists.d.ts +64 -0
- package/dist/lib/modules/SearchTrendBlacklists.js +101 -0
- package/dist/lib/modules/SearchTrends.d.ts +57 -0
- package/dist/lib/modules/SearchTrends.js +92 -0
- package/dist/lib/modules/StaffNotes.d.ts +80 -0
- package/dist/lib/modules/StaffNotes.js +140 -0
- package/dist/lib/modules/TagAliases.d.ts +80 -0
- package/dist/lib/modules/TagAliases.js +140 -0
- package/dist/lib/modules/TagCorrections.d.ts +25 -0
- package/dist/lib/modules/TagCorrections.js +52 -0
- package/dist/lib/modules/TagImplications.d.ts +80 -0
- package/dist/lib/modules/TagImplications.js +140 -0
- package/dist/lib/modules/TagTypeVersions.d.ts +18 -0
- package/dist/lib/modules/TagTypeVersions.js +28 -0
- package/dist/lib/modules/Tags.d.ts +64 -0
- package/dist/lib/modules/Tags.js +116 -0
- package/dist/lib/modules/Takedowns.d.ts +123 -0
- package/dist/lib/modules/Takedowns.js +211 -0
- package/dist/lib/modules/Tickets.d.ts +71 -0
- package/dist/lib/modules/Tickets.js +123 -0
- package/dist/lib/modules/UploadWhitelists.d.ts +71 -0
- package/dist/lib/modules/UploadWhitelists.js +117 -0
- package/dist/lib/modules/Uploads.d.ts +42 -0
- package/dist/lib/modules/Uploads.js +78 -0
- package/dist/lib/modules/UserFeedbacks.d.ts +94 -0
- package/dist/lib/modules/UserFeedbacks.js +165 -0
- package/dist/lib/modules/UserNameChangeRequests.d.ts +59 -0
- package/dist/lib/modules/UserNameChangeRequests.js +99 -0
- package/dist/lib/modules/Users.d.ts +135 -0
- package/dist/lib/modules/Users.js +263 -0
- package/dist/lib/modules/WikiPageVersions.d.ts +26 -0
- package/dist/lib/modules/WikiPageVersions.js +47 -0
- package/dist/lib/modules/WikiPages.d.ts +76 -0
- package/dist/lib/modules/WikiPages.js +137 -0
- package/dist/lib/modules/admin/Users.d.ts +45 -0
- package/dist/lib/modules/admin/Users.js +77 -0
- package/dist/lib/modules/comments/Votes.d.ts +31 -0
- package/dist/lib/modules/comments/Votes.js +51 -0
- package/dist/lib/modules/forum_posts/Votes.d.ts +29 -0
- package/dist/lib/modules/forum_posts/Votes.js +51 -0
- package/dist/lib/modules/index.d.ts +178 -0
- package/dist/lib/modules/index.js +118 -0
- package/dist/lib/modules/posts/Flag.d.ts +16 -0
- package/dist/lib/modules/posts/Flag.js +31 -0
- package/dist/lib/modules/posts/Votes.d.ts +31 -0
- package/dist/lib/modules/posts/Votes.js +51 -0
- package/dist/lib/modules/users/DMails.d.ts +29 -0
- package/dist/lib/modules/users/DMails.js +55 -0
- package/dist/lib/util.d.ts +50 -0
- package/dist/lib/util.js +49 -0
- package/dist/package.json +73 -0
- package/package.json +46 -20
- package/tsconfig.json +54 -0
- package/.mocharc.json +0 -6
- package/.ncurc.json +0 -3
- package/.node-version +0 -1
- package/Features/Artists.md +0 -39
- package/Features/Blips.md +0 -33
- package/Features/E621SearchInconsistencies.md +0 -54
- package/Features/FuturePlans.md +0 -50
- package/Features/Notes.md +0 -34
- package/Features/Pools.md +0 -38
- package/Features/PostFlags.md +0 -31
- package/Features/PostSets.md +0 -36
- package/Features/Posts.md +0 -46
- package/Features/README.md +0 -15
- package/Features/Tags.md +0 -34
- package/Features/Takedowns.md +0 -32
- package/Features/UserFeedback.md +0 -32
- package/Features/Users.md +0 -36
- package/Features/WikiPages.md +0 -36
- package/build/package.json +0 -45
- package/build/src/index.d.ts +0 -68
- package/build/src/index.js +0 -194
- package/build/src/modules/Artists.d.ts +0 -128
- package/build/src/modules/Artists.js +0 -295
- package/build/src/modules/Blips.d.ts +0 -79
- package/build/src/modules/Blips.js +0 -157
- package/build/src/modules/Notes.d.ts +0 -88
- package/build/src/modules/Notes.js +0 -189
- package/build/src/modules/Pools.d.ts +0 -130
- package/build/src/modules/Pools.js +0 -261
- package/build/src/modules/PostFlags.d.ts +0 -55
- package/build/src/modules/PostFlags.js +0 -126
- package/build/src/modules/PostSets.d.ts +0 -102
- package/build/src/modules/PostSets.js +0 -208
- package/build/src/modules/Posts.d.ts +0 -154
- package/build/src/modules/Posts.js +0 -390
- package/build/src/modules/Tags.d.ts +0 -78
- package/build/src/modules/Tags.js +0 -174
- package/build/src/modules/Takedowns.d.ts +0 -81
- package/build/src/modules/Takedowns.js +0 -195
- package/build/src/modules/UserFeedback.d.ts +0 -66
- package/build/src/modules/UserFeedback.js +0 -136
- package/build/src/modules/Users.d.ts +0 -117
- package/build/src/modules/Users.js +0 -261
- package/build/src/modules/WikiPages.d.ts +0 -107
- package/build/src/modules/WikiPages.js +0 -220
- package/build/src/structures/Artist.d.ts +0 -36
- package/build/src/structures/Artist.js +0 -51
- package/build/src/structures/ArtistHistory.d.ts +0 -39
- package/build/src/structures/ArtistHistory.js +0 -50
- package/build/src/structures/AuthenticatedUser.d.ts +0 -109
- package/build/src/structures/AuthenticatedUser.js +0 -128
- package/build/src/structures/Blip.d.ts +0 -66
- package/build/src/structures/Blip.js +0 -85
- package/build/src/structures/Note.d.ts +0 -32
- package/build/src/structures/Note.js +0 -41
- package/build/src/structures/NoteHistory.d.ts +0 -38
- package/build/src/structures/NoteHistory.js +0 -47
- package/build/src/structures/Pool.d.ts +0 -85
- package/build/src/structures/Pool.js +0 -112
- package/build/src/structures/PoolHistory.d.ts +0 -43
- package/build/src/structures/PoolHistory.js +0 -54
- package/build/src/structures/Post.d.ts +0 -157
- package/build/src/structures/Post.js +0 -170
- package/build/src/structures/PostApproval.d.ts +0 -25
- package/build/src/structures/PostApproval.js +0 -33
- package/build/src/structures/PostFlag.d.ts +0 -38
- package/build/src/structures/PostFlag.js +0 -47
- package/build/src/structures/PostHistory.d.ts +0 -52
- package/build/src/structures/PostHistory.js +0 -93
- package/build/src/structures/PostSet.d.ts +0 -71
- package/build/src/structures/PostSet.js +0 -93
- package/build/src/structures/Tag.d.ts +0 -61
- package/build/src/structures/Tag.js +0 -87
- package/build/src/structures/TagHistory.d.ts +0 -28
- package/build/src/structures/TagHistory.js +0 -36
- package/build/src/structures/Takedown.d.ts +0 -49
- package/build/src/structures/Takedown.js +0 -64
- package/build/src/structures/User.d.ts +0 -62
- package/build/src/structures/User.js +0 -80
- package/build/src/structures/WikiPage.d.ts +0 -17
- package/build/src/structures/WikiPage.js +0 -27
- package/build/src/structures/WikiPageHistory.d.ts +0 -38
- package/build/src/structures/WikiPageHistory.js +0 -49
- package/build/src/types/artists.d.ts +0 -82
- package/build/src/types/blips.d.ts +0 -37
- package/build/src/types/index.d.ts +0 -96
- package/build/src/types/notes.d.ts +0 -64
- package/build/src/types/pools.d.ts +0 -62
- package/build/src/types/post_flags.d.ts +0 -36
- package/build/src/types/post_sets.d.ts +0 -33
- package/build/src/types/posts.d.ts +0 -181
- package/build/src/types/tags.d.ts +0 -56
- package/build/src/types/takedowns.d.ts +0 -62
- package/build/src/types/user_feedback.d.ts +0 -27
- package/build/src/types/users.d.ts +0 -277
- package/build/src/types/wiki_pages.d.ts +0 -66
- package/build/src/util/Debug.d.ts +0 -1
- package/build/src/util/Debug.js +0 -16
- package/build/src/util/FormHelper.d.ts +0 -9
- package/build/src/util/FormHelper.js +0 -15
- package/build/src/util/MultipartData.d.ts +0 -7
- package/build/src/util/MultipartData.js +0 -39
- package/build/src/util/RequestHandler.d.ts +0 -38
- package/build/src/util/RequestHandler.js +0 -343
- package/build/src/util/Timer.d.ts +0 -6
- package/build/src/util/Timer.js +0 -74
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { __decorate, __metadata } from "tslib";
|
|
2
|
+
import Base from "./Base.js";
|
|
3
|
+
import { clearPostFlagNote, createPostFlag, getPostFlag, searchPostFlags } from "../generated/sdk.js";
|
|
4
|
+
import { OperationID, prefixKeys } from "../util.js";
|
|
5
|
+
import PostFlag from "../models/PostFlag.js";
|
|
6
|
+
/** @category Modules */
|
|
7
|
+
export default class PostFlags extends Base {
|
|
8
|
+
/**
|
|
9
|
+
* Clear Post Flag Note
|
|
10
|
+
*
|
|
11
|
+
* You must be Janitor+
|
|
12
|
+
*
|
|
13
|
+
* @requiresApiKeyAuth
|
|
14
|
+
*
|
|
15
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Flags-clearPostFlagNote clearPostFlagNote}
|
|
16
|
+
*
|
|
17
|
+
* @see {@link https://e621.wiki/#operations-Post_Flags-clearPostFlagNote Documentation} for more details.
|
|
18
|
+
*/
|
|
19
|
+
async clearNote(id) {
|
|
20
|
+
return clearPostFlagNote({
|
|
21
|
+
client: this.client,
|
|
22
|
+
path: { id }
|
|
23
|
+
}).then(res => this._handleResponse(res, 200, true, PostFlag));
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Create Post Flag
|
|
27
|
+
*
|
|
28
|
+
* Will error if post_id is not provided.
|
|
29
|
+
*
|
|
30
|
+
* @requiresApiKeyAuth
|
|
31
|
+
*
|
|
32
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Flags-createPostFlag createPostFlag}
|
|
33
|
+
*
|
|
34
|
+
* @see {@link https://e621.wiki/#operations-Post_Flags-createPostFlag Documentation} for more details.
|
|
35
|
+
*/
|
|
36
|
+
async create(options) {
|
|
37
|
+
return createPostFlag({
|
|
38
|
+
client: this.client,
|
|
39
|
+
body: prefixKeys(options, "post_flag")
|
|
40
|
+
}).then(res => this._handleResponse(res, 201, true, PostFlag));
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Get Post Flag
|
|
44
|
+
*
|
|
45
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Flags-getPostFlag getPostFlag}
|
|
46
|
+
*
|
|
47
|
+
* @see {@link https://e621.wiki/#operations-Post_Flags-getPostFlag Documentation} for more details.
|
|
48
|
+
*/
|
|
49
|
+
async get(id) {
|
|
50
|
+
return getPostFlag({
|
|
51
|
+
client: this.client,
|
|
52
|
+
path: { id }
|
|
53
|
+
}).then(res => this._handleResponse(res, 200, false, PostFlag));
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Search Post Flags
|
|
57
|
+
*
|
|
58
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Flags-searchPostFlags searchPostFlags}
|
|
59
|
+
*
|
|
60
|
+
* @see {@link https://e621.wiki/#operations-Post_Flags-searchPostFlags Documentation} for more details.
|
|
61
|
+
*/
|
|
62
|
+
async search(options) {
|
|
63
|
+
return searchPostFlags({
|
|
64
|
+
client: this.client,
|
|
65
|
+
query: prefixKeys(options, "search", ["limit", "page"])
|
|
66
|
+
}).then(res => this._handleResponse(res, 200, true, PostFlag));
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
__decorate([
|
|
70
|
+
OperationID("clearPostFlagNote"),
|
|
71
|
+
__metadata("design:type", Function),
|
|
72
|
+
__metadata("design:paramtypes", [Number]),
|
|
73
|
+
__metadata("design:returntype", Promise)
|
|
74
|
+
], PostFlags.prototype, "clearNote", null);
|
|
75
|
+
__decorate([
|
|
76
|
+
OperationID("createPostFlag"),
|
|
77
|
+
__metadata("design:type", Function),
|
|
78
|
+
__metadata("design:paramtypes", [Object]),
|
|
79
|
+
__metadata("design:returntype", Promise)
|
|
80
|
+
], PostFlags.prototype, "create", null);
|
|
81
|
+
__decorate([
|
|
82
|
+
OperationID("getPostFlag"),
|
|
83
|
+
__metadata("design:type", Function),
|
|
84
|
+
__metadata("design:paramtypes", [Number]),
|
|
85
|
+
__metadata("design:returntype", Promise)
|
|
86
|
+
], PostFlags.prototype, "get", null);
|
|
87
|
+
__decorate([
|
|
88
|
+
OperationID("searchPostFlags"),
|
|
89
|
+
__metadata("design:type", Function),
|
|
90
|
+
__metadata("design:paramtypes", [Object]),
|
|
91
|
+
__metadata("design:returntype", Promise)
|
|
92
|
+
], PostFlags.prototype, "search", null);
|
|
93
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiUG9zdEZsYWdzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vbGliL21vZHV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CLENBQUM7Ozs7dUNBTTNCIn0=
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import Base from "./Base.js";
|
|
2
|
+
import { GetResponse, type TransformDataBodyToOptions, type TransformDataQueryToOptions } from "../util.js";
|
|
3
|
+
import { type CreatePostReplacementResponses, type SearchPostReplacementsData, type CreatePostReplacementData } from "../generated/types.js";
|
|
4
|
+
import PostReplacement from "../models/PostReplacement.js";
|
|
5
|
+
import Post from "../models/Post.js";
|
|
6
|
+
/** @category Modules/Types */
|
|
7
|
+
export interface CreatePostReplacementOptions extends TransformDataBodyToOptions<CreatePostReplacementData> {
|
|
8
|
+
}
|
|
9
|
+
/** @category Modules/Types */
|
|
10
|
+
export interface SearchPostReplacementsOptions extends TransformDataQueryToOptions<SearchPostReplacementsData> {
|
|
11
|
+
}
|
|
12
|
+
/** @category Modules/Types */
|
|
13
|
+
export interface CreatePostReplacementResponse extends GetResponse<CreatePostReplacementResponses, 200> {
|
|
14
|
+
}
|
|
15
|
+
/** @category Modules */
|
|
16
|
+
export default class PostReplacements extends Base {
|
|
17
|
+
/**
|
|
18
|
+
* Approve Post Replacement
|
|
19
|
+
*
|
|
20
|
+
* You must have the "Approve Posts" permission.
|
|
21
|
+
*
|
|
22
|
+
* @requiresApiKeyAuth
|
|
23
|
+
*
|
|
24
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-approvePostReplacement approvePostReplacement}
|
|
25
|
+
*
|
|
26
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-approvePostReplacement Documentation} for more details.
|
|
27
|
+
*/
|
|
28
|
+
approve(id: number): Promise<null>;
|
|
29
|
+
/**
|
|
30
|
+
* Create Post Replacement
|
|
31
|
+
*
|
|
32
|
+
* @requiresApiKeyAuth
|
|
33
|
+
*
|
|
34
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-createPostReplacement createPostReplacement}
|
|
35
|
+
*
|
|
36
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-createPostReplacement Documentation} for more details.
|
|
37
|
+
*/
|
|
38
|
+
create(options: CreatePostReplacementOptions): Promise<CreatePostReplacementResponse>;
|
|
39
|
+
/**
|
|
40
|
+
* Delete Post Replacement
|
|
41
|
+
*
|
|
42
|
+
* You must be Admin+.
|
|
43
|
+
*
|
|
44
|
+
* @requiresApiKeyAuth
|
|
45
|
+
*
|
|
46
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-deletePostReplacement deletePostReplacement}
|
|
47
|
+
*
|
|
48
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-deletePostReplacement Documentation} for more details.
|
|
49
|
+
*/
|
|
50
|
+
delete(id: number): Promise<null>;
|
|
51
|
+
/**
|
|
52
|
+
* Promote Post Replacement
|
|
53
|
+
*
|
|
54
|
+
* You must have the "Approve Posts" permission.
|
|
55
|
+
*
|
|
56
|
+
* @requiresApiKeyAuth
|
|
57
|
+
*
|
|
58
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-promotePostReplacement promotePostReplacement}
|
|
59
|
+
*
|
|
60
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-promotePostReplacement Documentation} for more details.
|
|
61
|
+
*/
|
|
62
|
+
promote(id: number): Promise<Post>;
|
|
63
|
+
/**
|
|
64
|
+
* Reject Post Replacement
|
|
65
|
+
*
|
|
66
|
+
* You must have the "Approve Posts" permission.
|
|
67
|
+
*
|
|
68
|
+
* @requiresApiKeyAuth
|
|
69
|
+
*
|
|
70
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-rejectPostReplacement rejectPostReplacement}
|
|
71
|
+
*
|
|
72
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-rejectPostReplacement Documentation} for more details.
|
|
73
|
+
*/
|
|
74
|
+
reject(id: number): Promise<null>;
|
|
75
|
+
/**
|
|
76
|
+
* Search Post Replacements
|
|
77
|
+
*
|
|
78
|
+
* Rejected replacements can only be seen by staff.
|
|
79
|
+
*
|
|
80
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-searchPostReplacements searchPostReplacements}
|
|
81
|
+
*
|
|
82
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-searchPostReplacements Documentation} for more details.
|
|
83
|
+
*/
|
|
84
|
+
search(options?: SearchPostReplacementsOptions): Promise<Array<PostReplacement>>;
|
|
85
|
+
/**
|
|
86
|
+
* Toggle Post Replacement Penalty
|
|
87
|
+
*
|
|
88
|
+
* You must have the "Approve Posts" permission.
|
|
89
|
+
*
|
|
90
|
+
* @requiresApiKeyAuth
|
|
91
|
+
*
|
|
92
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-togglePostReplacementPenalty togglePostReplacementPenalty}
|
|
93
|
+
*
|
|
94
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-togglePostReplacementPenalty Documentation} for more details.
|
|
95
|
+
*/
|
|
96
|
+
togglePenalize(id: number): Promise<null>;
|
|
97
|
+
}
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import { __decorate, __metadata } from "tslib";
|
|
2
|
+
import Base from "./Base.js";
|
|
3
|
+
import { approvePostReplacement, createPostReplacement, deletePostReplacement, promotePostReplacement, rejectPostReplacement, searchPostReplacements, togglePostReplacementPenalty } from "../generated/sdk.js";
|
|
4
|
+
import { OperationID, prefixKeys } from "../util.js";
|
|
5
|
+
import PostReplacement from "../models/PostReplacement.js";
|
|
6
|
+
import Post from "../models/Post.js";
|
|
7
|
+
/** @category Modules */
|
|
8
|
+
export default class PostReplacements extends Base {
|
|
9
|
+
/**
|
|
10
|
+
* Approve Post Replacement
|
|
11
|
+
*
|
|
12
|
+
* You must have the "Approve Posts" permission.
|
|
13
|
+
*
|
|
14
|
+
* @requiresApiKeyAuth
|
|
15
|
+
*
|
|
16
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-approvePostReplacement approvePostReplacement}
|
|
17
|
+
*
|
|
18
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-approvePostReplacement Documentation} for more details.
|
|
19
|
+
*/
|
|
20
|
+
async approve(id) {
|
|
21
|
+
return approvePostReplacement({
|
|
22
|
+
client: this.client,
|
|
23
|
+
path: { id }
|
|
24
|
+
}).then(res => this._handleResponse(res, 204, true));
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Create Post Replacement
|
|
28
|
+
*
|
|
29
|
+
* @requiresApiKeyAuth
|
|
30
|
+
*
|
|
31
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-createPostReplacement createPostReplacement}
|
|
32
|
+
*
|
|
33
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-createPostReplacement Documentation} for more details.
|
|
34
|
+
*/
|
|
35
|
+
async create(options) {
|
|
36
|
+
return createPostReplacement({
|
|
37
|
+
client: this.client,
|
|
38
|
+
body: prefixKeys(options, "post_replacement")
|
|
39
|
+
}).then(res => this._handleResponse(res, 200, true));
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Delete Post Replacement
|
|
43
|
+
*
|
|
44
|
+
* You must be Admin+.
|
|
45
|
+
*
|
|
46
|
+
* @requiresApiKeyAuth
|
|
47
|
+
*
|
|
48
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-deletePostReplacement deletePostReplacement}
|
|
49
|
+
*
|
|
50
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-deletePostReplacement Documentation} for more details.
|
|
51
|
+
*/
|
|
52
|
+
async delete(id) {
|
|
53
|
+
return deletePostReplacement({
|
|
54
|
+
client: this.client,
|
|
55
|
+
path: { id }
|
|
56
|
+
}).then(res => this._handleResponse(res, 204, true));
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Promote Post Replacement
|
|
60
|
+
*
|
|
61
|
+
* You must have the "Approve Posts" permission.
|
|
62
|
+
*
|
|
63
|
+
* @requiresApiKeyAuth
|
|
64
|
+
*
|
|
65
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-promotePostReplacement promotePostReplacement}
|
|
66
|
+
*
|
|
67
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-promotePostReplacement Documentation} for more details.
|
|
68
|
+
*/
|
|
69
|
+
async promote(id) {
|
|
70
|
+
return promotePostReplacement({
|
|
71
|
+
client: this.client,
|
|
72
|
+
path: { id }
|
|
73
|
+
}).then(res => new Post(this.e621, this._handleResponse(res, 201, true).post));
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* Reject Post Replacement
|
|
77
|
+
*
|
|
78
|
+
* You must have the "Approve Posts" permission.
|
|
79
|
+
*
|
|
80
|
+
* @requiresApiKeyAuth
|
|
81
|
+
*
|
|
82
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-rejectPostReplacement rejectPostReplacement}
|
|
83
|
+
*
|
|
84
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-rejectPostReplacement Documentation} for more details.
|
|
85
|
+
*/
|
|
86
|
+
async reject(id) {
|
|
87
|
+
return rejectPostReplacement({
|
|
88
|
+
client: this.client,
|
|
89
|
+
path: { id }
|
|
90
|
+
}).then(res => this._handleResponse(res, 204, true));
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Search Post Replacements
|
|
94
|
+
*
|
|
95
|
+
* Rejected replacements can only be seen by staff.
|
|
96
|
+
*
|
|
97
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-searchPostReplacements searchPostReplacements}
|
|
98
|
+
*
|
|
99
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-searchPostReplacements Documentation} for more details.
|
|
100
|
+
*/
|
|
101
|
+
async search(options) {
|
|
102
|
+
return searchPostReplacements({
|
|
103
|
+
client: this.client,
|
|
104
|
+
query: prefixKeys(options, "search", ["limit", "page"])
|
|
105
|
+
}).then(res => this._handleResponse(res, 200, true, PostReplacement));
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Toggle Post Replacement Penalty
|
|
109
|
+
*
|
|
110
|
+
* You must have the "Approve Posts" permission.
|
|
111
|
+
*
|
|
112
|
+
* @requiresApiKeyAuth
|
|
113
|
+
*
|
|
114
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Replacements-togglePostReplacementPenalty togglePostReplacementPenalty}
|
|
115
|
+
*
|
|
116
|
+
* @see {@link https://e621.wiki/#operations-Post_Replacements-togglePostReplacementPenalty Documentation} for more details.
|
|
117
|
+
*/
|
|
118
|
+
async togglePenalize(id) {
|
|
119
|
+
return togglePostReplacementPenalty({
|
|
120
|
+
client: this.client,
|
|
121
|
+
path: { id }
|
|
122
|
+
}).then(res => this._handleResponse(res, 204, true));
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
__decorate([
|
|
126
|
+
OperationID("approvePostReplacement"),
|
|
127
|
+
__metadata("design:type", Function),
|
|
128
|
+
__metadata("design:paramtypes", [Number]),
|
|
129
|
+
__metadata("design:returntype", Promise)
|
|
130
|
+
], PostReplacements.prototype, "approve", null);
|
|
131
|
+
__decorate([
|
|
132
|
+
OperationID("createPostReplacement"),
|
|
133
|
+
__metadata("design:type", Function),
|
|
134
|
+
__metadata("design:paramtypes", [Object]),
|
|
135
|
+
__metadata("design:returntype", Promise)
|
|
136
|
+
], PostReplacements.prototype, "create", null);
|
|
137
|
+
__decorate([
|
|
138
|
+
OperationID("deletePostReplacement"),
|
|
139
|
+
__metadata("design:type", Function),
|
|
140
|
+
__metadata("design:paramtypes", [Number]),
|
|
141
|
+
__metadata("design:returntype", Promise)
|
|
142
|
+
], PostReplacements.prototype, "delete", null);
|
|
143
|
+
__decorate([
|
|
144
|
+
OperationID("promotePostReplacement"),
|
|
145
|
+
__metadata("design:type", Function),
|
|
146
|
+
__metadata("design:paramtypes", [Number]),
|
|
147
|
+
__metadata("design:returntype", Promise)
|
|
148
|
+
], PostReplacements.prototype, "promote", null);
|
|
149
|
+
__decorate([
|
|
150
|
+
OperationID("rejectPostReplacement"),
|
|
151
|
+
__metadata("design:type", Function),
|
|
152
|
+
__metadata("design:paramtypes", [Number]),
|
|
153
|
+
__metadata("design:returntype", Promise)
|
|
154
|
+
], PostReplacements.prototype, "reject", null);
|
|
155
|
+
__decorate([
|
|
156
|
+
OperationID("searchPostReplacements"),
|
|
157
|
+
__metadata("design:type", Function),
|
|
158
|
+
__metadata("design:paramtypes", [Object]),
|
|
159
|
+
__metadata("design:returntype", Promise)
|
|
160
|
+
], PostReplacements.prototype, "search", null);
|
|
161
|
+
__decorate([
|
|
162
|
+
OperationID("togglePostReplacementPenalty"),
|
|
163
|
+
__metadata("design:type", Function),
|
|
164
|
+
__metadata("design:paramtypes", [Number]),
|
|
165
|
+
__metadata("design:returntype", Promise)
|
|
166
|
+
], PostReplacements.prototype, "togglePenalize", null);
|
|
167
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiUG9zdFJlcGxhY2VtZW50cy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL2xpYi9tb2R1bGVzL1Bvc3RSZXBsYWNlbWVudHMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLE9BQU8sSUFBSSxNQUFNLFdBQVcsQ0FBQztBQUM3QixPQUFPLEVBQ0gsc0JBQXNCLEVBQ3RCLHFCQUFxQixFQUNyQixxQkFBcUIsRUFDckIsc0JBQXNCLEVBQ3RCLHFCQUFxQixFQUNyQixzQkFBc0IsRUFDdEIsNEJBQTRCLEVBQy9CLE1BQU0scUJBQXFCLENBQUM7QUFDN0IsT0FBTyxFQUVILFdBQVcsRUFDWCxVQUFVLEVBR2IsTUFBTSxZQUFZLENBQUM7QUFFcEIsT0FBTyxlQUFlLE1BQU0sOEJBQThCLENBQUM7QUFDM0QsT0FBTyxJQUFJLE1BQU0sbUJBQW1CLENBQUM7QUFTckMsd0JBQXdCO0FBQ3hCLE1BQU0sQ0FBQyxPQUFPLE9BQU8sZ0JBQWlCLFNBQVEsSUFBSTtJQUM5Qzs7Ozs7Ozs7OztPQVVBO0lBRU0sQUFBTixLQUF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BQyxHQUFHLEVBQUUsR0FBRyxFQUFFLElBQUksRUFBRSxlQUFlLENBQUMsQ0FBQyxDQUFDO0lBQzFFLENBQUM7SUFFRDs7Ozs7Ozs7OztPQVVBO0lBRU0sQUFBTixLQUFLLENBQUMsY0FBYyxDQUFDLEVBQVU7UUFDM0IsT0FBTyw0QkFBNEIsQ0FBQztZQUNoQyxNQUFNLEVBQUUsSUFBSSxDQUFDLE1BQU07WUFDbkIsSUFBSSxFQUFJLEVBQUUsRUFBRSxFQUFFO1NBQ2pCLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLEVBQUUsQ0FBQyxJQUFJLENBQUMsZUFBZSxDQUFDLEdBQUcsRUFBRSxHQUFHLEVBQUUsSUFBSSxDQUFDLENBQUMsQ0FBQztJQUN6RCxDQUFDO0NBQ0o7QUFwSFM7SUFEUixXQUFXLENBQUMsd0JBQXdCLENBQUM7Ozs7K0NBTWxDO0FBWUs7SUFEUixXQUFXLENBQUMsdUJBQXVCLENBQUM7Ozs7OENBTWpDO0FBY0s7SUFEUixXQUFXLENBQUMsdUJBQXVCLENBQUM7Ozs7OENBTWpDO0FBY0s7SUFEUixXQUFXLENBQUMsd0JBQXdCLENBQUM7Ozs7K0NBTWxDO0FBY0s7SUFEUixXQUFXLENBQUMsdUJBQXVCLENBQUM7Ozs7OENBTWpDO0FBWUs7SUFEUixXQUFXLENBQUMsd0JBQXdCLENBQUM7Ozs7OENBTWxDO0FBY0s7SUFEUixXQUFXLENBQUMsOEJBQThCLENBQUM7Ozs7c0RBTXhDIn0=
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import Base from "./Base.js";
|
|
2
|
+
import type { CreatePostSetData, EditPostSetData, ListPostSetsForSelectResponses, SearchPostSetsData } from "../generated/types.js";
|
|
3
|
+
import { GetResponse, type TransformDataBodyToOptions, type TransformDataQueryToOptions } from "../util.js";
|
|
4
|
+
import PostSet from "../models/PostSet.js";
|
|
5
|
+
/** @category Modules/Types */
|
|
6
|
+
export interface CreatePostSetOptions extends TransformDataBodyToOptions<CreatePostSetData> {
|
|
7
|
+
}
|
|
8
|
+
/** @category Modules/Types */
|
|
9
|
+
export interface EditPostSetOptions extends TransformDataBodyToOptions<EditPostSetData> {
|
|
10
|
+
}
|
|
11
|
+
/** @category Modules/Types */
|
|
12
|
+
export interface SearchPostSetsOptions extends TransformDataQueryToOptions<SearchPostSetsData> {
|
|
13
|
+
}
|
|
14
|
+
/** @category Modules/Types */
|
|
15
|
+
export interface ListPostSetsForSelectResponse extends GetResponse<ListPostSetsForSelectResponses, 200> {
|
|
16
|
+
}
|
|
17
|
+
/** @category Modules */
|
|
18
|
+
export default class PostSets extends Base {
|
|
19
|
+
/**
|
|
20
|
+
* Add Posts To Post Set
|
|
21
|
+
*
|
|
22
|
+
* You must be the owner of the set, a maintainer (if public), or Admin+.
|
|
23
|
+
*
|
|
24
|
+
* @requiresApiKeyAuth
|
|
25
|
+
*
|
|
26
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-addPostsToPostSet addPostsToPostSet}
|
|
27
|
+
*
|
|
28
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-addPostsToPostSet Documentation} for more details.
|
|
29
|
+
*/
|
|
30
|
+
addPosts(id: number, post_ids: Array<number>): Promise<PostSet>;
|
|
31
|
+
/**
|
|
32
|
+
* Create Post Set
|
|
33
|
+
*
|
|
34
|
+
* @requiresApiKeyAuth
|
|
35
|
+
*
|
|
36
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-createPostSet createPostSet}
|
|
37
|
+
*
|
|
38
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-createPostSet Documentation} for more details.
|
|
39
|
+
*/
|
|
40
|
+
create(options: CreatePostSetOptions): Promise<PostSet>;
|
|
41
|
+
/**
|
|
42
|
+
* Delete Post Set
|
|
43
|
+
*
|
|
44
|
+
* You must be the owner of the set, or Admin+.
|
|
45
|
+
*
|
|
46
|
+
* @requiresApiKeyAuth
|
|
47
|
+
*
|
|
48
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-deletePostSet deletePostSet}
|
|
49
|
+
*
|
|
50
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-deletePostSet Documentation} for more details.
|
|
51
|
+
*/
|
|
52
|
+
delete(id: number): Promise<null>;
|
|
53
|
+
/**
|
|
54
|
+
* Edit Post Set
|
|
55
|
+
*
|
|
56
|
+
* You must be the owner of the set, or Admin+.
|
|
57
|
+
*
|
|
58
|
+
* @requiresApiKeyAuth
|
|
59
|
+
*
|
|
60
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-editPostSet editPostSet}
|
|
61
|
+
*
|
|
62
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-editPostSet Documentation} for more details.
|
|
63
|
+
*/
|
|
64
|
+
edit(id: number, options: EditPostSetOptions): Promise<null>;
|
|
65
|
+
/**
|
|
66
|
+
* List Post Sets For Select
|
|
67
|
+
*
|
|
68
|
+
* You must be the owner of the set, a maintainer (if public), or Admin+.
|
|
69
|
+
*
|
|
70
|
+
* @requiresApiKeyAuth
|
|
71
|
+
*
|
|
72
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-listPostSetsForSelect listPostSetsForSelect}
|
|
73
|
+
*
|
|
74
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-listPostSetsForSelect Documentation} for more details.
|
|
75
|
+
*/
|
|
76
|
+
forSelect(): Promise<ListPostSetsForSelectResponse>;
|
|
77
|
+
/**
|
|
78
|
+
* Get Post Set
|
|
79
|
+
*
|
|
80
|
+
* You must be Moderator+ if the set is not public.
|
|
81
|
+
*
|
|
82
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-getPostSet getPostSet}
|
|
83
|
+
*
|
|
84
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-getPostSet Documentation} for more details.
|
|
85
|
+
*/
|
|
86
|
+
get(id: number): Promise<PostSet | null>;
|
|
87
|
+
/**
|
|
88
|
+
* Remove Posts From Post Set
|
|
89
|
+
*
|
|
90
|
+
* You must be the owner of the set, a maintainer (if public), or Admin+.
|
|
91
|
+
*
|
|
92
|
+
* @requiresApiKeyAuth
|
|
93
|
+
*
|
|
94
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-removePostsFromPostSet removePostsFromPostSet}
|
|
95
|
+
*
|
|
96
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-removePostsFromPostSet Documentation} for more details.
|
|
97
|
+
*/
|
|
98
|
+
removePosts(id: number, post_ids: Array<number>): Promise<PostSet>;
|
|
99
|
+
/**
|
|
100
|
+
* Search Post Sets
|
|
101
|
+
*
|
|
102
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-searchPostSets searchPostSets}
|
|
103
|
+
*
|
|
104
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-searchPostSets Documentation} for more details.
|
|
105
|
+
*/
|
|
106
|
+
search(options?: SearchPostSetsOptions): Promise<Array<PostSet>>;
|
|
107
|
+
/**
|
|
108
|
+
* Update Post Set Posts
|
|
109
|
+
*
|
|
110
|
+
* You must be the owner of the set, a maintainer (if public), or Admin+.
|
|
111
|
+
*
|
|
112
|
+
* @requiresApiKeyAuth
|
|
113
|
+
*
|
|
114
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Sets-updatePostSetPosts updatePostSetPosts}
|
|
115
|
+
*
|
|
116
|
+
* @see {@link https://e621.wiki/#operations-Post_Sets-updatePostSetPosts Documentation} for more details.
|
|
117
|
+
*/
|
|
118
|
+
updatePosts(id: number, post_ids: Array<number>): Promise<PostSet>;
|
|
119
|
+
}
|