@orq-ai/node 3.11.7 → 3.11.8

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.
Files changed (155) hide show
  1. package/bin/mcp-server.js +104 -104
  2. package/bin/mcp-server.js.map +26 -26
  3. package/examples/package-lock.json +1 -1
  4. package/jsr.json +1 -1
  5. package/lib/config.d.ts +3 -3
  6. package/lib/config.js +3 -3
  7. package/mcp-server/mcp-server.js +1 -1
  8. package/mcp-server/server.js +1 -1
  9. package/models/operations/createcontact.js +2 -2
  10. package/models/operations/createdataset.js +2 -2
  11. package/models/operations/createdatasetitem.js +2 -2
  12. package/models/operations/createdatasource.js +2 -2
  13. package/models/operations/createeval.js +16 -16
  14. package/models/operations/fileget.js +2 -2
  15. package/models/operations/filelist.js +2 -2
  16. package/models/operations/fileupload.js +2 -2
  17. package/models/operations/getevals.js +28 -28
  18. package/models/operations/listcontacts.js +2 -2
  19. package/models/operations/listdatasetdatapoints.js +2 -2
  20. package/models/operations/listdatasets.js +2 -2
  21. package/models/operations/listdatasources.js +2 -2
  22. package/models/operations/retrievecontact.js +2 -2
  23. package/models/operations/retrievedatapoint.js +2 -2
  24. package/models/operations/retrievedataset.js +2 -2
  25. package/models/operations/retrievedatasource.js +2 -2
  26. package/models/operations/updatecontact.js +2 -2
  27. package/models/operations/updatedatapoint.js +2 -2
  28. package/models/operations/updatedataset.js +2 -2
  29. package/models/operations/updatedatasource.js +2 -2
  30. package/models/operations/updateeval.js +16 -16
  31. package/package.json +1 -1
  32. package/packages/orq-rc/README.md +128 -87
  33. package/packages/orq-rc/docs/sdks/batches/README.md +307 -0
  34. package/packages/orq-rc/docs/sdks/proxy/README.md +1212 -0
  35. package/packages/orq-rc/examples/package-lock.json +1 -1
  36. package/packages/orq-rc/jsr.json +1 -1
  37. package/packages/orq-rc/package-lock.json +2 -2
  38. package/packages/orq-rc/package.json +1 -1
  39. package/packages/orq-rc/src/funcs/batchesCancel.ts +166 -0
  40. package/packages/orq-rc/src/funcs/batchesCreate.ts +160 -0
  41. package/packages/orq-rc/src/funcs/batchesList.ts +165 -0
  42. package/packages/orq-rc/src/funcs/batchesRetrieve.ts +166 -0
  43. package/packages/orq-rc/src/funcs/proxyAudioSpeech.ts +159 -0
  44. package/packages/orq-rc/src/funcs/proxyAudioTranscriptions.ts +233 -0
  45. package/packages/orq-rc/src/funcs/proxyAudioTranslations.ts +223 -0
  46. package/packages/orq-rc/src/funcs/proxyChatCompletions.ts +172 -0
  47. package/packages/orq-rc/src/funcs/proxyCompletions.ts +168 -0
  48. package/packages/orq-rc/src/funcs/proxyEmbeddings.ts +161 -0
  49. package/packages/orq-rc/src/funcs/proxyImagesEdit.ts +173 -0
  50. package/packages/orq-rc/src/funcs/proxyImagesGenerate.ts +163 -0
  51. package/packages/orq-rc/src/funcs/proxyImagesVariation.ts +179 -0
  52. package/packages/orq-rc/src/funcs/proxyModerations.ts +164 -0
  53. package/packages/orq-rc/src/funcs/proxyRerank.ts +158 -0
  54. package/packages/orq-rc/src/funcs/proxyResponsesCreate.ts +171 -0
  55. package/packages/orq-rc/src/lib/config.ts +3 -3
  56. package/packages/orq-rc/src/mcp-server/mcp-server.ts +1 -1
  57. package/packages/orq-rc/src/mcp-server/server.ts +33 -1
  58. package/packages/orq-rc/src/mcp-server/tools/batchesCancel.ts +37 -0
  59. package/packages/orq-rc/src/mcp-server/tools/batchesCreate.ts +37 -0
  60. package/packages/orq-rc/src/mcp-server/tools/batchesList.ts +37 -0
  61. package/packages/orq-rc/src/mcp-server/tools/batchesRetrieve.ts +37 -0
  62. package/packages/orq-rc/src/mcp-server/tools/proxyAudioSpeech.ts +33 -0
  63. package/packages/orq-rc/src/mcp-server/tools/proxyAudioTranscriptions.ts +35 -0
  64. package/packages/orq-rc/src/mcp-server/tools/proxyAudioTranslations.ts +35 -0
  65. package/packages/orq-rc/src/mcp-server/tools/proxyChatCompletions.ts +37 -0
  66. package/packages/orq-rc/src/mcp-server/tools/proxyCompletions.ts +37 -0
  67. package/packages/orq-rc/src/mcp-server/tools/proxyEmbeddings.ts +37 -0
  68. package/packages/orq-rc/src/mcp-server/tools/proxyImagesEdit.ts +35 -0
  69. package/packages/orq-rc/src/mcp-server/tools/proxyImagesGenerate.ts +35 -0
  70. package/packages/orq-rc/src/mcp-server/tools/proxyImagesVariation.ts +35 -0
  71. package/packages/orq-rc/src/mcp-server/tools/proxyModerations.ts +35 -0
  72. package/packages/orq-rc/src/mcp-server/tools/proxyRerank.ts +36 -0
  73. package/packages/orq-rc/src/mcp-server/tools/proxyResponsesCreate.ts +37 -0
  74. package/packages/orq-rc/src/models/components/deployments.ts +861 -0
  75. package/packages/orq-rc/src/models/components/index.ts +1 -0
  76. package/packages/orq-rc/src/models/components/publiccontact.ts +114 -0
  77. package/packages/orq-rc/src/models/errors/index.ts +3 -0
  78. package/packages/orq-rc/src/models/errors/postv2proxyaudiotranscriptions.ts +163 -0
  79. package/packages/orq-rc/src/models/errors/postv2proxyaudiotranslations.ts +162 -0
  80. package/packages/orq-rc/src/models/errors/postv2proxymoderations.ts +151 -0
  81. package/packages/orq-rc/src/models/operations/cancelbatch.ts +474 -0
  82. package/packages/orq-rc/src/models/operations/createbatch.ts +531 -0
  83. package/packages/orq-rc/src/models/operations/createbudget.ts +2 -2
  84. package/packages/orq-rc/src/models/operations/createchatcompletion.ts +11697 -0
  85. package/packages/orq-rc/src/models/operations/createcontact.ts +2 -2
  86. package/packages/orq-rc/src/models/operations/createdataset.ts +2 -2
  87. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +2205 -1224
  88. package/packages/orq-rc/src/models/operations/createdatasource.ts +2 -2
  89. package/packages/orq-rc/src/models/operations/createeval.ts +16 -16
  90. package/packages/orq-rc/src/models/operations/createresponse.ts +6908 -0
  91. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +2282 -1214
  92. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +938 -51
  93. package/packages/orq-rc/src/models/operations/deploymentstream.ts +1471 -305
  94. package/packages/orq-rc/src/models/operations/fileget.ts +2 -2
  95. package/packages/orq-rc/src/models/operations/filelist.ts +2 -2
  96. package/packages/orq-rc/src/models/operations/fileupload.ts +2 -2
  97. package/packages/orq-rc/src/models/operations/getbudget.ts +2 -2
  98. package/packages/orq-rc/src/models/operations/getevals.ts +107 -92
  99. package/packages/orq-rc/src/models/operations/index.ts +16 -0
  100. package/packages/orq-rc/src/models/operations/listbatches.ts +570 -0
  101. package/packages/orq-rc/src/models/operations/listbudgets.ts +2 -2
  102. package/packages/orq-rc/src/models/operations/listcontacts.ts +2 -2
  103. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +498 -2
  104. package/packages/orq-rc/src/models/operations/listdatasets.ts +2 -2
  105. package/packages/orq-rc/src/models/operations/listdatasources.ts +2 -2
  106. package/packages/orq-rc/src/models/operations/postv2proxyaudiospeech.ts +393 -0
  107. package/packages/orq-rc/src/models/operations/postv2proxyaudiotranscriptions.ts +731 -0
  108. package/packages/orq-rc/src/models/operations/postv2proxyaudiotranslations.ts +741 -0
  109. package/packages/orq-rc/src/models/operations/postv2proxycompletions.ts +5831 -0
  110. package/packages/orq-rc/src/models/operations/postv2proxyembeddings.ts +543 -0
  111. package/packages/orq-rc/src/models/operations/postv2proxyimagesedits.ts +596 -0
  112. package/packages/orq-rc/src/models/operations/postv2proxyimagesgenerations.ts +1107 -0
  113. package/packages/orq-rc/src/models/operations/postv2proxyimagesvariations.ts +592 -0
  114. package/packages/orq-rc/src/models/operations/postv2proxymoderations.ts +802 -0
  115. package/packages/orq-rc/src/models/operations/postv2proxyrerank.ts +526 -0
  116. package/packages/orq-rc/src/models/operations/retrievebatch.ts +474 -0
  117. package/packages/orq-rc/src/models/operations/retrievecontact.ts +2 -2
  118. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +478 -2
  119. package/packages/orq-rc/src/models/operations/retrievedataset.ts +2 -2
  120. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +2 -2
  121. package/packages/orq-rc/src/models/operations/updatebudget.ts +2 -2
  122. package/packages/orq-rc/src/models/operations/updatecontact.ts +2 -2
  123. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +974 -2
  124. package/packages/orq-rc/src/models/operations/updatedataset.ts +2 -2
  125. package/packages/orq-rc/src/models/operations/updatedatasource.ts +2 -2
  126. package/packages/orq-rc/src/models/operations/updateeval.ts +16 -16
  127. package/packages/orq-rc/src/sdk/batches.ts +81 -0
  128. package/packages/orq-rc/src/sdk/proxy.ts +211 -0
  129. package/packages/orq-rc/src/sdk/sdk.ts +12 -0
  130. package/packages/orq-rc/temp/example.ts +5 -0
  131. package/src/lib/config.ts +3 -3
  132. package/src/mcp-server/mcp-server.ts +1 -1
  133. package/src/mcp-server/server.ts +1 -1
  134. package/src/models/operations/createcontact.ts +2 -2
  135. package/src/models/operations/createdataset.ts +2 -2
  136. package/src/models/operations/createdatasetitem.ts +2 -2
  137. package/src/models/operations/createdatasource.ts +2 -2
  138. package/src/models/operations/createeval.ts +16 -16
  139. package/src/models/operations/fileget.ts +2 -2
  140. package/src/models/operations/filelist.ts +2 -2
  141. package/src/models/operations/fileupload.ts +2 -2
  142. package/src/models/operations/getevals.ts +28 -28
  143. package/src/models/operations/listcontacts.ts +2 -2
  144. package/src/models/operations/listdatasetdatapoints.ts +2 -2
  145. package/src/models/operations/listdatasets.ts +2 -2
  146. package/src/models/operations/listdatasources.ts +2 -2
  147. package/src/models/operations/retrievecontact.ts +2 -2
  148. package/src/models/operations/retrievedatapoint.ts +2 -2
  149. package/src/models/operations/retrievedataset.ts +2 -2
  150. package/src/models/operations/retrievedatasource.ts +2 -2
  151. package/src/models/operations/updatecontact.ts +2 -2
  152. package/src/models/operations/updatedatapoint.ts +2 -2
  153. package/src/models/operations/updatedataset.ts +2 -2
  154. package/src/models/operations/updatedatasource.ts +2 -2
  155. package/src/models/operations/updateeval.ts +16 -16
