@brigadasos/nadeshiko-sdk 1.5.0-dev.0c1011b → 1.5.0-dev.2f9d92f

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.
@@ -6,9 +6,9 @@ export type ClientOptions = {
6
6
  */
7
7
  export type MediaFilterItem = {
8
8
  /**
9
- * Media ID to filter
9
+ * Media identifier (publicId or AniList external ID)
10
10
  */
11
- mediaId: number;
11
+ mediaId: string;
12
12
  /**
13
13
  * Specific episodes (omit for all episodes)
14
14
  */
@@ -144,6 +144,10 @@ export type Segment = {
144
144
  * Unique identifier for the segment
145
145
  */
146
146
  uuid: string;
147
+ /**
148
+ * Public identifier for the segment (use this instead of uuid in public URLs)
149
+ */
150
+ publicId: string;
147
151
  /**
148
152
  * Position of the segment within the episode
149
153
  */
@@ -169,6 +173,10 @@ export type Segment = {
169
173
  * Media ID this segment belongs to
170
174
  */
171
175
  mediaId: number;
176
+ /**
177
+ * Public ID of the media this segment belongs to
178
+ */
179
+ mediaPublicId: string;
172
180
  textJa: {
173
181
  /**
174
182
  * Original Japanese content
@@ -250,6 +258,10 @@ export type Seiyuu = {
250
258
  * Internal seiyuu ID
251
259
  */
252
260
  id: number;
261
+ /**
262
+ * Public identifier for the seiyuu (use this in public URLs)
263
+ */
264
+ publicId: string;
253
265
  externalIds: ExternalId;
254
266
  /**
255
267
  * Japanese name of the voice actor
@@ -295,9 +307,13 @@ export type MediaCharacter = {
295
307
  */
296
308
  export type Media = {
297
309
  /**
298
- * Unique identifier for the media
310
+ * Internal unique identifier for the media
299
311
  */
300
312
  id: number;
313
+ /**
314
+ * Public identifier for the media (use this in public URLs)
315
+ */
316
+ publicId: string;
301
317
  externalIds: ExternalId;
302
318
  /**
303
319
  * Original Japanese name of the media
@@ -390,7 +406,7 @@ export type SearchResponse = {
390
406
  segments: Array<Segment>;
391
407
  includes: {
392
408
  /**
393
- * Media objects keyed by mediaId
409
+ * Media objects keyed by media publicId
394
410
  */
395
411
  media: {
396
412
  [key: string]: Media;
@@ -601,6 +617,10 @@ export type MediaSearchStats = {
601
617
  * Media identifier (look up full details in includes.media)
602
618
  */
603
619
  mediaId: number;
620
+ /**
621
+ * Public identifier for use in URLs and filters
622
+ */
623
+ publicId: string;
604
624
  /**
605
625
  * Number of matching segments found in this media
606
626
  */
@@ -627,7 +647,7 @@ export type SearchStatsResponse = {
627
647
  categories: Array<CategoryCount>;
628
648
  includes: {
629
649
  /**
630
- * Media objects keyed by mediaId
650
+ * Media objects keyed by media publicId
631
651
  */
632
652
  media: {
633
653
  [key: string]: Media;
@@ -719,6 +739,20 @@ export type OpaqueCursorPagination = {
719
739
  export type MediaListResponse = {
720
740
  media: Array<Media>;
721
741
  pagination: OpaqueCursorPagination;
742
+ stats: {
743
+ /**
744
+ * Total number of media across all pages
745
+ */
746
+ totalMedia: number;
747
+ /**
748
+ * Total number of non-deleted segments
749
+ */
750
+ totalSegments: number;
751
+ /**
752
+ * Total number of episodes
753
+ */
754
+ totalEpisodes: number;
755
+ };
722
756
  };
723
757
  /**
724
758
  * Character data for creating/updating media
@@ -866,8 +900,34 @@ export type Error409 = {
866
900
  [key: string]: string;
867
901
  };
868
902
  };
903
+ /**
904
+ * Slim media item returned by autocomplete (names + cover only)
905
+ */
906
+ export type MediaAutocompleteItem = {
907
+ /**
908
+ * Unique identifier for the media
909
+ */
910
+ id: number;
911
+ /**
912
+ * Original Japanese name of the media
913
+ */
914
+ nameJa: string;
915
+ /**
916
+ * Romaji transliteration of the media name
917
+ */
918
+ nameRomaji: string;
919
+ /**
920
+ * English name of the media
921
+ */
922
+ nameEn: string;
923
+ /**
924
+ * Full URL to the cover image
925
+ */
926
+ coverUrl: string;
927
+ category: Category;
928
+ };
869
929
  export type MediaAutocompleteResponse = {
870
- media: Array<Media>;
930
+ media: Array<MediaAutocompleteItem>;
871
931
  };
872
932
  /**
873
933
  * Segment with internal fields. For write operations (create, update) all fields are always populated.
@@ -1014,6 +1074,30 @@ export type SegmentContextResponse = {
1014
1074
  };
1015
1075
  };
1016
1076
  };
1077
+ export type SegmentRevision = {
1078
+ /**
1079
+ * Revision ID
1080
+ */
1081
+ id: number;
1082
+ /**
1083
+ * Sequential revision number per segment
1084
+ */
1085
+ revisionNumber: number;
1086
+ /**
1087
+ * Snapshot of editable fields at the time of the revision
1088
+ */
1089
+ snapshot: {
1090
+ [key: string]: unknown;
1091
+ };
1092
+ /**
1093
+ * Name of the user who made the change
1094
+ */
1095
+ userName?: string;
1096
+ /**
1097
+ * When the revision was created
1098
+ */
1099
+ createdAt: string;
1100
+ };
1017
1101
  /**
1018
1102
  * Ordered media series grouping
1019
1103
  */
@@ -1022,6 +1106,10 @@ export type Series = {
1022
1106
  * Series ID
1023
1107
  */
1024
1108
  id: number;
1109
+ /**
1110
+ * Public identifier for the series
1111
+ */
1112
+ publicId: string;
1025
1113
  /**
1026
1114
  * Japanese name of the series
1027
1115
  */
@@ -1078,6 +1166,10 @@ export type Character = {
1078
1166
  * Internal character ID
1079
1167
  */
1080
1168
  id: number;
1169
+ /**
1170
+ * Public identifier for the character (use this in public URLs)
1171
+ */
1172
+ publicId: string;
1081
1173
  externalIds: ExternalId;
1082
1174
  /**
1083
1175
  * Japanese name of the character
@@ -1399,6 +1491,9 @@ export type SegmentCreateRequest = {
1399
1491
  */
1400
1492
  hashedId: string;
1401
1493
  };
1494
+ export type SegmentBatchCreateRequest = {
1495
+ segments: Array<SegmentCreateRequest>;
1496
+ };
1402
1497
  export type UserQuotaResponse = {
1403
1498
  /**
1404
1499
  * Number of API requests used in the current billing period.
@@ -1431,39 +1526,39 @@ export type ReportTargetMedia = {
1431
1526
  */
1432
1527
  type: 'MEDIA';
1433
1528
  /**
1434
- * Media ID this report targets
1529
+ * Public ID of the media this report targets
1435
1530
  */
1436
- mediaId: number;
1531
+ mediaId: string;
1437
1532
  };
1438
- export type ReportTargetSegment = {
1533
+ export type ReportTargetSegmentInput = {
1439
1534
  /**
1440
1535
  * Report target type
1441
1536
  */
1442
1537
  type: 'SEGMENT';
1443
1538
  /**
1444
- * Media ID this report targets
1539
+ * Public ID of the media this report targets
1445
1540
  */
1446
- mediaId: number;
1541
+ mediaId: string;
1447
1542
  /**
1448
1543
  * Episode number containing the segment
1449
1544
  */
1450
1545
  episodeNumber?: number;
1451
1546
  /**
1452
- * Segment UUID this report targets
1547
+ * Segment public ID or UUID
1453
1548
  */
1454
- segmentUuid: string;
1549
+ segmentId: string;
1455
1550
  };
1456
1551
  export type UserReportTarget = ({
1457
1552
  type: 'MEDIA';
1458
1553
  } & ReportTargetMedia) | ({
1459
1554
  type: 'SEGMENT';
1460
- } & ReportTargetSegment);
1555
+ } & ReportTargetSegmentInput);
1461
1556
  export type CreateReportRequest = {
1462
1557
  target: UserReportTarget;
1463
1558
  /**
1464
1559
  * Reason for the report
1465
1560
  */
1466
- reason: 'WRONG_TRANSLATION' | 'WRONG_TIMING' | 'WRONG_AUDIO' | 'NSFW_NOT_TAGGED' | 'DUPLICATE_SEGMENT' | 'WRONG_METADATA' | 'MISSING_EPISODES' | 'WRONG_COVER_IMAGE' | 'INAPPROPRIATE_CONTENT' | 'OTHER';
1561
+ reason: 'WRONG_TRANSLATION' | 'WRONG_TIMING' | 'WRONG_AUDIO' | 'WRONG_JAPANESE_TEXT' | 'LOW_QUALITY_AUDIO' | 'NSFW_NOT_TAGGED' | 'DUPLICATE_SEGMENT' | 'WRONG_TITLE' | 'DUPLICATE_MEDIA' | 'WRONG_EPISODE_NUMBER' | 'IMAGE_ISSUE' | 'MISSING_EPISODES' | 'INAPPROPRIATE_CONTENT' | 'OTHER';
1467
1562
  /**
1468
1563
  * Optional description with additional details
1469
1564
  */
@@ -1475,14 +1570,32 @@ export type ReportTargetEpisode = {
1475
1570
  */
1476
1571
  type: 'EPISODE';
1477
1572
  /**
1478
- * Media ID this report targets
1573
+ * Public ID of the media this report targets
1479
1574
  */
1480
- mediaId: number;
1575
+ mediaId: string;
1481
1576
  /**
1482
1577
  * Episode number this report targets
1483
1578
  */
1484
1579
  episodeNumber: number;
1485
1580
  };
1581
+ export type ReportTargetSegment = {
1582
+ /**
1583
+ * Report target type
1584
+ */
1585
+ type: 'SEGMENT';
1586
+ /**
1587
+ * Public ID of the media this report targets
1588
+ */
1589
+ mediaId: string;
1590
+ /**
1591
+ * Episode number containing the segment
1592
+ */
1593
+ episodeNumber?: number;
1594
+ /**
1595
+ * Segment public ID or UUID
1596
+ */
1597
+ segmentId: string;
1598
+ };
1486
1599
  export type ReportTarget = ({
1487
1600
  type: 'MEDIA';
1488
1601
  } & ReportTargetMedia) | ({
@@ -1507,7 +1620,7 @@ export type Report = {
1507
1620
  /**
1508
1621
  * Reason for the report
1509
1622
  */
1510
- reason: 'WRONG_TRANSLATION' | 'WRONG_TIMING' | 'WRONG_AUDIO' | 'NSFW_NOT_TAGGED' | 'DUPLICATE_SEGMENT' | 'WRONG_METADATA' | 'MISSING_EPISODES' | 'WRONG_COVER_IMAGE' | 'INAPPROPRIATE_CONTENT' | 'OTHER' | 'LOW_SEGMENT_MEDIA' | 'EMPTY_EPISODES' | 'MISSING_EPISODES_AUTO' | 'BAD_SEGMENT_RATIO' | 'MEDIA_WITH_NO_EPISODES' | 'MISSING_TRANSLATIONS' | 'DB_ES_SYNC_ISSUES' | 'HIGH_REPORT_DENSITY';
1623
+ reason: 'WRONG_TRANSLATION' | 'WRONG_TIMING' | 'WRONG_AUDIO' | 'WRONG_JAPANESE_TEXT' | 'LOW_QUALITY_AUDIO' | 'NSFW_NOT_TAGGED' | 'DUPLICATE_SEGMENT' | 'WRONG_METADATA' | 'MISSING_EPISODES' | 'WRONG_COVER_IMAGE' | 'WRONG_TITLE' | 'DUPLICATE_MEDIA' | 'WRONG_EPISODE_NUMBER' | 'IMAGE_ISSUE' | 'INAPPROPRIATE_CONTENT' | 'OTHER' | 'LOW_SEGMENT_MEDIA' | 'EMPTY_EPISODES' | 'MISSING_EPISODES_AUTO' | 'BAD_SEGMENT_RATIO' | 'MEDIA_WITH_NO_EPISODES' | 'MISSING_TRANSLATIONS' | 'DB_ES_SYNC_ISSUES' | 'HIGH_REPORT_DENSITY';
1511
1624
  /**
1512
1625
  * Optional description with additional details
1513
1626
  */
@@ -1586,11 +1699,11 @@ export type UserPreferences = {
1586
1699
  /**
1587
1700
  * Type of user activity
1588
1701
  */
1589
- export type ActivityType = 'SEARCH' | 'ANKI_EXPORT' | 'SEGMENT_PLAY' | 'LIST_ADD_SEGMENT' | 'SHARE';
1702
+ export type ActivityType = 'SEARCH' | 'ANKI_EXPORT' | 'SEGMENT_PLAY' | 'SHARE';
1590
1703
  export type UserActivity = {
1591
1704
  id: number;
1592
1705
  activityType: ActivityType;
1593
- segmentUuid: string;
1706
+ segmentId: number;
1594
1707
  mediaId: number;
1595
1708
  searchQuery: string;
1596
1709
  mediaName: string;
@@ -1604,7 +1717,6 @@ export type HeatmapDayCounts = {
1604
1717
  SEARCH?: number;
1605
1718
  SEGMENT_PLAY?: number;
1606
1719
  ANKI_EXPORT?: number;
1607
- LIST_ADD_SEGMENT?: number;
1608
1720
  SHARE?: number;
1609
1721
  };
1610
1722
  /**
@@ -1615,10 +1727,18 @@ export type Collection = {
1615
1727
  * Collection ID
1616
1728
  */
1617
1729
  id: number;
1730
+ /**
1731
+ * Public identifier for the collection
1732
+ */
1733
+ publicId: string;
1618
1734
  /**
1619
1735
  * Name of the collection
1620
1736
  */
1621
1737
  name: string;
1738
+ /**
1739
+ * Type of the collection
1740
+ */
1741
+ type: 'USER' | 'ANKI_EXPORT';
1622
1742
  /**
1623
1743
  * Visibility of the collection
1624
1744
  */
@@ -1638,9 +1758,9 @@ export type Collection = {
1638
1758
  };
1639
1759
  export type UserExportCollection = Collection & {
1640
1760
  /**
1641
- * Segment UUIDs in saved order
1761
+ * Segment IDs in saved order
1642
1762
  */
1643
- segmentUuids: Array<string>;
1763
+ segmentIds: Array<number>;
1644
1764
  };
1645
1765
  /**
1646
1766
  * User data export payload (identifier-oriented references)
@@ -2214,7 +2334,7 @@ export type GetSegmentByUuidData = {
2214
2334
  body?: never;
2215
2335
  path: {
2216
2336
  /**
2217
- * Segment UUID
2337
+ * Segment UUID or publicId
2218
2338
  */
2219
2339
  uuid: string;
2220
2340
  };
@@ -2264,7 +2384,7 @@ export type UpdateSegmentByUuidData = {
2264
2384
  body: SegmentUpdateRequest;
2265
2385
  path: {
2266
2386
  /**
2267
- * Segment UUID
2387
+ * Segment UUID or publicId
2268
2388
  */
2269
2389
  uuid: string;
2270
2390
  };
@@ -2309,7 +2429,7 @@ export type GetSegmentContextData = {
2309
2429
  body?: never;
2310
2430
  path: {
2311
2431
  /**
2312
- * Segment UUID
2432
+ * Segment UUID or publicId
2313
2433
  */
2314
2434
  uuid: string;
2315
2435
  };
@@ -2359,6 +2479,53 @@ export type GetSegmentContextResponses = {
2359
2479
  200: SegmentContextResponse;
2360
2480
  };
2361
2481
  export type GetSegmentContextResponse = GetSegmentContextResponses[keyof GetSegmentContextResponses];
2482
+ export type ListSegmentRevisionsData = {
2483
+ body?: never;
2484
+ path: {
2485
+ /**
2486
+ * Segment UUID or publicId
2487
+ */
2488
+ uuid: string;
2489
+ };
2490
+ query?: never;
2491
+ url: '/v1/media/segments/{uuid}/revisions';
2492
+ };
2493
+ export type ListSegmentRevisionsErrors = {
2494
+ /**
2495
+ * Bad Request
2496
+ */
2497
+ 400: Error400;
2498
+ /**
2499
+ * Unauthorized (API key or session)
2500
+ */
2501
+ 401: Error401;
2502
+ /**
2503
+ * Forbidden
2504
+ */
2505
+ 403: Error403;
2506
+ /**
2507
+ * Not Found
2508
+ */
2509
+ 404: Error404;
2510
+ /**
2511
+ * Too Many Requests
2512
+ */
2513
+ 429: Error429;
2514
+ /**
2515
+ * Internal Server Error
2516
+ */
2517
+ 500: Error500;
2518
+ };
2519
+ export type ListSegmentRevisionsError = ListSegmentRevisionsErrors[keyof ListSegmentRevisionsErrors];
2520
+ export type ListSegmentRevisionsResponses = {
2521
+ /**
2522
+ * List of segment revisions
2523
+ */
2524
+ 200: {
2525
+ revisions: Array<SegmentRevision>;
2526
+ };
2527
+ };
2528
+ export type ListSegmentRevisionsResponse = ListSegmentRevisionsResponses[keyof ListSegmentRevisionsResponses];
2362
2529
  export type ListSeriesData = {
2363
2530
  body?: never;
2364
2531
  path?: never;
@@ -2461,9 +2628,9 @@ export type DeleteSeriesData = {
2461
2628
  body?: never;
2462
2629
  path: {
2463
2630
  /**
2464
- * Series ID
2631
+ * Series public ID
2465
2632
  */
2466
- id: number;
2633
+ id: string;
2467
2634
  };
2468
2635
  query?: never;
2469
2636
  url: '/v1/media/series/{id}';
@@ -2506,9 +2673,9 @@ export type GetSeriesData = {
2506
2673
  body?: never;
2507
2674
  path: {
2508
2675
  /**
2509
- * Series ID
2676
+ * Series public ID
2510
2677
  */
2511
- id: number;
2678
+ id: string;
2512
2679
  };
2513
2680
  query?: {
2514
2681
  /**
@@ -2569,9 +2736,9 @@ export type UpdateSeriesData = {
2569
2736
  };
2570
2737
  path: {
2571
2738
  /**
2572
- * Series ID
2739
+ * Series public ID
2573
2740
  */
2574
- id: number;
2741
+ id: string;
2575
2742
  };
2576
2743
  query?: never;
2577
2744
  url: '/v1/media/series/{id}';
@@ -2613,9 +2780,9 @@ export type UpdateSeriesResponse = UpdateSeriesResponses[keyof UpdateSeriesRespo
2613
2780
  export type AddMediaToSeriesData = {
2614
2781
  body: {
2615
2782
  /**
2616
- * Media ID to add
2783
+ * Media public ID to add
2617
2784
  */
2618
- mediaId: number;
2785
+ mediaId: string;
2619
2786
  /**
2620
2787
  * Position in the series (1-indexed)
2621
2788
  */
@@ -2623,9 +2790,9 @@ export type AddMediaToSeriesData = {
2623
2790
  };
2624
2791
  path: {
2625
2792
  /**
2626
- * Series ID
2793
+ * Series public ID
2627
2794
  */
2628
- id: number;
2795
+ id: string;
2629
2796
  };
2630
2797
  query?: never;
2631
2798
  url: '/v1/media/series/{id}/media';
@@ -2668,13 +2835,13 @@ export type RemoveMediaFromSeriesData = {
2668
2835
  body?: never;
2669
2836
  path: {
2670
2837
  /**
2671
- * Series ID
2838
+ * Series public ID
2672
2839
  */
2673
- id: number;
2840
+ id: string;
2674
2841
  /**
2675
- * Media ID
2842
+ * Media public ID
2676
2843
  */
2677
- mediaId: number;
2844
+ mediaId: string;
2678
2845
  };
2679
2846
  query?: never;
2680
2847
  url: '/v1/media/series/{id}/media/{mediaId}';
@@ -2722,13 +2889,13 @@ export type UpdateSeriesMediaData = {
2722
2889
  };
2723
2890
  path: {
2724
2891
  /**
2725
- * Series ID
2892
+ * Series public ID
2726
2893
  */
2727
- id: number;
2894
+ id: string;
2728
2895
  /**
2729
- * Media ID
2896
+ * Media public ID
2730
2897
  */
2731
- mediaId: number;
2898
+ mediaId: string;
2732
2899
  };
2733
2900
  query?: never;
2734
2901
  url: '/v1/media/series/{id}/media/{mediaId}';
@@ -2771,7 +2938,7 @@ export type GetCharacterData = {
2771
2938
  body?: never;
2772
2939
  path: {
2773
2940
  /**
2774
- * Internal character ID
2941
+ * Character ID
2775
2942
  */
2776
2943
  id: number;
2777
2944
  };
@@ -2861,9 +3028,9 @@ export type DeleteMediaData = {
2861
3028
  body?: never;
2862
3029
  path: {
2863
3030
  /**
2864
- * Media ID
3031
+ * Media public ID
2865
3032
  */
2866
- id: number;
3033
+ id: string;
2867
3034
  };
2868
3035
  query?: never;
2869
3036
  url: '/v1/media/{id}';
@@ -2906,9 +3073,9 @@ export type GetMediaData = {
2906
3073
  body?: never;
2907
3074
  path: {
2908
3075
  /**
2909
- * Media ID
3076
+ * Media public ID
2910
3077
  */
2911
- id: number;
3078
+ id: string;
2912
3079
  };
2913
3080
  query?: {
2914
3081
  /**
@@ -2956,9 +3123,9 @@ export type UpdateMediaData = {
2956
3123
  body: MediaUpdateRequest;
2957
3124
  path: {
2958
3125
  /**
2959
- * Media ID
3126
+ * Media public ID
2960
3127
  */
2961
- id: number;
3128
+ id: string;
2962
3129
  };
2963
3130
  query?: never;
2964
3131
  url: '/v1/media/{id}';
@@ -3001,9 +3168,9 @@ export type ListEpisodesData = {
3001
3168
  body?: never;
3002
3169
  path: {
3003
3170
  /**
3004
- * ID of the media
3171
+ * Public ID of the media
3005
3172
  */
3006
- mediaId: number;
3173
+ mediaId: string;
3007
3174
  };
3008
3175
  query?: {
3009
3176
  /**
@@ -3055,9 +3222,9 @@ export type CreateEpisodeData = {
3055
3222
  body: EpisodeCreateRequest;
3056
3223
  path: {
3057
3224
  /**
3058
- * ID of the media
3225
+ * Public ID of the media
3059
3226
  */
3060
- mediaId: number;
3227
+ mediaId: string;
3061
3228
  };
3062
3229
  query?: never;
3063
3230
  url: '/v1/media/{mediaId}/episodes';
@@ -3104,9 +3271,9 @@ export type DeleteEpisodeData = {
3104
3271
  body?: never;
3105
3272
  path: {
3106
3273
  /**
3107
- * ID of the media
3274
+ * Public ID of the media
3108
3275
  */
3109
- mediaId: number;
3276
+ mediaId: string;
3110
3277
  /**
3111
3278
  * Episode number
3112
3279
  */
@@ -3153,9 +3320,9 @@ export type GetEpisodeData = {
3153
3320
  body?: never;
3154
3321
  path: {
3155
3322
  /**
3156
- * ID of the media
3323
+ * Public ID of the media
3157
3324
  */
3158
- mediaId: number;
3325
+ mediaId: string;
3159
3326
  /**
3160
3327
  * Episode number
3161
3328
  */
@@ -3202,9 +3369,9 @@ export type UpdateEpisodeData = {
3202
3369
  body: EpisodeUpdateRequest;
3203
3370
  path: {
3204
3371
  /**
3205
- * ID of the media
3372
+ * Public ID of the media
3206
3373
  */
3207
- mediaId: number;
3374
+ mediaId: string;
3208
3375
  /**
3209
3376
  * Episode number
3210
3377
  */
@@ -3251,9 +3418,9 @@ export type ListSegmentsData = {
3251
3418
  body?: never;
3252
3419
  path: {
3253
3420
  /**
3254
- * ID of the media
3421
+ * Public ID of the media
3255
3422
  */
3256
- mediaId: number;
3423
+ mediaId: string;
3257
3424
  /**
3258
3425
  * Episode number
3259
3426
  */
@@ -3315,9 +3482,9 @@ export type CreateSegmentData = {
3315
3482
  body: SegmentCreateRequest;
3316
3483
  path: {
3317
3484
  /**
3318
- * ID of the media
3485
+ * Public ID of the media
3319
3486
  */
3320
- mediaId: number;
3487
+ mediaId: string;
3321
3488
  /**
3322
3489
  * Episode number
3323
3490
  */
@@ -3364,13 +3531,71 @@ export type CreateSegmentResponses = {
3364
3531
  201: SegmentInternal;
3365
3532
  };
3366
3533
  export type CreateSegmentResponse = CreateSegmentResponses[keyof CreateSegmentResponses];
3534
+ export type CreateSegmentsBatchData = {
3535
+ body: SegmentBatchCreateRequest;
3536
+ path: {
3537
+ /**
3538
+ * Public ID of the media
3539
+ */
3540
+ mediaId: string;
3541
+ /**
3542
+ * Episode number
3543
+ */
3544
+ episodeNumber: number;
3545
+ };
3546
+ query?: never;
3547
+ url: '/v1/media/{mediaId}/episodes/{episodeNumber}/segments/batch';
3548
+ };
3549
+ export type CreateSegmentsBatchErrors = {
3550
+ /**
3551
+ * Bad Request
3552
+ */
3553
+ 400: Error400;
3554
+ /**
3555
+ * Unauthorized (API key)
3556
+ */
3557
+ 401: Error401;
3558
+ /**
3559
+ * Forbidden
3560
+ */
3561
+ 403: Error403;
3562
+ /**
3563
+ * Not Found
3564
+ */
3565
+ 404: Error404;
3566
+ /**
3567
+ * Too Many Requests
3568
+ */
3569
+ 429: Error429;
3570
+ /**
3571
+ * Internal Server Error
3572
+ */
3573
+ 500: Error500;
3574
+ };
3575
+ export type CreateSegmentsBatchError = CreateSegmentsBatchErrors[keyof CreateSegmentsBatchErrors];
3576
+ export type CreateSegmentsBatchResponses = {
3577
+ /**
3578
+ * Batch segment creation result
3579
+ */
3580
+ 201: {
3581
+ /**
3582
+ * Number of segments successfully created
3583
+ */
3584
+ created: number;
3585
+ /**
3586
+ * Number of segments skipped due to duplicate UUIDs
3587
+ */
3588
+ skipped: number;
3589
+ };
3590
+ };
3591
+ export type CreateSegmentsBatchResponse = CreateSegmentsBatchResponses[keyof CreateSegmentsBatchResponses];
3367
3592
  export type DeleteSegmentData = {
3368
3593
  body?: never;
3369
3594
  path: {
3370
3595
  /**
3371
- * ID of the media
3596
+ * Public ID of the media
3372
3597
  */
3373
- mediaId: number;
3598
+ mediaId: string;
3374
3599
  /**
3375
3600
  * Episode number
3376
3601
  */
@@ -3421,9 +3646,9 @@ export type GetSegmentData = {
3421
3646
  body?: never;
3422
3647
  path: {
3423
3648
  /**
3424
- * ID of the media
3649
+ * Public ID of the media
3425
3650
  */
3426
- mediaId: number;
3651
+ mediaId: string;
3427
3652
  /**
3428
3653
  * Episode number
3429
3654
  */
@@ -3474,9 +3699,9 @@ export type UpdateSegmentData = {
3474
3699
  body: SegmentUpdateRequest;
3475
3700
  path: {
3476
3701
  /**
3477
- * ID of the media
3702
+ * Public ID of the media
3478
3703
  */
3479
- mediaId: number;
3704
+ mediaId: string;
3480
3705
  /**
3481
3706
  * Episode number
3482
3707
  */
@@ -3713,7 +3938,7 @@ export type ListUserActivityResponse = ListUserActivityResponses[keyof ListUserA
3713
3938
  export type TrackUserActivityData = {
3714
3939
  body: {
3715
3940
  activityType: 'SEGMENT_PLAY' | 'SHARE';
3716
- segmentUuid?: string;
3941
+ segmentId?: number;
3717
3942
  mediaId?: number;
3718
3943
  mediaName?: string;
3719
3944
  japaneseText?: string;
@@ -4086,9 +4311,9 @@ export type DeleteCollectionData = {
4086
4311
  body?: never;
4087
4312
  path: {
4088
4313
  /**
4089
- * Collection ID
4314
+ * Collection public ID
4090
4315
  */
4091
- id: number;
4316
+ id: string;
4092
4317
  };
4093
4318
  query?: never;
4094
4319
  url: '/v1/collections/{id}';
@@ -4131,9 +4356,9 @@ export type GetCollectionData = {
4131
4356
  body?: never;
4132
4357
  path: {
4133
4358
  /**
4134
- * Collection ID
4359
+ * Collection public ID
4135
4360
  */
4136
- id: number;
4361
+ id: string;
4137
4362
  };
4138
4363
  query?: {
4139
4364
  /**
@@ -4188,9 +4413,9 @@ export type UpdateCollectionData = {
4188
4413
  };
4189
4414
  path: {
4190
4415
  /**
4191
- * Collection ID
4416
+ * Collection public ID
4192
4417
  */
4193
- id: number;
4418
+ id: string;
4194
4419
  };
4195
4420
  query?: never;
4196
4421
  url: '/v1/collections/{id}';
@@ -4232,9 +4457,9 @@ export type UpdateCollectionResponse = UpdateCollectionResponses[keyof UpdateCol
4232
4457
  export type AddSegmentToCollectionData = {
4233
4458
  body: {
4234
4459
  /**
4235
- * UUID of the segment to add
4460
+ * Public ID or UUID of the segment to add
4236
4461
  */
4237
- segmentUuid: string;
4462
+ segmentId: string;
4238
4463
  /**
4239
4464
  * Optional annotation
4240
4465
  */
@@ -4242,9 +4467,9 @@ export type AddSegmentToCollectionData = {
4242
4467
  };
4243
4468
  path: {
4244
4469
  /**
4245
- * Collection ID
4470
+ * Collection public ID
4246
4471
  */
4247
- id: number;
4472
+ id: string;
4248
4473
  };
4249
4474
  query?: never;
4250
4475
  url: '/v1/collections/{id}/segments';
@@ -4287,16 +4512,16 @@ export type RemoveSegmentFromCollectionData = {
4287
4512
  body?: never;
4288
4513
  path: {
4289
4514
  /**
4290
- * Collection ID
4515
+ * Collection public ID
4291
4516
  */
4292
- id: number;
4517
+ id: string;
4293
4518
  /**
4294
- * Segment UUID
4519
+ * Segment ID
4295
4520
  */
4296
- uuid: string;
4521
+ segmentId: number;
4297
4522
  };
4298
4523
  query?: never;
4299
- url: '/v1/collections/{id}/segments/{uuid}';
4524
+ url: '/v1/collections/{id}/segments/{segmentId}';
4300
4525
  };
4301
4526
  export type RemoveSegmentFromCollectionErrors = {
4302
4527
  /**
@@ -4345,16 +4570,16 @@ export type UpdateCollectionSegmentData = {
4345
4570
  };
4346
4571
  path: {
4347
4572
  /**
4348
- * Collection ID
4573
+ * Collection public ID
4349
4574
  */
4350
- id: number;
4575
+ id: string;
4351
4576
  /**
4352
- * Segment UUID
4577
+ * Segment ID
4353
4578
  */
4354
- uuid: string;
4579
+ segmentId: number;
4355
4580
  };
4356
4581
  query?: never;
4357
- url: '/v1/collections/{id}/segments/{uuid}';
4582
+ url: '/v1/collections/{id}/segments/{segmentId}';
4358
4583
  };
4359
4584
  export type UpdateCollectionSegmentErrors = {
4360
4585
  /**
@@ -4394,9 +4619,9 @@ export type SearchCollectionSegmentsData = {
4394
4619
  body?: never;
4395
4620
  path: {
4396
4621
  /**
4397
- * Collection ID
4622
+ * Collection public ID
4398
4623
  */
4399
- id: number;
4624
+ id: string;
4400
4625
  };
4401
4626
  query?: {
4402
4627
  /**
@@ -4448,9 +4673,9 @@ export type GetCollectionStatsData = {
4448
4673
  body?: never;
4449
4674
  path: {
4450
4675
  /**
4451
- * Collection ID
4676
+ * Collection public ID
4452
4677
  */
4453
- id: number;
4678
+ id: string;
4454
4679
  };
4455
4680
  query?: never;
4456
4681
  url: '/v1/collections/{id}/stats';
@@ -5071,9 +5296,9 @@ export type ListAdminReportsData = {
5071
5296
  */
5072
5297
  'target.episodeNumber'?: number;
5073
5298
  /**
5074
- * Filter by target segment UUID
5299
+ * Filter by target segment ID
5075
5300
  */
5076
- 'target.segmentUuid'?: string;
5301
+ 'target.segmentId'?: number;
5077
5302
  /**
5078
5303
  * Filter by audit run ID
5079
5304
  */
@@ -5378,4 +5603,80 @@ export type GetAdminMediaAuditRunResponses = {
5378
5603
  };
5379
5604
  };
5380
5605
  export type GetAdminMediaAuditRunResponse = GetAdminMediaAuditRunResponses[keyof GetAdminMediaAuditRunResponses];
5606
+ export type GetAnnouncementData = {
5607
+ body?: never;
5608
+ path?: never;
5609
+ query?: never;
5610
+ url: '/v1/admin/announcement';
5611
+ };
5612
+ export type GetAnnouncementErrors = {
5613
+ /**
5614
+ * Too Many Requests
5615
+ */
5616
+ 429: Error429;
5617
+ /**
5618
+ * Internal Server Error
5619
+ */
5620
+ 500: Error500;
5621
+ };
5622
+ export type GetAnnouncementError = GetAnnouncementErrors[keyof GetAnnouncementErrors];
5623
+ export type GetAnnouncementResponses = {
5624
+ /**
5625
+ * OK
5626
+ */
5627
+ 200: {
5628
+ message: string;
5629
+ type: 'info' | 'warning' | 'maintenance';
5630
+ active: boolean;
5631
+ };
5632
+ /**
5633
+ * No announcement set
5634
+ */
5635
+ 204: void;
5636
+ };
5637
+ export type GetAnnouncementResponse = GetAnnouncementResponses[keyof GetAnnouncementResponses];
5638
+ export type UpdateAnnouncementData = {
5639
+ body: {
5640
+ message: string;
5641
+ type: 'info' | 'warning' | 'maintenance';
5642
+ active: boolean;
5643
+ };
5644
+ path?: never;
5645
+ query?: never;
5646
+ url: '/v1/admin/announcement';
5647
+ };
5648
+ export type UpdateAnnouncementErrors = {
5649
+ /**
5650
+ * Bad Request
5651
+ */
5652
+ 400: Error400;
5653
+ /**
5654
+ * Unauthorized (session)
5655
+ */
5656
+ 401: Error401;
5657
+ /**
5658
+ * Forbidden
5659
+ */
5660
+ 403: Error403;
5661
+ /**
5662
+ * Too Many Requests
5663
+ */
5664
+ 429: Error429;
5665
+ /**
5666
+ * Internal Server Error
5667
+ */
5668
+ 500: Error500;
5669
+ };
5670
+ export type UpdateAnnouncementError = UpdateAnnouncementErrors[keyof UpdateAnnouncementErrors];
5671
+ export type UpdateAnnouncementResponses = {
5672
+ /**
5673
+ * Announcement updated
5674
+ */
5675
+ 200: {
5676
+ message: string;
5677
+ type: 'info' | 'warning' | 'maintenance';
5678
+ active: boolean;
5679
+ };
5680
+ };
5681
+ export type UpdateAnnouncementResponse = UpdateAnnouncementResponses[keyof UpdateAnnouncementResponses];
5381
5682
  //# sourceMappingURL=types.gen.d.ts.map