@agentdock/wire 0.0.95 → 0.0.96

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/gateway.d.ts CHANGED
@@ -1,71 +1,9 @@
1
1
  import { z } from 'zod';
2
- export declare const GatewayRouteStatusSchema: z.ZodEnum<["draft", "validating", "active", "disabled", "error"]>;
3
- export type GatewayRouteStatus = z.infer<typeof GatewayRouteStatusSchema>;
4
2
  export declare const GatewayProtocolSchema: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
5
3
  export type GatewayProtocol = z.infer<typeof GatewayProtocolSchema>;
6
- export declare const GatewayErrorCodeSchema: z.ZodEnum<["unauthorized", "route-not-found", "route-disabled", "connection-disabled", "protocol-not-supported", "request-too-large", "upstream-timeout", "upstream-unavailable", "client-aborted", "model-not-allowed", "invalid-request"]>;
7
- export type GatewayErrorCode = z.infer<typeof GatewayErrorCodeSchema>;
8
4
 
9
- export declare const GatewayRouteSchema: z.ZodObject<{
10
- id: z.ZodString;
11
- alias: z.ZodString;
12
- enterpriseId: z.ZodString;
13
- agent: z.ZodEnum<["claude", "codex", "opencode"]>;
14
- provider: z.ZodDefault<z.ZodString>;
15
- model: z.ZodString;
16
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
17
- upstreamProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
18
- status: z.ZodEnum<["draft", "validating", "active", "disabled", "error"]>;
19
- connection: z.ZodObject<{
20
- status: z.ZodEnum<["active", "disabled"]>;
21
- baseUrl: z.ZodString;
22
- apiKey: z.ZodString;
23
- authScheme: z.ZodEnum<["x-api-key", "bearer"]>;
24
- }, "strict", z.ZodTypeAny, {
25
- status: "active" | "disabled";
26
- baseUrl: string;
27
- apiKey: string;
28
- authScheme: "x-api-key" | "bearer";
29
- }, {
30
- status: "active" | "disabled";
31
- baseUrl: string;
32
- apiKey: string;
33
- authScheme: "x-api-key" | "bearer";
34
- }>;
35
- }, "strict", z.ZodTypeAny, {
36
- status: "error" | "active" | "disabled" | "draft" | "validating";
37
- model: string;
38
- agent: "codex" | "claude" | "opencode";
39
- id: string;
40
- provider: string;
41
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
42
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
43
- alias: string;
44
- enterpriseId: string;
45
- connection: {
46
- status: "active" | "disabled";
47
- baseUrl: string;
48
- apiKey: string;
49
- authScheme: "x-api-key" | "bearer";
50
- };
51
- }, {
52
- status: "error" | "active" | "disabled" | "draft" | "validating";
53
- model: string;
54
- agent: "codex" | "claude" | "opencode";
55
- id: string;
56
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
57
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
58
- alias: string;
59
- enterpriseId: string;
60
- connection: {
61
- status: "active" | "disabled";
62
- baseUrl: string;
63
- apiKey: string;
64
- authScheme: "x-api-key" | "bearer";
65
- };
66
- provider?: string | undefined;
67
- }>;
68
- export type GatewayRoute = z.infer<typeof GatewayRouteSchema>;
5
+ export declare const GatewayErrorCodeSchema: z.ZodEnum<["unauthorized", "connection-unavailable", "protocol-not-supported", "request-too-large", "upstream-timeout", "upstream-unavailable", "client-aborted", "model-not-allowed", "model-disabled", "invalid-request", "logical-model-not-found", "deployment-not-ready", "connection-keys-not-equivalent", "logical-model-not-in-agent-config", "logical-model-not-authorized", "upstream-model-mapping-missing", "price-rule-conflict", "unsupported-pricing-currency"]>;
6
+ export type GatewayErrorCode = z.infer<typeof GatewayErrorCodeSchema>;
69
7
  export declare const GatewayTokenClaimsSchema: z.ZodObject<{
70
8
  enterpriseId: z.ZodString;
71
9
  userId: z.ZodString;
@@ -80,60 +18,429 @@ export type GatewayTokenClaims = z.infer<typeof GatewayTokenClaimsSchema>;
80
18
  export declare const GatewayConnectionCreateSchema: z.ZodObject<{
81
19
  name: z.ZodString;
82
20
  baseUrl: z.ZodString;
83
- apiKeys: z.ZodArray<z.ZodString, "many">;
84
21
  }, "strict", z.ZodTypeAny, {
85
22
  name: string;
86
23
  baseUrl: string;
87
- apiKeys: string[];
88
24
  }, {
89
25
  name: string;
90
26
  baseUrl: string;
91
- apiKeys: string[];
92
27
  }>;
93
28
  export type GatewayConnectionCreate = z.infer<typeof GatewayConnectionCreateSchema>;
94
29
  export declare const GatewayConnectionUpdateSchema: z.ZodObject<{
95
30
  name: z.ZodOptional<z.ZodString>;
96
31
  baseUrl: z.ZodOptional<z.ZodString>;
97
- apiKeys: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
98
32
  status: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
99
33
  }, "strict", z.ZodTypeAny, {
100
34
  status?: "active" | "disabled" | undefined;
101
35
  name?: string | undefined;
102
36
  baseUrl?: string | undefined;
103
- apiKeys?: string[] | undefined;
104
37
  }, {
105
38
  status?: "active" | "disabled" | undefined;
106
39
  name?: string | undefined;
107
40
  baseUrl?: string | undefined;
108
- apiKeys?: string[] | undefined;
109
41
  }>;
110
42
  export type GatewayConnectionUpdate = z.infer<typeof GatewayConnectionUpdateSchema>;
111
- export declare const GatewayConnectionKeyAddSchema: z.ZodObject<{
112
- apiKey: z.ZodString;
43
+ export declare const GatewayConnectionDiscoveryViewSchema: z.ZodObject<{
44
+ status: z.ZodEnum<["unknown", "succeeded", "empty", "unsupported", "authentication_failed", "unavailable", "timeout"]>;
45
+ checkedAt: z.ZodNullable<z.ZodString>;
46
+ failureCode: z.ZodNullable<z.ZodString>;
47
+ models: z.ZodArray<z.ZodObject<{
48
+ modelId: z.ZodString;
49
+ firstDiscoveredAt: z.ZodString;
50
+ lastDiscoveredAt: z.ZodString;
51
+ }, "strict", z.ZodTypeAny, {
52
+ modelId: string;
53
+ firstDiscoveredAt: string;
54
+ lastDiscoveredAt: string;
55
+ }, {
56
+ modelId: string;
57
+ firstDiscoveredAt: string;
58
+ lastDiscoveredAt: string;
59
+ }>, "many">;
113
60
  }, "strict", z.ZodTypeAny, {
114
- apiKey: string;
61
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
62
+ models: {
63
+ modelId: string;
64
+ firstDiscoveredAt: string;
65
+ lastDiscoveredAt: string;
66
+ }[];
67
+ checkedAt: string | null;
68
+ failureCode: string | null;
115
69
  }, {
116
- apiKey: string;
70
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
71
+ models: {
72
+ modelId: string;
73
+ firstDiscoveredAt: string;
74
+ lastDiscoveredAt: string;
75
+ }[];
76
+ checkedAt: string | null;
77
+ failureCode: string | null;
78
+ }>;
79
+ export type GatewayConnectionDiscoveryView = z.infer<typeof GatewayConnectionDiscoveryViewSchema>;
80
+ export declare const GatewayConnectionDiscoveryResponseSchema: z.ZodObject<{
81
+ ok: z.ZodLiteral<true>;
82
+ data: z.ZodObject<{
83
+ status: z.ZodEnum<["unknown", "succeeded", "empty", "unsupported", "authentication_failed", "unavailable", "timeout"]>;
84
+ checkedAt: z.ZodNullable<z.ZodString>;
85
+ failureCode: z.ZodNullable<z.ZodString>;
86
+ models: z.ZodArray<z.ZodObject<{
87
+ modelId: z.ZodString;
88
+ firstDiscoveredAt: z.ZodString;
89
+ lastDiscoveredAt: z.ZodString;
90
+ }, "strict", z.ZodTypeAny, {
91
+ modelId: string;
92
+ firstDiscoveredAt: string;
93
+ lastDiscoveredAt: string;
94
+ }, {
95
+ modelId: string;
96
+ firstDiscoveredAt: string;
97
+ lastDiscoveredAt: string;
98
+ }>, "many">;
99
+ }, "strict", z.ZodTypeAny, {
100
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
101
+ models: {
102
+ modelId: string;
103
+ firstDiscoveredAt: string;
104
+ lastDiscoveredAt: string;
105
+ }[];
106
+ checkedAt: string | null;
107
+ failureCode: string | null;
108
+ }, {
109
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
110
+ models: {
111
+ modelId: string;
112
+ firstDiscoveredAt: string;
113
+ lastDiscoveredAt: string;
114
+ }[];
115
+ checkedAt: string | null;
116
+ failureCode: string | null;
117
+ }>;
118
+ }, "strict", z.ZodTypeAny, {
119
+ data: {
120
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
121
+ models: {
122
+ modelId: string;
123
+ firstDiscoveredAt: string;
124
+ lastDiscoveredAt: string;
125
+ }[];
126
+ checkedAt: string | null;
127
+ failureCode: string | null;
128
+ };
129
+ ok: true;
130
+ }, {
131
+ data: {
132
+ status: "unknown" | "timeout" | "succeeded" | "empty" | "unsupported" | "authentication_failed" | "unavailable";
133
+ models: {
134
+ modelId: string;
135
+ firstDiscoveredAt: string;
136
+ lastDiscoveredAt: string;
137
+ }[];
138
+ checkedAt: string | null;
139
+ failureCode: string | null;
140
+ };
141
+ ok: true;
142
+ }>;
143
+ export declare const GatewayConnectionProtocolCapabilityViewSchema: z.ZodObject<{
144
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
145
+ status: z.ZodEnum<["supported", "unsupported", "unknown"]>;
146
+
147
+ authScheme: z.ZodNullable<z.ZodEnum<["bearer", "x-api-key"]>>;
148
+ evidenceSource: z.ZodString;
149
+ checkedAt: z.ZodString;
150
+ failureCode: z.ZodNullable<z.ZodString>;
151
+ }, "strict", z.ZodTypeAny, {
152
+ status: "unknown" | "unsupported" | "supported";
153
+ checkedAt: string;
154
+ failureCode: string | null;
155
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
156
+ authScheme: "bearer" | "x-api-key" | null;
157
+ evidenceSource: string;
158
+ }, {
159
+ status: "unknown" | "unsupported" | "supported";
160
+ checkedAt: string;
161
+ failureCode: string | null;
162
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
163
+ authScheme: "bearer" | "x-api-key" | null;
164
+ evidenceSource: string;
165
+ }>;
166
+ export declare const GatewayConnectionProtocolCapabilityResponseSchema: z.ZodObject<{
167
+ ok: z.ZodLiteral<true>;
168
+ data: z.ZodArray<z.ZodObject<{
169
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
170
+ status: z.ZodEnum<["supported", "unsupported", "unknown"]>;
171
+
172
+ authScheme: z.ZodNullable<z.ZodEnum<["bearer", "x-api-key"]>>;
173
+ evidenceSource: z.ZodString;
174
+ checkedAt: z.ZodString;
175
+ failureCode: z.ZodNullable<z.ZodString>;
176
+ }, "strict", z.ZodTypeAny, {
177
+ status: "unknown" | "unsupported" | "supported";
178
+ checkedAt: string;
179
+ failureCode: string | null;
180
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
181
+ authScheme: "bearer" | "x-api-key" | null;
182
+ evidenceSource: string;
183
+ }, {
184
+ status: "unknown" | "unsupported" | "supported";
185
+ checkedAt: string;
186
+ failureCode: string | null;
187
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
188
+ authScheme: "bearer" | "x-api-key" | null;
189
+ evidenceSource: string;
190
+ }>, "many">;
191
+ }, "strict", z.ZodTypeAny, {
192
+ data: {
193
+ status: "unknown" | "unsupported" | "supported";
194
+ checkedAt: string;
195
+ failureCode: string | null;
196
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
197
+ authScheme: "bearer" | "x-api-key" | null;
198
+ evidenceSource: string;
199
+ }[];
200
+ ok: true;
201
+ }, {
202
+ data: {
203
+ status: "unknown" | "unsupported" | "supported";
204
+ checkedAt: string;
205
+ failureCode: string | null;
206
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
207
+ authScheme: "bearer" | "x-api-key" | null;
208
+ evidenceSource: string;
209
+ }[];
210
+ ok: true;
211
+ }>;
212
+
213
+ export declare const GatewayProtocolProbeRequestSchema: z.ZodObject<{
214
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
215
+ modelId: z.ZodString;
216
+ }, "strict", z.ZodTypeAny, {
217
+ modelId: string;
218
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
219
+ }, {
220
+ modelId: string;
221
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
222
+ }>;
223
+ export type GatewayProtocolProbeRequest = z.infer<typeof GatewayProtocolProbeRequestSchema>;
224
+ export declare const GatewayConnectionModelsUpdateSchema: z.ZodObject<{
225
+ models: z.ZodArray<z.ZodString, "many">;
226
+ }, "strict", z.ZodTypeAny, {
227
+ models: string[];
228
+ }, {
229
+ models: string[];
230
+ }>;
231
+ export type GatewayConnectionModelsUpdate = z.infer<typeof GatewayConnectionModelsUpdateSchema>;
232
+ export declare const GatewayConnectionModelsEditorSchema: z.ZodObject<{
233
+ connectionId: z.ZodString;
234
+ modelsConfirmed: z.ZodBoolean;
235
+ availableModels: z.ZodArray<z.ZodString, "many">;
236
+
237
+ overallMultiplier: z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>;
238
+
239
+ perModelMultipliers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodEffects<z.ZodNumber, number, number>>>>;
240
+
241
+ catalogDisabledModels: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
242
+ discovered: z.ZodArray<z.ZodObject<{
243
+ model: z.ZodString;
244
+ inCatalog: z.ZodBoolean;
245
+
246
+ catalogStatus: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
247
+ }, "strict", z.ZodTypeAny, {
248
+ model: string;
249
+ inCatalog: boolean;
250
+ catalogStatus?: "active" | "disabled" | undefined;
251
+ }, {
252
+ model: string;
253
+ inCatalog: boolean;
254
+ catalogStatus?: "active" | "disabled" | undefined;
255
+ }>, "many">;
256
+ }, "strict", z.ZodTypeAny, {
257
+ connectionId: string;
258
+ modelsConfirmed: boolean;
259
+ availableModels: string[];
260
+ discovered: {
261
+ model: string;
262
+ inCatalog: boolean;
263
+ catalogStatus?: "active" | "disabled" | undefined;
264
+ }[];
265
+ overallMultiplier?: number | undefined;
266
+ perModelMultipliers?: Record<string, number | null> | undefined;
267
+ catalogDisabledModels?: string[] | undefined;
268
+ }, {
269
+ connectionId: string;
270
+ modelsConfirmed: boolean;
271
+ availableModels: string[];
272
+ discovered: {
273
+ model: string;
274
+ inCatalog: boolean;
275
+ catalogStatus?: "active" | "disabled" | undefined;
276
+ }[];
277
+ overallMultiplier?: number | undefined;
278
+ perModelMultipliers?: Record<string, number | null> | undefined;
279
+ catalogDisabledModels?: string[] | undefined;
280
+ }>;
281
+ export type GatewayConnectionModelsEditor = z.infer<typeof GatewayConnectionModelsEditorSchema>;
282
+ export declare const GatewayConnectionModelsEditorResponseSchema: z.ZodObject<{
283
+ ok: z.ZodLiteral<true>;
284
+ data: z.ZodObject<{
285
+ connectionId: z.ZodString;
286
+ modelsConfirmed: z.ZodBoolean;
287
+ availableModels: z.ZodArray<z.ZodString, "many">;
288
+
289
+ overallMultiplier: z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>;
290
+
291
+ perModelMultipliers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodEffects<z.ZodNumber, number, number>>>>;
292
+
293
+ catalogDisabledModels: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
294
+ discovered: z.ZodArray<z.ZodObject<{
295
+ model: z.ZodString;
296
+ inCatalog: z.ZodBoolean;
297
+
298
+ catalogStatus: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
299
+ }, "strict", z.ZodTypeAny, {
300
+ model: string;
301
+ inCatalog: boolean;
302
+ catalogStatus?: "active" | "disabled" | undefined;
303
+ }, {
304
+ model: string;
305
+ inCatalog: boolean;
306
+ catalogStatus?: "active" | "disabled" | undefined;
307
+ }>, "many">;
308
+ }, "strict", z.ZodTypeAny, {
309
+ connectionId: string;
310
+ modelsConfirmed: boolean;
311
+ availableModels: string[];
312
+ discovered: {
313
+ model: string;
314
+ inCatalog: boolean;
315
+ catalogStatus?: "active" | "disabled" | undefined;
316
+ }[];
317
+ overallMultiplier?: number | undefined;
318
+ perModelMultipliers?: Record<string, number | null> | undefined;
319
+ catalogDisabledModels?: string[] | undefined;
320
+ }, {
321
+ connectionId: string;
322
+ modelsConfirmed: boolean;
323
+ availableModels: string[];
324
+ discovered: {
325
+ model: string;
326
+ inCatalog: boolean;
327
+ catalogStatus?: "active" | "disabled" | undefined;
328
+ }[];
329
+ overallMultiplier?: number | undefined;
330
+ perModelMultipliers?: Record<string, number | null> | undefined;
331
+ catalogDisabledModels?: string[] | undefined;
332
+ }>;
333
+ }, "strict", z.ZodTypeAny, {
334
+ data: {
335
+ connectionId: string;
336
+ modelsConfirmed: boolean;
337
+ availableModels: string[];
338
+ discovered: {
339
+ model: string;
340
+ inCatalog: boolean;
341
+ catalogStatus?: "active" | "disabled" | undefined;
342
+ }[];
343
+ overallMultiplier?: number | undefined;
344
+ perModelMultipliers?: Record<string, number | null> | undefined;
345
+ catalogDisabledModels?: string[] | undefined;
346
+ };
347
+ ok: true;
348
+ }, {
349
+ data: {
350
+ connectionId: string;
351
+ modelsConfirmed: boolean;
352
+ availableModels: string[];
353
+ discovered: {
354
+ model: string;
355
+ inCatalog: boolean;
356
+ catalogStatus?: "active" | "disabled" | undefined;
357
+ }[];
358
+ overallMultiplier?: number | undefined;
359
+ perModelMultipliers?: Record<string, number | null> | undefined;
360
+ catalogDisabledModels?: string[] | undefined;
361
+ };
362
+ ok: true;
363
+ }>;
364
+
365
+ export declare const GatewayConnectionPriceMultipliersUpdateSchema: z.ZodEffects<z.ZodObject<{
366
+ overallMultiplier: z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>;
367
+ perModelMultipliers: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodEffects<z.ZodNumber, number, number>>>>;
368
+ }, "strict", z.ZodTypeAny, {
369
+ overallMultiplier?: number | undefined;
370
+ perModelMultipliers?: Record<string, number | null> | undefined;
371
+ }, {
372
+ overallMultiplier?: number | undefined;
373
+ perModelMultipliers?: Record<string, number | null> | undefined;
374
+ }>, {
375
+ overallMultiplier?: number | undefined;
376
+ perModelMultipliers?: Record<string, number | null> | undefined;
377
+ }, {
378
+ overallMultiplier?: number | undefined;
379
+ perModelMultipliers?: Record<string, number | null> | undefined;
117
380
  }>;
118
- export type GatewayConnectionKeyAdd = z.infer<typeof GatewayConnectionKeyAddSchema>;
381
+ export type GatewayConnectionPriceMultipliersUpdate = z.infer<typeof GatewayConnectionPriceMultipliersUpdateSchema>;
119
382
  export declare const GatewayConnectionViewSchema: z.ZodObject<{
120
383
  id: z.ZodString;
121
384
  enterpriseId: z.ZodString;
122
385
  name: z.ZodString;
123
386
  baseUrl: z.ZodString;
124
- apiKeyCount: z.ZodNumber;
125
- apiKeys: z.ZodArray<z.ZodObject<{
387
+ status: z.ZodEnum<["active", "disabled"]>;
388
+ metadata: z.ZodUnknown;
389
+ apiKeyCount: z.ZodDefault<z.ZodNumber>;
390
+
391
+ verifiedActiveKeyCount: z.ZodDefault<z.ZodNumber>;
392
+ costMultiplier: z.ZodOptional<z.ZodNumber>;
393
+ modelsConfirmed: z.ZodOptional<z.ZodBoolean>;
394
+ availableModels: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
395
+
396
+ protocolCapabilities: z.ZodOptional<z.ZodArray<z.ZodObject<{
397
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
398
+ status: z.ZodEnum<["supported", "unsupported", "unknown"]>;
399
+
400
+ authScheme: z.ZodNullable<z.ZodEnum<["bearer", "x-api-key"]>>;
401
+ evidenceSource: z.ZodString;
402
+ checkedAt: z.ZodString;
403
+ failureCode: z.ZodNullable<z.ZodString>;
404
+ }, "strict", z.ZodTypeAny, {
405
+ status: "unknown" | "unsupported" | "supported";
406
+ checkedAt: string;
407
+ failureCode: string | null;
408
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
409
+ authScheme: "bearer" | "x-api-key" | null;
410
+ evidenceSource: string;
411
+ }, {
412
+ status: "unknown" | "unsupported" | "supported";
413
+ checkedAt: string;
414
+ failureCode: string | null;
415
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
416
+ authScheme: "bearer" | "x-api-key" | null;
417
+ evidenceSource: string;
418
+ }>, "many">>;
419
+ apiKeys: z.ZodOptional<z.ZodArray<z.ZodObject<{
126
420
  fingerprint: z.ZodString;
127
421
  masked: z.ZodString;
422
+ status: z.ZodString;
423
+ verified: z.ZodBoolean;
424
+ isDefault: z.ZodBoolean;
425
+ createdAt: z.ZodString;
426
+ updatedAt: z.ZodString;
128
427
  }, "strict", z.ZodTypeAny, {
428
+ status: string;
429
+ createdAt: string;
430
+ updatedAt: string;
431
+ isDefault: boolean;
129
432
  fingerprint: string;
130
433
  masked: string;
434
+ verified: boolean;
131
435
  }, {
436
+ status: string;
437
+ createdAt: string;
438
+ updatedAt: string;
439
+ isDefault: boolean;
132
440
  fingerprint: string;
133
441
  masked: string;
134
- }>, "many">;
135
- status: z.ZodEnum<["active", "disabled"]>;
136
- metadata: z.ZodUnknown;
442
+ verified: boolean;
443
+ }>, "many">>;
137
444
  createdAt: z.ZodString;
138
445
  updatedAt: z.ZodString;
139
446
  }, "strict", z.ZodTypeAny, {
@@ -144,12 +451,29 @@ export declare const GatewayConnectionViewSchema: z.ZodObject<{
144
451
  updatedAt: string;
145
452
  baseUrl: string;
146
453
  enterpriseId: string;
147
- apiKeys: {
148
- fingerprint: string;
149
- masked: string;
150
- }[];
454
+ availableModels: string[];
151
455
  apiKeyCount: number;
456
+ verifiedActiveKeyCount: number;
457
+ modelsConfirmed?: boolean | undefined;
152
458
  metadata?: unknown;
459
+ costMultiplier?: number | undefined;
460
+ protocolCapabilities?: {
461
+ status: "unknown" | "unsupported" | "supported";
462
+ checkedAt: string;
463
+ failureCode: string | null;
464
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
465
+ authScheme: "bearer" | "x-api-key" | null;
466
+ evidenceSource: string;
467
+ }[] | undefined;
468
+ apiKeys?: {
469
+ status: string;
470
+ createdAt: string;
471
+ updatedAt: string;
472
+ isDefault: boolean;
473
+ fingerprint: string;
474
+ masked: string;
475
+ verified: boolean;
476
+ }[] | undefined;
153
477
  }, {
154
478
  status: "active" | "disabled";
155
479
  name: string;
@@ -158,12 +482,29 @@ export declare const GatewayConnectionViewSchema: z.ZodObject<{
158
482
  updatedAt: string;
159
483
  baseUrl: string;
160
484
  enterpriseId: string;
161
- apiKeys: {
485
+ modelsConfirmed?: boolean | undefined;
486
+ availableModels?: string[] | undefined;
487
+ metadata?: unknown;
488
+ apiKeyCount?: number | undefined;
489
+ verifiedActiveKeyCount?: number | undefined;
490
+ costMultiplier?: number | undefined;
491
+ protocolCapabilities?: {
492
+ status: "unknown" | "unsupported" | "supported";
493
+ checkedAt: string;
494
+ failureCode: string | null;
495
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
496
+ authScheme: "bearer" | "x-api-key" | null;
497
+ evidenceSource: string;
498
+ }[] | undefined;
499
+ apiKeys?: {
500
+ status: string;
501
+ createdAt: string;
502
+ updatedAt: string;
503
+ isDefault: boolean;
162
504
  fingerprint: string;
163
505
  masked: string;
164
- }[];
165
- apiKeyCount: number;
166
- metadata?: unknown;
506
+ verified: boolean;
507
+ }[] | undefined;
167
508
  }>;
168
509
  export type GatewayConnectionView = z.infer<typeof GatewayConnectionViewSchema>;
169
510
  export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
@@ -173,19 +514,63 @@ export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
173
514
  enterpriseId: z.ZodString;
174
515
  name: z.ZodString;
175
516
  baseUrl: z.ZodString;
176
- apiKeyCount: z.ZodNumber;
177
- apiKeys: z.ZodArray<z.ZodObject<{
517
+ status: z.ZodEnum<["active", "disabled"]>;
518
+ metadata: z.ZodUnknown;
519
+ apiKeyCount: z.ZodDefault<z.ZodNumber>;
520
+
521
+ verifiedActiveKeyCount: z.ZodDefault<z.ZodNumber>;
522
+ costMultiplier: z.ZodOptional<z.ZodNumber>;
523
+ modelsConfirmed: z.ZodOptional<z.ZodBoolean>;
524
+ availableModels: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
525
+
526
+ protocolCapabilities: z.ZodOptional<z.ZodArray<z.ZodObject<{
527
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
528
+ status: z.ZodEnum<["supported", "unsupported", "unknown"]>;
529
+
530
+ authScheme: z.ZodNullable<z.ZodEnum<["bearer", "x-api-key"]>>;
531
+ evidenceSource: z.ZodString;
532
+ checkedAt: z.ZodString;
533
+ failureCode: z.ZodNullable<z.ZodString>;
534
+ }, "strict", z.ZodTypeAny, {
535
+ status: "unknown" | "unsupported" | "supported";
536
+ checkedAt: string;
537
+ failureCode: string | null;
538
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
539
+ authScheme: "bearer" | "x-api-key" | null;
540
+ evidenceSource: string;
541
+ }, {
542
+ status: "unknown" | "unsupported" | "supported";
543
+ checkedAt: string;
544
+ failureCode: string | null;
545
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
546
+ authScheme: "bearer" | "x-api-key" | null;
547
+ evidenceSource: string;
548
+ }>, "many">>;
549
+ apiKeys: z.ZodOptional<z.ZodArray<z.ZodObject<{
178
550
  fingerprint: z.ZodString;
179
551
  masked: z.ZodString;
552
+ status: z.ZodString;
553
+ verified: z.ZodBoolean;
554
+ isDefault: z.ZodBoolean;
555
+ createdAt: z.ZodString;
556
+ updatedAt: z.ZodString;
180
557
  }, "strict", z.ZodTypeAny, {
558
+ status: string;
559
+ createdAt: string;
560
+ updatedAt: string;
561
+ isDefault: boolean;
181
562
  fingerprint: string;
182
563
  masked: string;
564
+ verified: boolean;
183
565
  }, {
566
+ status: string;
567
+ createdAt: string;
568
+ updatedAt: string;
569
+ isDefault: boolean;
184
570
  fingerprint: string;
185
571
  masked: string;
186
- }>, "many">;
187
- status: z.ZodEnum<["active", "disabled"]>;
188
- metadata: z.ZodUnknown;
572
+ verified: boolean;
573
+ }>, "many">>;
189
574
  createdAt: z.ZodString;
190
575
  updatedAt: z.ZodString;
191
576
  }, "strict", z.ZodTypeAny, {
@@ -196,12 +581,29 @@ export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
196
581
  updatedAt: string;
197
582
  baseUrl: string;
198
583
  enterpriseId: string;
199
- apiKeys: {
200
- fingerprint: string;
201
- masked: string;
202
- }[];
584
+ availableModels: string[];
203
585
  apiKeyCount: number;
586
+ verifiedActiveKeyCount: number;
587
+ modelsConfirmed?: boolean | undefined;
204
588
  metadata?: unknown;
589
+ costMultiplier?: number | undefined;
590
+ protocolCapabilities?: {
591
+ status: "unknown" | "unsupported" | "supported";
592
+ checkedAt: string;
593
+ failureCode: string | null;
594
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
595
+ authScheme: "bearer" | "x-api-key" | null;
596
+ evidenceSource: string;
597
+ }[] | undefined;
598
+ apiKeys?: {
599
+ status: string;
600
+ createdAt: string;
601
+ updatedAt: string;
602
+ isDefault: boolean;
603
+ fingerprint: string;
604
+ masked: string;
605
+ verified: boolean;
606
+ }[] | undefined;
205
607
  }, {
206
608
  status: "active" | "disabled";
207
609
  name: string;
@@ -210,12 +612,29 @@ export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
210
612
  updatedAt: string;
211
613
  baseUrl: string;
212
614
  enterpriseId: string;
213
- apiKeys: {
615
+ modelsConfirmed?: boolean | undefined;
616
+ availableModels?: string[] | undefined;
617
+ metadata?: unknown;
618
+ apiKeyCount?: number | undefined;
619
+ verifiedActiveKeyCount?: number | undefined;
620
+ costMultiplier?: number | undefined;
621
+ protocolCapabilities?: {
622
+ status: "unknown" | "unsupported" | "supported";
623
+ checkedAt: string;
624
+ failureCode: string | null;
625
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
626
+ authScheme: "bearer" | "x-api-key" | null;
627
+ evidenceSource: string;
628
+ }[] | undefined;
629
+ apiKeys?: {
630
+ status: string;
631
+ createdAt: string;
632
+ updatedAt: string;
633
+ isDefault: boolean;
214
634
  fingerprint: string;
215
635
  masked: string;
216
- }[];
217
- apiKeyCount: number;
218
- metadata?: unknown;
636
+ verified: boolean;
637
+ }[] | undefined;
219
638
  }>, "many">;
220
639
  }, "strict", z.ZodTypeAny, {
221
640
  data: {
@@ -226,12 +645,29 @@ export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
226
645
  updatedAt: string;
227
646
  baseUrl: string;
228
647
  enterpriseId: string;
229
- apiKeys: {
230
- fingerprint: string;
231
- masked: string;
232
- }[];
648
+ availableModels: string[];
233
649
  apiKeyCount: number;
650
+ verifiedActiveKeyCount: number;
651
+ modelsConfirmed?: boolean | undefined;
234
652
  metadata?: unknown;
653
+ costMultiplier?: number | undefined;
654
+ protocolCapabilities?: {
655
+ status: "unknown" | "unsupported" | "supported";
656
+ checkedAt: string;
657
+ failureCode: string | null;
658
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
659
+ authScheme: "bearer" | "x-api-key" | null;
660
+ evidenceSource: string;
661
+ }[] | undefined;
662
+ apiKeys?: {
663
+ status: string;
664
+ createdAt: string;
665
+ updatedAt: string;
666
+ isDefault: boolean;
667
+ fingerprint: string;
668
+ masked: string;
669
+ verified: boolean;
670
+ }[] | undefined;
235
671
  }[];
236
672
  ok: true;
237
673
  }, {
@@ -243,12 +679,29 @@ export declare const GatewayConnectionViewResponseSchema: z.ZodObject<{
243
679
  updatedAt: string;
244
680
  baseUrl: string;
245
681
  enterpriseId: string;
246
- apiKeys: {
682
+ modelsConfirmed?: boolean | undefined;
683
+ availableModels?: string[] | undefined;
684
+ metadata?: unknown;
685
+ apiKeyCount?: number | undefined;
686
+ verifiedActiveKeyCount?: number | undefined;
687
+ costMultiplier?: number | undefined;
688
+ protocolCapabilities?: {
689
+ status: "unknown" | "unsupported" | "supported";
690
+ checkedAt: string;
691
+ failureCode: string | null;
692
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
693
+ authScheme: "bearer" | "x-api-key" | null;
694
+ evidenceSource: string;
695
+ }[] | undefined;
696
+ apiKeys?: {
697
+ status: string;
698
+ createdAt: string;
699
+ updatedAt: string;
700
+ isDefault: boolean;
247
701
  fingerprint: string;
248
702
  masked: string;
249
- }[];
250
- apiKeyCount: number;
251
- metadata?: unknown;
703
+ verified: boolean;
704
+ }[] | undefined;
252
705
  }[];
253
706
  ok: true;
254
707
  }>;
@@ -259,19 +712,63 @@ export declare const GatewayConnectionMutationResponseSchema: z.ZodObject<{
259
712
  enterpriseId: z.ZodString;
260
713
  name: z.ZodString;
261
714
  baseUrl: z.ZodString;
262
- apiKeyCount: z.ZodNumber;
263
- apiKeys: z.ZodArray<z.ZodObject<{
715
+ status: z.ZodEnum<["active", "disabled"]>;
716
+ metadata: z.ZodUnknown;
717
+ apiKeyCount: z.ZodDefault<z.ZodNumber>;
718
+
719
+ verifiedActiveKeyCount: z.ZodDefault<z.ZodNumber>;
720
+ costMultiplier: z.ZodOptional<z.ZodNumber>;
721
+ modelsConfirmed: z.ZodOptional<z.ZodBoolean>;
722
+ availableModels: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
723
+
724
+ protocolCapabilities: z.ZodOptional<z.ZodArray<z.ZodObject<{
725
+ protocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
726
+ status: z.ZodEnum<["supported", "unsupported", "unknown"]>;
727
+
728
+ authScheme: z.ZodNullable<z.ZodEnum<["bearer", "x-api-key"]>>;
729
+ evidenceSource: z.ZodString;
730
+ checkedAt: z.ZodString;
731
+ failureCode: z.ZodNullable<z.ZodString>;
732
+ }, "strict", z.ZodTypeAny, {
733
+ status: "unknown" | "unsupported" | "supported";
734
+ checkedAt: string;
735
+ failureCode: string | null;
736
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
737
+ authScheme: "bearer" | "x-api-key" | null;
738
+ evidenceSource: string;
739
+ }, {
740
+ status: "unknown" | "unsupported" | "supported";
741
+ checkedAt: string;
742
+ failureCode: string | null;
743
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
744
+ authScheme: "bearer" | "x-api-key" | null;
745
+ evidenceSource: string;
746
+ }>, "many">>;
747
+ apiKeys: z.ZodOptional<z.ZodArray<z.ZodObject<{
264
748
  fingerprint: z.ZodString;
265
749
  masked: z.ZodString;
750
+ status: z.ZodString;
751
+ verified: z.ZodBoolean;
752
+ isDefault: z.ZodBoolean;
753
+ createdAt: z.ZodString;
754
+ updatedAt: z.ZodString;
266
755
  }, "strict", z.ZodTypeAny, {
756
+ status: string;
757
+ createdAt: string;
758
+ updatedAt: string;
759
+ isDefault: boolean;
267
760
  fingerprint: string;
268
761
  masked: string;
762
+ verified: boolean;
269
763
  }, {
764
+ status: string;
765
+ createdAt: string;
766
+ updatedAt: string;
767
+ isDefault: boolean;
270
768
  fingerprint: string;
271
769
  masked: string;
272
- }>, "many">;
273
- status: z.ZodEnum<["active", "disabled"]>;
274
- metadata: z.ZodUnknown;
770
+ verified: boolean;
771
+ }>, "many">>;
275
772
  createdAt: z.ZodString;
276
773
  updatedAt: z.ZodString;
277
774
  }, "strict", z.ZodTypeAny, {
@@ -282,12 +779,29 @@ export declare const GatewayConnectionMutationResponseSchema: z.ZodObject<{
282
779
  updatedAt: string;
283
780
  baseUrl: string;
284
781
  enterpriseId: string;
285
- apiKeys: {
286
- fingerprint: string;
287
- masked: string;
288
- }[];
782
+ availableModels: string[];
289
783
  apiKeyCount: number;
784
+ verifiedActiveKeyCount: number;
785
+ modelsConfirmed?: boolean | undefined;
290
786
  metadata?: unknown;
787
+ costMultiplier?: number | undefined;
788
+ protocolCapabilities?: {
789
+ status: "unknown" | "unsupported" | "supported";
790
+ checkedAt: string;
791
+ failureCode: string | null;
792
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
793
+ authScheme: "bearer" | "x-api-key" | null;
794
+ evidenceSource: string;
795
+ }[] | undefined;
796
+ apiKeys?: {
797
+ status: string;
798
+ createdAt: string;
799
+ updatedAt: string;
800
+ isDefault: boolean;
801
+ fingerprint: string;
802
+ masked: string;
803
+ verified: boolean;
804
+ }[] | undefined;
291
805
  }, {
292
806
  status: "active" | "disabled";
293
807
  name: string;
@@ -296,12 +810,29 @@ export declare const GatewayConnectionMutationResponseSchema: z.ZodObject<{
296
810
  updatedAt: string;
297
811
  baseUrl: string;
298
812
  enterpriseId: string;
299
- apiKeys: {
813
+ modelsConfirmed?: boolean | undefined;
814
+ availableModels?: string[] | undefined;
815
+ metadata?: unknown;
816
+ apiKeyCount?: number | undefined;
817
+ verifiedActiveKeyCount?: number | undefined;
818
+ costMultiplier?: number | undefined;
819
+ protocolCapabilities?: {
820
+ status: "unknown" | "unsupported" | "supported";
821
+ checkedAt: string;
822
+ failureCode: string | null;
823
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
824
+ authScheme: "bearer" | "x-api-key" | null;
825
+ evidenceSource: string;
826
+ }[] | undefined;
827
+ apiKeys?: {
828
+ status: string;
829
+ createdAt: string;
830
+ updatedAt: string;
831
+ isDefault: boolean;
300
832
  fingerprint: string;
301
833
  masked: string;
302
- }[];
303
- apiKeyCount: number;
304
- metadata?: unknown;
834
+ verified: boolean;
835
+ }[] | undefined;
305
836
  }>;
306
837
  }, "strict", z.ZodTypeAny, {
307
838
  data: {
@@ -312,12 +843,29 @@ export declare const GatewayConnectionMutationResponseSchema: z.ZodObject<{
312
843
  updatedAt: string;
313
844
  baseUrl: string;
314
845
  enterpriseId: string;
315
- apiKeys: {
316
- fingerprint: string;
317
- masked: string;
318
- }[];
846
+ availableModels: string[];
319
847
  apiKeyCount: number;
848
+ verifiedActiveKeyCount: number;
849
+ modelsConfirmed?: boolean | undefined;
320
850
  metadata?: unknown;
851
+ costMultiplier?: number | undefined;
852
+ protocolCapabilities?: {
853
+ status: "unknown" | "unsupported" | "supported";
854
+ checkedAt: string;
855
+ failureCode: string | null;
856
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
857
+ authScheme: "bearer" | "x-api-key" | null;
858
+ evidenceSource: string;
859
+ }[] | undefined;
860
+ apiKeys?: {
861
+ status: string;
862
+ createdAt: string;
863
+ updatedAt: string;
864
+ isDefault: boolean;
865
+ fingerprint: string;
866
+ masked: string;
867
+ verified: boolean;
868
+ }[] | undefined;
321
869
  };
322
870
  ok: true;
323
871
  }, {
@@ -329,856 +877,825 @@ export declare const GatewayConnectionMutationResponseSchema: z.ZodObject<{
329
877
  updatedAt: string;
330
878
  baseUrl: string;
331
879
  enterpriseId: string;
332
- apiKeys: {
880
+ modelsConfirmed?: boolean | undefined;
881
+ availableModels?: string[] | undefined;
882
+ metadata?: unknown;
883
+ apiKeyCount?: number | undefined;
884
+ verifiedActiveKeyCount?: number | undefined;
885
+ costMultiplier?: number | undefined;
886
+ protocolCapabilities?: {
887
+ status: "unknown" | "unsupported" | "supported";
888
+ checkedAt: string;
889
+ failureCode: string | null;
890
+ protocol: "anthropic_messages" | "openai_responses" | "openai_chat";
891
+ authScheme: "bearer" | "x-api-key" | null;
892
+ evidenceSource: string;
893
+ }[] | undefined;
894
+ apiKeys?: {
895
+ status: string;
896
+ createdAt: string;
897
+ updatedAt: string;
898
+ isDefault: boolean;
333
899
  fingerprint: string;
334
900
  masked: string;
335
- }[];
336
- apiKeyCount: number;
337
- metadata?: unknown;
901
+ verified: boolean;
902
+ }[] | undefined;
338
903
  };
339
904
  ok: true;
340
905
  }>;
341
- export declare const GatewayCapabilityViewSchema: z.ZodObject<{
342
- connectionId: z.ZodString;
343
- connectionName: z.ZodString;
344
- agent: z.ZodEnum<["claude", "codex"]>;
345
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses"]>;
346
- models: z.ZodArray<z.ZodString, "many">;
347
- status: z.ZodEnum<["ready", "unknown", "unavailable", "unsupported"]>;
906
+
907
+ export declare const GatewayConnectionChangeUpstreamRequestSchema: z.ZodObject<{
908
+ baseUrl: z.ZodString;
909
+ apiKey: z.ZodOptional<z.ZodString>;
348
910
  }, "strict", z.ZodTypeAny, {
349
- status: "unknown" | "ready" | "unavailable" | "unsupported";
350
- agent: "codex" | "claude";
351
- connectionId: string;
352
- requestProtocol: "anthropic_messages" | "openai_responses";
353
- connectionName: string;
354
- models: string[];
911
+ baseUrl: string;
912
+ apiKey?: string | undefined;
355
913
  }, {
356
- status: "unknown" | "ready" | "unavailable" | "unsupported";
357
- agent: "codex" | "claude";
358
- connectionId: string;
359
- requestProtocol: "anthropic_messages" | "openai_responses";
360
- connectionName: string;
361
- models: string[];
914
+ baseUrl: string;
915
+ apiKey?: string | undefined;
362
916
  }>;
363
- export type GatewayCapabilityView = z.infer<typeof GatewayCapabilityViewSchema>;
364
- export declare const GatewayCapabilityViewResponseSchema: z.ZodObject<{
365
- ok: z.ZodLiteral<true>;
366
- data: z.ZodArray<z.ZodObject<{
367
- connectionId: z.ZodString;
368
- connectionName: z.ZodString;
369
- agent: z.ZodEnum<["claude", "codex"]>;
370
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses"]>;
371
- models: z.ZodArray<z.ZodString, "many">;
372
- status: z.ZodEnum<["ready", "unknown", "unavailable", "unsupported"]>;
917
+ export type GatewayConnectionChangeUpstreamRequest = z.infer<typeof GatewayConnectionChangeUpstreamRequestSchema>;
918
+
919
+ export declare const GatewayConnectionChangeUpstreamAffectedSchema: z.ZodObject<{
920
+ groupCount: z.ZodNumber;
921
+ agentCount: z.ZodNumber;
922
+ modelCount: z.ZodNumber;
923
+ }, "strict", z.ZodTypeAny, {
924
+ groupCount: number;
925
+ agentCount: number;
926
+ modelCount: number;
927
+ }, {
928
+ groupCount: number;
929
+ agentCount: number;
930
+ modelCount: number;
931
+ }>;
932
+ export type GatewayConnectionChangeUpstreamAffected = z.infer<typeof GatewayConnectionChangeUpstreamAffectedSchema>;
933
+
934
+ export declare const GatewayConnectionChangeUpstreamPreviewSchema: z.ZodObject<{
935
+ baseUrl: z.ZodString;
936
+ affected: z.ZodObject<{
937
+ groupCount: z.ZodNumber;
938
+ agentCount: z.ZodNumber;
939
+ modelCount: z.ZodNumber;
373
940
  }, "strict", z.ZodTypeAny, {
374
- status: "unknown" | "ready" | "unavailable" | "unsupported";
375
- agent: "codex" | "claude";
376
- connectionId: string;
377
- requestProtocol: "anthropic_messages" | "openai_responses";
378
- connectionName: string;
379
- models: string[];
941
+ groupCount: number;
942
+ agentCount: number;
943
+ modelCount: number;
380
944
  }, {
381
- status: "unknown" | "ready" | "unavailable" | "unsupported";
382
- agent: "codex" | "claude";
383
- connectionId: string;
384
- requestProtocol: "anthropic_messages" | "openai_responses";
945
+ groupCount: number;
946
+ agentCount: number;
947
+ modelCount: number;
948
+ }>;
949
+ }, "strict", z.ZodTypeAny, {
950
+ baseUrl: string;
951
+ affected: {
952
+ groupCount: number;
953
+ agentCount: number;
954
+ modelCount: number;
955
+ };
956
+ }, {
957
+ baseUrl: string;
958
+ affected: {
959
+ groupCount: number;
960
+ agentCount: number;
961
+ modelCount: number;
962
+ };
963
+ }>;
964
+ export type GatewayConnectionChangeUpstreamPreview = z.infer<typeof GatewayConnectionChangeUpstreamPreviewSchema>;
965
+ export declare const GatewayConnectionChangeUpstreamPreviewResponseSchema: z.ZodObject<{
966
+ ok: z.ZodLiteral<true>;
967
+ data: z.ZodObject<{
968
+ baseUrl: z.ZodString;
969
+ affected: z.ZodObject<{
970
+ groupCount: z.ZodNumber;
971
+ agentCount: z.ZodNumber;
972
+ modelCount: z.ZodNumber;
973
+ }, "strict", z.ZodTypeAny, {
974
+ groupCount: number;
975
+ agentCount: number;
976
+ modelCount: number;
977
+ }, {
978
+ groupCount: number;
979
+ agentCount: number;
980
+ modelCount: number;
981
+ }>;
982
+ }, "strict", z.ZodTypeAny, {
983
+ baseUrl: string;
984
+ affected: {
985
+ groupCount: number;
986
+ agentCount: number;
987
+ modelCount: number;
988
+ };
989
+ }, {
990
+ baseUrl: string;
991
+ affected: {
992
+ groupCount: number;
993
+ agentCount: number;
994
+ modelCount: number;
995
+ };
996
+ }>;
997
+ }, "strict", z.ZodTypeAny, {
998
+ data: {
999
+ baseUrl: string;
1000
+ affected: {
1001
+ groupCount: number;
1002
+ agentCount: number;
1003
+ modelCount: number;
1004
+ };
1005
+ };
1006
+ ok: true;
1007
+ }, {
1008
+ data: {
1009
+ baseUrl: string;
1010
+ affected: {
1011
+ groupCount: number;
1012
+ agentCount: number;
1013
+ modelCount: number;
1014
+ };
1015
+ };
1016
+ ok: true;
1017
+ }>;
1018
+ export declare const GatewayCapabilityViewSchema: z.ZodObject<{
1019
+ connectionId: z.ZodString;
1020
+ connectionName: z.ZodString;
1021
+ agent: z.ZodEnum<["claude", "codex"]>;
1022
+ requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses"]>;
1023
+ models: z.ZodArray<z.ZodString, "many">;
1024
+ status: z.ZodEnum<["ready", "unknown", "unavailable", "unsupported"]>;
1025
+ }, "strict", z.ZodTypeAny, {
1026
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
1027
+ agent: "codex" | "claude";
1028
+ models: string[];
1029
+ connectionId: string;
1030
+ connectionName: string;
1031
+ requestProtocol: "anthropic_messages" | "openai_responses";
1032
+ }, {
1033
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
1034
+ agent: "codex" | "claude";
1035
+ models: string[];
1036
+ connectionId: string;
1037
+ connectionName: string;
1038
+ requestProtocol: "anthropic_messages" | "openai_responses";
1039
+ }>;
1040
+ export type GatewayCapabilityView = z.infer<typeof GatewayCapabilityViewSchema>;
1041
+ export declare const GatewayCapabilityViewResponseSchema: z.ZodObject<{
1042
+ ok: z.ZodLiteral<true>;
1043
+ data: z.ZodArray<z.ZodObject<{
1044
+ connectionId: z.ZodString;
1045
+ connectionName: z.ZodString;
1046
+ agent: z.ZodEnum<["claude", "codex"]>;
1047
+ requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses"]>;
1048
+ models: z.ZodArray<z.ZodString, "many">;
1049
+ status: z.ZodEnum<["ready", "unknown", "unavailable", "unsupported"]>;
1050
+ }, "strict", z.ZodTypeAny, {
1051
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
1052
+ agent: "codex" | "claude";
1053
+ models: string[];
1054
+ connectionId: string;
385
1055
  connectionName: string;
1056
+ requestProtocol: "anthropic_messages" | "openai_responses";
1057
+ }, {
1058
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
1059
+ agent: "codex" | "claude";
386
1060
  models: string[];
1061
+ connectionId: string;
1062
+ connectionName: string;
1063
+ requestProtocol: "anthropic_messages" | "openai_responses";
387
1064
  }>, "many">;
388
1065
  }, "strict", z.ZodTypeAny, {
389
1066
  data: {
390
- status: "unknown" | "ready" | "unavailable" | "unsupported";
1067
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
391
1068
  agent: "codex" | "claude";
1069
+ models: string[];
392
1070
  connectionId: string;
393
- requestProtocol: "anthropic_messages" | "openai_responses";
394
1071
  connectionName: string;
395
- models: string[];
1072
+ requestProtocol: "anthropic_messages" | "openai_responses";
396
1073
  }[];
397
1074
  ok: true;
398
1075
  }, {
399
1076
  data: {
400
- status: "unknown" | "ready" | "unavailable" | "unsupported";
1077
+ status: "unknown" | "ready" | "unsupported" | "unavailable";
401
1078
  agent: "codex" | "claude";
1079
+ models: string[];
402
1080
  connectionId: string;
403
- requestProtocol: "anthropic_messages" | "openai_responses";
404
1081
  connectionName: string;
405
- models: string[];
1082
+ requestProtocol: "anthropic_messages" | "openai_responses";
406
1083
  }[];
407
1084
  ok: true;
408
1085
  }>;
409
1086
  export declare const GatewayConnectionKeyFingerprintSchema: z.ZodString;
410
- export declare const GatewayRouteCreateSchema: z.ZodDiscriminatedUnion<"agent", [z.ZodObject<{
411
- connectionId: z.ZodString;
412
- userId: z.ZodString;
413
- machineId: z.ZodString;
414
- agent: z.ZodLiteral<"claude">;
415
- model: z.ZodString;
416
- requestProtocol: z.ZodLiteral<"anthropic_messages">;
417
- upstreamProtocol: z.ZodLiteral<"anthropic_messages">;
418
- provider: z.ZodString;
419
- alias: z.ZodString;
1087
+
1088
+ export declare const MANAGED_MODEL_VENDORS: readonly ["openai", "anthropic", "deepseek", "google", "meta", "mistral", "qwen", "zhipu", "moonshot", "minimax", "other"];
1089
+ export declare const ManagedModelVendorSchema: z.ZodEnum<["openai", "anthropic", "deepseek", "google", "meta", "mistral", "qwen", "zhipu", "moonshot", "minimax", "other"]>;
1090
+ export type ManagedModelVendor = z.infer<typeof ManagedModelVendorSchema>;
1091
+ export declare const ManagedModelCurrencySchema: z.ZodString;
1092
+ export declare const ManagedModelCreateSchema: z.ZodObject<{
1093
+ modelId: z.ZodString;
1094
+ vendor: z.ZodOptional<z.ZodEnum<["openai", "anthropic", "deepseek", "google", "meta", "mistral", "qwen", "zhipu", "moonshot", "minimax", "other"]>>;
1095
+ contextWindow: z.ZodOptional<z.ZodNumber>;
1096
+ currency: z.ZodOptional<z.ZodString>;
420
1097
  }, "strict", z.ZodTypeAny, {
421
- model: string;
422
- agent: "claude";
423
- machineId: string;
424
- provider: string;
425
- connectionId: string;
426
- requestProtocol: "anthropic_messages";
427
- upstreamProtocol: "anthropic_messages";
428
- alias: string;
429
- userId: string;
1098
+ modelId: string;
1099
+ currency?: string | undefined;
1100
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1101
+ contextWindow?: number | undefined;
430
1102
  }, {
431
- model: string;
432
- agent: "claude";
433
- machineId: string;
434
- provider: string;
435
- connectionId: string;
436
- requestProtocol: "anthropic_messages";
437
- upstreamProtocol: "anthropic_messages";
438
- alias: string;
439
- userId: string;
440
- }>, z.ZodObject<{
441
- connectionId: z.ZodString;
442
- userId: z.ZodString;
443
- machineId: z.ZodString;
444
- agent: z.ZodLiteral<"codex">;
445
- model: z.ZodString;
446
- requestProtocol: z.ZodLiteral<"openai_responses">;
447
- upstreamProtocol: z.ZodLiteral<"openai_responses">;
448
- provider: z.ZodString;
449
- alias: z.ZodString;
1103
+ modelId: string;
1104
+ currency?: string | undefined;
1105
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1106
+ contextWindow?: number | undefined;
1107
+ }>;
1108
+ export declare const ManagedModelUpdateSchema: z.ZodEffects<z.ZodObject<{
1109
+ status: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
1110
+ vendor: z.ZodOptional<z.ZodEnum<["openai", "anthropic", "deepseek", "google", "meta", "mistral", "qwen", "zhipu", "moonshot", "minimax", "other"]>>;
1111
+ contextWindow: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1112
+ currency: z.ZodOptional<z.ZodString>;
450
1113
  }, "strict", z.ZodTypeAny, {
451
- model: string;
452
- agent: "codex";
453
- machineId: string;
454
- provider: string;
455
- connectionId: string;
456
- requestProtocol: "openai_responses";
457
- upstreamProtocol: "openai_responses";
458
- alias: string;
459
- userId: string;
1114
+ status?: "active" | "disabled" | undefined;
1115
+ currency?: string | undefined;
1116
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1117
+ contextWindow?: number | null | undefined;
460
1118
  }, {
461
- model: string;
462
- agent: "codex";
463
- machineId: string;
464
- provider: string;
465
- connectionId: string;
466
- requestProtocol: "openai_responses";
467
- upstreamProtocol: "openai_responses";
468
- alias: string;
469
- userId: string;
470
- }>]>;
471
- export type GatewayRouteCreate = z.infer<typeof GatewayRouteCreateSchema>;
472
- export declare const GatewayRouteUpdateSchema: z.ZodObject<{
473
- model: z.ZodOptional<z.ZodString>;
474
- provider: z.ZodOptional<z.ZodString>;
475
- status: z.ZodOptional<z.ZodEnum<["disabled", "error"]>>;
476
- }, "strict", z.ZodTypeAny, {
477
- status?: "error" | "disabled" | undefined;
478
- model?: string | undefined;
479
- provider?: string | undefined;
1119
+ status?: "active" | "disabled" | undefined;
1120
+ currency?: string | undefined;
1121
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1122
+ contextWindow?: number | null | undefined;
1123
+ }>, {
1124
+ status?: "active" | "disabled" | undefined;
1125
+ currency?: string | undefined;
1126
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1127
+ contextWindow?: number | null | undefined;
480
1128
  }, {
481
- status?: "error" | "disabled" | undefined;
482
- model?: string | undefined;
483
- provider?: string | undefined;
1129
+ status?: "active" | "disabled" | undefined;
1130
+ currency?: string | undefined;
1131
+ vendor?: "meta" | "openai" | "anthropic" | "deepseek" | "google" | "mistral" | "qwen" | "zhipu" | "moonshot" | "minimax" | "other" | undefined;
1132
+ contextWindow?: number | null | undefined;
484
1133
  }>;
485
- export type GatewayRouteUpdate = z.infer<typeof GatewayRouteUpdateSchema>;
486
- export declare const GatewayRouteViewSchema: z.ZodObject<{
1134
+ export declare const ManagedModelViewSchema: z.ZodObject<{
487
1135
  id: z.ZodString;
488
- enterpriseId: z.ZodString;
489
- alias: z.ZodString;
490
- agent: z.ZodEnum<["claude", "codex", "opencode"]>;
491
- provider: z.ZodString;
492
- model: z.ZodString;
493
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
494
- upstreamProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
495
- status: z.ZodEnum<["draft", "validating", "active", "disabled", "error"]>;
496
- connection: z.ZodOptional<z.ZodObject<{
1136
+ modelId: z.ZodString;
1137
+ status: z.ZodEnum<["active", "disabled"]>;
1138
+ vendor: z.ZodString;
1139
+ contextWindow: z.ZodNullable<z.ZodNumber>;
1140
+ currency: z.ZodString;
1141
+ discoveredConnectionIds: z.ZodArray<z.ZodString, "many">;
1142
+ createdAt: z.ZodString;
1143
+ updatedAt: z.ZodString;
1144
+ }, "strict", z.ZodTypeAny, {
1145
+ status: "active" | "disabled";
1146
+ id: string;
1147
+ createdAt: string;
1148
+ updatedAt: string;
1149
+ modelId: string;
1150
+ currency: string;
1151
+ vendor: string;
1152
+ contextWindow: number | null;
1153
+ discoveredConnectionIds: string[];
1154
+ }, {
1155
+ status: "active" | "disabled";
1156
+ id: string;
1157
+ createdAt: string;
1158
+ updatedAt: string;
1159
+ modelId: string;
1160
+ currency: string;
1161
+ vendor: string;
1162
+ contextWindow: number | null;
1163
+ discoveredConnectionIds: string[];
1164
+ }>;
1165
+ export declare const ManagedModelListResponseSchema: z.ZodObject<{
1166
+ ok: z.ZodLiteral<true>;
1167
+ data: z.ZodArray<z.ZodObject<{
497
1168
  id: z.ZodString;
498
- name: z.ZodString;
1169
+ modelId: z.ZodString;
499
1170
  status: z.ZodEnum<["active", "disabled"]>;
1171
+ vendor: z.ZodString;
1172
+ contextWindow: z.ZodNullable<z.ZodNumber>;
1173
+ currency: z.ZodString;
1174
+ discoveredConnectionIds: z.ZodArray<z.ZodString, "many">;
1175
+ createdAt: z.ZodString;
1176
+ updatedAt: z.ZodString;
500
1177
  }, "strict", z.ZodTypeAny, {
501
1178
  status: "active" | "disabled";
502
- name: string;
503
1179
  id: string;
1180
+ createdAt: string;
1181
+ updatedAt: string;
1182
+ modelId: string;
1183
+ currency: string;
1184
+ vendor: string;
1185
+ contextWindow: number | null;
1186
+ discoveredConnectionIds: string[];
504
1187
  }, {
505
1188
  status: "active" | "disabled";
506
- name: string;
507
1189
  id: string;
508
- }>>;
509
- } & {
510
- connectionId: z.ZodString;
511
- lastValidationAt: z.ZodNullable<z.ZodString>;
512
- lastErrorCode: z.ZodNullable<z.ZodString>;
513
- runtimeBinding: z.ZodNullable<z.ZodObject<{
1190
+ createdAt: string;
1191
+ updatedAt: string;
1192
+ modelId: string;
1193
+ currency: string;
1194
+ vendor: string;
1195
+ contextWindow: number | null;
1196
+ discoveredConnectionIds: string[];
1197
+ }>, "many">;
1198
+ }, "strict", z.ZodTypeAny, {
1199
+ data: {
1200
+ status: "active" | "disabled";
1201
+ id: string;
1202
+ createdAt: string;
1203
+ updatedAt: string;
1204
+ modelId: string;
1205
+ currency: string;
1206
+ vendor: string;
1207
+ contextWindow: number | null;
1208
+ discoveredConnectionIds: string[];
1209
+ }[];
1210
+ ok: true;
1211
+ }, {
1212
+ data: {
1213
+ status: "active" | "disabled";
1214
+ id: string;
1215
+ createdAt: string;
1216
+ updatedAt: string;
1217
+ modelId: string;
1218
+ currency: string;
1219
+ vendor: string;
1220
+ contextWindow: number | null;
1221
+ discoveredConnectionIds: string[];
1222
+ }[];
1223
+ ok: true;
1224
+ }>;
1225
+ export declare const ManagedModelResponseSchema: z.ZodObject<{
1226
+ ok: z.ZodLiteral<true>;
1227
+ data: z.ZodObject<{
514
1228
  id: z.ZodString;
515
- status: z.ZodEnum<["active", "expired", "revoked"]>;
516
- expiresAt: z.ZodNullable<z.ZodString>;
1229
+ modelId: z.ZodString;
1230
+ status: z.ZodEnum<["active", "disabled"]>;
1231
+ vendor: z.ZodString;
1232
+ contextWindow: z.ZodNullable<z.ZodNumber>;
1233
+ currency: z.ZodString;
1234
+ discoveredConnectionIds: z.ZodArray<z.ZodString, "many">;
1235
+ createdAt: z.ZodString;
1236
+ updatedAt: z.ZodString;
517
1237
  }, "strict", z.ZodTypeAny, {
518
- status: "active" | "revoked" | "expired";
1238
+ status: "active" | "disabled";
519
1239
  id: string;
520
- expiresAt: string | null;
1240
+ createdAt: string;
1241
+ updatedAt: string;
1242
+ modelId: string;
1243
+ currency: string;
1244
+ vendor: string;
1245
+ contextWindow: number | null;
1246
+ discoveredConnectionIds: string[];
521
1247
  }, {
522
- status: "active" | "revoked" | "expired";
1248
+ status: "active" | "disabled";
523
1249
  id: string;
524
- expiresAt: string | null;
525
- }>>;
1250
+ createdAt: string;
1251
+ updatedAt: string;
1252
+ modelId: string;
1253
+ currency: string;
1254
+ vendor: string;
1255
+ contextWindow: number | null;
1256
+ discoveredConnectionIds: string[];
1257
+ }>;
526
1258
  }, "strict", z.ZodTypeAny, {
527
- status: "error" | "active" | "disabled" | "draft" | "validating";
528
- model: string;
529
- agent: "codex" | "claude" | "opencode";
530
- id: string;
531
- provider: string;
532
- connectionId: string;
533
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
534
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
535
- lastErrorCode: string | null;
536
- alias: string;
537
- enterpriseId: string;
538
- lastValidationAt: string | null;
539
- runtimeBinding: {
540
- status: "active" | "revoked" | "expired";
541
- id: string;
542
- expiresAt: string | null;
543
- } | null;
544
- connection?: {
1259
+ data: {
545
1260
  status: "active" | "disabled";
546
- name: string;
547
1261
  id: string;
548
- } | undefined;
1262
+ createdAt: string;
1263
+ updatedAt: string;
1264
+ modelId: string;
1265
+ currency: string;
1266
+ vendor: string;
1267
+ contextWindow: number | null;
1268
+ discoveredConnectionIds: string[];
1269
+ };
1270
+ ok: true;
549
1271
  }, {
550
- status: "error" | "active" | "disabled" | "draft" | "validating";
551
- model: string;
552
- agent: "codex" | "claude" | "opencode";
553
- id: string;
554
- provider: string;
555
- connectionId: string;
556
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
557
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
558
- lastErrorCode: string | null;
559
- alias: string;
560
- enterpriseId: string;
561
- lastValidationAt: string | null;
562
- runtimeBinding: {
563
- status: "active" | "revoked" | "expired";
564
- id: string;
565
- expiresAt: string | null;
566
- } | null;
567
- connection?: {
1272
+ data: {
568
1273
  status: "active" | "disabled";
569
- name: string;
570
1274
  id: string;
571
- } | undefined;
1275
+ createdAt: string;
1276
+ updatedAt: string;
1277
+ modelId: string;
1278
+ currency: string;
1279
+ vendor: string;
1280
+ contextWindow: number | null;
1281
+ discoveredConnectionIds: string[];
1282
+ };
1283
+ ok: true;
1284
+ }>;
1285
+ export declare const ManagedModelPriceInputSchema: z.ZodEffects<z.ZodObject<{
1286
+ scope: z.ZodEnum<["default", "connection_override"]>;
1287
+ connectionId: z.ZodOptional<z.ZodString>;
1288
+ currency: z.ZodString;
1289
+ inputMicrosPerMillion: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1290
+ outputMicrosPerMillion: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1291
+ cacheReadMicrosPerMillion: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1292
+ cacheWriteMicrosPerMillion: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1293
+ effectiveFrom: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1294
+ effectiveUntil: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1295
+ status: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
1296
+ }, "strict", z.ZodTypeAny, {
1297
+ currency: string;
1298
+ scope: "default" | "connection_override";
1299
+ status?: "active" | "disabled" | undefined;
1300
+ connectionId?: string | undefined;
1301
+ inputMicrosPerMillion?: string | null | undefined;
1302
+ outputMicrosPerMillion?: string | null | undefined;
1303
+ cacheReadMicrosPerMillion?: string | null | undefined;
1304
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1305
+ effectiveFrom?: string | null | undefined;
1306
+ effectiveUntil?: string | null | undefined;
1307
+ }, {
1308
+ currency: string;
1309
+ scope: "default" | "connection_override";
1310
+ status?: "active" | "disabled" | undefined;
1311
+ connectionId?: string | undefined;
1312
+ inputMicrosPerMillion?: string | null | undefined;
1313
+ outputMicrosPerMillion?: string | null | undefined;
1314
+ cacheReadMicrosPerMillion?: string | null | undefined;
1315
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1316
+ effectiveFrom?: string | null | undefined;
1317
+ effectiveUntil?: string | null | undefined;
1318
+ }>, {
1319
+ currency: string;
1320
+ scope: "default" | "connection_override";
1321
+ status?: "active" | "disabled" | undefined;
1322
+ connectionId?: string | undefined;
1323
+ inputMicrosPerMillion?: string | null | undefined;
1324
+ outputMicrosPerMillion?: string | null | undefined;
1325
+ cacheReadMicrosPerMillion?: string | null | undefined;
1326
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1327
+ effectiveFrom?: string | null | undefined;
1328
+ effectiveUntil?: string | null | undefined;
1329
+ }, {
1330
+ currency: string;
1331
+ scope: "default" | "connection_override";
1332
+ status?: "active" | "disabled" | undefined;
1333
+ connectionId?: string | undefined;
1334
+ inputMicrosPerMillion?: string | null | undefined;
1335
+ outputMicrosPerMillion?: string | null | undefined;
1336
+ cacheReadMicrosPerMillion?: string | null | undefined;
1337
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1338
+ effectiveFrom?: string | null | undefined;
1339
+ effectiveUntil?: string | null | undefined;
572
1340
  }>;
573
- export type GatewayRouteView = z.infer<typeof GatewayRouteViewSchema>;
574
- export declare const GatewayRouteViewResponseSchema: z.ZodObject<{
1341
+ export declare const ManagedModelPriceUpdateSchema: z.ZodObject<{
1342
+ scope: z.ZodOptional<z.ZodEnum<["default", "connection_override"]>>;
1343
+ connectionId: z.ZodOptional<z.ZodOptional<z.ZodString>>;
1344
+ currency: z.ZodOptional<z.ZodString>;
1345
+ inputMicrosPerMillion: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1346
+ outputMicrosPerMillion: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1347
+ cacheReadMicrosPerMillion: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1348
+ cacheWriteMicrosPerMillion: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1349
+ effectiveFrom: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1350
+ effectiveUntil: z.ZodOptional<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
1351
+ status: z.ZodOptional<z.ZodOptional<z.ZodEnum<["active", "disabled"]>>>;
1352
+ }, "strict", z.ZodTypeAny, {
1353
+ status?: "active" | "disabled" | undefined;
1354
+ currency?: string | undefined;
1355
+ connectionId?: string | undefined;
1356
+ scope?: "default" | "connection_override" | undefined;
1357
+ inputMicrosPerMillion?: string | null | undefined;
1358
+ outputMicrosPerMillion?: string | null | undefined;
1359
+ cacheReadMicrosPerMillion?: string | null | undefined;
1360
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1361
+ effectiveFrom?: string | null | undefined;
1362
+ effectiveUntil?: string | null | undefined;
1363
+ }, {
1364
+ status?: "active" | "disabled" | undefined;
1365
+ currency?: string | undefined;
1366
+ connectionId?: string | undefined;
1367
+ scope?: "default" | "connection_override" | undefined;
1368
+ inputMicrosPerMillion?: string | null | undefined;
1369
+ outputMicrosPerMillion?: string | null | undefined;
1370
+ cacheReadMicrosPerMillion?: string | null | undefined;
1371
+ cacheWriteMicrosPerMillion?: string | null | undefined;
1372
+ effectiveFrom?: string | null | undefined;
1373
+ effectiveUntil?: string | null | undefined;
1374
+ }>;
1375
+ export declare const ManagedModelPriceViewSchema: z.ZodObject<{
1376
+ scope: z.ZodEnum<["default", "connection_override"]>;
1377
+ currency: z.ZodString;
1378
+ effectiveFrom: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1379
+ effectiveUntil: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1380
+ } & {
1381
+ id: z.ZodString;
1382
+ managedModelId: z.ZodString;
1383
+ connectionId: z.ZodNullable<z.ZodString>;
1384
+ inputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1385
+ outputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1386
+ cacheReadMicrosPerMillion: z.ZodNullable<z.ZodString>;
1387
+ cacheWriteMicrosPerMillion: z.ZodNullable<z.ZodString>;
1388
+ status: z.ZodEnum<["active", "disabled"]>;
1389
+ createdAt: z.ZodString;
1390
+ updatedAt: z.ZodString;
1391
+ }, "strict", z.ZodTypeAny, {
1392
+ status: "active" | "disabled";
1393
+ id: string;
1394
+ createdAt: string;
1395
+ updatedAt: string;
1396
+ currency: string;
1397
+ connectionId: string | null;
1398
+ scope: "default" | "connection_override";
1399
+ inputMicrosPerMillion: string | null;
1400
+ outputMicrosPerMillion: string | null;
1401
+ cacheReadMicrosPerMillion: string | null;
1402
+ cacheWriteMicrosPerMillion: string | null;
1403
+ managedModelId: string;
1404
+ effectiveFrom?: string | null | undefined;
1405
+ effectiveUntil?: string | null | undefined;
1406
+ }, {
1407
+ status: "active" | "disabled";
1408
+ id: string;
1409
+ createdAt: string;
1410
+ updatedAt: string;
1411
+ currency: string;
1412
+ connectionId: string | null;
1413
+ scope: "default" | "connection_override";
1414
+ inputMicrosPerMillion: string | null;
1415
+ outputMicrosPerMillion: string | null;
1416
+ cacheReadMicrosPerMillion: string | null;
1417
+ cacheWriteMicrosPerMillion: string | null;
1418
+ managedModelId: string;
1419
+ effectiveFrom?: string | null | undefined;
1420
+ effectiveUntil?: string | null | undefined;
1421
+ }>;
1422
+ export declare const ManagedModelPriceListResponseSchema: z.ZodObject<{
575
1423
  ok: z.ZodLiteral<true>;
576
1424
  data: z.ZodArray<z.ZodObject<{
577
- id: z.ZodString;
578
- enterpriseId: z.ZodString;
579
- alias: z.ZodString;
580
- agent: z.ZodEnum<["claude", "codex", "opencode"]>;
581
- provider: z.ZodString;
582
- model: z.ZodString;
583
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
584
- upstreamProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
585
- status: z.ZodEnum<["draft", "validating", "active", "disabled", "error"]>;
586
- connection: z.ZodOptional<z.ZodObject<{
587
- id: z.ZodString;
588
- name: z.ZodString;
589
- status: z.ZodEnum<["active", "disabled"]>;
590
- }, "strict", z.ZodTypeAny, {
591
- status: "active" | "disabled";
592
- name: string;
593
- id: string;
594
- }, {
595
- status: "active" | "disabled";
596
- name: string;
597
- id: string;
598
- }>>;
1425
+ scope: z.ZodEnum<["default", "connection_override"]>;
1426
+ currency: z.ZodString;
1427
+ effectiveFrom: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1428
+ effectiveUntil: z.ZodOptional<z.ZodNullable<z.ZodString>>;
599
1429
  } & {
600
- connectionId: z.ZodString;
601
- lastValidationAt: z.ZodNullable<z.ZodString>;
602
- lastErrorCode: z.ZodNullable<z.ZodString>;
603
- runtimeBinding: z.ZodNullable<z.ZodObject<{
604
- id: z.ZodString;
605
- status: z.ZodEnum<["active", "expired", "revoked"]>;
606
- expiresAt: z.ZodNullable<z.ZodString>;
607
- }, "strict", z.ZodTypeAny, {
608
- status: "active" | "revoked" | "expired";
609
- id: string;
610
- expiresAt: string | null;
611
- }, {
612
- status: "active" | "revoked" | "expired";
613
- id: string;
614
- expiresAt: string | null;
615
- }>>;
1430
+ id: z.ZodString;
1431
+ managedModelId: z.ZodString;
1432
+ connectionId: z.ZodNullable<z.ZodString>;
1433
+ inputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1434
+ outputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1435
+ cacheReadMicrosPerMillion: z.ZodNullable<z.ZodString>;
1436
+ cacheWriteMicrosPerMillion: z.ZodNullable<z.ZodString>;
1437
+ status: z.ZodEnum<["active", "disabled"]>;
1438
+ createdAt: z.ZodString;
1439
+ updatedAt: z.ZodString;
616
1440
  }, "strict", z.ZodTypeAny, {
617
- status: "error" | "active" | "disabled" | "draft" | "validating";
618
- model: string;
619
- agent: "codex" | "claude" | "opencode";
1441
+ status: "active" | "disabled";
620
1442
  id: string;
621
- provider: string;
622
- connectionId: string;
623
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
624
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
625
- lastErrorCode: string | null;
626
- alias: string;
627
- enterpriseId: string;
628
- lastValidationAt: string | null;
629
- runtimeBinding: {
630
- status: "active" | "revoked" | "expired";
631
- id: string;
632
- expiresAt: string | null;
633
- } | null;
634
- connection?: {
635
- status: "active" | "disabled";
636
- name: string;
637
- id: string;
638
- } | undefined;
1443
+ createdAt: string;
1444
+ updatedAt: string;
1445
+ currency: string;
1446
+ connectionId: string | null;
1447
+ scope: "default" | "connection_override";
1448
+ inputMicrosPerMillion: string | null;
1449
+ outputMicrosPerMillion: string | null;
1450
+ cacheReadMicrosPerMillion: string | null;
1451
+ cacheWriteMicrosPerMillion: string | null;
1452
+ managedModelId: string;
1453
+ effectiveFrom?: string | null | undefined;
1454
+ effectiveUntil?: string | null | undefined;
639
1455
  }, {
640
- status: "error" | "active" | "disabled" | "draft" | "validating";
641
- model: string;
642
- agent: "codex" | "claude" | "opencode";
1456
+ status: "active" | "disabled";
643
1457
  id: string;
644
- provider: string;
645
- connectionId: string;
646
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
647
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
648
- lastErrorCode: string | null;
649
- alias: string;
650
- enterpriseId: string;
651
- lastValidationAt: string | null;
652
- runtimeBinding: {
653
- status: "active" | "revoked" | "expired";
654
- id: string;
655
- expiresAt: string | null;
656
- } | null;
657
- connection?: {
658
- status: "active" | "disabled";
659
- name: string;
660
- id: string;
661
- } | undefined;
1458
+ createdAt: string;
1459
+ updatedAt: string;
1460
+ currency: string;
1461
+ connectionId: string | null;
1462
+ scope: "default" | "connection_override";
1463
+ inputMicrosPerMillion: string | null;
1464
+ outputMicrosPerMillion: string | null;
1465
+ cacheReadMicrosPerMillion: string | null;
1466
+ cacheWriteMicrosPerMillion: string | null;
1467
+ managedModelId: string;
1468
+ effectiveFrom?: string | null | undefined;
1469
+ effectiveUntil?: string | null | undefined;
662
1470
  }>, "many">;
663
1471
  }, "strict", z.ZodTypeAny, {
664
1472
  data: {
665
- status: "error" | "active" | "disabled" | "draft" | "validating";
666
- model: string;
667
- agent: "codex" | "claude" | "opencode";
1473
+ status: "active" | "disabled";
668
1474
  id: string;
669
- provider: string;
670
- connectionId: string;
671
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
672
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
673
- lastErrorCode: string | null;
674
- alias: string;
675
- enterpriseId: string;
676
- lastValidationAt: string | null;
677
- runtimeBinding: {
678
- status: "active" | "revoked" | "expired";
679
- id: string;
680
- expiresAt: string | null;
681
- } | null;
682
- connection?: {
683
- status: "active" | "disabled";
684
- name: string;
685
- id: string;
686
- } | undefined;
1475
+ createdAt: string;
1476
+ updatedAt: string;
1477
+ currency: string;
1478
+ connectionId: string | null;
1479
+ scope: "default" | "connection_override";
1480
+ inputMicrosPerMillion: string | null;
1481
+ outputMicrosPerMillion: string | null;
1482
+ cacheReadMicrosPerMillion: string | null;
1483
+ cacheWriteMicrosPerMillion: string | null;
1484
+ managedModelId: string;
1485
+ effectiveFrom?: string | null | undefined;
1486
+ effectiveUntil?: string | null | undefined;
687
1487
  }[];
688
1488
  ok: true;
689
1489
  }, {
690
1490
  data: {
691
- status: "error" | "active" | "disabled" | "draft" | "validating";
692
- model: string;
693
- agent: "codex" | "claude" | "opencode";
1491
+ status: "active" | "disabled";
694
1492
  id: string;
695
- provider: string;
696
- connectionId: string;
697
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
698
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
699
- lastErrorCode: string | null;
700
- alias: string;
701
- enterpriseId: string;
702
- lastValidationAt: string | null;
703
- runtimeBinding: {
704
- status: "active" | "revoked" | "expired";
705
- id: string;
706
- expiresAt: string | null;
707
- } | null;
708
- connection?: {
709
- status: "active" | "disabled";
710
- name: string;
711
- id: string;
712
- } | undefined;
1493
+ createdAt: string;
1494
+ updatedAt: string;
1495
+ currency: string;
1496
+ connectionId: string | null;
1497
+ scope: "default" | "connection_override";
1498
+ inputMicrosPerMillion: string | null;
1499
+ outputMicrosPerMillion: string | null;
1500
+ cacheReadMicrosPerMillion: string | null;
1501
+ cacheWriteMicrosPerMillion: string | null;
1502
+ managedModelId: string;
1503
+ effectiveFrom?: string | null | undefined;
1504
+ effectiveUntil?: string | null | undefined;
713
1505
  }[];
714
1506
  ok: true;
715
1507
  }>;
716
- export declare const GatewayRouteMutationResponseSchema: z.ZodObject<{
1508
+ export declare const ManagedModelPriceResponseSchema: z.ZodObject<{
717
1509
  ok: z.ZodLiteral<true>;
718
1510
  data: z.ZodObject<{
719
- route: z.ZodObject<{
720
- id: z.ZodString;
721
- enterpriseId: z.ZodString;
722
- alias: z.ZodString;
723
- agent: z.ZodEnum<["claude", "codex", "opencode"]>;
724
- provider: z.ZodString;
725
- model: z.ZodString;
726
- requestProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
727
- upstreamProtocol: z.ZodEnum<["anthropic_messages", "openai_responses", "openai_chat"]>;
728
- status: z.ZodEnum<["draft", "validating", "active", "disabled", "error"]>;
729
- connection: z.ZodOptional<z.ZodObject<{
730
- id: z.ZodString;
731
- name: z.ZodString;
732
- status: z.ZodEnum<["active", "disabled"]>;
733
- }, "strict", z.ZodTypeAny, {
734
- status: "active" | "disabled";
735
- name: string;
736
- id: string;
737
- }, {
738
- status: "active" | "disabled";
739
- name: string;
740
- id: string;
741
- }>>;
742
- } & {
743
- connectionId: z.ZodString;
744
- lastValidationAt: z.ZodNullable<z.ZodString>;
745
- lastErrorCode: z.ZodNullable<z.ZodString>;
746
- runtimeBinding: z.ZodNullable<z.ZodObject<{
747
- id: z.ZodString;
748
- status: z.ZodEnum<["active", "expired", "revoked"]>;
749
- expiresAt: z.ZodNullable<z.ZodString>;
750
- }, "strict", z.ZodTypeAny, {
751
- status: "active" | "revoked" | "expired";
752
- id: string;
753
- expiresAt: string | null;
754
- }, {
755
- status: "active" | "revoked" | "expired";
756
- id: string;
757
- expiresAt: string | null;
758
- }>>;
759
- }, "strict", z.ZodTypeAny, {
760
- status: "error" | "active" | "disabled" | "draft" | "validating";
761
- model: string;
762
- agent: "codex" | "claude" | "opencode";
763
- id: string;
764
- provider: string;
765
- connectionId: string;
766
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
767
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
768
- lastErrorCode: string | null;
769
- alias: string;
770
- enterpriseId: string;
771
- lastValidationAt: string | null;
772
- runtimeBinding: {
773
- status: "active" | "revoked" | "expired";
774
- id: string;
775
- expiresAt: string | null;
776
- } | null;
777
- connection?: {
778
- status: "active" | "disabled";
779
- name: string;
780
- id: string;
781
- } | undefined;
782
- }, {
783
- status: "error" | "active" | "disabled" | "draft" | "validating";
784
- model: string;
785
- agent: "codex" | "claude" | "opencode";
786
- id: string;
787
- provider: string;
788
- connectionId: string;
789
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
790
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
791
- lastErrorCode: string | null;
792
- alias: string;
793
- enterpriseId: string;
794
- lastValidationAt: string | null;
795
- runtimeBinding: {
796
- status: "active" | "revoked" | "expired";
797
- id: string;
798
- expiresAt: string | null;
799
- } | null;
800
- connection?: {
801
- status: "active" | "disabled";
802
- name: string;
803
- id: string;
804
- } | undefined;
805
- }>;
1511
+ scope: z.ZodEnum<["default", "connection_override"]>;
1512
+ currency: z.ZodString;
1513
+ effectiveFrom: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1514
+ effectiveUntil: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1515
+ } & {
1516
+ id: z.ZodString;
1517
+ managedModelId: z.ZodString;
1518
+ connectionId: z.ZodNullable<z.ZodString>;
1519
+ inputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1520
+ outputMicrosPerMillion: z.ZodNullable<z.ZodString>;
1521
+ cacheReadMicrosPerMillion: z.ZodNullable<z.ZodString>;
1522
+ cacheWriteMicrosPerMillion: z.ZodNullable<z.ZodString>;
1523
+ status: z.ZodEnum<["active", "disabled"]>;
1524
+ createdAt: z.ZodString;
1525
+ updatedAt: z.ZodString;
806
1526
  }, "strict", z.ZodTypeAny, {
807
- route: {
808
- status: "error" | "active" | "disabled" | "draft" | "validating";
809
- model: string;
810
- agent: "codex" | "claude" | "opencode";
811
- id: string;
812
- provider: string;
813
- connectionId: string;
814
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
815
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
816
- lastErrorCode: string | null;
817
- alias: string;
818
- enterpriseId: string;
819
- lastValidationAt: string | null;
820
- runtimeBinding: {
821
- status: "active" | "revoked" | "expired";
822
- id: string;
823
- expiresAt: string | null;
824
- } | null;
825
- connection?: {
826
- status: "active" | "disabled";
827
- name: string;
828
- id: string;
829
- } | undefined;
830
- };
1527
+ status: "active" | "disabled";
1528
+ id: string;
1529
+ createdAt: string;
1530
+ updatedAt: string;
1531
+ currency: string;
1532
+ connectionId: string | null;
1533
+ scope: "default" | "connection_override";
1534
+ inputMicrosPerMillion: string | null;
1535
+ outputMicrosPerMillion: string | null;
1536
+ cacheReadMicrosPerMillion: string | null;
1537
+ cacheWriteMicrosPerMillion: string | null;
1538
+ managedModelId: string;
1539
+ effectiveFrom?: string | null | undefined;
1540
+ effectiveUntil?: string | null | undefined;
831
1541
  }, {
832
- route: {
833
- status: "error" | "active" | "disabled" | "draft" | "validating";
834
- model: string;
835
- agent: "codex" | "claude" | "opencode";
836
- id: string;
837
- provider: string;
838
- connectionId: string;
839
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
840
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
841
- lastErrorCode: string | null;
842
- alias: string;
843
- enterpriseId: string;
844
- lastValidationAt: string | null;
845
- runtimeBinding: {
846
- status: "active" | "revoked" | "expired";
847
- id: string;
848
- expiresAt: string | null;
849
- } | null;
850
- connection?: {
851
- status: "active" | "disabled";
852
- name: string;
853
- id: string;
854
- } | undefined;
855
- };
1542
+ status: "active" | "disabled";
1543
+ id: string;
1544
+ createdAt: string;
1545
+ updatedAt: string;
1546
+ currency: string;
1547
+ connectionId: string | null;
1548
+ scope: "default" | "connection_override";
1549
+ inputMicrosPerMillion: string | null;
1550
+ outputMicrosPerMillion: string | null;
1551
+ cacheReadMicrosPerMillion: string | null;
1552
+ cacheWriteMicrosPerMillion: string | null;
1553
+ managedModelId: string;
1554
+ effectiveFrom?: string | null | undefined;
1555
+ effectiveUntil?: string | null | undefined;
856
1556
  }>;
857
1557
  }, "strict", z.ZodTypeAny, {
858
1558
  data: {
859
- route: {
860
- status: "error" | "active" | "disabled" | "draft" | "validating";
861
- model: string;
862
- agent: "codex" | "claude" | "opencode";
863
- id: string;
864
- provider: string;
865
- connectionId: string;
866
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
867
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
868
- lastErrorCode: string | null;
869
- alias: string;
870
- enterpriseId: string;
871
- lastValidationAt: string | null;
872
- runtimeBinding: {
873
- status: "active" | "revoked" | "expired";
874
- id: string;
875
- expiresAt: string | null;
876
- } | null;
877
- connection?: {
878
- status: "active" | "disabled";
879
- name: string;
880
- id: string;
881
- } | undefined;
882
- };
1559
+ status: "active" | "disabled";
1560
+ id: string;
1561
+ createdAt: string;
1562
+ updatedAt: string;
1563
+ currency: string;
1564
+ connectionId: string | null;
1565
+ scope: "default" | "connection_override";
1566
+ inputMicrosPerMillion: string | null;
1567
+ outputMicrosPerMillion: string | null;
1568
+ cacheReadMicrosPerMillion: string | null;
1569
+ cacheWriteMicrosPerMillion: string | null;
1570
+ managedModelId: string;
1571
+ effectiveFrom?: string | null | undefined;
1572
+ effectiveUntil?: string | null | undefined;
883
1573
  };
884
1574
  ok: true;
885
1575
  }, {
886
1576
  data: {
887
- route: {
888
- status: "error" | "active" | "disabled" | "draft" | "validating";
889
- model: string;
890
- agent: "codex" | "claude" | "opencode";
891
- id: string;
892
- provider: string;
893
- connectionId: string;
894
- requestProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
895
- upstreamProtocol: "anthropic_messages" | "openai_responses" | "openai_chat";
896
- lastErrorCode: string | null;
897
- alias: string;
898
- enterpriseId: string;
899
- lastValidationAt: string | null;
900
- runtimeBinding: {
901
- status: "active" | "revoked" | "expired";
902
- id: string;
903
- expiresAt: string | null;
904
- } | null;
905
- connection?: {
906
- status: "active" | "disabled";
907
- name: string;
908
- id: string;
909
- } | undefined;
910
- };
1577
+ status: "active" | "disabled";
1578
+ id: string;
1579
+ createdAt: string;
1580
+ updatedAt: string;
1581
+ currency: string;
1582
+ connectionId: string | null;
1583
+ scope: "default" | "connection_override";
1584
+ inputMicrosPerMillion: string | null;
1585
+ outputMicrosPerMillion: string | null;
1586
+ cacheReadMicrosPerMillion: string | null;
1587
+ cacheWriteMicrosPerMillion: string | null;
1588
+ managedModelId: string;
1589
+ effectiveFrom?: string | null | undefined;
1590
+ effectiveUntil?: string | null | undefined;
911
1591
  };
912
1592
  ok: true;
913
1593
  }>;
914
- export declare const EnterpriseNativeModelCatalogEntrySchema: z.ZodObject<{
915
- model: z.ZodString;
916
- provider: z.ZodString;
917
- mode: z.ZodString;
918
- inputCostPerToken: z.ZodNullable<z.ZodNumber>;
919
- outputCostPerToken: z.ZodNullable<z.ZodNumber>;
920
- maxInputTokens: z.ZodNullable<z.ZodNumber>;
921
- maxOutputTokens: z.ZodNullable<z.ZodNumber>;
922
- source: z.ZodEnum<["github", "custom"]>;
1594
+ export type ManagedModelView = z.infer<typeof ManagedModelViewSchema>;
1595
+ export type ManagedModelPriceView = z.infer<typeof ManagedModelPriceViewSchema>;
1596
+
1597
+ export declare const GatewayLogicalConnectionKeyCreateSchema: z.ZodObject<{
1598
+ apiKey: z.ZodString;
923
1599
  }, "strict", z.ZodTypeAny, {
924
- model: string;
925
- mode: string;
926
- source: "custom" | "github";
927
- provider: string;
928
- inputCostPerToken: number | null;
929
- outputCostPerToken: number | null;
930
- maxInputTokens: number | null;
931
- maxOutputTokens: number | null;
1600
+ apiKey: string;
932
1601
  }, {
933
- model: string;
934
- mode: string;
935
- source: "custom" | "github";
936
- provider: string;
937
- inputCostPerToken: number | null;
938
- outputCostPerToken: number | null;
939
- maxInputTokens: number | null;
940
- maxOutputTokens: number | null;
1602
+ apiKey: string;
941
1603
  }>;
942
- export type EnterpriseNativeModelCatalogEntry = z.infer<typeof EnterpriseNativeModelCatalogEntrySchema>;
943
- export declare const EnterpriseNativeModelCatalogResponseSchema: z.ZodObject<{
944
- ok: z.ZodLiteral<true>;
945
- data: z.ZodArray<z.ZodObject<{
946
- model: z.ZodString;
947
- provider: z.ZodString;
948
- mode: z.ZodString;
949
- inputCostPerToken: z.ZodNullable<z.ZodNumber>;
950
- outputCostPerToken: z.ZodNullable<z.ZodNumber>;
951
- maxInputTokens: z.ZodNullable<z.ZodNumber>;
952
- maxOutputTokens: z.ZodNullable<z.ZodNumber>;
953
- source: z.ZodEnum<["github", "custom"]>;
954
- }, "strict", z.ZodTypeAny, {
955
- model: string;
956
- mode: string;
957
- source: "custom" | "github";
958
- provider: string;
959
- inputCostPerToken: number | null;
960
- outputCostPerToken: number | null;
961
- maxInputTokens: number | null;
962
- maxOutputTokens: number | null;
963
- }, {
964
- model: string;
965
- mode: string;
966
- source: "custom" | "github";
967
- provider: string;
968
- inputCostPerToken: number | null;
969
- outputCostPerToken: number | null;
970
- maxInputTokens: number | null;
971
- maxOutputTokens: number | null;
972
- }>, "many">;
1604
+ export type GatewayLogicalConnectionKeyCreate = z.infer<typeof GatewayLogicalConnectionKeyCreateSchema>;
1605
+ export declare const GatewayLogicalConnectionKeyUpdateSchema: z.ZodEffects<z.ZodObject<{
1606
+ status: z.ZodOptional<z.ZodEnum<["active", "disabled"]>>;
1607
+ isDefault: z.ZodOptional<z.ZodBoolean>;
973
1608
  }, "strict", z.ZodTypeAny, {
974
- data: {
975
- model: string;
976
- mode: string;
977
- source: "custom" | "github";
978
- provider: string;
979
- inputCostPerToken: number | null;
980
- outputCostPerToken: number | null;
981
- maxInputTokens: number | null;
982
- maxOutputTokens: number | null;
983
- }[];
984
- ok: true;
1609
+ status?: "active" | "disabled" | undefined;
1610
+ isDefault?: boolean | undefined;
985
1611
  }, {
986
- data: {
987
- model: string;
988
- mode: string;
989
- source: "custom" | "github";
990
- provider: string;
991
- inputCostPerToken: number | null;
992
- outputCostPerToken: number | null;
993
- maxInputTokens: number | null;
994
- maxOutputTokens: number | null;
995
- }[];
996
- ok: true;
1612
+ status?: "active" | "disabled" | undefined;
1613
+ isDefault?: boolean | undefined;
1614
+ }>, {
1615
+ status?: "active" | "disabled" | undefined;
1616
+ isDefault?: boolean | undefined;
1617
+ }, {
1618
+ status?: "active" | "disabled" | undefined;
1619
+ isDefault?: boolean | undefined;
997
1620
  }>;
998
- export declare const GatewayRequestListQuerySchema: z.ZodObject<{
999
- from: z.ZodOptional<z.ZodString>;
1000
- to: z.ZodOptional<z.ZodString>;
1001
- userId: z.ZodOptional<z.ZodString>;
1002
- machineId: z.ZodOptional<z.ZodString>;
1003
- routeId: z.ZodOptional<z.ZodString>;
1004
- agent: z.ZodOptional<z.ZodString>;
1005
- model: z.ZodOptional<z.ZodString>;
1006
- provider: z.ZodOptional<z.ZodString>;
1007
- outcome: z.ZodOptional<z.ZodString>;
1008
- limit: z.ZodNumber;
1009
- offset: z.ZodNumber;
1010
- cursor: z.ZodOptional<z.ZodString>;
1621
+ export type GatewayLogicalConnectionKeyUpdate = z.infer<typeof GatewayLogicalConnectionKeyUpdateSchema>;
1622
+ export declare const GatewayLogicalConnectionKeyViewSchema: z.ZodObject<{
1623
+ id: z.ZodString;
1624
+ fingerprint: z.ZodString;
1625
+ status: z.ZodEnum<["active", "disabled"]>;
1626
+
1627
+ verified: z.ZodBoolean;
1628
+
1629
+ isDefault: z.ZodBoolean;
1630
+ createdAt: z.ZodString;
1631
+ updatedAt: z.ZodString;
1011
1632
  }, "strict", z.ZodTypeAny, {
1012
- limit: number;
1013
- offset: number;
1014
- model?: string | undefined;
1015
- agent?: string | undefined;
1016
- machineId?: string | undefined;
1017
- provider?: string | undefined;
1018
- routeId?: string | undefined;
1019
- userId?: string | undefined;
1020
- from?: string | undefined;
1021
- to?: string | undefined;
1022
- outcome?: string | undefined;
1023
- cursor?: string | undefined;
1633
+ status: "active" | "disabled";
1634
+ id: string;
1635
+ createdAt: string;
1636
+ updatedAt: string;
1637
+ isDefault: boolean;
1638
+ fingerprint: string;
1639
+ verified: boolean;
1024
1640
  }, {
1025
- limit: number;
1026
- offset: number;
1027
- model?: string | undefined;
1028
- agent?: string | undefined;
1029
- machineId?: string | undefined;
1030
- provider?: string | undefined;
1031
- routeId?: string | undefined;
1032
- userId?: string | undefined;
1033
- from?: string | undefined;
1034
- to?: string | undefined;
1035
- outcome?: string | undefined;
1036
- cursor?: string | undefined;
1641
+ status: "active" | "disabled";
1642
+ id: string;
1643
+ createdAt: string;
1644
+ updatedAt: string;
1645
+ isDefault: boolean;
1646
+ fingerprint: string;
1647
+ verified: boolean;
1037
1648
  }>;
1038
- export declare const GatewayUsageSummarySchema: z.ZodObject<{
1039
- requestCount: z.ZodNumber;
1040
- inputTokens: z.ZodNumber;
1041
- outputTokens: z.ZodNumber;
1042
- cacheReadTokens: z.ZodNumber;
1043
- cacheWriteTokens: z.ZodNumber;
1044
- reasoningTokens: z.ZodNumber;
1045
- totalTokens: z.ZodNumber;
1046
- costMicros: z.ZodNullable<z.ZodNumber>;
1047
- pricedCount: z.ZodNumber;
1048
- unpricedCount: z.ZodNumber;
1049
- errorCount: z.ZodNumber;
1050
- errorRate: z.ZodNumber;
1051
- latencyMs: z.ZodObject<{
1052
- p50: z.ZodNullable<z.ZodNumber>;
1053
- p95: z.ZodNullable<z.ZodNumber>;
1054
- }, "strict", z.ZodTypeAny, {
1055
- p50: number | null;
1056
- p95: number | null;
1057
- }, {
1058
- p50: number | null;
1059
- p95: number | null;
1060
- }>;
1061
- breakdown: z.ZodArray<z.ZodObject<{
1062
- agent: z.ZodNullable<z.ZodString>;
1063
- model: z.ZodNullable<z.ZodString>;
1064
- provider: z.ZodNullable<z.ZodString>;
1065
- requestCount: z.ZodNumber;
1066
- inputTokens: z.ZodNumber;
1067
- outputTokens: z.ZodNumber;
1068
- totalTokens: z.ZodNumber;
1069
- costMicros: z.ZodNullable<z.ZodNumber>;
1649
+ export type GatewayLogicalConnectionKeyView = z.infer<typeof GatewayLogicalConnectionKeyViewSchema>;
1650
+ export declare const GatewayLogicalConnectionKeyListResponseSchema: z.ZodObject<{
1651
+ ok: z.ZodLiteral<true>;
1652
+ data: z.ZodArray<z.ZodObject<{
1653
+ id: z.ZodString;
1654
+ fingerprint: z.ZodString;
1655
+ status: z.ZodEnum<["active", "disabled"]>;
1656
+
1657
+ verified: z.ZodBoolean;
1658
+
1659
+ isDefault: z.ZodBoolean;
1660
+ createdAt: z.ZodString;
1661
+ updatedAt: z.ZodString;
1070
1662
  }, "strict", z.ZodTypeAny, {
1071
- model: string | null;
1072
- inputTokens: number;
1073
- outputTokens: number;
1074
- totalTokens: number;
1075
- agent: string | null;
1076
- provider: string | null;
1077
- requestCount: number;
1078
- costMicros: number | null;
1663
+ status: "active" | "disabled";
1664
+ id: string;
1665
+ createdAt: string;
1666
+ updatedAt: string;
1667
+ isDefault: boolean;
1668
+ fingerprint: string;
1669
+ verified: boolean;
1079
1670
  }, {
1080
- model: string | null;
1081
- inputTokens: number;
1082
- outputTokens: number;
1083
- totalTokens: number;
1084
- agent: string | null;
1085
- provider: string | null;
1086
- requestCount: number;
1087
- costMicros: number | null;
1671
+ status: "active" | "disabled";
1672
+ id: string;
1673
+ createdAt: string;
1674
+ updatedAt: string;
1675
+ isDefault: boolean;
1676
+ fingerprint: string;
1677
+ verified: boolean;
1088
1678
  }>, "many">;
1089
1679
  }, "strict", z.ZodTypeAny, {
1090
- inputTokens: number;
1091
- outputTokens: number;
1092
- cacheReadTokens: number;
1093
- cacheWriteTokens: number;
1094
- totalTokens: number;
1095
- requestCount: number;
1096
- reasoningTokens: number;
1097
- costMicros: number | null;
1098
- pricedCount: number;
1099
- unpricedCount: number;
1100
- errorCount: number;
1101
- errorRate: number;
1102
- latencyMs: {
1103
- p50: number | null;
1104
- p95: number | null;
1105
- };
1106
- breakdown: {
1107
- model: string | null;
1108
- inputTokens: number;
1109
- outputTokens: number;
1110
- totalTokens: number;
1111
- agent: string | null;
1112
- provider: string | null;
1113
- requestCount: number;
1114
- costMicros: number | null;
1680
+ data: {
1681
+ status: "active" | "disabled";
1682
+ id: string;
1683
+ createdAt: string;
1684
+ updatedAt: string;
1685
+ isDefault: boolean;
1686
+ fingerprint: string;
1687
+ verified: boolean;
1115
1688
  }[];
1689
+ ok: true;
1116
1690
  }, {
1117
- inputTokens: number;
1118
- outputTokens: number;
1119
- cacheReadTokens: number;
1120
- cacheWriteTokens: number;
1121
- totalTokens: number;
1122
- requestCount: number;
1123
- reasoningTokens: number;
1124
- costMicros: number | null;
1125
- pricedCount: number;
1126
- unpricedCount: number;
1127
- errorCount: number;
1128
- errorRate: number;
1129
- latencyMs: {
1130
- p50: number | null;
1131
- p95: number | null;
1132
- };
1133
- breakdown: {
1134
- model: string | null;
1135
- inputTokens: number;
1136
- outputTokens: number;
1137
- totalTokens: number;
1138
- agent: string | null;
1139
- provider: string | null;
1140
- requestCount: number;
1141
- costMicros: number | null;
1691
+ data: {
1692
+ status: "active" | "disabled";
1693
+ id: string;
1694
+ createdAt: string;
1695
+ updatedAt: string;
1696
+ isDefault: boolean;
1697
+ fingerprint: string;
1698
+ verified: boolean;
1142
1699
  }[];
1143
- }>;
1144
- export type GatewayUsageSummary = z.infer<typeof GatewayUsageSummarySchema>;
1145
- export declare const GatewayDailyUsageSchema: z.ZodObject<{
1146
- day: z.ZodString;
1147
- agent: z.ZodNullable<z.ZodString>;
1148
- model: z.ZodNullable<z.ZodString>;
1149
- provider: z.ZodNullable<z.ZodString>;
1150
- requestCount: z.ZodNumber;
1151
- inputTokens: z.ZodNumber;
1152
- outputTokens: z.ZodNumber;
1153
- cacheReadTokens: z.ZodNumber;
1154
- cacheWriteTokens: z.ZodNumber;
1155
- totalTokens: z.ZodNumber;
1156
- costMicros: z.ZodNullable<z.ZodNumber>;
1157
- currency: z.ZodNullable<z.ZodString>;
1158
- }, "strict", z.ZodTypeAny, {
1159
- model: string | null;
1160
- inputTokens: number;
1161
- outputTokens: number;
1162
- cacheReadTokens: number;
1163
- cacheWriteTokens: number;
1164
- totalTokens: number;
1165
- agent: string | null;
1166
- provider: string | null;
1167
- requestCount: number;
1168
- costMicros: number | null;
1169
- day: string;
1170
- currency: string | null;
1171
- }, {
1172
- model: string | null;
1173
- inputTokens: number;
1174
- outputTokens: number;
1175
- cacheReadTokens: number;
1176
- cacheWriteTokens: number;
1177
- totalTokens: number;
1178
- agent: string | null;
1179
- provider: string | null;
1180
- requestCount: number;
1181
- costMicros: number | null;
1182
- day: string;
1183
- currency: string | null;
1700
+ ok: true;
1184
1701
  }>;