@runapi.ai/kling 0.4.0 → 0.6.0

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/dist/index.mjs CHANGED
@@ -2,1577 +2,9 @@
2
2
  import { BaseClient } from "@runapi.ai/core";
3
3
 
4
4
  // src/resources/text-to-video.ts
5
- import { ValidationError as ValidationError2, compactParams, validateParams } from "@runapi.ai/core";
5
+ import { compactParams } from "@runapi.ai/core";
6
6
  import { pollUntilComplete } from "@runapi.ai/core/internal";
7
-
8
- // src/contract_gen.ts
9
- var contract = {
10
- "avatar": {
11
- "models": [
12
- "kling-ai-avatar-pro",
13
- "kling-ai-avatar-standard",
14
- "kling-ai-avatar-v1-pro",
15
- "kling-v1-avatar-standard"
16
- ],
17
- "fields_by_model": {
18
- "kling-ai-avatar-pro": {
19
- "model": {
20
- "required": true
21
- },
22
- "prompt": {
23
- "required": true
24
- },
25
- "source_audio_url": {
26
- "required": true
27
- },
28
- "source_image_url": {
29
- "required": true
30
- }
31
- },
32
- "kling-ai-avatar-standard": {
33
- "model": {
34
- "required": true
35
- },
36
- "prompt": {
37
- "required": true
38
- },
39
- "source_audio_url": {
40
- "required": true
41
- },
42
- "source_image_url": {
43
- "required": true
44
- }
45
- },
46
- "kling-ai-avatar-v1-pro": {
47
- "model": {
48
- "required": true
49
- },
50
- "prompt": {
51
- "required": true
52
- },
53
- "source_audio_url": {
54
- "required": true
55
- },
56
- "source_image_url": {
57
- "required": true
58
- }
59
- },
60
- "kling-v1-avatar-standard": {
61
- "model": {
62
- "required": true
63
- },
64
- "prompt": {
65
- "required": true
66
- },
67
- "source_audio_url": {
68
- "required": true
69
- },
70
- "source_image_url": {
71
- "required": true
72
- }
73
- }
74
- }
75
- },
76
- "edit-video": {
77
- "models": [
78
- "kling-v3-omni-edit",
79
- "kling-v3-omni-reference"
80
- ],
81
- "fields_by_model": {
82
- "kling-v3-omni-edit": {
83
- "aspect_ratio": {
84
- "enum": [
85
- "auto",
86
- "16:9",
87
- "9:16",
88
- "1:1"
89
- ]
90
- },
91
- "duration_seconds": {
92
- "enum": [
93
- 3,
94
- 4,
95
- 5,
96
- 6,
97
- 7,
98
- 8,
99
- 9,
100
- 10,
101
- 11,
102
- 12,
103
- 13,
104
- 14,
105
- 15
106
- ],
107
- "type": "integer"
108
- },
109
- "model": {
110
- "required": true
111
- },
112
- "output_resolution": {
113
- "enum": [
114
- "720p",
115
- "1080p",
116
- "4k"
117
- ]
118
- },
119
- "prompt": {
120
- "required": true,
121
- "min": 1,
122
- "max": 2500,
123
- "length": true
124
- },
125
- "reference_image_urls": {
126
- "min_items": 1,
127
- "max_items": 4
128
- }
129
- },
130
- "kling-v3-omni-reference": {
131
- "aspect_ratio": {
132
- "enum": [
133
- "auto",
134
- "16:9",
135
- "9:16",
136
- "1:1"
137
- ]
138
- },
139
- "duration_seconds": {
140
- "enum": [
141
- 3,
142
- 4,
143
- 5,
144
- 6,
145
- 7,
146
- 8,
147
- 9,
148
- 10,
149
- 11,
150
- 12,
151
- 13,
152
- 14,
153
- 15
154
- ],
155
- "type": "integer"
156
- },
157
- "model": {
158
- "required": true
159
- },
160
- "output_resolution": {
161
- "enum": [
162
- "720p",
163
- "1080p",
164
- "4k"
165
- ]
166
- },
167
- "prompt": {
168
- "required": true,
169
- "min": 1,
170
- "max": 2500,
171
- "length": true
172
- },
173
- "reference_image_urls": {
174
- "min_items": 1,
175
- "max_items": 4
176
- }
177
- }
178
- },
179
- "rules": [
180
- {
181
- "when": {
182
- "model": "kling-v3-omni-edit",
183
- "source_video_url": {
184
- "present": true
185
- }
186
- },
187
- "forbidden": [
188
- "source_task_id"
189
- ]
190
- },
191
- {
192
- "when": {
193
- "model": "kling-v3-omni-edit",
194
- "source_task_id": {
195
- "present": true
196
- }
197
- },
198
- "forbidden": [
199
- "source_video_url"
200
- ]
201
- },
202
- {
203
- "enum": {
204
- "aspect_ratio": [
205
- "auto"
206
- ],
207
- "duration_seconds": [
208
- 5
209
- ]
210
- },
211
- "when": {
212
- "model": "kling-v3-omni-edit",
213
- "source_video_url": {
214
- "present": true
215
- },
216
- "reference_image_urls": {
217
- "present": false
218
- }
219
- },
220
- "required": [
221
- "aspect_ratio"
222
- ]
223
- },
224
- {
225
- "enum": {
226
- "aspect_ratio": [
227
- "auto"
228
- ],
229
- "duration_seconds": [
230
- 5
231
- ]
232
- },
233
- "when": {
234
- "model": "kling-v3-omni-edit",
235
- "source_task_id": {
236
- "present": true
237
- },
238
- "reference_image_urls": {
239
- "present": false
240
- }
241
- },
242
- "required": [
243
- "aspect_ratio"
244
- ]
245
- },
246
- {
247
- "enum": {
248
- "aspect_ratio": [
249
- "16:9",
250
- "9:16",
251
- "1:1"
252
- ]
253
- },
254
- "when": {
255
- "model": "kling-v3-omni-edit",
256
- "source_video_url": {
257
- "present": true
258
- },
259
- "reference_image_urls": {
260
- "present": true
261
- }
262
- },
263
- "required": [
264
- "aspect_ratio"
265
- ]
266
- },
267
- {
268
- "enum": {
269
- "aspect_ratio": [
270
- "16:9",
271
- "9:16",
272
- "1:1"
273
- ]
274
- },
275
- "when": {
276
- "model": "kling-v3-omni-edit",
277
- "source_task_id": {
278
- "present": true
279
- },
280
- "reference_image_urls": {
281
- "present": true
282
- }
283
- },
284
- "required": [
285
- "aspect_ratio"
286
- ]
287
- },
288
- {
289
- "when": {
290
- "model": "kling-v3-omni-edit",
291
- "source_task_id": {
292
- "present": false
293
- },
294
- "source_video_url": {
295
- "present": false
296
- }
297
- },
298
- "required_any": [
299
- "source_video_url",
300
- "source_task_id"
301
- ]
302
- },
303
- {
304
- "enum": {
305
- "aspect_ratio": [
306
- "16:9",
307
- "9:16",
308
- "1:1"
309
- ],
310
- "enable_sound": [
311
- false
312
- ]
313
- },
314
- "when": {
315
- "model": "kling-v3-omni-reference",
316
- "source_task_id": {
317
- "present": true
318
- },
319
- "reference_image_urls": {
320
- "present": true
321
- }
322
- },
323
- "required": [
324
- "aspect_ratio"
325
- ]
326
- },
327
- {
328
- "when": {
329
- "model": "kling-v3-omni-reference",
330
- "source_task_id": {
331
- "present": false
332
- },
333
- "source_video_url": {
334
- "present": false
335
- }
336
- },
337
- "required_any": [
338
- "source_video_url",
339
- "source_task_id"
340
- ]
341
- },
342
- {
343
- "when": {
344
- "model": "kling-v3-omni-reference",
345
- "source_video_url": {
346
- "present": true
347
- }
348
- },
349
- "forbidden": [
350
- "source_task_id"
351
- ]
352
- },
353
- {
354
- "when": {
355
- "model": "kling-v3-omni-reference",
356
- "source_task_id": {
357
- "present": true
358
- }
359
- },
360
- "forbidden": [
361
- "source_video_url"
362
- ]
363
- },
364
- {
365
- "enum": {
366
- "aspect_ratio": [
367
- "auto"
368
- ],
369
- "enable_sound": [
370
- false
371
- ],
372
- "duration_seconds": [
373
- 5
374
- ]
375
- },
376
- "when": {
377
- "model": "kling-v3-omni-reference",
378
- "source_video_url": {
379
- "present": true
380
- },
381
- "reference_image_urls": {
382
- "present": false
383
- }
384
- },
385
- "required": [
386
- "aspect_ratio"
387
- ]
388
- },
389
- {
390
- "enum": {
391
- "aspect_ratio": [
392
- "auto"
393
- ],
394
- "enable_sound": [
395
- false
396
- ],
397
- "duration_seconds": [
398
- 5
399
- ]
400
- },
401
- "when": {
402
- "model": "kling-v3-omni-reference",
403
- "source_task_id": {
404
- "present": true
405
- },
406
- "reference_image_urls": {
407
- "present": false
408
- }
409
- },
410
- "required": [
411
- "aspect_ratio"
412
- ]
413
- },
414
- {
415
- "enum": {
416
- "aspect_ratio": [
417
- "16:9",
418
- "9:16",
419
- "1:1"
420
- ],
421
- "enable_sound": [
422
- false
423
- ]
424
- },
425
- "when": {
426
- "model": "kling-v3-omni-reference",
427
- "source_video_url": {
428
- "present": true
429
- },
430
- "reference_image_urls": {
431
- "present": true
432
- }
433
- },
434
- "required": [
435
- "aspect_ratio"
436
- ]
437
- }
438
- ]
439
- },
440
- "extend-video": {
441
- "models": [
442
- "kling-v2.5-turbo-image-to-video-pro",
443
- "kling-v2.5-turbo-text-to-video-pro"
444
- ],
445
- "fields_by_model": {
446
- "kling-v2.5-turbo-image-to-video-pro": {
447
- "mode": {
448
- "enum": [
449
- "std",
450
- "pro"
451
- ]
452
- },
453
- "source_task_id": {
454
- "required": true
455
- }
456
- },
457
- "kling-v2.5-turbo-text-to-video-pro": {
458
- "mode": {
459
- "enum": [
460
- "std",
461
- "pro"
462
- ]
463
- },
464
- "source_task_id": {
465
- "required": true
466
- }
467
- }
468
- }
469
- },
470
- "image-to-video": {
471
- "models": [
472
- "kling-o1",
473
- "kling-v2.1-master-image-to-video",
474
- "kling-v2.1-pro",
475
- "kling-v2.1-standard",
476
- "kling-v2.5-turbo-image-to-video-pro",
477
- "kling-v2.6",
478
- "kling-v3-omni",
479
- "kling-v3-turbo-image-to-video"
480
- ],
481
- "fields_by_model": {
482
- "kling-o1": {
483
- "aspect_ratio": {
484
- "enum": [
485
- "16:9",
486
- "9:16",
487
- "1:1"
488
- ]
489
- },
490
- "duration_seconds": {
491
- "enum": [
492
- 5
493
- ],
494
- "type": "integer"
495
- },
496
- "first_frame_image_url": {
497
- "required": true
498
- },
499
- "mode": {
500
- "enum": [
501
- "std",
502
- "pro"
503
- ]
504
- },
505
- "model": {
506
- "required": true
507
- },
508
- "prompt": {
509
- "required": true,
510
- "min": 1,
511
- "max": 2500,
512
- "length": true
513
- },
514
- "reference_image_urls": {
515
- "min_items": 1,
516
- "max_items": 7
517
- },
518
- "reference_video_type": {
519
- "enum": [
520
- "base",
521
- "feature"
522
- ]
523
- }
524
- },
525
- "kling-v2.1-master-image-to-video": {
526
- "duration_seconds": {
527
- "enum": [
528
- 5,
529
- 10
530
- ],
531
- "type": "integer"
532
- },
533
- "first_frame_image_url": {
534
- "required": true
535
- },
536
- "model": {
537
- "required": true
538
- },
539
- "prompt": {
540
- "required": true
541
- }
542
- },
543
- "kling-v2.1-pro": {
544
- "duration_seconds": {
545
- "enum": [
546
- 5,
547
- 10
548
- ],
549
- "type": "integer"
550
- },
551
- "first_frame_image_url": {
552
- "required": true
553
- },
554
- "model": {
555
- "required": true
556
- },
557
- "prompt": {
558
- "required": true
559
- }
560
- },
561
- "kling-v2.1-standard": {
562
- "duration_seconds": {
563
- "enum": [
564
- 5,
565
- 10
566
- ],
567
- "type": "integer"
568
- },
569
- "first_frame_image_url": {
570
- "required": true
571
- },
572
- "model": {
573
- "required": true
574
- },
575
- "prompt": {
576
- "required": true
577
- }
578
- },
579
- "kling-v2.5-turbo-image-to-video-pro": {
580
- "duration_seconds": {
581
- "enum": [
582
- 5,
583
- 10
584
- ],
585
- "type": "integer"
586
- },
587
- "first_frame_image_url": {
588
- "required": true
589
- },
590
- "model": {
591
- "required": true
592
- },
593
- "prompt": {
594
- "required": true
595
- }
596
- },
597
- "kling-v2.6": {
598
- "aspect_ratio": {
599
- "enum": [
600
- "16:9",
601
- "9:16",
602
- "1:1"
603
- ]
604
- },
605
- "duration_seconds": {
606
- "enum": [
607
- 5,
608
- 10
609
- ],
610
- "type": "integer"
611
- },
612
- "first_frame_image_url": {
613
- "required": true
614
- },
615
- "mode": {
616
- "enum": [
617
- "std",
618
- "pro"
619
- ]
620
- },
621
- "model": {
622
- "required": true
623
- },
624
- "prompt": {
625
- "required": true,
626
- "min": 1,
627
- "max": 2500,
628
- "length": true
629
- }
630
- },
631
- "kling-v3-omni": {
632
- "aspect_ratio": {
633
- "enum": [
634
- "16:9",
635
- "9:16",
636
- "1:1"
637
- ]
638
- },
639
- "duration_seconds": {
640
- "enum": [
641
- 3,
642
- 4,
643
- 5,
644
- 6,
645
- 7,
646
- 8,
647
- 9,
648
- 10,
649
- 11,
650
- 12,
651
- 13,
652
- 14,
653
- 15
654
- ],
655
- "type": "integer"
656
- },
657
- "first_frame_image_url": {
658
- "required": true
659
- },
660
- "model": {
661
- "required": true
662
- },
663
- "output_resolution": {
664
- "enum": [
665
- "720p",
666
- "1080p",
667
- "4k"
668
- ]
669
- },
670
- "prompt": {
671
- "required": true,
672
- "min": 1,
673
- "max": 2500,
674
- "length": true
675
- }
676
- },
677
- "kling-v3-turbo-image-to-video": {
678
- "duration_seconds": {
679
- "enum": [
680
- 3,
681
- 4,
682
- 5,
683
- 6,
684
- 7,
685
- 8,
686
- 9,
687
- 10,
688
- 11,
689
- 12,
690
- 13,
691
- 14,
692
- 15
693
- ],
694
- "type": "integer"
695
- },
696
- "first_frame_image_url": {
697
- "required": true
698
- },
699
- "model": {
700
- "required": true
701
- },
702
- "output_resolution": {
703
- "enum": [
704
- "720p",
705
- "1080p"
706
- ]
707
- },
708
- "prompt": {
709
- "required": true,
710
- "min": 1,
711
- "max": 2500,
712
- "length": true
713
- }
714
- }
715
- },
716
- "rules": [
717
- {
718
- "when": {
719
- "model": "kling-o1"
720
- },
721
- "forbidden": [
722
- "output_resolution",
723
- "negative_prompt",
724
- "cfg_scale"
725
- ]
726
- },
727
- {
728
- "when": {
729
- "model": "kling-v2.1-master-image-to-video"
730
- },
731
- "forbidden": [
732
- "output_resolution",
733
- "enable_sound",
734
- "reference_image_urls",
735
- "reference_video_url",
736
- "reference_video_type",
737
- "preserve_reference_video_audio"
738
- ]
739
- },
740
- {
741
- "when": {
742
- "model": "kling-v2.1-pro"
743
- },
744
- "forbidden": [
745
- "output_resolution",
746
- "enable_sound",
747
- "reference_image_urls",
748
- "reference_video_url",
749
- "reference_video_type",
750
- "preserve_reference_video_audio"
751
- ]
752
- },
753
- {
754
- "when": {
755
- "model": "kling-v2.1-standard"
756
- },
757
- "forbidden": [
758
- "output_resolution",
759
- "enable_sound",
760
- "reference_image_urls",
761
- "reference_video_url",
762
- "reference_video_type",
763
- "preserve_reference_video_audio"
764
- ]
765
- },
766
- {
767
- "when": {
768
- "model": "kling-v2.5-turbo-image-to-video-pro"
769
- },
770
- "forbidden": [
771
- "output_resolution",
772
- "enable_sound",
773
- "reference_image_urls",
774
- "reference_video_url",
775
- "reference_video_type",
776
- "preserve_reference_video_audio"
777
- ]
778
- },
779
- {
780
- "enum": {
781
- "enable_sound": [
782
- false
783
- ]
784
- },
785
- "when": {
786
- "mode": "std",
787
- "model": "kling-v2.6"
788
- }
789
- },
790
- {
791
- "when": {
792
- "model": "kling-v2.6"
793
- },
794
- "forbidden": [
795
- "output_resolution",
796
- "negative_prompt",
797
- "cfg_scale",
798
- "reference_image_urls",
799
- "reference_video_url",
800
- "reference_video_type",
801
- "preserve_reference_video_audio"
802
- ]
803
- },
804
- {
805
- "enum": {
806
- "enable_sound": [
807
- false
808
- ]
809
- },
810
- "when": {
811
- "mode": {
812
- "present": false
813
- },
814
- "model": "kling-v2.6"
815
- }
816
- },
817
- {
818
- "when": {
819
- "model": "kling-v3-omni"
820
- },
821
- "forbidden": [
822
- "negative_prompt",
823
- "cfg_scale",
824
- "reference_image_urls",
825
- "reference_video_url",
826
- "reference_video_type",
827
- "preserve_reference_video_audio"
828
- ]
829
- },
830
- {
831
- "when": {
832
- "model": "kling-v3-turbo-image-to-video"
833
- },
834
- "forbidden": [
835
- "enable_sound",
836
- "aspect_ratio",
837
- "negative_prompt",
838
- "cfg_scale",
839
- "last_frame_image_url",
840
- "reference_image_urls",
841
- "reference_video_url",
842
- "reference_video_type",
843
- "preserve_reference_video_audio"
844
- ]
845
- }
846
- ]
847
- },
848
- "motion-control": {
849
- "models": [
850
- "kling-3.0",
851
- "kling-v2.6"
852
- ],
853
- "fields_by_model": {
854
- "kling-3.0": {
855
- "background_source": {
856
- "enum": [
857
- "video",
858
- "image"
859
- ]
860
- },
861
- "character_orientation": {
862
- "enum": [
863
- "video",
864
- "image"
865
- ]
866
- },
867
- "model": {
868
- "required": true
869
- },
870
- "output_resolution": {
871
- "enum": [
872
- "720p",
873
- "1080p"
874
- ],
875
- "required": true
876
- },
877
- "reference_video_url": {
878
- "required": true
879
- },
880
- "source_image_url": {
881
- "required": true
882
- }
883
- },
884
- "kling-v2.6": {
885
- "character_orientation": {
886
- "enum": [
887
- "video",
888
- "image"
889
- ],
890
- "required": true
891
- },
892
- "model": {
893
- "required": true
894
- },
895
- "output_resolution": {
896
- "enum": [
897
- "720p",
898
- "1080p"
899
- ],
900
- "required": true
901
- },
902
- "prompt": {
903
- "max": 2500,
904
- "length": true
905
- },
906
- "reference_video_url": {
907
- "required": true
908
- },
909
- "source_image_url": {
910
- "required": true
911
- }
912
- }
913
- },
914
- "rules": [
915
- {
916
- "when": {
917
- "model": "kling-v2.6"
918
- },
919
- "forbidden": [
920
- "background_source"
921
- ]
922
- }
923
- ]
924
- },
925
- "text-to-video": {
926
- "models": [
927
- "kling-3.0",
928
- "kling-o1",
929
- "kling-v2.1-master-text-to-video",
930
- "kling-v2.5-turbo-text-to-video-pro",
931
- "kling-v2.6",
932
- "kling-v3-omni",
933
- "kling-v3-omni-reference",
934
- "kling-v3-turbo-text-to-video"
935
- ],
936
- "fields_by_model": {
937
- "kling-3.0": {
938
- "aspect_ratio": {
939
- "enum": [
940
- "16:9",
941
- "9:16",
942
- "1:1"
943
- ]
944
- },
945
- "duration_seconds": {
946
- "enum": [
947
- 3,
948
- 4,
949
- 5,
950
- 6,
951
- 7,
952
- 8,
953
- 9,
954
- 10,
955
- 11,
956
- 12,
957
- 13,
958
- 14,
959
- 15
960
- ],
961
- "type": "integer"
962
- },
963
- "model": {
964
- "required": true
965
- },
966
- "output_resolution": {
967
- "enum": [
968
- "720p",
969
- "1080p",
970
- "4k"
971
- ]
972
- }
973
- },
974
- "kling-o1": {
975
- "aspect_ratio": {
976
- "enum": [
977
- "16:9",
978
- "9:16",
979
- "1:1"
980
- ]
981
- },
982
- "duration_seconds": {
983
- "enum": [
984
- 5
985
- ],
986
- "type": "integer"
987
- },
988
- "mode": {
989
- "enum": [
990
- "std",
991
- "pro"
992
- ]
993
- },
994
- "model": {
995
- "required": true
996
- },
997
- "prompt": {
998
- "required": true,
999
- "min": 1,
1000
- "max": 2500,
1001
- "length": true
1002
- },
1003
- "reference_image_urls": {
1004
- "min_items": 1,
1005
- "max_items": 7
1006
- },
1007
- "reference_video_type": {
1008
- "enum": [
1009
- "base",
1010
- "feature"
1011
- ]
1012
- }
1013
- },
1014
- "kling-v2.1-master-text-to-video": {
1015
- "aspect_ratio": {
1016
- "enum": [
1017
- "16:9",
1018
- "9:16",
1019
- "1:1"
1020
- ]
1021
- },
1022
- "duration_seconds": {
1023
- "enum": [
1024
- 5,
1025
- 10
1026
- ],
1027
- "type": "integer"
1028
- },
1029
- "model": {
1030
- "required": true
1031
- }
1032
- },
1033
- "kling-v2.5-turbo-text-to-video-pro": {
1034
- "aspect_ratio": {
1035
- "enum": [
1036
- "16:9",
1037
- "9:16",
1038
- "1:1"
1039
- ]
1040
- },
1041
- "duration_seconds": {
1042
- "enum": [
1043
- 5,
1044
- 10
1045
- ],
1046
- "type": "integer"
1047
- },
1048
- "model": {
1049
- "required": true
1050
- }
1051
- },
1052
- "kling-v2.6": {
1053
- "aspect_ratio": {
1054
- "enum": [
1055
- "16:9",
1056
- "9:16",
1057
- "1:1"
1058
- ]
1059
- },
1060
- "duration_seconds": {
1061
- "enum": [
1062
- 5,
1063
- 10
1064
- ],
1065
- "type": "integer"
1066
- },
1067
- "mode": {
1068
- "enum": [
1069
- "std",
1070
- "pro"
1071
- ]
1072
- },
1073
- "model": {
1074
- "required": true
1075
- },
1076
- "prompt": {
1077
- "required": true,
1078
- "min": 1,
1079
- "max": 2500,
1080
- "length": true
1081
- }
1082
- },
1083
- "kling-v3-omni": {
1084
- "aspect_ratio": {
1085
- "enum": [
1086
- "16:9",
1087
- "9:16",
1088
- "1:1"
1089
- ]
1090
- },
1091
- "duration_seconds": {
1092
- "enum": [
1093
- 3,
1094
- 4,
1095
- 5,
1096
- 6,
1097
- 7,
1098
- 8,
1099
- 9,
1100
- 10,
1101
- 11,
1102
- 12,
1103
- 13,
1104
- 14,
1105
- 15
1106
- ],
1107
- "type": "integer"
1108
- },
1109
- "model": {
1110
- "required": true
1111
- },
1112
- "output_resolution": {
1113
- "enum": [
1114
- "720p",
1115
- "1080p",
1116
- "4k"
1117
- ]
1118
- },
1119
- "prompt": {
1120
- "required": true,
1121
- "min": 1,
1122
- "max": 2500,
1123
- "length": true
1124
- }
1125
- },
1126
- "kling-v3-omni-reference": {
1127
- "aspect_ratio": {
1128
- "enum": [
1129
- "16:9",
1130
- "9:16",
1131
- "1:1"
1132
- ],
1133
- "required": true
1134
- },
1135
- "duration_seconds": {
1136
- "enum": [
1137
- 3,
1138
- 4,
1139
- 5,
1140
- 6,
1141
- 7,
1142
- 8,
1143
- 9,
1144
- 10,
1145
- 11,
1146
- 12,
1147
- 13,
1148
- 14,
1149
- 15
1150
- ],
1151
- "type": "integer"
1152
- },
1153
- "model": {
1154
- "required": true
1155
- },
1156
- "output_resolution": {
1157
- "enum": [
1158
- "720p",
1159
- "1080p",
1160
- "4k"
1161
- ]
1162
- },
1163
- "prompt": {
1164
- "required": true,
1165
- "min": 1,
1166
- "max": 2500,
1167
- "length": true
1168
- },
1169
- "reference_image_urls": {
1170
- "required": true,
1171
- "min_items": 1,
1172
- "max_items": 7
1173
- }
1174
- },
1175
- "kling-v3-turbo-text-to-video": {
1176
- "aspect_ratio": {
1177
- "enum": [
1178
- "16:9",
1179
- "9:16",
1180
- "1:1"
1181
- ]
1182
- },
1183
- "duration_seconds": {
1184
- "enum": [
1185
- 3,
1186
- 4,
1187
- 5,
1188
- 6,
1189
- 7,
1190
- 8,
1191
- 9,
1192
- 10,
1193
- 11,
1194
- 12,
1195
- 13,
1196
- 14,
1197
- 15
1198
- ],
1199
- "type": "integer"
1200
- },
1201
- "model": {
1202
- "required": true
1203
- },
1204
- "output_resolution": {
1205
- "enum": [
1206
- "720p",
1207
- "1080p"
1208
- ]
1209
- },
1210
- "prompt": {
1211
- "required": true,
1212
- "min": 1,
1213
- "max": 2500,
1214
- "length": true
1215
- }
1216
- }
1217
- },
1218
- "rules": [
1219
- {
1220
- "when": {
1221
- "model": "kling-3.0"
1222
- },
1223
- "forbidden": [
1224
- "reference_image_urls",
1225
- "reference_video_url",
1226
- "reference_video_type",
1227
- "preserve_reference_video_audio"
1228
- ]
1229
- },
1230
- {
1231
- "when": {
1232
- "model": "kling-o1"
1233
- },
1234
- "forbidden": [
1235
- "output_resolution",
1236
- "negative_prompt",
1237
- "cfg_scale",
1238
- "multi_shots",
1239
- "multi_prompt",
1240
- "first_frame_image_url",
1241
- "last_frame_image_url",
1242
- "kling_elements"
1243
- ]
1244
- },
1245
- {
1246
- "when": {
1247
- "model": "kling-v2.1-master-text-to-video"
1248
- },
1249
- "forbidden": [
1250
- "mode",
1251
- "reference_image_urls",
1252
- "reference_video_url",
1253
- "reference_video_type",
1254
- "preserve_reference_video_audio"
1255
- ]
1256
- },
1257
- {
1258
- "when": {
1259
- "model": "kling-v2.5-turbo-text-to-video-pro"
1260
- },
1261
- "forbidden": [
1262
- "mode",
1263
- "reference_image_urls",
1264
- "reference_video_url",
1265
- "reference_video_type",
1266
- "preserve_reference_video_audio"
1267
- ]
1268
- },
1269
- {
1270
- "when": {
1271
- "model": "kling-v2.6"
1272
- },
1273
- "forbidden": [
1274
- "output_resolution",
1275
- "negative_prompt",
1276
- "cfg_scale",
1277
- "multi_shots",
1278
- "multi_prompt",
1279
- "first_frame_image_url",
1280
- "last_frame_image_url",
1281
- "kling_elements",
1282
- "reference_image_urls",
1283
- "reference_video_url",
1284
- "reference_video_type",
1285
- "preserve_reference_video_audio"
1286
- ]
1287
- },
1288
- {
1289
- "enum": {
1290
- "enable_sound": [
1291
- false
1292
- ]
1293
- },
1294
- "when": {
1295
- "mode": "std",
1296
- "model": "kling-v2.6"
1297
- }
1298
- },
1299
- {
1300
- "enum": {
1301
- "enable_sound": [
1302
- false
1303
- ]
1304
- },
1305
- "when": {
1306
- "mode": {
1307
- "present": false
1308
- },
1309
- "model": "kling-v2.6"
1310
- }
1311
- },
1312
- {
1313
- "when": {
1314
- "model": "kling-v3-omni"
1315
- },
1316
- "forbidden": [
1317
- "negative_prompt",
1318
- "cfg_scale",
1319
- "multi_shots",
1320
- "multi_prompt",
1321
- "first_frame_image_url",
1322
- "last_frame_image_url",
1323
- "kling_elements",
1324
- "reference_image_urls",
1325
- "reference_video_url",
1326
- "reference_video_type",
1327
- "preserve_reference_video_audio"
1328
- ]
1329
- },
1330
- {
1331
- "when": {
1332
- "model": "kling-v3-turbo-text-to-video"
1333
- },
1334
- "forbidden": [
1335
- "enable_sound",
1336
- "negative_prompt",
1337
- "cfg_scale",
1338
- "multi_shots",
1339
- "multi_prompt",
1340
- "first_frame_image_url",
1341
- "last_frame_image_url",
1342
- "kling_elements",
1343
- "reference_image_urls",
1344
- "reference_video_url",
1345
- "reference_video_type",
1346
- "preserve_reference_video_audio"
1347
- ]
1348
- }
1349
- ]
1350
- }
1351
- };
1352
-
1353
- // src/resources/o1-reference-validation.ts
1354
- import { ValidationError } from "@runapi.ai/core";
1355
- var O1_MODEL = "kling-o1";
1356
- var IMAGE_EXTENSIONS = /* @__PURE__ */ new Set([".jpg", ".jpeg", ".png"]);
1357
- var VIDEO_EXTENSIONS = /* @__PURE__ */ new Set([".mp4", ".mov"]);
1358
- var BLOCKED_IP_CIDRS = [
1359
- "0.0.0.0/8",
1360
- "10.0.0.0/8",
1361
- "100.64.0.0/10",
1362
- "127.0.0.0/8",
1363
- "169.254.0.0/16",
1364
- "172.16.0.0/12",
1365
- "192.0.0.0/24",
1366
- "192.0.2.0/24",
1367
- "192.88.99.0/24",
1368
- "192.168.0.0/16",
1369
- "198.18.0.0/15",
1370
- "198.51.100.0/24",
1371
- "203.0.113.0/24",
1372
- "224.0.0.0/4",
1373
- "240.0.0.0/4",
1374
- "255.255.255.255/32",
1375
- "::/128",
1376
- "::1/128",
1377
- "64:ff9b::/96",
1378
- "64:ff9b:1::/48",
1379
- "100::/64",
1380
- "2001::/32",
1381
- "2001:2::/48",
1382
- "2001:db8::/32",
1383
- "2002::/16",
1384
- "3fff::/20",
1385
- "fc00::/7",
1386
- "fe80::/10",
1387
- "ff00::/8"
1388
- ];
1389
- var BLOCKED_IP_NETWORKS = BLOCKED_IP_CIDRS.map((cidr) => {
1390
- const [address, prefixText] = cidr.split("/");
1391
- const parsed = parseIpLiteral(address);
1392
- if (!parsed) throw new Error("Invalid blocked IP range: " + cidr);
1393
- return { ...parsed, prefix: Number(prefixText) };
1394
- });
1395
- function validateKlingO1References(body) {
1396
- if (body.model !== O1_MODEL) return;
1397
- if (body.enable_sound === true) {
1398
- throw new ValidationError(`enable_sound is not supported by ${O1_MODEL}`);
1399
- }
1400
- validateFrameUrls(body);
1401
- if (typeof body.prompt !== "string") {
1402
- throw new ValidationError("prompt must be a string");
1403
- }
1404
- const prompt = body.prompt;
1405
- const referenceImages = Array.isArray(body.reference_image_urls) ? body.reference_image_urls : [];
1406
- if ("reference_video_url" in body && typeof body.reference_video_url !== "string") {
1407
- throw new ValidationError("reference_video_url must be a string");
1408
- }
1409
- const referenceVideoUrl = body.reference_video_url;
1410
- if (present(body.last_frame_image_url) && (referenceImages.length > 0 || present(referenceVideoUrl))) {
1411
- throw new ValidationError(
1412
- "last_frame_image_url cannot be combined with reference_image_urls or reference_video_url"
1413
- );
1414
- }
1415
- if (referenceVideoUrl && referenceImages.length > 4) {
1416
- throw new ValidationError(
1417
- "reference_image_urls must contain at most 4 items when reference_video_url is present"
1418
- );
1419
- }
1420
- validateReferenceImages(prompt, referenceImages);
1421
- validateReferenceVideo(body, prompt, referenceVideoUrl);
1422
- }
1423
- function validateFrameUrls(body) {
1424
- for (const field of ["first_frame_image_url", "last_frame_image_url"]) {
1425
- const value = body[field];
1426
- if (typeof value !== "string" || value.length === 0) continue;
1427
- if (!isPublicHttpUrl(value)) {
1428
- throw new ValidationError(`${field} must be a public HTTP or HTTPS URL`);
1429
- }
1430
- if (!IMAGE_EXTENSIONS.has(urlExtension(value))) {
1431
- throw new ValidationError(`${field} must use a JPG, JPEG, or PNG URL`);
1432
- }
1433
- }
1434
- }
1435
- function validateReferenceImages(prompt, urls) {
1436
- urls.forEach((url, index) => {
1437
- if (typeof url !== "string") {
1438
- throw new ValidationError(`reference_image_urls[${index}] must be a string`);
1439
- }
1440
- if (!isPublicHttpUrl(url)) {
1441
- throw new ValidationError(
1442
- `reference_image_urls[${index}] must be a public HTTP or HTTPS URL`
1443
- );
1444
- }
1445
- if (!IMAGE_EXTENSIONS.has(urlExtension(url))) {
1446
- throw new ValidationError(
1447
- `reference_image_urls[${index}] must use a JPG, JPEG, or PNG URL`
1448
- );
1449
- }
1450
- const marker = `<<<image_${index + 1}>>>`;
1451
- if (!prompt.includes(marker)) {
1452
- throw new ValidationError(
1453
- `prompt must reference reference_image_urls[${index}] as ${marker}`
1454
- );
1455
- }
1456
- });
1457
- for (const match of prompt.matchAll(/<<<image_(\d+)>>>/g)) {
1458
- const index = Number(match[1]);
1459
- if (index < 1 || index > urls.length) {
1460
- throw new ValidationError(`prompt references missing image_${index}`);
1461
- }
1462
- }
1463
- }
1464
- function validateReferenceVideo(body, prompt, referenceVideoUrl) {
1465
- if (!referenceVideoUrl) {
1466
- if ("reference_video_type" in body) {
1467
- throw new ValidationError("reference_video_type requires reference_video_url");
1468
- }
1469
- if ("preserve_reference_video_audio" in body) {
1470
- throw new ValidationError("preserve_reference_video_audio requires reference_video_url");
1471
- }
1472
- const missingMarker = prompt.match(/<<<video_([^>]+)>>>/);
1473
- if (missingMarker) {
1474
- throw new ValidationError(`prompt references missing video_${missingMarker[1]}`);
1475
- }
1476
- return;
1477
- }
1478
- if (!isPublicHttpUrl(referenceVideoUrl)) {
1479
- throw new ValidationError("reference_video_url must be a public HTTP or HTTPS URL");
1480
- }
1481
- if (!VIDEO_EXTENSIONS.has(urlExtension(referenceVideoUrl))) {
1482
- throw new ValidationError("reference_video_url must use an MP4 or MOV URL");
1483
- }
1484
- if (!prompt.includes("<<<video_1>>>")) {
1485
- throw new ValidationError("prompt must reference reference_video_url as <<<video_1>>>");
1486
- }
1487
- for (const match of prompt.matchAll(/<<<video_([^>]+)>>>/g)) {
1488
- if (match[1] !== "1") {
1489
- throw new ValidationError("prompt may only reference video_1");
1490
- }
1491
- }
1492
- const referenceVideoType = body.reference_video_type ?? "base";
1493
- if (referenceVideoType === "base" && (present(body.first_frame_image_url) || present(body.last_frame_image_url))) {
1494
- throw new ValidationError(
1495
- "reference_video_type base cannot be combined with first_frame_image_url or last_frame_image_url"
1496
- );
1497
- }
1498
- }
1499
- function present(value) {
1500
- return typeof value === "string" ? value.trim().length > 0 : value !== void 0 && value !== null;
1501
- }
1502
- function urlExtension(value) {
1503
- try {
1504
- const path = new URL(value).pathname;
1505
- const dot = path.lastIndexOf(".");
1506
- return dot >= 0 ? path.slice(dot).toLowerCase() : "";
1507
- } catch {
1508
- return "";
1509
- }
1510
- }
1511
- function isPublicHttpUrl(value) {
1512
- try {
1513
- const url = new URL(value);
1514
- return (url.protocol === "http:" || url.protocol === "https:") && url.hostname.length > 0 && url.username.length === 0 && url.password.length === 0 && !isBlockedHost(url.hostname);
1515
- } catch {
1516
- return false;
1517
- }
1518
- }
1519
- function isBlockedHost(hostname) {
1520
- const host = hostname.toLowerCase().replace(/^\[|\]$/g, "").replace(/\.$/, "");
1521
- if (host === "localhost" || host.endsWith(".localhost")) return true;
1522
- const parsed = parseIpLiteral(host);
1523
- if (!parsed) return false;
1524
- return BLOCKED_IP_NETWORKS.some((network) => {
1525
- if (network.bits !== parsed.bits) return false;
1526
- const shift = BigInt(parsed.bits - network.prefix);
1527
- return parsed.value >> shift === network.value >> shift;
1528
- });
1529
- }
1530
- function parseIpLiteral(value) {
1531
- const ipv4 = parseIpv4(value);
1532
- if (ipv4 !== void 0) return { bits: 32, value: ipv4 };
1533
- if (!value.includes(":")) return void 0;
1534
- const halves = value.toLowerCase().split("::");
1535
- if (halves.length > 2) return void 0;
1536
- const head = parseIpv6Half(halves[0]);
1537
- const tail = parseIpv6Half(halves[1] ?? "");
1538
- if (!head || !tail) return void 0;
1539
- const compressed = halves.length === 2;
1540
- const missing = 8 - head.length - tail.length;
1541
- if (!compressed && missing !== 0 || compressed && missing < 1) return void 0;
1542
- const segments = [...head, ...Array(missing).fill(0), ...tail];
1543
- const address = segments.reduce((result, segment) => result << 16n | BigInt(segment), 0n);
1544
- if (address >> 32n === 0xffffn) {
1545
- return { bits: 32, value: address & 0xffffffffn };
1546
- }
1547
- return { bits: 128, value: address };
1548
- }
1549
- function parseIpv4(value) {
1550
- const parts = value.split(".");
1551
- if (parts.length !== 4 || parts.some((part) => !/^\d+$/.test(part))) return void 0;
1552
- const octets = parts.map(Number);
1553
- if (octets.some((octet) => octet < 0 || octet > 255)) return void 0;
1554
- return octets.reduce((result, octet) => result << 8n | BigInt(octet), 0n);
1555
- }
1556
- function parseIpv6Half(value) {
1557
- if (value === "") return [];
1558
- const parts = value.split(":");
1559
- if (parts.some((part) => !/^[0-9a-f]{1,4}$/.test(part))) return void 0;
1560
- return parts.map((part) => Number.parseInt(part, 16));
1561
- }
1562
-
1563
- // src/resources/text-to-video.ts
1564
7
  var ENDPOINT = "/api/v1/kling/text_to_video";
