anilink-api-wrapper 1.17.4 → 1.17.6
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 +319 -0
- package/dist/AniLink.js +10 -0
- package/dist/apis/anilist/interfaces/Activity.js +8 -0
- package/dist/apis/anilist/interfaces/ActivityNotification.js +4 -0
- package/dist/apis/anilist/interfaces/ActivityReply.js +4 -0
- package/dist/apis/anilist/interfaces/BasicComment.js +4 -0
- package/dist/apis/anilist/interfaces/BasicThread.js +4 -0
- package/dist/apis/anilist/interfaces/BasicUser.js +4 -0
- package/dist/apis/anilist/interfaces/CoverImage.js +4 -0
- package/dist/apis/anilist/interfaces/ExternalLink.js +4 -0
- package/dist/apis/anilist/interfaces/FuzzyDate.js +4 -0
- package/dist/apis/anilist/interfaces/Image.js +4 -0
- package/dist/apis/anilist/interfaces/MediaListEntry.js +4 -0
- package/dist/apis/anilist/interfaces/Name.js +4 -0
- package/dist/apis/anilist/interfaces/NextAiringEpisode.js +4 -0
- package/dist/apis/anilist/interfaces/Ranking.js +4 -0
- package/dist/apis/anilist/interfaces/ScoreDistribution.js +4 -0
- package/dist/apis/anilist/interfaces/SiteTrend.js +4 -0
- package/dist/apis/anilist/interfaces/SiteTrendConnection.js +4 -0
- package/dist/apis/anilist/interfaces/StatusDistribution.js +4 -0
- package/dist/apis/anilist/interfaces/StreamingEpisode.js +4 -0
- package/dist/apis/anilist/interfaces/Tag.js +4 -0
- package/dist/apis/anilist/interfaces/ThreadNotification.js +4 -0
- package/dist/apis/anilist/interfaces/Title.js +4 -0
- package/dist/apis/anilist/interfaces/Trailer.js +4 -0
- package/dist/apis/anilist/interfaces/UserStats.js +8 -0
- package/dist/apis/anilist/interfaces/responses/query/AiringSchedule.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Character.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Media.js +8 -0
- package/dist/apis/anilist/interfaces/responses/query/MediaList.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/MediaListCollectionResponse.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/MediaTrend.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Notification.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Recommendation.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Review.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/SiteStatistics.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Staff.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Studio.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/Thread.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/ThreadComment.js +4 -0
- package/dist/apis/anilist/interfaces/responses/query/User.js +4 -0
- package/dist/apis/anilist/mutation/SaveMediaListEntry.js +15 -0
- package/dist/apis/anilist/mutation/UpdateMediaListEntries.js +15 -0
- package/dist/apis/anilist/mutation/UpdateUser.js +15 -0
- package/dist/apis/anilist/query/Activity.js +15 -0
- package/dist/apis/anilist/query/ActivityReply.js +15 -0
- package/dist/apis/anilist/query/AiringSchedule.js +15 -0
- package/dist/apis/anilist/query/AniChartUser.js +14 -0
- package/dist/apis/anilist/query/Character.js +15 -0
- package/dist/apis/anilist/query/ExternalLinkSourceCollection.js +17 -2
- package/dist/apis/anilist/query/Follower.js +15 -0
- package/dist/apis/anilist/query/Following.js +15 -0
- package/dist/apis/anilist/query/GenreCollection.js +14 -0
- package/dist/apis/anilist/query/Markdown.js +15 -0
- package/dist/apis/anilist/query/Media.js +15 -0
- package/dist/apis/anilist/query/MediaList.js +15 -0
- package/dist/apis/anilist/query/MediaListCollection.js +15 -0
- package/dist/apis/anilist/query/MediaTagCollection.js +17 -2
- package/dist/apis/anilist/query/MediaTrend.js +15 -0
- package/dist/apis/anilist/query/Notification.js +15 -0
- package/dist/apis/anilist/query/Recommendation.js +15 -0
- package/dist/apis/anilist/query/Review.js +15 -0
- package/dist/apis/anilist/query/SiteStatistics.js +17 -2
- package/dist/apis/anilist/query/Staff.js +15 -0
- package/dist/apis/anilist/query/Studio.js +15 -0
- package/dist/apis/anilist/query/Thread.js +15 -0
- package/dist/apis/anilist/query/ThreadComment.js +15 -0
- package/dist/apis/anilist/query/User.js +15 -0
- package/dist/apis/anilist/query/Viewer.js +15 -0
- package/dist/apis/anilist/query/page/Activities.js +15 -0
- package/dist/apis/anilist/query/page/ActivityReplies.js +15 -0
- package/dist/apis/anilist/query/page/AiringSchedules.js +15 -0
- package/dist/apis/anilist/query/page/Characters.js +15 -0
- package/dist/apis/anilist/query/page/Followers.js +15 -0
- package/dist/apis/anilist/query/page/Followings.js +15 -0
- package/dist/apis/anilist/query/page/Likes.js +15 -0
- package/dist/apis/anilist/query/page/MediaLists.js +15 -0
- package/dist/apis/anilist/query/page/MediaTrends.js +15 -0
- package/dist/apis/anilist/query/page/Medias.js +13 -0
- package/dist/apis/anilist/query/page/Notifications.js +15 -0
- package/dist/apis/anilist/query/page/Recommendations.js +15 -0
- package/dist/apis/anilist/query/page/Reviews.js +15 -0
- package/dist/apis/anilist/query/page/Staffs.js +15 -0
- package/dist/apis/anilist/query/page/Studios.js +15 -0
- package/dist/apis/anilist/query/page/ThreadCommments.js +15 -0
- package/dist/apis/anilist/query/page/Threads.js +15 -0
- package/dist/apis/anilist/query/page/Users.js +15 -0
- package/dist/base/APIWrapper.js +8 -0
- package/dist/base/RequestHandler.js +9 -0
- package/package.json +4 -1
- package/typedoc.json +15 -0
package/README.md
CHANGED
|
@@ -1 +1,320 @@
|
|
|
1
1
|
# AniLink
|
|
2
|
+
|
|
3
|
+
For full documentation on methods and parameters, please refer to the [AniLink documentation](https://rlalpha49.github.io/AniLink/).
|
|
4
|
+
|
|
5
|
+
AniLink is a TypeScript library for interacting with the AniList API. It provides methods for querying and mutating data, making it easier to integrate AniList's features into your own applications.
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
|
|
9
|
+
To install AniLink, you can use npm:
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm install anilink-api-wrapper
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Initialization
|
|
16
|
+
|
|
17
|
+
### AniList
|
|
18
|
+
|
|
19
|
+
To start using AniLink, you need to import it and initialize it with an optional authentication token. You can get an authentication token by registering your application on the AniList website.
|
|
20
|
+
|
|
21
|
+
#### Typescript
|
|
22
|
+
|
|
23
|
+
```typescript
|
|
24
|
+
import AniLink from 'anilink-api-wrapper';
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
#### Javascript
|
|
28
|
+
|
|
29
|
+
```javascript
|
|
30
|
+
const AniLink = require('anilink-api-wrapper');
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
#### Initialization
|
|
34
|
+
|
|
35
|
+
```typescript
|
|
36
|
+
const authToken = 'your-auth-token';
|
|
37
|
+
const aniLink = new AniLink(authToken);
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
You can also initialize AniLink without an authentication token
|
|
41
|
+
|
|
42
|
+
```typescript
|
|
43
|
+
const aniLink = new AniLink();
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Structure
|
|
47
|
+
|
|
48
|
+
AniLink for AniList is divided into two main sections: `anilist.query` and `anilist.mutation`. The `anilist.query` section contains methods for querying data from the AniList API, while the `anilist.mutation` section contains methods for mutating data.
|
|
49
|
+
|
|
50
|
+
### Query Methods
|
|
51
|
+
|
|
52
|
+
The `anilist.query` section is further divided into main query methods and page query methods. The main query methods return a single piece of data, while the page query methods return pages of data.
|
|
53
|
+
|
|
54
|
+
List of main query methods in `anilist.query`:
|
|
55
|
+
|
|
56
|
+
- user
|
|
57
|
+
- media
|
|
58
|
+
- mediaTrend
|
|
59
|
+
- airingSchedule
|
|
60
|
+
- character
|
|
61
|
+
- staff
|
|
62
|
+
- mediaList
|
|
63
|
+
- mediaListCollection
|
|
64
|
+
- genreCollection
|
|
65
|
+
- mediaTagCollection
|
|
66
|
+
- viewer
|
|
67
|
+
- notification
|
|
68
|
+
- studio
|
|
69
|
+
- review
|
|
70
|
+
- activity
|
|
71
|
+
- activityReply
|
|
72
|
+
- following
|
|
73
|
+
- follower
|
|
74
|
+
- thread
|
|
75
|
+
- threadComment
|
|
76
|
+
- recommendation
|
|
77
|
+
- markdown
|
|
78
|
+
- aniChartUser
|
|
79
|
+
- siteStatistics
|
|
80
|
+
- externalLinkSourceCollection
|
|
81
|
+
|
|
82
|
+
List of page query methods in `anilist.query.page`:
|
|
83
|
+
|
|
84
|
+
- users
|
|
85
|
+
- medias
|
|
86
|
+
- characters
|
|
87
|
+
- staffs
|
|
88
|
+
- studios
|
|
89
|
+
- mediaLists
|
|
90
|
+
- airingSchedules
|
|
91
|
+
- mediaTrends
|
|
92
|
+
- notifications
|
|
93
|
+
- followers
|
|
94
|
+
- following
|
|
95
|
+
- activities
|
|
96
|
+
- activityReplies
|
|
97
|
+
- threads
|
|
98
|
+
- threadComments
|
|
99
|
+
- reviews
|
|
100
|
+
- recommendations
|
|
101
|
+
- likes
|
|
102
|
+
|
|
103
|
+
### Mutation Methods
|
|
104
|
+
|
|
105
|
+
List of methods in `anilist.mutation`:
|
|
106
|
+
|
|
107
|
+
- updateUser
|
|
108
|
+
- saveMediaListEntry
|
|
109
|
+
- updateMediaListEntries
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
## Examples
|
|
113
|
+
|
|
114
|
+
Here are examples of how to use AniLink to interact with the AniList API:
|
|
115
|
+
|
|
116
|
+
### Querying user data
|
|
117
|
+
|
|
118
|
+
```typescript
|
|
119
|
+
// Querying user data
|
|
120
|
+
aniLink.anilist.query.user({id: 542244, isHTML: true});
|
|
121
|
+
|
|
122
|
+
// Querying media data
|
|
123
|
+
aniLink.anilist.query.media({id: 1, type: 'ANIME'});
|
|
124
|
+
|
|
125
|
+
// Querying media trend data
|
|
126
|
+
aniLink.anilist.query.mediaTrend({mediaId: 1, type: 'ANIME'});
|
|
127
|
+
|
|
128
|
+
// Querying airing schedule data
|
|
129
|
+
aniLink.anilist.query.airingSchedule({mediaId: 130590});
|
|
130
|
+
|
|
131
|
+
// Querying character data
|
|
132
|
+
aniLink.anilist.query.character({
|
|
133
|
+
id: 1,
|
|
134
|
+
asHtml: true,
|
|
135
|
+
mediaSort: ['POPULARITY_DESC'],
|
|
136
|
+
mediaType: 'ANIME',
|
|
137
|
+
mediaOnList: true,
|
|
138
|
+
mediaPage: 1,
|
|
139
|
+
mediaPerPage: 10
|
|
140
|
+
});
|
|
141
|
+
|
|
142
|
+
// Querying staff data
|
|
143
|
+
aniLink.anilist.query.staff({
|
|
144
|
+
id: 132186,
|
|
145
|
+
asHtml: true,
|
|
146
|
+
staffMediaSort: ['POPULARITY_DESC'],
|
|
147
|
+
staffMediaType: 'ANIME',
|
|
148
|
+
staffMediaOnList: true,
|
|
149
|
+
staffMediaPage: 1,
|
|
150
|
+
staffMediaPerPage: 10,
|
|
151
|
+
charactersSort: ['ID'],
|
|
152
|
+
charactersPage: 1,
|
|
153
|
+
charactersPerPage: 10,
|
|
154
|
+
characterMediaSort: ['POPULARITY_DESC'],
|
|
155
|
+
characterMediaOnList: true,
|
|
156
|
+
characterMediaPage: 1,
|
|
157
|
+
characterMediaPerPage: 10
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
// Querying media list data
|
|
161
|
+
aniLink.anilist.query.mediaList({userId: 542244});
|
|
162
|
+
|
|
163
|
+
// Querying media list collection data
|
|
164
|
+
aniLink.anilist.query.mediaListCollection({
|
|
165
|
+
userId: 542244,
|
|
166
|
+
type: 'ANIME',
|
|
167
|
+
status: 'COMPLETED',
|
|
168
|
+
chunk: 1,
|
|
169
|
+
perChunk: 10000
|
|
170
|
+
});
|
|
171
|
+
|
|
172
|
+
// Querying genre collection data
|
|
173
|
+
aniLink.anilist.query.genreCollection();
|
|
174
|
+
|
|
175
|
+
// Querying media tag collection data
|
|
176
|
+
aniLink.anilist.query.mediaTagCollection();
|
|
177
|
+
|
|
178
|
+
// Querying viewer data
|
|
179
|
+
aniLink.anilist.query.viewer({isHTML: true});
|
|
180
|
+
|
|
181
|
+
// Querying notification data
|
|
182
|
+
aniLink.anilist.query.notification({asHtml: true});
|
|
183
|
+
|
|
184
|
+
// Querying studio data
|
|
185
|
+
aniLink.anilist.query.studio({id: 561, asHtml: true});
|
|
186
|
+
|
|
187
|
+
// Querying review data
|
|
188
|
+
aniLink.anilist.query.review({id: 8008, asHtml: true});
|
|
189
|
+
|
|
190
|
+
// Querying activity data
|
|
191
|
+
aniLink.anilist.query.activity({id: 723235883, asHtml: true});
|
|
192
|
+
|
|
193
|
+
// Querying activity reply data
|
|
194
|
+
aniLink.anilist.query.activityReply({id: 12191046, asHtml: true});
|
|
195
|
+
|
|
196
|
+
// Querying following data
|
|
197
|
+
aniLink.anilist.query.following({userId: 542244, asHtml: true});
|
|
198
|
+
|
|
199
|
+
// Querying follower data
|
|
200
|
+
aniLink.anilist.query.follower({userId: 542244, asHtml: true});
|
|
201
|
+
|
|
202
|
+
// Querying thread data
|
|
203
|
+
aniLink.anilist.query.thread({id: 71881, asHtml: true});
|
|
204
|
+
|
|
205
|
+
// Querying thread comment data
|
|
206
|
+
aniLink.anilist.query.threadComment({id: 2555166, asHtml: true});
|
|
207
|
+
|
|
208
|
+
// Querying recommendation data
|
|
209
|
+
aniLink.anilist.query.recommendation({mediaId: 156822, asHtml: true});
|
|
210
|
+
|
|
211
|
+
// Querying markdown data
|
|
212
|
+
aniLink.anilist.query.markdown({markdown: 'Hello'});
|
|
213
|
+
|
|
214
|
+
// Querying AniChartUser data
|
|
215
|
+
aniLink.anilist.query.aniChartUser();
|
|
216
|
+
|
|
217
|
+
// Querying site statistics data
|
|
218
|
+
aniLink.anilist.query.siteStatistics();
|
|
219
|
+
|
|
220
|
+
// Querying external link source collection data
|
|
221
|
+
aniLink.anilist.query.externalLinkSourceCollection();
|
|
222
|
+
|
|
223
|
+
// Querying users page data
|
|
224
|
+
aniLink.anilist.query.page.users({id: 542244, isHTML: true});
|
|
225
|
+
|
|
226
|
+
// Querying media page data
|
|
227
|
+
aniLink.anilist.query.page.medias({id: 1, type: 'ANIME'});
|
|
228
|
+
|
|
229
|
+
// Querying character page data
|
|
230
|
+
aniLink.anilist.query.page.characters({id: 1, asHtml: true});
|
|
231
|
+
|
|
232
|
+
// Querying staff page data
|
|
233
|
+
aniLink.anilist.query.page.staffs({id: 132186, asHtml: true});
|
|
234
|
+
|
|
235
|
+
// Querying studio page data
|
|
236
|
+
aniLink.anilist.query.page.studios({id: 561, asHtml: true});
|
|
237
|
+
|
|
238
|
+
// Querying media list page data
|
|
239
|
+
aniLink.anilist.query.page.mediaLists({userId: 542244});
|
|
240
|
+
|
|
241
|
+
// Querying airing schedule page data
|
|
242
|
+
aniLink.anilist.query.page.airingSchedules({mediaId: 130590});
|
|
243
|
+
|
|
244
|
+
// Querying media trend page data
|
|
245
|
+
aniLink.anilist.query.page.mediaTrends({mediaId: 1, type: 'ANIME'});
|
|
246
|
+
|
|
247
|
+
// Querying notification page data
|
|
248
|
+
aniLink.anilist.query.page.notifications({asHtml: true});
|
|
249
|
+
|
|
250
|
+
// Querying follower page data
|
|
251
|
+
aniLink.anilist.query.page.followers({userId: 542244, asHtml: true});
|
|
252
|
+
|
|
253
|
+
// Querying following page data
|
|
254
|
+
aniLink.anilist.query.page.following({userId: 542244, asHtml: true});
|
|
255
|
+
|
|
256
|
+
// Querying activity page data
|
|
257
|
+
aniLink.anilist.query.page.activities({id: 723235883, asHtml: true});
|
|
258
|
+
|
|
259
|
+
// Querying activity reply page data
|
|
260
|
+
aniLink.anilist.query.page.activityReplies({id: 12191046, asHtml: true
|
|
261
|
+
});
|
|
262
|
+
|
|
263
|
+
// Querying thread page data
|
|
264
|
+
aniLink.anilist.query.page.threads({id: 71881, asHtml: true});
|
|
265
|
+
|
|
266
|
+
// Querying thread comment page data
|
|
267
|
+
aniLink.anilist.query.page.threadComments({threadId: 71881, asHtml: true
|
|
268
|
+
});
|
|
269
|
+
|
|
270
|
+
// Querying review page data
|
|
271
|
+
aniLink.anilist.query.page.reviews({id: 8008, asHtml: true});
|
|
272
|
+
|
|
273
|
+
// Querying recommendation page data
|
|
274
|
+
aniLink.anilist.query.page.recommendations({mediaId: 156822, asHtml: true
|
|
275
|
+
});
|
|
276
|
+
|
|
277
|
+
// Querying likes page data
|
|
278
|
+
aniLink.anilist.query.page.likes({likeableId: 723422275, type: 'ACTIVITY', asHtml: true
|
|
279
|
+
});
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
### Mutating user data
|
|
283
|
+
|
|
284
|
+
```typescript
|
|
285
|
+
// Updating a user
|
|
286
|
+
aniLink.anilist.mutation.updateUser({
|
|
287
|
+
about: 'New about text',
|
|
288
|
+
titleLanguage: 'ENGLISH',
|
|
289
|
+
displayAdultContent: true,
|
|
290
|
+
airingNotifications: true,
|
|
291
|
+
scoreFormat: 'POINT_10',
|
|
292
|
+
rowOrder: 'title',
|
|
293
|
+
profileColor: 'blue',
|
|
294
|
+
donatorBadge: 'Supporter',
|
|
295
|
+
notificationOptions: [{type: 'AIRING', enabled: true}],
|
|
296
|
+
timezone: '-06:00',
|
|
297
|
+
activityMergeTime: 30,
|
|
298
|
+
animeListOptions: {sectionOrder: ['title'], customLists: [], advancedScoring: [], advancedScoringEnabled: false},
|
|
299
|
+
mangaListOptions: {sectionOrder: ['title'], customLists: [], advancedScoring: [], advancedScoringEnabled: false},
|
|
300
|
+
staffNameLanguage: 'ROMAJI',
|
|
301
|
+
restrictMessagesToFollowing: false,
|
|
302
|
+
disabledListActivity: [{type: 'CURRENT', disabled: false}]
|
|
303
|
+
});
|
|
304
|
+
|
|
305
|
+
// Saving media list entries
|
|
306
|
+
aniLink.anilist.mutation.saveMediaListEntry({
|
|
307
|
+
mediaId: 1,
|
|
308
|
+
status: 'CURRENT',
|
|
309
|
+
score: 8.5,
|
|
310
|
+
progress: 3,
|
|
311
|
+
});
|
|
312
|
+
|
|
313
|
+
// Updating media list entries
|
|
314
|
+
aniLink.anilist.mutation.updateMediaListEntries({
|
|
315
|
+
status: 'CURRENT',
|
|
316
|
+
score: 8.5,
|
|
317
|
+
progress: 3,
|
|
318
|
+
ids: [143271, 156822, 170890],
|
|
319
|
+
});
|
|
320
|
+
```
|
package/dist/AniLink.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AniLink = void 0;
|
|
3
4
|
const Activity_1 = require("./apis/anilist/query/Activity");
|
|
4
5
|
const ActivityReply_1 = require("./apis/anilist/query/ActivityReply");
|
|
5
6
|
const ActivityReplies_1 = require("./apis/anilist/query/page/ActivityReplies");
|
|
@@ -46,7 +47,15 @@ const UpdateUser_1 = require("./apis/anilist/mutation/UpdateUser");
|
|
|
46
47
|
const User_1 = require("./apis/anilist/query/User");
|
|
47
48
|
const Users_1 = require("./apis/anilist/query/page/Users");
|
|
48
49
|
const Viewer_1 = require("./apis/anilist/query/Viewer");
|
|
50
|
+
/**
|
|
51
|
+
* `AniLink` is a class for interacting with the APIs.
|
|
52
|
+
* It provides methods for querying and mutating data.
|
|
53
|
+
*/
|
|
49
54
|
class AniLink {
|
|
55
|
+
/**
|
|
56
|
+
* Creates a new AniLink instance.
|
|
57
|
+
* @param {string} authToken - The authentication token to use for API requests.
|
|
58
|
+
*/
|
|
50
59
|
constructor(authToken) {
|
|
51
60
|
const userQueryInstance = new User_1.UserQuery(authToken);
|
|
52
61
|
const mediaQueryInstance = new Media_1.MediaQuery(authToken);
|
|
@@ -150,4 +159,5 @@ class AniLink {
|
|
|
150
159
|
};
|
|
151
160
|
}
|
|
152
161
|
}
|
|
162
|
+
exports.AniLink = AniLink;
|
|
153
163
|
module.exports = AniLink;
|
|
@@ -3,6 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ActivityWithRepliesSchema = exports.ActivitySchema = void 0;
|
|
4
4
|
const BasicUser_1 = require("./BasicUser");
|
|
5
5
|
const ActivityReply_1 = require("./ActivityReply");
|
|
6
|
+
/**
|
|
7
|
+
* `ActivitySchema` is a constant representing the GraphQL schema for an activity query.
|
|
8
|
+
* It includes the TextActivity, ListActivity, and MessageActivity each having their own properties.
|
|
9
|
+
*/
|
|
6
10
|
exports.ActivitySchema = `
|
|
7
11
|
activity {
|
|
8
12
|
... on TextActivity {
|
|
@@ -58,6 +62,10 @@ exports.ActivitySchema = `
|
|
|
58
62
|
}
|
|
59
63
|
}
|
|
60
64
|
`;
|
|
65
|
+
/**
|
|
66
|
+
* `ActivityWithRepliesSchema` is a constant representing the GraphQL schema for an activity query with replies.
|
|
67
|
+
* It includes the TextActivity, ListActivity, and MessageActivity each having their own properties and replies.
|
|
68
|
+
*/
|
|
61
69
|
exports.ActivityWithRepliesSchema = `
|
|
62
70
|
... on TextActivity {
|
|
63
71
|
id
|
|
@@ -3,6 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ActivityNotificationSchema = void 0;
|
|
4
4
|
const Activity_1 = require("./Activity");
|
|
5
5
|
const BasicUser_1 = require("./BasicUser");
|
|
6
|
+
/**
|
|
7
|
+
* `ActivityNotificationSchema` is a constant representing the GraphQL schema for an activity notification query.
|
|
8
|
+
* It includes the id of the notification, the user id, the type of the notification, the activity id, the context, the creation date, the activity details, and the user details.
|
|
9
|
+
*/
|
|
6
10
|
exports.ActivityNotificationSchema = `
|
|
7
11
|
id
|
|
8
12
|
userId
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ActivityReplySchema = void 0;
|
|
4
4
|
const BasicUser_1 = require("./BasicUser");
|
|
5
|
+
/**
|
|
6
|
+
* `ActivityReplySchema` is a constant representing the GraphQL schema for an activity reply query.
|
|
7
|
+
* It includes the id of the reply, the user id, the activity id, the text of the reply, the like count, the like status, the creation date, the user details, and the likes details.
|
|
8
|
+
*/
|
|
5
9
|
exports.ActivityReplySchema = `
|
|
6
10
|
id
|
|
7
11
|
userId
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.BasicCommentSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `BasicCommentSchema` is a string representing the GraphQL schema for a basic comment.
|
|
6
|
+
* It includes the id, user id, and thread id.
|
|
7
|
+
*/
|
|
4
8
|
exports.BasicCommentSchema = `
|
|
5
9
|
id
|
|
6
10
|
userId
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.BasicThreadSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `BasicThreadSchema` is a string representing the GraphQL schema for a basic thread.
|
|
6
|
+
* It includes the id, title, body, and site url.
|
|
7
|
+
*/
|
|
4
8
|
exports.BasicThreadSchema = `
|
|
5
9
|
id
|
|
6
10
|
title
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.BasicUserSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `BasicUserSchema` is a string representing the GraphQL schema for a basic user.
|
|
6
|
+
* It includes the id, name, and avatar with a large size.
|
|
7
|
+
*/
|
|
4
8
|
exports.BasicUserSchema = `
|
|
5
9
|
id
|
|
6
10
|
name
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CoverImageSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `CoverImageSchema` is a string representing the GraphQL schema for a cover image.
|
|
6
|
+
* It includes the extra large, large, medium size images and color.
|
|
7
|
+
*/
|
|
4
8
|
exports.CoverImageSchema = `
|
|
5
9
|
coverImage {
|
|
6
10
|
extraLarge
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ExternalLinkSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `ExternalLinkSchema` is a string representing the GraphQL schema for an external link.
|
|
6
|
+
* It includes the id, url, and site.
|
|
7
|
+
*/
|
|
4
8
|
exports.ExternalLinkSchema = `
|
|
5
9
|
externalLinks {
|
|
6
10
|
id
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.FuzzyDateSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `FuzzyDateSchema` is a string representing the GraphQL schema for a fuzzy date.
|
|
6
|
+
* It includes the year, month, and day.
|
|
7
|
+
*/
|
|
4
8
|
exports.FuzzyDateSchema = `
|
|
5
9
|
year
|
|
6
10
|
month
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ImageSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `ImageSchema` is a string representing the GraphQL schema for an image.
|
|
6
|
+
* It includes the large and medium size images.
|
|
7
|
+
*/
|
|
4
8
|
exports.ImageSchema = `
|
|
5
9
|
image {
|
|
6
10
|
large
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.MediaListEntrySchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `MediaListEntrySchema` is a string representing the GraphQL schema for a media list entry.
|
|
6
|
+
* It includes the id and status.
|
|
7
|
+
*/
|
|
4
8
|
exports.MediaListEntrySchema = `
|
|
5
9
|
mediaListEntry {
|
|
6
10
|
id
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.NameSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `NameSchema` is a string representing the GraphQL schema for a name.
|
|
6
|
+
* It includes the first name, last name, full name, and native name.
|
|
7
|
+
*/
|
|
4
8
|
exports.NameSchema = `
|
|
5
9
|
name {
|
|
6
10
|
first
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.NextAiringEpisodeSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `NextAiringEpisodeSchema` is a string representing the GraphQL schema for a next airing episode.
|
|
6
|
+
* It includes the airing time, time until airing, and the episode number.
|
|
7
|
+
*/
|
|
4
8
|
exports.NextAiringEpisodeSchema = `
|
|
5
9
|
nextAiringEpisode {
|
|
6
10
|
airingAt
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.RankingSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `RankingSchema` is a string representing the GraphQL schema for a ranking.
|
|
6
|
+
* It includes the id, rank, type, format, year, season, all-time status, and context.
|
|
7
|
+
*/
|
|
4
8
|
exports.RankingSchema = `
|
|
5
9
|
rankings {
|
|
6
10
|
id
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.ScoreDistributionSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `ScoreDistributionSchema` is a string representing the GraphQL schema for a score distribution.
|
|
6
|
+
* It includes the score and the amount.
|
|
7
|
+
*/
|
|
4
8
|
exports.ScoreDistributionSchema = `
|
|
5
9
|
scoreDistribution {
|
|
6
10
|
score
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SiteTrendSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `SiteTrendSchema` is a string representing the GraphQL schema for a site trend.
|
|
6
|
+
* It includes the date, count, and change.
|
|
7
|
+
*/
|
|
4
8
|
exports.SiteTrendSchema = `
|
|
5
9
|
date
|
|
6
10
|
count
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SiteTrendConnectionSchema = void 0;
|
|
4
4
|
const SiteTrend_1 = require("./SiteTrend");
|
|
5
|
+
/**
|
|
6
|
+
* `SiteTrendConnectionSchema` is a string representing the GraphQL schema for a site trend connection.
|
|
7
|
+
* It includes the page information and the edges and nodes of the site trends.
|
|
8
|
+
*/
|
|
5
9
|
exports.SiteTrendConnectionSchema = `
|
|
6
10
|
pageInfo {
|
|
7
11
|
total
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.StatusDistributionSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `StatusDistributionSchema` is a string representing the GraphQL schema for a status distribution.
|
|
6
|
+
* It includes the status and amount.
|
|
7
|
+
*/
|
|
4
8
|
exports.StatusDistributionSchema = `
|
|
5
9
|
statusDistribution {
|
|
6
10
|
status
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.StreamingEpisodeSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `StreamingEpisodeSchema` is a string representing the GraphQL schema for a streaming episode.
|
|
6
|
+
* It includes the title, thumbnail, url, and site.
|
|
7
|
+
*/
|
|
4
8
|
exports.StreamingEpisodeSchema = `
|
|
5
9
|
streamingEpisodes {
|
|
6
10
|
title
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TagSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `TagSchema` is a string representing the GraphQL schema for a tag.
|
|
6
|
+
* It includes the id, name, description, category, rank, isGeneralSpoiler, isMediaSpoiler, isAdult, and userId.
|
|
7
|
+
*/
|
|
4
8
|
exports.TagSchema = `
|
|
5
9
|
id
|
|
6
10
|
name
|
|
@@ -4,6 +4,10 @@ exports.ThreadNotificationSchema = void 0;
|
|
|
4
4
|
const BasicThread_1 = require("./BasicThread");
|
|
5
5
|
const BasicComment_1 = require("./BasicComment");
|
|
6
6
|
const BasicUser_1 = require("./BasicUser");
|
|
7
|
+
/**
|
|
8
|
+
* `ThreadNotificationSchema` is a string representing the GraphQL schema for a thread notification.
|
|
9
|
+
* It includes the id, userId, type, commentId, context, createdAt, thread, comment, and user.
|
|
10
|
+
*/
|
|
7
11
|
exports.ThreadNotificationSchema = `
|
|
8
12
|
id
|
|
9
13
|
userId
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TitleSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `TitleSchema` is a string representing the GraphQL schema for a title.
|
|
6
|
+
* It includes the romaji, english, native, and userPreferred.
|
|
7
|
+
*/
|
|
4
8
|
exports.TitleSchema = `
|
|
5
9
|
title {
|
|
6
10
|
romaji
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TrailerSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `TrailerSchema` is a string representing the GraphQL schema for a trailer.
|
|
6
|
+
* It includes the id, site, and thumbnail.
|
|
7
|
+
*/
|
|
4
8
|
exports.TrailerSchema = `
|
|
5
9
|
trailer {
|
|
6
10
|
id
|
|
@@ -1,12 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.UserMangaStatsSchema = exports.UserAnimeStatsSchema = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* `UserAnimeStatsSchema` is a string representing the GraphQL schema for a user's anime statistics.
|
|
6
|
+
* It includes the count, meanScore, minutesWatched, and mediaIds.
|
|
7
|
+
*/
|
|
4
8
|
exports.UserAnimeStatsSchema = `
|
|
5
9
|
count
|
|
6
10
|
meanScore
|
|
7
11
|
minutesWatched
|
|
8
12
|
mediaIds
|
|
9
13
|
`;
|
|
14
|
+
/**
|
|
15
|
+
* `UserMangaStatsSchema` is a string representing the GraphQL schema for a user's manga statistics.
|
|
16
|
+
* It includes the count, meanScore, chaptersRead, and mediaIds.
|
|
17
|
+
*/
|
|
10
18
|
exports.UserMangaStatsSchema = `
|
|
11
19
|
count
|
|
12
20
|
meanScore
|
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.AiringScheduleSchema = void 0;
|
|
4
4
|
const Media_1 = require("./Media");
|
|
5
|
+
/**
|
|
6
|
+
* `AiringScheduleSchema` is a constant representing the GraphQL schema for an airing schedule query.
|
|
7
|
+
* It includes the id, airing time, time until airing, episode number, media id, and the media schema.
|
|
8
|
+
*/
|
|
5
9
|
exports.AiringScheduleSchema = `
|
|
6
10
|
id
|
|
7
11
|
airingAt
|
|
@@ -5,6 +5,10 @@ const FuzzyDate_1 = require("../../FuzzyDate");
|
|
|
5
5
|
const Name_1 = require("../../Name");
|
|
6
6
|
const Image_1 = require("../../Image");
|
|
7
7
|
const Title_1 = require("../../Title");
|
|
8
|
+
/**
|
|
9
|
+
* `CharacterSchema` is a constant representing the GraphQL schema for a character query.
|
|
10
|
+
* It includes the character's id, name, image, description, gender, date of birth, age, blood type, favourite status, site URL, associated media, number of favourites, and moderator notes.
|
|
11
|
+
*/
|
|
8
12
|
exports.CharacterSchema = `
|
|
9
13
|
id
|
|
10
14
|
${Name_1.NameSchema}
|