@oxy.so/contracts 4.2.0 → 4.4.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/cjs/.tsbuildinfo +1 -1
- package/dist/cjs/index.js +72 -4
- package/dist/cjs/inference/catalogue.js +105 -2
- package/dist/cjs/inference/money.js +23 -0
- package/dist/cjs/inference/realtime.js +826 -0
- package/dist/cjs/inference/request.js +34 -11
- package/dist/cjs/inference/streamEvents.js +7 -1
- package/dist/cjs/inference/version.js +1 -1
- package/dist/cjs/stickers.js +151 -0
- package/dist/esm/.tsbuildinfo +1 -1
- package/dist/esm/index.js +6 -2
- package/dist/esm/inference/catalogue.js +104 -1
- package/dist/esm/inference/money.js +23 -0
- package/dist/esm/inference/realtime.js +822 -0
- package/dist/esm/inference/request.js +34 -11
- package/dist/esm/inference/streamEvents.js +7 -1
- package/dist/esm/inference/version.js +1 -1
- package/dist/esm/stickers.js +148 -0
- package/dist/types/.tsbuildinfo +1 -1
- package/dist/types/index.d.ts +7 -4
- package/dist/types/inference/catalogue.d.ts +299 -10
- package/dist/types/inference/entitlement.d.ts +6 -6
- package/dist/types/inference/inbox.d.ts +2 -2
- package/dist/types/inference/modelDocumentation.d.ts +146 -2
- package/dist/types/inference/money.d.ts +28 -8
- package/dist/types/inference/priceVersion.d.ts +12 -12
- package/dist/types/inference/realtime.d.ts +8012 -0
- package/dist/types/inference/request.d.ts +51 -0
- package/dist/types/inference/routingPolicy.d.ts +7 -7
- package/dist/types/inference/streamEvents.d.ts +28 -16
- package/dist/types/inference/usage.d.ts +28 -28
- package/dist/types/inference/version.d.ts +1 -1
- package/dist/types/stickers.d.ts +1049 -0
- package/package.json +1 -1
|
@@ -326,7 +326,7 @@ export declare const modelGpaiDocumentationSchema: z.ZodEffects<z.ZodObject<{
|
|
|
326
326
|
export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
327
327
|
displayName: z.ZodString;
|
|
328
328
|
description: z.ZodOptional<z.ZodString>;
|
|
329
|
-
capabilities: z.ZodObject<{
|
|
329
|
+
capabilities: z.ZodEffects<z.ZodObject<{
|
|
330
330
|
inputModalities: z.ZodArray<z.ZodEnum<["text", "image", "audio", "video", "embedding"]>, "many">;
|
|
331
331
|
outputModalities: z.ZodArray<z.ZodEnum<["text", "image", "audio", "video", "embedding"]>, "many">;
|
|
332
332
|
tools: z.ZodBoolean;
|
|
@@ -339,6 +339,17 @@ export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
|
339
339
|
promptCaching: z.ZodBoolean;
|
|
340
340
|
maxContextTokens: z.ZodNumber;
|
|
341
341
|
maxOutputTokens: z.ZodNumber;
|
|
342
|
+
apiFormats: z.ZodOptional<z.ZodArray<z.ZodEnum<["responses", "chat_completions", "embeddings", "images_generations", "audio_transcriptions", "audio_speech", "rerank", "batches"]>, "many">>;
|
|
343
|
+
realtime: z.ZodOptional<z.ZodObject<{
|
|
344
|
+
transports: z.ZodArray<z.ZodEnum<["websocket"]>, "many">;
|
|
345
|
+
sessionKinds: z.ZodArray<z.ZodEnum<["conversation", "transcription", "translation"]>, "many">;
|
|
346
|
+
}, "strict", z.ZodTypeAny, {
|
|
347
|
+
transports: "websocket"[];
|
|
348
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
349
|
+
}, {
|
|
350
|
+
transports: "websocket"[];
|
|
351
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
352
|
+
}>>;
|
|
342
353
|
}, "strict", z.ZodTypeAny, {
|
|
343
354
|
tools: boolean;
|
|
344
355
|
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
@@ -352,6 +363,11 @@ export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
|
352
363
|
promptCaching: boolean;
|
|
353
364
|
maxContextTokens: number;
|
|
354
365
|
maxOutputTokens: number;
|
|
366
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
367
|
+
realtime?: {
|
|
368
|
+
transports: "websocket"[];
|
|
369
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
370
|
+
} | undefined;
|
|
355
371
|
}, {
|
|
356
372
|
tools: boolean;
|
|
357
373
|
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
@@ -365,6 +381,47 @@ export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
|
365
381
|
maxContextTokens: number;
|
|
366
382
|
maxOutputTokens: number;
|
|
367
383
|
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
384
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
385
|
+
realtime?: {
|
|
386
|
+
transports: "websocket"[];
|
|
387
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
388
|
+
} | undefined;
|
|
389
|
+
}>, {
|
|
390
|
+
tools: boolean;
|
|
391
|
+
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
392
|
+
outputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
393
|
+
parallelToolCalls: boolean;
|
|
394
|
+
structuredOutput: boolean;
|
|
395
|
+
jsonMode: boolean;
|
|
396
|
+
reasoning: boolean;
|
|
397
|
+
reasoningEfforts: ("low" | "medium" | "high")[];
|
|
398
|
+
streaming: boolean;
|
|
399
|
+
promptCaching: boolean;
|
|
400
|
+
maxContextTokens: number;
|
|
401
|
+
maxOutputTokens: number;
|
|
402
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
403
|
+
realtime?: {
|
|
404
|
+
transports: "websocket"[];
|
|
405
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
406
|
+
} | undefined;
|
|
407
|
+
}, {
|
|
408
|
+
tools: boolean;
|
|
409
|
+
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
410
|
+
outputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
411
|
+
parallelToolCalls: boolean;
|
|
412
|
+
structuredOutput: boolean;
|
|
413
|
+
jsonMode: boolean;
|
|
414
|
+
reasoning: boolean;
|
|
415
|
+
streaming: boolean;
|
|
416
|
+
promptCaching: boolean;
|
|
417
|
+
maxContextTokens: number;
|
|
418
|
+
maxOutputTokens: number;
|
|
419
|
+
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
420
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
421
|
+
realtime?: {
|
|
422
|
+
transports: "websocket"[];
|
|
423
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
424
|
+
} | undefined;
|
|
368
425
|
}>;
|
|
369
426
|
knowledgeCutoff: z.ZodOptional<z.ZodString>;
|
|
370
427
|
releasedOn: z.ZodOptional<z.ZodString>;
|
|
@@ -383,6 +440,11 @@ export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
|
383
440
|
promptCaching: boolean;
|
|
384
441
|
maxContextTokens: number;
|
|
385
442
|
maxOutputTokens: number;
|
|
443
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
444
|
+
realtime?: {
|
|
445
|
+
transports: "websocket"[];
|
|
446
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
447
|
+
} | undefined;
|
|
386
448
|
};
|
|
387
449
|
description?: string | undefined;
|
|
388
450
|
knowledgeCutoff?: string | undefined;
|
|
@@ -402,6 +464,11 @@ export declare const modelLineDeclarationSchema: z.ZodObject<{
|
|
|
402
464
|
maxContextTokens: number;
|
|
403
465
|
maxOutputTokens: number;
|
|
404
466
|
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
467
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
468
|
+
realtime?: {
|
|
469
|
+
transports: "websocket"[];
|
|
470
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
471
|
+
} | undefined;
|
|
405
472
|
};
|
|
406
473
|
description?: string | undefined;
|
|
407
474
|
knowledgeCutoff?: string | undefined;
|
|
@@ -954,7 +1021,7 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
954
1021
|
model: z.ZodObject<{
|
|
955
1022
|
displayName: z.ZodString;
|
|
956
1023
|
description: z.ZodOptional<z.ZodString>;
|
|
957
|
-
capabilities: z.ZodObject<{
|
|
1024
|
+
capabilities: z.ZodEffects<z.ZodObject<{
|
|
958
1025
|
inputModalities: z.ZodArray<z.ZodEnum<["text", "image", "audio", "video", "embedding"]>, "many">;
|
|
959
1026
|
outputModalities: z.ZodArray<z.ZodEnum<["text", "image", "audio", "video", "embedding"]>, "many">;
|
|
960
1027
|
tools: z.ZodBoolean;
|
|
@@ -967,6 +1034,17 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
967
1034
|
promptCaching: z.ZodBoolean;
|
|
968
1035
|
maxContextTokens: z.ZodNumber;
|
|
969
1036
|
maxOutputTokens: z.ZodNumber;
|
|
1037
|
+
apiFormats: z.ZodOptional<z.ZodArray<z.ZodEnum<["responses", "chat_completions", "embeddings", "images_generations", "audio_transcriptions", "audio_speech", "rerank", "batches"]>, "many">>;
|
|
1038
|
+
realtime: z.ZodOptional<z.ZodObject<{
|
|
1039
|
+
transports: z.ZodArray<z.ZodEnum<["websocket"]>, "many">;
|
|
1040
|
+
sessionKinds: z.ZodArray<z.ZodEnum<["conversation", "transcription", "translation"]>, "many">;
|
|
1041
|
+
}, "strict", z.ZodTypeAny, {
|
|
1042
|
+
transports: "websocket"[];
|
|
1043
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1044
|
+
}, {
|
|
1045
|
+
transports: "websocket"[];
|
|
1046
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1047
|
+
}>>;
|
|
970
1048
|
}, "strict", z.ZodTypeAny, {
|
|
971
1049
|
tools: boolean;
|
|
972
1050
|
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
@@ -980,6 +1058,11 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
980
1058
|
promptCaching: boolean;
|
|
981
1059
|
maxContextTokens: number;
|
|
982
1060
|
maxOutputTokens: number;
|
|
1061
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1062
|
+
realtime?: {
|
|
1063
|
+
transports: "websocket"[];
|
|
1064
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1065
|
+
} | undefined;
|
|
983
1066
|
}, {
|
|
984
1067
|
tools: boolean;
|
|
985
1068
|
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
@@ -993,6 +1076,47 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
993
1076
|
maxContextTokens: number;
|
|
994
1077
|
maxOutputTokens: number;
|
|
995
1078
|
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
1079
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1080
|
+
realtime?: {
|
|
1081
|
+
transports: "websocket"[];
|
|
1082
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1083
|
+
} | undefined;
|
|
1084
|
+
}>, {
|
|
1085
|
+
tools: boolean;
|
|
1086
|
+
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
1087
|
+
outputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
1088
|
+
parallelToolCalls: boolean;
|
|
1089
|
+
structuredOutput: boolean;
|
|
1090
|
+
jsonMode: boolean;
|
|
1091
|
+
reasoning: boolean;
|
|
1092
|
+
reasoningEfforts: ("low" | "medium" | "high")[];
|
|
1093
|
+
streaming: boolean;
|
|
1094
|
+
promptCaching: boolean;
|
|
1095
|
+
maxContextTokens: number;
|
|
1096
|
+
maxOutputTokens: number;
|
|
1097
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1098
|
+
realtime?: {
|
|
1099
|
+
transports: "websocket"[];
|
|
1100
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1101
|
+
} | undefined;
|
|
1102
|
+
}, {
|
|
1103
|
+
tools: boolean;
|
|
1104
|
+
inputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
1105
|
+
outputModalities: ("image" | "embedding" | "text" | "audio" | "video")[];
|
|
1106
|
+
parallelToolCalls: boolean;
|
|
1107
|
+
structuredOutput: boolean;
|
|
1108
|
+
jsonMode: boolean;
|
|
1109
|
+
reasoning: boolean;
|
|
1110
|
+
streaming: boolean;
|
|
1111
|
+
promptCaching: boolean;
|
|
1112
|
+
maxContextTokens: number;
|
|
1113
|
+
maxOutputTokens: number;
|
|
1114
|
+
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
1115
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1116
|
+
realtime?: {
|
|
1117
|
+
transports: "websocket"[];
|
|
1118
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1119
|
+
} | undefined;
|
|
996
1120
|
}>;
|
|
997
1121
|
knowledgeCutoff: z.ZodOptional<z.ZodString>;
|
|
998
1122
|
releasedOn: z.ZodOptional<z.ZodString>;
|
|
@@ -1011,6 +1135,11 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
1011
1135
|
promptCaching: boolean;
|
|
1012
1136
|
maxContextTokens: number;
|
|
1013
1137
|
maxOutputTokens: number;
|
|
1138
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1139
|
+
realtime?: {
|
|
1140
|
+
transports: "websocket"[];
|
|
1141
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1142
|
+
} | undefined;
|
|
1014
1143
|
};
|
|
1015
1144
|
description?: string | undefined;
|
|
1016
1145
|
knowledgeCutoff?: string | undefined;
|
|
@@ -1030,6 +1159,11 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
1030
1159
|
maxContextTokens: number;
|
|
1031
1160
|
maxOutputTokens: number;
|
|
1032
1161
|
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
1162
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1163
|
+
realtime?: {
|
|
1164
|
+
transports: "websocket"[];
|
|
1165
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1166
|
+
} | undefined;
|
|
1033
1167
|
};
|
|
1034
1168
|
description?: string | undefined;
|
|
1035
1169
|
knowledgeCutoff?: string | undefined;
|
|
@@ -1052,6 +1186,11 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
1052
1186
|
promptCaching: boolean;
|
|
1053
1187
|
maxContextTokens: number;
|
|
1054
1188
|
maxOutputTokens: number;
|
|
1189
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1190
|
+
realtime?: {
|
|
1191
|
+
transports: "websocket"[];
|
|
1192
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1193
|
+
} | undefined;
|
|
1055
1194
|
};
|
|
1056
1195
|
description?: string | undefined;
|
|
1057
1196
|
knowledgeCutoff?: string | undefined;
|
|
@@ -1143,6 +1282,11 @@ export declare const modelReleaseIngestionRequestSchema: z.ZodObject<{
|
|
|
1143
1282
|
maxContextTokens: number;
|
|
1144
1283
|
maxOutputTokens: number;
|
|
1145
1284
|
reasoningEfforts?: ("low" | "medium" | "high")[] | undefined;
|
|
1285
|
+
apiFormats?: ("embeddings" | "responses" | "chat_completions" | "images_generations" | "audio_transcriptions" | "audio_speech" | "rerank" | "batches")[] | undefined;
|
|
1286
|
+
realtime?: {
|
|
1287
|
+
transports: "websocket"[];
|
|
1288
|
+
sessionKinds: ("conversation" | "transcription" | "translation")[];
|
|
1289
|
+
} | undefined;
|
|
1146
1290
|
};
|
|
1147
1291
|
description?: string | undefined;
|
|
1148
1292
|
knowledgeCutoff?: string | undefined;
|
|
@@ -105,6 +105,26 @@ export declare const moneySchema: z.ZodObject<{
|
|
|
105
105
|
* output_tokens = completion_tokens - completion_tokens_details.reasoning_tokens
|
|
106
106
|
* ```
|
|
107
107
|
*
|
|
108
|
+
* **Audio tokens are siblings too** (added in contract set 3.2.0). A model that
|
|
109
|
+
* consumes or produces audio AS TOKENS — OpenAI's audio chat and Realtime
|
|
110
|
+
* models — reports them inside the same totals, and they are priced several
|
|
111
|
+
* times higher than text tokens, so folding them into `input_tokens` would
|
|
112
|
+
* under-charge by exactly the audio. They are subtracted out the same way:
|
|
113
|
+
*
|
|
114
|
+
* ```text
|
|
115
|
+
* cached_audio_input_tokens = prompt_tokens_details.cached_tokens_details.audio_tokens
|
|
116
|
+
* audio_input_tokens = prompt_tokens_details.audio_tokens - cached_audio_input_tokens
|
|
117
|
+
* input_tokens = prompt_tokens - (text AND audio cached) - audio_input_tokens
|
|
118
|
+
* audio_output_tokens = completion_tokens_details.audio_tokens
|
|
119
|
+
* output_tokens = completion_tokens - reasoning_tokens - audio_output_tokens
|
|
120
|
+
* ```
|
|
121
|
+
*
|
|
122
|
+
* `audio_input_milliseconds` and `audio_output_milliseconds` remain the units
|
|
123
|
+
* for audio metered by DURATION (file transcription, speech synthesis). A
|
|
124
|
+
* report carries one reading of a given audio, never both: the same audio
|
|
125
|
+
* reported as tokens and as milliseconds is the double charge this rule exists
|
|
126
|
+
* to prevent.
|
|
127
|
+
*
|
|
108
128
|
* No refinement in this package can enforce it, and saying so is part of the
|
|
109
129
|
* rule: a nested report and a disjoint one are the same four non-negative
|
|
110
130
|
* integers, so no predicate over a single report can tell them apart. The two
|
|
@@ -126,20 +146,20 @@ export declare const moneySchema: z.ZodObject<{
|
|
|
126
146
|
* and the "units are integers" rule holds for every modality instead of holding
|
|
127
147
|
* for tokens and being quietly broken by audio.
|
|
128
148
|
*/
|
|
129
|
-
export declare const USAGE_UNITS: readonly ["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"];
|
|
130
|
-
export declare const usageUnitSchema: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"]>;
|
|
149
|
+
export declare const USAGE_UNITS: readonly ["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"];
|
|
150
|
+
export declare const usageUnitSchema: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"]>;
|
|
131
151
|
/**
|
|
132
152
|
* A metered quantity of ONE unit. Never money — a quantity carries no price and
|
|
133
153
|
* no currency, so a consumer cannot mistake a token count for an amount owed.
|
|
134
154
|
*/
|
|
135
155
|
export declare const usageQuantitySchema: z.ZodObject<{
|
|
136
|
-
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"]>;
|
|
156
|
+
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"]>;
|
|
137
157
|
quantity: z.ZodNumber;
|
|
138
158
|
}, "strict", z.ZodTypeAny, {
|
|
139
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
159
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
140
160
|
quantity: number;
|
|
141
161
|
}, {
|
|
142
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
162
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
143
163
|
quantity: number;
|
|
144
164
|
}>;
|
|
145
165
|
/**
|
|
@@ -161,19 +181,19 @@ export declare const usageSourceSchema: z.ZodEnum<["provider_reported", "oxy_mea
|
|
|
161
181
|
* every customer reads it).
|
|
162
182
|
*/
|
|
163
183
|
export declare const unitPriceSchema: z.ZodObject<{
|
|
164
|
-
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"]>;
|
|
184
|
+
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"]>;
|
|
165
185
|
amount: z.ZodBranded<z.ZodString, "ExactDecimal">;
|
|
166
186
|
per: z.ZodNumber;
|
|
167
187
|
currency: z.ZodString;
|
|
168
188
|
}, "strict", z.ZodTypeAny, {
|
|
169
189
|
currency: string;
|
|
170
190
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
171
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
191
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
172
192
|
per: number;
|
|
173
193
|
}, {
|
|
174
194
|
currency: string;
|
|
175
195
|
amount: string;
|
|
176
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
196
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
177
197
|
per: number;
|
|
178
198
|
}>;
|
|
179
199
|
export type CurrencyCode = z.infer<typeof currencyCodeSchema>;
|
|
@@ -41,19 +41,19 @@ export declare const priceVersionSchema: z.ZodEffects<z.ZodObject<{
|
|
|
41
41
|
provider: z.ZodString;
|
|
42
42
|
currency: z.ZodString;
|
|
43
43
|
unitPrices: z.ZodArray<z.ZodObject<{
|
|
44
|
-
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"]>;
|
|
44
|
+
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"]>;
|
|
45
45
|
amount: z.ZodBranded<z.ZodString, "ExactDecimal">;
|
|
46
46
|
per: z.ZodNumber;
|
|
47
47
|
currency: z.ZodString;
|
|
48
48
|
}, "strict", z.ZodTypeAny, {
|
|
49
49
|
currency: string;
|
|
50
50
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
51
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
51
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
52
52
|
per: number;
|
|
53
53
|
}, {
|
|
54
54
|
currency: string;
|
|
55
55
|
amount: string;
|
|
56
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
56
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
57
57
|
per: number;
|
|
58
58
|
}>, "many">;
|
|
59
59
|
effectiveFrom: z.ZodString;
|
|
@@ -73,7 +73,7 @@ export declare const priceVersionSchema: z.ZodEffects<z.ZodObject<{
|
|
|
73
73
|
unitPrices: {
|
|
74
74
|
currency: string;
|
|
75
75
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
76
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
76
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
77
77
|
per: number;
|
|
78
78
|
}[];
|
|
79
79
|
effectiveFrom: string;
|
|
@@ -90,7 +90,7 @@ export declare const priceVersionSchema: z.ZodEffects<z.ZodObject<{
|
|
|
90
90
|
unitPrices: {
|
|
91
91
|
currency: string;
|
|
92
92
|
amount: string;
|
|
93
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
93
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
94
94
|
per: number;
|
|
95
95
|
}[];
|
|
96
96
|
effectiveFrom: string;
|
|
@@ -107,7 +107,7 @@ export declare const priceVersionSchema: z.ZodEffects<z.ZodObject<{
|
|
|
107
107
|
unitPrices: {
|
|
108
108
|
currency: string;
|
|
109
109
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
110
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
110
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
111
111
|
per: number;
|
|
112
112
|
}[];
|
|
113
113
|
effectiveFrom: string;
|
|
@@ -124,7 +124,7 @@ export declare const priceVersionSchema: z.ZodEffects<z.ZodObject<{
|
|
|
124
124
|
unitPrices: {
|
|
125
125
|
currency: string;
|
|
126
126
|
amount: string;
|
|
127
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
127
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
128
128
|
per: number;
|
|
129
129
|
}[];
|
|
130
130
|
effectiveFrom: string;
|
|
@@ -143,19 +143,19 @@ export declare const priceSnapshotSchema: z.ZodObject<{
|
|
|
143
143
|
priceVersionId: z.ZodString;
|
|
144
144
|
currency: z.ZodString;
|
|
145
145
|
unitPrices: z.ZodArray<z.ZodObject<{
|
|
146
|
-
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings"]>;
|
|
146
|
+
unit: z.ZodEnum<["input_tokens", "cached_input_tokens", "output_tokens", "reasoning_tokens", "requests", "images", "audio_input_milliseconds", "audio_output_milliseconds", "video_milliseconds", "characters", "embeddings", "audio_input_tokens", "cached_audio_input_tokens", "audio_output_tokens"]>;
|
|
147
147
|
amount: z.ZodBranded<z.ZodString, "ExactDecimal">;
|
|
148
148
|
per: z.ZodNumber;
|
|
149
149
|
currency: z.ZodString;
|
|
150
150
|
}, "strict", z.ZodTypeAny, {
|
|
151
151
|
currency: string;
|
|
152
152
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
153
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
153
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
154
154
|
per: number;
|
|
155
155
|
}, {
|
|
156
156
|
currency: string;
|
|
157
157
|
amount: string;
|
|
158
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
158
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
159
159
|
per: number;
|
|
160
160
|
}>, "many">;
|
|
161
161
|
}, "strict", z.ZodTypeAny, {
|
|
@@ -164,7 +164,7 @@ export declare const priceSnapshotSchema: z.ZodObject<{
|
|
|
164
164
|
unitPrices: {
|
|
165
165
|
currency: string;
|
|
166
166
|
amount: string & z.BRAND<"ExactDecimal">;
|
|
167
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
167
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
168
168
|
per: number;
|
|
169
169
|
}[];
|
|
170
170
|
}, {
|
|
@@ -173,7 +173,7 @@ export declare const priceSnapshotSchema: z.ZodObject<{
|
|
|
173
173
|
unitPrices: {
|
|
174
174
|
currency: string;
|
|
175
175
|
amount: string;
|
|
176
|
-
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings";
|
|
176
|
+
unit: "input_tokens" | "cached_input_tokens" | "output_tokens" | "reasoning_tokens" | "requests" | "images" | "audio_input_milliseconds" | "audio_output_milliseconds" | "video_milliseconds" | "characters" | "embeddings" | "audio_input_tokens" | "cached_audio_input_tokens" | "audio_output_tokens";
|
|
177
177
|
per: number;
|
|
178
178
|
}[];
|
|
179
179
|
}>;
|