1565
- var V3_TURBO_MODEL = "kling-v3-turbo-text-to-video";
1566
- var V3_TURBO_UNSUPPORTED_FIELDS = [
1567
- "enable_sound",
1568
- "negative_prompt",
1569
- "cfg_scale",
1570
- "multi_shots",
1571
- "multi_prompt",
1572
- "first_frame_image_url",
1573
- "last_frame_image_url",
1574
- "kling_elements"
1575
- ];
1576
8
  var TextToVideo = class {
1577
9
  constructor(http) {
1578
10
  this.http = http;
@@ -1600,9 +32,6 @@ var TextToVideo = class {
1600
32
  */
1601
33
  async create(params, options) {
1602
34
  const body = compactParams(params);
1603
- rejectUnsupportedV3TurboFields(body);
1604
- validateParams(contract["text-to-video"], body);
1605
- validateKlingO1References(body);
1606
35
  return this.http.request("POST", ENDPOINT, {
1607
36
  body,
1608
37
  ...options
@@ -1620,42 +49,11 @@ var TextToVideo = class {
1620
49
  });
1621
50
  }
1622
51
  };
1623
- function rejectUnsupportedV3TurboFields(body) {
1624
- if (body.model !== V3_TURBO_MODEL) return;
1625
- const field = V3_TURBO_UNSUPPORTED_FIELDS.find((candidate) => fieldPresent(body, candidate));
1626
- if (field) {
1627
- throw new ValidationError2(`${field} is not supported by ${V3_TURBO_MODEL}`);
1628
- }
1629
- }
1630
- function fieldPresent(params, field) {
1631
- if (!(field in params)) return false;
1632
- const value = params[field];
1633
- if (value === false) return true;
1634
- if (Array.isArray(value)) return value.some((item) => presentValue(item));
1635
- return presentValue(value);
1636
- }
1637
- function presentValue(value) {
1638
- if (value === null || value === void 0 || value === false) return false;
1639
- if (value === true) return true;
1640
- if (typeof value === "string") return value.trim() !== "";
1641
- if (Array.isArray(value)) return value.length > 0;
1642
- if (typeof value === "object") return Object.keys(value).length > 0;
1643
- return true;
1644
- }
1645
52
 
1646
53
  // src/resources/image-to-video.ts
1647
- import { ValidationError as ValidationError3, compactParams as compactParams2, validateParams as validateParams2 } from "@runapi.ai/core";
54
+ import { compactParams as compactParams2 } from "@runapi.ai/core";
1648
55
  import { pollUntilComplete as pollUntilComplete2 } from "@runapi.ai/core/internal";
1649
56
  var ENDPOINT2 = "/api/v1/kling/image_to_video";
1650
- var V26_MODEL = "kling-v2.6";
1651
- var V3_OMNI_MODEL = "kling-v3-omni";
1652
- var V3_TURBO_MODEL2 = "kling-v3-turbo-image-to-video";
1653
- var V3_TURBO_UNSUPPORTED_FIELDS2 = [
1654
- "aspect_ratio",
1655
- "negative_prompt",
1656
- "cfg_scale",
1657
- "last_frame_image_url"
1658
- ];
1659
57
  var ImageToVideo = class {
1660
58
  constructor(http) {
1661
59
  this.http = http;
@@ -1683,11 +81,6 @@ var ImageToVideo = class {
1683
81
  */
1684
82
  async create(params, options) {
1685
83
  const body = compactParams2(params);
1686
- rejectUnsupportedV3TurboFields2(body);
1687
- validateParams2(contract["image-to-video"], body);
1688
- validateV26Params(body);
1689
- validateV3OmniFields(body);
1690
- validateKlingO1References(body);
1691
84
  return this.http.request("POST", ENDPOINT2, {
1692
85
  body,
1693
86
  ...options
@@ -1705,47 +98,9 @@ var ImageToVideo = class {
1705
98
  });
1706
99
  }
1707
100
  };
1708
- function validateV26Params(body) {
1709
- if (body.model !== V26_MODEL) return;
1710
- if (!fieldPresent2(body, "last_frame_image_url")) return;
1711
- if (body.mode !== "pro") {
1712
- throw new ValidationError3(`last_frame_image_url requires mode pro for ${V26_MODEL}`);
1713
- }
1714
- if (body.duration_seconds !== void 0 && body.duration_seconds !== 5) {
1715
- throw new ValidationError3(`last_frame_image_url requires duration_seconds 5 for ${V26_MODEL}`);
1716
- }
1717
- }
1718
- function validateV3OmniFields(body) {
1719
- if (body.model !== V3_OMNI_MODEL || !fieldPresent2(body, "last_frame_image_url")) return;
1720
- if ((body.duration_seconds ?? 5) !== 5) {
1721
- throw new ValidationError3(`last_frame_image_url requires duration_seconds 5 for ${V3_OMNI_MODEL}`);
1722
- }
1723
- }
1724
- function rejectUnsupportedV3TurboFields2(body) {
1725
- if (body.model !== V3_TURBO_MODEL2) return;
1726
- const field = V3_TURBO_UNSUPPORTED_FIELDS2.find((candidate) => fieldPresent2(body, candidate));
1727
- if (field) {
1728
- throw new ValidationError3(`${field} is not supported by ${V3_TURBO_MODEL2}`);
1729
- }
1730
- }
1731
- function fieldPresent2(params, field) {
1732
- if (!(field in params)) return false;
1733
- const value = params[field];
1734
- if (value === false) return true;
1735
- if (Array.isArray(value)) return value.some((item) => presentValue2(item));
1736
- return presentValue2(value);
1737
- }
1738
- function presentValue2(value) {
1739
- if (value === null || value === void 0 || value === false) return false;
1740
- if (value === true) return true;
1741
- if (typeof value === "string") return value.trim() !== "";
1742
- if (Array.isArray(value)) return value.length > 0;
1743
- if (typeof value === "object") return Object.keys(value).length > 0;
1744
- return true;
1745
- }
1746
101
 
1747
102
  // src/resources/ai-avatar.ts
1748
- import { compactParams as compactParams3, validateParams as validateParams3 } from "@runapi.ai/core";
103
+ import { compactParams as compactParams3 } from "@runapi.ai/core";
1749
104
  import { pollUntilComplete as pollUntilComplete3 } from "@runapi.ai/core/internal";
1750
105
  var ENDPOINT3 = "/api/v1/kling/ai_avatar";
1751
106
  var AiAvatar = class {
@@ -1775,7 +130,6 @@ var AiAvatar = class {
1775
130
  */
1776
131
  async create(params, options) {
1777
132
  const body = compactParams3(params);
1778
- validateParams3(contract["avatar"], body);
1779
133
  return this.http.request("POST", ENDPOINT3, {
1780
134
  body,
1781
135
  ...options
@@ -1795,7 +149,7 @@ var AiAvatar = class {
1795
149
  };
1796
150
 
1797
151
  // src/resources/motion-control.ts
1798
- import { compactParams as compactParams4, validateParams as validateParams4 } from "@runapi.ai/core";
152
+ import { compactParams as compactParams4 } from "@runapi.ai/core";
1799
153
  import { pollUntilComplete as pollUntilComplete4 } from "@runapi.ai/core/internal";
1800
154
  var ENDPOINT4 = "/api/v1/kling/motion_control";
1801
155
  var MotionControl = class {
@@ -1825,7 +179,6 @@ var MotionControl = class {
1825
179
  */
1826
180
  async create(params, options) {
1827
181
  const body = compactParams4(params);
1828
- validateParams4(contract["motion-control"], body);
1829
182
  return this.http.request("POST", ENDPOINT4, {
1830
183
  body,
1831
184
  ...options
@@ -1845,7 +198,7 @@ var MotionControl = class {
1845
198
  };
1846
199
 
1847
200
  // src/resources/extend-video.ts
1848
- import { compactParams as compactParams5, validateParams as validateParams5 } from "@runapi.ai/core";
201
+ import { compactParams as compactParams5 } from "@runapi.ai/core";
1849
202
  import { pollUntilComplete as pollUntilComplete5 } from "@runapi.ai/core/internal";
1850
203
  var ENDPOINT5 = "/api/v1/kling/extend_video";
1851
204
  var ExtendVideo = class {
@@ -1862,7 +215,6 @@ var ExtendVideo = class {
1862
215
  }
1863
216
  async create(params, options) {
1864
217
  const body = compactParams5(params);
1865
- validateParams5(contract["extend-video"], body);
1866
218
  return this.http.request("POST", ENDPOINT5, { body, ...options });
1867
219
  }
1868
220
  async get(id, options) {
@@ -1871,7 +223,7 @@ var ExtendVideo = class {
1871
223
  };
1872
224
 
1873
225
  // src/resources/edit-video.ts
1874
- import { compactParams as compactParams6, validateParams as validateParams6 } from "@runapi.ai/core";
226
+ import { compactParams as compactParams6 } from "@runapi.ai/core";
1875
227
  import { pollUntilComplete as pollUntilComplete6 } from "@runapi.ai/core/internal";
1876
228
  var ENDPOINT6 = "/api/v1/kling/edit_video";
1877
229
  var EditVideo = class {
@@ -1888,7 +240,6 @@ var EditVideo = class {
1888
240
  }
1889
241
  async create(params, options) {
1890
242
  const body = compactParams6(params);
1891
- validateParams6(contract["edit-video"], body);
1892
243
  return this.http.request("POST", ENDPOINT6, { body, ...options });
1893
244
  }
1894
245
  async get(id, options) {
@@ -1926,7 +277,7 @@ import {
1926
277
  AuthenticationError,
1927
278
  InsufficientCreditsError,
1928
279
  NotFoundError,
1929
- ValidationError as ValidationError4,
280
+ ValidationError,
1930
281
  RateLimitError,
1931
282
  ServiceUnavailableError,
1932
283
  NetworkError,
@@ -1946,6 +297,6 @@ export {
1946
297
  TaskFailedError,
1947
298
  TaskTimeoutError,
1948
299
  TimeoutError,
1949
- ValidationError4 as ValidationError
300
+ ValidationError
1950
301
  };
1951
302
  //# sourceMappingURL=index.mjs.map