@retab/node 1.0.87 → 1.0.90
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/README.md +1 -1
- package/dist/api/extractions/client.d.ts +4 -8
- package/dist/api/extractions/client.d.ts.map +1 -1
- package/dist/api/extractions/client.js +4 -11
- package/dist/api/jobs/client.d.ts +16 -10
- package/dist/api/jobs/client.d.ts.map +1 -1
- package/dist/api/jobs/client.js +12 -3
- package/dist/generated_types.d.ts +11197 -1508
- package/dist/generated_types.d.ts.map +1 -1
- package/dist/generated_types.js +378 -19
- package/dist/types.d.ts +3 -3
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/generated_types.js
CHANGED
|
@@ -117,7 +117,7 @@ export const ZJob = z.lazy(() => (z.object({
|
|
|
117
117
|
object: z.literal("job").default("job"),
|
|
118
118
|
status: z.union([z.literal("validating"), z.literal("queued"), z.literal("in_progress"), z.literal("completed"), z.literal("failed"), z.literal("cancelled"), z.literal("expired")]),
|
|
119
119
|
endpoint: z.union([z.literal("/v1/documents/extract"), z.literal("/v1/documents/parse"), z.literal("/v1/documents/split"), z.literal("/v1/documents/classify"), z.literal("/v1/schemas/generate"), z.literal("/v1/edit/agent/fill"), z.literal("/v1/edit/templates/fill"), z.literal("/v1/edit/templates/generate"), z.literal("/v1/projects/extract")]),
|
|
120
|
-
request: z.record(z.string(), z.any()),
|
|
120
|
+
request: z.record(z.string(), z.any()).nullable().optional(),
|
|
121
121
|
response: ZJobResponse.nullable().optional(),
|
|
122
122
|
error: ZJobError.nullable().optional(),
|
|
123
123
|
created_at: z.number(),
|
|
@@ -249,13 +249,8 @@ export const ZComputationSpec = z.lazy(() => (z.object({
|
|
|
249
249
|
export const ZDraftConfig = z.lazy(() => (z.object({
|
|
250
250
|
inference_settings: ZInferenceSettings.default({ "model": "retab-small", "temperature": 0.5, "reasoning_effort": "minimal", "image_resolution_dpi": 192, "n_consensus": 1 }),
|
|
251
251
|
json_schema: z.record(z.string(), z.any()),
|
|
252
|
-
human_in_the_loop_criteria: z.array(ZHilCriterion),
|
|
253
252
|
computation_spec: ZComputationSpec,
|
|
254
253
|
})));
|
|
255
|
-
export const ZHilCriterion = z.lazy(() => (z.object({
|
|
256
|
-
path: z.string(),
|
|
257
|
-
agentic_fix: z.boolean().default(false),
|
|
258
|
-
})));
|
|
259
254
|
export const ZPatchBuilderDocumentRequest = z.lazy(() => (z.object({
|
|
260
255
|
extraction_id: z.string().nullable().optional(),
|
|
261
256
|
prediction_data: ZPredictionData.nullable().optional(),
|
|
@@ -365,7 +360,7 @@ export const ZSchema = z.lazy(() => (ZPartialSchema.schema).merge(z.object({
|
|
|
365
360
|
json_schema: z.record(z.string(), z.any()).default({}),
|
|
366
361
|
})));
|
|
367
362
|
export const ZMessageParam = z.lazy(() => (z.object({
|
|
368
|
-
content: z.union([z.string(), z.array(z.union([ZTextBlockParam, ZImageBlockParam, ZDocumentBlockParam, ZSearchResultBlockParam, ZThinkingBlockParam, ZRedactedThinkingBlockParam, ZToolUseBlockParam, ZToolResultBlockParam, ZServerToolUseBlockParam, ZWebSearchToolResultBlockParam, z.union([ZTextBlock, ZThinkingBlock, ZRedactedThinkingBlock, ZToolUseBlock, ZServerToolUseBlock, ZWebSearchToolResultBlock])]))]),
|
|
363
|
+
content: z.union([z.string(), z.array(z.union([ZTextBlockParam, ZImageBlockParam, ZDocumentBlockParam, ZSearchResultBlockParam, ZThinkingBlockParam, ZRedactedThinkingBlockParam, ZToolUseBlockParam, ZToolResultBlockParam, ZServerToolUseBlockParam, ZWebSearchToolResultBlockParam, ZWebFetchToolResultBlockParam, ZCodeExecutionToolResultBlockParam, ZBashCodeExecutionToolResultBlockParam, ZTextEditorCodeExecutionToolResultBlockParam, ZToolSearchToolResultBlockParam, ZContainerUploadBlockParam, z.union([ZTextBlock, ZThinkingBlock, ZRedactedThinkingBlock, ZToolUseBlock, ZServerToolUseBlock, ZWebSearchToolResultBlock, ZWebFetchToolResultBlock, ZCodeExecutionToolResultBlock, ZBashCodeExecutionToolResultBlock, ZTextEditorCodeExecutionToolResultBlock, ZToolSearchToolResultBlock, ZContainerUploadBlock])]))]),
|
|
369
364
|
role: z.union([z.literal("user"), z.literal("assistant")]),
|
|
370
365
|
})));
|
|
371
366
|
export const ZPartialSchema = z.lazy(() => (z.object({
|
|
@@ -513,7 +508,6 @@ export const ZRetabParsedChatCompletion = z.lazy(() => (ZParsedChatCompletion.sc
|
|
|
513
508
|
choices: z.array(ZRetabParsedChoice),
|
|
514
509
|
extraction_id: z.string().nullable().optional(),
|
|
515
510
|
likelihoods: z.record(z.string(), z.any()).nullable().optional(),
|
|
516
|
-
requires_human_review: z.boolean().default(false),
|
|
517
511
|
request_at: z.string().nullable().optional(),
|
|
518
512
|
first_token_at: z.string().nullable().optional(),
|
|
519
513
|
last_token_at: z.string().nullable().optional(),
|
|
@@ -610,6 +604,7 @@ export const ZSplitRequest = z.lazy(() => (z.object({
|
|
|
610
604
|
subdocuments: z.array(ZSubdocument),
|
|
611
605
|
model: z.string().default("retab-small"),
|
|
612
606
|
context: z.string().nullable().optional(),
|
|
607
|
+
n_consensus: z.number().default(1),
|
|
613
608
|
})));
|
|
614
609
|
export const ZSplitResponse = z.lazy(() => (z.object({
|
|
615
610
|
splits: z.array(ZSplitResult),
|
|
@@ -617,6 +612,8 @@ export const ZSplitResponse = z.lazy(() => (z.object({
|
|
|
617
612
|
export const ZSplitResult = z.lazy(() => (z.object({
|
|
618
613
|
name: z.string(),
|
|
619
614
|
pages: z.array(z.number()),
|
|
615
|
+
confidence: z.number().nullable().optional(),
|
|
616
|
+
votes: z.array(ZSplitVote),
|
|
620
617
|
partitions: z.array(ZPartition),
|
|
621
618
|
})));
|
|
622
619
|
export const ZSubdocument = z.lazy(() => (z.object({
|
|
@@ -689,6 +686,9 @@ export const ZSplitOutputItem = z.lazy(() => (z.object({
|
|
|
689
686
|
export const ZSplitOutputSchema = z.lazy(() => (z.object({
|
|
690
687
|
splits: z.array(ZSplitOutputItem),
|
|
691
688
|
})));
|
|
689
|
+
export const ZSplitVote = z.lazy(() => (z.object({
|
|
690
|
+
pages: z.array(z.number()),
|
|
691
|
+
})));
|
|
692
692
|
export const ZDocumentCreateInputRequest = z.lazy(() => (ZDocumentCreateMessageRequest.schema).merge(z.object({
|
|
693
693
|
json_schema: z.record(z.string(), z.any()),
|
|
694
694
|
})));
|
|
@@ -752,7 +752,6 @@ export const ZDocumentExtractRequest = z.lazy(() => (z.object({
|
|
|
752
752
|
model: z.string(),
|
|
753
753
|
json_schema: z.record(z.string(), z.any()),
|
|
754
754
|
temperature: z.number().default(0.0),
|
|
755
|
-
reasoning_effort: z.union([z.literal("none"), z.literal("minimal"), z.literal("low"), z.literal("medium"), z.literal("high"), z.literal("xhigh")]).nullable().optional().default("minimal"),
|
|
756
755
|
n_consensus: z.number().default(1),
|
|
757
756
|
stream: z.boolean().default(false),
|
|
758
757
|
seed: z.number().nullable().optional(),
|
|
@@ -841,26 +840,65 @@ export const ZToolUseBlockParam = z.lazy(() => (z.object({
|
|
|
841
840
|
name: z.string(),
|
|
842
841
|
type: z.literal("tool_use"),
|
|
843
842
|
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
843
|
+
caller: z.union([ZDirectCallerParam, ZServerToolCallerParam, ZServerToolCaller20260120Param]),
|
|
844
844
|
})));
|
|
845
845
|
export const ZToolResultBlockParam = z.lazy(() => (z.object({
|
|
846
846
|
tool_use_id: z.string(),
|
|
847
847
|
type: z.literal("tool_result"),
|
|
848
848
|
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
849
|
-
content: z.union([z.string(), z.array(z.union([ZTextBlockParam, ZImageBlockParam, ZSearchResultBlockParam, ZDocumentBlockParam]))]),
|
|
849
|
+
content: z.union([z.string(), z.array(z.union([ZTextBlockParam, ZImageBlockParam, ZSearchResultBlockParam, ZDocumentBlockParam, ZToolReferenceBlockParam]))]),
|
|
850
850
|
is_error: z.boolean(),
|
|
851
851
|
})));
|
|
852
852
|
export const ZServerToolUseBlockParam = z.lazy(() => (z.object({
|
|
853
853
|
id: z.string(),
|
|
854
854
|
input: z.record(z.string(), z.object({}).passthrough()),
|
|
855
|
-
name: z.literal("web_search"),
|
|
855
|
+
name: z.union([z.literal("web_search"), z.literal("web_fetch"), z.literal("code_execution"), z.literal("bash_code_execution"), z.literal("text_editor_code_execution"), z.literal("tool_search_tool_regex"), z.literal("tool_search_tool_bm25")]),
|
|
856
856
|
type: z.literal("server_tool_use"),
|
|
857
857
|
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
858
|
+
caller: z.union([ZDirectCallerParam, ZServerToolCallerParam, ZServerToolCaller20260120Param]),
|
|
858
859
|
})));
|
|
859
860
|
export const ZWebSearchToolResultBlockParam = z.lazy(() => (z.object({
|
|
860
861
|
content: z.union([z.array(ZWebSearchResultBlockParam), ZWebSearchToolRequestErrorParam]),
|
|
861
862
|
tool_use_id: z.string(),
|
|
862
863
|
type: z.literal("web_search_tool_result"),
|
|
863
864
|
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
865
|
+
caller: z.union([ZDirectCallerParam, ZServerToolCallerParam, ZServerToolCaller20260120Param]),
|
|
866
|
+
})));
|
|
867
|
+
export const ZWebFetchToolResultBlockParam = z.lazy(() => (z.object({
|
|
868
|
+
content: z.union([ZWebFetchToolResultErrorBlockParam, ZWebFetchBlockParam]),
|
|
869
|
+
tool_use_id: z.string(),
|
|
870
|
+
type: z.literal("web_fetch_tool_result"),
|
|
871
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
872
|
+
caller: z.union([ZDirectCallerParam, ZServerToolCallerParam, ZServerToolCaller20260120Param]),
|
|
873
|
+
})));
|
|
874
|
+
export const ZCodeExecutionToolResultBlockParam = z.lazy(() => (z.object({
|
|
875
|
+
content: z.union([ZCodeExecutionToolResultErrorParam, ZCodeExecutionResultBlockParam, ZEncryptedCodeExecutionResultBlockParam]),
|
|
876
|
+
tool_use_id: z.string(),
|
|
877
|
+
type: z.literal("code_execution_tool_result"),
|
|
878
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
879
|
+
})));
|
|
880
|
+
export const ZBashCodeExecutionToolResultBlockParam = z.lazy(() => (z.object({
|
|
881
|
+
content: z.union([ZBashCodeExecutionToolResultErrorParam, ZBashCodeExecutionResultBlockParam]),
|
|
882
|
+
tool_use_id: z.string(),
|
|
883
|
+
type: z.literal("bash_code_execution_tool_result"),
|
|
884
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
885
|
+
})));
|
|
886
|
+
export const ZTextEditorCodeExecutionToolResultBlockParam = z.lazy(() => (z.object({
|
|
887
|
+
content: z.union([ZTextEditorCodeExecutionToolResultErrorParam, ZTextEditorCodeExecutionViewResultBlockParam, ZTextEditorCodeExecutionCreateResultBlockParam, ZTextEditorCodeExecutionStrReplaceResultBlockParam]),
|
|
888
|
+
tool_use_id: z.string(),
|
|
889
|
+
type: z.literal("text_editor_code_execution_tool_result"),
|
|
890
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
891
|
+
})));
|
|
892
|
+
export const ZToolSearchToolResultBlockParam = z.lazy(() => (z.object({
|
|
893
|
+
content: z.union([ZToolSearchToolResultErrorParam, ZToolSearchToolSearchResultBlockParam]),
|
|
894
|
+
tool_use_id: z.string(),
|
|
895
|
+
type: z.literal("tool_search_tool_result"),
|
|
896
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
897
|
+
})));
|
|
898
|
+
export const ZContainerUploadBlockParam = z.lazy(() => (z.object({
|
|
899
|
+
file_id: z.string(),
|
|
900
|
+
type: z.literal("container_upload"),
|
|
901
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
864
902
|
})));
|
|
865
903
|
export const ZTextBlock = z.lazy(() => (z.object({
|
|
866
904
|
citations: z.array(z.union([ZCitationCharLocation, ZCitationPageLocation, ZCitationContentBlockLocation, ZCitationsWebSearchResultLocation, ZCitationsSearchResultLocation])).nullable().optional(),
|
|
@@ -878,21 +916,54 @@ export const ZRedactedThinkingBlock = z.lazy(() => (z.object({
|
|
|
878
916
|
})));
|
|
879
917
|
export const ZToolUseBlock = z.lazy(() => (z.object({
|
|
880
918
|
id: z.string(),
|
|
919
|
+
caller: z.union([ZDirectCaller, ZServerToolCaller, ZServerToolCaller20260120]).nullable().optional(),
|
|
881
920
|
input: z.record(z.string(), z.object({}).passthrough()),
|
|
882
921
|
name: z.string(),
|
|
883
922
|
type: z.literal("tool_use"),
|
|
884
923
|
})));
|
|
885
924
|
export const ZServerToolUseBlock = z.lazy(() => (z.object({
|
|
886
925
|
id: z.string(),
|
|
926
|
+
caller: z.union([ZDirectCaller, ZServerToolCaller, ZServerToolCaller20260120]).nullable().optional(),
|
|
887
927
|
input: z.record(z.string(), z.object({}).passthrough()),
|
|
888
|
-
name: z.literal("web_search"),
|
|
928
|
+
name: z.union([z.literal("web_search"), z.literal("web_fetch"), z.literal("code_execution"), z.literal("bash_code_execution"), z.literal("text_editor_code_execution"), z.literal("tool_search_tool_regex"), z.literal("tool_search_tool_bm25")]),
|
|
889
929
|
type: z.literal("server_tool_use"),
|
|
890
930
|
})));
|
|
891
931
|
export const ZWebSearchToolResultBlock = z.lazy(() => (z.object({
|
|
932
|
+
caller: z.union([ZDirectCaller, ZServerToolCaller, ZServerToolCaller20260120]).nullable().optional(),
|
|
892
933
|
content: z.union([ZWebSearchToolResultError, z.array(ZWebSearchResultBlock)]),
|
|
893
934
|
tool_use_id: z.string(),
|
|
894
935
|
type: z.literal("web_search_tool_result"),
|
|
895
936
|
})));
|
|
937
|
+
export const ZWebFetchToolResultBlock = z.lazy(() => (z.object({
|
|
938
|
+
caller: z.union([ZDirectCaller, ZServerToolCaller, ZServerToolCaller20260120]).nullable().optional(),
|
|
939
|
+
content: z.union([ZWebFetchToolResultErrorBlock, ZWebFetchBlock]),
|
|
940
|
+
tool_use_id: z.string(),
|
|
941
|
+
type: z.literal("web_fetch_tool_result"),
|
|
942
|
+
})));
|
|
943
|
+
export const ZCodeExecutionToolResultBlock = z.lazy(() => (z.object({
|
|
944
|
+
content: z.union([ZCodeExecutionToolResultError, ZCodeExecutionResultBlock, ZEncryptedCodeExecutionResultBlock]),
|
|
945
|
+
tool_use_id: z.string(),
|
|
946
|
+
type: z.literal("code_execution_tool_result"),
|
|
947
|
+
})));
|
|
948
|
+
export const ZBashCodeExecutionToolResultBlock = z.lazy(() => (z.object({
|
|
949
|
+
content: z.union([ZBashCodeExecutionToolResultError, ZBashCodeExecutionResultBlock]),
|
|
950
|
+
tool_use_id: z.string(),
|
|
951
|
+
type: z.literal("bash_code_execution_tool_result"),
|
|
952
|
+
})));
|
|
953
|
+
export const ZTextEditorCodeExecutionToolResultBlock = z.lazy(() => (z.object({
|
|
954
|
+
content: z.union([ZTextEditorCodeExecutionToolResultError, ZTextEditorCodeExecutionViewResultBlock, ZTextEditorCodeExecutionCreateResultBlock, ZTextEditorCodeExecutionStrReplaceResultBlock]),
|
|
955
|
+
tool_use_id: z.string(),
|
|
956
|
+
type: z.literal("text_editor_code_execution_tool_result"),
|
|
957
|
+
})));
|
|
958
|
+
export const ZToolSearchToolResultBlock = z.lazy(() => (z.object({
|
|
959
|
+
content: z.union([ZToolSearchToolResultError, ZToolSearchToolSearchResultBlock]),
|
|
960
|
+
tool_use_id: z.string(),
|
|
961
|
+
type: z.literal("tool_search_tool_result"),
|
|
962
|
+
})));
|
|
963
|
+
export const ZContainerUploadBlock = z.lazy(() => (z.object({
|
|
964
|
+
file_id: z.string(),
|
|
965
|
+
type: z.literal("container_upload"),
|
|
966
|
+
})));
|
|
896
967
|
export const ZInputAudio = z.lazy(() => (z.object({
|
|
897
968
|
data: z.string(),
|
|
898
969
|
format: z.union([z.literal("wav"), z.literal("mp3")]),
|
|
@@ -1071,6 +1142,7 @@ export const ZShellCall = z.lazy(() => (z.object({
|
|
|
1071
1142
|
call_id: z.string(),
|
|
1072
1143
|
type: z.literal("shell_call"),
|
|
1073
1144
|
id: z.string().nullable().optional(),
|
|
1145
|
+
environment: z.union([ZLocalEnvironment, ZContainerReference]).nullable().optional().nullable().optional(),
|
|
1074
1146
|
status: z.union([z.literal("in_progress"), z.literal("completed"), z.literal("incomplete")]).nullable().optional(),
|
|
1075
1147
|
})));
|
|
1076
1148
|
export const ZShellCallOutput = z.lazy(() => (z.object({
|
|
@@ -1079,6 +1151,7 @@ export const ZShellCallOutput = z.lazy(() => (z.object({
|
|
|
1079
1151
|
type: z.literal("shell_call_output"),
|
|
1080
1152
|
id: z.string().nullable().optional(),
|
|
1081
1153
|
max_output_length: z.number().nullable().optional(),
|
|
1154
|
+
status: z.union([z.literal("in_progress"), z.literal("completed"), z.literal("incomplete")]).nullable().optional(),
|
|
1082
1155
|
})));
|
|
1083
1156
|
export const ZApplyPatchCall = z.lazy(() => (z.object({
|
|
1084
1157
|
call_id: z.string(),
|
|
@@ -1166,6 +1239,7 @@ export const ZResponseFunctionShellToolCall = z.lazy(() => (z.object({
|
|
|
1166
1239
|
id: z.string(),
|
|
1167
1240
|
action: ZAction,
|
|
1168
1241
|
call_id: z.string(),
|
|
1242
|
+
environment: z.union([ZResponseLocalEnvironment, ZResponseContainerReference]).nullable().optional().nullable().optional(),
|
|
1169
1243
|
status: z.union([z.literal("in_progress"), z.literal("completed"), z.literal("incomplete")]),
|
|
1170
1244
|
type: z.literal("shell_call"),
|
|
1171
1245
|
created_by: z.string().nullable().optional(),
|
|
@@ -1290,10 +1364,11 @@ export const ZCodeInterpreter = z.lazy(() => (z.object({
|
|
|
1290
1364
|
})));
|
|
1291
1365
|
export const ZImageGeneration = z.lazy(() => (z.object({
|
|
1292
1366
|
type: z.literal("image_generation"),
|
|
1367
|
+
action: z.union([z.literal("generate"), z.literal("edit"), z.literal("auto")]).nullable().optional(),
|
|
1293
1368
|
background: z.union([z.literal("transparent"), z.literal("opaque"), z.literal("auto")]).nullable().optional(),
|
|
1294
1369
|
input_fidelity: z.union([z.literal("high"), z.literal("low")]).nullable().optional(),
|
|
1295
1370
|
input_image_mask: ZImageGenerationInputImageMask.nullable().optional(),
|
|
1296
|
-
model: z.union([z.string(), z.union([z.literal("gpt-image-1"), z.literal("gpt-image-1-mini")])]).nullable().optional(),
|
|
1371
|
+
model: z.union([z.string(), z.union([z.literal("gpt-image-1"), z.literal("gpt-image-1-mini"), z.literal("gpt-image-1.5")])]).nullable().optional(),
|
|
1297
1372
|
moderation: z.union([z.literal("auto"), z.literal("low")]).nullable().optional(),
|
|
1298
1373
|
output_compression: z.number().nullable().optional(),
|
|
1299
1374
|
output_format: z.union([z.literal("png"), z.literal("webp"), z.literal("jpeg")]).nullable().optional(),
|
|
@@ -1306,6 +1381,7 @@ export const ZLocalShell = z.lazy(() => (z.object({
|
|
|
1306
1381
|
})));
|
|
1307
1382
|
export const ZFunctionShellTool = z.lazy(() => (z.object({
|
|
1308
1383
|
type: z.literal("shell"),
|
|
1384
|
+
environment: z.union([ZContainerAuto, ZLocalEnvironment, ZContainerReference]).nullable().optional().nullable().optional(),
|
|
1309
1385
|
})));
|
|
1310
1386
|
export const ZCustomTool = z.lazy(() => (z.object({
|
|
1311
1387
|
name: z.string(),
|
|
@@ -1541,6 +1617,7 @@ export const ZResponseInputParamShellCall = z.lazy(() => (z.object({
|
|
|
1541
1617
|
call_id: z.string(),
|
|
1542
1618
|
type: z.literal("shell_call"),
|
|
1543
1619
|
id: z.string().nullable().optional(),
|
|
1620
|
+
environment: z.union([ZLocalEnvironmentParam, ZContainerReferenceParam]).nullable().optional(),
|
|
1544
1621
|
status: z.union([z.literal("in_progress"), z.literal("completed"), z.literal("incomplete")]).nullable().optional(),
|
|
1545
1622
|
})));
|
|
1546
1623
|
export const ZResponseInputParamShellCallOutput = z.lazy(() => (z.object({
|
|
@@ -1549,6 +1626,7 @@ export const ZResponseInputParamShellCallOutput = z.lazy(() => (z.object({
|
|
|
1549
1626
|
type: z.literal("shell_call_output"),
|
|
1550
1627
|
id: z.string().nullable().optional(),
|
|
1551
1628
|
max_output_length: z.number().nullable().optional(),
|
|
1629
|
+
status: z.union([z.literal("in_progress"), z.literal("completed"), z.literal("incomplete")]).nullable().optional(),
|
|
1552
1630
|
})));
|
|
1553
1631
|
export const ZResponseInputParamApplyPatchCall = z.lazy(() => (z.object({
|
|
1554
1632
|
call_id: z.string(),
|
|
@@ -1639,6 +1717,22 @@ export const ZURLPDFSourceParam = z.lazy(() => (z.object({
|
|
|
1639
1717
|
export const ZCitationsConfigParam = z.lazy(() => (z.object({
|
|
1640
1718
|
enabled: z.boolean(),
|
|
1641
1719
|
})));
|
|
1720
|
+
export const ZDirectCallerParam = z.lazy(() => (z.object({
|
|
1721
|
+
type: z.literal("direct"),
|
|
1722
|
+
})));
|
|
1723
|
+
export const ZServerToolCallerParam = z.lazy(() => (z.object({
|
|
1724
|
+
tool_id: z.string(),
|
|
1725
|
+
type: z.literal("code_execution_20250825"),
|
|
1726
|
+
})));
|
|
1727
|
+
export const ZServerToolCaller20260120Param = z.lazy(() => (z.object({
|
|
1728
|
+
tool_id: z.string(),
|
|
1729
|
+
type: z.literal("code_execution_20260120"),
|
|
1730
|
+
})));
|
|
1731
|
+
export const ZToolReferenceBlockParam = z.lazy(() => (z.object({
|
|
1732
|
+
tool_name: z.string(),
|
|
1733
|
+
type: z.literal("tool_reference"),
|
|
1734
|
+
cache_control: ZCacheControlEphemeralParam.nullable().optional(),
|
|
1735
|
+
})));
|
|
1642
1736
|
export const ZWebSearchResultBlockParam = z.lazy(() => (z.object({
|
|
1643
1737
|
encrypted_content: z.string(),
|
|
1644
1738
|
title: z.string(),
|
|
@@ -1647,9 +1741,81 @@ export const ZWebSearchResultBlockParam = z.lazy(() => (z.object({
|
|
|
1647
1741
|
page_age: z.string().nullable().optional(),
|
|
1648
1742
|
})));
|
|
1649
1743
|
export const ZWebSearchToolRequestErrorParam = z.lazy(() => (z.object({
|
|
1650
|
-
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("max_uses_exceeded"), z.literal("too_many_requests"), z.literal("query_too_long")]),
|
|
1744
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("max_uses_exceeded"), z.literal("too_many_requests"), z.literal("query_too_long"), z.literal("request_too_large")]),
|
|
1651
1745
|
type: z.literal("web_search_tool_result_error"),
|
|
1652
1746
|
})));
|
|
1747
|
+
export const ZWebFetchToolResultErrorBlockParam = z.lazy(() => (z.object({
|
|
1748
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("url_too_long"), z.literal("url_not_allowed"), z.literal("url_not_accessible"), z.literal("unsupported_content_type"), z.literal("too_many_requests"), z.literal("max_uses_exceeded"), z.literal("unavailable")]),
|
|
1749
|
+
type: z.literal("web_fetch_tool_result_error"),
|
|
1750
|
+
})));
|
|
1751
|
+
export const ZWebFetchBlockParam = z.lazy(() => (z.object({
|
|
1752
|
+
content: ZDocumentBlockParam,
|
|
1753
|
+
type: z.literal("web_fetch_result"),
|
|
1754
|
+
url: z.string(),
|
|
1755
|
+
retrieved_at: z.string().nullable().optional(),
|
|
1756
|
+
})));
|
|
1757
|
+
export const ZCodeExecutionToolResultErrorParam = z.lazy(() => (z.object({
|
|
1758
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded")]),
|
|
1759
|
+
type: z.literal("code_execution_tool_result_error"),
|
|
1760
|
+
})));
|
|
1761
|
+
export const ZCodeExecutionResultBlockParam = z.lazy(() => (z.object({
|
|
1762
|
+
content: z.array(ZCodeExecutionOutputBlockParam),
|
|
1763
|
+
return_code: z.number(),
|
|
1764
|
+
stderr: z.string(),
|
|
1765
|
+
stdout: z.string(),
|
|
1766
|
+
type: z.literal("code_execution_result"),
|
|
1767
|
+
})));
|
|
1768
|
+
export const ZEncryptedCodeExecutionResultBlockParam = z.lazy(() => (z.object({
|
|
1769
|
+
content: z.array(ZCodeExecutionOutputBlockParam),
|
|
1770
|
+
encrypted_stdout: z.string(),
|
|
1771
|
+
return_code: z.number(),
|
|
1772
|
+
stderr: z.string(),
|
|
1773
|
+
type: z.literal("encrypted_code_execution_result"),
|
|
1774
|
+
})));
|
|
1775
|
+
export const ZBashCodeExecutionToolResultErrorParam = z.lazy(() => (z.object({
|
|
1776
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded"), z.literal("output_file_too_large")]),
|
|
1777
|
+
type: z.literal("bash_code_execution_tool_result_error"),
|
|
1778
|
+
})));
|
|
1779
|
+
export const ZBashCodeExecutionResultBlockParam = z.lazy(() => (z.object({
|
|
1780
|
+
content: z.array(ZBashCodeExecutionOutputBlockParam),
|
|
1781
|
+
return_code: z.number(),
|
|
1782
|
+
stderr: z.string(),
|
|
1783
|
+
stdout: z.string(),
|
|
1784
|
+
type: z.literal("bash_code_execution_result"),
|
|
1785
|
+
})));
|
|
1786
|
+
export const ZTextEditorCodeExecutionToolResultErrorParam = z.lazy(() => (z.object({
|
|
1787
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded"), z.literal("file_not_found")]),
|
|
1788
|
+
type: z.literal("text_editor_code_execution_tool_result_error"),
|
|
1789
|
+
error_message: z.string().nullable().optional(),
|
|
1790
|
+
})));
|
|
1791
|
+
export const ZTextEditorCodeExecutionViewResultBlockParam = z.lazy(() => (z.object({
|
|
1792
|
+
content: z.string(),
|
|
1793
|
+
file_type: z.union([z.literal("text"), z.literal("image"), z.literal("pdf")]),
|
|
1794
|
+
type: z.literal("text_editor_code_execution_view_result"),
|
|
1795
|
+
num_lines: z.number().nullable().optional(),
|
|
1796
|
+
start_line: z.number().nullable().optional(),
|
|
1797
|
+
total_lines: z.number().nullable().optional(),
|
|
1798
|
+
})));
|
|
1799
|
+
export const ZTextEditorCodeExecutionCreateResultBlockParam = z.lazy(() => (z.object({
|
|
1800
|
+
is_file_update: z.boolean(),
|
|
1801
|
+
type: z.literal("text_editor_code_execution_create_result"),
|
|
1802
|
+
})));
|
|
1803
|
+
export const ZTextEditorCodeExecutionStrReplaceResultBlockParam = z.lazy(() => (z.object({
|
|
1804
|
+
type: z.literal("text_editor_code_execution_str_replace_result"),
|
|
1805
|
+
lines: z.array(z.string()).nullable().optional(),
|
|
1806
|
+
new_lines: z.number().nullable().optional(),
|
|
1807
|
+
new_start: z.number().nullable().optional(),
|
|
1808
|
+
old_lines: z.number().nullable().optional(),
|
|
1809
|
+
old_start: z.number().nullable().optional(),
|
|
1810
|
+
})));
|
|
1811
|
+
export const ZToolSearchToolResultErrorParam = z.lazy(() => (z.object({
|
|
1812
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded")]),
|
|
1813
|
+
type: z.literal("tool_search_tool_result_error"),
|
|
1814
|
+
})));
|
|
1815
|
+
export const ZToolSearchToolSearchResultBlockParam = z.lazy(() => (z.object({
|
|
1816
|
+
tool_references: z.array(ZToolReferenceBlockParam),
|
|
1817
|
+
type: z.literal("tool_search_tool_search_result"),
|
|
1818
|
+
})));
|
|
1653
1819
|
export const ZCitationCharLocation = z.lazy(() => (z.object({
|
|
1654
1820
|
cited_text: z.string(),
|
|
1655
1821
|
document_index: z.number(),
|
|
@@ -1693,8 +1859,19 @@ export const ZCitationsSearchResultLocation = z.lazy(() => (z.object({
|
|
|
1693
1859
|
title: z.string().nullable().optional(),
|
|
1694
1860
|
type: z.literal("search_result_location"),
|
|
1695
1861
|
})));
|
|
1862
|
+
export const ZDirectCaller = z.lazy(() => (z.object({
|
|
1863
|
+
type: z.literal("direct"),
|
|
1864
|
+
})));
|
|
1865
|
+
export const ZServerToolCaller = z.lazy(() => (z.object({
|
|
1866
|
+
tool_id: z.string(),
|
|
1867
|
+
type: z.literal("code_execution_20250825"),
|
|
1868
|
+
})));
|
|
1869
|
+
export const ZServerToolCaller20260120 = z.lazy(() => (z.object({
|
|
1870
|
+
tool_id: z.string(),
|
|
1871
|
+
type: z.literal("code_execution_20260120"),
|
|
1872
|
+
})));
|
|
1696
1873
|
export const ZWebSearchToolResultError = z.lazy(() => (z.object({
|
|
1697
|
-
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("max_uses_exceeded"), z.literal("too_many_requests"), z.literal("query_too_long")]),
|
|
1874
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("max_uses_exceeded"), z.literal("too_many_requests"), z.literal("query_too_long"), z.literal("request_too_large")]),
|
|
1698
1875
|
type: z.literal("web_search_tool_result_error"),
|
|
1699
1876
|
})));
|
|
1700
1877
|
export const ZWebSearchResultBlock = z.lazy(() => (z.object({
|
|
@@ -1704,6 +1881,79 @@ export const ZWebSearchResultBlock = z.lazy(() => (z.object({
|
|
|
1704
1881
|
type: z.literal("web_search_result"),
|
|
1705
1882
|
url: z.string(),
|
|
1706
1883
|
})));
|
|
1884
|
+
export const ZWebFetchToolResultErrorBlock = z.lazy(() => (z.object({
|
|
1885
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("url_too_long"), z.literal("url_not_allowed"), z.literal("url_not_accessible"), z.literal("unsupported_content_type"), z.literal("too_many_requests"), z.literal("max_uses_exceeded"), z.literal("unavailable")]),
|
|
1886
|
+
type: z.literal("web_fetch_tool_result_error"),
|
|
1887
|
+
})));
|
|
1888
|
+
export const ZWebFetchBlock = z.lazy(() => (z.object({
|
|
1889
|
+
content: ZDocumentBlock,
|
|
1890
|
+
retrieved_at: z.string().nullable().optional(),
|
|
1891
|
+
type: z.literal("web_fetch_result"),
|
|
1892
|
+
url: z.string(),
|
|
1893
|
+
})));
|
|
1894
|
+
export const ZCodeExecutionToolResultError = z.lazy(() => (z.object({
|
|
1895
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded")]),
|
|
1896
|
+
type: z.literal("code_execution_tool_result_error"),
|
|
1897
|
+
})));
|
|
1898
|
+
export const ZCodeExecutionResultBlock = z.lazy(() => (z.object({
|
|
1899
|
+
content: z.array(ZCodeExecutionOutputBlock),
|
|
1900
|
+
return_code: z.number(),
|
|
1901
|
+
stderr: z.string(),
|
|
1902
|
+
stdout: z.string(),
|
|
1903
|
+
type: z.literal("code_execution_result"),
|
|
1904
|
+
})));
|
|
1905
|
+
export const ZEncryptedCodeExecutionResultBlock = z.lazy(() => (z.object({
|
|
1906
|
+
content: z.array(ZCodeExecutionOutputBlock),
|
|
1907
|
+
encrypted_stdout: z.string(),
|
|
1908
|
+
return_code: z.number(),
|
|
1909
|
+
stderr: z.string(),
|
|
1910
|
+
type: z.literal("encrypted_code_execution_result"),
|
|
1911
|
+
})));
|
|
1912
|
+
export const ZBashCodeExecutionToolResultError = z.lazy(() => (z.object({
|
|
1913
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded"), z.literal("output_file_too_large")]),
|
|
1914
|
+
type: z.literal("bash_code_execution_tool_result_error"),
|
|
1915
|
+
})));
|
|
1916
|
+
export const ZBashCodeExecutionResultBlock = z.lazy(() => (z.object({
|
|
1917
|
+
content: z.array(ZBashCodeExecutionOutputBlock),
|
|
1918
|
+
return_code: z.number(),
|
|
1919
|
+
stderr: z.string(),
|
|
1920
|
+
stdout: z.string(),
|
|
1921
|
+
type: z.literal("bash_code_execution_result"),
|
|
1922
|
+
})));
|
|
1923
|
+
export const ZTextEditorCodeExecutionToolResultError = z.lazy(() => (z.object({
|
|
1924
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded"), z.literal("file_not_found")]),
|
|
1925
|
+
error_message: z.string().nullable().optional(),
|
|
1926
|
+
type: z.literal("text_editor_code_execution_tool_result_error"),
|
|
1927
|
+
})));
|
|
1928
|
+
export const ZTextEditorCodeExecutionViewResultBlock = z.lazy(() => (z.object({
|
|
1929
|
+
content: z.string(),
|
|
1930
|
+
file_type: z.union([z.literal("text"), z.literal("image"), z.literal("pdf")]),
|
|
1931
|
+
num_lines: z.number().nullable().optional(),
|
|
1932
|
+
start_line: z.number().nullable().optional(),
|
|
1933
|
+
total_lines: z.number().nullable().optional(),
|
|
1934
|
+
type: z.literal("text_editor_code_execution_view_result"),
|
|
1935
|
+
})));
|
|
1936
|
+
export const ZTextEditorCodeExecutionCreateResultBlock = z.lazy(() => (z.object({
|
|
1937
|
+
is_file_update: z.boolean(),
|
|
1938
|
+
type: z.literal("text_editor_code_execution_create_result"),
|
|
1939
|
+
})));
|
|
1940
|
+
export const ZTextEditorCodeExecutionStrReplaceResultBlock = z.lazy(() => (z.object({
|
|
1941
|
+
lines: z.array(z.string()).nullable().optional(),
|
|
1942
|
+
new_lines: z.number().nullable().optional(),
|
|
1943
|
+
new_start: z.number().nullable().optional(),
|
|
1944
|
+
old_lines: z.number().nullable().optional(),
|
|
1945
|
+
old_start: z.number().nullable().optional(),
|
|
1946
|
+
type: z.literal("text_editor_code_execution_str_replace_result"),
|
|
1947
|
+
})));
|
|
1948
|
+
export const ZToolSearchToolResultError = z.lazy(() => (z.object({
|
|
1949
|
+
error_code: z.union([z.literal("invalid_tool_input"), z.literal("unavailable"), z.literal("too_many_requests"), z.literal("execution_time_exceeded")]),
|
|
1950
|
+
error_message: z.string().nullable().optional(),
|
|
1951
|
+
type: z.literal("tool_search_tool_result_error"),
|
|
1952
|
+
})));
|
|
1953
|
+
export const ZToolSearchToolSearchResultBlock = z.lazy(() => (z.object({
|
|
1954
|
+
tool_references: z.array(ZToolReferenceBlock),
|
|
1955
|
+
type: z.literal("tool_search_tool_search_result"),
|
|
1956
|
+
})));
|
|
1707
1957
|
export const ZParsedFunction = z.lazy(() => (ZChatCompletionMessageFunctionToolCallFunction.schema).merge(z.object({
|
|
1708
1958
|
parsed_arguments: z.object({}).passthrough().nullable().optional(),
|
|
1709
1959
|
})));
|
|
@@ -1817,11 +2067,11 @@ export const ZActionSearch = z.lazy(() => (z.object({
|
|
|
1817
2067
|
})));
|
|
1818
2068
|
export const ZActionOpenPage = z.lazy(() => (z.object({
|
|
1819
2069
|
type: z.literal("open_page"),
|
|
1820
|
-
url: z.string(),
|
|
2070
|
+
url: z.string().nullable().optional(),
|
|
1821
2071
|
})));
|
|
1822
2072
|
export const ZActionFind = z.lazy(() => (z.object({
|
|
1823
2073
|
pattern: z.string(),
|
|
1824
|
-
type: z.literal("
|
|
2074
|
+
type: z.literal("find_in_page"),
|
|
1825
2075
|
url: z.string(),
|
|
1826
2076
|
})));
|
|
1827
2077
|
export const ZResponseInputTextContent = z.lazy(() => (z.object({
|
|
@@ -1870,6 +2120,14 @@ export const ZShellCallAction = z.lazy(() => (z.object({
|
|
|
1870
2120
|
max_output_length: z.number().nullable().optional(),
|
|
1871
2121
|
timeout_ms: z.number().nullable().optional(),
|
|
1872
2122
|
})));
|
|
2123
|
+
export const ZLocalEnvironment = z.lazy(() => (z.object({
|
|
2124
|
+
type: z.literal("local"),
|
|
2125
|
+
skills: z.array(ZLocalSkill).nullable().optional(),
|
|
2126
|
+
})));
|
|
2127
|
+
export const ZContainerReference = z.lazy(() => (z.object({
|
|
2128
|
+
container_id: z.string(),
|
|
2129
|
+
type: z.literal("container_reference"),
|
|
2130
|
+
})));
|
|
1873
2131
|
export const ZResponseFunctionShellCallOutputContent = z.lazy(() => (z.object({
|
|
1874
2132
|
outcome: z.union([ZOutcomeTimeout, ZOutcomeExit]),
|
|
1875
2133
|
stderr: z.string(),
|
|
@@ -1908,6 +2166,13 @@ export const ZAction = z.lazy(() => (z.object({
|
|
|
1908
2166
|
max_output_length: z.number().nullable().optional(),
|
|
1909
2167
|
timeout_ms: z.number().nullable().optional(),
|
|
1910
2168
|
})));
|
|
2169
|
+
export const ZResponseLocalEnvironment = z.lazy(() => (z.object({
|
|
2170
|
+
type: z.literal("local"),
|
|
2171
|
+
})));
|
|
2172
|
+
export const ZResponseContainerReference = z.lazy(() => (z.object({
|
|
2173
|
+
container_id: z.string(),
|
|
2174
|
+
type: z.literal("container_reference"),
|
|
2175
|
+
})));
|
|
1911
2176
|
export const ZOutput = z.lazy(() => (z.object({
|
|
1912
2177
|
outcome: z.union([ZOutputOutcomeTimeout, ZOutputOutcomeExit]),
|
|
1913
2178
|
stderr: z.string(),
|
|
@@ -1970,11 +2235,19 @@ export const ZCodeInterpreterContainerCodeInterpreterToolAuto = z.lazy(() => (z.
|
|
|
1970
2235
|
type: z.literal("auto"),
|
|
1971
2236
|
file_ids: z.array(z.string()).nullable().optional(),
|
|
1972
2237
|
memory_limit: z.union([z.literal("1g"), z.literal("4g"), z.literal("16g"), z.literal("64g")]).nullable().optional(),
|
|
2238
|
+
network_policy: z.union([ZContainerNetworkPolicyDisabled, ZContainerNetworkPolicyAllowlist]).nullable().optional(),
|
|
1973
2239
|
})));
|
|
1974
2240
|
export const ZImageGenerationInputImageMask = z.lazy(() => (z.object({
|
|
1975
2241
|
file_id: z.string().nullable().optional(),
|
|
1976
2242
|
image_url: z.string().nullable().optional(),
|
|
1977
2243
|
})));
|
|
2244
|
+
export const ZContainerAuto = z.lazy(() => (z.object({
|
|
2245
|
+
type: z.literal("container_auto"),
|
|
2246
|
+
file_ids: z.array(z.string()).nullable().optional(),
|
|
2247
|
+
memory_limit: z.union([z.literal("1g"), z.literal("4g"), z.literal("16g"), z.literal("64g")]).nullable().optional(),
|
|
2248
|
+
network_policy: z.union([ZContainerNetworkPolicyDisabled, ZContainerNetworkPolicyAllowlist]).nullable().optional(),
|
|
2249
|
+
skills: z.array(z.union([ZSkillReference, ZInlineSkill])).nullable().optional(),
|
|
2250
|
+
})));
|
|
1978
2251
|
export const ZText = z.lazy(() => (z.object({
|
|
1979
2252
|
type: z.literal("text"),
|
|
1980
2253
|
})));
|
|
@@ -2129,11 +2402,11 @@ export const ZResponseFunctionWebSearchParamActionSearch = z.lazy(() => (z.objec
|
|
|
2129
2402
|
})));
|
|
2130
2403
|
export const ZResponseFunctionWebSearchParamActionOpenPage = z.lazy(() => (z.object({
|
|
2131
2404
|
type: z.literal("open_page"),
|
|
2132
|
-
url: z.string(),
|
|
2405
|
+
url: z.string().nullable().optional(),
|
|
2133
2406
|
})));
|
|
2134
2407
|
export const ZResponseFunctionWebSearchParamActionFind = z.lazy(() => (z.object({
|
|
2135
2408
|
pattern: z.string(),
|
|
2136
|
-
type: z.literal("
|
|
2409
|
+
type: z.literal("find_in_page"),
|
|
2137
2410
|
url: z.string(),
|
|
2138
2411
|
})));
|
|
2139
2412
|
export const ZResponseInputTextContentParam = z.lazy(() => (z.object({
|
|
@@ -2182,6 +2455,14 @@ export const ZResponseInputParamShellCallAction = z.lazy(() => (z.object({
|
|
|
2182
2455
|
max_output_length: z.number().nullable().optional(),
|
|
2183
2456
|
timeout_ms: z.number().nullable().optional(),
|
|
2184
2457
|
})));
|
|
2458
|
+
export const ZLocalEnvironmentParam = z.lazy(() => (z.object({
|
|
2459
|
+
type: z.literal("local"),
|
|
2460
|
+
skills: z.array(ZLocalSkillParam),
|
|
2461
|
+
})));
|
|
2462
|
+
export const ZContainerReferenceParam = z.lazy(() => (z.object({
|
|
2463
|
+
container_id: z.string(),
|
|
2464
|
+
type: z.literal("container_reference"),
|
|
2465
|
+
})));
|
|
2185
2466
|
export const ZResponseFunctionShellCallOutputContentParam = z.lazy(() => (z.object({
|
|
2186
2467
|
outcome: z.union([ZResponseFunctionShellCallOutputContentParamOutcomeTimeout, ZResponseFunctionShellCallOutputContentParamOutcomeExit]),
|
|
2187
2468
|
stderr: z.string(),
|
|
@@ -2207,6 +2488,32 @@ export const ZResponseInputParamMcpListToolsTool = z.lazy(() => (z.object({
|
|
|
2207
2488
|
annotations: z.object({}).passthrough().nullable().optional(),
|
|
2208
2489
|
description: z.string().nullable().optional(),
|
|
2209
2490
|
})));
|
|
2491
|
+
export const ZCodeExecutionOutputBlockParam = z.lazy(() => (z.object({
|
|
2492
|
+
file_id: z.string(),
|
|
2493
|
+
type: z.literal("code_execution_output"),
|
|
2494
|
+
})));
|
|
2495
|
+
export const ZBashCodeExecutionOutputBlockParam = z.lazy(() => (z.object({
|
|
2496
|
+
file_id: z.string(),
|
|
2497
|
+
type: z.literal("bash_code_execution_output"),
|
|
2498
|
+
})));
|
|
2499
|
+
export const ZDocumentBlock = z.lazy(() => (z.object({
|
|
2500
|
+
citations: ZCitationsConfig.nullable().optional(),
|
|
2501
|
+
source: z.union([ZBase64PDFSource, ZPlainTextSource]),
|
|
2502
|
+
title: z.string().nullable().optional(),
|
|
2503
|
+
type: z.literal("document"),
|
|
2504
|
+
})));
|
|
2505
|
+
export const ZCodeExecutionOutputBlock = z.lazy(() => (z.object({
|
|
2506
|
+
file_id: z.string(),
|
|
2507
|
+
type: z.literal("code_execution_output"),
|
|
2508
|
+
})));
|
|
2509
|
+
export const ZBashCodeExecutionOutputBlock = z.lazy(() => (z.object({
|
|
2510
|
+
file_id: z.string(),
|
|
2511
|
+
type: z.literal("bash_code_execution_output"),
|
|
2512
|
+
})));
|
|
2513
|
+
export const ZToolReferenceBlock = z.lazy(() => (z.object({
|
|
2514
|
+
tool_name: z.string(),
|
|
2515
|
+
type: z.literal("tool_reference"),
|
|
2516
|
+
})));
|
|
2210
2517
|
export const ZFunctionResponseBlobDict = z.lazy(() => (z.object({
|
|
2211
2518
|
mime_type: z.string().nullable().optional(),
|
|
2212
2519
|
data: z.instanceof(Uint8Array).nullable().optional(),
|
|
@@ -2257,6 +2564,11 @@ export const ZActionSearchSource = z.lazy(() => (z.object({
|
|
|
2257
2564
|
type: z.literal("url"),
|
|
2258
2565
|
url: z.string(),
|
|
2259
2566
|
})));
|
|
2567
|
+
export const ZLocalSkill = z.lazy(() => (z.object({
|
|
2568
|
+
description: z.string(),
|
|
2569
|
+
name: z.string(),
|
|
2570
|
+
path: z.string(),
|
|
2571
|
+
})));
|
|
2260
2572
|
export const ZOutcomeTimeout = z.lazy(() => (z.object({
|
|
2261
2573
|
type: z.literal("timeout"),
|
|
2262
2574
|
})));
|
|
@@ -2283,6 +2595,25 @@ export const ZMcpRequireApprovalMcpToolApprovalFilterNever = z.lazy(() => (z.obj
|
|
|
2283
2595
|
read_only: z.boolean().nullable().optional(),
|
|
2284
2596
|
tool_names: z.array(z.string()).nullable().optional(),
|
|
2285
2597
|
})));
|
|
2598
|
+
export const ZContainerNetworkPolicyDisabled = z.lazy(() => (z.object({
|
|
2599
|
+
type: z.literal("disabled"),
|
|
2600
|
+
})));
|
|
2601
|
+
export const ZContainerNetworkPolicyAllowlist = z.lazy(() => (z.object({
|
|
2602
|
+
allowed_domains: z.array(z.string()),
|
|
2603
|
+
type: z.literal("allowlist"),
|
|
2604
|
+
domain_secrets: z.array(ZContainerNetworkPolicyDomainSecret).nullable().optional(),
|
|
2605
|
+
})));
|
|
2606
|
+
export const ZSkillReference = z.lazy(() => (z.object({
|
|
2607
|
+
skill_id: z.string(),
|
|
2608
|
+
type: z.literal("skill_reference"),
|
|
2609
|
+
version: z.string().nullable().optional(),
|
|
2610
|
+
})));
|
|
2611
|
+
export const ZInlineSkill = z.lazy(() => (z.object({
|
|
2612
|
+
description: z.string(),
|
|
2613
|
+
name: z.string(),
|
|
2614
|
+
source: ZInlineSkillSource,
|
|
2615
|
+
type: z.literal("inline"),
|
|
2616
|
+
})));
|
|
2286
2617
|
export const ZAnnotation = z.lazy(() => (z.object({
|
|
2287
2618
|
type: z.literal("url_citation"),
|
|
2288
2619
|
url_citation: ZChatCompletionMessageAnnotationURLCitation,
|
|
@@ -2356,6 +2687,11 @@ export const ZResponseFunctionWebSearchParamActionSearchSource = z.lazy(() => (z
|
|
|
2356
2687
|
type: z.literal("url"),
|
|
2357
2688
|
url: z.string(),
|
|
2358
2689
|
})));
|
|
2690
|
+
export const ZLocalSkillParam = z.lazy(() => (z.object({
|
|
2691
|
+
description: z.string(),
|
|
2692
|
+
name: z.string(),
|
|
2693
|
+
path: z.string(),
|
|
2694
|
+
})));
|
|
2359
2695
|
export const ZResponseFunctionShellCallOutputContentParamOutcomeTimeout = z.lazy(() => (z.object({
|
|
2360
2696
|
type: z.literal("timeout"),
|
|
2361
2697
|
})));
|
|
@@ -2363,11 +2699,34 @@ export const ZResponseFunctionShellCallOutputContentParamOutcomeExit = z.lazy(()
|
|
|
2363
2699
|
exit_code: z.number(),
|
|
2364
2700
|
type: z.literal("exit"),
|
|
2365
2701
|
})));
|
|
2702
|
+
export const ZCitationsConfig = z.lazy(() => (z.object({
|
|
2703
|
+
enabled: z.boolean(),
|
|
2704
|
+
})));
|
|
2705
|
+
export const ZBase64PDFSource = z.lazy(() => (z.object({
|
|
2706
|
+
data: z.string(),
|
|
2707
|
+
media_type: z.literal("application/pdf"),
|
|
2708
|
+
type: z.literal("base64"),
|
|
2709
|
+
})));
|
|
2710
|
+
export const ZPlainTextSource = z.lazy(() => (z.object({
|
|
2711
|
+
data: z.string(),
|
|
2712
|
+
media_type: z.literal("text/plain"),
|
|
2713
|
+
type: z.literal("text"),
|
|
2714
|
+
})));
|
|
2366
2715
|
export const ZLogprobTopLogprob = z.lazy(() => (z.object({
|
|
2367
2716
|
token: z.string(),
|
|
2368
2717
|
bytes: z.array(z.number()),
|
|
2369
2718
|
logprob: z.number(),
|
|
2370
2719
|
})));
|
|
2720
|
+
export const ZContainerNetworkPolicyDomainSecret = z.lazy(() => (z.object({
|
|
2721
|
+
domain: z.string(),
|
|
2722
|
+
name: z.string(),
|
|
2723
|
+
value: z.string(),
|
|
2724
|
+
})));
|
|
2725
|
+
export const ZInlineSkillSource = z.lazy(() => (z.object({
|
|
2726
|
+
data: z.string(),
|
|
2727
|
+
media_type: z.literal("application/zip"),
|
|
2728
|
+
type: z.literal("base64"),
|
|
2729
|
+
})));
|
|
2371
2730
|
export const ZChatCompletionMessageAnnotationURLCitation = z.lazy(() => (z.object({
|
|
2372
2731
|
end_index: z.number(),
|
|
2373
2732
|
start_index: z.number(),
|