@inference-gateway/sdk 0.7.3 → 0.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,65 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [0.8.3](https://github.com/inference-gateway/typescript-sdk/compare/v0.8.2...v0.8.3) (2026-05-06)
6
+
7
+ ### 👷 CI
8
+
9
+ * Drop NPM_TOKEN fallback now that Trusted Publishing is live ([005af68](https://github.com/inference-gateway/typescript-sdk/commit/005af68af7eedadefcf28b8dfd305ff7d5f751ac))
10
+
11
+ ## [0.8.2](https://github.com/inference-gateway/typescript-sdk/compare/v0.8.1...v0.8.2) (2026-05-06)
12
+
13
+ ### 👷 CI
14
+
15
+ * Grant id-token write permission for npm Trusted Publishing ([36b2e88](https://github.com/inference-gateway/typescript-sdk/commit/36b2e881313b4b5d73ba6479eb5c7e664d4dd291))
16
+
17
+ ## [0.8.1](https://github.com/inference-gateway/typescript-sdk/compare/v0.8.0...v0.8.1) (2026-05-06)
18
+
19
+ ### 🐛 Bug Fixes
20
+
21
+ * Exclude test files from published npm tarball ([56a3f5e](https://github.com/inference-gateway/typescript-sdk/commit/56a3f5e2caeb15baa034e1b35d04f92a56ca96f2)), closes [package.json#files](https://github.com/inference-gateway/package.json/issues/files)
22
+
23
+ ## [0.8.0](https://github.com/inference-gateway/typescript-sdk/compare/v0.7.3...v0.8.0) (2026-05-06)
24
+
25
+ ### ✨ Features
26
+
27
+ * Adopt latest OpenAPI spec and preserve tool-call extra_content ([193184c](https://github.com/inference-gateway/typescript-sdk/commit/193184c5d9513fc8681606da860c409655f9453f))
28
+ * **providers:** Add Google provider support ([#21](https://github.com/inference-gateway/typescript-sdk/issues/21)) ([a6381d7](https://github.com/inference-gateway/typescript-sdk/commit/a6381d7357d22f32434599e204955fff4db2e3e0)), closes [#19](https://github.com/inference-gateway/typescript-sdk/issues/19)
29
+
30
+ ### ♻️ Improvements
31
+
32
+ * Rename all instances of deepseek-chat to deepseek-v4-flash ([465851e](https://github.com/inference-gateway/typescript-sdk/commit/465851e8f49fba153d1ded6add5d3511507ee50e))
33
+
34
+ ### 👷 CI
35
+
36
+ * Add Claude Code GitHub Workflow ([#20](https://github.com/inference-gateway/typescript-sdk/issues/20)) ([83e61a0](https://github.com/inference-gateway/typescript-sdk/commit/83e61a01fb2fcfc63f06ea2fc1cebb6076285b17))
37
+ * Bump all actions to latest ([d23eef1](https://github.com/inference-gateway/typescript-sdk/commit/d23eef13fa6f4d015059b98bd90a75c4b8f3ddf7))
38
+
39
+ ### 📚 Documentation
40
+
41
+ * Add more examples how to use this sdk ([#16](https://github.com/inference-gateway/typescript-sdk/issues/16)) ([5bddd0b](https://github.com/inference-gateway/typescript-sdk/commit/5bddd0beb693e1ed3341f8c48511dd5e9045729d))
42
+ * Add CLAUDE.md for project guidance and development instructions ([47645bf](https://github.com/inference-gateway/typescript-sdk/commit/47645bfd0f9e0f5c0c83051acbdd52253318522d))
43
+
44
+ ### 🔧 Miscellaneous
45
+
46
+ * Add .vscode to gitignore ([6e3117e](https://github.com/inference-gateway/typescript-sdk/commit/6e3117e0b6344747acc36ba21f747d10118560a2))
47
+ * Add issue templates ([769f017](https://github.com/inference-gateway/typescript-sdk/commit/769f017bf6810c687bc11795fbcb545ffaaaa446))
48
+ * Add project configuration and documentation ([f4bde02](https://github.com/inference-gateway/typescript-sdk/commit/f4bde02757e2d32512ec535e254217d3d81d76a0))
49
+ * Delete CLAUDE.md ([56bc06c](https://github.com/inference-gateway/typescript-sdk/commit/56bc06c85b061d6c7674173b60ab3dde6e0f9b69))
50
+ * **deps:** Bump all version to latest ([0d02bc5](https://github.com/inference-gateway/typescript-sdk/commit/0d02bc5045696a3046cb5460eeb1601b039accdb))
51
+ * **deps:** Install task runner for local env ([be7a77f](https://github.com/inference-gateway/typescript-sdk/commit/be7a77ffe5bcb05980a73604190661b2a079cb2e))
52
+ * **deps:** Update to their latest ([741971b](https://github.com/inference-gateway/typescript-sdk/commit/741971bd3d9f8a4ab80590b5c3b6a374dc292940))
53
+ * Download the latest oas ([9fcf5da](https://github.com/inference-gateway/typescript-sdk/commit/9fcf5da1b7cc12661e3222155c885fae77cb1931))
54
+ * Lock the versions of npm and node in package.json ([9690d75](https://github.com/inference-gateway/typescript-sdk/commit/9690d7501b8edd49bb30c9d0274247802c9bfde4))
55
+ * Remove deprecated lines from husky ([177d464](https://github.com/inference-gateway/typescript-sdk/commit/177d46459c9ffb190dbad41808e7f9ed207ed1e7))
56
+ * Replace devcontainer with Flox environment and streamline CI ([08c1eaf](https://github.com/inference-gateway/typescript-sdk/commit/08c1eaf3ac525153445ab2e1db5fc7b0c79c9457))
57
+ * Run task generate-types ([e01feff](https://github.com/inference-gateway/typescript-sdk/commit/e01feffba970085449bae28fcc49132f84e27ae8))
58
+ * Update GitHub Actions dependencies ([31006d8](https://github.com/inference-gateway/typescript-sdk/commit/31006d898f64d996d225818f3b93f38df644ae3f))
59
+
60
+ ### 🎨 Miscellaneous
61
+
62
+ * Fix markdown lint errors across all documentation ([419062d](https://github.com/inference-gateway/typescript-sdk/commit/419062d726106aa84b88f805a75f3acb48582ca7))
63
+
5
64
  ## [0.7.3](https://github.com/inference-gateway/typescript-sdk/compare/v0.7.2...v0.7.3) (2025-06-01)
6
65
 
7
66
  ### ♻️ Improvements
package/README.md CHANGED
@@ -62,7 +62,8 @@ try {
62
62
 
63
63
  ### Listing MCP Tools
64
64
 
65
- To list available Model Context Protocol (MCP) tools (only available when EXPOSE_MCP is enabled):
65
+ To list available Model Context Protocol (MCP) tools (only available when
66
+ EXPOSE_MCP is enabled):
66
67
 
67
68
  ```typescript
68
69
  import { InferenceGatewayClient } from '@inference-gateway/sdk';
@@ -116,7 +117,7 @@ try {
116
117
  },
117
118
  ],
118
119
  },
119
- Provider.OpenAI
120
+ Provider.openai
120
121
  ); // Provider is optional
121
122
 
122
123
  console.log('Response:', response.choices[0].message.content);
@@ -159,7 +160,7 @@ try {
159
160
  onFinish: () => console.log('\nStream completed'),
160
161
  onError: (error) => console.error('Stream error:', error),
161
162
  },
162
- Provider.Groq // Provider is optional
163
+ Provider.groq // Provider is optional
163
164
  );
164
165
  } catch (error) {
165
166
  console.error('Error:', error);
@@ -241,7 +242,7 @@ const client = new InferenceGatewayClient({
241
242
  });
242
243
 
243
244
  try {
244
- const response = await client.proxy(Provider.OpenAI, 'embeddings', {
245
+ const response = await client.proxy(Provider.openai, 'embeddings', {
245
246
  method: 'POST',
246
247
  body: JSON.stringify({
247
248
  model: 'text-embedding-ada-002',
@@ -300,7 +301,8 @@ For more examples, check the [examples directory](./examples).
300
301
 
301
302
  ## Contributing
302
303
 
303
- Please refer to the [CONTRIBUTING.md](CONTRIBUTING.md) file for information about how to get involved. We welcome issues, questions, and pull requests.
304
+ Please refer to the [CONTRIBUTING.md](CONTRIBUTING.md) file for information
305
+ about how to get involved. We welcome issues, questions, and pull requests.
304
306
 
305
307
  ## License
306
308
 
@@ -133,6 +133,7 @@ class StreamProcessor {
133
133
  name: toolCallChunk.function?.name || '',
134
134
  arguments: toolCallChunk.function?.arguments || '',
135
135
  },
136
+ extra_content: toolCallChunk.extra_content,
136
137
  });
137
138
  }
138
139
  else {
@@ -147,6 +148,9 @@ class StreamProcessor {
147
148
  existingToolCall.function.arguments +=
148
149
  toolCallChunk.function.arguments;
149
150
  }
151
+ if (toolCallChunk.extra_content) {
152
+ existingToolCall.extra_content = toolCallChunk.extra_content;
153
+ }
150
154
  }
151
155
  }
152
156
  }
@@ -169,6 +173,9 @@ class StreamProcessor {
169
173
  name: toolCall.function.name,
170
174
  arguments: toolCall.function.arguments,
171
175
  },
176
+ ...(toolCall.extra_content && {
177
+ extra_content: toolCall.extra_content,
178
+ }),
172
179
  };
173
180
  if (this.isMCPTool(toolCall.function.name)) {
174
181
  try {
@@ -14,7 +14,6 @@ export interface paths {
14
14
  * Lists the currently available models, and provides basic information about each one such as the owner and availability.
15
15
  * @description Lists the currently available models, and provides basic information
16
16
  * about each one such as the owner and availability.
17
- *
18
17
  */
19
18
  get: operations['listModels'];
20
19
  put?: never;
@@ -38,7 +37,6 @@ export interface paths {
38
37
  * Create a chat completion
39
38
  * @description Generates a chat completion based on the provided input.
40
39
  * The completion can be streamed to the client as it is generated.
41
- *
42
40
  */
43
41
  post: operations['createChatCompletion'];
44
42
  delete?: never;
@@ -57,7 +55,6 @@ export interface paths {
57
55
  /**
58
56
  * Lists the currently available MCP tools
59
57
  * @description Lists the currently available MCP tools. Only accessible when EXPOSE_MCP is enabled.
60
- *
61
58
  */
62
59
  get: operations['listTools'];
63
60
  put?: never;
@@ -84,7 +81,6 @@ export interface paths {
84
81
  * @description Proxy GET request to provider
85
82
  * The request body depends on the specific provider and endpoint being called.
86
83
  * If you decide to use this approach, please follow the provider-specific documentations.
87
- *
88
84
  */
89
85
  get: operations['proxyGet'];
90
86
  /**
@@ -92,7 +88,6 @@ export interface paths {
92
88
  * @description Proxy PUT request to provider
93
89
  * The request body depends on the specific provider and endpoint being called.
94
90
  * If you decide to use this approach, please follow the provider-specific documentations.
95
- *
96
91
  */
97
92
  put: operations['proxyPut'];
98
93
  /**
@@ -100,7 +95,6 @@ export interface paths {
100
95
  * @description Proxy POST request to provider
101
96
  * The request body depends on the specific provider and endpoint being called.
102
97
  * If you decide to use this approach, please follow the provider-specific documentations.
103
- *
104
98
  */
105
99
  post: operations['proxyPost'];
106
100
  /**
@@ -108,7 +102,6 @@ export interface paths {
108
102
  * @description Proxy DELETE request to provider
109
103
  * The request body depends on the specific provider and endpoint being called.
110
104
  * If you decide to use this approach, please follow the provider-specific documentations.
111
- *
112
105
  */
113
106
  delete: operations['proxyDelete'];
114
107
  options?: never;
@@ -118,7 +111,6 @@ export interface paths {
118
111
  * @description Proxy PATCH request to provider
119
112
  * The request body depends on the specific provider and endpoint being called.
120
113
  * If you decide to use this approach, please follow the provider-specific documentations.
121
- *
122
114
  */
123
115
  patch: operations['proxyPatch'];
124
116
  trace?: never;
@@ -134,7 +126,6 @@ export interface paths {
134
126
  * Health check
135
127
  * @description Health check endpoint
136
128
  * Returns a 200 status code if the service is healthy
137
- *
138
129
  */
139
130
  get: operations['healthCheck'];
140
131
  put?: never;
@@ -151,7 +142,8 @@ export interface components {
151
142
  schemas: {
152
143
  /** @enum {string} */
153
144
  Provider: Provider;
154
- /** @description Provider-specific response format. Examples:
145
+ /**
146
+ * @description Provider-specific response format. Examples:
155
147
  *
156
148
  * OpenAI GET /v1/models?provider=openai response:
157
149
  * ```json
@@ -186,7 +178,7 @@ export interface components {
186
178
  * ]
187
179
  * }
188
180
  * ```
189
- * */
181
+ */
190
182
  ProviderSpecificResponse: Record<string, never>;
191
183
  /**
192
184
  * @description Authentication type for providers
@@ -215,7 +207,7 @@ export interface components {
215
207
  /** @description Message structure for provider requests */
216
208
  Message: {
217
209
  role: components['schemas']['MessageRole'];
218
- content: string;
210
+ content: components['schemas']['MessageContent'];
219
211
  tool_calls?: components['schemas']['ChatCompletionMessageToolCall'][];
220
212
  tool_call_id?: string;
221
213
  /** @description The reasoning content of the chunk message. */
@@ -223,6 +215,40 @@ export interface components {
223
215
  /** @description The reasoning of the chunk message. Same as reasoning_content. */
224
216
  reasoning?: string;
225
217
  };
218
+ /** @description Message content - either text or multimodal content parts */
219
+ MessageContent: string | components['schemas']['ContentPart'][];
220
+ /** @description A content part within a multimodal message */
221
+ ContentPart: components['schemas']['TextContentPart'] | components['schemas']['ImageContentPart'];
222
+ /** @description Text content part */
223
+ TextContentPart: {
224
+ /**
225
+ * @description Content type identifier
226
+ * @enum {string}
227
+ */
228
+ type: TextContentPartType;
229
+ /** @description The text content */
230
+ text: string;
231
+ };
232
+ /** @description Image content part */
233
+ ImageContentPart: {
234
+ /**
235
+ * @description Content type identifier
236
+ * @enum {string}
237
+ */
238
+ type: ImageContentPartType;
239
+ image_url: components['schemas']['ImageURL'];
240
+ };
241
+ /** @description Image URL configuration */
242
+ ImageURL: {
243
+ /** @description URL of the image (data URLs supported) */
244
+ url: string;
245
+ /**
246
+ * @description Image detail level for vision processing
247
+ * @default auto
248
+ * @enum {string}
249
+ */
250
+ detail: ImageURLDetail;
251
+ };
226
252
  /** @description Common model information */
227
253
  Model: {
228
254
  id: string;
@@ -304,8 +330,10 @@ export interface components {
304
330
  type: components['schemas']['ChatCompletionToolType'];
305
331
  function: components['schemas']['FunctionObject'];
306
332
  };
307
- /** @description The parameters the functions accepts, described as a JSON Schema object. See the [guide](/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
308
- * Omitting `parameters` defines a function with an empty parameter list. */
333
+ /**
334
+ * @description The parameters the functions accepts, described as a JSON Schema object. See the [guide](/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
335
+ * Omitting `parameters` defines a function with an empty parameter list.
336
+ */
309
337
  FunctionParameters: {
310
338
  [key: string]: unknown;
311
339
  };
@@ -335,35 +363,30 @@ export interface components {
335
363
  */
336
364
  total_tokens: number;
337
365
  };
338
- /** @description Options for streaming response. Only set this when you set `stream: true`.
339
- * */
366
+ /** @description Options for streaming response. Only set this when you set `stream: true`. */
340
367
  ChatCompletionStreamOptions: {
341
- /** @description If set, an additional chunk will be streamed before the `data: [DONE]` message. The `usage` field on this chunk shows the token usage statistics for the entire request, and the `choices` field will always be an empty array. All other chunks will also include a `usage` field, but with a null value.
342
- * */
368
+ /** @description If set, an additional chunk will be streamed before the `data: [DONE]` message. The `usage` field on this chunk shows the token usage statistics for the entire request, and the `choices` field will always be an empty array. All other chunks will also include a `usage` field, but with a null value. */
343
369
  include_usage: boolean;
344
370
  };
345
371
  CreateChatCompletionRequest: {
346
372
  /** @description Model ID to use */
347
373
  model: string;
348
- /** @description A list of messages comprising the conversation so far.
349
- * */
374
+ /** @description A list of messages comprising the conversation so far. */
350
375
  messages: components['schemas']['Message'][];
351
- /** @description An upper bound for the number of tokens that can be generated for a completion, including visible output tokens and reasoning tokens.
352
- * */
376
+ /** @description An upper bound for the number of tokens that can be generated for a completion, including visible output tokens and reasoning tokens. */
353
377
  max_tokens?: number;
354
378
  /**
355
379
  * @description If set to true, the model response data will be streamed to the client as it is generated using [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
356
- *
357
380
  * @default false
358
381
  */
359
382
  stream: boolean;
360
383
  stream_options?: components['schemas']['ChatCompletionStreamOptions'];
361
- /** @description A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.
362
- * */
384
+ /** @description A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported. */
363
385
  tools?: components['schemas']['ChatCompletionTool'][];
364
- /** @description The format of the reasoning content. Can be `raw` or `parsed`.
386
+ /**
387
+ * @description The format of the reasoning content. Can be `raw` or `parsed`.
365
388
  * When specified as raw some reasoning models will output <think /> tags. When specified as parsed the model will output the reasoning under `reasoning` or `reasoning_content` attribute.
366
- * */
389
+ */
367
390
  reasoning_format?: string;
368
391
  };
369
392
  /** @description The function that the model called. */
@@ -378,17 +401,10 @@ export interface components {
378
401
  id: string;
379
402
  type: components['schemas']['ChatCompletionToolType'];
380
403
  function: components['schemas']['ChatCompletionMessageToolCallFunction'];
404
+ extra_content?: components['schemas']['ToolCallExtraContent'];
381
405
  };
382
406
  ChatCompletionChoice: {
383
- /**
384
- * @description The reason the model stopped generating tokens. This will be `stop` if the model hit a natural stop point or a provided stop sequence,
385
- * `length` if the maximum number of tokens specified in the request was reached,
386
- * `content_filter` if content was omitted due to a flag from our content filters,
387
- * `tool_calls` if the model called a tool.
388
- *
389
- * @enum {string}
390
- */
391
- finish_reason: ChatCompletionChoiceFinish_reason;
407
+ finish_reason: components['schemas']['FinishReason'];
392
408
  /** @description The index of the choice in the list of choices. */
393
409
  index: number;
394
410
  message: components['schemas']['Message'];
@@ -439,11 +455,27 @@ export interface components {
439
455
  id?: string;
440
456
  /** @description The type of the tool. Currently, only `function` is supported. */
441
457
  type?: string;
442
- function?: {
443
- /** @description The name of the function to call. */
444
- name?: string;
445
- /** @description The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function. */
446
- arguments?: string;
458
+ function?: components['schemas']['ChatCompletionMessageToolCallFunction'];
459
+ extra_content?: components['schemas']['ToolCallExtraContent'];
460
+ };
461
+ /**
462
+ * @description Provider-specific opaque data attached to a tool call. The contents are
463
+ * not interpreted by the gateway, but must be echoed back verbatim on the
464
+ * next request that references this tool call. Currently used by Google
465
+ * Gemini extended-thinking models to carry the per-call `thought_signature`.
466
+ * Other providers may ignore the field.
467
+ */
468
+ ToolCallExtraContent: {
469
+ /** @description Google Gemini-specific extra content. */
470
+ google?: {
471
+ /**
472
+ * @description Opaque signature returned with reasoning-enabled tool calls.
473
+ * Must be echoed back verbatim in the next request that includes
474
+ * this tool call, or Google will reject the request.
475
+ */
476
+ thought_signature?: string;
477
+ } & {
478
+ [key: string]: unknown;
447
479
  };
448
480
  };
449
481
  ChatCompletionTokenLogprob: {
@@ -468,34 +500,37 @@ export interface components {
468
500
  * `length` if the maximum number of tokens specified in the request was reached,
469
501
  * `content_filter` if content was omitted due to a flag from our content filters,
470
502
  * `tool_calls` if the model called a tool.
471
- *
472
503
  * @enum {string}
473
504
  */
474
- FinishReason: ChatCompletionChoiceFinish_reason;
475
- /** @description Represents a streamed chunk of a chat completion response returned
505
+ FinishReason: FinishReason;
506
+ /**
507
+ * @description Represents a streamed chunk of a chat completion response returned
476
508
  * by the model, based on the provided input.
477
- * */
509
+ */
478
510
  CreateChatCompletionStreamResponse: {
479
511
  /** @description A unique identifier for the chat completion. Each chunk has the same ID. */
480
512
  id: string;
481
- /** @description A list of chat completion choices. Can contain more than one elements if `n` is greater than 1. Can also be empty for the
513
+ /**
514
+ * @description A list of chat completion choices. Can contain more than one elements if `n` is greater than 1. Can also be empty for the
482
515
  * last chunk if you set `stream_options: {"include_usage": true}`.
483
- * */
516
+ */
484
517
  choices: components['schemas']['ChatCompletionStreamChoice'][];
485
518
  /** @description The Unix timestamp (in seconds) of when the chat completion was created. Each chunk has the same timestamp. */
486
519
  created: number;
487
520
  /** @description The model to generate the completion. */
488
521
  model: string;
489
- /** @description This fingerprint represents the backend configuration that the model runs with.
522
+ /**
523
+ * @description This fingerprint represents the backend configuration that the model runs with.
490
524
  * Can be used in conjunction with the `seed` request parameter to understand when backend changes have been made that might impact determinism.
491
- * */
525
+ */
492
526
  system_fingerprint?: string;
493
527
  /** @description The object type, which is always `chat.completion.chunk`. */
494
528
  object: string;
495
529
  usage?: components['schemas']['CompletionUsage'];
496
- /** @description The format of the reasoning content. Can be `raw` or `parsed`.
530
+ /**
531
+ * @description The format of the reasoning content. Can be `raw` or `parsed`.
497
532
  * When specified as raw some reasoning models will output <think /> tags. When specified as parsed the model will output the reasoning under reasoning_content.
498
- * */
533
+ */
499
534
  reasoning_format?: string;
500
535
  };
501
536
  Config: unknown;
@@ -534,15 +569,18 @@ export interface components {
534
569
  [name: string]: unknown;
535
570
  };
536
571
  content: {
537
- /** @example {
572
+ /**
573
+ * @example {
538
574
  * "error": "MCP tools endpoint is not exposed. Set EXPOSE_MCP=true to enable."
539
- * } */
575
+ * }
576
+ */
540
577
  'application/json': components['schemas']['Error'];
541
578
  };
542
579
  };
543
- /** @description ProviderResponse depends on the specific provider and endpoint being called
580
+ /**
581
+ * @description ProviderResponse depends on the specific provider and endpoint being called
544
582
  * If you decide to use this approach, please follow the provider-specific documentations.
545
- * */
583
+ */
546
584
  ProviderResponse: {
547
585
  headers: {
548
586
  [name: string]: unknown;
@@ -554,9 +592,10 @@ export interface components {
554
592
  };
555
593
  parameters: never;
556
594
  requestBodies: {
557
- /** @description ProviderRequest depends on the specific provider and endpoint being called
595
+ /**
596
+ * @description ProviderRequest depends on the specific provider and endpoint being called
558
597
  * If you decide to use this approach, please follow the provider-specific documentations.
559
- * */
598
+ */
560
599
  ProviderRequest: {
561
600
  content: {
562
601
  'application/json': {
@@ -573,9 +612,10 @@ export interface components {
573
612
  };
574
613
  };
575
614
  };
576
- /** @description ProviderRequest depends on the specific provider and endpoint being called
615
+ /**
616
+ * @description ProviderRequest depends on the specific provider and endpoint being called
577
617
  * If you decide to use this approach, please follow the provider-specific documentations.
578
- * */
618
+ */
579
619
  CreateChatCompletionRequest: {
580
620
  content: {
581
621
  'application/json': components['schemas']['CreateChatCompletionRequest'];
@@ -585,14 +625,16 @@ export interface components {
585
625
  headers: never;
586
626
  pathItems: never;
587
627
  }
588
- export type SchemaProvider = components['schemas']['Provider'];
589
628
  export type SchemaProviderSpecificResponse = components['schemas']['ProviderSpecificResponse'];
590
- export type SchemaProviderAuthType = components['schemas']['ProviderAuthType'];
591
629
  export type SchemaSsEvent = components['schemas']['SSEvent'];
592
630
  export type SchemaEndpoints = components['schemas']['Endpoints'];
593
631
  export type SchemaError = components['schemas']['Error'];
594
- export type SchemaMessageRole = components['schemas']['MessageRole'];
595
632
  export type SchemaMessage = components['schemas']['Message'];
633
+ export type SchemaMessageContent = components['schemas']['MessageContent'];
634
+ export type SchemaContentPart = components['schemas']['ContentPart'];
635
+ export type SchemaTextContentPart = components['schemas']['TextContentPart'];
636
+ export type SchemaImageContentPart = components['schemas']['ImageContentPart'];
637
+ export type SchemaImageUrl = components['schemas']['ImageURL'];
596
638
  export type SchemaModel = components['schemas']['Model'];
597
639
  export type SchemaListModelsResponse = components['schemas']['ListModelsResponse'];
598
640
  export type SchemaListToolsResponse = components['schemas']['ListToolsResponse'];
@@ -600,7 +642,6 @@ export type SchemaMcpTool = components['schemas']['MCPTool'];
600
642
  export type SchemaFunctionObject = components['schemas']['FunctionObject'];
601
643
  export type SchemaChatCompletionTool = components['schemas']['ChatCompletionTool'];
602
644
  export type SchemaFunctionParameters = components['schemas']['FunctionParameters'];
603
- export type SchemaChatCompletionToolType = components['schemas']['ChatCompletionToolType'];
604
645
  export type SchemaCompletionUsage = components['schemas']['CompletionUsage'];
605
646
  export type SchemaChatCompletionStreamOptions = components['schemas']['ChatCompletionStreamOptions'];
606
647
  export type SchemaCreateChatCompletionRequest = components['schemas']['CreateChatCompletionRequest'];
@@ -611,8 +652,8 @@ export type SchemaChatCompletionStreamChoice = components['schemas']['ChatComple
611
652
  export type SchemaCreateChatCompletionResponse = components['schemas']['CreateChatCompletionResponse'];
612
653
  export type SchemaChatCompletionStreamResponseDelta = components['schemas']['ChatCompletionStreamResponseDelta'];
613
654
  export type SchemaChatCompletionMessageToolCallChunk = components['schemas']['ChatCompletionMessageToolCallChunk'];
655
+ export type SchemaToolCallExtraContent = components['schemas']['ToolCallExtraContent'];
614
656
  export type SchemaChatCompletionTokenLogprob = components['schemas']['ChatCompletionTokenLogprob'];
615
- export type SchemaFinishReason = components['schemas']['FinishReason'];
616
657
  export type SchemaCreateChatCompletionStreamResponse = components['schemas']['CreateChatCompletionStreamResponse'];
617
658
  export type SchemaConfig = components['schemas']['Config'];
618
659
  export type ResponseBadRequest = components['responses']['BadRequest'];
@@ -815,12 +856,16 @@ export interface operations {
815
856
  }
816
857
  export declare enum Provider {
817
858
  ollama = "ollama",
859
+ ollama_cloud = "ollama_cloud",
818
860
  groq = "groq",
819
861
  openai = "openai",
820
862
  cloudflare = "cloudflare",
821
863
  cohere = "cohere",
822
864
  anthropic = "anthropic",
823
- deepseek = "deepseek"
865
+ deepseek = "deepseek",
866
+ google = "google",
867
+ mistral = "mistral",
868
+ moonshot = "moonshot"
824
869
  }
825
870
  export declare enum ProviderAuthType {
826
871
  bearer = "bearer",
@@ -843,10 +888,21 @@ export declare enum MessageRole {
843
888
  assistant = "assistant",
844
889
  tool = "tool"
845
890
  }
891
+ export declare enum TextContentPartType {
892
+ text = "text"
893
+ }
894
+ export declare enum ImageContentPartType {
895
+ image_url = "image_url"
896
+ }
897
+ export declare enum ImageURLDetail {
898
+ auto = "auto",
899
+ low = "low",
900
+ high = "high"
901
+ }
846
902
  export declare enum ChatCompletionToolType {
847
903
  function = "function"
848
904
  }
849
- export declare enum ChatCompletionChoiceFinish_reason {
905
+ export declare enum FinishReason {
850
906
  stop = "stop",
851
907
  length = "length",
852
908
  tool_calls = "tool_calls",
@@ -4,16 +4,20 @@
4
4
  * Do not make direct changes to the file.
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.ChatCompletionChoiceFinish_reason = exports.ChatCompletionToolType = exports.MessageRole = exports.SSEventEvent = exports.ProviderAuthType = exports.Provider = void 0;
7
+ exports.FinishReason = exports.ChatCompletionToolType = exports.ImageURLDetail = exports.ImageContentPartType = exports.TextContentPartType = exports.MessageRole = exports.SSEventEvent = exports.ProviderAuthType = exports.Provider = void 0;
8
8
  var Provider;
9
9
  (function (Provider) {
10
10
  Provider["ollama"] = "ollama";
11
+ Provider["ollama_cloud"] = "ollama_cloud";
11
12
  Provider["groq"] = "groq";
12
13
  Provider["openai"] = "openai";
13
14
  Provider["cloudflare"] = "cloudflare";
14
15
  Provider["cohere"] = "cohere";
15
16
  Provider["anthropic"] = "anthropic";
16
17
  Provider["deepseek"] = "deepseek";
18
+ Provider["google"] = "google";
19
+ Provider["mistral"] = "mistral";
20
+ Provider["moonshot"] = "moonshot";
17
21
  })(Provider || (exports.Provider = Provider = {}));
18
22
  var ProviderAuthType;
19
23
  (function (ProviderAuthType) {
@@ -39,15 +43,29 @@ var MessageRole;
39
43
  MessageRole["assistant"] = "assistant";
40
44
  MessageRole["tool"] = "tool";
41
45
  })(MessageRole || (exports.MessageRole = MessageRole = {}));
46
+ var TextContentPartType;
47
+ (function (TextContentPartType) {
48
+ TextContentPartType["text"] = "text";
49
+ })(TextContentPartType || (exports.TextContentPartType = TextContentPartType = {}));
50
+ var ImageContentPartType;
51
+ (function (ImageContentPartType) {
52
+ ImageContentPartType["image_url"] = "image_url";
53
+ })(ImageContentPartType || (exports.ImageContentPartType = ImageContentPartType = {}));
54
+ var ImageURLDetail;
55
+ (function (ImageURLDetail) {
56
+ ImageURLDetail["auto"] = "auto";
57
+ ImageURLDetail["low"] = "low";
58
+ ImageURLDetail["high"] = "high";
59
+ })(ImageURLDetail || (exports.ImageURLDetail = ImageURLDetail = {}));
42
60
  var ChatCompletionToolType;
43
61
  (function (ChatCompletionToolType) {
44
62
  ChatCompletionToolType["function"] = "function";
45
63
  })(ChatCompletionToolType || (exports.ChatCompletionToolType = ChatCompletionToolType = {}));
46
- var ChatCompletionChoiceFinish_reason;
47
- (function (ChatCompletionChoiceFinish_reason) {
48
- ChatCompletionChoiceFinish_reason["stop"] = "stop";
49
- ChatCompletionChoiceFinish_reason["length"] = "length";
50
- ChatCompletionChoiceFinish_reason["tool_calls"] = "tool_calls";
51
- ChatCompletionChoiceFinish_reason["content_filter"] = "content_filter";
52
- ChatCompletionChoiceFinish_reason["function_call"] = "function_call";
53
- })(ChatCompletionChoiceFinish_reason || (exports.ChatCompletionChoiceFinish_reason = ChatCompletionChoiceFinish_reason = {}));
64
+ var FinishReason;
65
+ (function (FinishReason) {
66
+ FinishReason["stop"] = "stop";
67
+ FinishReason["length"] = "length";
68
+ FinishReason["tool_calls"] = "tool_calls";
69
+ FinishReason["content_filter"] = "content_filter";
70
+ FinishReason["function_call"] = "function_call";
71
+ })(FinishReason || (exports.FinishReason = FinishReason = {}));