@@ -0,0 +1,474 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { ClosedEnum } from "../../types/enums.js";
9
+ import { Result as SafeParseResult } from "../../types/fp.js";
10
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
+
12
+ export type RetrieveBatchRequest = {
13
+ batchId: string;
14
+ };
15
+
16
+ /**
17
+ * The object type, which is always batch.
18
+ */
19
+ export const RetrieveBatchObject = {
20
+ Batch: "batch",
21
+ } as const;
22
+ /**
23
+ * The object type, which is always batch.
24
+ */
25
+ export type RetrieveBatchObject = ClosedEnum<typeof RetrieveBatchObject>;
26
+
27
+ /**
28
+ * Errors associated with the batch.
29
+ */
30
+ export type RetrieveBatchErrors = {};
31
+
32
+ /**
33
+ * The request counts for different statuses within the batch.
34
+ */
35
+ export type RetrieveBatchRequestCounts = {
36
+ /**
37
+ * Total number of requests in the batch.
38
+ */
39
+ total: number;
40
+ /**
41
+ * Number of requests that have been completed successfully.
42
+ */
43
+ completed: number;
44
+ /**
45
+ * Number of requests that have failed.
46
+ */
47
+ failed: number;
48
+ };
49
+
50
+ /**
51
+ * A list of paginated Batch objects.
52
+ */
53
+ export type RetrieveBatchResponseBody = {
54
+ /**
55
+ * The ID of the batch job.
56
+ */
57
+ id: string;
58
+ /**
59
+ * The object type, which is always batch.
60
+ */
61
+ object: RetrieveBatchObject;
62
+ /**
63
+ * The OpenAI API endpoint used by the batch.
64
+ */
65
+ endpoint: string;
66
+ /**
67
+ * Errors associated with the batch.
68
+ */
69
+ errors: RetrieveBatchErrors;
70
+ /**
71
+ * The ID of the input file for the batch.
72
+ */
73
+ inputFileId: string;
74
+ /**
75
+ * The time frame within which the batch should be processed.
76
+ */
77
+ completionWindow: string;
78
+ /**
79
+ * The current status of the batch.
80
+ */
81
+ status: string;
82
+ /**
83
+ * The ID of the file containing the outputs of successfully executed requests.
84
+ */
85
+ outputFileId: string | null;
86
+ /**
87
+ * The ID of the file containing the outputs of requests with errors.
88
+ */
89
+ errorFileId: string | null;
90
+ /**
91
+ * The Unix timestamp (in seconds) for when the batch was created.
92
+ */
93
+ createdAt: number;
94
+ /**
95
+ * The Unix timestamp (in seconds) for when the batch started processing.
96
+ */
97
+ inProgressAt: number | null;
98
+ /**
99
+ * The Unix timestamp (in seconds) for when the batch will expire.
100
+ */
101
+ expiresAt: number | null;
102
+ /**
103
+ * The Unix timestamp (in seconds) for when the batch started finalizing.
104
+ */
105
+ finalizingAt: number | null;
106
+ /**
107
+ * The Unix timestamp (in seconds) for when the batch was completed.
108
+ */
109
+ completedAt: number | null;
110
+ /**
111
+ * The Unix timestamp (in seconds) for when the batch failed.
112
+ */
113
+ failedAt: number | null;
114
+ /**
115
+ * The Unix timestamp (in seconds) for when the batch expired.
116
+ */
117
+ expiredAt: number | null;
118
+ /**
119
+ * The Unix timestamp (in seconds) for when the batch started cancelling.
120
+ */
121
+ cancellingAt: number | null;
122
+ /**
123
+ * The Unix timestamp (in seconds) for when the batch was cancelled.
124
+ */
125
+ cancelledAt: number | null;
126
+ /**
127
+ * The request counts for different statuses within the batch.
128
+ */
129
+ requestCounts: RetrieveBatchRequestCounts;
130
+ /**
131
+ * Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects via API or the dashboard.
132
+ *
133
+ * @remarks
134
+ *
135
+ * Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.
136
+ */
137
+ metadata?: { [k: string]: any } | undefined;
138
+ };
139
+
140
+ /** @internal */
141
+ export const RetrieveBatchRequest$inboundSchema: z.ZodType<
142
+ RetrieveBatchRequest,
143
+ z.ZodTypeDef,
144
+ unknown
145
+ > = z.object({
146
+ batch_id: z.string(),
147
+ }).transform((v) => {
148
+ return remap$(v, {
149
+ "batch_id": "batchId",
150
+ });
151
+ });
152
+
153
+ /** @internal */
154
+ export type RetrieveBatchRequest$Outbound = {
155
+ batch_id: string;
156
+ };
157
+
158
+ /** @internal */
159
+ export const RetrieveBatchRequest$outboundSchema: z.ZodType<
160
+ RetrieveBatchRequest$Outbound,
161
+ z.ZodTypeDef,
162
+ RetrieveBatchRequest
163
+ > = z.object({
164
+ batchId: z.string(),
165
+ }).transform((v) => {
166
+ return remap$(v, {
167
+ batchId: "batch_id",
168
+ });
169
+ });
170
+
171
+ /**
172
+ * @internal
173
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
174
+ */
175
+ export namespace RetrieveBatchRequest$ {
176
+ /** @deprecated use `RetrieveBatchRequest$inboundSchema` instead. */
177
+ export const inboundSchema = RetrieveBatchRequest$inboundSchema;
178
+ /** @deprecated use `RetrieveBatchRequest$outboundSchema` instead. */
179
+ export const outboundSchema = RetrieveBatchRequest$outboundSchema;
180
+ /** @deprecated use `RetrieveBatchRequest$Outbound` instead. */
181
+ export type Outbound = RetrieveBatchRequest$Outbound;
182
+ }
183
+
184
+ export function retrieveBatchRequestToJSON(
185
+ retrieveBatchRequest: RetrieveBatchRequest,
186
+ ): string {
187
+ return JSON.stringify(
188
+ RetrieveBatchRequest$outboundSchema.parse(retrieveBatchRequest),
189
+ );
190
+ }
191
+
192
+ export function retrieveBatchRequestFromJSON(
193
+ jsonString: string,
194
+ ): SafeParseResult<RetrieveBatchRequest, SDKValidationError> {
195
+ return safeParse(
196
+ jsonString,
197
+ (x) => RetrieveBatchRequest$inboundSchema.parse(JSON.parse(x)),
198
+ `Failed to parse 'RetrieveBatchRequest' from JSON`,
199
+ );
200
+ }
201
+
202
+ /** @internal */
203
+ export const RetrieveBatchObject$inboundSchema: z.ZodNativeEnum<
204
+ typeof RetrieveBatchObject
205
+ > = z.nativeEnum(RetrieveBatchObject);
206
+
207
+ /** @internal */
208
+ export const RetrieveBatchObject$outboundSchema: z.ZodNativeEnum<
209
+ typeof RetrieveBatchObject
210
+ > = RetrieveBatchObject$inboundSchema;
211
+
212
+ /**
213
+ * @internal
214
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
215
+ */
216
+ export namespace RetrieveBatchObject$ {
217
+ /** @deprecated use `RetrieveBatchObject$inboundSchema` instead. */
218
+ export const inboundSchema = RetrieveBatchObject$inboundSchema;
219
+ /** @deprecated use `RetrieveBatchObject$outboundSchema` instead. */
220
+ export const outboundSchema = RetrieveBatchObject$outboundSchema;
221
+ }
222
+
223
+ /** @internal */
224
+ export const RetrieveBatchErrors$inboundSchema: z.ZodType<
225
+ RetrieveBatchErrors,
226
+ z.ZodTypeDef,
227
+ unknown
228
+ > = z.object({});
229
+
230
+ /** @internal */
231
+ export type RetrieveBatchErrors$Outbound = {};
232
+
233
+ /** @internal */
234
+ export const RetrieveBatchErrors$outboundSchema: z.ZodType<
235
+ RetrieveBatchErrors$Outbound,
236
+ z.ZodTypeDef,
237
+ RetrieveBatchErrors
238
+ > = z.object({});
239
+
240
+ /**
241
+ * @internal
242
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
243
+ */
244
+ export namespace RetrieveBatchErrors$ {
245
+ /** @deprecated use `RetrieveBatchErrors$inboundSchema` instead. */
246
+ export const inboundSchema = RetrieveBatchErrors$inboundSchema;
247
+ /** @deprecated use `RetrieveBatchErrors$outboundSchema` instead. */
248
+ export const outboundSchema = RetrieveBatchErrors$outboundSchema;
249
+ /** @deprecated use `RetrieveBatchErrors$Outbound` instead. */
250
+ export type Outbound = RetrieveBatchErrors$Outbound;
251
+ }
252
+
253
+ export function retrieveBatchErrorsToJSON(
254
+ retrieveBatchErrors: RetrieveBatchErrors,
255
+ ): string {
256
+ return JSON.stringify(
257
+ RetrieveBatchErrors$outboundSchema.parse(retrieveBatchErrors),
258
+ );
259
+ }
260
+
261
+ export function retrieveBatchErrorsFromJSON(
262
+ jsonString: string,
263
+ ): SafeParseResult<RetrieveBatchErrors, SDKValidationError> {
264
+ return safeParse(
265
+ jsonString,
266
+ (x) => RetrieveBatchErrors$inboundSchema.parse(JSON.parse(x)),
267
+ `Failed to parse 'RetrieveBatchErrors' from JSON`,
268
+ );
269
+ }
270
+
271
+ /** @internal */
272
+ export const RetrieveBatchRequestCounts$inboundSchema: z.ZodType<
273
+ RetrieveBatchRequestCounts,
274
+ z.ZodTypeDef,
275
+ unknown
276
+ > = z.object({
277
+ total: z.number().int(),
278
+ completed: z.number().int(),
279
+ failed: z.number().int(),
280
+ });
281
+
282
+ /** @internal */
283
+ export type RetrieveBatchRequestCounts$Outbound = {
284
+ total: number;
285
+ completed: number;
286
+ failed: number;
287
+ };
288
+
289
+ /** @internal */
290
+ export const RetrieveBatchRequestCounts$outboundSchema: z.ZodType<
291
+ RetrieveBatchRequestCounts$Outbound,
292
+ z.ZodTypeDef,
293
+ RetrieveBatchRequestCounts
294
+ > = z.object({
295
+ total: z.number().int(),
296
+ completed: z.number().int(),
297
+ failed: z.number().int(),
298
+ });
299
+
300
+ /**
301
+ * @internal
302
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
303
+ */
304
+ export namespace RetrieveBatchRequestCounts$ {
305
+ /** @deprecated use `RetrieveBatchRequestCounts$inboundSchema` instead. */
306
+ export const inboundSchema = RetrieveBatchRequestCounts$inboundSchema;
307
+ /** @deprecated use `RetrieveBatchRequestCounts$outboundSchema` instead. */
308
+ export const outboundSchema = RetrieveBatchRequestCounts$outboundSchema;
309
+ /** @deprecated use `RetrieveBatchRequestCounts$Outbound` instead. */
310
+ export type Outbound = RetrieveBatchRequestCounts$Outbound;
311
+ }
312
+
313
+ export function retrieveBatchRequestCountsToJSON(
314
+ retrieveBatchRequestCounts: RetrieveBatchRequestCounts,
315
+ ): string {
316
+ return JSON.stringify(
317
+ RetrieveBatchRequestCounts$outboundSchema.parse(retrieveBatchRequestCounts),
318
+ );
319
+ }
320
+
321
+ export function retrieveBatchRequestCountsFromJSON(
322
+ jsonString: string,
323
+ ): SafeParseResult<RetrieveBatchRequestCounts, SDKValidationError> {
324
+ return safeParse(
325
+ jsonString,
326
+ (x) => RetrieveBatchRequestCounts$inboundSchema.parse(JSON.parse(x)),
327
+ `Failed to parse 'RetrieveBatchRequestCounts' from JSON`,
328
+ );
329
+ }
330
+
331
+ /** @internal */
332
+ export const RetrieveBatchResponseBody$inboundSchema: z.ZodType<
333
+ RetrieveBatchResponseBody,
334
+ z.ZodTypeDef,
335
+ unknown
336
+ > = z.object({
337
+ id: z.string(),
338
+ object: RetrieveBatchObject$inboundSchema,
339
+ endpoint: z.string(),
340
+ errors: z.lazy(() => RetrieveBatchErrors$inboundSchema),
341
+ input_file_id: z.string(),
342
+ completion_window: z.string(),
343
+ status: z.string(),
344
+ output_file_id: z.nullable(z.string()),
345
+ error_file_id: z.nullable(z.string()),
346
+ created_at: z.number().int(),
347
+ in_progress_at: z.nullable(z.number().int()),
348
+ expires_at: z.nullable(z.number().int()),
349
+ finalizing_at: z.nullable(z.number().int()),
350
+ completed_at: z.nullable(z.number().int()),
351
+ failed_at: z.nullable(z.number().int()),
352
+ expired_at: z.nullable(z.number().int()),
353
+ cancelling_at: z.nullable(z.number().int()),
354
+ cancelled_at: z.nullable(z.number().int()),
355
+ request_counts: z.lazy(() => RetrieveBatchRequestCounts$inboundSchema),
356
+ metadata: z.record(z.any()).optional(),
357
+ }).transform((v) => {
358
+ return remap$(v, {
359
+ "input_file_id": "inputFileId",
360
+ "completion_window": "completionWindow",
361
+ "output_file_id": "outputFileId",
362
+ "error_file_id": "errorFileId",
363
+ "created_at": "createdAt",
364
+ "in_progress_at": "inProgressAt",
365
+ "expires_at": "expiresAt",
366
+ "finalizing_at": "finalizingAt",
367
+ "completed_at": "completedAt",
368
+ "failed_at": "failedAt",
369
+ "expired_at": "expiredAt",
370
+ "cancelling_at": "cancellingAt",
371
+ "cancelled_at": "cancelledAt",
372
+ "request_counts": "requestCounts",
373
+ });
374
+ });
375
+
376
+ /** @internal */
377
+ export type RetrieveBatchResponseBody$Outbound = {
378
+ id: string;
379
+ object: string;
380
+ endpoint: string;
381
+ errors: RetrieveBatchErrors$Outbound;
382
+ input_file_id: string;
383
+ completion_window: string;
384
+ status: string;
385
+ output_file_id: string | null;
386
+ error_file_id: string | null;
387
+ created_at: number;
388
+ in_progress_at: number | null;
389
+ expires_at: number | null;
390
+ finalizing_at: number | null;
391
+ completed_at: number | null;
392
+ failed_at: number | null;
393
+ expired_at: number | null;
394
+ cancelling_at: number | null;
395
+ cancelled_at: number | null;
396
+ request_counts: RetrieveBatchRequestCounts$Outbound;
397
+ metadata?: { [k: string]: any } | undefined;
398
+ };
399
+
400
+ /** @internal */
401
+ export const RetrieveBatchResponseBody$outboundSchema: z.ZodType<
402
+ RetrieveBatchResponseBody$Outbound,
403
+ z.ZodTypeDef,
404
+ RetrieveBatchResponseBody
405
+ > = z.object({
406
+ id: z.string(),
407
+ object: RetrieveBatchObject$outboundSchema,
408
+ endpoint: z.string(),
409
+ errors: z.lazy(() => RetrieveBatchErrors$outboundSchema),
410
+ inputFileId: z.string(),
411
+ completionWindow: z.string(),
412
+ status: z.string(),
413
+ outputFileId: z.nullable(z.string()),
414
+ errorFileId: z.nullable(z.string()),
415
+ createdAt: z.number().int(),
416
+ inProgressAt: z.nullable(z.number().int()),
417
+ expiresAt: z.nullable(z.number().int()),
418
+ finalizingAt: z.nullable(z.number().int()),
419
+ completedAt: z.nullable(z.number().int()),
420
+ failedAt: z.nullable(z.number().int()),
421
+ expiredAt: z.nullable(z.number().int()),
422
+ cancellingAt: z.nullable(z.number().int()),
423
+ cancelledAt: z.nullable(z.number().int()),
424
+ requestCounts: z.lazy(() => RetrieveBatchRequestCounts$outboundSchema),
425
+ metadata: z.record(z.any()).optional(),
426
+ }).transform((v) => {
427
+ return remap$(v, {
428
+ inputFileId: "input_file_id",
429
+ completionWindow: "completion_window",
430
+ outputFileId: "output_file_id",
431
+ errorFileId: "error_file_id",
432
+ createdAt: "created_at",
433
+ inProgressAt: "in_progress_at",
434
+ expiresAt: "expires_at",
435
+ finalizingAt: "finalizing_at",
436
+ completedAt: "completed_at",
437
+ failedAt: "failed_at",
438
+ expiredAt: "expired_at",
439
+ cancellingAt: "cancelling_at",
440
+ cancelledAt: "cancelled_at",
441
+ requestCounts: "request_counts",
442
+ });
443
+ });
444
+
445
+ /**
446
+ * @internal
447
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
448
+ */
449
+ export namespace RetrieveBatchResponseBody$ {
450
+ /** @deprecated use `RetrieveBatchResponseBody$inboundSchema` instead. */
451
+ export const inboundSchema = RetrieveBatchResponseBody$inboundSchema;
452
+ /** @deprecated use `RetrieveBatchResponseBody$outboundSchema` instead. */
453
+ export const outboundSchema = RetrieveBatchResponseBody$outboundSchema;
454
+ /** @deprecated use `RetrieveBatchResponseBody$Outbound` instead. */
455
+ export type Outbound = RetrieveBatchResponseBody$Outbound;
456
+ }
457
+
458
+ export function retrieveBatchResponseBodyToJSON(
459
+ retrieveBatchResponseBody: RetrieveBatchResponseBody,
460
+ ): string {
461
+ return JSON.stringify(
462
+ RetrieveBatchResponseBody$outboundSchema.parse(retrieveBatchResponseBody),
463
+ );
464
+ }
465
+
466
+ export function retrieveBatchResponseBodyFromJSON(
467
+ jsonString: string,
468
+ ): SafeParseResult<RetrieveBatchResponseBody, SDKValidationError> {
469
+ return safeParse(
470
+ jsonString,
471
+ (x) => RetrieveBatchResponseBody$inboundSchema.parse(JSON.parse(x)),
472
+ `Failed to parse 'RetrieveBatchResponseBody' from JSON`,
473
+ );
474
+ }
@@ -127,7 +127,7 @@ export const RetrieveContactResponseBody$inboundSchema: z.ZodType<
127
127
  created: z.string().datetime({ offset: true }).transform(v => new Date(v))
128
128
  .optional(),
129
129
  updated: z.string().datetime({ offset: true }).default(
130
- "2025-08-20T11:38:10.692Z",
130
+ "2025-08-27T07:41:07.739Z",
131
131
  ).transform(v => new Date(v)),
132
132
  }).transform((v) => {
133
133
  return remap$(v, {
@@ -165,7 +165,7 @@ export const RetrieveContactResponseBody$outboundSchema: z.ZodType<
165
165
  tags: z.array(z.string()).optional(),
166
166
  metadata: z.record(z.any()).optional(),
167
167
  created: z.date().transform(v => v.toISOString()).optional(),
168
- updated: z.date().default(() => new Date("2025-08-20T11:38:10.692Z"))
168
+ updated: z.date().default(() => new Date("2025-08-27T07:41:07.739Z"))
169
169
  .transform(v => v.toISOString()),
170
170
  }).transform((v) => {
171
171
  return remap$(v, {