@crvouga/mockingbird-service-openai 0.1.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/openapi.yaml ADDED
@@ -0,0 +1,3656 @@
1
+ {
2
+ "openapi": "3.1.0",
3
+ "info": {
4
+ "title": "Local scripted OpenAI API",
5
+ "version": "0.1.0",
6
+ "x-mockingbird-upstream": {
7
+ "note": "Hand-authored bounded Chat/embeddings/files/uploads subset from official OpenAI docs and real SDKs openai7.27.0, @ai-sdk/openai4.0.83/ai7.0.127. No billed inference."
8
+ }
9
+ },
10
+ "servers": [
11
+ {
12
+ "url": "https://api.openai.com"
13
+ }
14
+ ],
15
+ "paths": {
16
+ "/v1/chat/completions": {
17
+ "post": {
18
+ "operationId": "CreateChatCompletion",
19
+ "summary": "CreateChatCompletion",
20
+ "parameters": [],
21
+ "responses": {
22
+ "200": {
23
+ "description": "Success",
24
+ "content": {
25
+ "application/json": {
26
+ "schema": {
27
+ "$ref": "#/components/schemas/Chat"
28
+ }
29
+ },
30
+ "text/event-stream": {
31
+ "schema": {
32
+ "type": "string"
33
+ }
34
+ }
35
+ }
36
+ },
37
+ "400": {
38
+ "description": "OpenAI error",
39
+ "content": {
40
+ "application/json": {
41
+ "schema": {
42
+ "$ref": "#/components/schemas/Error"
43
+ }
44
+ }
45
+ }
46
+ },
47
+ "401": {
48
+ "description": "OpenAI error",
49
+ "content": {
50
+ "application/json": {
51
+ "schema": {
52
+ "$ref": "#/components/schemas/Error"
53
+ }
54
+ }
55
+ }
56
+ },
57
+ "403": {
58
+ "description": "OpenAI error",
59
+ "content": {
60
+ "application/json": {
61
+ "schema": {
62
+ "$ref": "#/components/schemas/Error"
63
+ }
64
+ }
65
+ }
66
+ },
67
+ "404": {
68
+ "description": "OpenAI error",
69
+ "content": {
70
+ "application/json": {
71
+ "schema": {
72
+ "$ref": "#/components/schemas/Error"
73
+ }
74
+ }
75
+ }
76
+ },
77
+ "408": {
78
+ "description": "OpenAI error",
79
+ "content": {
80
+ "application/json": {
81
+ "schema": {
82
+ "$ref": "#/components/schemas/Error"
83
+ }
84
+ }
85
+ }
86
+ },
87
+ "409": {
88
+ "description": "OpenAI error",
89
+ "content": {
90
+ "application/json": {
91
+ "schema": {
92
+ "$ref": "#/components/schemas/Error"
93
+ }
94
+ }
95
+ }
96
+ },
97
+ "413": {
98
+ "description": "OpenAI error",
99
+ "content": {
100
+ "application/json": {
101
+ "schema": {
102
+ "$ref": "#/components/schemas/Error"
103
+ }
104
+ }
105
+ }
106
+ },
107
+ "422": {
108
+ "description": "OpenAI error",
109
+ "content": {
110
+ "application/json": {
111
+ "schema": {
112
+ "$ref": "#/components/schemas/Error"
113
+ }
114
+ }
115
+ }
116
+ },
117
+ "429": {
118
+ "description": "OpenAI error",
119
+ "content": {
120
+ "application/json": {
121
+ "schema": {
122
+ "$ref": "#/components/schemas/Error"
123
+ }
124
+ }
125
+ }
126
+ },
127
+ "500": {
128
+ "description": "OpenAI error",
129
+ "content": {
130
+ "application/json": {
131
+ "schema": {
132
+ "$ref": "#/components/schemas/Error"
133
+ }
134
+ }
135
+ }
136
+ },
137
+ "502": {
138
+ "description": "OpenAI error",
139
+ "content": {
140
+ "application/json": {
141
+ "schema": {
142
+ "$ref": "#/components/schemas/Error"
143
+ }
144
+ }
145
+ }
146
+ },
147
+ "503": {
148
+ "description": "OpenAI error",
149
+ "content": {
150
+ "application/json": {
151
+ "schema": {
152
+ "$ref": "#/components/schemas/Error"
153
+ }
154
+ }
155
+ }
156
+ },
157
+ "504": {
158
+ "description": "OpenAI error",
159
+ "content": {
160
+ "application/json": {
161
+ "schema": {
162
+ "$ref": "#/components/schemas/Error"
163
+ }
164
+ }
165
+ }
166
+ }
167
+ },
168
+ "security": [
169
+ {
170
+ "fixtureKey": []
171
+ }
172
+ ],
173
+ "requestBody": {
174
+ "required": true,
175
+ "content": {
176
+ "application/json": {
177
+ "schema": {
178
+ "type": "object",
179
+ "properties": {
180
+ "model": {
181
+ "type": "string",
182
+ "examples": [
183
+ "fixture-chat"
184
+ ]
185
+ },
186
+ "messages": {
187
+ "type": "array",
188
+ "items": {
189
+ "type": "object",
190
+ "properties": {
191
+ "role": {
192
+ "type": "string",
193
+ "enum": [
194
+ "system",
195
+ "developer",
196
+ "user",
197
+ "assistant",
198
+ "tool",
199
+ "function"
200
+ ]
201
+ },
202
+ "content": {
203
+ "oneOf": [
204
+ {
205
+ "type": "string"
206
+ },
207
+ {
208
+ "type": "null"
209
+ },
210
+ {
211
+ "type": "array",
212
+ "items": {
213
+ "type": "object",
214
+ "additionalProperties": true
215
+ }
216
+ }
217
+ ]
218
+ },
219
+ "tool_calls": {
220
+ "type": "array",
221
+ "items": {
222
+ "$ref": "#/components/schemas/ToolCall"
223
+ }
224
+ },
225
+ "tool_call_id": {
226
+ "type": "string"
227
+ },
228
+ "name": {
229
+ "type": "string"
230
+ }
231
+ },
232
+ "required": [
233
+ "role"
234
+ ],
235
+ "additionalProperties": true
236
+ },
237
+ "minItems": 1
238
+ },
239
+ "tools": {
240
+ "type": "array",
241
+ "items": {
242
+ "type": "object",
243
+ "properties": {
244
+ "type": {
245
+ "const": "function"
246
+ },
247
+ "function": {
248
+ "type": "object",
249
+ "properties": {
250
+ "name": {
251
+ "type": "string"
252
+ },
253
+ "parameters": {
254
+ "type": "object",
255
+ "additionalProperties": true
256
+ },
257
+ "description": {
258
+ "type": "string"
259
+ },
260
+ "strict": {
261
+ "type": "boolean"
262
+ }
263
+ },
264
+ "required": [
265
+ "name"
266
+ ],
267
+ "additionalProperties": true
268
+ }
269
+ },
270
+ "required": [
271
+ "type",
272
+ "function"
273
+ ],
274
+ "additionalProperties": false
275
+ }
276
+ },
277
+ "tool_choice": {
278
+ "oneOf": [
279
+ {
280
+ "type": "string",
281
+ "enum": [
282
+ "auto",
283
+ "none",
284
+ "required"
285
+ ]
286
+ },
287
+ {
288
+ "type": "object",
289
+ "additionalProperties": true
290
+ }
291
+ ]
292
+ },
293
+ "max_tokens": {
294
+ "type": "integer",
295
+ "minimum": 1
296
+ },
297
+ "max_completion_tokens": {
298
+ "type": "integer",
299
+ "minimum": 1
300
+ },
301
+ "stream": {
302
+ "type": [
303
+ "boolean",
304
+ "null"
305
+ ]
306
+ },
307
+ "stream_options": {
308
+ "type": [
309
+ "object",
310
+ "null"
311
+ ],
312
+ "additionalProperties": true
313
+ },
314
+ "store": {
315
+ "type": [
316
+ "boolean",
317
+ "null"
318
+ ]
319
+ },
320
+ "prompt_cache_key": {
321
+ "type": "string"
322
+ },
323
+ "metadata": {
324
+ "type": "object",
325
+ "additionalProperties": {
326
+ "type": "string"
327
+ }
328
+ }
329
+ },
330
+ "required": [
331
+ "model",
332
+ "messages"
333
+ ],
334
+ "additionalProperties": true
335
+ }
336
+ }
337
+ }
338
+ },
339
+ "x-mockingbird": {
340
+ "parity": {
341
+ "safe": false
342
+ }
343
+ }
344
+ },
345
+ "get": {
346
+ "operationId": "ListChatCompletions",
347
+ "summary": "ListChatCompletions",
348
+ "parameters": [
349
+ {
350
+ "name": "after",
351
+ "in": "query",
352
+ "required": false,
353
+ "schema": {
354
+ "type": "string"
355
+ }
356
+ },
357
+ {
358
+ "name": "limit",
359
+ "in": "query",
360
+ "required": false,
361
+ "schema": {
362
+ "type": "integer",
363
+ "minimum": 1,
364
+ "maximum": 100
365
+ }
366
+ },
367
+ {
368
+ "name": "order",
369
+ "in": "query",
370
+ "required": false,
371
+ "schema": {
372
+ "type": "string",
373
+ "enum": [
374
+ "asc",
375
+ "desc"
376
+ ]
377
+ }
378
+ },
379
+ {
380
+ "name": "model",
381
+ "in": "query",
382
+ "required": false,
383
+ "schema": {
384
+ "type": "string"
385
+ }
386
+ }
387
+ ],
388
+ "responses": {
389
+ "200": {
390
+ "description": "Success",
391
+ "content": {
392
+ "application/json": {
393
+ "schema": {
394
+ "$ref": "#/components/schemas/Chats"
395
+ }
396
+ }
397
+ }
398
+ },
399
+ "400": {
400
+ "description": "OpenAI error",
401
+ "content": {
402
+ "application/json": {
403
+ "schema": {
404
+ "$ref": "#/components/schemas/Error"
405
+ }
406
+ }
407
+ }
408
+ },
409
+ "401": {
410
+ "description": "OpenAI error",
411
+ "content": {
412
+ "application/json": {
413
+ "schema": {
414
+ "$ref": "#/components/schemas/Error"
415
+ }
416
+ }
417
+ }
418
+ },
419
+ "403": {
420
+ "description": "OpenAI error",
421
+ "content": {
422
+ "application/json": {
423
+ "schema": {
424
+ "$ref": "#/components/schemas/Error"
425
+ }
426
+ }
427
+ }
428
+ },
429
+ "404": {
430
+ "description": "OpenAI error",
431
+ "content": {
432
+ "application/json": {
433
+ "schema": {
434
+ "$ref": "#/components/schemas/Error"
435
+ }
436
+ }
437
+ }
438
+ },
439
+ "408": {
440
+ "description": "OpenAI error",
441
+ "content": {
442
+ "application/json": {
443
+ "schema": {
444
+ "$ref": "#/components/schemas/Error"
445
+ }
446
+ }
447
+ }
448
+ },
449
+ "409": {
450
+ "description": "OpenAI error",
451
+ "content": {
452
+ "application/json": {
453
+ "schema": {
454
+ "$ref": "#/components/schemas/Error"
455
+ }
456
+ }
457
+ }
458
+ },
459
+ "413": {
460
+ "description": "OpenAI error",
461
+ "content": {
462
+ "application/json": {
463
+ "schema": {
464
+ "$ref": "#/components/schemas/Error"
465
+ }
466
+ }
467
+ }
468
+ },
469
+ "422": {
470
+ "description": "OpenAI error",
471
+ "content": {
472
+ "application/json": {
473
+ "schema": {
474
+ "$ref": "#/components/schemas/Error"
475
+ }
476
+ }
477
+ }
478
+ },
479
+ "429": {
480
+ "description": "OpenAI error",
481
+ "content": {
482
+ "application/json": {
483
+ "schema": {
484
+ "$ref": "#/components/schemas/Error"
485
+ }
486
+ }
487
+ }
488
+ },
489
+ "500": {
490
+ "description": "OpenAI error",
491
+ "content": {
492
+ "application/json": {
493
+ "schema": {
494
+ "$ref": "#/components/schemas/Error"
495
+ }
496
+ }
497
+ }
498
+ },
499
+ "502": {
500
+ "description": "OpenAI error",
501
+ "content": {
502
+ "application/json": {
503
+ "schema": {
504
+ "$ref": "#/components/schemas/Error"
505
+ }
506
+ }
507
+ }
508
+ },
509
+ "503": {
510
+ "description": "OpenAI error",
511
+ "content": {
512
+ "application/json": {
513
+ "schema": {
514
+ "$ref": "#/components/schemas/Error"
515
+ }
516
+ }
517
+ }
518
+ },
519
+ "504": {
520
+ "description": "OpenAI error",
521
+ "content": {
522
+ "application/json": {
523
+ "schema": {
524
+ "$ref": "#/components/schemas/Error"
525
+ }
526
+ }
527
+ }
528
+ }
529
+ },
530
+ "security": [
531
+ {
532
+ "fixtureKey": []
533
+ }
534
+ ]
535
+ }
536
+ },
537
+ "/v1/chat/completions/{completion_id}": {
538
+ "get": {
539
+ "operationId": "GetChatCompletion",
540
+ "summary": "GetChatCompletion",
541
+ "parameters": [
542
+ {
543
+ "name": "completion_id",
544
+ "in": "path",
545
+ "required": true,
546
+ "schema": {
547
+ "type": "string"
548
+ }
549
+ }
550
+ ],
551
+ "responses": {
552
+ "200": {
553
+ "description": "Success",
554
+ "content": {
555
+ "application/json": {
556
+ "schema": {
557
+ "$ref": "#/components/schemas/Chat"
558
+ }
559
+ }
560
+ }
561
+ },
562
+ "400": {
563
+ "description": "OpenAI error",
564
+ "content": {
565
+ "application/json": {
566
+ "schema": {
567
+ "$ref": "#/components/schemas/Error"
568
+ }
569
+ }
570
+ }
571
+ },
572
+ "401": {
573
+ "description": "OpenAI error",
574
+ "content": {
575
+ "application/json": {
576
+ "schema": {
577
+ "$ref": "#/components/schemas/Error"
578
+ }
579
+ }
580
+ }
581
+ },
582
+ "403": {
583
+ "description": "OpenAI error",
584
+ "content": {
585
+ "application/json": {
586
+ "schema": {
587
+ "$ref": "#/components/schemas/Error"
588
+ }
589
+ }
590
+ }
591
+ },
592
+ "404": {
593
+ "description": "OpenAI error",
594
+ "content": {
595
+ "application/json": {
596
+ "schema": {
597
+ "$ref": "#/components/schemas/Error"
598
+ }
599
+ }
600
+ }
601
+ },
602
+ "408": {
603
+ "description": "OpenAI error",
604
+ "content": {
605
+ "application/json": {
606
+ "schema": {
607
+ "$ref": "#/components/schemas/Error"
608
+ }
609
+ }
610
+ }
611
+ },
612
+ "409": {
613
+ "description": "OpenAI error",
614
+ "content": {
615
+ "application/json": {
616
+ "schema": {
617
+ "$ref": "#/components/schemas/Error"
618
+ }
619
+ }
620
+ }
621
+ },
622
+ "413": {
623
+ "description": "OpenAI error",
624
+ "content": {
625
+ "application/json": {
626
+ "schema": {
627
+ "$ref": "#/components/schemas/Error"
628
+ }
629
+ }
630
+ }
631
+ },
632
+ "422": {
633
+ "description": "OpenAI error",
634
+ "content": {
635
+ "application/json": {
636
+ "schema": {
637
+ "$ref": "#/components/schemas/Error"
638
+ }
639
+ }
640
+ }
641
+ },
642
+ "429": {
643
+ "description": "OpenAI error",
644
+ "content": {
645
+ "application/json": {
646
+ "schema": {
647
+ "$ref": "#/components/schemas/Error"
648
+ }
649
+ }
650
+ }
651
+ },
652
+ "500": {
653
+ "description": "OpenAI error",
654
+ "content": {
655
+ "application/json": {
656
+ "schema": {
657
+ "$ref": "#/components/schemas/Error"
658
+ }
659
+ }
660
+ }
661
+ },
662
+ "502": {
663
+ "description": "OpenAI error",
664
+ "content": {
665
+ "application/json": {
666
+ "schema": {
667
+ "$ref": "#/components/schemas/Error"
668
+ }
669
+ }
670
+ }
671
+ },
672
+ "503": {
673
+ "description": "OpenAI error",
674
+ "content": {
675
+ "application/json": {
676
+ "schema": {
677
+ "$ref": "#/components/schemas/Error"
678
+ }
679
+ }
680
+ }
681
+ },
682
+ "504": {
683
+ "description": "OpenAI error",
684
+ "content": {
685
+ "application/json": {
686
+ "schema": {
687
+ "$ref": "#/components/schemas/Error"
688
+ }
689
+ }
690
+ }
691
+ }
692
+ },
693
+ "security": [
694
+ {
695
+ "fixtureKey": []
696
+ }
697
+ ]
698
+ },
699
+ "delete": {
700
+ "operationId": "DeleteChatCompletion",
701
+ "summary": "DeleteChatCompletion",
702
+ "parameters": [
703
+ {
704
+ "name": "completion_id",
705
+ "in": "path",
706
+ "required": true,
707
+ "schema": {
708
+ "type": "string"
709
+ }
710
+ }
711
+ ],
712
+ "responses": {
713
+ "200": {
714
+ "description": "Success",
715
+ "content": {
716
+ "application/json": {
717
+ "schema": {
718
+ "$ref": "#/components/schemas/DeletedChat"
719
+ }
720
+ }
721
+ }
722
+ },
723
+ "400": {
724
+ "description": "OpenAI error",
725
+ "content": {
726
+ "application/json": {
727
+ "schema": {
728
+ "$ref": "#/components/schemas/Error"
729
+ }
730
+ }
731
+ }
732
+ },
733
+ "401": {
734
+ "description": "OpenAI error",
735
+ "content": {
736
+ "application/json": {
737
+ "schema": {
738
+ "$ref": "#/components/schemas/Error"
739
+ }
740
+ }
741
+ }
742
+ },
743
+ "403": {
744
+ "description": "OpenAI error",
745
+ "content": {
746
+ "application/json": {
747
+ "schema": {
748
+ "$ref": "#/components/schemas/Error"
749
+ }
750
+ }
751
+ }
752
+ },
753
+ "404": {
754
+ "description": "OpenAI error",
755
+ "content": {
756
+ "application/json": {
757
+ "schema": {
758
+ "$ref": "#/components/schemas/Error"
759
+ }
760
+ }
761
+ }
762
+ },
763
+ "408": {
764
+ "description": "OpenAI error",
765
+ "content": {
766
+ "application/json": {
767
+ "schema": {
768
+ "$ref": "#/components/schemas/Error"
769
+ }
770
+ }
771
+ }
772
+ },
773
+ "409": {
774
+ "description": "OpenAI error",
775
+ "content": {
776
+ "application/json": {
777
+ "schema": {
778
+ "$ref": "#/components/schemas/Error"
779
+ }
780
+ }
781
+ }
782
+ },
783
+ "413": {
784
+ "description": "OpenAI error",
785
+ "content": {
786
+ "application/json": {
787
+ "schema": {
788
+ "$ref": "#/components/schemas/Error"
789
+ }
790
+ }
791
+ }
792
+ },
793
+ "422": {
794
+ "description": "OpenAI error",
795
+ "content": {
796
+ "application/json": {
797
+ "schema": {
798
+ "$ref": "#/components/schemas/Error"
799
+ }
800
+ }
801
+ }
802
+ },
803
+ "429": {
804
+ "description": "OpenAI error",
805
+ "content": {
806
+ "application/json": {
807
+ "schema": {
808
+ "$ref": "#/components/schemas/Error"
809
+ }
810
+ }
811
+ }
812
+ },
813
+ "500": {
814
+ "description": "OpenAI error",
815
+ "content": {
816
+ "application/json": {
817
+ "schema": {
818
+ "$ref": "#/components/schemas/Error"
819
+ }
820
+ }
821
+ }
822
+ },
823
+ "502": {
824
+ "description": "OpenAI error",
825
+ "content": {
826
+ "application/json": {
827
+ "schema": {
828
+ "$ref": "#/components/schemas/Error"
829
+ }
830
+ }
831
+ }
832
+ },
833
+ "503": {
834
+ "description": "OpenAI error",
835
+ "content": {
836
+ "application/json": {
837
+ "schema": {
838
+ "$ref": "#/components/schemas/Error"
839
+ }
840
+ }
841
+ }
842
+ },
843
+ "504": {
844
+ "description": "OpenAI error",
845
+ "content": {
846
+ "application/json": {
847
+ "schema": {
848
+ "$ref": "#/components/schemas/Error"
849
+ }
850
+ }
851
+ }
852
+ }
853
+ },
854
+ "security": [
855
+ {
856
+ "fixtureKey": []
857
+ }
858
+ ],
859
+ "x-mockingbird": {
860
+ "parity": {
861
+ "safe": false
862
+ }
863
+ }
864
+ }
865
+ },
866
+ "/v1/embeddings": {
867
+ "post": {
868
+ "operationId": "CreateEmbeddings",
869
+ "summary": "CreateEmbeddings",
870
+ "parameters": [],
871
+ "responses": {
872
+ "200": {
873
+ "description": "Success",
874
+ "content": {
875
+ "application/json": {
876
+ "schema": {
877
+ "$ref": "#/components/schemas/Embeddings"
878
+ }
879
+ }
880
+ }
881
+ },
882
+ "400": {
883
+ "description": "OpenAI error",
884
+ "content": {
885
+ "application/json": {
886
+ "schema": {
887
+ "$ref": "#/components/schemas/Error"
888
+ }
889
+ }
890
+ }
891
+ },
892
+ "401": {
893
+ "description": "OpenAI error",
894
+ "content": {
895
+ "application/json": {
896
+ "schema": {
897
+ "$ref": "#/components/schemas/Error"
898
+ }
899
+ }
900
+ }
901
+ },
902
+ "403": {
903
+ "description": "OpenAI error",
904
+ "content": {
905
+ "application/json": {
906
+ "schema": {
907
+ "$ref": "#/components/schemas/Error"
908
+ }
909
+ }
910
+ }
911
+ },
912
+ "404": {
913
+ "description": "OpenAI error",
914
+ "content": {
915
+ "application/json": {
916
+ "schema": {
917
+ "$ref": "#/components/schemas/Error"
918
+ }
919
+ }
920
+ }
921
+ },
922
+ "408": {
923
+ "description": "OpenAI error",
924
+ "content": {
925
+ "application/json": {
926
+ "schema": {
927
+ "$ref": "#/components/schemas/Error"
928
+ }
929
+ }
930
+ }
931
+ },
932
+ "409": {
933
+ "description": "OpenAI error",
934
+ "content": {
935
+ "application/json": {
936
+ "schema": {
937
+ "$ref": "#/components/schemas/Error"
938
+ }
939
+ }
940
+ }
941
+ },
942
+ "413": {
943
+ "description": "OpenAI error",
944
+ "content": {
945
+ "application/json": {
946
+ "schema": {
947
+ "$ref": "#/components/schemas/Error"
948
+ }
949
+ }
950
+ }
951
+ },
952
+ "422": {
953
+ "description": "OpenAI error",
954
+ "content": {
955
+ "application/json": {
956
+ "schema": {
957
+ "$ref": "#/components/schemas/Error"
958
+ }
959
+ }
960
+ }
961
+ },
962
+ "429": {
963
+ "description": "OpenAI error",
964
+ "content": {
965
+ "application/json": {
966
+ "schema": {
967
+ "$ref": "#/components/schemas/Error"
968
+ }
969
+ }
970
+ }
971
+ },
972
+ "500": {
973
+ "description": "OpenAI error",
974
+ "content": {
975
+ "application/json": {
976
+ "schema": {
977
+ "$ref": "#/components/schemas/Error"
978
+ }
979
+ }
980
+ }
981
+ },
982
+ "502": {
983
+ "description": "OpenAI error",
984
+ "content": {
985
+ "application/json": {
986
+ "schema": {
987
+ "$ref": "#/components/schemas/Error"
988
+ }
989
+ }
990
+ }
991
+ },
992
+ "503": {
993
+ "description": "OpenAI error",
994
+ "content": {
995
+ "application/json": {
996
+ "schema": {
997
+ "$ref": "#/components/schemas/Error"
998
+ }
999
+ }
1000
+ }
1001
+ },
1002
+ "504": {
1003
+ "description": "OpenAI error",
1004
+ "content": {
1005
+ "application/json": {
1006
+ "schema": {
1007
+ "$ref": "#/components/schemas/Error"
1008
+ }
1009
+ }
1010
+ }
1011
+ }
1012
+ },
1013
+ "security": [
1014
+ {
1015
+ "fixtureKey": []
1016
+ }
1017
+ ],
1018
+ "requestBody": {
1019
+ "required": true,
1020
+ "content": {
1021
+ "application/json": {
1022
+ "schema": {
1023
+ "type": "object",
1024
+ "properties": {
1025
+ "model": {
1026
+ "type": "string",
1027
+ "examples": [
1028
+ "fixture-embedding"
1029
+ ]
1030
+ },
1031
+ "input": {
1032
+ "oneOf": [
1033
+ {
1034
+ "type": "string",
1035
+ "minLength": 1
1036
+ },
1037
+ {
1038
+ "type": "array",
1039
+ "items": {
1040
+ "type": "string",
1041
+ "minLength": 1
1042
+ }
1043
+ },
1044
+ {
1045
+ "type": "array",
1046
+ "items": {
1047
+ "type": "integer",
1048
+ "minimum": 0
1049
+ }
1050
+ },
1051
+ {
1052
+ "type": "array",
1053
+ "items": {
1054
+ "type": "array",
1055
+ "items": {
1056
+ "type": "integer",
1057
+ "minimum": 0
1058
+ }
1059
+ }
1060
+ }
1061
+ ]
1062
+ },
1063
+ "dimensions": {
1064
+ "type": "integer",
1065
+ "minimum": 1
1066
+ },
1067
+ "encoding_format": {
1068
+ "type": "string",
1069
+ "enum": [
1070
+ "float",
1071
+ "base64"
1072
+ ]
1073
+ }
1074
+ },
1075
+ "required": [
1076
+ "model",
1077
+ "input"
1078
+ ],
1079
+ "additionalProperties": true
1080
+ }
1081
+ }
1082
+ }
1083
+ },
1084
+ "x-mockingbird": {
1085
+ "parity": {
1086
+ "safe": false
1087
+ }
1088
+ }
1089
+ }
1090
+ },
1091
+ "/v1/models": {
1092
+ "get": {
1093
+ "operationId": "ListModels",
1094
+ "summary": "ListModels",
1095
+ "parameters": [],
1096
+ "responses": {
1097
+ "200": {
1098
+ "description": "Success",
1099
+ "content": {
1100
+ "application/json": {
1101
+ "schema": {
1102
+ "$ref": "#/components/schemas/Models"
1103
+ }
1104
+ }
1105
+ }
1106
+ },
1107
+ "400": {
1108
+ "description": "OpenAI error",
1109
+ "content": {
1110
+ "application/json": {
1111
+ "schema": {
1112
+ "$ref": "#/components/schemas/Error"
1113
+ }
1114
+ }
1115
+ }
1116
+ },
1117
+ "401": {
1118
+ "description": "OpenAI error",
1119
+ "content": {
1120
+ "application/json": {
1121
+ "schema": {
1122
+ "$ref": "#/components/schemas/Error"
1123
+ }
1124
+ }
1125
+ }
1126
+ },
1127
+ "403": {
1128
+ "description": "OpenAI error",
1129
+ "content": {
1130
+ "application/json": {
1131
+ "schema": {
1132
+ "$ref": "#/components/schemas/Error"
1133
+ }
1134
+ }
1135
+ }
1136
+ },
1137
+ "404": {
1138
+ "description": "OpenAI error",
1139
+ "content": {
1140
+ "application/json": {
1141
+ "schema": {
1142
+ "$ref": "#/components/schemas/Error"
1143
+ }
1144
+ }
1145
+ }
1146
+ },
1147
+ "408": {
1148
+ "description": "OpenAI error",
1149
+ "content": {
1150
+ "application/json": {
1151
+ "schema": {
1152
+ "$ref": "#/components/schemas/Error"
1153
+ }
1154
+ }
1155
+ }
1156
+ },
1157
+ "409": {
1158
+ "description": "OpenAI error",
1159
+ "content": {
1160
+ "application/json": {
1161
+ "schema": {
1162
+ "$ref": "#/components/schemas/Error"
1163
+ }
1164
+ }
1165
+ }
1166
+ },
1167
+ "413": {
1168
+ "description": "OpenAI error",
1169
+ "content": {
1170
+ "application/json": {
1171
+ "schema": {
1172
+ "$ref": "#/components/schemas/Error"
1173
+ }
1174
+ }
1175
+ }
1176
+ },
1177
+ "422": {
1178
+ "description": "OpenAI error",
1179
+ "content": {
1180
+ "application/json": {
1181
+ "schema": {
1182
+ "$ref": "#/components/schemas/Error"
1183
+ }
1184
+ }
1185
+ }
1186
+ },
1187
+ "429": {
1188
+ "description": "OpenAI error",
1189
+ "content": {
1190
+ "application/json": {
1191
+ "schema": {
1192
+ "$ref": "#/components/schemas/Error"
1193
+ }
1194
+ }
1195
+ }
1196
+ },
1197
+ "500": {
1198
+ "description": "OpenAI error",
1199
+ "content": {
1200
+ "application/json": {
1201
+ "schema": {
1202
+ "$ref": "#/components/schemas/Error"
1203
+ }
1204
+ }
1205
+ }
1206
+ },
1207
+ "502": {
1208
+ "description": "OpenAI error",
1209
+ "content": {
1210
+ "application/json": {
1211
+ "schema": {
1212
+ "$ref": "#/components/schemas/Error"
1213
+ }
1214
+ }
1215
+ }
1216
+ },
1217
+ "503": {
1218
+ "description": "OpenAI error",
1219
+ "content": {
1220
+ "application/json": {
1221
+ "schema": {
1222
+ "$ref": "#/components/schemas/Error"
1223
+ }
1224
+ }
1225
+ }
1226
+ },
1227
+ "504": {
1228
+ "description": "OpenAI error",
1229
+ "content": {
1230
+ "application/json": {
1231
+ "schema": {
1232
+ "$ref": "#/components/schemas/Error"
1233
+ }
1234
+ }
1235
+ }
1236
+ }
1237
+ },
1238
+ "security": [
1239
+ {
1240
+ "fixtureKey": []
1241
+ }
1242
+ ]
1243
+ }
1244
+ },
1245
+ "/v1/models/{model}": {
1246
+ "get": {
1247
+ "operationId": "GetModel",
1248
+ "summary": "GetModel",
1249
+ "parameters": [
1250
+ {
1251
+ "name": "model",
1252
+ "in": "path",
1253
+ "required": true,
1254
+ "schema": {
1255
+ "type": "string"
1256
+ }
1257
+ }
1258
+ ],
1259
+ "responses": {
1260
+ "200": {
1261
+ "description": "Success",
1262
+ "content": {
1263
+ "application/json": {
1264
+ "schema": {
1265
+ "$ref": "#/components/schemas/Model"
1266
+ }
1267
+ }
1268
+ }
1269
+ },
1270
+ "400": {
1271
+ "description": "OpenAI error",
1272
+ "content": {
1273
+ "application/json": {
1274
+ "schema": {
1275
+ "$ref": "#/components/schemas/Error"
1276
+ }
1277
+ }
1278
+ }
1279
+ },
1280
+ "401": {
1281
+ "description": "OpenAI error",
1282
+ "content": {
1283
+ "application/json": {
1284
+ "schema": {
1285
+ "$ref": "#/components/schemas/Error"
1286
+ }
1287
+ }
1288
+ }
1289
+ },
1290
+ "403": {
1291
+ "description": "OpenAI error",
1292
+ "content": {
1293
+ "application/json": {
1294
+ "schema": {
1295
+ "$ref": "#/components/schemas/Error"
1296
+ }
1297
+ }
1298
+ }
1299
+ },
1300
+ "404": {
1301
+ "description": "OpenAI error",
1302
+ "content": {
1303
+ "application/json": {
1304
+ "schema": {
1305
+ "$ref": "#/components/schemas/Error"
1306
+ }
1307
+ }
1308
+ }
1309
+ },
1310
+ "408": {
1311
+ "description": "OpenAI error",
1312
+ "content": {
1313
+ "application/json": {
1314
+ "schema": {
1315
+ "$ref": "#/components/schemas/Error"
1316
+ }
1317
+ }
1318
+ }
1319
+ },
1320
+ "409": {
1321
+ "description": "OpenAI error",
1322
+ "content": {
1323
+ "application/json": {
1324
+ "schema": {
1325
+ "$ref": "#/components/schemas/Error"
1326
+ }
1327
+ }
1328
+ }
1329
+ },
1330
+ "413": {
1331
+ "description": "OpenAI error",
1332
+ "content": {
1333
+ "application/json": {
1334
+ "schema": {
1335
+ "$ref": "#/components/schemas/Error"
1336
+ }
1337
+ }
1338
+ }
1339
+ },
1340
+ "422": {
1341
+ "description": "OpenAI error",
1342
+ "content": {
1343
+ "application/json": {
1344
+ "schema": {
1345
+ "$ref": "#/components/schemas/Error"
1346
+ }
1347
+ }
1348
+ }
1349
+ },
1350
+ "429": {
1351
+ "description": "OpenAI error",
1352
+ "content": {
1353
+ "application/json": {
1354
+ "schema": {
1355
+ "$ref": "#/components/schemas/Error"
1356
+ }
1357
+ }
1358
+ }
1359
+ },
1360
+ "500": {
1361
+ "description": "OpenAI error",
1362
+ "content": {
1363
+ "application/json": {
1364
+ "schema": {
1365
+ "$ref": "#/components/schemas/Error"
1366
+ }
1367
+ }
1368
+ }
1369
+ },
1370
+ "502": {
1371
+ "description": "OpenAI error",
1372
+ "content": {
1373
+ "application/json": {
1374
+ "schema": {
1375
+ "$ref": "#/components/schemas/Error"
1376
+ }
1377
+ }
1378
+ }
1379
+ },
1380
+ "503": {
1381
+ "description": "OpenAI error",
1382
+ "content": {
1383
+ "application/json": {
1384
+ "schema": {
1385
+ "$ref": "#/components/schemas/Error"
1386
+ }
1387
+ }
1388
+ }
1389
+ },
1390
+ "504": {
1391
+ "description": "OpenAI error",
1392
+ "content": {
1393
+ "application/json": {
1394
+ "schema": {
1395
+ "$ref": "#/components/schemas/Error"
1396
+ }
1397
+ }
1398
+ }
1399
+ }
1400
+ },
1401
+ "security": [
1402
+ {
1403
+ "fixtureKey": []
1404
+ }
1405
+ ]
1406
+ }
1407
+ },
1408
+ "/v1/files": {
1409
+ "post": {
1410
+ "operationId": "CreateFile",
1411
+ "summary": "CreateFile",
1412
+ "parameters": [],
1413
+ "responses": {
1414
+ "200": {
1415
+ "description": "Success",
1416
+ "content": {
1417
+ "application/json": {
1418
+ "schema": {
1419
+ "$ref": "#/components/schemas/File"
1420
+ }
1421
+ }
1422
+ }
1423
+ },
1424
+ "400": {
1425
+ "description": "OpenAI error",
1426
+ "content": {
1427
+ "application/json": {
1428
+ "schema": {
1429
+ "$ref": "#/components/schemas/Error"
1430
+ }
1431
+ }
1432
+ }
1433
+ },
1434
+ "401": {
1435
+ "description": "OpenAI error",
1436
+ "content": {
1437
+ "application/json": {
1438
+ "schema": {
1439
+ "$ref": "#/components/schemas/Error"
1440
+ }
1441
+ }
1442
+ }
1443
+ },
1444
+ "403": {
1445
+ "description": "OpenAI error",
1446
+ "content": {
1447
+ "application/json": {
1448
+ "schema": {
1449
+ "$ref": "#/components/schemas/Error"
1450
+ }
1451
+ }
1452
+ }
1453
+ },
1454
+ "404": {
1455
+ "description": "OpenAI error",
1456
+ "content": {
1457
+ "application/json": {
1458
+ "schema": {
1459
+ "$ref": "#/components/schemas/Error"
1460
+ }
1461
+ }
1462
+ }
1463
+ },
1464
+ "408": {
1465
+ "description": "OpenAI error",
1466
+ "content": {
1467
+ "application/json": {
1468
+ "schema": {
1469
+ "$ref": "#/components/schemas/Error"
1470
+ }
1471
+ }
1472
+ }
1473
+ },
1474
+ "409": {
1475
+ "description": "OpenAI error",
1476
+ "content": {
1477
+ "application/json": {
1478
+ "schema": {
1479
+ "$ref": "#/components/schemas/Error"
1480
+ }
1481
+ }
1482
+ }
1483
+ },
1484
+ "413": {
1485
+ "description": "OpenAI error",
1486
+ "content": {
1487
+ "application/json": {
1488
+ "schema": {
1489
+ "$ref": "#/components/schemas/Error"
1490
+ }
1491
+ }
1492
+ }
1493
+ },
1494
+ "422": {
1495
+ "description": "OpenAI error",
1496
+ "content": {
1497
+ "application/json": {
1498
+ "schema": {
1499
+ "$ref": "#/components/schemas/Error"
1500
+ }
1501
+ }
1502
+ }
1503
+ },
1504
+ "429": {
1505
+ "description": "OpenAI error",
1506
+ "content": {
1507
+ "application/json": {
1508
+ "schema": {
1509
+ "$ref": "#/components/schemas/Error"
1510
+ }
1511
+ }
1512
+ }
1513
+ },
1514
+ "500": {
1515
+ "description": "OpenAI error",
1516
+ "content": {
1517
+ "application/json": {
1518
+ "schema": {
1519
+ "$ref": "#/components/schemas/Error"
1520
+ }
1521
+ }
1522
+ }
1523
+ },
1524
+ "502": {
1525
+ "description": "OpenAI error",
1526
+ "content": {
1527
+ "application/json": {
1528
+ "schema": {
1529
+ "$ref": "#/components/schemas/Error"
1530
+ }
1531
+ }
1532
+ }
1533
+ },
1534
+ "503": {
1535
+ "description": "OpenAI error",
1536
+ "content": {
1537
+ "application/json": {
1538
+ "schema": {
1539
+ "$ref": "#/components/schemas/Error"
1540
+ }
1541
+ }
1542
+ }
1543
+ },
1544
+ "504": {
1545
+ "description": "OpenAI error",
1546
+ "content": {
1547
+ "application/json": {
1548
+ "schema": {
1549
+ "$ref": "#/components/schemas/Error"
1550
+ }
1551
+ }
1552
+ }
1553
+ }
1554
+ },
1555
+ "security": [
1556
+ {
1557
+ "fixtureKey": []
1558
+ }
1559
+ ],
1560
+ "x-mockingbird": {
1561
+ "parity": {
1562
+ "safe": false,
1563
+ "enabled": false,
1564
+ "reason": "Multipart/binary byte shapes are verified by served SDK and acceptance tests."
1565
+ }
1566
+ },
1567
+ "requestBody": {
1568
+ "required": true,
1569
+ "content": {
1570
+ "multipart/form-data": {
1571
+ "schema": {
1572
+ "type": "object",
1573
+ "properties": {
1574
+ "file": {
1575
+ "type": "string",
1576
+ "format": "binary"
1577
+ },
1578
+ "purpose": {
1579
+ "type": "string"
1580
+ }
1581
+ },
1582
+ "required": [
1583
+ "file",
1584
+ "purpose"
1585
+ ],
1586
+ "additionalProperties": false
1587
+ }
1588
+ }
1589
+ }
1590
+ }
1591
+ },
1592
+ "get": {
1593
+ "operationId": "ListFiles",
1594
+ "summary": "ListFiles",
1595
+ "parameters": [
1596
+ {
1597
+ "name": "after",
1598
+ "in": "query",
1599
+ "required": false,
1600
+ "schema": {
1601
+ "type": "string"
1602
+ }
1603
+ },
1604
+ {
1605
+ "name": "limit",
1606
+ "in": "query",
1607
+ "required": false,
1608
+ "schema": {
1609
+ "type": "integer",
1610
+ "minimum": 1,
1611
+ "maximum": 10000
1612
+ }
1613
+ },
1614
+ {
1615
+ "name": "order",
1616
+ "in": "query",
1617
+ "required": false,
1618
+ "schema": {
1619
+ "type": "string",
1620
+ "enum": [
1621
+ "asc",
1622
+ "desc"
1623
+ ]
1624
+ }
1625
+ },
1626
+ {
1627
+ "name": "purpose",
1628
+ "in": "query",
1629
+ "required": false,
1630
+ "schema": {
1631
+ "type": "string"
1632
+ }
1633
+ }
1634
+ ],
1635
+ "responses": {
1636
+ "200": {
1637
+ "description": "Success",
1638
+ "content": {
1639
+ "application/json": {
1640
+ "schema": {
1641
+ "$ref": "#/components/schemas/Files"
1642
+ }
1643
+ }
1644
+ }
1645
+ },
1646
+ "400": {
1647
+ "description": "OpenAI error",
1648
+ "content": {
1649
+ "application/json": {
1650
+ "schema": {
1651
+ "$ref": "#/components/schemas/Error"
1652
+ }
1653
+ }
1654
+ }
1655
+ },
1656
+ "401": {
1657
+ "description": "OpenAI error",
1658
+ "content": {
1659
+ "application/json": {
1660
+ "schema": {
1661
+ "$ref": "#/components/schemas/Error"
1662
+ }
1663
+ }
1664
+ }
1665
+ },
1666
+ "403": {
1667
+ "description": "OpenAI error",
1668
+ "content": {
1669
+ "application/json": {
1670
+ "schema": {
1671
+ "$ref": "#/components/schemas/Error"
1672
+ }
1673
+ }
1674
+ }
1675
+ },
1676
+ "404": {
1677
+ "description": "OpenAI error",
1678
+ "content": {
1679
+ "application/json": {
1680
+ "schema": {
1681
+ "$ref": "#/components/schemas/Error"
1682
+ }
1683
+ }
1684
+ }
1685
+ },
1686
+ "408": {
1687
+ "description": "OpenAI error",
1688
+ "content": {
1689
+ "application/json": {
1690
+ "schema": {
1691
+ "$ref": "#/components/schemas/Error"
1692
+ }
1693
+ }
1694
+ }
1695
+ },
1696
+ "409": {
1697
+ "description": "OpenAI error",
1698
+ "content": {
1699
+ "application/json": {
1700
+ "schema": {
1701
+ "$ref": "#/components/schemas/Error"
1702
+ }
1703
+ }
1704
+ }
1705
+ },
1706
+ "413": {
1707
+ "description": "OpenAI error",
1708
+ "content": {
1709
+ "application/json": {
1710
+ "schema": {
1711
+ "$ref": "#/components/schemas/Error"
1712
+ }
1713
+ }
1714
+ }
1715
+ },
1716
+ "422": {
1717
+ "description": "OpenAI error",
1718
+ "content": {
1719
+ "application/json": {
1720
+ "schema": {
1721
+ "$ref": "#/components/schemas/Error"
1722
+ }
1723
+ }
1724
+ }
1725
+ },
1726
+ "429": {
1727
+ "description": "OpenAI error",
1728
+ "content": {
1729
+ "application/json": {
1730
+ "schema": {
1731
+ "$ref": "#/components/schemas/Error"
1732
+ }
1733
+ }
1734
+ }
1735
+ },
1736
+ "500": {
1737
+ "description": "OpenAI error",
1738
+ "content": {
1739
+ "application/json": {
1740
+ "schema": {
1741
+ "$ref": "#/components/schemas/Error"
1742
+ }
1743
+ }
1744
+ }
1745
+ },
1746
+ "502": {
1747
+ "description": "OpenAI error",
1748
+ "content": {
1749
+ "application/json": {
1750
+ "schema": {
1751
+ "$ref": "#/components/schemas/Error"
1752
+ }
1753
+ }
1754
+ }
1755
+ },
1756
+ "503": {
1757
+ "description": "OpenAI error",
1758
+ "content": {
1759
+ "application/json": {
1760
+ "schema": {
1761
+ "$ref": "#/components/schemas/Error"
1762
+ }
1763
+ }
1764
+ }
1765
+ },
1766
+ "504": {
1767
+ "description": "OpenAI error",
1768
+ "content": {
1769
+ "application/json": {
1770
+ "schema": {
1771
+ "$ref": "#/components/schemas/Error"
1772
+ }
1773
+ }
1774
+ }
1775
+ }
1776
+ },
1777
+ "security": [
1778
+ {
1779
+ "fixtureKey": []
1780
+ }
1781
+ ]
1782
+ }
1783
+ },
1784
+ "/v1/files/{file_id}": {
1785
+ "get": {
1786
+ "operationId": "GetFile",
1787
+ "summary": "GetFile",
1788
+ "parameters": [
1789
+ {
1790
+ "name": "file_id",
1791
+ "in": "path",
1792
+ "required": true,
1793
+ "schema": {
1794
+ "type": "string"
1795
+ }
1796
+ }
1797
+ ],
1798
+ "responses": {
1799
+ "200": {
1800
+ "description": "Success",
1801
+ "content": {
1802
+ "application/json": {
1803
+ "schema": {
1804
+ "$ref": "#/components/schemas/File"
1805
+ }
1806
+ }
1807
+ }
1808
+ },
1809
+ "400": {
1810
+ "description": "OpenAI error",
1811
+ "content": {
1812
+ "application/json": {
1813
+ "schema": {
1814
+ "$ref": "#/components/schemas/Error"
1815
+ }
1816
+ }
1817
+ }
1818
+ },
1819
+ "401": {
1820
+ "description": "OpenAI error",
1821
+ "content": {
1822
+ "application/json": {
1823
+ "schema": {
1824
+ "$ref": "#/components/schemas/Error"
1825
+ }
1826
+ }
1827
+ }
1828
+ },
1829
+ "403": {
1830
+ "description": "OpenAI error",
1831
+ "content": {
1832
+ "application/json": {
1833
+ "schema": {
1834
+ "$ref": "#/components/schemas/Error"
1835
+ }
1836
+ }
1837
+ }
1838
+ },
1839
+ "404": {
1840
+ "description": "OpenAI error",
1841
+ "content": {
1842
+ "application/json": {
1843
+ "schema": {
1844
+ "$ref": "#/components/schemas/Error"
1845
+ }
1846
+ }
1847
+ }
1848
+ },
1849
+ "408": {
1850
+ "description": "OpenAI error",
1851
+ "content": {
1852
+ "application/json": {
1853
+ "schema": {
1854
+ "$ref": "#/components/schemas/Error"
1855
+ }
1856
+ }
1857
+ }
1858
+ },
1859
+ "409": {
1860
+ "description": "OpenAI error",
1861
+ "content": {
1862
+ "application/json": {
1863
+ "schema": {
1864
+ "$ref": "#/components/schemas/Error"
1865
+ }
1866
+ }
1867
+ }
1868
+ },
1869
+ "413": {
1870
+ "description": "OpenAI error",
1871
+ "content": {
1872
+ "application/json": {
1873
+ "schema": {
1874
+ "$ref": "#/components/schemas/Error"
1875
+ }
1876
+ }
1877
+ }
1878
+ },
1879
+ "422": {
1880
+ "description": "OpenAI error",
1881
+ "content": {
1882
+ "application/json": {
1883
+ "schema": {
1884
+ "$ref": "#/components/schemas/Error"
1885
+ }
1886
+ }
1887
+ }
1888
+ },
1889
+ "429": {
1890
+ "description": "OpenAI error",
1891
+ "content": {
1892
+ "application/json": {
1893
+ "schema": {
1894
+ "$ref": "#/components/schemas/Error"
1895
+ }
1896
+ }
1897
+ }
1898
+ },
1899
+ "500": {
1900
+ "description": "OpenAI error",
1901
+ "content": {
1902
+ "application/json": {
1903
+ "schema": {
1904
+ "$ref": "#/components/schemas/Error"
1905
+ }
1906
+ }
1907
+ }
1908
+ },
1909
+ "502": {
1910
+ "description": "OpenAI error",
1911
+ "content": {
1912
+ "application/json": {
1913
+ "schema": {
1914
+ "$ref": "#/components/schemas/Error"
1915
+ }
1916
+ }
1917
+ }
1918
+ },
1919
+ "503": {
1920
+ "description": "OpenAI error",
1921
+ "content": {
1922
+ "application/json": {
1923
+ "schema": {
1924
+ "$ref": "#/components/schemas/Error"
1925
+ }
1926
+ }
1927
+ }
1928
+ },
1929
+ "504": {
1930
+ "description": "OpenAI error",
1931
+ "content": {
1932
+ "application/json": {
1933
+ "schema": {
1934
+ "$ref": "#/components/schemas/Error"
1935
+ }
1936
+ }
1937
+ }
1938
+ }
1939
+ },
1940
+ "security": [
1941
+ {
1942
+ "fixtureKey": []
1943
+ }
1944
+ ]
1945
+ },
1946
+ "delete": {
1947
+ "operationId": "DeleteFile",
1948
+ "summary": "DeleteFile",
1949
+ "parameters": [
1950
+ {
1951
+ "name": "file_id",
1952
+ "in": "path",
1953
+ "required": true,
1954
+ "schema": {
1955
+ "type": "string"
1956
+ }
1957
+ }
1958
+ ],
1959
+ "responses": {
1960
+ "200": {
1961
+ "description": "Success",
1962
+ "content": {
1963
+ "application/json": {
1964
+ "schema": {
1965
+ "$ref": "#/components/schemas/DeletedFile"
1966
+ }
1967
+ }
1968
+ }
1969
+ },
1970
+ "400": {
1971
+ "description": "OpenAI error",
1972
+ "content": {
1973
+ "application/json": {
1974
+ "schema": {
1975
+ "$ref": "#/components/schemas/Error"
1976
+ }
1977
+ }
1978
+ }
1979
+ },
1980
+ "401": {
1981
+ "description": "OpenAI error",
1982
+ "content": {
1983
+ "application/json": {
1984
+ "schema": {
1985
+ "$ref": "#/components/schemas/Error"
1986
+ }
1987
+ }
1988
+ }
1989
+ },
1990
+ "403": {
1991
+ "description": "OpenAI error",
1992
+ "content": {
1993
+ "application/json": {
1994
+ "schema": {
1995
+ "$ref": "#/components/schemas/Error"
1996
+ }
1997
+ }
1998
+ }
1999
+ },
2000
+ "404": {
2001
+ "description": "OpenAI error",
2002
+ "content": {
2003
+ "application/json": {
2004
+ "schema": {
2005
+ "$ref": "#/components/schemas/Error"
2006
+ }
2007
+ }
2008
+ }
2009
+ },
2010
+ "408": {
2011
+ "description": "OpenAI error",
2012
+ "content": {
2013
+ "application/json": {
2014
+ "schema": {
2015
+ "$ref": "#/components/schemas/Error"
2016
+ }
2017
+ }
2018
+ }
2019
+ },
2020
+ "409": {
2021
+ "description": "OpenAI error",
2022
+ "content": {
2023
+ "application/json": {
2024
+ "schema": {
2025
+ "$ref": "#/components/schemas/Error"
2026
+ }
2027
+ }
2028
+ }
2029
+ },
2030
+ "413": {
2031
+ "description": "OpenAI error",
2032
+ "content": {
2033
+ "application/json": {
2034
+ "schema": {
2035
+ "$ref": "#/components/schemas/Error"
2036
+ }
2037
+ }
2038
+ }
2039
+ },
2040
+ "422": {
2041
+ "description": "OpenAI error",
2042
+ "content": {
2043
+ "application/json": {
2044
+ "schema": {
2045
+ "$ref": "#/components/schemas/Error"
2046
+ }
2047
+ }
2048
+ }
2049
+ },
2050
+ "429": {
2051
+ "description": "OpenAI error",
2052
+ "content": {
2053
+ "application/json": {
2054
+ "schema": {
2055
+ "$ref": "#/components/schemas/Error"
2056
+ }
2057
+ }
2058
+ }
2059
+ },
2060
+ "500": {
2061
+ "description": "OpenAI error",
2062
+ "content": {
2063
+ "application/json": {
2064
+ "schema": {
2065
+ "$ref": "#/components/schemas/Error"
2066
+ }
2067
+ }
2068
+ }
2069
+ },
2070
+ "502": {
2071
+ "description": "OpenAI error",
2072
+ "content": {
2073
+ "application/json": {
2074
+ "schema": {
2075
+ "$ref": "#/components/schemas/Error"
2076
+ }
2077
+ }
2078
+ }
2079
+ },
2080
+ "503": {
2081
+ "description": "OpenAI error",
2082
+ "content": {
2083
+ "application/json": {
2084
+ "schema": {
2085
+ "$ref": "#/components/schemas/Error"
2086
+ }
2087
+ }
2088
+ }
2089
+ },
2090
+ "504": {
2091
+ "description": "OpenAI error",
2092
+ "content": {
2093
+ "application/json": {
2094
+ "schema": {
2095
+ "$ref": "#/components/schemas/Error"
2096
+ }
2097
+ }
2098
+ }
2099
+ }
2100
+ },
2101
+ "security": [
2102
+ {
2103
+ "fixtureKey": []
2104
+ }
2105
+ ],
2106
+ "x-mockingbird": {
2107
+ "parity": {
2108
+ "safe": false
2109
+ }
2110
+ }
2111
+ }
2112
+ },
2113
+ "/v1/files/{file_id}/content": {
2114
+ "get": {
2115
+ "operationId": "DownloadFile",
2116
+ "summary": "DownloadFile",
2117
+ "parameters": [
2118
+ {
2119
+ "name": "file_id",
2120
+ "in": "path",
2121
+ "required": true,
2122
+ "schema": {
2123
+ "type": "string"
2124
+ }
2125
+ }
2126
+ ],
2127
+ "responses": {
2128
+ "200": {
2129
+ "description": "Exact uploaded bytes",
2130
+ "content": {
2131
+ "application/octet-stream": {
2132
+ "schema": {
2133
+ "type": "string",
2134
+ "format": "binary"
2135
+ }
2136
+ }
2137
+ }
2138
+ },
2139
+ "400": {
2140
+ "description": "OpenAI error",
2141
+ "content": {
2142
+ "application/json": {
2143
+ "schema": {
2144
+ "$ref": "#/components/schemas/Error"
2145
+ }
2146
+ }
2147
+ }
2148
+ },
2149
+ "401": {
2150
+ "description": "OpenAI error",
2151
+ "content": {
2152
+ "application/json": {
2153
+ "schema": {
2154
+ "$ref": "#/components/schemas/Error"
2155
+ }
2156
+ }
2157
+ }
2158
+ },
2159
+ "403": {
2160
+ "description": "OpenAI error",
2161
+ "content": {
2162
+ "application/json": {
2163
+ "schema": {
2164
+ "$ref": "#/components/schemas/Error"
2165
+ }
2166
+ }
2167
+ }
2168
+ },
2169
+ "404": {
2170
+ "description": "OpenAI error",
2171
+ "content": {
2172
+ "application/json": {
2173
+ "schema": {
2174
+ "$ref": "#/components/schemas/Error"
2175
+ }
2176
+ }
2177
+ }
2178
+ },
2179
+ "408": {
2180
+ "description": "OpenAI error",
2181
+ "content": {
2182
+ "application/json": {
2183
+ "schema": {
2184
+ "$ref": "#/components/schemas/Error"
2185
+ }
2186
+ }
2187
+ }
2188
+ },
2189
+ "409": {
2190
+ "description": "OpenAI error",
2191
+ "content": {
2192
+ "application/json": {
2193
+ "schema": {
2194
+ "$ref": "#/components/schemas/Error"
2195
+ }
2196
+ }
2197
+ }
2198
+ },
2199
+ "413": {
2200
+ "description": "OpenAI error",
2201
+ "content": {
2202
+ "application/json": {
2203
+ "schema": {
2204
+ "$ref": "#/components/schemas/Error"
2205
+ }
2206
+ }
2207
+ }
2208
+ },
2209
+ "422": {
2210
+ "description": "OpenAI error",
2211
+ "content": {
2212
+ "application/json": {
2213
+ "schema": {
2214
+ "$ref": "#/components/schemas/Error"
2215
+ }
2216
+ }
2217
+ }
2218
+ },
2219
+ "429": {
2220
+ "description": "OpenAI error",
2221
+ "content": {
2222
+ "application/json": {
2223
+ "schema": {
2224
+ "$ref": "#/components/schemas/Error"
2225
+ }
2226
+ }
2227
+ }
2228
+ },
2229
+ "500": {
2230
+ "description": "OpenAI error",
2231
+ "content": {
2232
+ "application/json": {
2233
+ "schema": {
2234
+ "$ref": "#/components/schemas/Error"
2235
+ }
2236
+ }
2237
+ }
2238
+ },
2239
+ "502": {
2240
+ "description": "OpenAI error",
2241
+ "content": {
2242
+ "application/json": {
2243
+ "schema": {
2244
+ "$ref": "#/components/schemas/Error"
2245
+ }
2246
+ }
2247
+ }
2248
+ },
2249
+ "503": {
2250
+ "description": "OpenAI error",
2251
+ "content": {
2252
+ "application/json": {
2253
+ "schema": {
2254
+ "$ref": "#/components/schemas/Error"
2255
+ }
2256
+ }
2257
+ }
2258
+ },
2259
+ "504": {
2260
+ "description": "OpenAI error",
2261
+ "content": {
2262
+ "application/json": {
2263
+ "schema": {
2264
+ "$ref": "#/components/schemas/Error"
2265
+ }
2266
+ }
2267
+ }
2268
+ }
2269
+ },
2270
+ "security": [
2271
+ {
2272
+ "fixtureKey": []
2273
+ }
2274
+ ],
2275
+ "x-mockingbird": {
2276
+ "parity": {
2277
+ "safe": true,
2278
+ "enabled": false,
2279
+ "reason": "Multipart/binary byte shapes are verified by served SDK and acceptance tests."
2280
+ }
2281
+ }
2282
+ }
2283
+ },
2284
+ "/v1/uploads": {
2285
+ "post": {
2286
+ "operationId": "CreateUpload",
2287
+ "summary": "CreateUpload",
2288
+ "parameters": [],
2289
+ "responses": {
2290
+ "200": {
2291
+ "description": "Success",
2292
+ "content": {
2293
+ "application/json": {
2294
+ "schema": {
2295
+ "$ref": "#/components/schemas/Upload"
2296
+ }
2297
+ }
2298
+ }
2299
+ },
2300
+ "400": {
2301
+ "description": "OpenAI error",
2302
+ "content": {
2303
+ "application/json": {
2304
+ "schema": {
2305
+ "$ref": "#/components/schemas/Error"
2306
+ }
2307
+ }
2308
+ }
2309
+ },
2310
+ "401": {
2311
+ "description": "OpenAI error",
2312
+ "content": {
2313
+ "application/json": {
2314
+ "schema": {
2315
+ "$ref": "#/components/schemas/Error"
2316
+ }
2317
+ }
2318
+ }
2319
+ },
2320
+ "403": {
2321
+ "description": "OpenAI error",
2322
+ "content": {
2323
+ "application/json": {
2324
+ "schema": {
2325
+ "$ref": "#/components/schemas/Error"
2326
+ }
2327
+ }
2328
+ }
2329
+ },
2330
+ "404": {
2331
+ "description": "OpenAI error",
2332
+ "content": {
2333
+ "application/json": {
2334
+ "schema": {
2335
+ "$ref": "#/components/schemas/Error"
2336
+ }
2337
+ }
2338
+ }
2339
+ },
2340
+ "408": {
2341
+ "description": "OpenAI error",
2342
+ "content": {
2343
+ "application/json": {
2344
+ "schema": {
2345
+ "$ref": "#/components/schemas/Error"
2346
+ }
2347
+ }
2348
+ }
2349
+ },
2350
+ "409": {
2351
+ "description": "OpenAI error",
2352
+ "content": {
2353
+ "application/json": {
2354
+ "schema": {
2355
+ "$ref": "#/components/schemas/Error"
2356
+ }
2357
+ }
2358
+ }
2359
+ },
2360
+ "413": {
2361
+ "description": "OpenAI error",
2362
+ "content": {
2363
+ "application/json": {
2364
+ "schema": {
2365
+ "$ref": "#/components/schemas/Error"
2366
+ }
2367
+ }
2368
+ }
2369
+ },
2370
+ "422": {
2371
+ "description": "OpenAI error",
2372
+ "content": {
2373
+ "application/json": {
2374
+ "schema": {
2375
+ "$ref": "#/components/schemas/Error"
2376
+ }
2377
+ }
2378
+ }
2379
+ },
2380
+ "429": {
2381
+ "description": "OpenAI error",
2382
+ "content": {
2383
+ "application/json": {
2384
+ "schema": {
2385
+ "$ref": "#/components/schemas/Error"
2386
+ }
2387
+ }
2388
+ }
2389
+ },
2390
+ "500": {
2391
+ "description": "OpenAI error",
2392
+ "content": {
2393
+ "application/json": {
2394
+ "schema": {
2395
+ "$ref": "#/components/schemas/Error"
2396
+ }
2397
+ }
2398
+ }
2399
+ },
2400
+ "502": {
2401
+ "description": "OpenAI error",
2402
+ "content": {
2403
+ "application/json": {
2404
+ "schema": {
2405
+ "$ref": "#/components/schemas/Error"
2406
+ }
2407
+ }
2408
+ }
2409
+ },
2410
+ "503": {
2411
+ "description": "OpenAI error",
2412
+ "content": {
2413
+ "application/json": {
2414
+ "schema": {
2415
+ "$ref": "#/components/schemas/Error"
2416
+ }
2417
+ }
2418
+ }
2419
+ },
2420
+ "504": {
2421
+ "description": "OpenAI error",
2422
+ "content": {
2423
+ "application/json": {
2424
+ "schema": {
2425
+ "$ref": "#/components/schemas/Error"
2426
+ }
2427
+ }
2428
+ }
2429
+ }
2430
+ },
2431
+ "security": [
2432
+ {
2433
+ "fixtureKey": []
2434
+ }
2435
+ ],
2436
+ "requestBody": {
2437
+ "required": true,
2438
+ "content": {
2439
+ "application/json": {
2440
+ "schema": {
2441
+ "type": "object",
2442
+ "properties": {
2443
+ "filename": {
2444
+ "type": "string"
2445
+ },
2446
+ "bytes": {
2447
+ "type": "integer",
2448
+ "minimum": 0
2449
+ },
2450
+ "mime_type": {
2451
+ "type": "string"
2452
+ },
2453
+ "purpose": {
2454
+ "type": "string",
2455
+ "enum": [
2456
+ "assistants",
2457
+ "batch",
2458
+ "fine-tune",
2459
+ "vision"
2460
+ ]
2461
+ },
2462
+ "expires_after": {
2463
+ "type": "object",
2464
+ "properties": {
2465
+ "anchor": {
2466
+ "const": "created_at"
2467
+ },
2468
+ "seconds": {
2469
+ "type": "integer",
2470
+ "minimum": 3600,
2471
+ "maximum": 2592000
2472
+ }
2473
+ },
2474
+ "required": [
2475
+ "anchor",
2476
+ "seconds"
2477
+ ],
2478
+ "additionalProperties": false
2479
+ }
2480
+ },
2481
+ "required": [
2482
+ "filename",
2483
+ "bytes",
2484
+ "mime_type",
2485
+ "purpose"
2486
+ ],
2487
+ "additionalProperties": false
2488
+ }
2489
+ }
2490
+ }
2491
+ },
2492
+ "x-mockingbird": {
2493
+ "parity": {
2494
+ "safe": false
2495
+ }
2496
+ }
2497
+ }
2498
+ },
2499
+ "/v1/uploads/{upload_id}/parts": {
2500
+ "post": {
2501
+ "operationId": "CreateUploadPart",
2502
+ "summary": "CreateUploadPart",
2503
+ "parameters": [
2504
+ {
2505
+ "name": "upload_id",
2506
+ "in": "path",
2507
+ "required": true,
2508
+ "schema": {
2509
+ "type": "string"
2510
+ }
2511
+ }
2512
+ ],
2513
+ "responses": {
2514
+ "200": {
2515
+ "description": "Success",
2516
+ "content": {
2517
+ "application/json": {
2518
+ "schema": {
2519
+ "$ref": "#/components/schemas/Part"
2520
+ }
2521
+ }
2522
+ }
2523
+ },
2524
+ "400": {
2525
+ "description": "OpenAI error",
2526
+ "content": {
2527
+ "application/json": {
2528
+ "schema": {
2529
+ "$ref": "#/components/schemas/Error"
2530
+ }
2531
+ }
2532
+ }
2533
+ },
2534
+ "401": {
2535
+ "description": "OpenAI error",
2536
+ "content": {
2537
+ "application/json": {
2538
+ "schema": {
2539
+ "$ref": "#/components/schemas/Error"
2540
+ }
2541
+ }
2542
+ }
2543
+ },
2544
+ "403": {
2545
+ "description": "OpenAI error",
2546
+ "content": {
2547
+ "application/json": {
2548
+ "schema": {
2549
+ "$ref": "#/components/schemas/Error"
2550
+ }
2551
+ }
2552
+ }
2553
+ },
2554
+ "404": {
2555
+ "description": "OpenAI error",
2556
+ "content": {
2557
+ "application/json": {
2558
+ "schema": {
2559
+ "$ref": "#/components/schemas/Error"
2560
+ }
2561
+ }
2562
+ }
2563
+ },
2564
+ "408": {
2565
+ "description": "OpenAI error",
2566
+ "content": {
2567
+ "application/json": {
2568
+ "schema": {
2569
+ "$ref": "#/components/schemas/Error"
2570
+ }
2571
+ }
2572
+ }
2573
+ },
2574
+ "409": {
2575
+ "description": "OpenAI error",
2576
+ "content": {
2577
+ "application/json": {
2578
+ "schema": {
2579
+ "$ref": "#/components/schemas/Error"
2580
+ }
2581
+ }
2582
+ }
2583
+ },
2584
+ "413": {
2585
+ "description": "OpenAI error",
2586
+ "content": {
2587
+ "application/json": {
2588
+ "schema": {
2589
+ "$ref": "#/components/schemas/Error"
2590
+ }
2591
+ }
2592
+ }
2593
+ },
2594
+ "422": {
2595
+ "description": "OpenAI error",
2596
+ "content": {
2597
+ "application/json": {
2598
+ "schema": {
2599
+ "$ref": "#/components/schemas/Error"
2600
+ }
2601
+ }
2602
+ }
2603
+ },
2604
+ "429": {
2605
+ "description": "OpenAI error",
2606
+ "content": {
2607
+ "application/json": {
2608
+ "schema": {
2609
+ "$ref": "#/components/schemas/Error"
2610
+ }
2611
+ }
2612
+ }
2613
+ },
2614
+ "500": {
2615
+ "description": "OpenAI error",
2616
+ "content": {
2617
+ "application/json": {
2618
+ "schema": {
2619
+ "$ref": "#/components/schemas/Error"
2620
+ }
2621
+ }
2622
+ }
2623
+ },
2624
+ "502": {
2625
+ "description": "OpenAI error",
2626
+ "content": {
2627
+ "application/json": {
2628
+ "schema": {
2629
+ "$ref": "#/components/schemas/Error"
2630
+ }
2631
+ }
2632
+ }
2633
+ },
2634
+ "503": {
2635
+ "description": "OpenAI error",
2636
+ "content": {
2637
+ "application/json": {
2638
+ "schema": {
2639
+ "$ref": "#/components/schemas/Error"
2640
+ }
2641
+ }
2642
+ }
2643
+ },
2644
+ "504": {
2645
+ "description": "OpenAI error",
2646
+ "content": {
2647
+ "application/json": {
2648
+ "schema": {
2649
+ "$ref": "#/components/schemas/Error"
2650
+ }
2651
+ }
2652
+ }
2653
+ }
2654
+ },
2655
+ "security": [
2656
+ {
2657
+ "fixtureKey": []
2658
+ }
2659
+ ],
2660
+ "x-mockingbird": {
2661
+ "parity": {
2662
+ "safe": false,
2663
+ "enabled": false,
2664
+ "reason": "Multipart/binary byte shapes are verified by served SDK and acceptance tests."
2665
+ }
2666
+ },
2667
+ "requestBody": {
2668
+ "required": true,
2669
+ "content": {
2670
+ "multipart/form-data": {
2671
+ "schema": {
2672
+ "type": "object",
2673
+ "properties": {
2674
+ "data": {
2675
+ "type": "string",
2676
+ "format": "binary"
2677
+ }
2678
+ },
2679
+ "required": [
2680
+ "data"
2681
+ ],
2682
+ "additionalProperties": false
2683
+ }
2684
+ }
2685
+ }
2686
+ }
2687
+ }
2688
+ },
2689
+ "/v1/uploads/{upload_id}/complete": {
2690
+ "post": {
2691
+ "operationId": "CompleteUpload",
2692
+ "summary": "CompleteUpload",
2693
+ "parameters": [
2694
+ {
2695
+ "name": "upload_id",
2696
+ "in": "path",
2697
+ "required": true,
2698
+ "schema": {
2699
+ "type": "string"
2700
+ }
2701
+ }
2702
+ ],
2703
+ "responses": {
2704
+ "200": {
2705
+ "description": "Success",
2706
+ "content": {
2707
+ "application/json": {
2708
+ "schema": {
2709
+ "$ref": "#/components/schemas/Upload"
2710
+ }
2711
+ }
2712
+ }
2713
+ },
2714
+ "400": {
2715
+ "description": "OpenAI error",
2716
+ "content": {
2717
+ "application/json": {
2718
+ "schema": {
2719
+ "$ref": "#/components/schemas/Error"
2720
+ }
2721
+ }
2722
+ }
2723
+ },
2724
+ "401": {
2725
+ "description": "OpenAI error",
2726
+ "content": {
2727
+ "application/json": {
2728
+ "schema": {
2729
+ "$ref": "#/components/schemas/Error"
2730
+ }
2731
+ }
2732
+ }
2733
+ },
2734
+ "403": {
2735
+ "description": "OpenAI error",
2736
+ "content": {
2737
+ "application/json": {
2738
+ "schema": {
2739
+ "$ref": "#/components/schemas/Error"
2740
+ }
2741
+ }
2742
+ }
2743
+ },
2744
+ "404": {
2745
+ "description": "OpenAI error",
2746
+ "content": {
2747
+ "application/json": {
2748
+ "schema": {
2749
+ "$ref": "#/components/schemas/Error"
2750
+ }
2751
+ }
2752
+ }
2753
+ },
2754
+ "408": {
2755
+ "description": "OpenAI error",
2756
+ "content": {
2757
+ "application/json": {
2758
+ "schema": {
2759
+ "$ref": "#/components/schemas/Error"
2760
+ }
2761
+ }
2762
+ }
2763
+ },
2764
+ "409": {
2765
+ "description": "OpenAI error",
2766
+ "content": {
2767
+ "application/json": {
2768
+ "schema": {
2769
+ "$ref": "#/components/schemas/Error"
2770
+ }
2771
+ }
2772
+ }
2773
+ },
2774
+ "413": {
2775
+ "description": "OpenAI error",
2776
+ "content": {
2777
+ "application/json": {
2778
+ "schema": {
2779
+ "$ref": "#/components/schemas/Error"
2780
+ }
2781
+ }
2782
+ }
2783
+ },
2784
+ "422": {
2785
+ "description": "OpenAI error",
2786
+ "content": {
2787
+ "application/json": {
2788
+ "schema": {
2789
+ "$ref": "#/components/schemas/Error"
2790
+ }
2791
+ }
2792
+ }
2793
+ },
2794
+ "429": {
2795
+ "description": "OpenAI error",
2796
+ "content": {
2797
+ "application/json": {
2798
+ "schema": {
2799
+ "$ref": "#/components/schemas/Error"
2800
+ }
2801
+ }
2802
+ }
2803
+ },
2804
+ "500": {
2805
+ "description": "OpenAI error",
2806
+ "content": {
2807
+ "application/json": {
2808
+ "schema": {
2809
+ "$ref": "#/components/schemas/Error"
2810
+ }
2811
+ }
2812
+ }
2813
+ },
2814
+ "502": {
2815
+ "description": "OpenAI error",
2816
+ "content": {
2817
+ "application/json": {
2818
+ "schema": {
2819
+ "$ref": "#/components/schemas/Error"
2820
+ }
2821
+ }
2822
+ }
2823
+ },
2824
+ "503": {
2825
+ "description": "OpenAI error",
2826
+ "content": {
2827
+ "application/json": {
2828
+ "schema": {
2829
+ "$ref": "#/components/schemas/Error"
2830
+ }
2831
+ }
2832
+ }
2833
+ },
2834
+ "504": {
2835
+ "description": "OpenAI error",
2836
+ "content": {
2837
+ "application/json": {
2838
+ "schema": {
2839
+ "$ref": "#/components/schemas/Error"
2840
+ }
2841
+ }
2842
+ }
2843
+ }
2844
+ },
2845
+ "security": [
2846
+ {
2847
+ "fixtureKey": []
2848
+ }
2849
+ ],
2850
+ "requestBody": {
2851
+ "required": true,
2852
+ "content": {
2853
+ "application/json": {
2854
+ "schema": {
2855
+ "type": "object",
2856
+ "properties": {
2857
+ "part_ids": {
2858
+ "type": "array",
2859
+ "items": {
2860
+ "type": "string"
2861
+ }
2862
+ },
2863
+ "md5": {
2864
+ "type": "string"
2865
+ }
2866
+ },
2867
+ "required": [
2868
+ "part_ids"
2869
+ ],
2870
+ "additionalProperties": false
2871
+ }
2872
+ }
2873
+ }
2874
+ },
2875
+ "x-mockingbird": {
2876
+ "parity": {
2877
+ "safe": false
2878
+ }
2879
+ }
2880
+ }
2881
+ },
2882
+ "/v1/uploads/{upload_id}/cancel": {
2883
+ "post": {
2884
+ "operationId": "CancelUpload",
2885
+ "summary": "CancelUpload",
2886
+ "parameters": [
2887
+ {
2888
+ "name": "upload_id",
2889
+ "in": "path",
2890
+ "required": true,
2891
+ "schema": {
2892
+ "type": "string"
2893
+ }
2894
+ }
2895
+ ],
2896
+ "responses": {
2897
+ "200": {
2898
+ "description": "Success",
2899
+ "content": {
2900
+ "application/json": {
2901
+ "schema": {
2902
+ "$ref": "#/components/schemas/Upload"
2903
+ }
2904
+ }
2905
+ }
2906
+ },
2907
+ "400": {
2908
+ "description": "OpenAI error",
2909
+ "content": {
2910
+ "application/json": {
2911
+ "schema": {
2912
+ "$ref": "#/components/schemas/Error"
2913
+ }
2914
+ }
2915
+ }
2916
+ },
2917
+ "401": {
2918
+ "description": "OpenAI error",
2919
+ "content": {
2920
+ "application/json": {
2921
+ "schema": {
2922
+ "$ref": "#/components/schemas/Error"
2923
+ }
2924
+ }
2925
+ }
2926
+ },
2927
+ "403": {
2928
+ "description": "OpenAI error",
2929
+ "content": {
2930
+ "application/json": {
2931
+ "schema": {
2932
+ "$ref": "#/components/schemas/Error"
2933
+ }
2934
+ }
2935
+ }
2936
+ },
2937
+ "404": {
2938
+ "description": "OpenAI error",
2939
+ "content": {
2940
+ "application/json": {
2941
+ "schema": {
2942
+ "$ref": "#/components/schemas/Error"
2943
+ }
2944
+ }
2945
+ }
2946
+ },
2947
+ "408": {
2948
+ "description": "OpenAI error",
2949
+ "content": {
2950
+ "application/json": {
2951
+ "schema": {
2952
+ "$ref": "#/components/schemas/Error"
2953
+ }
2954
+ }
2955
+ }
2956
+ },
2957
+ "409": {
2958
+ "description": "OpenAI error",
2959
+ "content": {
2960
+ "application/json": {
2961
+ "schema": {
2962
+ "$ref": "#/components/schemas/Error"
2963
+ }
2964
+ }
2965
+ }
2966
+ },
2967
+ "413": {
2968
+ "description": "OpenAI error",
2969
+ "content": {
2970
+ "application/json": {
2971
+ "schema": {
2972
+ "$ref": "#/components/schemas/Error"
2973
+ }
2974
+ }
2975
+ }
2976
+ },
2977
+ "422": {
2978
+ "description": "OpenAI error",
2979
+ "content": {
2980
+ "application/json": {
2981
+ "schema": {
2982
+ "$ref": "#/components/schemas/Error"
2983
+ }
2984
+ }
2985
+ }
2986
+ },
2987
+ "429": {
2988
+ "description": "OpenAI error",
2989
+ "content": {
2990
+ "application/json": {
2991
+ "schema": {
2992
+ "$ref": "#/components/schemas/Error"
2993
+ }
2994
+ }
2995
+ }
2996
+ },
2997
+ "500": {
2998
+ "description": "OpenAI error",
2999
+ "content": {
3000
+ "application/json": {
3001
+ "schema": {
3002
+ "$ref": "#/components/schemas/Error"
3003
+ }
3004
+ }
3005
+ }
3006
+ },
3007
+ "502": {
3008
+ "description": "OpenAI error",
3009
+ "content": {
3010
+ "application/json": {
3011
+ "schema": {
3012
+ "$ref": "#/components/schemas/Error"
3013
+ }
3014
+ }
3015
+ }
3016
+ },
3017
+ "503": {
3018
+ "description": "OpenAI error",
3019
+ "content": {
3020
+ "application/json": {
3021
+ "schema": {
3022
+ "$ref": "#/components/schemas/Error"
3023
+ }
3024
+ }
3025
+ }
3026
+ },
3027
+ "504": {
3028
+ "description": "OpenAI error",
3029
+ "content": {
3030
+ "application/json": {
3031
+ "schema": {
3032
+ "$ref": "#/components/schemas/Error"
3033
+ }
3034
+ }
3035
+ }
3036
+ }
3037
+ },
3038
+ "security": [
3039
+ {
3040
+ "fixtureKey": []
3041
+ }
3042
+ ],
3043
+ "x-mockingbird": {
3044
+ "parity": {
3045
+ "safe": false
3046
+ }
3047
+ }
3048
+ }
3049
+ }
3050
+ },
3051
+ "components": {
3052
+ "securitySchemes": {
3053
+ "fixtureKey": {
3054
+ "type": "http",
3055
+ "scheme": "bearer"
3056
+ }
3057
+ },
3058
+ "schemas": {
3059
+ "Error": {
3060
+ "type": "object",
3061
+ "properties": {
3062
+ "error": {
3063
+ "type": "object",
3064
+ "properties": {
3065
+ "message": {
3066
+ "type": "string"
3067
+ },
3068
+ "type": {
3069
+ "type": "string"
3070
+ },
3071
+ "param": {
3072
+ "type": [
3073
+ "string",
3074
+ "null"
3075
+ ]
3076
+ },
3077
+ "code": {
3078
+ "type": [
3079
+ "string",
3080
+ "null"
3081
+ ]
3082
+ }
3083
+ },
3084
+ "required": [
3085
+ "message",
3086
+ "type",
3087
+ "param",
3088
+ "code"
3089
+ ],
3090
+ "additionalProperties": false
3091
+ }
3092
+ },
3093
+ "required": [
3094
+ "error"
3095
+ ],
3096
+ "additionalProperties": false
3097
+ },
3098
+ "ToolCall": {
3099
+ "type": "object",
3100
+ "properties": {
3101
+ "id": {
3102
+ "type": "string",
3103
+ "x-mockingbird-resource": {
3104
+ "type": "toolCall",
3105
+ "identity": true
3106
+ }
3107
+ },
3108
+ "type": {
3109
+ "const": "function"
3110
+ },
3111
+ "function": {
3112
+ "type": "object",
3113
+ "properties": {
3114
+ "name": {
3115
+ "type": "string"
3116
+ },
3117
+ "arguments": {
3118
+ "type": "string"
3119
+ }
3120
+ },
3121
+ "required": [
3122
+ "name",
3123
+ "arguments"
3124
+ ],
3125
+ "additionalProperties": false
3126
+ }
3127
+ },
3128
+ "required": [
3129
+ "id",
3130
+ "type",
3131
+ "function"
3132
+ ],
3133
+ "additionalProperties": false
3134
+ },
3135
+ "Usage": {
3136
+ "type": "object",
3137
+ "properties": {
3138
+ "prompt_tokens": {
3139
+ "type": "integer",
3140
+ "minimum": 0
3141
+ },
3142
+ "completion_tokens": {
3143
+ "type": "integer",
3144
+ "minimum": 0
3145
+ },
3146
+ "total_tokens": {
3147
+ "type": "integer",
3148
+ "minimum": 0
3149
+ },
3150
+ "prompt_tokens_details": {
3151
+ "type": "object",
3152
+ "properties": {
3153
+ "cached_tokens": {
3154
+ "type": "integer",
3155
+ "minimum": 0
3156
+ }
3157
+ },
3158
+ "required": [
3159
+ "cached_tokens"
3160
+ ],
3161
+ "additionalProperties": false
3162
+ }
3163
+ },
3164
+ "required": [
3165
+ "prompt_tokens",
3166
+ "completion_tokens",
3167
+ "total_tokens",
3168
+ "prompt_tokens_details"
3169
+ ],
3170
+ "additionalProperties": false
3171
+ },
3172
+ "Chat": {
3173
+ "type": "object",
3174
+ "properties": {
3175
+ "id": {
3176
+ "type": "string",
3177
+ "x-mockingbird-resource": {
3178
+ "type": "chat",
3179
+ "identity": true
3180
+ }
3181
+ },
3182
+ "object": {
3183
+ "const": "chat.completion"
3184
+ },
3185
+ "created": {
3186
+ "type": "integer",
3187
+ "x-mockingbird-volatile": {
3188
+ "kind": "timestamp"
3189
+ }
3190
+ },
3191
+ "model": {
3192
+ "type": "string"
3193
+ },
3194
+ "choices": {
3195
+ "type": "array",
3196
+ "items": {
3197
+ "type": "object",
3198
+ "properties": {
3199
+ "index": {
3200
+ "type": "integer",
3201
+ "minimum": 0
3202
+ },
3203
+ "message": {
3204
+ "type": "object",
3205
+ "properties": {
3206
+ "role": {
3207
+ "const": "assistant"
3208
+ },
3209
+ "content": {
3210
+ "type": [
3211
+ "string",
3212
+ "null"
3213
+ ]
3214
+ },
3215
+ "tool_calls": {
3216
+ "type": "array",
3217
+ "items": {
3218
+ "$ref": "#/components/schemas/ToolCall"
3219
+ }
3220
+ },
3221
+ "refusal": {
3222
+ "type": [
3223
+ "string",
3224
+ "null"
3225
+ ]
3226
+ }
3227
+ },
3228
+ "required": [
3229
+ "role",
3230
+ "content"
3231
+ ],
3232
+ "additionalProperties": false
3233
+ },
3234
+ "finish_reason": {
3235
+ "type": "string",
3236
+ "enum": [
3237
+ "stop",
3238
+ "tool_calls",
3239
+ "length",
3240
+ "content_filter",
3241
+ "function_call"
3242
+ ]
3243
+ },
3244
+ "logprobs": {
3245
+ "type": "null"
3246
+ }
3247
+ },
3248
+ "required": [
3249
+ "index",
3250
+ "message",
3251
+ "finish_reason",
3252
+ "logprobs"
3253
+ ],
3254
+ "additionalProperties": false
3255
+ }
3256
+ },
3257
+ "usage": {
3258
+ "$ref": "#/components/schemas/Usage"
3259
+ },
3260
+ "system_fingerprint": {
3261
+ "type": "null"
3262
+ }
3263
+ },
3264
+ "required": [
3265
+ "id",
3266
+ "object",
3267
+ "created",
3268
+ "model",
3269
+ "choices",
3270
+ "usage"
3271
+ ],
3272
+ "additionalProperties": true
3273
+ },
3274
+ "Model": {
3275
+ "type": "object",
3276
+ "properties": {
3277
+ "id": {
3278
+ "type": "string",
3279
+ "x-mockingbird-resource": {
3280
+ "type": "model",
3281
+ "identity": true
3282
+ }
3283
+ },
3284
+ "object": {
3285
+ "const": "model"
3286
+ },
3287
+ "created": {
3288
+ "type": "integer",
3289
+ "x-mockingbird-volatile": {
3290
+ "kind": "timestamp"
3291
+ }
3292
+ },
3293
+ "owned_by": {
3294
+ "type": "string"
3295
+ }
3296
+ },
3297
+ "required": [
3298
+ "id",
3299
+ "object",
3300
+ "created",
3301
+ "owned_by"
3302
+ ],
3303
+ "additionalProperties": false
3304
+ },
3305
+ "File": {
3306
+ "type": "object",
3307
+ "properties": {
3308
+ "id": {
3309
+ "type": "string",
3310
+ "x-mockingbird-resource": {
3311
+ "type": "file",
3312
+ "identity": true
3313
+ }
3314
+ },
3315
+ "object": {
3316
+ "const": "file"
3317
+ },
3318
+ "bytes": {
3319
+ "type": "integer",
3320
+ "minimum": 0
3321
+ },
3322
+ "created_at": {
3323
+ "type": "integer",
3324
+ "x-mockingbird-volatile": {
3325
+ "kind": "timestamp"
3326
+ }
3327
+ },
3328
+ "filename": {
3329
+ "type": "string"
3330
+ },
3331
+ "purpose": {
3332
+ "type": "string"
3333
+ },
3334
+ "status": {
3335
+ "type": "string",
3336
+ "enum": [
3337
+ "uploaded",
3338
+ "processed",
3339
+ "error"
3340
+ ]
3341
+ },
3342
+ "expires_at": {
3343
+ "type": "integer",
3344
+ "x-mockingbird-volatile": {
3345
+ "kind": "timestamp"
3346
+ }
3347
+ }
3348
+ },
3349
+ "required": [
3350
+ "id",
3351
+ "object",
3352
+ "bytes",
3353
+ "created_at",
3354
+ "filename",
3355
+ "purpose",
3356
+ "status"
3357
+ ],
3358
+ "additionalProperties": false
3359
+ },
3360
+ "Upload": {
3361
+ "type": "object",
3362
+ "properties": {
3363
+ "id": {
3364
+ "type": "string",
3365
+ "x-mockingbird-resource": {
3366
+ "type": "upload",
3367
+ "identity": true
3368
+ }
3369
+ },
3370
+ "object": {
3371
+ "const": "upload"
3372
+ },
3373
+ "bytes": {
3374
+ "type": "integer",
3375
+ "minimum": 0
3376
+ },
3377
+ "created_at": {
3378
+ "type": "integer",
3379
+ "x-mockingbird-volatile": {
3380
+ "kind": "timestamp"
3381
+ }
3382
+ },
3383
+ "expires_at": {
3384
+ "type": "integer",
3385
+ "x-mockingbird-volatile": {
3386
+ "kind": "timestamp"
3387
+ }
3388
+ },
3389
+ "filename": {
3390
+ "type": "string"
3391
+ },
3392
+ "purpose": {
3393
+ "type": "string"
3394
+ },
3395
+ "status": {
3396
+ "type": "string",
3397
+ "enum": [
3398
+ "pending",
3399
+ "completed",
3400
+ "cancelled",
3401
+ "expired"
3402
+ ]
3403
+ },
3404
+ "file": {
3405
+ "$ref": "#/components/schemas/File"
3406
+ }
3407
+ },
3408
+ "required": [
3409
+ "id",
3410
+ "object",
3411
+ "bytes",
3412
+ "created_at",
3413
+ "expires_at",
3414
+ "filename",
3415
+ "purpose",
3416
+ "status"
3417
+ ],
3418
+ "additionalProperties": false
3419
+ },
3420
+ "Part": {
3421
+ "type": "object",
3422
+ "properties": {
3423
+ "id": {
3424
+ "type": "string",
3425
+ "x-mockingbird-resource": {
3426
+ "type": "part",
3427
+ "identity": true
3428
+ }
3429
+ },
3430
+ "object": {
3431
+ "const": "upload.part"
3432
+ },
3433
+ "created_at": {
3434
+ "type": "integer",
3435
+ "x-mockingbird-volatile": {
3436
+ "kind": "timestamp"
3437
+ }
3438
+ },
3439
+ "upload_id": {
3440
+ "type": "string"
3441
+ }
3442
+ },
3443
+ "required": [
3444
+ "id",
3445
+ "object",
3446
+ "created_at",
3447
+ "upload_id"
3448
+ ],
3449
+ "additionalProperties": false
3450
+ },
3451
+ "Embeddings": {
3452
+ "type": "object",
3453
+ "properties": {
3454
+ "object": {
3455
+ "const": "list"
3456
+ },
3457
+ "model": {
3458
+ "type": "string"
3459
+ },
3460
+ "data": {
3461
+ "type": "array",
3462
+ "items": {
3463
+ "type": "object",
3464
+ "properties": {
3465
+ "object": {
3466
+ "const": "embedding"
3467
+ },
3468
+ "index": {
3469
+ "type": "integer",
3470
+ "minimum": 0
3471
+ },
3472
+ "embedding": {
3473
+ "oneOf": [
3474
+ {
3475
+ "type": "array",
3476
+ "items": {
3477
+ "type": "number"
3478
+ }
3479
+ },
3480
+ {
3481
+ "type": "string"
3482
+ }
3483
+ ]
3484
+ }
3485
+ },
3486
+ "required": [
3487
+ "object",
3488
+ "index",
3489
+ "embedding"
3490
+ ],
3491
+ "additionalProperties": false
3492
+ }
3493
+ },
3494
+ "usage": {
3495
+ "type": "object",
3496
+ "properties": {
3497
+ "prompt_tokens": {
3498
+ "type": "integer",
3499
+ "minimum": 0
3500
+ },
3501
+ "total_tokens": {
3502
+ "type": "integer",
3503
+ "minimum": 0
3504
+ }
3505
+ },
3506
+ "required": [
3507
+ "prompt_tokens",
3508
+ "total_tokens"
3509
+ ],
3510
+ "additionalProperties": false
3511
+ }
3512
+ },
3513
+ "required": [
3514
+ "object",
3515
+ "model",
3516
+ "data",
3517
+ "usage"
3518
+ ],
3519
+ "additionalProperties": false
3520
+ },
3521
+ "DeletedChat": {
3522
+ "type": "object",
3523
+ "properties": {
3524
+ "id": {
3525
+ "type": "string"
3526
+ },
3527
+ "object": {
3528
+ "const": "chat.completion.deleted"
3529
+ },
3530
+ "deleted": {
3531
+ "const": true
3532
+ }
3533
+ },
3534
+ "required": [
3535
+ "id",
3536
+ "object",
3537
+ "deleted"
3538
+ ],
3539
+ "additionalProperties": false
3540
+ },
3541
+ "DeletedFile": {
3542
+ "type": "object",
3543
+ "properties": {
3544
+ "id": {
3545
+ "type": "string"
3546
+ },
3547
+ "object": {
3548
+ "const": "file"
3549
+ },
3550
+ "deleted": {
3551
+ "const": true
3552
+ }
3553
+ },
3554
+ "required": [
3555
+ "id",
3556
+ "object",
3557
+ "deleted"
3558
+ ],
3559
+ "additionalProperties": false
3560
+ },
3561
+ "Chats": {
3562
+ "type": "object",
3563
+ "properties": {
3564
+ "object": {
3565
+ "const": "list"
3566
+ },
3567
+ "data": {
3568
+ "type": "array",
3569
+ "items": {
3570
+ "$ref": "#/components/schemas/Chat"
3571
+ }
3572
+ },
3573
+ "first_id": {
3574
+ "type": [
3575
+ "string",
3576
+ "null"
3577
+ ]
3578
+ },
3579
+ "last_id": {
3580
+ "type": [
3581
+ "string",
3582
+ "null"
3583
+ ]
3584
+ },
3585
+ "has_more": {
3586
+ "type": "boolean"
3587
+ }
3588
+ },
3589
+ "required": [
3590
+ "object",
3591
+ "data",
3592
+ "first_id",
3593
+ "last_id",
3594
+ "has_more"
3595
+ ],
3596
+ "additionalProperties": false
3597
+ },
3598
+ "Files": {
3599
+ "type": "object",
3600
+ "properties": {
3601
+ "object": {
3602
+ "const": "list"
3603
+ },
3604
+ "data": {
3605
+ "type": "array",
3606
+ "items": {
3607
+ "$ref": "#/components/schemas/File"
3608
+ }
3609
+ },
3610
+ "first_id": {
3611
+ "type": [
3612
+ "string",
3613
+ "null"
3614
+ ]
3615
+ },
3616
+ "last_id": {
3617
+ "type": [
3618
+ "string",
3619
+ "null"
3620
+ ]
3621
+ },
3622
+ "has_more": {
3623
+ "type": "boolean"
3624
+ }
3625
+ },
3626
+ "required": [
3627
+ "object",
3628
+ "data",
3629
+ "first_id",
3630
+ "last_id",
3631
+ "has_more"
3632
+ ],
3633
+ "additionalProperties": false
3634
+ },
3635
+ "Models": {
3636
+ "type": "object",
3637
+ "properties": {
3638
+ "object": {
3639
+ "const": "list"
3640
+ },
3641
+ "data": {
3642
+ "type": "array",
3643
+ "items": {
3644
+ "$ref": "#/components/schemas/Model"
3645
+ }
3646
+ }
3647
+ },
3648
+ "required": [
3649
+ "object",
3650
+ "data"
3651
+ ],
3652
+ "additionalProperties": false
3653
+ }
3654
+ }
3655
+ }
3656
+ }