@effect/ai-openrouter 0.7.1 → 0.8.1

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.
@@ -20,7 +20,7 @@ export declare class CacheControlEphemeral extends CacheControlEphemeral_base {
20
20
  declare const ReasoningDetailSummaryType_base: S.Literal<["reasoning.summary"]>;
21
21
  export declare class ReasoningDetailSummaryType extends ReasoningDetailSummaryType_base {
22
22
  }
23
- declare const ReasoningDetailSummaryFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1", "google-gemini-v1"]>;
23
+ declare const ReasoningDetailSummaryFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1"]>;
24
24
  export declare class ReasoningDetailSummaryFormat extends ReasoningDetailSummaryFormat_base {
25
25
  }
26
26
  declare const ReasoningDetailSummary_base: S.Class<ReasoningDetailSummary, {
@@ -56,7 +56,7 @@ declare const ReasoningDetailSummary_base: S.Class<ReasoningDetailSummary, {
56
56
  } & {
57
57
  readonly id?: string | undefined;
58
58
  } & {
59
- readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | "google-gemini-v1" | undefined;
59
+ readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | undefined;
60
60
  } & {
61
61
  readonly index?: number | undefined;
62
62
  }, {}, {}>;
@@ -68,7 +68,7 @@ export declare class ReasoningDetailSummary extends ReasoningDetailSummary_base
68
68
  declare const ReasoningDetailEncryptedType_base: S.Literal<["reasoning.encrypted"]>;
69
69
  export declare class ReasoningDetailEncryptedType extends ReasoningDetailEncryptedType_base {
70
70
  }
71
- declare const ReasoningDetailEncryptedFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1", "google-gemini-v1"]>;
71
+ declare const ReasoningDetailEncryptedFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1"]>;
72
72
  export declare class ReasoningDetailEncryptedFormat extends ReasoningDetailEncryptedFormat_base {
73
73
  }
74
74
  declare const ReasoningDetailEncrypted_base: S.Class<ReasoningDetailEncrypted, {
@@ -102,7 +102,7 @@ declare const ReasoningDetailEncrypted_base: S.Class<ReasoningDetailEncrypted, {
102
102
  } & {
103
103
  readonly id?: string | undefined;
104
104
  } & {
105
- readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | "google-gemini-v1" | undefined;
105
+ readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | undefined;
106
106
  } & {
107
107
  readonly index?: number | undefined;
108
108
  } & {
@@ -116,7 +116,7 @@ export declare class ReasoningDetailEncrypted extends ReasoningDetailEncrypted_b
116
116
  declare const ReasoningDetailTextType_base: S.Literal<["reasoning.text"]>;
117
117
  export declare class ReasoningDetailTextType extends ReasoningDetailTextType_base {
118
118
  }
119
- declare const ReasoningDetailTextFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1", "google-gemini-v1"]>;
119
+ declare const ReasoningDetailTextFormat_base: S.Literal<["unknown", "openai-responses-v1", "anthropic-claude-v1"]>;
120
120
  export declare class ReasoningDetailTextFormat extends ReasoningDetailTextFormat_base {
121
121
  }
122
122
  declare const ReasoningDetailText_base: S.Class<ReasoningDetailText, {
@@ -160,7 +160,7 @@ declare const ReasoningDetailText_base: S.Class<ReasoningDetailText, {
160
160
  } & {
161
161
  readonly id?: string | undefined;
162
162
  } & {
163
- readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | "google-gemini-v1" | undefined;
163
+ readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | undefined;
164
164
  } & {
165
165
  readonly index?: number | undefined;
166
166
  } & {
@@ -371,7 +371,7 @@ declare const OpenResponsesReasoning_base: S.Class<OpenResponsesReasoning, {
371
371
  } & {
372
372
  readonly id: string;
373
373
  } & {
374
- readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | "google-gemini-v1" | "xai-responses-v1" | undefined;
374
+ readonly format?: "unknown" | "openai-responses-v1" | "anthropic-claude-v1" | "xai-responses-v1" | "google-gemini-v1" | undefined;
375
375
  } & {
376
376
  readonly signature?: string | undefined;
377
377
  } & {
@@ -1368,7 +1368,7 @@ declare const OpenResponsesResponseText_base: S.Class<OpenResponsesResponseText,
1368
1368
  */
1369
1369
  export declare class OpenResponsesResponseText extends OpenResponsesResponseText_base {
1370
1370
  }
1371
- declare const OpenAIResponsesReasoningEffort_base: S.Literal<["high", "medium", "low", "minimal", "none"]>;
1371
+ declare const OpenAIResponsesReasoningEffort_base: S.Literal<["xhigh", "high", "medium", "low", "minimal", "none"]>;
1372
1372
  export declare class OpenAIResponsesReasoningEffort extends OpenAIResponsesReasoningEffort_base {
1373
1373
  }
1374
1374
  declare const ReasoningSummaryVerbosity_base: S.Literal<["auto", "concise", "detailed"]>;
@@ -1407,7 +1407,7 @@ declare const OpenResponsesReasoningConfig_base: S.Class<OpenResponsesReasoningC
1407
1407
  } & {
1408
1408
  readonly enabled?: boolean | undefined;
1409
1409
  } & {
1410
- readonly effort?: "high" | "low" | "medium" | "minimal" | "none" | undefined;
1410
+ readonly effort?: "high" | "low" | "medium" | "xhigh" | "minimal" | "none" | undefined;
1411
1411
  }, {}, {}>;
1412
1412
  export declare class OpenResponsesReasoningConfig extends OpenResponsesReasoningConfig_base {
1413
1413
  }
@@ -1433,10 +1433,8 @@ export declare class OpenAIResponsesPrompt extends OpenAIResponsesPrompt_base {
1433
1433
  declare const OpenAIResponsesIncludable_base: S.Literal<["file_search_call.results", "message.input_image.image_url", "computer_call_output.output.image_url", "reasoning.encrypted_content", "code_interpreter_call.outputs"]>;
1434
1434
  export declare class OpenAIResponsesIncludable extends OpenAIResponsesIncludable_base {
1435
1435
  }
1436
- declare const OpenResponsesRequestServiceTierEnum_base: S.Literal<["auto", "default", "flex", "scale", "priority"]>;
1437
- export declare class OpenResponsesRequestServiceTierEnum extends OpenResponsesRequestServiceTierEnum_base {
1438
- }
1439
- export declare class OpenResponsesRequestServiceTier extends OpenResponsesRequestServiceTierEnum {
1436
+ declare const OpenResponsesRequestServiceTier_base: S.Literal<["auto"]>;
1437
+ export declare class OpenResponsesRequestServiceTier extends OpenResponsesRequestServiceTier_base {
1440
1438
  }
1441
1439
  declare const OpenResponsesRequestTruncationEnum_base: S.Literal<["auto", "disabled"]>;
1442
1440
  export declare class OpenResponsesRequestTruncationEnum extends OpenResponsesRequestTruncationEnum_base {
@@ -1452,23 +1450,77 @@ declare const DataCollection_base: S.Literal<["deny", "allow"]>;
1452
1450
  */
1453
1451
  export declare class DataCollection extends DataCollection_base {
1454
1452
  }
1455
- declare const ProviderName_base: S.Literal<["AI21", "AionLabs", "Alibaba", "Amazon Bedrock", "Anthropic", "Arcee", "AtlasCloud", "Avian", "Azure", "BaseTen", "Black Forest Labs", "Cerebras", "Chutes", "Cirrascale", "Clarifai", "Cloudflare", "Cohere", "Crusoe", "DeepInfra", "DeepSeek", "Featherless", "Fireworks", "Friendli", "GMICloud", "Google", "Google AI Studio", "Groq", "Hyperbolic", "Inception", "InferenceNet", "Infermatic", "Inflection", "Liquid", "Mancer 2", "Minimax", "ModelRun", "Mistral", "Modular", "Moonshot AI", "Morph", "NCompass", "Nebius", "NextBit", "Novita", "Nvidia", "OpenAI", "OpenInference", "Parasail", "Perplexity", "Phala", "Relace", "SambaNova", "SiliconFlow", "Stealth", "Switchpoint", "Targon", "Together", "Venice", "WandB", "xAI", "Z.AI", "FakeProvider"]>;
1453
+ declare const ProviderName_base: S.Literal<["AI21", "AionLabs", "Alibaba", "Amazon Bedrock", "Amazon Nova", "Anthropic", "Arcee AI", "AtlasCloud", "Avian", "Azure", "BaseTen", "BytePlus", "Black Forest Labs", "Cerebras", "Chutes", "Cirrascale", "Clarifai", "Cloudflare", "Cohere", "Crusoe", "DeepInfra", "DeepSeek", "Featherless", "Fireworks", "Friendli", "GMICloud", "GoPomelo", "Google", "Google AI Studio", "Groq", "Hyperbolic", "Inception", "InferenceNet", "Infermatic", "Inflection", "Liquid", "Mara", "Mancer 2", "Minimax", "ModelRun", "Mistral", "Modular", "Moonshot AI", "Morph", "NCompass", "Nebius", "NextBit", "Novita", "Nvidia", "OpenAI", "OpenInference", "Parasail", "Perplexity", "Phala", "Relace", "SambaNova", "SiliconFlow", "Sourceful", "Stealth", "StreamLake", "Switchpoint", "Targon", "Together", "Venice", "WandB", "Xiaomi", "xAI", "Z.AI", "FakeProvider"]>;
1456
1454
  export declare class ProviderName extends ProviderName_base {
1457
1455
  }
1458
1456
  declare const Quantization_base: S.Literal<["int4", "int8", "fp4", "fp6", "fp8", "fp16", "bf16", "fp32", "unknown"]>;
1459
1457
  export declare class Quantization extends Quantization_base {
1460
1458
  }
1461
1459
  declare const ProviderSort_base: S.Literal<["price", "throughput", "latency"]>;
1460
+ export declare class ProviderSort extends ProviderSort_base {
1461
+ }
1462
+ declare const ProviderSortConfigPartitionEnum_base: S.Literal<["model", "none"]>;
1463
+ export declare class ProviderSortConfigPartitionEnum extends ProviderSortConfigPartitionEnum_base {
1464
+ }
1465
+ declare const ProviderSortConfig_base: S.Class<ProviderSortConfig, {
1466
+ by: S.optionalWith<typeof ProviderSort, {
1467
+ nullable: true;
1468
+ }>;
1469
+ partition: S.optionalWith<typeof ProviderSortConfigPartitionEnum, {
1470
+ nullable: true;
1471
+ }>;
1472
+ }, S.Struct.Encoded<{
1473
+ by: S.optionalWith<typeof ProviderSort, {
1474
+ nullable: true;
1475
+ }>;
1476
+ partition: S.optionalWith<typeof ProviderSortConfigPartitionEnum, {
1477
+ nullable: true;
1478
+ }>;
1479
+ }>, never, {
1480
+ readonly by?: "price" | "throughput" | "latency" | undefined;
1481
+ } & {
1482
+ readonly partition?: "none" | "model" | undefined;
1483
+ }, {}, {}>;
1484
+ export declare class ProviderSortConfig extends ProviderSortConfig_base {
1485
+ }
1462
1486
  /**
1463
- * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
1487
+ * A value in string format that is a large number
1464
1488
  */
1465
- export declare class ProviderSort extends ProviderSort_base {
1489
+ export declare class BigNumberUnion extends S.String {
1490
+ }
1491
+ declare const WebSearchEngine_base: S.Literal<["native", "exa"]>;
1492
+ /**
1493
+ * The search engine to use for web search.
1494
+ */
1495
+ export declare class WebSearchEngine extends WebSearchEngine_base {
1496
+ }
1497
+ declare const PDFParserEngine_base: S.Literal<["mistral-ocr", "pdf-text", "native"]>;
1498
+ /**
1499
+ * The engine to use for parsing PDF files.
1500
+ */
1501
+ export declare class PDFParserEngine extends PDFParserEngine_base {
1502
+ }
1503
+ declare const PDFParserOptions_base: S.Class<PDFParserOptions, {
1504
+ engine: S.optionalWith<typeof PDFParserEngine, {
1505
+ nullable: true;
1506
+ }>;
1507
+ }, S.Struct.Encoded<{
1508
+ engine: S.optionalWith<typeof PDFParserEngine, {
1509
+ nullable: true;
1510
+ }>;
1511
+ }>, never, {
1512
+ readonly engine?: "native" | "mistral-ocr" | "pdf-text" | undefined;
1513
+ }, {}, {}>;
1514
+ /**
1515
+ * Options for PDF parsing.
1516
+ */
1517
+ export declare class PDFParserOptions extends PDFParserOptions_base {
1466
1518
  }
1467
- declare const BigNumberUnion_base: S.Union<[typeof S.Number, typeof S.String, typeof S.Number]>;
1519
+ declare const OpenResponsesRequestRoute_base: S.Literal<["fallback", "sort"]>;
1468
1520
  /**
1469
- * A value in string or number format that is a large number
1521
+ * **DEPRECATED** Use providers.sort.partition instead. Backwards-compatible alias for providers.sort.partition. Accepts legacy values: "fallback" (maps to "model"), "sort" (maps to "none").
1470
1522
  */
1471
- export declare class BigNumberUnion extends BigNumberUnion_base {
1523
+ export declare class OpenResponsesRequestRoute extends OpenResponsesRequestRoute_base {
1472
1524
  }
1473
1525
  declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1474
1526
  input: S.optionalWith<typeof OpenResponsesInput, {
@@ -1531,11 +1583,13 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1531
1583
  safety_identifier: S.optionalWith<typeof S.String, {
1532
1584
  nullable: true;
1533
1585
  }>;
1534
- store: S.optionalWith<typeof S.Boolean, {
1586
+ store: S.optionalWith<S.Literal<[false]>, {
1535
1587
  nullable: true;
1588
+ default: () => false;
1536
1589
  }>;
1537
1590
  service_tier: S.optionalWith<typeof OpenResponsesRequestServiceTier, {
1538
1591
  nullable: true;
1592
+ default: () => "auto";
1539
1593
  }>;
1540
1594
  truncation: S.optionalWith<typeof OpenResponsesRequestTruncation, {
1541
1595
  nullable: true;
@@ -1601,7 +1655,10 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1601
1655
  quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
1602
1656
  nullable: true;
1603
1657
  }>;
1604
- sort: S.optionalWith<typeof ProviderSort, {
1658
+ /**
1659
+ * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
1660
+ */
1661
+ sort: S.optionalWith<S.Union<[typeof ProviderSort, typeof ProviderSortConfig]>, {
1605
1662
  nullable: true;
1606
1663
  }>;
1607
1664
  /**
@@ -1626,6 +1683,30 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1626
1683
  }>, {
1627
1684
  nullable: true;
1628
1685
  }>;
1686
+ /**
1687
+ * Preferred minimum throughput (in tokens per second). Endpoints below this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
1688
+ */
1689
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
1690
+ nullable: true;
1691
+ }>;
1692
+ /**
1693
+ * Preferred maximum latency (in seconds). Endpoints above this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
1694
+ */
1695
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
1696
+ nullable: true;
1697
+ }>;
1698
+ /**
1699
+ * **DEPRECATED** Use preferred_min_throughput instead. Backwards-compatible alias for preferred_min_throughput.
1700
+ */
1701
+ min_throughput: S.optionalWith<typeof S.Number, {
1702
+ nullable: true;
1703
+ }>;
1704
+ /**
1705
+ * **DEPRECATED** Use preferred_max_latency instead. Backwards-compatible alias for preferred_max_latency.
1706
+ */
1707
+ max_latency: S.optionalWith<typeof S.Number, {
1708
+ nullable: true;
1709
+ }>;
1629
1710
  }>, {
1630
1711
  nullable: true;
1631
1712
  }>;
@@ -1636,36 +1717,61 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1636
1717
  id: S.Literal<["moderation"]>;
1637
1718
  }>, S.Struct<{
1638
1719
  id: S.Literal<["web"]>;
1720
+ /**
1721
+ * Set to false to disable the web-search plugin for this request. Defaults to true.
1722
+ */
1723
+ enabled: S.optionalWith<typeof S.Boolean, {
1724
+ nullable: true;
1725
+ }>;
1639
1726
  max_results: S.optionalWith<typeof S.Number, {
1640
1727
  nullable: true;
1641
1728
  }>;
1642
1729
  search_prompt: S.optionalWith<typeof S.String, {
1643
1730
  nullable: true;
1644
1731
  }>;
1645
- engine: S.optionalWith<S.Literal<["native", "exa"]>, {
1732
+ engine: S.optionalWith<typeof WebSearchEngine, {
1646
1733
  nullable: true;
1647
1734
  }>;
1648
1735
  }>, S.Struct<{
1649
1736
  id: S.Literal<["file-parser"]>;
1650
- max_files: S.optionalWith<typeof S.Number, {
1737
+ /**
1738
+ * Set to false to disable the file-parser plugin for this request. Defaults to true.
1739
+ */
1740
+ enabled: S.optionalWith<typeof S.Boolean, {
1651
1741
  nullable: true;
1652
1742
  }>;
1653
- pdf: S.optionalWith<S.Struct<{
1654
- engine: S.optionalWith<S.Literal<["mistral-ocr", "pdf-text", "native"]>, {
1655
- nullable: true;
1656
- }>;
1657
- }>, {
1743
+ pdf: S.optionalWith<typeof PDFParserOptions, {
1744
+ nullable: true;
1745
+ }>;
1746
+ }>, S.Struct<{
1747
+ id: S.Literal<["response-healing"]>;
1748
+ /**
1749
+ * Set to false to disable the response-healing plugin for this request. Defaults to true.
1750
+ */
1751
+ enabled: S.optionalWith<typeof S.Boolean, {
1658
1752
  nullable: true;
1659
1753
  }>;
1660
1754
  }>]>>, {
1661
1755
  nullable: true;
1662
1756
  }>;
1757
+ /**
1758
+ * **DEPRECATED** Use providers.sort.partition instead. Backwards-compatible alias for providers.sort.partition. Accepts legacy values: "fallback" (maps to "model"), "sort" (maps to "none").
1759
+ */
1760
+ route: S.optionalWith<typeof OpenResponsesRequestRoute, {
1761
+ nullable: true;
1762
+ }>;
1663
1763
  /**
1664
1764
  * A unique identifier representing your end-user, which helps distinguish between different users of your app. This allows your app to identify specific users in case of abuse reports, preventing your entire app from being affected by the actions of individual users. Maximum of 128 characters.
1665
1765
  */
1666
1766
  user: S.optionalWith<S.filter<typeof S.String>, {
1667
1767
  nullable: true;
1668
1768
  }>;
1769
+ /**
1770
+ * A unique identifier for grouping related requests (e.g., a conversation or agent workflow) for observability. If provided in both the request body and the x-session-id header, the body value takes precedence. Maximum of 128 characters.
1771
+ */
1772
+ session_id: S.optionalWith<S.filter<typeof S.String>, {
1773
+ nullable: true;
1774
+ }>;
1669
1775
  }, S.Struct.Encoded<{
1670
1776
  input: S.optionalWith<typeof OpenResponsesInput, {
1671
1777
  nullable: true;
@@ -1727,11 +1833,13 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1727
1833
  safety_identifier: S.optionalWith<typeof S.String, {
1728
1834
  nullable: true;
1729
1835
  }>;
1730
- store: S.optionalWith<typeof S.Boolean, {
1836
+ store: S.optionalWith<S.Literal<[false]>, {
1731
1837
  nullable: true;
1838
+ default: () => false;
1732
1839
  }>;
1733
1840
  service_tier: S.optionalWith<typeof OpenResponsesRequestServiceTier, {
1734
1841
  nullable: true;
1842
+ default: () => "auto";
1735
1843
  }>;
1736
1844
  truncation: S.optionalWith<typeof OpenResponsesRequestTruncation, {
1737
1845
  nullable: true;
@@ -1797,7 +1905,10 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1797
1905
  quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
1798
1906
  nullable: true;
1799
1907
  }>;
1800
- sort: S.optionalWith<typeof ProviderSort, {
1908
+ /**
1909
+ * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
1910
+ */
1911
+ sort: S.optionalWith<S.Union<[typeof ProviderSort, typeof ProviderSortConfig]>, {
1801
1912
  nullable: true;
1802
1913
  }>;
1803
1914
  /**
@@ -1822,6 +1933,30 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1822
1933
  }>, {
1823
1934
  nullable: true;
1824
1935
  }>;
1936
+ /**
1937
+ * Preferred minimum throughput (in tokens per second). Endpoints below this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
1938
+ */
1939
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
1940
+ nullable: true;
1941
+ }>;
1942
+ /**
1943
+ * Preferred maximum latency (in seconds). Endpoints above this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
1944
+ */
1945
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
1946
+ nullable: true;
1947
+ }>;
1948
+ /**
1949
+ * **DEPRECATED** Use preferred_min_throughput instead. Backwards-compatible alias for preferred_min_throughput.
1950
+ */
1951
+ min_throughput: S.optionalWith<typeof S.Number, {
1952
+ nullable: true;
1953
+ }>;
1954
+ /**
1955
+ * **DEPRECATED** Use preferred_max_latency instead. Backwards-compatible alias for preferred_max_latency.
1956
+ */
1957
+ max_latency: S.optionalWith<typeof S.Number, {
1958
+ nullable: true;
1959
+ }>;
1825
1960
  }>, {
1826
1961
  nullable: true;
1827
1962
  }>;
@@ -1832,40 +1967,67 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1832
1967
  id: S.Literal<["moderation"]>;
1833
1968
  }>, S.Struct<{
1834
1969
  id: S.Literal<["web"]>;
1970
+ /**
1971
+ * Set to false to disable the web-search plugin for this request. Defaults to true.
1972
+ */
1973
+ enabled: S.optionalWith<typeof S.Boolean, {
1974
+ nullable: true;
1975
+ }>;
1835
1976
  max_results: S.optionalWith<typeof S.Number, {
1836
1977
  nullable: true;
1837
1978
  }>;
1838
1979
  search_prompt: S.optionalWith<typeof S.String, {
1839
1980
  nullable: true;
1840
1981
  }>;
1841
- engine: S.optionalWith<S.Literal<["native", "exa"]>, {
1982
+ engine: S.optionalWith<typeof WebSearchEngine, {
1842
1983
  nullable: true;
1843
1984
  }>;
1844
1985
  }>, S.Struct<{
1845
1986
  id: S.Literal<["file-parser"]>;
1846
- max_files: S.optionalWith<typeof S.Number, {
1987
+ /**
1988
+ * Set to false to disable the file-parser plugin for this request. Defaults to true.
1989
+ */
1990
+ enabled: S.optionalWith<typeof S.Boolean, {
1847
1991
  nullable: true;
1848
1992
  }>;
1849
- pdf: S.optionalWith<S.Struct<{
1850
- engine: S.optionalWith<S.Literal<["mistral-ocr", "pdf-text", "native"]>, {
1851
- nullable: true;
1852
- }>;
1853
- }>, {
1993
+ pdf: S.optionalWith<typeof PDFParserOptions, {
1994
+ nullable: true;
1995
+ }>;
1996
+ }>, S.Struct<{
1997
+ id: S.Literal<["response-healing"]>;
1998
+ /**
1999
+ * Set to false to disable the response-healing plugin for this request. Defaults to true.
2000
+ */
2001
+ enabled: S.optionalWith<typeof S.Boolean, {
1854
2002
  nullable: true;
1855
2003
  }>;
1856
2004
  }>]>>, {
1857
2005
  nullable: true;
1858
2006
  }>;
2007
+ /**
2008
+ * **DEPRECATED** Use providers.sort.partition instead. Backwards-compatible alias for providers.sort.partition. Accepts legacy values: "fallback" (maps to "model"), "sort" (maps to "none").
2009
+ */
2010
+ route: S.optionalWith<typeof OpenResponsesRequestRoute, {
2011
+ nullable: true;
2012
+ }>;
1859
2013
  /**
1860
2014
  * A unique identifier representing your end-user, which helps distinguish between different users of your app. This allows your app to identify specific users in case of abuse reports, preventing your entire app from being affected by the actions of individual users. Maximum of 128 characters.
1861
2015
  */
1862
2016
  user: S.optionalWith<S.filter<typeof S.String>, {
1863
2017
  nullable: true;
1864
2018
  }>;
2019
+ /**
2020
+ * A unique identifier for grouping related requests (e.g., a conversation or agent workflow) for observability. If provided in both the request body and the x-session-id header, the body value takes precedence. Maximum of 128 characters.
2021
+ */
2022
+ session_id: S.optionalWith<S.filter<typeof S.String>, {
2023
+ nullable: true;
2024
+ }>;
1865
2025
  }>, never, {
1866
2026
  readonly text?: OpenResponsesResponseText | undefined;
1867
2027
  } & {
1868
2028
  readonly reasoning?: OpenResponsesReasoningConfig | undefined;
2029
+ } & {
2030
+ readonly model?: string | undefined;
1869
2031
  } & {
1870
2032
  readonly input?: string | readonly (OpenResponsesReasoning | OpenResponsesEasyInputMessage | OpenResponsesInputMessageItem | OpenResponsesFunctionToolCall | OpenResponsesFunctionCallOutput | ResponsesOutputMessage | ResponsesOutputItemReasoning | ResponsesOutputItemFunctionCall | ResponsesWebSearchCallOutput | ResponsesOutputItemFileSearchCall | ResponsesImageGenerationCall)[] | undefined;
1871
2033
  } & {
@@ -1885,8 +2047,6 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1885
2047
  } | undefined;
1886
2048
  } & {
1887
2049
  readonly parallel_tool_calls?: boolean | undefined;
1888
- } & {
1889
- readonly model?: string | undefined;
1890
2050
  } & {
1891
2051
  readonly models?: readonly string[] | undefined;
1892
2052
  } & {
@@ -1910,16 +2070,16 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1910
2070
  } & {
1911
2071
  readonly safety_identifier?: string | undefined;
1912
2072
  } & {
1913
- readonly store?: boolean | undefined;
2073
+ readonly store?: false | undefined;
1914
2074
  } & {
1915
- readonly service_tier?: "default" | "auto" | "flex" | "scale" | "priority" | undefined;
2075
+ readonly service_tier?: "auto" | undefined;
1916
2076
  } & {
1917
2077
  readonly truncation?: "auto" | "disabled" | undefined;
1918
2078
  } & {
1919
2079
  readonly stream?: boolean | undefined;
1920
2080
  } & {
1921
2081
  readonly provider?: {
1922
- readonly sort?: "price" | "throughput" | "latency" | undefined;
2082
+ readonly sort?: "price" | "throughput" | "latency" | ProviderSortConfig | undefined;
1923
2083
  readonly allow_fallbacks?: boolean | undefined;
1924
2084
  readonly require_parameters?: boolean | undefined;
1925
2085
  readonly data_collection?: "deny" | "allow" | undefined;
@@ -1930,30 +2090,40 @@ declare const OpenResponsesRequest_base: S.Class<OpenResponsesRequest, {
1930
2090
  readonly ignore?: readonly string[] | undefined;
1931
2091
  readonly quantizations?: readonly ("unknown" | "int4" | "int8" | "fp4" | "fp6" | "fp8" | "fp16" | "bf16" | "fp32")[] | undefined;
1932
2092
  readonly max_price?: {
1933
- readonly prompt?: string | number | undefined;
1934
- readonly completion?: string | number | undefined;
1935
- readonly image?: string | number | undefined;
1936
- readonly audio?: string | number | undefined;
1937
- readonly request?: string | number | undefined;
2093
+ readonly prompt?: string | undefined;
2094
+ readonly completion?: string | undefined;
2095
+ readonly image?: string | undefined;
2096
+ readonly audio?: string | undefined;
2097
+ readonly request?: string | undefined;
1938
2098
  } | undefined;
2099
+ readonly preferred_min_throughput?: number | undefined;
2100
+ readonly preferred_max_latency?: number | undefined;
2101
+ readonly min_throughput?: number | undefined;
2102
+ readonly max_latency?: number | undefined;
1939
2103
  } | undefined;
1940
2104
  } & {
1941
2105
  readonly plugins?: readonly ({
1942
2106
  readonly id: "moderation";
1943
2107
  } | {
1944
2108
  readonly id: "web";
2109
+ readonly enabled?: boolean | undefined;
2110
+ readonly engine?: "native" | "exa" | undefined;
1945
2111
  readonly max_results?: number | undefined;
1946
2112
  readonly search_prompt?: string | undefined;
1947
- readonly engine?: "native" | "exa" | undefined;
1948
2113
  } | {
1949
2114
  readonly id: "file-parser";
1950
- readonly max_files?: number | undefined;
1951
- readonly pdf?: {
1952
- readonly engine?: "native" | "mistral-ocr" | "pdf-text" | undefined;
1953
- } | undefined;
2115
+ readonly enabled?: boolean | undefined;
2116
+ readonly pdf?: PDFParserOptions | undefined;
2117
+ } | {
2118
+ readonly id: "response-healing";
2119
+ readonly enabled?: boolean | undefined;
1954
2120
  })[] | undefined;
2121
+ } & {
2122
+ readonly route?: "sort" | "fallback" | undefined;
1955
2123
  } & {
1956
2124
  readonly user?: string | undefined;
2125
+ } & {
2126
+ readonly session_id?: string | undefined;
1957
2127
  }, {}, {}>;
1958
2128
  /**
1959
2129
  * Request schema for Responses endpoint
@@ -2292,7 +2462,7 @@ declare const OpenAIResponsesReasoningConfig_base: S.Class<OpenAIResponsesReason
2292
2462
  }>, never, {
2293
2463
  readonly summary?: "auto" | "concise" | "detailed" | undefined;
2294
2464
  } & {
2295
- readonly effort?: "high" | "low" | "medium" | "minimal" | "none" | undefined;
2465
+ readonly effort?: "high" | "low" | "medium" | "xhigh" | "minimal" | "none" | undefined;
2296
2466
  }, {}, {}>;
2297
2467
  export declare class OpenAIResponsesReasoningConfig extends OpenAIResponsesReasoningConfig_base {
2298
2468
  }
@@ -2475,6 +2645,8 @@ declare const OpenResponsesNonStreamingResponse_base: S.Class<OpenResponsesNonSt
2475
2645
  readonly output: readonly (OutputMessage | OutputItemReasoning | OutputItemFunctionCall | OutputItemWebSearchCall | OutputItemFileSearchCall | OutputItemImageGenerationCall)[];
2476
2646
  } & {
2477
2647
  readonly output_text?: string | undefined;
2648
+ } & {
2649
+ readonly model: string;
2478
2650
  } & {
2479
2651
  readonly instructions: string | readonly (OutputMessage | OutputItemImageGenerationCall | {
2480
2652
  readonly type?: "message" | undefined;
@@ -2514,8 +2686,6 @@ declare const OpenResponsesNonStreamingResponse_base: S.Class<OpenResponsesNonSt
2514
2686
  };
2515
2687
  } & {
2516
2688
  readonly parallel_tool_calls: boolean;
2517
- } & {
2518
- readonly model: string;
2519
2689
  } & {
2520
2690
  readonly max_output_tokens?: number | undefined;
2521
2691
  } & {
@@ -2535,7 +2705,7 @@ declare const OpenResponsesNonStreamingResponse_base: S.Class<OpenResponsesNonSt
2535
2705
  } & {
2536
2706
  readonly store?: boolean | undefined;
2537
2707
  } & {
2538
- readonly service_tier?: "default" | "auto" | "flex" | "scale" | "priority" | undefined;
2708
+ readonly service_tier?: "default" | "auto" | "flex" | "priority" | "scale" | undefined;
2539
2709
  } & {
2540
2710
  readonly truncation?: "auto" | "disabled" | undefined;
2541
2711
  } & {
@@ -3332,7 +3502,18 @@ declare const ForbiddenResponse_base: S.Class<ForbiddenResponse, {
3332
3502
  */
3333
3503
  export declare class ForbiddenResponse extends ForbiddenResponse_base {
3334
3504
  }
3335
- declare const GetCredits200_base: S.Record$<typeof S.String, typeof S.Unknown>;
3505
+ declare const GetCredits200_base: S.Struct<{
3506
+ data: S.Struct<{
3507
+ /**
3508
+ * Total credits purchased
3509
+ */
3510
+ total_credits: typeof S.Number;
3511
+ /**
3512
+ * Total credits used
3513
+ */
3514
+ total_usage: typeof S.Number;
3515
+ }>;
3516
+ }>;
3336
3517
  /**
3337
3518
  * Total credits purchased and used
3338
3519
  */
@@ -3394,110 +3575,285 @@ export declare class CreateCoinbaseCharge200 extends CreateCoinbaseCharge200_bas
3394
3575
  declare const CreateEmbeddingsRequestEncodingFormat_base: S.Literal<["float", "base64"]>;
3395
3576
  export declare class CreateEmbeddingsRequestEncodingFormat extends CreateEmbeddingsRequestEncodingFormat_base {
3396
3577
  }
3397
- declare const CreateEmbeddingsRequest_base: S.Class<CreateEmbeddingsRequest, {
3398
- input: S.Union<[typeof S.String, S.Array$<typeof S.String>, S.Array$<typeof S.Number>, S.Array$<S.Array$<typeof S.Number>>, S.Array$<S.Struct<{
3399
- content: S.Array$<S.Union<[S.Struct<{
3400
- type: S.Literal<["text"]>;
3401
- text: typeof S.String;
3402
- }>, S.Struct<{
3403
- type: S.Literal<["image_url"]>;
3404
- image_url: S.Struct<{
3405
- url: typeof S.String;
3406
- }>;
3407
- }>]>>;
3408
- }>>]>;
3409
- model: typeof S.String;
3410
- encoding_format: S.optionalWith<typeof CreateEmbeddingsRequestEncodingFormat, {
3578
+ declare const ProviderPreferencesSort_base: S.Literal<["price", "throughput", "latency"]>;
3579
+ /**
3580
+ * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
3581
+ */
3582
+ export declare class ProviderPreferencesSort extends ProviderPreferencesSort_base {
3583
+ }
3584
+ declare const ProviderPreferences_base: S.Class<ProviderPreferences, {
3585
+ /**
3586
+ * Whether to allow backup providers to serve requests
3587
+ * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
3588
+ * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
3589
+ */
3590
+ allow_fallbacks: S.optionalWith<typeof S.Boolean, {
3411
3591
  nullable: true;
3412
3592
  }>;
3413
- dimensions: S.optionalWith<S.filter<typeof S.Int>, {
3593
+ /**
3594
+ * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
3595
+ */
3596
+ require_parameters: S.optionalWith<typeof S.Boolean, {
3414
3597
  nullable: true;
3415
3598
  }>;
3416
- user: S.optionalWith<typeof S.String, {
3599
+ data_collection: S.optionalWith<typeof DataCollection, {
3417
3600
  nullable: true;
3418
3601
  }>;
3419
- provider: S.optionalWith<S.Struct<{
3420
- /**
3421
- * Whether to allow backup providers to serve requests
3422
- * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
3423
- * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
3424
- */
3425
- allow_fallbacks: S.optionalWith<typeof S.Boolean, {
3426
- nullable: true;
3427
- }>;
3428
- /**
3429
- * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
3430
- */
3431
- require_parameters: S.optionalWith<typeof S.Boolean, {
3432
- nullable: true;
3433
- }>;
3434
- data_collection: S.optionalWith<typeof DataCollection, {
3435
- nullable: true;
3436
- }>;
3437
- /**
3438
- * Whether to restrict routing to only ZDR (Zero Data Retention) endpoints. When true, only endpoints that do not retain prompts will be used.
3439
- */
3440
- zdr: S.optionalWith<typeof S.Boolean, {
3441
- nullable: true;
3442
- }>;
3443
- /**
3444
- * Whether to restrict routing to only models that allow text distillation. When true, only models where the author has allowed distillation will be used.
3445
- */
3446
- enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
3447
- nullable: true;
3448
- }>;
3449
- /**
3450
- * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
3451
- */
3452
- order: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3602
+ /**
3603
+ * Whether to restrict routing to only ZDR (Zero Data Retention) endpoints. When true, only endpoints that do not retain prompts will be used.
3604
+ */
3605
+ zdr: S.optionalWith<typeof S.Boolean, {
3606
+ nullable: true;
3607
+ }>;
3608
+ /**
3609
+ * Whether to restrict routing to only models that allow text distillation. When true, only models where the author has allowed distillation will be used.
3610
+ */
3611
+ enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
3612
+ nullable: true;
3613
+ }>;
3614
+ /**
3615
+ * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
3616
+ */
3617
+ order: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3618
+ nullable: true;
3619
+ }>;
3620
+ /**
3621
+ * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
3622
+ */
3623
+ only: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3624
+ nullable: true;
3625
+ }>;
3626
+ /**
3627
+ * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
3628
+ */
3629
+ ignore: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3630
+ nullable: true;
3631
+ }>;
3632
+ /**
3633
+ * A list of quantization levels to filter the provider by.
3634
+ */
3635
+ quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
3636
+ nullable: true;
3637
+ }>;
3638
+ sort: S.optionalWith<typeof ProviderPreferencesSort, {
3639
+ nullable: true;
3640
+ }>;
3641
+ /**
3642
+ * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
3643
+ */
3644
+ max_price: S.optionalWith<S.Struct<{
3645
+ prompt: S.optionalWith<typeof BigNumberUnion, {
3453
3646
  nullable: true;
3454
3647
  }>;
3455
- /**
3456
- * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
3457
- */
3458
- only: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3648
+ completion: S.optionalWith<typeof BigNumberUnion, {
3459
3649
  nullable: true;
3460
3650
  }>;
3461
- /**
3462
- * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
3463
- */
3464
- ignore: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3651
+ image: S.optionalWith<typeof BigNumberUnion, {
3465
3652
  nullable: true;
3466
3653
  }>;
3467
- /**
3468
- * A list of quantization levels to filter the provider by.
3469
- */
3470
- quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
3654
+ audio: S.optionalWith<typeof BigNumberUnion, {
3471
3655
  nullable: true;
3472
3656
  }>;
3473
- sort: S.optionalWith<typeof ProviderSort, {
3657
+ request: S.optionalWith<typeof BigNumberUnion, {
3474
3658
  nullable: true;
3475
3659
  }>;
3476
- /**
3477
- * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
3478
- */
3479
- max_price: S.optionalWith<S.Struct<{
3480
- prompt: S.optionalWith<typeof BigNumberUnion, {
3481
- nullable: true;
3482
- }>;
3483
- completion: S.optionalWith<typeof BigNumberUnion, {
3484
- nullable: true;
3485
- }>;
3486
- image: S.optionalWith<typeof BigNumberUnion, {
3487
- nullable: true;
3488
- }>;
3489
- audio: S.optionalWith<typeof BigNumberUnion, {
3490
- nullable: true;
3491
- }>;
3492
- request: S.optionalWith<typeof BigNumberUnion, {
3493
- nullable: true;
3494
- }>;
3495
- }>, {
3660
+ }>, {
3661
+ nullable: true;
3662
+ }>;
3663
+ /**
3664
+ * Preferred minimum throughput (in tokens per second). Endpoints below this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
3665
+ */
3666
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
3667
+ nullable: true;
3668
+ }>;
3669
+ /**
3670
+ * Preferred maximum latency (in seconds). Endpoints above this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
3671
+ */
3672
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
3673
+ nullable: true;
3674
+ }>;
3675
+ /**
3676
+ * **DEPRECATED** Use preferred_min_throughput instead. Backwards-compatible alias for preferred_min_throughput.
3677
+ */
3678
+ min_throughput: S.optionalWith<typeof S.Number, {
3679
+ nullable: true;
3680
+ }>;
3681
+ /**
3682
+ * **DEPRECATED** Use preferred_max_latency instead. Backwards-compatible alias for preferred_max_latency.
3683
+ */
3684
+ max_latency: S.optionalWith<typeof S.Number, {
3685
+ nullable: true;
3686
+ }>;
3687
+ }, S.Struct.Encoded<{
3688
+ /**
3689
+ * Whether to allow backup providers to serve requests
3690
+ * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
3691
+ * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
3692
+ */
3693
+ allow_fallbacks: S.optionalWith<typeof S.Boolean, {
3694
+ nullable: true;
3695
+ }>;
3696
+ /**
3697
+ * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
3698
+ */
3699
+ require_parameters: S.optionalWith<typeof S.Boolean, {
3700
+ nullable: true;
3701
+ }>;
3702
+ data_collection: S.optionalWith<typeof DataCollection, {
3703
+ nullable: true;
3704
+ }>;
3705
+ /**
3706
+ * Whether to restrict routing to only ZDR (Zero Data Retention) endpoints. When true, only endpoints that do not retain prompts will be used.
3707
+ */
3708
+ zdr: S.optionalWith<typeof S.Boolean, {
3709
+ nullable: true;
3710
+ }>;
3711
+ /**
3712
+ * Whether to restrict routing to only models that allow text distillation. When true, only models where the author has allowed distillation will be used.
3713
+ */
3714
+ enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
3715
+ nullable: true;
3716
+ }>;
3717
+ /**
3718
+ * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
3719
+ */
3720
+ order: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3721
+ nullable: true;
3722
+ }>;
3723
+ /**
3724
+ * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
3725
+ */
3726
+ only: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3727
+ nullable: true;
3728
+ }>;
3729
+ /**
3730
+ * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
3731
+ */
3732
+ ignore: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3733
+ nullable: true;
3734
+ }>;
3735
+ /**
3736
+ * A list of quantization levels to filter the provider by.
3737
+ */
3738
+ quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
3739
+ nullable: true;
3740
+ }>;
3741
+ sort: S.optionalWith<typeof ProviderPreferencesSort, {
3742
+ nullable: true;
3743
+ }>;
3744
+ /**
3745
+ * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
3746
+ */
3747
+ max_price: S.optionalWith<S.Struct<{
3748
+ prompt: S.optionalWith<typeof BigNumberUnion, {
3749
+ nullable: true;
3750
+ }>;
3751
+ completion: S.optionalWith<typeof BigNumberUnion, {
3752
+ nullable: true;
3753
+ }>;
3754
+ image: S.optionalWith<typeof BigNumberUnion, {
3755
+ nullable: true;
3756
+ }>;
3757
+ audio: S.optionalWith<typeof BigNumberUnion, {
3758
+ nullable: true;
3759
+ }>;
3760
+ request: S.optionalWith<typeof BigNumberUnion, {
3496
3761
  nullable: true;
3497
3762
  }>;
3498
3763
  }>, {
3499
3764
  nullable: true;
3500
3765
  }>;
3766
+ /**
3767
+ * Preferred minimum throughput (in tokens per second). Endpoints below this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
3768
+ */
3769
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
3770
+ nullable: true;
3771
+ }>;
3772
+ /**
3773
+ * Preferred maximum latency (in seconds). Endpoints above this threshold may still be used, but are deprioritized in routing. When using fallback models, this may cause a fallback model to be used instead of the primary model if it meets the threshold.
3774
+ */
3775
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
3776
+ nullable: true;
3777
+ }>;
3778
+ /**
3779
+ * **DEPRECATED** Use preferred_min_throughput instead. Backwards-compatible alias for preferred_min_throughput.
3780
+ */
3781
+ min_throughput: S.optionalWith<typeof S.Number, {
3782
+ nullable: true;
3783
+ }>;
3784
+ /**
3785
+ * **DEPRECATED** Use preferred_max_latency instead. Backwards-compatible alias for preferred_max_latency.
3786
+ */
3787
+ max_latency: S.optionalWith<typeof S.Number, {
3788
+ nullable: true;
3789
+ }>;
3790
+ }>, never, {
3791
+ readonly sort?: "price" | "throughput" | "latency" | undefined;
3792
+ } & {
3793
+ readonly allow_fallbacks?: boolean | undefined;
3794
+ } & {
3795
+ readonly require_parameters?: boolean | undefined;
3796
+ } & {
3797
+ readonly data_collection?: "deny" | "allow" | undefined;
3798
+ } & {
3799
+ readonly zdr?: boolean | undefined;
3800
+ } & {
3801
+ readonly enforce_distillable_text?: boolean | undefined;
3802
+ } & {
3803
+ readonly order?: readonly string[] | undefined;
3804
+ } & {
3805
+ readonly only?: readonly string[] | undefined;
3806
+ } & {
3807
+ readonly ignore?: readonly string[] | undefined;
3808
+ } & {
3809
+ readonly quantizations?: readonly ("unknown" | "int4" | "int8" | "fp4" | "fp6" | "fp8" | "fp16" | "bf16" | "fp32")[] | undefined;
3810
+ } & {
3811
+ readonly max_price?: {
3812
+ readonly prompt?: string | undefined;
3813
+ readonly completion?: string | undefined;
3814
+ readonly image?: string | undefined;
3815
+ readonly audio?: string | undefined;
3816
+ readonly request?: string | undefined;
3817
+ } | undefined;
3818
+ } & {
3819
+ readonly preferred_min_throughput?: number | undefined;
3820
+ } & {
3821
+ readonly preferred_max_latency?: number | undefined;
3822
+ } & {
3823
+ readonly min_throughput?: number | undefined;
3824
+ } & {
3825
+ readonly max_latency?: number | undefined;
3826
+ }, {}, {}>;
3827
+ /**
3828
+ * Provider routing preferences for the request.
3829
+ */
3830
+ export declare class ProviderPreferences extends ProviderPreferences_base {
3831
+ }
3832
+ declare const CreateEmbeddingsRequest_base: S.Class<CreateEmbeddingsRequest, {
3833
+ input: S.Union<[typeof S.String, S.Array$<typeof S.String>, S.Array$<typeof S.Number>, S.Array$<S.Array$<typeof S.Number>>, S.Array$<S.Struct<{
3834
+ content: S.Array$<S.Union<[S.Struct<{
3835
+ type: S.Literal<["text"]>;
3836
+ text: typeof S.String;
3837
+ }>, S.Struct<{
3838
+ type: S.Literal<["image_url"]>;
3839
+ image_url: S.Struct<{
3840
+ url: typeof S.String;
3841
+ }>;
3842
+ }>]>>;
3843
+ }>>]>;
3844
+ model: typeof S.String;
3845
+ encoding_format: S.optionalWith<typeof CreateEmbeddingsRequestEncodingFormat, {
3846
+ nullable: true;
3847
+ }>;
3848
+ dimensions: S.optionalWith<S.filter<typeof S.Int>, {
3849
+ nullable: true;
3850
+ }>;
3851
+ user: S.optionalWith<typeof S.String, {
3852
+ nullable: true;
3853
+ }>;
3854
+ provider: S.optionalWith<typeof ProviderPreferences, {
3855
+ nullable: true;
3856
+ }>;
3501
3857
  input_type: S.optionalWith<typeof S.String, {
3502
3858
  nullable: true;
3503
3859
  }>;
@@ -3523,92 +3879,15 @@ declare const CreateEmbeddingsRequest_base: S.Class<CreateEmbeddingsRequest, {
3523
3879
  user: S.optionalWith<typeof S.String, {
3524
3880
  nullable: true;
3525
3881
  }>;
3526
- provider: S.optionalWith<S.Struct<{
3527
- /**
3528
- * Whether to allow backup providers to serve requests
3529
- * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
3530
- * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
3531
- */
3532
- allow_fallbacks: S.optionalWith<typeof S.Boolean, {
3533
- nullable: true;
3534
- }>;
3535
- /**
3536
- * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
3537
- */
3538
- require_parameters: S.optionalWith<typeof S.Boolean, {
3539
- nullable: true;
3540
- }>;
3541
- data_collection: S.optionalWith<typeof DataCollection, {
3542
- nullable: true;
3543
- }>;
3544
- /**
3545
- * Whether to restrict routing to only ZDR (Zero Data Retention) endpoints. When true, only endpoints that do not retain prompts will be used.
3546
- */
3547
- zdr: S.optionalWith<typeof S.Boolean, {
3548
- nullable: true;
3549
- }>;
3550
- /**
3551
- * Whether to restrict routing to only models that allow text distillation. When true, only models where the author has allowed distillation will be used.
3552
- */
3553
- enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
3554
- nullable: true;
3555
- }>;
3556
- /**
3557
- * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
3558
- */
3559
- order: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3560
- nullable: true;
3561
- }>;
3562
- /**
3563
- * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
3564
- */
3565
- only: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3566
- nullable: true;
3567
- }>;
3568
- /**
3569
- * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
3570
- */
3571
- ignore: S.optionalWith<S.Array$<S.Union<[typeof ProviderName, typeof S.String]>>, {
3572
- nullable: true;
3573
- }>;
3574
- /**
3575
- * A list of quantization levels to filter the provider by.
3576
- */
3577
- quantizations: S.optionalWith<S.Array$<typeof Quantization>, {
3578
- nullable: true;
3579
- }>;
3580
- sort: S.optionalWith<typeof ProviderSort, {
3581
- nullable: true;
3582
- }>;
3583
- /**
3584
- * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
3585
- */
3586
- max_price: S.optionalWith<S.Struct<{
3587
- prompt: S.optionalWith<typeof BigNumberUnion, {
3588
- nullable: true;
3589
- }>;
3590
- completion: S.optionalWith<typeof BigNumberUnion, {
3591
- nullable: true;
3592
- }>;
3593
- image: S.optionalWith<typeof BigNumberUnion, {
3594
- nullable: true;
3595
- }>;
3596
- audio: S.optionalWith<typeof BigNumberUnion, {
3597
- nullable: true;
3598
- }>;
3599
- request: S.optionalWith<typeof BigNumberUnion, {
3600
- nullable: true;
3601
- }>;
3602
- }>, {
3603
- nullable: true;
3604
- }>;
3605
- }>, {
3882
+ provider: S.optionalWith<typeof ProviderPreferences, {
3606
3883
  nullable: true;
3607
3884
  }>;
3608
3885
  input_type: S.optionalWith<typeof S.String, {
3609
3886
  nullable: true;
3610
3887
  }>;
3611
3888
  }>, never, {
3889
+ readonly model: string;
3890
+ } & {
3612
3891
  readonly input: string | readonly string[] | readonly number[] | readonly (readonly number[])[] | readonly {
3613
3892
  readonly content: readonly ({
3614
3893
  readonly type: "text";
@@ -3621,27 +3900,7 @@ declare const CreateEmbeddingsRequest_base: S.Class<CreateEmbeddingsRequest, {
3621
3900
  })[];
3622
3901
  }[];
3623
3902
  } & {
3624
- readonly model: string;
3625
- } & {
3626
- readonly provider?: {
3627
- readonly sort?: "price" | "throughput" | "latency" | undefined;
3628
- readonly allow_fallbacks?: boolean | undefined;
3629
- readonly require_parameters?: boolean | undefined;
3630
- readonly data_collection?: "deny" | "allow" | undefined;
3631
- readonly zdr?: boolean | undefined;
3632
- readonly enforce_distillable_text?: boolean | undefined;
3633
- readonly order?: readonly string[] | undefined;
3634
- readonly only?: readonly string[] | undefined;
3635
- readonly ignore?: readonly string[] | undefined;
3636
- readonly quantizations?: readonly ("unknown" | "int4" | "int8" | "fp4" | "fp6" | "fp8" | "fp16" | "bf16" | "fp32")[] | undefined;
3637
- readonly max_price?: {
3638
- readonly prompt?: string | number | undefined;
3639
- readonly completion?: string | number | undefined;
3640
- readonly image?: string | number | undefined;
3641
- readonly audio?: string | number | undefined;
3642
- readonly request?: string | number | undefined;
3643
- } | undefined;
3644
- } | undefined;
3903
+ readonly provider?: ProviderPreferences | undefined;
3645
3904
  } & {
3646
3905
  readonly user?: string | undefined;
3647
3906
  } & {
@@ -3754,29 +4013,29 @@ declare const PublicPricing_base: S.Class<PublicPricing, {
3754
4013
  nullable: true;
3755
4014
  }>;
3756
4015
  }>, never, {
3757
- readonly web_search?: string | number | undefined;
4016
+ readonly web_search?: string | undefined;
3758
4017
  } & {
3759
- readonly prompt: string | number;
4018
+ readonly prompt: string;
3760
4019
  } & {
3761
- readonly completion: string | number;
4020
+ readonly completion: string;
3762
4021
  } & {
3763
- readonly image?: string | number | undefined;
4022
+ readonly image?: string | undefined;
3764
4023
  } & {
3765
- readonly audio?: string | number | undefined;
4024
+ readonly audio?: string | undefined;
3766
4025
  } & {
3767
- readonly request?: string | number | undefined;
4026
+ readonly request?: string | undefined;
3768
4027
  } & {
3769
- readonly image_token?: string | number | undefined;
4028
+ readonly image_token?: string | undefined;
3770
4029
  } & {
3771
- readonly image_output?: string | number | undefined;
4030
+ readonly image_output?: string | undefined;
3772
4031
  } & {
3773
- readonly input_audio_cache?: string | number | undefined;
4032
+ readonly input_audio_cache?: string | undefined;
3774
4033
  } & {
3775
- readonly internal_reasoning?: string | number | undefined;
4034
+ readonly internal_reasoning?: string | undefined;
3776
4035
  } & {
3777
- readonly input_cache_read?: string | number | undefined;
4036
+ readonly input_cache_read?: string | undefined;
3778
4037
  } & {
3779
- readonly input_cache_write?: string | number | undefined;
4038
+ readonly input_cache_write?: string | undefined;
3780
4039
  } & {
3781
4040
  readonly discount?: number | undefined;
3782
4041
  }, {}, {}>;
@@ -3937,7 +4196,7 @@ declare const PerRequestLimits_base: S.Class<PerRequestLimits, {
3937
4196
  */
3938
4197
  export declare class PerRequestLimits extends PerRequestLimits_base {
3939
4198
  }
3940
- declare const Parameter_base: S.Literal<["temperature", "top_p", "top_k", "min_p", "top_a", "frequency_penalty", "presence_penalty", "repetition_penalty", "max_tokens", "logit_bias", "logprobs", "top_logprobs", "seed", "response_format", "structured_outputs", "stop", "tools", "tool_choice", "parallel_tool_calls", "include_reasoning", "reasoning", "web_search_options", "verbosity"]>;
4199
+ declare const Parameter_base: S.Literal<["temperature", "top_p", "top_k", "min_p", "top_a", "frequency_penalty", "presence_penalty", "repetition_penalty", "max_tokens", "logit_bias", "logprobs", "top_logprobs", "seed", "response_format", "structured_outputs", "stop", "tools", "tool_choice", "parallel_tool_calls", "include_reasoning", "reasoning", "reasoning_effort", "web_search_options", "verbosity"]>;
3941
4200
  export declare class Parameter extends Parameter_base {
3942
4201
  }
3943
4202
  declare const DefaultParameters_base: S.Class<DefaultParameters, {
@@ -4079,7 +4338,7 @@ declare const Model_base: S.Class<Model, {
4079
4338
  } & {
4080
4339
  readonly per_request_limits: PerRequestLimits | null;
4081
4340
  } & {
4082
- readonly supported_parameters: readonly ("reasoning" | "verbosity" | "max_tokens" | "tools" | "tool_choice" | "parallel_tool_calls" | "temperature" | "top_p" | "top_k" | "top_logprobs" | "min_p" | "top_a" | "frequency_penalty" | "presence_penalty" | "repetition_penalty" | "logit_bias" | "logprobs" | "seed" | "response_format" | "structured_outputs" | "stop" | "include_reasoning" | "web_search_options")[];
4341
+ readonly supported_parameters: readonly ("reasoning" | "verbosity" | "max_tokens" | "tools" | "tool_choice" | "parallel_tool_calls" | "temperature" | "top_p" | "top_k" | "top_logprobs" | "min_p" | "top_a" | "frequency_penalty" | "presence_penalty" | "repetition_penalty" | "logit_bias" | "logprobs" | "seed" | "response_format" | "structured_outputs" | "stop" | "include_reasoning" | "reasoning_effort" | "web_search_options")[];
4083
4342
  } & {
4084
4343
  readonly default_parameters: DefaultParameters | null;
4085
4344
  }, {}, {}>;
@@ -4444,29 +4703,29 @@ declare const PublicEndpoint_base: S.Class<PublicEndpoint, {
4444
4703
  } & {
4445
4704
  readonly status?: 0 | -2 | -1 | -3 | -5 | -10 | undefined;
4446
4705
  } & {
4447
- readonly provider_name: "AI21" | "AionLabs" | "Alibaba" | "Amazon Bedrock" | "Anthropic" | "Arcee" | "AtlasCloud" | "Avian" | "Azure" | "BaseTen" | "Black Forest Labs" | "Cerebras" | "Chutes" | "Cirrascale" | "Clarifai" | "Cloudflare" | "Cohere" | "Crusoe" | "DeepInfra" | "DeepSeek" | "Featherless" | "Fireworks" | "Friendli" | "GMICloud" | "Google" | "Google AI Studio" | "Groq" | "Hyperbolic" | "Inception" | "InferenceNet" | "Infermatic" | "Inflection" | "Liquid" | "Mancer 2" | "Minimax" | "ModelRun" | "Mistral" | "Modular" | "Moonshot AI" | "Morph" | "NCompass" | "Nebius" | "NextBit" | "Novita" | "Nvidia" | "OpenAI" | "OpenInference" | "Parasail" | "Perplexity" | "Phala" | "Relace" | "SambaNova" | "SiliconFlow" | "Stealth" | "Switchpoint" | "Targon" | "Together" | "Venice" | "WandB" | "xAI" | "Z.AI" | "FakeProvider";
4706
+ readonly provider_name: "AI21" | "AionLabs" | "Alibaba" | "Amazon Bedrock" | "Amazon Nova" | "Anthropic" | "Arcee AI" | "AtlasCloud" | "Avian" | "Azure" | "BaseTen" | "BytePlus" | "Black Forest Labs" | "Cerebras" | "Chutes" | "Cirrascale" | "Clarifai" | "Cloudflare" | "Cohere" | "Crusoe" | "DeepInfra" | "DeepSeek" | "Featherless" | "Fireworks" | "Friendli" | "GMICloud" | "GoPomelo" | "Google" | "Google AI Studio" | "Groq" | "Hyperbolic" | "Inception" | "InferenceNet" | "Infermatic" | "Inflection" | "Liquid" | "Mara" | "Mancer 2" | "Minimax" | "ModelRun" | "Mistral" | "Modular" | "Moonshot AI" | "Morph" | "NCompass" | "Nebius" | "NextBit" | "Novita" | "Nvidia" | "OpenAI" | "OpenInference" | "Parasail" | "Perplexity" | "Phala" | "Relace" | "SambaNova" | "SiliconFlow" | "Sourceful" | "Stealth" | "StreamLake" | "Switchpoint" | "Targon" | "Together" | "Venice" | "WandB" | "Xiaomi" | "xAI" | "Z.AI" | "FakeProvider";
4448
4707
  } & {
4449
4708
  readonly context_length: number;
4450
4709
  } & {
4451
4710
  readonly max_completion_tokens: number | null;
4452
4711
  } & {
4453
4712
  readonly pricing: {
4454
- readonly web_search?: string | number | undefined;
4455
- readonly prompt: string | number;
4456
- readonly completion: string | number;
4457
- readonly image?: string | number | undefined;
4458
- readonly audio?: string | number | undefined;
4459
- readonly request?: string | number | undefined;
4460
- readonly image_token?: string | number | undefined;
4461
- readonly image_output?: string | number | undefined;
4462
- readonly input_audio_cache?: string | number | undefined;
4463
- readonly internal_reasoning?: string | number | undefined;
4464
- readonly input_cache_read?: string | number | undefined;
4465
- readonly input_cache_write?: string | number | undefined;
4713
+ readonly web_search?: string | undefined;
4714
+ readonly prompt: string;
4715
+ readonly completion: string;
4716
+ readonly image?: string | undefined;
4717
+ readonly audio?: string | undefined;
4718
+ readonly request?: string | undefined;
4719
+ readonly image_token?: string | undefined;
4720
+ readonly image_output?: string | undefined;
4721
+ readonly input_audio_cache?: string | undefined;
4722
+ readonly internal_reasoning?: string | undefined;
4723
+ readonly input_cache_read?: string | undefined;
4724
+ readonly input_cache_write?: string | undefined;
4466
4725
  readonly discount?: number | undefined;
4467
4726
  };
4468
4727
  } & {
4469
- readonly supported_parameters: readonly ("reasoning" | "verbosity" | "max_tokens" | "tools" | "tool_choice" | "parallel_tool_calls" | "temperature" | "top_p" | "top_k" | "top_logprobs" | "min_p" | "top_a" | "frequency_penalty" | "presence_penalty" | "repetition_penalty" | "logit_bias" | "logprobs" | "seed" | "response_format" | "structured_outputs" | "stop" | "include_reasoning" | "web_search_options")[];
4728
+ readonly supported_parameters: readonly ("reasoning" | "verbosity" | "max_tokens" | "tools" | "tool_choice" | "parallel_tool_calls" | "temperature" | "top_p" | "top_k" | "top_logprobs" | "min_p" | "top_a" | "frequency_penalty" | "presence_penalty" | "repetition_penalty" | "logit_bias" | "logprobs" | "seed" | "response_format" | "structured_outputs" | "stop" | "include_reasoning" | "reasoning_effort" | "web_search_options")[];
4470
4729
  } & {
4471
4730
  readonly model_name: string;
4472
4731
  } & {
@@ -4563,11 +4822,8 @@ declare const ListEndpointsZdr200_base: S.Struct<{
4563
4822
  }>;
4564
4823
  export declare class ListEndpointsZdr200 extends ListEndpointsZdr200_base {
4565
4824
  }
4566
- declare const GetParametersParamsProvider_base: S.Literal<["AI21", "AionLabs", "Alibaba", "Amazon Bedrock", "Anthropic", "Arcee", "AtlasCloud", "Avian", "Azure", "BaseTen", "Black Forest Labs", "Cerebras", "Chutes", "Cirrascale", "Clarifai", "Cloudflare", "Cohere", "Crusoe", "DeepInfra", "DeepSeek", "Featherless", "Fireworks", "Friendli", "GMICloud", "Google", "Google AI Studio", "Groq", "Hyperbolic", "Inception", "InferenceNet", "Infermatic", "Inflection", "Liquid", "Mancer 2", "Minimax", "ModelRun", "Mistral", "Modular", "Moonshot AI", "Morph", "NCompass", "Nebius", "NextBit", "Novita", "Nvidia", "OpenAI", "OpenInference", "Parasail", "Perplexity", "Phala", "Relace", "SambaNova", "SiliconFlow", "Stealth", "Switchpoint", "Targon", "Together", "Venice", "WandB", "xAI", "Z.AI", "FakeProvider"]>;
4567
- export declare class GetParametersParamsProvider extends GetParametersParamsProvider_base {
4568
- }
4569
4825
  declare const GetParametersParams_base: S.Struct<{
4570
- provider: S.optionalWith<typeof GetParametersParamsProvider, {
4826
+ provider: S.optionalWith<typeof ProviderName, {
4571
4827
  nullable: true;
4572
4828
  }>;
4573
4829
  }>;
@@ -4585,7 +4841,7 @@ declare const GetParameters200_base: S.Struct<{
4585
4841
  /**
4586
4842
  * List of parameters supported by this model
4587
4843
  */
4588
- supported_parameters: S.Array$<S.Literal<["temperature", "top_p", "top_k", "min_p", "top_a", "frequency_penalty", "presence_penalty", "repetition_penalty", "max_tokens", "logit_bias", "logprobs", "top_logprobs", "seed", "response_format", "structured_outputs", "stop", "tools", "tool_choice", "parallel_tool_calls", "include_reasoning", "reasoning", "web_search_options", "verbosity"]>>;
4844
+ supported_parameters: S.Array$<S.Literal<["temperature", "top_p", "top_k", "min_p", "top_a", "frequency_penalty", "presence_penalty", "repetition_penalty", "max_tokens", "logit_bias", "logprobs", "top_logprobs", "seed", "response_format", "structured_outputs", "stop", "tools", "tool_choice", "parallel_tool_calls", "include_reasoning", "reasoning", "reasoning_effort", "web_search_options", "verbosity"]>>;
4589
4845
  }>;
4590
4846
  }>;
4591
4847
  export declare class GetParameters200 extends GetParameters200_base {
@@ -5405,21 +5661,64 @@ declare const CreateAuthKeysCode200_base: S.Struct<{
5405
5661
  }>;
5406
5662
  export declare class CreateAuthKeysCode200 extends CreateAuthKeysCode200_base {
5407
5663
  }
5408
- declare const ChatMessageContentItemText_base: S.Class<ChatMessageContentItemText, {
5409
- type: S.Literal<["text"]>;
5410
- text: typeof S.String;
5411
- }, S.Struct.Encoded<{
5412
- type: S.Literal<["text"]>;
5413
- text: typeof S.String;
5414
- }>, never, {
5415
- readonly type: "text";
5416
- } & {
5417
- readonly text: string;
5418
- }, {}, {}>;
5419
- export declare class ChatMessageContentItemText extends ChatMessageContentItemText_base {
5664
+ declare const ChatGenerationParamsProviderEnumDataCollectionEnum_base: S.Literal<["deny", "allow"]>;
5665
+ export declare class ChatGenerationParamsProviderEnumDataCollectionEnum extends ChatGenerationParamsProviderEnumDataCollectionEnum_base {
5420
5666
  }
5421
- declare const SystemMessage_base: S.Class<SystemMessage, {
5422
- role: S.Literal<["system"]>;
5667
+ declare const Schema0_base: S.Array$<S.Union<[S.Literal<["AI21", "AionLabs", "Alibaba", "Amazon Bedrock", "Amazon Nova", "Anthropic", "Arcee AI", "AtlasCloud", "Avian", "Azure", "BaseTen", "BytePlus", "Black Forest Labs", "Cerebras", "Chutes", "Cirrascale", "Clarifai", "Cloudflare", "Cohere", "Crusoe", "DeepInfra", "DeepSeek", "Featherless", "Fireworks", "Friendli", "GMICloud", "GoPomelo", "Google", "Google AI Studio", "Groq", "Hyperbolic", "Inception", "InferenceNet", "Infermatic", "Inflection", "Liquid", "Mara", "Mancer 2", "Minimax", "ModelRun", "Mistral", "Modular", "Moonshot AI", "Morph", "NCompass", "Nebius", "NextBit", "Novita", "Nvidia", "OpenAI", "OpenInference", "Parasail", "Perplexity", "Phala", "Relace", "SambaNova", "SiliconFlow", "Sourceful", "Stealth", "StreamLake", "Switchpoint", "Targon", "Together", "Venice", "WandB", "Xiaomi", "xAI", "Z.AI", "FakeProvider"]>, typeof S.String]>>;
5668
+ export declare class Schema0 extends Schema0_base {
5669
+ }
5670
+ declare const ProviderSortUnion_base: S.Union<[typeof ProviderSort, typeof ProviderSortConfig]>;
5671
+ export declare class ProviderSortUnion extends ProviderSortUnion_base {
5672
+ }
5673
+ declare const Schema1_base: S.Union<[typeof S.Number, typeof S.String, typeof S.Number]>;
5674
+ export declare class Schema1 extends Schema1_base {
5675
+ }
5676
+ declare const ChatGenerationParamsRouteEnum_base: S.Literal<["fallback", "sort"]>;
5677
+ export declare class ChatGenerationParamsRouteEnum extends ChatGenerationParamsRouteEnum_base {
5678
+ }
5679
+ declare const ChatMessageContentItemCacheControlTtl_base: S.Literal<["5m", "1h"]>;
5680
+ export declare class ChatMessageContentItemCacheControlTtl extends ChatMessageContentItemCacheControlTtl_base {
5681
+ }
5682
+ declare const ChatMessageContentItemCacheControl_base: S.Class<ChatMessageContentItemCacheControl, {
5683
+ type: S.Literal<["ephemeral"]>;
5684
+ ttl: S.optionalWith<typeof ChatMessageContentItemCacheControlTtl, {
5685
+ nullable: true;
5686
+ }>;
5687
+ }, S.Struct.Encoded<{
5688
+ type: S.Literal<["ephemeral"]>;
5689
+ ttl: S.optionalWith<typeof ChatMessageContentItemCacheControlTtl, {
5690
+ nullable: true;
5691
+ }>;
5692
+ }>, never, {
5693
+ readonly type: "ephemeral";
5694
+ } & {
5695
+ readonly ttl?: "5m" | "1h" | undefined;
5696
+ }, {}, {}>;
5697
+ export declare class ChatMessageContentItemCacheControl extends ChatMessageContentItemCacheControl_base {
5698
+ }
5699
+ declare const ChatMessageContentItemText_base: S.Class<ChatMessageContentItemText, {
5700
+ type: S.Literal<["text"]>;
5701
+ text: typeof S.String;
5702
+ cache_control: S.optionalWith<typeof ChatMessageContentItemCacheControl, {
5703
+ nullable: true;
5704
+ }>;
5705
+ }, S.Struct.Encoded<{
5706
+ type: S.Literal<["text"]>;
5707
+ text: typeof S.String;
5708
+ cache_control: S.optionalWith<typeof ChatMessageContentItemCacheControl, {
5709
+ nullable: true;
5710
+ }>;
5711
+ }>, never, {
5712
+ readonly type: "text";
5713
+ } & {
5714
+ readonly text: string;
5715
+ } & {
5716
+ readonly cache_control?: ChatMessageContentItemCacheControl | undefined;
5717
+ }, {}, {}>;
5718
+ export declare class ChatMessageContentItemText extends ChatMessageContentItemText_base {
5719
+ }
5720
+ declare const SystemMessage_base: S.Class<SystemMessage, {
5721
+ role: S.Literal<["system"]>;
5423
5722
  content: S.Union<[typeof S.String, S.Array$<typeof ChatMessageContentItemText>]>;
5424
5723
  name: S.optionalWith<typeof S.String, {
5425
5724
  nullable: true;
@@ -5468,76 +5767,31 @@ declare const ChatMessageContentItemImage_base: S.Class<ChatMessageContentItemIm
5468
5767
  }, {}, {}>;
5469
5768
  export declare class ChatMessageContentItemImage extends ChatMessageContentItemImage_base {
5470
5769
  }
5471
- declare const ChatMessageContentItemAudioInputAudioFormat_base: S.Literal<["wav", "mp3", "flac", "m4a", "ogg", "pcm16", "pcm24"]>;
5472
- export declare class ChatMessageContentItemAudioInputAudioFormat extends ChatMessageContentItemAudioInputAudioFormat_base {
5473
- }
5474
5770
  declare const ChatMessageContentItemAudio_base: S.Class<ChatMessageContentItemAudio, {
5475
5771
  type: S.Literal<["input_audio"]>;
5476
5772
  input_audio: S.Struct<{
5477
5773
  data: typeof S.String;
5478
- format: typeof ChatMessageContentItemAudioInputAudioFormat;
5774
+ format: typeof S.String;
5479
5775
  }>;
5480
5776
  }, S.Struct.Encoded<{
5481
5777
  type: S.Literal<["input_audio"]>;
5482
5778
  input_audio: S.Struct<{
5483
5779
  data: typeof S.String;
5484
- format: typeof ChatMessageContentItemAudioInputAudioFormat;
5780
+ format: typeof S.String;
5485
5781
  }>;
5486
5782
  }>, never, {
5487
5783
  readonly type: "input_audio";
5488
5784
  } & {
5489
5785
  readonly input_audio: {
5490
- readonly format: "mp3" | "wav" | "flac" | "m4a" | "ogg" | "pcm16" | "pcm24";
5786
+ readonly format: string;
5491
5787
  readonly data: string;
5492
5788
  };
5493
5789
  }, {}, {}>;
5494
5790
  export declare class ChatMessageContentItemAudio extends ChatMessageContentItemAudio_base {
5495
5791
  }
5496
- declare const VideoURL_base: S.Class<VideoURL, {
5497
- url: typeof S.String;
5498
- }, S.Struct.Encoded<{
5499
- url: typeof S.String;
5500
- }>, never, {
5501
- readonly url: string;
5502
- }, {}, {}>;
5503
- export declare class VideoURL extends VideoURL_base {
5504
- }
5505
5792
  declare const ChatMessageContentItemVideo_base: S.Record$<typeof S.String, typeof S.Unknown>;
5506
5793
  export declare class ChatMessageContentItemVideo extends ChatMessageContentItemVideo_base {
5507
5794
  }
5508
- declare const ChatMessageContentItemFile_base: S.Class<ChatMessageContentItemFile, {
5509
- type: S.Literal<["file"]>;
5510
- file: S.Struct<{
5511
- file_data: typeof S.String;
5512
- file_id: S.optionalWith<typeof S.String, {
5513
- nullable: true;
5514
- }>;
5515
- filename: S.optionalWith<typeof S.String, {
5516
- nullable: true;
5517
- }>;
5518
- }>;
5519
- }, S.Struct.Encoded<{
5520
- type: S.Literal<["file"]>;
5521
- file: S.Struct<{
5522
- file_data: typeof S.String;
5523
- file_id: S.optionalWith<typeof S.String, {
5524
- nullable: true;
5525
- }>;
5526
- filename: S.optionalWith<typeof S.String, {
5527
- nullable: true;
5528
- }>;
5529
- }>;
5530
- }>, never, {
5531
- readonly type: "file";
5532
- } & {
5533
- readonly file: {
5534
- readonly file_id?: string | undefined;
5535
- readonly file_data: string;
5536
- readonly filename?: string | undefined;
5537
- };
5538
- }, {}, {}>;
5539
- export declare class ChatMessageContentItemFile extends ChatMessageContentItemFile_base {
5540
- }
5541
5795
  declare const ChatMessageContentItem_base: S.Record$<typeof S.String, typeof S.Unknown>;
5542
5796
  export declare class ChatMessageContentItem extends ChatMessageContentItem_base {
5543
5797
  }
@@ -5689,7 +5943,7 @@ export declare class Message extends Message_base {
5689
5943
  }
5690
5944
  export declare class ModelName extends S.String {
5691
5945
  }
5692
- declare const ChatGenerationParamsReasoningEffortEnum_base: S.Literal<["none", "minimal", "low", "medium", "high"]>;
5946
+ declare const ChatGenerationParamsReasoningEffortEnum_base: S.Literal<["xhigh", "high", "medium", "low", "minimal", "none"]>;
5693
5947
  export declare class ChatGenerationParamsReasoningEffortEnum extends ChatGenerationParamsReasoningEffortEnum_base {
5694
5948
  }
5695
5949
  declare const JSONSchemaConfig_base: S.Class<JSONSchemaConfig, {
@@ -5831,6 +6085,124 @@ declare const ToolDefinitionJson_base: S.Class<ToolDefinitionJson, {
5831
6085
  export declare class ToolDefinitionJson extends ToolDefinitionJson_base {
5832
6086
  }
5833
6087
  declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
6088
+ /**
6089
+ * When multiple model providers are available, optionally indicate your routing preference.
6090
+ */
6091
+ provider: S.optionalWith<S.Struct<{
6092
+ /**
6093
+ * Whether to allow backup providers to serve requests
6094
+ * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
6095
+ * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
6096
+ */
6097
+ allow_fallbacks: S.optionalWith<typeof S.Boolean, {
6098
+ nullable: true;
6099
+ }>;
6100
+ /**
6101
+ * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
6102
+ */
6103
+ require_parameters: S.optionalWith<typeof S.Boolean, {
6104
+ nullable: true;
6105
+ }>;
6106
+ /**
6107
+ * Data collection setting. If no available model provider meets the requirement, your request will return an error.
6108
+ * - allow: (default) allow providers which store user data non-transiently and may train on it
6109
+ *
6110
+ * - deny: use only providers which do not collect user data.
6111
+ */
6112
+ data_collection: S.optionalWith<S.Literal<["deny", "allow"]>, {
6113
+ nullable: true;
6114
+ }>;
6115
+ zdr: S.optionalWith<typeof S.Boolean, {
6116
+ nullable: true;
6117
+ }>;
6118
+ enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
6119
+ nullable: true;
6120
+ }>;
6121
+ /**
6122
+ * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
6123
+ */
6124
+ order: S.optionalWith<typeof Schema0, {
6125
+ nullable: true;
6126
+ }>;
6127
+ /**
6128
+ * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
6129
+ */
6130
+ only: S.optionalWith<typeof Schema0, {
6131
+ nullable: true;
6132
+ }>;
6133
+ /**
6134
+ * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
6135
+ */
6136
+ ignore: S.optionalWith<typeof Schema0, {
6137
+ nullable: true;
6138
+ }>;
6139
+ /**
6140
+ * A list of quantization levels to filter the provider by.
6141
+ */
6142
+ quantizations: S.optionalWith<S.Array$<S.Literal<["int4", "int8", "fp4", "fp6", "fp8", "fp16", "bf16", "fp32", "unknown"]>>, {
6143
+ nullable: true;
6144
+ }>;
6145
+ /**
6146
+ * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
6147
+ */
6148
+ sort: S.optionalWith<typeof ProviderSortUnion, {
6149
+ nullable: true;
6150
+ }>;
6151
+ /**
6152
+ * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
6153
+ */
6154
+ max_price: S.optionalWith<S.Struct<{
6155
+ prompt: S.optionalWith<typeof Schema1, {
6156
+ nullable: true;
6157
+ }>;
6158
+ completion: S.optionalWith<typeof Schema1, {
6159
+ nullable: true;
6160
+ }>;
6161
+ image: S.optionalWith<typeof Schema1, {
6162
+ nullable: true;
6163
+ }>;
6164
+ audio: S.optionalWith<typeof Schema1, {
6165
+ nullable: true;
6166
+ }>;
6167
+ request: S.optionalWith<typeof Schema1, {
6168
+ nullable: true;
6169
+ }>;
6170
+ }>, {
6171
+ nullable: true;
6172
+ }>;
6173
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
6174
+ nullable: true;
6175
+ }>;
6176
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
6177
+ nullable: true;
6178
+ }>;
6179
+ min_throughput: S.optionalWith<typeof S.Number, {
6180
+ nullable: true;
6181
+ }>;
6182
+ max_latency: S.optionalWith<typeof S.Number, {
6183
+ nullable: true;
6184
+ }>;
6185
+ }>, {
6186
+ nullable: true;
6187
+ }>;
6188
+ /**
6189
+ * Plugins you want to enable for this request, including their settings.
6190
+ */
6191
+ plugins: S.optionalWith<S.Array$<S.Record$<typeof S.String, typeof S.Unknown>>, {
6192
+ nullable: true;
6193
+ }>;
6194
+ route: S.optionalWith<typeof ChatGenerationParamsRouteEnum, {
6195
+ nullable: true;
6196
+ }>;
6197
+ user: S.optionalWith<typeof S.String, {
6198
+ nullable: true;
6199
+ }>;
6200
+ /**
6201
+ * A unique identifier for grouping related requests (e.g., a conversation or agent workflow) for observability. If provided in both the request body and the x-session-id header, the body value takes precedence. Maximum of 128 characters.
6202
+ */
6203
+ session_id: S.optionalWith<S.filter<typeof S.String>, {
6204
+ nullable: true;
6205
+ }>;
5834
6206
  messages: S.filter<S.NonEmptyArray<typeof Message>>;
5835
6207
  model: S.optionalWith<typeof ModelName, {
5836
6208
  nullable: true;
@@ -5902,10 +6274,132 @@ declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
5902
6274
  nullable: true;
5903
6275
  default: () => 1;
5904
6276
  }>;
5905
- user: S.optionalWith<typeof S.String, {
6277
+ debug: S.optionalWith<S.Struct<{
6278
+ echo_upstream_body: S.optionalWith<typeof S.Boolean, {
6279
+ nullable: true;
6280
+ }>;
6281
+ }>, {
5906
6282
  nullable: true;
5907
6283
  }>;
5908
6284
  }, S.Struct.Encoded<{
6285
+ /**
6286
+ * When multiple model providers are available, optionally indicate your routing preference.
6287
+ */
6288
+ provider: S.optionalWith<S.Struct<{
6289
+ /**
6290
+ * Whether to allow backup providers to serve requests
6291
+ * - true: (default) when the primary provider (or your custom providers in "order") is unavailable, use the next best provider.
6292
+ * - false: use only the primary/custom provider, and return the upstream error if it's unavailable.
6293
+ */
6294
+ allow_fallbacks: S.optionalWith<typeof S.Boolean, {
6295
+ nullable: true;
6296
+ }>;
6297
+ /**
6298
+ * Whether to filter providers to only those that support the parameters you've provided. If this setting is omitted or set to false, then providers will receive only the parameters they support, and ignore the rest.
6299
+ */
6300
+ require_parameters: S.optionalWith<typeof S.Boolean, {
6301
+ nullable: true;
6302
+ }>;
6303
+ /**
6304
+ * Data collection setting. If no available model provider meets the requirement, your request will return an error.
6305
+ * - allow: (default) allow providers which store user data non-transiently and may train on it
6306
+ *
6307
+ * - deny: use only providers which do not collect user data.
6308
+ */
6309
+ data_collection: S.optionalWith<S.Literal<["deny", "allow"]>, {
6310
+ nullable: true;
6311
+ }>;
6312
+ zdr: S.optionalWith<typeof S.Boolean, {
6313
+ nullable: true;
6314
+ }>;
6315
+ enforce_distillable_text: S.optionalWith<typeof S.Boolean, {
6316
+ nullable: true;
6317
+ }>;
6318
+ /**
6319
+ * An ordered list of provider slugs. The router will attempt to use the first provider in the subset of this list that supports your requested model, and fall back to the next if it is unavailable. If no providers are available, the request will fail with an error message.
6320
+ */
6321
+ order: S.optionalWith<typeof Schema0, {
6322
+ nullable: true;
6323
+ }>;
6324
+ /**
6325
+ * List of provider slugs to allow. If provided, this list is merged with your account-wide allowed provider settings for this request.
6326
+ */
6327
+ only: S.optionalWith<typeof Schema0, {
6328
+ nullable: true;
6329
+ }>;
6330
+ /**
6331
+ * List of provider slugs to ignore. If provided, this list is merged with your account-wide ignored provider settings for this request.
6332
+ */
6333
+ ignore: S.optionalWith<typeof Schema0, {
6334
+ nullable: true;
6335
+ }>;
6336
+ /**
6337
+ * A list of quantization levels to filter the provider by.
6338
+ */
6339
+ quantizations: S.optionalWith<S.Array$<S.Literal<["int4", "int8", "fp4", "fp6", "fp8", "fp16", "bf16", "fp32", "unknown"]>>, {
6340
+ nullable: true;
6341
+ }>;
6342
+ /**
6343
+ * The sorting strategy to use for this request, if "order" is not specified. When set, no load balancing is performed.
6344
+ */
6345
+ sort: S.optionalWith<typeof ProviderSortUnion, {
6346
+ nullable: true;
6347
+ }>;
6348
+ /**
6349
+ * The object specifying the maximum price you want to pay for this request. USD price per million tokens, for prompt and completion.
6350
+ */
6351
+ max_price: S.optionalWith<S.Struct<{
6352
+ prompt: S.optionalWith<typeof Schema1, {
6353
+ nullable: true;
6354
+ }>;
6355
+ completion: S.optionalWith<typeof Schema1, {
6356
+ nullable: true;
6357
+ }>;
6358
+ image: S.optionalWith<typeof Schema1, {
6359
+ nullable: true;
6360
+ }>;
6361
+ audio: S.optionalWith<typeof Schema1, {
6362
+ nullable: true;
6363
+ }>;
6364
+ request: S.optionalWith<typeof Schema1, {
6365
+ nullable: true;
6366
+ }>;
6367
+ }>, {
6368
+ nullable: true;
6369
+ }>;
6370
+ preferred_min_throughput: S.optionalWith<typeof S.Number, {
6371
+ nullable: true;
6372
+ }>;
6373
+ preferred_max_latency: S.optionalWith<typeof S.Number, {
6374
+ nullable: true;
6375
+ }>;
6376
+ min_throughput: S.optionalWith<typeof S.Number, {
6377
+ nullable: true;
6378
+ }>;
6379
+ max_latency: S.optionalWith<typeof S.Number, {
6380
+ nullable: true;
6381
+ }>;
6382
+ }>, {
6383
+ nullable: true;
6384
+ }>;
6385
+ /**
6386
+ * Plugins you want to enable for this request, including their settings.
6387
+ */
6388
+ plugins: S.optionalWith<S.Array$<S.Record$<typeof S.String, typeof S.Unknown>>, {
6389
+ nullable: true;
6390
+ }>;
6391
+ route: S.optionalWith<typeof ChatGenerationParamsRouteEnum, {
6392
+ nullable: true;
6393
+ }>;
6394
+ user: S.optionalWith<typeof S.String, {
6395
+ nullable: true;
6396
+ }>;
6397
+ /**
6398
+ * A unique identifier for grouping related requests (e.g., a conversation or agent workflow) for observability. If provided in both the request body and the x-session-id header, the body value takes precedence. Maximum of 128 characters.
6399
+ */
6400
+ session_id: S.optionalWith<S.filter<typeof S.String>, {
6401
+ nullable: true;
6402
+ }>;
5909
6403
  messages: S.filter<S.NonEmptyArray<typeof Message>>;
5910
6404
  model: S.optionalWith<typeof ModelName, {
5911
6405
  nullable: true;
@@ -5977,16 +6471,22 @@ declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
5977
6471
  nullable: true;
5978
6472
  default: () => 1;
5979
6473
  }>;
5980
- user: S.optionalWith<typeof S.String, {
6474
+ debug: S.optionalWith<S.Struct<{
6475
+ echo_upstream_body: S.optionalWith<typeof S.Boolean, {
6476
+ nullable: true;
6477
+ }>;
6478
+ }>, {
5981
6479
  nullable: true;
5982
6480
  }>;
5983
6481
  }>, never, {
5984
6482
  readonly reasoning?: {
5985
6483
  readonly summary?: "auto" | "concise" | "detailed" | undefined;
5986
- readonly effort?: "high" | "low" | "medium" | "minimal" | "none" | undefined;
6484
+ readonly effort?: "high" | "low" | "medium" | "xhigh" | "minimal" | "none" | undefined;
5987
6485
  } | undefined;
5988
6486
  } & {
5989
6487
  readonly max_tokens?: number | undefined;
6488
+ } & {
6489
+ readonly model?: string | undefined;
5990
6490
  } & {
5991
6491
  readonly metadata?: {
5992
6492
  readonly [x: string]: unknown;
@@ -5995,8 +6495,6 @@ declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
5995
6495
  readonly tools?: readonly ToolDefinitionJson[] | undefined;
5996
6496
  } & {
5997
6497
  readonly tool_choice?: "auto" | "required" | "none" | NamedToolChoice | undefined;
5998
- } & {
5999
- readonly model?: string | undefined;
6000
6498
  } & {
6001
6499
  readonly models?: readonly string[] | undefined;
6002
6500
  } & {
@@ -6005,8 +6503,40 @@ declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
6005
6503
  readonly top_p?: number | undefined;
6006
6504
  } & {
6007
6505
  readonly stream?: boolean | undefined;
6506
+ } & {
6507
+ readonly provider?: {
6508
+ readonly sort?: "price" | "throughput" | "latency" | ProviderSortConfig | undefined;
6509
+ readonly allow_fallbacks?: boolean | undefined;
6510
+ readonly require_parameters?: boolean | undefined;
6511
+ readonly data_collection?: "deny" | "allow" | undefined;
6512
+ readonly zdr?: boolean | undefined;
6513
+ readonly enforce_distillable_text?: boolean | undefined;
6514
+ readonly order?: readonly string[] | undefined;
6515
+ readonly only?: readonly string[] | undefined;
6516
+ readonly ignore?: readonly string[] | undefined;
6517
+ readonly quantizations?: readonly ("unknown" | "int4" | "int8" | "fp4" | "fp6" | "fp8" | "fp16" | "bf16" | "fp32")[] | undefined;
6518
+ readonly max_price?: {
6519
+ readonly prompt?: string | number | undefined;
6520
+ readonly completion?: string | number | undefined;
6521
+ readonly image?: string | number | undefined;
6522
+ readonly audio?: string | number | undefined;
6523
+ readonly request?: string | number | undefined;
6524
+ } | undefined;
6525
+ readonly preferred_min_throughput?: number | undefined;
6526
+ readonly preferred_max_latency?: number | undefined;
6527
+ readonly min_throughput?: number | undefined;
6528
+ readonly max_latency?: number | undefined;
6529
+ } | undefined;
6530
+ } & {
6531
+ readonly plugins?: readonly {
6532
+ readonly [x: string]: unknown;
6533
+ }[] | undefined;
6534
+ } & {
6535
+ readonly route?: "sort" | "fallback" | undefined;
6008
6536
  } & {
6009
6537
  readonly user?: string | undefined;
6538
+ } & {
6539
+ readonly session_id?: string | undefined;
6010
6540
  } & {
6011
6541
  readonly top_logprobs?: number | undefined;
6012
6542
  } & {
@@ -6037,15 +6567,33 @@ declare const ChatGenerationParams_base: S.Class<ChatGenerationParams, {
6037
6567
  }[]];
6038
6568
  } & {
6039
6569
  readonly stream_options?: ChatStreamOptions | undefined;
6570
+ } & {
6571
+ readonly debug?: {
6572
+ readonly echo_upstream_body?: boolean | undefined;
6573
+ } | undefined;
6040
6574
  }, {}, {}>;
6041
6575
  export declare class ChatGenerationParams extends ChatGenerationParams_base {
6042
6576
  }
6043
- declare const ChatCompletionFinishReasonEnum_base: S.Literal<["tool_calls", "stop", "length", "content_filter", "error"]>;
6044
- export declare class ChatCompletionFinishReasonEnum extends ChatCompletionFinishReasonEnum_base {
6045
- }
6046
- declare const ChatCompletionFinishReason_base: S.Union<[typeof ChatCompletionFinishReasonEnum, typeof S.Null]>;
6577
+ declare const ChatCompletionFinishReason_base: S.Literal<["tool_calls", "stop", "length", "content_filter", "error"]>;
6047
6578
  export declare class ChatCompletionFinishReason extends ChatCompletionFinishReason_base {
6048
6579
  }
6580
+ declare const Schema2_base: S.Union<[typeof ChatCompletionFinishReason, typeof S.Null]>;
6581
+ export declare class Schema2 extends Schema2_base {
6582
+ }
6583
+ declare const Schema4_base: S.Union<[typeof S.String, typeof S.Null]>;
6584
+ export declare class Schema4 extends Schema4_base {
6585
+ }
6586
+ declare const Schema5Enum_base: S.Literal<["unknown", "openai-responses-v1", "xai-responses-v1", "anthropic-claude-v1", "google-gemini-v1"]>;
6587
+ export declare class Schema5Enum extends Schema5Enum_base {
6588
+ }
6589
+ declare const Schema5_base: S.Union<[typeof Schema5Enum, typeof S.Null]>;
6590
+ export declare class Schema5 extends Schema5_base {
6591
+ }
6592
+ export declare class Schema6 extends S.Number {
6593
+ }
6594
+ declare const Schema3_base: S.Record$<typeof S.String, typeof S.Unknown>;
6595
+ export declare class Schema3 extends Schema3_base {
6596
+ }
6049
6597
  declare const ChatMessageTokenLogprob_base: S.Class<ChatMessageTokenLogprob, {
6050
6598
  token: typeof S.String;
6051
6599
  logprob: typeof S.Number;
@@ -6101,16 +6649,22 @@ declare const ChatMessageTokenLogprobs_base: S.Class<ChatMessageTokenLogprobs, {
6101
6649
  export declare class ChatMessageTokenLogprobs extends ChatMessageTokenLogprobs_base {
6102
6650
  }
6103
6651
  declare const ChatResponseChoice_base: S.Class<ChatResponseChoice, {
6104
- finish_reason: S.NullOr<S.Literal<["tool_calls", "stop", "length", "content_filter", "error"]>>;
6652
+ finish_reason: S.NullOr<typeof ChatCompletionFinishReason>;
6105
6653
  index: typeof S.Number;
6106
6654
  message: typeof AssistantMessage;
6655
+ reasoning_details: S.optionalWith<S.Array$<typeof Schema3>, {
6656
+ nullable: true;
6657
+ }>;
6107
6658
  logprobs: S.optionalWith<typeof ChatMessageTokenLogprobs, {
6108
6659
  nullable: true;
6109
6660
  }>;
6110
6661
  }, S.Struct.Encoded<{
6111
- finish_reason: S.NullOr<S.Literal<["tool_calls", "stop", "length", "content_filter", "error"]>>;
6662
+ finish_reason: S.NullOr<typeof ChatCompletionFinishReason>;
6112
6663
  index: typeof S.Number;
6113
6664
  message: typeof AssistantMessage;
6665
+ reasoning_details: S.optionalWith<S.Array$<typeof Schema3>, {
6666
+ nullable: true;
6667
+ }>;
6114
6668
  logprobs: S.optionalWith<typeof ChatMessageTokenLogprobs, {
6115
6669
  nullable: true;
6116
6670
  }>;
@@ -6122,6 +6676,10 @@ declare const ChatResponseChoice_base: S.Class<ChatResponseChoice, {
6122
6676
  readonly logprobs?: ChatMessageTokenLogprobs | undefined;
6123
6677
  } & {
6124
6678
  readonly finish_reason: "length" | "content_filter" | "error" | "stop" | "tool_calls" | null;
6679
+ } & {
6680
+ readonly reasoning_details?: readonly {
6681
+ readonly [x: string]: unknown;
6682
+ }[] | undefined;
6125
6683
  }, {}, {}>;
6126
6684
  export declare class ChatResponseChoice extends ChatResponseChoice_base {
6127
6685
  }
@@ -6456,12 +7014,12 @@ declare const CompletionCreateParams_base: S.Class<CompletionCreateParams, {
6456
7014
  }>;
6457
7015
  }>, never, {
6458
7016
  readonly max_tokens?: number | undefined;
7017
+ } & {
7018
+ readonly model?: string | undefined;
6459
7019
  } & {
6460
7020
  readonly metadata?: {
6461
7021
  readonly [x: string]: unknown;
6462
7022
  } | undefined;
6463
- } & {
6464
- readonly model?: string | undefined;
6465
7023
  } & {
6466
7024
  readonly models?: readonly string[] | undefined;
6467
7025
  } & {
@@ -6541,19 +7099,35 @@ declare const CompletionChoice_base: S.Class<CompletionChoice, {
6541
7099
  index: typeof S.Number;
6542
7100
  logprobs: S.NullOr<typeof CompletionLogprobs>;
6543
7101
  finish_reason: S.NullOr<S.Literal<["stop", "length", "content_filter"]>>;
7102
+ native_finish_reason: S.optionalWith<typeof S.String, {
7103
+ nullable: true;
7104
+ }>;
7105
+ reasoning: S.optionalWith<typeof S.String, {
7106
+ nullable: true;
7107
+ }>;
6544
7108
  }, S.Struct.Encoded<{
6545
7109
  text: typeof S.String;
6546
7110
  index: typeof S.Number;
6547
7111
  logprobs: S.NullOr<typeof CompletionLogprobs>;
6548
7112
  finish_reason: S.NullOr<S.Literal<["stop", "length", "content_filter"]>>;
7113
+ native_finish_reason: S.optionalWith<typeof S.String, {
7114
+ nullable: true;
7115
+ }>;
7116
+ reasoning: S.optionalWith<typeof S.String, {
7117
+ nullable: true;
7118
+ }>;
6549
7119
  }>, never, {
6550
7120
  readonly index: number;
6551
7121
  } & {
6552
7122
  readonly text: string;
7123
+ } & {
7124
+ readonly reasoning?: string | undefined;
6553
7125
  } & {
6554
7126
  readonly logprobs: CompletionLogprobs | null;
6555
7127
  } & {
6556
7128
  readonly finish_reason: "length" | "content_filter" | "stop" | null;
7129
+ } & {
7130
+ readonly native_finish_reason?: string | undefined;
6557
7131
  }, {}, {}>;
6558
7132
  export declare class CompletionChoice extends CompletionChoice_base {
6559
7133
  }
@@ -6579,6 +7153,9 @@ declare const CompletionResponse_base: S.Class<CompletionResponse, {
6579
7153
  object: S.Literal<["text_completion"]>;
6580
7154
  created: typeof S.Number;
6581
7155
  model: typeof S.String;
7156
+ provider: S.optionalWith<typeof S.String, {
7157
+ nullable: true;
7158
+ }>;
6582
7159
  system_fingerprint: S.optionalWith<typeof S.String, {
6583
7160
  nullable: true;
6584
7161
  }>;
@@ -6591,6 +7168,9 @@ declare const CompletionResponse_base: S.Class<CompletionResponse, {
6591
7168
  object: S.Literal<["text_completion"]>;
6592
7169
  created: typeof S.Number;
6593
7170
  model: typeof S.String;
7171
+ provider: S.optionalWith<typeof S.String, {
7172
+ nullable: true;
7173
+ }>;
6594
7174
  system_fingerprint: S.optionalWith<typeof S.String, {
6595
7175
  nullable: true;
6596
7176
  }>;
@@ -6604,6 +7184,8 @@ declare const CompletionResponse_base: S.Class<CompletionResponse, {
6604
7184
  readonly id: string;
6605
7185
  } & {
6606
7186
  readonly model: string;
7187
+ } & {
7188
+ readonly provider?: string | undefined;
6607
7189
  } & {
6608
7190
  readonly usage?: CompletionUsage | undefined;
6609
7191
  } & {