anixapi 0.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/LICENSE +339 -0
- package/README.md +165 -0
- package/dist/api/auth.d.ts +129 -0
- package/dist/api/auth.js +156 -0
- package/dist/api/bookmarks/export.d.ts +19 -0
- package/dist/api/bookmarks/export.js +24 -0
- package/dist/api/bookmarks/import.d.ts +29 -0
- package/dist/api/bookmarks/import.js +36 -0
- package/dist/api/bookmarks/index.d.ts +2 -0
- package/dist/api/bookmarks/index.js +18 -0
- package/dist/api/channel/article.d.ts +119 -0
- package/dist/api/channel/article.js +144 -0
- package/dist/api/channel/articleComment.d.ts +119 -0
- package/dist/api/channel/articleComment.js +144 -0
- package/dist/api/channel/articleSuggestion.d.ts +69 -0
- package/dist/api/channel/articleSuggestion.js +84 -0
- package/dist/api/channel/channel.d.ts +249 -0
- package/dist/api/channel/channel.js +300 -0
- package/dist/api/channel/index.d.ts +4 -0
- package/dist/api/channel/index.js +20 -0
- package/dist/api/collection/collection.d.ts +59 -0
- package/dist/api/collection/collection.js +72 -0
- package/dist/api/collection/collectionComment.d.ts +109 -0
- package/dist/api/collection/collectionComment.js +132 -0
- package/dist/api/collection/collectionFavorite.d.ts +39 -0
- package/dist/api/collection/collectionFavorite.js +48 -0
- package/dist/api/collection/collectionMy.d.ts +69 -0
- package/dist/api/collection/collectionMy.js +84 -0
- package/dist/api/collection/index.d.ts +4 -0
- package/dist/api/collection/index.js +20 -0
- package/dist/api/config.d.ts +29 -0
- package/dist/api/config.js +36 -0
- package/dist/api/discover.d.ts +59 -0
- package/dist/api/discover.js +72 -0
- package/dist/api/feed.d.ts +39 -0
- package/dist/api/feed.js +48 -0
- package/dist/api/index.d.ts +12 -0
- package/dist/api/index.js +28 -0
- package/dist/api/notification/index.d.ts +2 -0
- package/dist/api/notification/index.js +18 -0
- package/dist/api/notification/notification.d.ts +199 -0
- package/dist/api/notification/notification.js +240 -0
- package/dist/api/notification/notificationPreference.d.ts +159 -0
- package/dist/api/notification/notificationPreference.js +192 -0
- package/dist/api/profile/index.d.ts +10 -0
- package/dist/api/profile/index.js +26 -0
- package/dist/api/profile/profile.d.ts +65 -0
- package/dist/api/profile/profile.js +80 -0
- package/dist/api/profile/profileBadge.d.ts +39 -0
- package/dist/api/profile/profileBadge.js +48 -0
- package/dist/api/profile/profileBlockList.d.ts +39 -0
- package/dist/api/profile/profileBlockList.js +48 -0
- package/dist/api/profile/profileDeletion.d.ts +39 -0
- package/dist/api/profile/profileDeletion.js +48 -0
- package/dist/api/profile/profileFriend.d.ts +99 -0
- package/dist/api/profile/profileFriend.js +120 -0
- package/dist/api/profile/profileHealth.d.ts +59 -0
- package/dist/api/profile/profileHealth.js +72 -0
- package/dist/api/profile/profileList.d.ts +49 -0
- package/dist/api/profile/profileList.js +60 -0
- package/dist/api/profile/profilePreference.d.ts +239 -0
- package/dist/api/profile/profilePreference.js +288 -0
- package/dist/api/profile/profileReleaseVote.d.ts +39 -0
- package/dist/api/profile/profileReleaseVote.js +48 -0
- package/dist/api/profile/profileRoleList.d.ts +19 -0
- package/dist/api/profile/profileRoleList.js +24 -0
- package/dist/api/release/episode.d.ts +99 -0
- package/dist/api/release/episode.js +120 -0
- package/dist/api/release/favorite.d.ts +39 -0
- package/dist/api/release/favorite.js +48 -0
- package/dist/api/release/filter.d.ts +19 -0
- package/dist/api/release/filter.js +24 -0
- package/dist/api/release/history.d.ts +39 -0
- package/dist/api/release/history.js +48 -0
- package/dist/api/release/index.d.ts +13 -0
- package/dist/api/release/index.js +29 -0
- package/dist/api/release/related.d.ts +19 -0
- package/dist/api/release/related.js +24 -0
- package/dist/api/release/release.d.ts +79 -0
- package/dist/api/release/release.js +96 -0
- package/dist/api/release/releaseComment.d.ts +109 -0
- package/dist/api/release/releaseComment.js +132 -0
- package/dist/api/release/releaseStreamingPlatform.d.ts +19 -0
- package/dist/api/release/releaseStreamingPlatform.js +24 -0
- package/dist/api/release/releaseVideo.d.ts +59 -0
- package/dist/api/release/releaseVideo.js +72 -0
- package/dist/api/release/releaseVideoAppeal.d.ts +49 -0
- package/dist/api/release/releaseVideoAppeal.js +60 -0
- package/dist/api/release/releaseVideoFavorite.d.ts +39 -0
- package/dist/api/release/releaseVideoFavorite.js +48 -0
- package/dist/api/release/schedule.d.ts +19 -0
- package/dist/api/release/schedule.js +24 -0
- package/dist/api/release/type.d.ts +39 -0
- package/dist/api/release/type.js +48 -0
- package/dist/api/report.d.ts +189 -0
- package/dist/api/report.js +228 -0
- package/dist/api/search.d.ts +129 -0
- package/dist/api/search.js +156 -0
- package/dist/classes/Article.d.ts +18 -0
- package/dist/classes/Article.js +44 -0
- package/dist/classes/ArticleComment.d.ts +15 -0
- package/dist/classes/ArticleComment.js +37 -0
- package/dist/classes/BaseArticle.d.ts +21 -0
- package/dist/classes/BaseArticle.js +23 -0
- package/dist/classes/BaseComment.d.ts +22 -0
- package/dist/classes/BaseComment.js +25 -0
- package/dist/classes/BaseProfile.d.ts +29 -0
- package/dist/classes/BaseProfile.js +52 -0
- package/dist/classes/Channel.d.ts +47 -0
- package/dist/classes/Channel.js +108 -0
- package/dist/classes/Collection.d.ts +29 -0
- package/dist/classes/Collection.js +58 -0
- package/dist/classes/Dubber.d.ts +19 -0
- package/dist/classes/Dubber.js +24 -0
- package/dist/classes/Episode.d.ts +20 -0
- package/dist/classes/Episode.js +30 -0
- package/dist/classes/FullProfile.d.ts +70 -0
- package/dist/classes/FullProfile.js +92 -0
- package/dist/classes/Release.d.ts +91 -0
- package/dist/classes/Release.js +150 -0
- package/dist/classes/ReleaseComment.d.ts +16 -0
- package/dist/classes/ReleaseComment.js +45 -0
- package/dist/classes/Source.d.ts +15 -0
- package/dist/classes/Source.js +20 -0
- package/dist/classes/SuggestionArticle.d.ts +14 -0
- package/dist/classes/SuggestionArticle.js +30 -0
- package/dist/client.d.ts +49 -0
- package/dist/client.js +183 -0
- package/dist/endpoints.d.ts +63 -0
- package/dist/endpoints.js +67 -0
- package/dist/errors.d.ts +37 -0
- package/dist/errors.js +122 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +23 -0
- package/dist/types/auth.d.ts +127 -0
- package/dist/types/auth.js +47 -0
- package/dist/types/channel.d.ts +350 -0
- package/dist/types/channel.js +104 -0
- package/dist/types/collection.d.ts +105 -0
- package/dist/types/collection.js +44 -0
- package/dist/types/config.d.ts +41 -0
- package/dist/types/config.js +4 -0
- package/dist/types/index.d.ts +13 -0
- package/dist/types/index.js +26 -0
- package/dist/types/notification.d.ts +81 -0
- package/dist/types/notification.js +2 -0
- package/dist/types/profile.d.ts +339 -0
- package/dist/types/profile.js +46 -0
- package/dist/types/release.d.ts +467 -0
- package/dist/types/release.js +39 -0
- package/dist/types/request.d.ts +138 -0
- package/dist/types/request.js +2 -0
- package/dist/types/response.d.ts +104 -0
- package/dist/types/response.js +35 -0
- package/dist/types/settings.d.ts +119 -0
- package/dist/types/settings.js +48 -0
- package/dist/utils/ArticleBuilder.d.ts +38 -0
- package/dist/utils/ArticleBuilder.js +144 -0
- package/dist/utils/LinkParser.d.ts +253 -0
- package/dist/utils/LinkParser.js +253 -0
- package/dist/utils/Utils.d.ts +3 -0
- package/dist/utils/Utils.js +11 -0
- package/docs/DOCUMENTATION.md +290 -0
- package/package.json +55 -0
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IChangeEmailVerifyResponse, IChangeLoginInfoResponse, IChangeLoginResponse, IChangePasswordResponse, IGoogleBindResponse, IGoogleUnbindResponse, IPrivacyEditRequest, IProfileSettingsResponse, IProfileSocialResponse, IResponse, ISelectPinnedSectionRequest, ISelectThemeRequest, ISocialEditResponse, ISocialPagesEditRequest, IStatusEditRequest, IVkBindResponse, IVkUnbindResponse } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами настроек профиля
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfilePreference {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET profile/preference/avatar/delete
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IProfileSettingsResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profilePreference.avatarDelete(...);
|
|
17
|
+
*/
|
|
18
|
+
avatarDelete(options?: IBaseApiParams): Promise<IProfileSettingsResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* POST profile/preference/avatar/edit
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IProfileSettingsResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profilePreference.avatarEdit(...);
|
|
27
|
+
*/
|
|
28
|
+
avatarEdit(image?: Buffer, name?: string, options?: IBaseApiParams): Promise<IProfileSettingsResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* GET profile/preference/email/change
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IResponse}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profilePreference.changeEmail(...);
|
|
37
|
+
*/
|
|
38
|
+
changeEmail(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IResponse>;
|
|
39
|
+
/**
|
|
40
|
+
* GET profile/preference/email/resend
|
|
41
|
+
*
|
|
42
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
43
|
+
* @returns {@link IResponse}
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* const result = await client.endpoints.profilePreference.changeEmailResend(...);
|
|
47
|
+
*/
|
|
48
|
+
changeEmailResend(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IResponse>;
|
|
49
|
+
/**
|
|
50
|
+
* GET profile/preference/email/verify
|
|
51
|
+
*
|
|
52
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
53
|
+
* @returns {@link IChangeEmailVerifyResponse}
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* const result = await client.endpoints.profilePreference.changeEmailVerify(...);
|
|
57
|
+
*/
|
|
58
|
+
changeEmailVerify(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IChangeEmailVerifyResponse>;
|
|
59
|
+
/**
|
|
60
|
+
* POST profile/preference/login/change
|
|
61
|
+
*
|
|
62
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
63
|
+
* @returns {@link IChangeLoginResponse}
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* const result = await client.endpoints.profilePreference.changeLogin(...);
|
|
67
|
+
*/
|
|
68
|
+
changeLogin(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IChangeLoginResponse>;
|
|
69
|
+
/**
|
|
70
|
+
* POST profile/preference/login/info
|
|
71
|
+
*
|
|
72
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
73
|
+
* @returns {@link IChangeLoginInfoResponse}
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* const result = await client.endpoints.profilePreference.changeLoginInfo(...);
|
|
77
|
+
*/
|
|
78
|
+
changeLoginInfo(options?: IBaseApiParams): Promise<IChangeLoginInfoResponse>;
|
|
79
|
+
/**
|
|
80
|
+
* GET profile/preference/password/change
|
|
81
|
+
*
|
|
82
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
83
|
+
* @returns {@link IChangePasswordResponse}
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* const result = await client.endpoints.profilePreference.changePassword(...);
|
|
87
|
+
*/
|
|
88
|
+
changePassword(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IChangePasswordResponse>;
|
|
89
|
+
/**
|
|
90
|
+
* POST profile/preference/google/bind
|
|
91
|
+
*
|
|
92
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
93
|
+
* @returns {@link IGoogleBindResponse}
|
|
94
|
+
*
|
|
95
|
+
* @example
|
|
96
|
+
* const result = await client.endpoints.profilePreference.googleBind(...);
|
|
97
|
+
*/
|
|
98
|
+
googleBind(data?: Record<string, string | number | undefined>, options?: IBaseApiParams): Promise<IGoogleBindResponse>;
|
|
99
|
+
/**
|
|
100
|
+
* POST profile/preference/google/unbind
|
|
101
|
+
*
|
|
102
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
103
|
+
* @returns {@link IGoogleUnbindResponse}
|
|
104
|
+
*
|
|
105
|
+
* @example
|
|
106
|
+
* const result = await client.endpoints.profilePreference.googleUnbind(...);
|
|
107
|
+
*/
|
|
108
|
+
googleUnbind(options?: IBaseApiParams): Promise<IGoogleUnbindResponse>;
|
|
109
|
+
/**
|
|
110
|
+
* GET profile/preference/my
|
|
111
|
+
*
|
|
112
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
113
|
+
* @returns {@link IProfileSettingsResponse}
|
|
114
|
+
*
|
|
115
|
+
* @example
|
|
116
|
+
* const result = await client.endpoints.profilePreference.my(...);
|
|
117
|
+
*/
|
|
118
|
+
my(options?: IBaseApiParams): Promise<IProfileSettingsResponse>;
|
|
119
|
+
/**
|
|
120
|
+
* POST profile/preference/section/edit
|
|
121
|
+
*
|
|
122
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
123
|
+
* @returns {@link IResponse}
|
|
124
|
+
*
|
|
125
|
+
* @example
|
|
126
|
+
* const result = await client.endpoints.profilePreference.pinSection(...);
|
|
127
|
+
*/
|
|
128
|
+
pinSection(body: ISelectPinnedSectionRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
129
|
+
/**
|
|
130
|
+
* POST profile/preference/privacy/counts/edit
|
|
131
|
+
*
|
|
132
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
133
|
+
* @returns {@link IResponse}
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* const result = await client.endpoints.profilePreference.privacyCountsEdit(...);
|
|
137
|
+
*/
|
|
138
|
+
privacyCountsEdit(body: IPrivacyEditRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
139
|
+
/**
|
|
140
|
+
* POST profile/preference/privacy/friendRequests/edit
|
|
141
|
+
*
|
|
142
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
143
|
+
* @returns {@link IResponse}
|
|
144
|
+
*
|
|
145
|
+
* @example
|
|
146
|
+
* const result = await client.endpoints.profilePreference.privacyFriendRequestsEdit(...);
|
|
147
|
+
*/
|
|
148
|
+
privacyFriendRequestsEdit(body: IPrivacyEditRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
149
|
+
/**
|
|
150
|
+
* GET profile/preference/privacy/incognito/edit
|
|
151
|
+
*
|
|
152
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
153
|
+
* @returns {@link IResponse}
|
|
154
|
+
*
|
|
155
|
+
* @example
|
|
156
|
+
* const result = await client.endpoints.profilePreference.privacyIncognitoEdit(...);
|
|
157
|
+
*/
|
|
158
|
+
privacyIncognitoEdit(options?: IBaseApiParams): Promise<IResponse>;
|
|
159
|
+
/**
|
|
160
|
+
* POST profile/preference/privacy/social/edit
|
|
161
|
+
*
|
|
162
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
163
|
+
* @returns {@link IResponse}
|
|
164
|
+
*
|
|
165
|
+
* @example
|
|
166
|
+
* const result = await client.endpoints.profilePreference.privacySocialEdit(...);
|
|
167
|
+
*/
|
|
168
|
+
privacySocialEdit(body: IPrivacyEditRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
169
|
+
/**
|
|
170
|
+
* POST profile/preference/privacy/stats/edit
|
|
171
|
+
*
|
|
172
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
173
|
+
* @returns {@link IResponse}
|
|
174
|
+
*
|
|
175
|
+
* @example
|
|
176
|
+
* const result = await client.endpoints.profilePreference.privacyStatsEdit(...);
|
|
177
|
+
*/
|
|
178
|
+
privacyStatsEdit(body: IPrivacyEditRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
179
|
+
/**
|
|
180
|
+
* POST profile/preference/themes/edit
|
|
181
|
+
*
|
|
182
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
183
|
+
* @returns {@link IResponse}
|
|
184
|
+
*
|
|
185
|
+
* @example
|
|
186
|
+
* const result = await client.endpoints.profilePreference.selectTheme(...);
|
|
187
|
+
*/
|
|
188
|
+
selectTheme(body: ISelectThemeRequest, options?: IBaseApiParams): Promise<IResponse>;
|
|
189
|
+
/**
|
|
190
|
+
* GET profile/preference/social
|
|
191
|
+
*
|
|
192
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
193
|
+
* @returns {@link IProfileSocialResponse}
|
|
194
|
+
*
|
|
195
|
+
* @example
|
|
196
|
+
* const result = await client.endpoints.profilePreference.social(...);
|
|
197
|
+
*/
|
|
198
|
+
social(options?: IBaseApiParams): Promise<IProfileSocialResponse>;
|
|
199
|
+
/**
|
|
200
|
+
* POST profile/preference/social/edit
|
|
201
|
+
*
|
|
202
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
203
|
+
* @returns {@link ISocialEditResponse}
|
|
204
|
+
*
|
|
205
|
+
* @example
|
|
206
|
+
* const result = await client.endpoints.profilePreference.socialPagesEdit(...);
|
|
207
|
+
*/
|
|
208
|
+
socialPagesEdit(body: ISocialPagesEditRequest, options?: IBaseApiParams): Promise<ISocialEditResponse>;
|
|
209
|
+
/**
|
|
210
|
+
* POST profile/preference/status/edit
|
|
211
|
+
*
|
|
212
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
213
|
+
* @returns {@link IProfileSettingsResponse}
|
|
214
|
+
*
|
|
215
|
+
* @example
|
|
216
|
+
* const result = await client.endpoints.profilePreference.statusEdit(...);
|
|
217
|
+
*/
|
|
218
|
+
statusEdit(body: IStatusEditRequest, options?: IBaseApiParams): Promise<IProfileSettingsResponse>;
|
|
219
|
+
/**
|
|
220
|
+
* POST profile/preference/vk/bind
|
|
221
|
+
*
|
|
222
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
223
|
+
* @returns {@link IVkBindResponse}
|
|
224
|
+
*
|
|
225
|
+
* @example
|
|
226
|
+
* const result = await client.endpoints.profilePreference.vkBind(...);
|
|
227
|
+
*/
|
|
228
|
+
vkBind(data?: Record<string, string | number | undefined>, options?: IBaseApiParams): Promise<IVkBindResponse>;
|
|
229
|
+
/**
|
|
230
|
+
* POST profile/preference/vk/unbind
|
|
231
|
+
*
|
|
232
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
233
|
+
* @returns {@link IVkUnbindResponse}
|
|
234
|
+
*
|
|
235
|
+
* @example
|
|
236
|
+
* const result = await client.endpoints.profilePreference.vkUnbind(...);
|
|
237
|
+
*/
|
|
238
|
+
vkUnbind(options?: IBaseApiParams): Promise<IVkUnbindResponse>;
|
|
239
|
+
}
|
|
@@ -0,0 +1,288 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfilePreference = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами настроек профиля
|
|
6
|
+
*/
|
|
7
|
+
class ProfilePreference {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET profile/preference/avatar/delete
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IProfileSettingsResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profilePreference.avatarDelete(...);
|
|
19
|
+
*/
|
|
20
|
+
async avatarDelete(options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/preference/avatar/delete`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* POST profile/preference/avatar/edit
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IProfileSettingsResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profilePreference.avatarEdit(...);
|
|
31
|
+
*/
|
|
32
|
+
async avatarEdit(image, name, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/preference/avatar/edit`, method: 'POST', image: image ? { type: 'image', name: name !== null && name !== void 0 ? name : 'image.jpg', stream: image } : undefined, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/preference/email/change
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profilePreference.changeEmail(...);
|
|
43
|
+
*/
|
|
44
|
+
async changeEmail(query, options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/preference/email/change`, queryParams: query, apiV2: true, ...options });
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* GET profile/preference/email/resend
|
|
49
|
+
*
|
|
50
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
51
|
+
* @returns {@link IResponse}
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const result = await client.endpoints.profilePreference.changeEmailResend(...);
|
|
55
|
+
*/
|
|
56
|
+
async changeEmailResend(query, options) {
|
|
57
|
+
return await this.client.call({ path: `/profile/preference/email/resend`, queryParams: query, ...options });
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* GET profile/preference/email/verify
|
|
61
|
+
*
|
|
62
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
63
|
+
* @returns {@link IChangeEmailVerifyResponse}
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* const result = await client.endpoints.profilePreference.changeEmailVerify(...);
|
|
67
|
+
*/
|
|
68
|
+
async changeEmailVerify(query, options) {
|
|
69
|
+
return await this.client.call({ path: `/profile/preference/email/verify`, queryParams: query, ...options });
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* POST profile/preference/login/change
|
|
73
|
+
*
|
|
74
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
75
|
+
* @returns {@link IChangeLoginResponse}
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* const result = await client.endpoints.profilePreference.changeLogin(...);
|
|
79
|
+
*/
|
|
80
|
+
async changeLogin(query, options) {
|
|
81
|
+
return await this.client.call({ path: `/profile/preference/login/change`, method: 'POST', queryParams: query, ...options });
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* POST profile/preference/login/info
|
|
85
|
+
*
|
|
86
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
87
|
+
* @returns {@link IChangeLoginInfoResponse}
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* const result = await client.endpoints.profilePreference.changeLoginInfo(...);
|
|
91
|
+
*/
|
|
92
|
+
async changeLoginInfo(options) {
|
|
93
|
+
return await this.client.call({ path: `/profile/preference/login/info`, method: 'POST', ...options });
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* GET profile/preference/password/change
|
|
97
|
+
*
|
|
98
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
99
|
+
* @returns {@link IChangePasswordResponse}
|
|
100
|
+
*
|
|
101
|
+
* @example
|
|
102
|
+
* const result = await client.endpoints.profilePreference.changePassword(...);
|
|
103
|
+
*/
|
|
104
|
+
async changePassword(query, options) {
|
|
105
|
+
return await this.client.call({ path: `/profile/preference/password/change`, queryParams: query, ...options });
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* POST profile/preference/google/bind
|
|
109
|
+
*
|
|
110
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
111
|
+
* @returns {@link IGoogleBindResponse}
|
|
112
|
+
*
|
|
113
|
+
* @example
|
|
114
|
+
* const result = await client.endpoints.profilePreference.googleBind(...);
|
|
115
|
+
*/
|
|
116
|
+
async googleBind(data, options) {
|
|
117
|
+
return await this.client.call({ path: `/profile/preference/google/bind`, method: 'POST', urlEncoded: data, ...options });
|
|
118
|
+
}
|
|
119
|
+
/**
|
|
120
|
+
* POST profile/preference/google/unbind
|
|
121
|
+
*
|
|
122
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
123
|
+
* @returns {@link IGoogleUnbindResponse}
|
|
124
|
+
*
|
|
125
|
+
* @example
|
|
126
|
+
* const result = await client.endpoints.profilePreference.googleUnbind(...);
|
|
127
|
+
*/
|
|
128
|
+
async googleUnbind(options) {
|
|
129
|
+
return await this.client.call({ path: `/profile/preference/google/unbind`, method: 'POST', ...options });
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* GET profile/preference/my
|
|
133
|
+
*
|
|
134
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
135
|
+
* @returns {@link IProfileSettingsResponse}
|
|
136
|
+
*
|
|
137
|
+
* @example
|
|
138
|
+
* const result = await client.endpoints.profilePreference.my(...);
|
|
139
|
+
*/
|
|
140
|
+
async my(options) {
|
|
141
|
+
return await this.client.call({ path: `/profile/preference/my`, ...options });
|
|
142
|
+
}
|
|
143
|
+
/**
|
|
144
|
+
* POST profile/preference/section/edit
|
|
145
|
+
*
|
|
146
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
147
|
+
* @returns {@link IResponse}
|
|
148
|
+
*
|
|
149
|
+
* @example
|
|
150
|
+
* const result = await client.endpoints.profilePreference.pinSection(...);
|
|
151
|
+
*/
|
|
152
|
+
async pinSection(body, options) {
|
|
153
|
+
return await this.client.call({ path: `/profile/preference/section/edit`, method: 'POST', json: body, ...options });
|
|
154
|
+
}
|
|
155
|
+
/**
|
|
156
|
+
* POST profile/preference/privacy/counts/edit
|
|
157
|
+
*
|
|
158
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
159
|
+
* @returns {@link IResponse}
|
|
160
|
+
*
|
|
161
|
+
* @example
|
|
162
|
+
* const result = await client.endpoints.profilePreference.privacyCountsEdit(...);
|
|
163
|
+
*/
|
|
164
|
+
async privacyCountsEdit(body, options) {
|
|
165
|
+
return await this.client.call({ path: `/profile/preference/privacy/counts/edit`, method: 'POST', json: body, ...options });
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* POST profile/preference/privacy/friendRequests/edit
|
|
169
|
+
*
|
|
170
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
171
|
+
* @returns {@link IResponse}
|
|
172
|
+
*
|
|
173
|
+
* @example
|
|
174
|
+
* const result = await client.endpoints.profilePreference.privacyFriendRequestsEdit(...);
|
|
175
|
+
*/
|
|
176
|
+
async privacyFriendRequestsEdit(body, options) {
|
|
177
|
+
return await this.client.call({ path: `/profile/preference/privacy/friendRequests/edit`, method: 'POST', json: body, ...options });
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* GET profile/preference/privacy/incognito/edit
|
|
181
|
+
*
|
|
182
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
183
|
+
* @returns {@link IResponse}
|
|
184
|
+
*
|
|
185
|
+
* @example
|
|
186
|
+
* const result = await client.endpoints.profilePreference.privacyIncognitoEdit(...);
|
|
187
|
+
*/
|
|
188
|
+
async privacyIncognitoEdit(options) {
|
|
189
|
+
return await this.client.call({ path: `/profile/preference/privacy/incognito/edit`, ...options });
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* POST profile/preference/privacy/social/edit
|
|
193
|
+
*
|
|
194
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
195
|
+
* @returns {@link IResponse}
|
|
196
|
+
*
|
|
197
|
+
* @example
|
|
198
|
+
* const result = await client.endpoints.profilePreference.privacySocialEdit(...);
|
|
199
|
+
*/
|
|
200
|
+
async privacySocialEdit(body, options) {
|
|
201
|
+
return await this.client.call({ path: `/profile/preference/privacy/social/edit`, method: 'POST', json: body, ...options });
|
|
202
|
+
}
|
|
203
|
+
/**
|
|
204
|
+
* POST profile/preference/privacy/stats/edit
|
|
205
|
+
*
|
|
206
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
207
|
+
* @returns {@link IResponse}
|
|
208
|
+
*
|
|
209
|
+
* @example
|
|
210
|
+
* const result = await client.endpoints.profilePreference.privacyStatsEdit(...);
|
|
211
|
+
*/
|
|
212
|
+
async privacyStatsEdit(body, options) {
|
|
213
|
+
return await this.client.call({ path: `/profile/preference/privacy/stats/edit`, method: 'POST', json: body, ...options });
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* POST profile/preference/themes/edit
|
|
217
|
+
*
|
|
218
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
219
|
+
* @returns {@link IResponse}
|
|
220
|
+
*
|
|
221
|
+
* @example
|
|
222
|
+
* const result = await client.endpoints.profilePreference.selectTheme(...);
|
|
223
|
+
*/
|
|
224
|
+
async selectTheme(body, options) {
|
|
225
|
+
return await this.client.call({ path: `/profile/preference/themes/edit`, method: 'POST', json: body, ...options });
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* GET profile/preference/social
|
|
229
|
+
*
|
|
230
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
231
|
+
* @returns {@link IProfileSocialResponse}
|
|
232
|
+
*
|
|
233
|
+
* @example
|
|
234
|
+
* const result = await client.endpoints.profilePreference.social(...);
|
|
235
|
+
*/
|
|
236
|
+
async social(options) {
|
|
237
|
+
return await this.client.call({ path: `/profile/preference/social`, ...options });
|
|
238
|
+
}
|
|
239
|
+
/**
|
|
240
|
+
* POST profile/preference/social/edit
|
|
241
|
+
*
|
|
242
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
243
|
+
* @returns {@link ISocialEditResponse}
|
|
244
|
+
*
|
|
245
|
+
* @example
|
|
246
|
+
* const result = await client.endpoints.profilePreference.socialPagesEdit(...);
|
|
247
|
+
*/
|
|
248
|
+
async socialPagesEdit(body, options) {
|
|
249
|
+
return await this.client.call({ path: `/profile/preference/social/edit`, method: 'POST', json: body, ...options });
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* POST profile/preference/status/edit
|
|
253
|
+
*
|
|
254
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
255
|
+
* @returns {@link IProfileSettingsResponse}
|
|
256
|
+
*
|
|
257
|
+
* @example
|
|
258
|
+
* const result = await client.endpoints.profilePreference.statusEdit(...);
|
|
259
|
+
*/
|
|
260
|
+
async statusEdit(body, options) {
|
|
261
|
+
return await this.client.call({ path: `/profile/preference/status/edit`, method: 'POST', json: body, ...options });
|
|
262
|
+
}
|
|
263
|
+
/**
|
|
264
|
+
* POST profile/preference/vk/bind
|
|
265
|
+
*
|
|
266
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
267
|
+
* @returns {@link IVkBindResponse}
|
|
268
|
+
*
|
|
269
|
+
* @example
|
|
270
|
+
* const result = await client.endpoints.profilePreference.vkBind(...);
|
|
271
|
+
*/
|
|
272
|
+
async vkBind(data, options) {
|
|
273
|
+
return await this.client.call({ path: `/profile/preference/vk/bind`, method: 'POST', urlEncoded: data, ...options });
|
|
274
|
+
}
|
|
275
|
+
/**
|
|
276
|
+
* POST profile/preference/vk/unbind
|
|
277
|
+
*
|
|
278
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
279
|
+
* @returns {@link IVkUnbindResponse}
|
|
280
|
+
*
|
|
281
|
+
* @example
|
|
282
|
+
* const result = await client.endpoints.profilePreference.vkUnbind(...);
|
|
283
|
+
*/
|
|
284
|
+
async vkUnbind(options) {
|
|
285
|
+
return await this.client.call({ path: `/profile/preference/vk/unbind`, method: 'POST', ...options });
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
exports.ProfilePreference = ProfilePreference;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IPageableResponse, IRelease, IVoteRelease } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами оценок релизов
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileReleaseVote {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET /profile/vote/release/unvoted/{page}
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IPageableResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileReleaseVote.allReleaseUnvoted(1, ...);
|
|
17
|
+
*/
|
|
18
|
+
allReleaseUnvoted(page: number, options?: IBaseApiParams): Promise<IPageableResponse<IRelease>>;
|
|
19
|
+
/**
|
|
20
|
+
* GET /profile/vote/release/voted/{p_id}/{page}
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IPageableResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profileReleaseVote.allReleaseVoted(1, 1, ...);
|
|
27
|
+
*/
|
|
28
|
+
allReleaseVoted(profileId: number, page: number, query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IPageableResponse<IVoteRelease>>;
|
|
29
|
+
/**
|
|
30
|
+
* GET /profile/vote/release/unvoted/last
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IPageableResponse}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profileReleaseVote.lastReleaseUnvoted(...);
|
|
37
|
+
*/
|
|
38
|
+
lastReleaseUnvoted(options?: IBaseApiParams): Promise<IPageableResponse<IRelease>>;
|
|
39
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileReleaseVote = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами оценок релизов
|
|
6
|
+
*/
|
|
7
|
+
class ProfileReleaseVote {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET /profile/vote/release/unvoted/{page}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IPageableResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileReleaseVote.allReleaseUnvoted(1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async allReleaseUnvoted(page, options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/vote/release/unvoted/${page}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* GET /profile/vote/release/voted/{p_id}/{page}
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IPageableResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileReleaseVote.allReleaseVoted(1, 1, ...);
|
|
31
|
+
*/
|
|
32
|
+
async allReleaseVoted(profileId, page, query, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/vote/release/voted/${profileId}/${page}`, queryParams: query, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET /profile/vote/release/unvoted/last
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IPageableResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileReleaseVote.lastReleaseUnvoted(...);
|
|
43
|
+
*/
|
|
44
|
+
async lastReleaseUnvoted(options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/vote/release/unvoted/last`, ...options });
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.ProfileReleaseVote = ProfileReleaseVote;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IPageableResponse, IProfileRole } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами ролей
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileRoleList {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET role/all/{page}/{role_id}
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IPageableResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileRoleList.all(1, 1, ...);
|
|
17
|
+
*/
|
|
18
|
+
all(page: number, roleId: number, options?: IBaseApiParams): Promise<IPageableResponse<IProfileRole>>;
|
|
19
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileRoleList = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами ролей
|
|
6
|
+
*/
|
|
7
|
+
class ProfileRoleList {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET role/all/{page}/{role_id}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IPageableResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileRoleList.all(1, 1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async all(page, roleId, options) {
|
|
21
|
+
return await this.client.call({ path: `/role/all/${page}/${roleId}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.ProfileRoleList = ProfileRoleList;
|