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,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileBlockList = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами чёрного списка
|
|
6
|
+
*/
|
|
7
|
+
class ProfileBlockList {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET profile/blocklist/add/{id}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IBlockProfileListAddResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileBlockList.addToBlockList(1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async addToBlockList(id2, options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/blocklist/add/${id2}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* GET profile/blocklist/all/{page}
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IPageableResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileBlockList.blockList(1, ...);
|
|
31
|
+
*/
|
|
32
|
+
async blockList(page, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/blocklist/all/${page}`, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/blocklist/remove/{id}
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileBlockList.removeFromBlockList(1, ...);
|
|
43
|
+
*/
|
|
44
|
+
async removeFromBlockList(id2, options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/blocklist/remove/${id2}`, ...options });
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.ProfileBlockList = ProfileBlockList;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IResponse } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами удаления профиля
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileDeletion {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* POST profile/deletion/cancel
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileDeletion.cancel(...);
|
|
17
|
+
*/
|
|
18
|
+
cancel(options?: IBaseApiParams): Promise<IResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* POST profile/deletion/request
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profileDeletion.request(...);
|
|
27
|
+
*/
|
|
28
|
+
request(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* GET profile/deletion/status
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IResponse}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profileDeletion.status(...);
|
|
37
|
+
*/
|
|
38
|
+
status(options?: IBaseApiParams): Promise<IResponse>;
|
|
39
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileDeletion = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами удаления профиля
|
|
6
|
+
*/
|
|
7
|
+
class ProfileDeletion {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* POST profile/deletion/cancel
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileDeletion.cancel(...);
|
|
19
|
+
*/
|
|
20
|
+
async cancel(options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/deletion/cancel`, method: 'POST', ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* POST profile/deletion/request
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileDeletion.request(...);
|
|
31
|
+
*/
|
|
32
|
+
async request(query, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/deletion/request`, method: 'POST', queryParams: query, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/deletion/status
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileDeletion.status(...);
|
|
43
|
+
*/
|
|
44
|
+
async status(options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/deletion/status`, ...options });
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.ProfileDeletion = ProfileDeletion;
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IFriendRequestResponse, IPageableResponse, IProfile, IProfileShort, IResponse } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами друзей
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileFriend {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET profile/friend/all/{id}/{page}
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IPageableResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileFriend.friends(1, 1, ...);
|
|
17
|
+
*/
|
|
18
|
+
friends(id2: number, page: number, options?: IBaseApiParams): Promise<IPageableResponse<IProfileShort>>;
|
|
19
|
+
/**
|
|
20
|
+
* GET profile/friend/recommendations
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IPageableResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profileFriend.recommendations(...);
|
|
27
|
+
*/
|
|
28
|
+
recommendations(options?: IBaseApiParams): Promise<IPageableResponse<IProfileShort>>;
|
|
29
|
+
/**
|
|
30
|
+
* GET profile/friend/request/hide/{id}
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IResponse}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profileFriend.requestHide(1, ...);
|
|
37
|
+
*/
|
|
38
|
+
requestHide(id2: number, options?: IBaseApiParams): Promise<IResponse>;
|
|
39
|
+
/**
|
|
40
|
+
* GET profile/friend/request/remove/{id}
|
|
41
|
+
*
|
|
42
|
+
* Возможные коды ответа: {@link RemoveFriendRequestResult}
|
|
43
|
+
* @returns {@link IFriendRequestResponse}
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* const result = await client.endpoints.profileFriend.requestRemove(1, ...);
|
|
47
|
+
*/
|
|
48
|
+
requestRemove(id2: number, options?: IBaseApiParams): Promise<IFriendRequestResponse>;
|
|
49
|
+
/**
|
|
50
|
+
* GET profile/friend/request/send/{id}
|
|
51
|
+
*
|
|
52
|
+
* Возможные коды ответа: {@link SendFriendRequestResult}
|
|
53
|
+
* @returns {@link IFriendRequestResponse}
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* const result = await client.endpoints.profileFriend.requestSend(1, ...);
|
|
57
|
+
*/
|
|
58
|
+
requestSend(id2: number, options?: IBaseApiParams): Promise<IFriendRequestResponse>;
|
|
59
|
+
/**
|
|
60
|
+
* GET profile/friend/requests/in/{page}
|
|
61
|
+
*
|
|
62
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
63
|
+
* @returns {@link IPageableResponse}
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* const result = await client.endpoints.profileFriend.requestsIn(1, ...);
|
|
67
|
+
*/
|
|
68
|
+
requestsIn(page: number, options?: IBaseApiParams): Promise<IPageableResponse<IProfile>>;
|
|
69
|
+
/**
|
|
70
|
+
* GET profile/friend/requests/in/last
|
|
71
|
+
*
|
|
72
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
73
|
+
* @returns {@link IPageableResponse}
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* const result = await client.endpoints.profileFriend.requestsInLast(...);
|
|
77
|
+
*/
|
|
78
|
+
requestsInLast(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IPageableResponse<IProfile>>;
|
|
79
|
+
/**
|
|
80
|
+
* GET profile/friend/requests/out/{page}
|
|
81
|
+
*
|
|
82
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
83
|
+
* @returns {@link IPageableResponse}
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* const result = await client.endpoints.profileFriend.requestsOut(1, ...);
|
|
87
|
+
*/
|
|
88
|
+
requestsOut(page: number, options?: IBaseApiParams): Promise<IPageableResponse<IProfile>>;
|
|
89
|
+
/**
|
|
90
|
+
* GET profile/friend/requests/out/last
|
|
91
|
+
*
|
|
92
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
93
|
+
* @returns {@link IPageableResponse}
|
|
94
|
+
*
|
|
95
|
+
* @example
|
|
96
|
+
* const result = await client.endpoints.profileFriend.requestsOutLast(...);
|
|
97
|
+
*/
|
|
98
|
+
requestsOutLast(query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IPageableResponse<IProfile>>;
|
|
99
|
+
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileFriend = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами друзей
|
|
6
|
+
*/
|
|
7
|
+
class ProfileFriend {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET profile/friend/all/{id}/{page}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IPageableResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileFriend.friends(1, 1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async friends(id2, page, options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/friend/all/${id2}/${page}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* GET profile/friend/recommendations
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IPageableResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileFriend.recommendations(...);
|
|
31
|
+
*/
|
|
32
|
+
async recommendations(options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/friend/recommendations`, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/friend/request/hide/{id}
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileFriend.requestHide(1, ...);
|
|
43
|
+
*/
|
|
44
|
+
async requestHide(id2, options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/friend/request/hide/${id2}`, ...options });
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* GET profile/friend/request/remove/{id}
|
|
49
|
+
*
|
|
50
|
+
* Возможные коды ответа: {@link RemoveFriendRequestResult}
|
|
51
|
+
* @returns {@link IFriendRequestResponse}
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const result = await client.endpoints.profileFriend.requestRemove(1, ...);
|
|
55
|
+
*/
|
|
56
|
+
async requestRemove(id2, options) {
|
|
57
|
+
return await this.client.call({ path: `/profile/friend/request/remove/${id2}`, ...options });
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* GET profile/friend/request/send/{id}
|
|
61
|
+
*
|
|
62
|
+
* Возможные коды ответа: {@link SendFriendRequestResult}
|
|
63
|
+
* @returns {@link IFriendRequestResponse}
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* const result = await client.endpoints.profileFriend.requestSend(1, ...);
|
|
67
|
+
*/
|
|
68
|
+
async requestSend(id2, options) {
|
|
69
|
+
return await this.client.call({ path: `/profile/friend/request/send/${id2}`, ...options });
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* GET profile/friend/requests/in/{page}
|
|
73
|
+
*
|
|
74
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
75
|
+
* @returns {@link IPageableResponse}
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* const result = await client.endpoints.profileFriend.requestsIn(1, ...);
|
|
79
|
+
*/
|
|
80
|
+
async requestsIn(page, options) {
|
|
81
|
+
return await this.client.call({ path: `/profile/friend/requests/in/${page}`, ...options });
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* GET profile/friend/requests/in/last
|
|
85
|
+
*
|
|
86
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
87
|
+
* @returns {@link IPageableResponse}
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* const result = await client.endpoints.profileFriend.requestsInLast(...);
|
|
91
|
+
*/
|
|
92
|
+
async requestsInLast(query, options) {
|
|
93
|
+
return await this.client.call({ path: `/profile/friend/requests/in/last`, queryParams: query, ...options });
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* GET profile/friend/requests/out/{page}
|
|
97
|
+
*
|
|
98
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
99
|
+
* @returns {@link IPageableResponse}
|
|
100
|
+
*
|
|
101
|
+
* @example
|
|
102
|
+
* const result = await client.endpoints.profileFriend.requestsOut(1, ...);
|
|
103
|
+
*/
|
|
104
|
+
async requestsOut(page, options) {
|
|
105
|
+
return await this.client.call({ path: `/profile/friend/requests/out/${page}`, ...options });
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* GET profile/friend/requests/out/last
|
|
109
|
+
*
|
|
110
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
111
|
+
* @returns {@link IPageableResponse}
|
|
112
|
+
*
|
|
113
|
+
* @example
|
|
114
|
+
* const result = await client.endpoints.profileFriend.requestsOutLast(...);
|
|
115
|
+
*/
|
|
116
|
+
async requestsOutLast(query, options) {
|
|
117
|
+
return await this.client.call({ path: `/profile/friend/requests/out/last`, queryParams: query, ...options });
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
exports.ProfileFriend = ProfileFriend;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IHealthStatusResponse, IProfileEnforcement, IProfileEnforcementAppealRequest, IProfileEnforcementAppealResponse, IProfileEnforcementResponse } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами здоровья аккаунта
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileHealth {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET profile/health/enforcement/account/all/{page}
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IProfileEnforcement[]}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileHealth.account(1, ...);
|
|
17
|
+
*/
|
|
18
|
+
account(page: number, options?: IBaseApiParams): Promise<IProfileEnforcement[]>;
|
|
19
|
+
/**
|
|
20
|
+
* POST profile/health/enforcement/{id}/appeal
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IProfileEnforcementAppealResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profileHealth.appeal(1, ...);
|
|
27
|
+
*/
|
|
28
|
+
appeal(enforcementId: number, body: IProfileEnforcementAppealRequest, options?: IBaseApiParams): Promise<IProfileEnforcementAppealResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* GET profile/health/enforcement/content/all/{page}
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IProfileEnforcement[]}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profileHealth.content(1, ...);
|
|
37
|
+
*/
|
|
38
|
+
content(page: number, options?: IBaseApiParams): Promise<IProfileEnforcement[]>;
|
|
39
|
+
/**
|
|
40
|
+
* GET profile/health/enforcement/{id}
|
|
41
|
+
*
|
|
42
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
43
|
+
* @returns {@link IProfileEnforcementResponse}
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* const result = await client.endpoints.profileHealth.enforcement(1, ...);
|
|
47
|
+
*/
|
|
48
|
+
enforcement(id2: number, options?: IBaseApiParams): Promise<IProfileEnforcementResponse>;
|
|
49
|
+
/**
|
|
50
|
+
* GET profile/health/status
|
|
51
|
+
*
|
|
52
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
53
|
+
* @returns {@link IHealthStatusResponse}
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* const result = await client.endpoints.profileHealth.status(...);
|
|
57
|
+
*/
|
|
58
|
+
status(options?: IBaseApiParams): Promise<IHealthStatusResponse>;
|
|
59
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileHealth = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами здоровья аккаунта
|
|
6
|
+
*/
|
|
7
|
+
class ProfileHealth {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET profile/health/enforcement/account/all/{page}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IProfileEnforcement[]}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileHealth.account(1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async account(page, options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/health/enforcement/account/all/${page}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* POST profile/health/enforcement/{id}/appeal
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IProfileEnforcementAppealResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileHealth.appeal(1, ...);
|
|
31
|
+
*/
|
|
32
|
+
async appeal(enforcementId, body, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/health/enforcement/${enforcementId}/appeal`, method: 'POST', json: body, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/health/enforcement/content/all/{page}
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IProfileEnforcement[]}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileHealth.content(1, ...);
|
|
43
|
+
*/
|
|
44
|
+
async content(page, options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/health/enforcement/content/all/${page}`, ...options });
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* GET profile/health/enforcement/{id}
|
|
49
|
+
*
|
|
50
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
51
|
+
* @returns {@link IProfileEnforcementResponse}
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const result = await client.endpoints.profileHealth.enforcement(1, ...);
|
|
55
|
+
*/
|
|
56
|
+
async enforcement(id2, options) {
|
|
57
|
+
return await this.client.call({ path: `/profile/health/enforcement/${id2}`, ...options });
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* GET profile/health/status
|
|
61
|
+
*
|
|
62
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
63
|
+
* @returns {@link IHealthStatusResponse}
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* const result = await client.endpoints.profileHealth.status(...);
|
|
67
|
+
*/
|
|
68
|
+
async status(options) {
|
|
69
|
+
return await this.client.call({ path: `/profile/health/status`, ...options });
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
exports.ProfileHealth = ProfileHealth;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { Anixart } from "../../client";
|
|
2
|
+
import { IBaseApiParams, IPageableResponse, IProfileListResponse, IRelease } from "../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Класс с эндпоинтами закладок профиля
|
|
5
|
+
*/
|
|
6
|
+
export declare class ProfileList {
|
|
7
|
+
private readonly client;
|
|
8
|
+
constructor(client: Anixart);
|
|
9
|
+
/**
|
|
10
|
+
* GET profile/list/add/{status}/{r_id}
|
|
11
|
+
*
|
|
12
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
13
|
+
* @returns {@link IProfileListResponse}
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* const result = await client.endpoints.profileList.add(1, 1, ...);
|
|
17
|
+
*/
|
|
18
|
+
add(status: number, id2: number, options?: IBaseApiParams): Promise<IProfileListResponse>;
|
|
19
|
+
/**
|
|
20
|
+
* GET profile/list/delete/{status}/{r_id}
|
|
21
|
+
*
|
|
22
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
23
|
+
* @returns {@link IProfileListResponse}
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* const result = await client.endpoints.profileList.delete(1, 1, ...);
|
|
27
|
+
*/
|
|
28
|
+
delete(status: number, id2: number, options?: IBaseApiParams): Promise<IProfileListResponse>;
|
|
29
|
+
/**
|
|
30
|
+
* GET profile/list/all/{status}/{page}
|
|
31
|
+
*
|
|
32
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
33
|
+
* @returns {@link IPageableResponse}
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* const result = await client.endpoints.profileList.profileList(1, 1, ...);
|
|
37
|
+
*/
|
|
38
|
+
profileList(status: number, page: number, query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IPageableResponse<IRelease>>;
|
|
39
|
+
/**
|
|
40
|
+
* GET profile/list/all/{p_id}/{status}/{page}
|
|
41
|
+
*
|
|
42
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
43
|
+
* @returns {@link IPageableResponse}
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* const result = await client.endpoints.profileList.profileListByProfile(1, 1, 1, ...);
|
|
47
|
+
*/
|
|
48
|
+
profileListByProfile(profileId: number, status: number, page: number, query?: Record<string, string | number | boolean | undefined>, options?: IBaseApiParams): Promise<IPageableResponse<IRelease>>;
|
|
49
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProfileList = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Класс с эндпоинтами закладок профиля
|
|
6
|
+
*/
|
|
7
|
+
class ProfileList {
|
|
8
|
+
constructor(client) {
|
|
9
|
+
this.client = client;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* GET profile/list/add/{status}/{r_id}
|
|
13
|
+
*
|
|
14
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
15
|
+
* @returns {@link IProfileListResponse}
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const result = await client.endpoints.profileList.add(1, 1, ...);
|
|
19
|
+
*/
|
|
20
|
+
async add(status, id2, options) {
|
|
21
|
+
return await this.client.call({ path: `/profile/list/add/${status}/${id2}`, ...options });
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* GET profile/list/delete/{status}/{r_id}
|
|
25
|
+
*
|
|
26
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
27
|
+
* @returns {@link IProfileListResponse}
|
|
28
|
+
*
|
|
29
|
+
* @example
|
|
30
|
+
* const result = await client.endpoints.profileList.delete(1, 1, ...);
|
|
31
|
+
*/
|
|
32
|
+
async delete(status, id2, options) {
|
|
33
|
+
return await this.client.call({ path: `/profile/list/delete/${status}/${id2}`, ...options });
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* GET profile/list/all/{status}/{page}
|
|
37
|
+
*
|
|
38
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
39
|
+
* @returns {@link IPageableResponse}
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* const result = await client.endpoints.profileList.profileList(1, 1, ...);
|
|
43
|
+
*/
|
|
44
|
+
async profileList(status, page, query, options) {
|
|
45
|
+
return await this.client.call({ path: `/profile/list/all/${status}/${page}`, queryParams: query, ...options });
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* GET profile/list/all/{p_id}/{status}/{page}
|
|
49
|
+
*
|
|
50
|
+
* Возможные коды ответа: {@link DefaultResult}
|
|
51
|
+
* @returns {@link IPageableResponse}
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const result = await client.endpoints.profileList.profileListByProfile(1, 1, 1, ...);
|
|
55
|
+
*/
|
|
56
|
+
async profileListByProfile(profileId, status, page, query, options) {
|
|
57
|
+
return await this.client.call({ path: `/profile/list/all/${profileId}/${status}/${page}`, queryParams: query, ...options });
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
exports.ProfileList = ProfileList;
|