e621 3.1.0 → 3.2.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 +68 -0
- package/dist/browser/e621.d.ts +2 -0
- package/dist/browser/e621.js +19346 -0
- package/dist/browser/e621.js.map +7 -0
- package/dist/lib/Debug.browser.d.ts +6 -0
- package/dist/lib/Debug.browser.js +8 -0
- package/dist/lib/client.d.ts +68 -0
- package/dist/lib/client.js +72 -0
- package/dist/lib/generated/schemas.d.ts +7 -2
- package/dist/lib/generated/schemas.js +17 -10
- package/dist/lib/generated/types.d.ts +53 -57
- package/dist/lib/index.d.ts +6 -46
- package/dist/lib/index.js +6 -62
- package/dist/lib/models/Appeal.d.ts +6 -9
- package/dist/lib/models/Appeal.js +7 -10
- package/dist/lib/models/Artist.d.ts +6 -9
- package/dist/lib/models/Artist.js +7 -10
- package/dist/lib/models/AvoidPosting.d.ts +8 -12
- package/dist/lib/models/AvoidPosting.js +9 -13
- package/dist/lib/models/Base.browser.d.ts +15 -0
- package/dist/lib/models/Base.browser.js +22 -0
- package/dist/lib/models/Base.d.ts +4 -3
- package/dist/lib/models/Base.js +1 -1
- package/dist/lib/models/BasicPost.d.ts +2 -1
- package/dist/lib/models/BasicPost.js +1 -1
- package/dist/lib/models/Blip.d.ts +10 -15
- package/dist/lib/models/Blip.js +11 -16
- package/dist/lib/models/BulkUpdateRequest.d.ts +6 -9
- package/dist/lib/models/BulkUpdateRequest.js +7 -10
- package/dist/lib/models/Comment.d.ts +14 -21
- package/dist/lib/models/Comment.js +15 -22
- package/dist/lib/models/CommentVote.d.ts +6 -9
- package/dist/lib/models/CommentVote.js +7 -10
- package/dist/lib/models/CurrentUser.d.ts +6 -9
- package/dist/lib/models/CurrentUser.js +7 -10
- package/dist/lib/models/DMail.d.ts +8 -12
- package/dist/lib/models/DMail.js +9 -13
- package/dist/lib/models/EmailBlacklist.d.ts +2 -3
- package/dist/lib/models/EmailBlacklist.js +3 -4
- package/dist/lib/models/ExtendedPost.d.ts +2 -1
- package/dist/lib/models/ExtendedPost.js +1 -1
- package/dist/lib/models/ForumPost.d.ts +16 -24
- package/dist/lib/models/ForumPost.js +17 -25
- package/dist/lib/models/ForumPostVote.d.ts +2 -3
- package/dist/lib/models/ForumPostVote.js +3 -4
- package/dist/lib/models/ForumTopic.d.ts +12 -18
- package/dist/lib/models/ForumTopic.js +13 -19
- package/dist/lib/models/HelpPage.d.ts +4 -6
- package/dist/lib/models/HelpPage.js +5 -7
- package/dist/lib/models/IpBan.d.ts +2 -3
- package/dist/lib/models/IpBan.js +3 -4
- package/dist/lib/models/Mascot.d.ts +4 -6
- package/dist/lib/models/Mascot.js +5 -7
- package/dist/lib/models/NewsUpdate.d.ts +4 -6
- package/dist/lib/models/NewsUpdate.js +5 -7
- package/dist/lib/models/Note.d.ts +6 -9
- package/dist/lib/models/Note.js +7 -10
- package/dist/lib/models/NoteVersion.d.ts +2 -3
- package/dist/lib/models/NoteVersion.js +3 -4
- package/dist/lib/models/Pool.d.ts +10 -15
- package/dist/lib/models/Pool.js +11 -16
- package/dist/lib/models/PoolVersion.d.ts +2 -3
- package/dist/lib/models/PoolVersion.js +3 -4
- package/dist/lib/models/Post.d.ts +2 -1
- package/dist/lib/models/Post.js +1 -1
- package/dist/lib/models/PostApproval.d.ts +2 -3
- package/dist/lib/models/PostApproval.js +3 -4
- package/dist/lib/models/PostFlag.d.ts +4 -6
- package/dist/lib/models/PostFlag.js +5 -7
- package/dist/lib/models/PostReplacement.d.ts +10 -15
- package/dist/lib/models/PostReplacement.js +11 -16
- package/dist/lib/models/PostSet.d.ts +10 -15
- package/dist/lib/models/PostSet.js +11 -16
- package/dist/lib/models/PostVersion.d.ts +8 -12
- package/dist/lib/models/PostVersion.js +9 -13
- package/dist/lib/models/PostVote.d.ts +6 -9
- package/dist/lib/models/PostVote.js +7 -10
- package/dist/lib/models/SearchTrendBlacklist.d.ts +4 -6
- package/dist/lib/models/SearchTrendBlacklist.js +5 -7
- package/dist/lib/models/StaffFile.d.ts +5 -7
- package/dist/lib/models/StaffFile.js +7 -9
- package/dist/lib/models/StaffNote.d.ts +6 -9
- package/dist/lib/models/StaffNote.js +7 -10
- package/dist/lib/models/StaffWiki.d.ts +9 -13
- package/dist/lib/models/StaffWiki.js +13 -17
- package/dist/lib/models/Tag.d.ts +8 -12
- package/dist/lib/models/Tag.js +9 -13
- package/dist/lib/models/TagAlias.d.ts +6 -9
- package/dist/lib/models/TagAlias.js +7 -10
- package/dist/lib/models/TagImplication.d.ts +6 -9
- package/dist/lib/models/TagImplication.js +7 -10
- package/dist/lib/models/Takedown.d.ts +12 -18
- package/dist/lib/models/Takedown.js +13 -19
- package/dist/lib/models/ThumbnailPost.d.ts +2 -1
- package/dist/lib/models/ThumbnailPost.js +1 -1
- package/dist/lib/models/Ticket.d.ts +6 -9
- package/dist/lib/models/Ticket.js +7 -10
- package/dist/lib/models/UploadWhitelist.d.ts +4 -6
- package/dist/lib/models/UploadWhitelist.js +5 -7
- package/dist/lib/models/User.d.ts +17 -25
- package/dist/lib/models/User.js +19 -27
- package/dist/lib/models/UserFeedback.d.ts +8 -12
- package/dist/lib/models/UserFeedback.js +9 -13
- package/dist/lib/models/UserNameChangeRequest.d.ts +2 -3
- package/dist/lib/models/UserNameChangeRequest.js +3 -4
- package/dist/lib/models/WikiPage.d.ts +6 -9
- package/dist/lib/models/WikiPage.js +7 -10
- package/dist/lib/models/WikiPageVersion.d.ts +2 -3
- package/dist/lib/models/WikiPageVersion.js +3 -4
- package/dist/lib/models/posts/Actions.d.ts +63 -89
- package/dist/lib/models/posts/Actions.js +53 -79
- package/dist/lib/modules/Appeals.d.ts +11 -15
- package/dist/lib/modules/Appeals.js +12 -16
- package/dist/lib/modules/ArtistUrls.d.ts +3 -3
- package/dist/lib/modules/ArtistUrls.js +4 -4
- package/dist/lib/modules/ArtistVersions.d.ts +3 -3
- package/dist/lib/modules/ArtistVersions.js +4 -4
- package/dist/lib/modules/Artists.d.ts +13 -18
- package/dist/lib/modules/Artists.js +14 -19
- package/dist/lib/modules/AvoidPostingVersions.d.ts +3 -3
- package/dist/lib/modules/AvoidPostingVersions.js +4 -4
- package/dist/lib/modules/AvoidPostings.d.ts +15 -21
- package/dist/lib/modules/AvoidPostings.js +16 -22
- package/dist/lib/modules/Bans.d.ts +5 -6
- package/dist/lib/modules/Bans.js +6 -7
- package/dist/lib/modules/Base.d.ts +16 -4
- package/dist/lib/modules/Base.js +18 -4
- package/dist/lib/modules/Blips.d.ts +17 -24
- package/dist/lib/modules/Blips.js +18 -25
- package/dist/lib/modules/BulkUpdateRequests.d.ts +13 -18
- package/dist/lib/modules/BulkUpdateRequests.js +14 -19
- package/dist/lib/modules/CommentVotes.d.ts +11 -15
- package/dist/lib/modules/CommentVotes.js +12 -16
- package/dist/lib/modules/Comments.d.ts +17 -24
- package/dist/lib/modules/Comments.js +18 -25
- package/dist/lib/modules/DMails.d.ts +13 -18
- package/dist/lib/modules/DMails.js +14 -19
- package/dist/lib/modules/DText.d.ts +3 -3
- package/dist/lib/modules/DText.js +4 -4
- package/dist/lib/modules/DbExports.d.ts +3 -3
- package/dist/lib/modules/DbExports.js +4 -4
- package/dist/lib/modules/EditHistories.d.ts +5 -6
- package/dist/lib/modules/EditHistories.js +6 -7
- package/dist/lib/modules/EmailBlacklists.d.ts +7 -9
- package/dist/lib/modules/EmailBlacklists.js +8 -10
- package/dist/lib/modules/Favorites.d.ts +15 -12
- package/dist/lib/modules/Favorites.js +19 -13
- package/dist/lib/modules/ForumPostVotes.d.ts +7 -9
- package/dist/lib/modules/ForumPostVotes.js +8 -10
- package/dist/lib/modules/ForumPosts.d.ts +17 -24
- package/dist/lib/modules/ForumPosts.js +18 -25
- package/dist/lib/modules/ForumTopics.d.ts +21 -30
- package/dist/lib/modules/ForumTopics.js +22 -31
- package/dist/lib/modules/Health.d.ts +3 -3
- package/dist/lib/modules/Health.js +4 -4
- package/dist/lib/modules/HelpPages.d.ts +13 -18
- package/dist/lib/modules/HelpPages.js +14 -19
- package/dist/lib/modules/IpBans.d.ts +7 -9
- package/dist/lib/modules/IpBans.js +8 -10
- package/dist/lib/modules/IqdbQueries.d.ts +16 -12
- package/dist/lib/modules/IqdbQueries.js +17 -10
- package/dist/lib/modules/Mascots.d.ts +9 -12
- package/dist/lib/modules/Mascots.js +10 -13
- package/dist/lib/modules/ModActions.d.ts +5 -6
- package/dist/lib/modules/ModActions.js +6 -7
- package/dist/lib/modules/NewsUpdates.d.ts +9 -12
- package/dist/lib/modules/NewsUpdates.js +10 -13
- package/dist/lib/modules/NoteVersions.d.ts +3 -3
- package/dist/lib/modules/NoteVersions.js +4 -4
- package/dist/lib/modules/Notes.d.ts +13 -18
- package/dist/lib/modules/Notes.js +14 -19
- package/dist/lib/modules/PoolVersions.d.ts +3 -3
- package/dist/lib/modules/PoolVersions.js +4 -4
- package/dist/lib/modules/Pools.d.ts +19 -27
- package/dist/lib/modules/Pools.js +20 -28
- package/dist/lib/modules/Popular.d.ts +11 -6
- package/dist/lib/modules/Popular.js +15 -7
- package/dist/lib/modules/PostApprovals.d.ts +7 -9
- package/dist/lib/modules/PostApprovals.js +8 -10
- package/dist/lib/modules/PostDisapprovals.d.ts +5 -6
- package/dist/lib/modules/PostDisapprovals.js +6 -7
- package/dist/lib/modules/PostEvents.d.ts +3 -3
- package/dist/lib/modules/PostEvents.js +4 -4
- package/dist/lib/modules/PostFlags.d.ts +11 -15
- package/dist/lib/modules/PostFlags.js +12 -16
- package/dist/lib/modules/PostReplacements.d.ts +15 -21
- package/dist/lib/modules/PostReplacements.js +16 -22
- package/dist/lib/modules/PostSets.d.ts +19 -27
- package/dist/lib/modules/PostSets.js +20 -28
- package/dist/lib/modules/PostVersions.d.ts +9 -12
- package/dist/lib/modules/PostVersions.js +10 -13
- package/dist/lib/modules/PostVotes.d.ts +11 -15
- package/dist/lib/modules/PostVotes.js +12 -16
- package/dist/lib/modules/Posts.d.ts +70 -81
- package/dist/lib/modules/Posts.js +89 -85
- package/dist/lib/modules/RelatedTags.d.ts +3 -3
- package/dist/lib/modules/RelatedTags.js +4 -4
- package/dist/lib/modules/SearchTrendBlacklists.d.ts +7 -9
- package/dist/lib/modules/SearchTrendBlacklists.js +8 -10
- package/dist/lib/modules/SearchTrends.d.ts +11 -15
- package/dist/lib/modules/SearchTrends.js +12 -16
- package/dist/lib/modules/{staff/AutomodDMails.d.ts → StaffAutomodDMails.d.ts} +15 -18
- package/dist/lib/modules/{staff/AutomodDMails.js → StaffAutomodDMails.js} +14 -17
- package/dist/lib/modules/{staff/DMails.d.ts → StaffDMails.d.ts} +7 -8
- package/dist/lib/modules/StaffDMails.js +54 -0
- package/dist/lib/modules/StaffExceptionLogs.d.ts +33 -0
- package/dist/lib/modules/StaffExceptionLogs.js +54 -0
- package/dist/lib/modules/{staff/Files.d.ts → StaffFiles.d.ts} +15 -19
- package/dist/lib/modules/{staff/Files.js → StaffFiles.js} +16 -20
- package/dist/lib/modules/StaffNotes.d.ts +13 -18
- package/dist/lib/modules/StaffNotes.js +14 -19
- package/dist/lib/modules/{staff/UserCleanups.d.ts → StaffUserCleanups.d.ts} +12 -16
- package/dist/lib/modules/{staff/UserCleanups.js → StaffUserCleanups.js} +15 -19
- package/dist/lib/modules/{staff/Users.d.ts → StaffUsers.d.ts} +10 -12
- package/dist/lib/modules/{staff/Users.js → StaffUsers.js} +11 -13
- package/dist/lib/modules/StaffVoteTrends.d.ts +26 -0
- package/dist/lib/modules/StaffVoteTrends.js +39 -0
- package/dist/lib/modules/{staff/WikiVersions.d.ts → StaffWikiVersions.d.ts} +9 -10
- package/dist/lib/modules/StaffWikiVersions.js +54 -0
- package/dist/lib/modules/{staff/Wikis.d.ts → StaffWikis.d.ts} +19 -25
- package/dist/lib/modules/{staff/Wikis.js → StaffWikis.js} +20 -26
- package/dist/lib/modules/TagAliases.d.ts +13 -18
- package/dist/lib/modules/TagAliases.js +14 -19
- package/dist/lib/modules/TagCorrections.d.ts +5 -6
- package/dist/lib/modules/TagCorrections.js +6 -7
- package/dist/lib/modules/TagImplications.d.ts +13 -18
- package/dist/lib/modules/TagImplications.js +14 -19
- package/dist/lib/modules/TagTypeVersions.d.ts +3 -3
- package/dist/lib/modules/TagTypeVersions.js +4 -4
- package/dist/lib/modules/Tags.d.ts +11 -15
- package/dist/lib/modules/Tags.js +12 -16
- package/dist/lib/modules/Takedowns.d.ts +19 -27
- package/dist/lib/modules/Takedowns.js +20 -28
- package/dist/lib/modules/Tickets.d.ts +11 -15
- package/dist/lib/modules/Tickets.js +12 -16
- package/dist/lib/modules/UploadWhitelists.d.ts +11 -15
- package/dist/lib/modules/UploadWhitelists.js +12 -16
- package/dist/lib/modules/Uploads.d.ts +10 -12
- package/dist/lib/modules/Uploads.js +8 -10
- package/dist/lib/modules/UserFeedbacks.d.ts +15 -21
- package/dist/lib/modules/UserFeedbacks.js +16 -22
- package/dist/lib/modules/UserNameChangeRequests.d.ts +9 -12
- package/dist/lib/modules/UserNameChangeRequests.js +10 -13
- package/dist/lib/modules/Users.d.ts +27 -39
- package/dist/lib/modules/Users.js +28 -40
- package/dist/lib/modules/WikiPageVersions.d.ts +5 -6
- package/dist/lib/modules/WikiPageVersions.js +6 -7
- package/dist/lib/modules/WikiPages.d.ts +13 -18
- package/dist/lib/modules/WikiPages.js +14 -19
- package/dist/lib/modules/index.d.ts +35 -36
- package/dist/lib/modules/index.js +81 -80
- package/dist/lib/modules/posts/Format.d.ts +15 -5
- package/dist/lib/modules/posts/Format.js +1 -1
- package/dist/lib/standalone.d.ts +26 -0
- package/dist/lib/standalone.js +26 -0
- package/dist/lib/util.js +4 -10
- package/dist/lib/version.d.ts +2 -0
- package/dist/lib/version.js +3 -0
- package/package.json +38 -8
- package/tsconfig.json +1 -1
- package/dist/lib/generated/source.json +0 -22669
- package/dist/lib/modules/staff/DMails.js +0 -55
- package/dist/lib/modules/staff/ExceptionLogs.d.ts +0 -34
- package/dist/lib/modules/staff/ExceptionLogs.js +0 -55
- package/dist/lib/modules/staff/VoteTrends.d.ts +0 -26
- package/dist/lib/modules/staff/VoteTrends.js +0 -39
- package/dist/lib/modules/staff/WikiVersions.js +0 -55
- package/dist/package.json +0 -73
|
@@ -12,60 +12,56 @@ export interface SearchPostVotesOptions extends TransformDataQueryToOptions<Post
|
|
|
12
12
|
}
|
|
13
13
|
/** @category Modules */
|
|
14
14
|
export default class PostVotes extends Base {
|
|
15
|
+
static readonly moduleKey: "postVotes";
|
|
15
16
|
/**
|
|
16
|
-
* Create Post Vote
|
|
17
17
|
*
|
|
18
18
|
* @requiresApiKeyAuth
|
|
19
19
|
*
|
|
20
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
20
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#create post_votes#create}
|
|
21
21
|
*
|
|
22
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
22
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#create Documentation} for more details.
|
|
23
23
|
*/
|
|
24
24
|
create(id: number, score: PostVoteScore, no_unvote?: boolean): Promise<PostVotesCreateResponse>;
|
|
25
25
|
/**
|
|
26
|
-
* Delete Post Votes
|
|
27
26
|
*
|
|
28
27
|
* You must be Admin+. Errors if ids is not provided.
|
|
29
28
|
*
|
|
30
29
|
* @requiresApiKeyAuth
|
|
31
30
|
*
|
|
32
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
31
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#delete post_votes#delete}
|
|
33
32
|
*
|
|
34
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
33
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#delete Documentation} for more details.
|
|
35
34
|
*/
|
|
36
35
|
delete(ids: Array<number>): Promise<null>;
|
|
37
36
|
/**
|
|
38
|
-
* Lock Post Votes
|
|
39
37
|
*
|
|
40
38
|
* You must be Moderator+. Errors if ids is not provided.
|
|
41
39
|
*
|
|
42
40
|
* @requiresApiKeyAuth
|
|
43
41
|
*
|
|
44
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
42
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#lock post_votes#lock}
|
|
45
43
|
*
|
|
46
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
44
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#lock Documentation} for more details.
|
|
47
45
|
*/
|
|
48
46
|
lock(ids: Array<number>): Promise<null>;
|
|
49
47
|
/**
|
|
50
|
-
* Post Votes Index
|
|
51
48
|
*
|
|
52
49
|
* You must be Moderator+.
|
|
53
50
|
*
|
|
54
51
|
* @requiresApiKeyAuth
|
|
55
52
|
*
|
|
56
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
53
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#index post_votes#index}
|
|
57
54
|
*
|
|
58
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
55
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#index Documentation} for more details.
|
|
59
56
|
*/
|
|
60
57
|
search(options?: SearchPostVotesOptions): Promise<Array<PostVote>>;
|
|
61
58
|
/**
|
|
62
|
-
* Delete Post Vote
|
|
63
59
|
*
|
|
64
60
|
* @requiresApiKeyAuth
|
|
65
61
|
*
|
|
66
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
62
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#destroy post_votes#destroy}
|
|
67
63
|
*
|
|
68
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
64
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#destroy Documentation} for more details.
|
|
69
65
|
*/
|
|
70
66
|
unvote(id: number): Promise<null>;
|
|
71
67
|
}
|
|
@@ -5,14 +5,14 @@ import { OperationID } from "../util.js";
|
|
|
5
5
|
import Base from "./Base.js";
|
|
6
6
|
/** @category Modules */
|
|
7
7
|
export default class PostVotes extends Base {
|
|
8
|
+
static moduleKey = "postVotes";
|
|
8
9
|
/**
|
|
9
|
-
* Create Post Vote
|
|
10
10
|
*
|
|
11
11
|
* @requiresApiKeyAuth
|
|
12
12
|
*
|
|
13
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
13
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#create post_votes#create}
|
|
14
14
|
*
|
|
15
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
15
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#create Documentation} for more details.
|
|
16
16
|
*/
|
|
17
17
|
async create(id, score, no_unvote) {
|
|
18
18
|
return postVotes_create({
|
|
@@ -22,15 +22,14 @@ export default class PostVotes extends Base {
|
|
|
22
22
|
}).then(res => this._handleResponse(res, 200, true));
|
|
23
23
|
}
|
|
24
24
|
/**
|
|
25
|
-
* Delete Post Votes
|
|
26
25
|
*
|
|
27
26
|
* You must be Admin+. Errors if ids is not provided.
|
|
28
27
|
*
|
|
29
28
|
* @requiresApiKeyAuth
|
|
30
29
|
*
|
|
31
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
30
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#delete post_votes#delete}
|
|
32
31
|
*
|
|
33
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
32
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#delete Documentation} for more details.
|
|
34
33
|
*/
|
|
35
34
|
async delete(ids) {
|
|
36
35
|
return postVotes_delete({
|
|
@@ -39,15 +38,14 @@ export default class PostVotes extends Base {
|
|
|
39
38
|
}).then(res => this._handleResponse(res, 204, true));
|
|
40
39
|
}
|
|
41
40
|
/**
|
|
42
|
-
* Lock Post Votes
|
|
43
41
|
*
|
|
44
42
|
* You must be Moderator+. Errors if ids is not provided.
|
|
45
43
|
*
|
|
46
44
|
* @requiresApiKeyAuth
|
|
47
45
|
*
|
|
48
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
46
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#lock post_votes#lock}
|
|
49
47
|
*
|
|
50
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
48
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#lock Documentation} for more details.
|
|
51
49
|
*/
|
|
52
50
|
async lock(ids) {
|
|
53
51
|
return postVotes_lock({
|
|
@@ -56,15 +54,14 @@ export default class PostVotes extends Base {
|
|
|
56
54
|
}).then(res => this._handleResponse(res, 204, true));
|
|
57
55
|
}
|
|
58
56
|
/**
|
|
59
|
-
* Post Votes Index
|
|
60
57
|
*
|
|
61
58
|
* You must be Moderator+.
|
|
62
59
|
*
|
|
63
60
|
* @requiresApiKeyAuth
|
|
64
61
|
*
|
|
65
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
62
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#index post_votes#index}
|
|
66
63
|
*
|
|
67
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
64
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#index Documentation} for more details.
|
|
68
65
|
*/
|
|
69
66
|
async search(options) {
|
|
70
67
|
return postVotes_index({
|
|
@@ -73,13 +70,12 @@ export default class PostVotes extends Base {
|
|
|
73
70
|
}).then(res => this._handleResponse(res, 200, true, PostVote));
|
|
74
71
|
}
|
|
75
72
|
/**
|
|
76
|
-
* Delete Post Vote
|
|
77
73
|
*
|
|
78
74
|
* @requiresApiKeyAuth
|
|
79
75
|
*
|
|
80
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
76
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Votes-post_votes\#destroy post_votes#destroy}
|
|
81
77
|
*
|
|
82
|
-
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes
|
|
78
|
+
* @see {@link https://e621.wiki/#operations-Post_Votes-post_votes\#destroy Documentation} for more details.
|
|
83
79
|
*/
|
|
84
80
|
async unvote(id) {
|
|
85
81
|
return postVotes_destroy({
|
|
@@ -118,4 +114,4 @@ __decorate([
|
|
|
118
114
|
__metadata("design:paramtypes", [Number]),
|
|
119
115
|
__metadata("design:returntype", Promise)
|
|
120
116
|
], PostVotes.prototype, "unvote", null);
|
|
121
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
117
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiUG9zdFZvdGVzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vbGliL21vZHVsZXMvUG9zdFZvdGVzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFBQSxPQUFPLEVBQUUsZ0JBQWdCLEVBQUUsZ0JBQWdCLEVBQUUsaUJBQWlCLEVBQUUsY0FBYyxFQUFFLGVBQWUsRUFBRSxNQUFNLHFCQUFxQixDQUFDO0FBQzdILE9BQU8sUUFBUSxNQUFNLHVCQUF1QixDQUFDO0FBQzdDLE9BQU8sRUFBZSxXQUFXLEVBQWtELE1BQU0sWUFBWSxDQUFDO0FBRXRHLE9BQU8sSUFBSSxNQUFNLFdBQVcsQ0FBQztBQVc3Qix3QkFBd0I7QUFDeEIsTUFBTSxDQUFDLE9BQU8sT0FBTyxTQUFVLFNBQVEsSUFBSTtJQUN2QyxNQUFNLENBQVUsU0FBUyxHQUFHLFdBQW9CLENBQUM7SUFDakQ7Ozs7Ozs7T0FPQTtJQUVNLEFBQU4sS0FBSyxDQUFDLE1BQU0sQ0FBQyxFQUFVLEVBQUUsS0FBb0IsRUFBRSxTQUFtQjtRQUM5RCxPQUFPLGdCQUFnQixDQUFDO1lBQ3BCLE1BQU0sRUFBRSxJQUFJLENBQUMsTUFBTTtZQUNuQixJQUFJLEVBQUUsRUFBRSxFQUFFLEVBQUU7WUFDWixLQUFLLEVBQUUsRUFBRSxTQUFTLEVBQUUsS0FBSyxFQUFFO1NBQzlCLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLEVBQUUsQ0FBQyxJQUFJLENBQUMsZUFBZSxDQUFDLEdBQUcsRUFBRSxHQUFHLEVBQUUsSUFBSSxDQUFDLENBQUMsQ0FBQztJQUN6RCxDQUFDO0lBRUQ7Ozs7Ozs7OztPQVNBO0lBRU0sQUFBTixLQUFLLENBQUMsTUFBTSxDQUFDLEdBQWtCO1FBQzNCLE9BQU8sZ0JBQWdCLENBQUM7WUFDcEIsTUFBTSxFQUFFLElBQUksQ0FBQyxNQUFNO1lBQ25CLEtBQUssRUFBRSxFQUFFLEdBQUcsRUFBRSxHQUFHLENBQUMsSUFBSSxDQUFDLEdBQUcsQ0FBQyxFQUFFO1NBQ2hDLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLEVBQUUsQ0FBQyxJQUFJLENBQUMsZUFBZSxDQUFDLEdBQUcsRUFBRSxHQUFHLEVBQUUsSUFBSSxDQUFDLENBQUMsQ0FBQztJQUN6RCxDQUFDO0lBRUQ7Ozs7Ozs7OztPQVNBO0lBRU0sQUFBTixLQUFLLENBQUMsSUFBSSxDQUFDLEdBQWtCO1FBQ3pCLE9BQU8sY0FBYyxDQUFDO1lBQ2xCLE1BQU0sRUFBRSxJQUFJLENBQUMsTUFBTTtZQUNuQixLQUFLLEVBQUUsRUFBRSxHQUFHLEVBQUUsR0FBRyxDQUFDLElBQUksQ0FBQyxHQUFHLENBQUMsRUFBRTtTQUNoQyxDQUFDLENBQUMsSUFBSSxDQUFDLEdBQUcsQ0FBQyxFQUFFLENBQUMsSUFBSSxDQUFDLGVBQWUsQ0FBQyxHQUFHLEVBQUUsR0FBRyxFQUFFLElBQUksQ0FBQyxDQUFDLENBQUM7SUFDekQsQ0FBQztJQUVEOzs7Ozs7Ozs7T0FTQTtJQUVNLEFBQU4sS0FBSyxDQUFDLE1BQU0sQ0FBQyxPQUFnQztRQUN6QyxPQUFPLGVBQWUsQ0FBQztZQUNuQixNQUFNLEVBQUUsSUFBSSxDQUFDLE1BQU07WUFDbkIsS0FBSyxFQUFFLE9BQU87U0FDakIsQ0FBQyxDQUFDLElBQUksQ0FBQyxHQUFHLENBQUMsRUFBRSxDQUFDLElBQUksQ0FBQyxlQUFlLENBQUMsR0FBRyxFQUFFLEdBQUcsRUFBRSxJQUFJLEVBQUUsUUFBUSxDQUFDLENBQUMsQ0FBQztJQUNuRSxDQUFDO0lBRUQ7Ozs7Ozs7T0FPQTtJQUVNLEFBQU4sS0FBSyxDQUFDLE1BQU0sQ0FBQyxFQUFVO1FBQ25CLE9BQU8saUJBQWlCLENBQUM7WUFDckIsTUFBTSxFQUFFLElBQUksQ0FBQyxNQUFNO1lBQ25CLElBQUksRUFBRSxFQUFFLEVBQUUsRUFBRTtTQUNmLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLEVBQUUsQ0FBQyxJQUFJLENBQUMsZUFBZSxDQUFDLEdBQUcsRUFBRSxHQUFHLEVBQUUsSUFBSSxDQUFDLENBQUMsQ0FBQztJQUN6RCxDQUFDOztBQTVFSztJQURSLFdBQVcsQ0FBQyxtQkFBbUIsQ0FBQzs7Ozt1Q0FPN0I7QUFhSztJQURSLFdBQVcsQ0FBQyxtQkFBbUIsQ0FBQzs7cUNBQ1osS0FBSzs7dUNBS3RCO0FBYUs7SUFEUixXQUFXLENBQUMsaUJBQWlCLENBQUM7O3FDQUNaLEtBQUs7O3FDQUtwQjtBQWFLO0lBRFIsV0FBVyxDQUFDLGtCQUFrQixDQUFDOzs7O3VDQU01QjtBQVdLO0lBRFIsV0FBVyxDQUFDLG9CQUFvQixDQUFDOzs7O3VDQU05QiJ9
|
|
@@ -3,8 +3,10 @@ import Post from "../models/Post.js";
|
|
|
3
3
|
import ThumbnailPost from "../models/ThumbnailPost.js";
|
|
4
4
|
import { type TransformDataBodyToOptions, type TransformDataQueryToOptions } from "../util.js";
|
|
5
5
|
import Base from "./Base.js";
|
|
6
|
-
import { type NoV2Options, type PostFormat } from "./posts/Format.js";
|
|
6
|
+
import { type NoV2Options, type PostFormat, type PostFormatOptions } from "./posts/Format.js";
|
|
7
|
+
import type { Client } from "../generated/client/types.js";
|
|
7
8
|
import type { StaffPostPostsDeleteData, PostsShowData, PostsShowSeqData, PostsRandomData, PostRecommendationsArtistData, PostFavoritesIndexData, PostsMarkAsTranslatedData, StaffPostPostsMoveFavoritesData, PostRecommendation, StaffPostPostsReownerData, PostsIndexData, PostsUpdateData, PostsUpdateIqdbData } from "../generated/types.js";
|
|
9
|
+
import type E621 from "../index.js";
|
|
8
10
|
/** @category Modules/Types */
|
|
9
11
|
export interface DeletePostOptions extends TransformDataBodyToOptions<StaffPostPostsDeleteData> {
|
|
10
12
|
}
|
|
@@ -47,238 +49,225 @@ export interface PostPreviousOwner {
|
|
|
47
49
|
name: string;
|
|
48
50
|
}
|
|
49
51
|
/** @category Modules/Types */
|
|
50
|
-
export interface RecommendedPostsResult {
|
|
52
|
+
export interface RecommendedPostsResult<PF extends PostFormatOptions = NoV2Options> {
|
|
51
53
|
model_version: string;
|
|
52
|
-
post_data: Array<ThumbnailPost
|
|
54
|
+
post_data: Array<ThumbnailPost<PF>>;
|
|
53
55
|
post_id: number;
|
|
54
56
|
results: Array<PostRecommendation>;
|
|
55
57
|
}
|
|
56
58
|
/** @category Modules/Types */
|
|
57
|
-
export type PostSearchResult<O extends SearchPostsOptions> = O extends {
|
|
59
|
+
export type PostSearchResult<O extends SearchPostsOptions, PF extends PostFormatOptions = NoV2Options> = O extends {
|
|
58
60
|
md5: string;
|
|
59
|
-
} ? PostFormat<O["v2"], O["mode"]> : Array<PostFormat<O["v2"], O["mode"]>>;
|
|
61
|
+
} ? PostFormat<O["v2"], O["mode"], PF> : Array<PostFormat<O["v2"], O["mode"], PF>>;
|
|
60
62
|
/** @category Modules */
|
|
61
|
-
export default class Posts extends Base {
|
|
63
|
+
export default class Posts<PF extends PostFormatOptions = NoV2Options> extends Base<PF> {
|
|
64
|
+
static readonly moduleKey: "posts";
|
|
65
|
+
protected readonly defaultFormat: PF;
|
|
66
|
+
/**
|
|
67
|
+
* @param defaultFormat - The v2/mode format to fall back to for any method here (or any convenience
|
|
68
|
+
* method on a returned post model) called without explicit v2/mode options. Defaults to the legacy
|
|
69
|
+
* format, matching `new E621()`'s behavior when {@link Options.defaultPostFormat} isn't set.
|
|
70
|
+
*/
|
|
71
|
+
constructor(e621: E621<PF> | undefined, client: Client, defaultFormat?: PF);
|
|
62
72
|
/**
|
|
63
|
-
* AI Check Post
|
|
64
73
|
*
|
|
65
74
|
* You must be Janitor+.
|
|
66
75
|
*
|
|
67
76
|
* @requiresApiKeyAuth
|
|
68
77
|
*
|
|
69
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
78
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#ai_check staff/post/posts#ai_check}
|
|
70
79
|
*
|
|
71
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
80
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#ai_check Documentation} for more details.
|
|
72
81
|
*/
|
|
73
82
|
aiCheck(id: number): Promise<string>;
|
|
74
83
|
/**
|
|
75
|
-
* Copy Notes To Post
|
|
76
84
|
*
|
|
77
85
|
* @requiresApiKeyAuth
|
|
78
86
|
*
|
|
79
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
87
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#copy_notes posts#copy_notes}
|
|
80
88
|
*
|
|
81
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
89
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#copy_notes Documentation} for more details.
|
|
82
90
|
*/
|
|
83
91
|
copyNotes(id: number, other_post_id: number): Promise<null>;
|
|
84
92
|
/**
|
|
85
|
-
* Delete Post
|
|
86
93
|
*
|
|
87
94
|
* You must have the "Approve Posts" permission. `commit=Delete` must be set.
|
|
88
95
|
*
|
|
89
96
|
* @requiresApiKeyAuth
|
|
90
97
|
*
|
|
91
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
98
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#delete staff/post/posts#delete}
|
|
92
99
|
*
|
|
93
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
100
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#delete Documentation} for more details.
|
|
94
101
|
*/
|
|
95
102
|
delete(id: number, options: DeletePostOptions): Promise<unknown>;
|
|
96
103
|
/**
|
|
97
|
-
* Expunge Post
|
|
98
104
|
*
|
|
99
105
|
* You must have the "Approve Posts" permission and be Admin+.
|
|
100
106
|
*
|
|
101
107
|
* @requiresApiKeyAuth
|
|
102
108
|
*
|
|
103
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
109
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#expunge staff/post/posts#expunge}
|
|
104
110
|
*
|
|
105
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
111
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#expunge Documentation} for more details.
|
|
106
112
|
*/
|
|
107
|
-
expunge(id: number, reason: string): Promise<Post
|
|
113
|
+
expunge(id: number, reason: string): Promise<Post<PF>>;
|
|
108
114
|
/**
|
|
109
|
-
* Post Favorites Index
|
|
110
115
|
*
|
|
111
116
|
* You must be the user or Moderator+ to see users that have their favorites hidden.
|
|
112
117
|
*
|
|
113
|
-
* @operationId {@link https://e621.wiki/#operations-Post_Favorites-post_favorites
|
|
118
|
+
* @operationId {@link https://e621.wiki/#operations-Post_Favorites-post_favorites\#index post_favorites#index}
|
|
114
119
|
*
|
|
115
|
-
* @see {@link https://e621.wiki/#operations-Post_Favorites-post_favorites
|
|
120
|
+
* @see {@link https://e621.wiki/#operations-Post_Favorites-post_favorites\#index Documentation} for more details.
|
|
116
121
|
*/
|
|
117
122
|
favorites(id: number, options: ListPostFavoritesOptions): Promise<Array<MinimalUser>>;
|
|
118
123
|
/**
|
|
119
|
-
* Get Post
|
|
120
124
|
*
|
|
121
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
125
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#show posts#show}
|
|
122
126
|
*
|
|
123
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
127
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#show Documentation} for more details.
|
|
124
128
|
*/
|
|
125
|
-
get<const O extends GetPostOptions =
|
|
129
|
+
get<const O extends GetPostOptions = PF>(id: number, options?: O): Promise<PostFormat<O["v2"], O["mode"], PF> | null>;
|
|
126
130
|
/**
|
|
127
|
-
* Mark Post As Translated
|
|
128
131
|
*
|
|
129
132
|
* Will error if no body is provided.
|
|
130
133
|
*
|
|
131
134
|
* @requiresApiKeyAuth
|
|
132
135
|
*
|
|
133
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
136
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#mark_as_translated posts#mark_as_translated}
|
|
134
137
|
*
|
|
135
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
138
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#mark_as_translated Documentation} for more details.
|
|
136
139
|
*/
|
|
137
|
-
markTranslated<const O extends MarkPostAsTranslatedOptions =
|
|
140
|
+
markTranslated<const O extends MarkPostAsTranslatedOptions = PF>(id: number, options?: O): Promise<PostFormat<O["v2"], O["mode"], PF>>;
|
|
138
141
|
/**
|
|
139
|
-
* Move Post Favorites
|
|
140
142
|
*
|
|
141
143
|
* You must have the "Approve Posts" permission. `commit=Submit`` must be set.
|
|
142
144
|
*
|
|
143
145
|
* @requiresApiKeyAuth
|
|
144
146
|
*
|
|
145
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
147
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#move_favorites staff/post/posts#move_favorites}
|
|
146
148
|
*
|
|
147
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
149
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#move_favorites Documentation} for more details.
|
|
148
150
|
*/
|
|
149
151
|
moveFavorites(id: number, options: MovePostFavoritesOptions): Promise<unknown>;
|
|
150
152
|
/**
|
|
151
|
-
* Get Post Previous Owners
|
|
152
153
|
*
|
|
153
154
|
* You must be an Approver
|
|
154
155
|
*
|
|
155
156
|
* @requiresApiKeyAuth
|
|
156
157
|
*
|
|
157
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
158
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#previous_owners staff/post/posts#previous_owners}
|
|
158
159
|
*
|
|
159
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
160
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#previous_owners Documentation} for more details.
|
|
160
161
|
*/
|
|
161
162
|
previousOwners(id: number): Promise<Array<PostPreviousOwner>>;
|
|
162
163
|
/**
|
|
163
|
-
* Get Random Post
|
|
164
164
|
*
|
|
165
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
165
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#random posts#random}
|
|
166
166
|
*
|
|
167
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
167
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#random Documentation} for more details.
|
|
168
168
|
*/
|
|
169
|
-
random<const O extends GetRandomPostOptions =
|
|
169
|
+
random<const O extends GetRandomPostOptions = PF>(options?: O): Promise<PostFormat<O["v2"], O["mode"], PF>>;
|
|
170
170
|
/**
|
|
171
|
-
* Get Recommended Posts For Artist
|
|
172
171
|
*
|
|
173
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-post_recommendations
|
|
172
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-post_recommendations\#artist post_recommendations#artist}
|
|
174
173
|
*
|
|
175
|
-
* @see {@link https://e621.wiki/#operations-Posts-post_recommendations
|
|
174
|
+
* @see {@link https://e621.wiki/#operations-Posts-post_recommendations\#artist Documentation} for more details.
|
|
176
175
|
*/
|
|
177
|
-
recommendedByArtist(id: number, options?: RecommendedPostsOptions): Promise<RecommendedPostsResult
|
|
176
|
+
recommendedByArtist(id: number, options?: RecommendedPostsOptions): Promise<RecommendedPostsResult<PF>>;
|
|
178
177
|
/**
|
|
179
|
-
* Get Recommended Posts For Tags
|
|
180
178
|
*
|
|
181
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-post_recommendations
|
|
179
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-post_recommendations\#tags post_recommendations#tags}
|
|
182
180
|
*
|
|
183
|
-
* @see {@link https://e621.wiki/#operations-Posts-post_recommendations
|
|
181
|
+
* @see {@link https://e621.wiki/#operations-Posts-post_recommendations\#tags Documentation} for more details.
|
|
184
182
|
*/
|
|
185
|
-
recommendedByTags(id: number, options?: RecommendedPostsOptions): Promise<RecommendedPostsResult
|
|
183
|
+
recommendedByTags(id: number, options?: RecommendedPostsOptions): Promise<RecommendedPostsResult<PF>>;
|
|
186
184
|
/**
|
|
187
|
-
* Regenerate Post Thumbnails
|
|
188
185
|
*
|
|
189
186
|
* You must be Janitor+.
|
|
190
187
|
*
|
|
191
188
|
* @requiresApiKeyAuth
|
|
192
189
|
*
|
|
193
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
190
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#regenerate_thumbnails staff/post/posts#regenerate_thumbnails}
|
|
194
191
|
*
|
|
195
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
192
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#regenerate_thumbnails Documentation} for more details.
|
|
196
193
|
*/
|
|
197
|
-
regenerateThumbnails(id: number): Promise<Post
|
|
194
|
+
regenerateThumbnails(id: number): Promise<Post<PF>>;
|
|
198
195
|
/**
|
|
199
|
-
* Regenerate Post Videos
|
|
200
196
|
*
|
|
201
197
|
* You must be Janitor+.
|
|
202
198
|
*
|
|
203
199
|
* @requiresApiKeyAuth
|
|
204
200
|
*
|
|
205
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
201
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#regenerate_videos staff/post/posts#regenerate_videos}
|
|
206
202
|
*
|
|
207
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
203
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#regenerate_videos Documentation} for more details.
|
|
208
204
|
*/
|
|
209
205
|
regenerateVideos(id: number): Promise<null>;
|
|
210
206
|
/**
|
|
211
|
-
* Reown Post
|
|
212
207
|
*
|
|
213
208
|
* You must have be Janitor+ and an Approver
|
|
214
209
|
*
|
|
215
210
|
* @requiresApiKeyAuth
|
|
216
211
|
*
|
|
217
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
212
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#reowner staff/post/posts#reowner}
|
|
218
213
|
*
|
|
219
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
214
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#reowner Documentation} for more details.
|
|
220
215
|
*/
|
|
221
216
|
reown(id: number, options: ReownPostOptions): Promise<string>;
|
|
222
217
|
/**
|
|
223
|
-
* Revert Post
|
|
224
218
|
*
|
|
225
219
|
* @requiresApiKeyAuth
|
|
226
220
|
*
|
|
227
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
221
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#revert posts#revert}
|
|
228
222
|
*
|
|
229
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
223
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#revert Documentation} for more details.
|
|
230
224
|
*/
|
|
231
225
|
revert(id: number, version_id: number): Promise<null>;
|
|
232
226
|
/**
|
|
233
|
-
* Posts Index
|
|
234
227
|
*
|
|
235
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
228
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#index posts#index}
|
|
236
229
|
*
|
|
237
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
230
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#index Documentation} for more details.
|
|
238
231
|
*/
|
|
239
|
-
search<const O extends SearchPostsOptions =
|
|
232
|
+
search<const O extends SearchPostsOptions = PF>(options?: O): Promise<PostSearchResult<O, PF>>;
|
|
240
233
|
/**
|
|
241
|
-
* Get Post In Sequence
|
|
242
234
|
*
|
|
243
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
235
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#show_seq posts#show_seq}
|
|
244
236
|
*
|
|
245
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
237
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#show_seq Documentation} for more details.
|
|
246
238
|
*/
|
|
247
|
-
sequence<const O extends GetPostInSequenceOptions =
|
|
239
|
+
sequence<const O extends GetPostInSequenceOptions = PF>(id: number, options?: O): Promise<PostFormat<O["v2"], O["mode"], PF>>;
|
|
248
240
|
/**
|
|
249
|
-
* Undelete Post
|
|
250
241
|
*
|
|
251
242
|
* You must have the "Approve Posts" permission.
|
|
252
243
|
*
|
|
253
244
|
* @requiresApiKeyAuth
|
|
254
245
|
*
|
|
255
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
246
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-staff/post/posts\#undelete staff/post/posts#undelete}
|
|
256
247
|
*
|
|
257
|
-
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts
|
|
248
|
+
* @see {@link https://e621.wiki/#operations-Posts-staff/post/posts\#undelete Documentation} for more details.
|
|
258
249
|
*/
|
|
259
|
-
undelete(id: number): Promise<Post
|
|
250
|
+
undelete(id: number): Promise<Post<PF>>;
|
|
260
251
|
/**
|
|
261
|
-
* Update Post
|
|
262
252
|
*
|
|
263
253
|
* Most errors are silently swallowed.
|
|
264
254
|
*
|
|
265
255
|
* @requiresApiKeyAuth
|
|
266
256
|
*
|
|
267
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
257
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#update posts#update}
|
|
268
258
|
*
|
|
269
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
259
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#update Documentation} for more details.
|
|
270
260
|
*/
|
|
271
|
-
update<const O extends UpdatePostOptions =
|
|
261
|
+
update<const O extends UpdatePostOptions = PF>(id: number, options?: O): Promise<PostFormat<O["v2"], O["mode"], PF>>;
|
|
272
262
|
/**
|
|
273
|
-
* Update Post IQDB
|
|
274
263
|
*
|
|
275
264
|
* You must be Admin+.
|
|
276
265
|
*
|
|
277
266
|
* @requiresApiKeyAuth
|
|
278
267
|
*
|
|
279
|
-
* @operationId {@link https://e621.wiki/#operations-Posts-posts
|
|
268
|
+
* @operationId {@link https://e621.wiki/#operations-Posts-posts\#update_iqdb posts#update_iqdb}
|
|
280
269
|
*
|
|
281
|
-
* @see {@link https://e621.wiki/#operations-Posts-posts
|
|
270
|
+
* @see {@link https://e621.wiki/#operations-Posts-posts\#update_iqdb Documentation} for more details.
|
|
282
271
|
*/
|
|
283
|
-
updateIqdb<const O extends UpdatePostIqdbOptions =
|
|
272
|
+
updateIqdb<const O extends UpdatePostIqdbOptions = PF>(id: number, options?: O): Promise<PostFormat<O["v2"], O["mode"], PF>>;
|
|
284
273
|
}
|