@orq-ai/node 4.1.0-rc.3 → 4.1.0-rc.5
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/bin/mcp-server.js +34865 -37649
- package/bin/mcp-server.js.map +77 -55
- package/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.js +1 -1
- package/models/components/actionreviewedstreamingevent.d.ts +76 -0
- package/models/components/actionreviewedstreamingevent.d.ts.map +1 -0
- package/models/components/actionreviewedstreamingevent.js +127 -0
- package/models/components/actionreviewedstreamingevent.js.map +1 -0
- package/models/components/actionreviewrequestedstreamingevent.d.ts +135 -0
- package/models/components/actionreviewrequestedstreamingevent.d.ts.map +1 -0
- package/models/components/actionreviewrequestedstreamingevent.js +180 -0
- package/models/components/actionreviewrequestedstreamingevent.js.map +1 -0
- package/models/components/agenterroredstreamingevent.d.ts +58 -0
- package/models/components/agenterroredstreamingevent.d.ts.map +1 -0
- package/models/components/agenterroredstreamingevent.js +91 -0
- package/models/components/agenterroredstreamingevent.js.map +1 -0
- package/models/components/agentexecutionstartedstreamingevent.d.ts +62 -0
- package/models/components/agentexecutionstartedstreamingevent.d.ts.map +1 -0
- package/models/components/agentexecutionstartedstreamingevent.js +103 -0
- package/models/components/agentexecutionstartedstreamingevent.js.map +1 -0
- package/models/components/agenthandedoffstreamingevent.d.ts +51 -0
- package/models/components/agenthandedoffstreamingevent.d.ts.map +1 -0
- package/models/components/agenthandedoffstreamingevent.js +96 -0
- package/models/components/agenthandedoffstreamingevent.js.map +1 -0
- package/models/components/agentinactivestreamingevent.d.ts +309 -0
- package/models/components/agentinactivestreamingevent.d.ts.map +1 -0
- package/models/components/agentinactivestreamingevent.js +385 -0
- package/models/components/agentinactivestreamingevent.js.map +1 -0
- package/models/components/agentmessagecreatedstreamingevent.d.ts +141 -0
- package/models/components/agentmessagecreatedstreamingevent.d.ts.map +1 -0
- package/models/components/agentmessagecreatedstreamingevent.js +190 -0
- package/models/components/agentmessagecreatedstreamingevent.js.map +1 -0
- package/models/components/agentstartedstreamingevent.d.ts +382 -0
- package/models/components/agentstartedstreamingevent.d.ts.map +1 -0
- package/models/components/agentstartedstreamingevent.js +441 -0
- package/models/components/agentstartedstreamingevent.js.map +1 -0
- package/models/components/agentthoughtstreamingevent.d.ts +542 -0
- package/models/components/agentthoughtstreamingevent.d.ts.map +1 -0
- package/models/components/agentthoughtstreamingevent.js +626 -0
- package/models/components/agentthoughtstreamingevent.js.map +1 -0
- package/models/components/datapart.d.ts +41 -0
- package/models/components/datapart.d.ts.map +1 -0
- package/models/components/datapart.js +69 -0
- package/models/components/datapart.js.map +1 -0
- package/models/components/errorstreamingevent.d.ts +51 -0
- package/models/components/errorstreamingevent.d.ts.map +1 -0
- package/models/components/errorstreamingevent.js +87 -0
- package/models/components/errorstreamingevent.js.map +1 -0
- package/models/components/executionnamedstreamingevent.d.ts +51 -0
- package/models/components/executionnamedstreamingevent.d.ts.map +1 -0
- package/models/components/executionnamedstreamingevent.js +96 -0
- package/models/components/executionnamedstreamingevent.js.map +1 -0
- package/models/components/executionreviewedstreamingevent.d.ts +45 -0
- package/models/components/executionreviewedstreamingevent.d.ts.map +1 -0
- package/models/components/executionreviewedstreamingevent.js +81 -0
- package/models/components/executionreviewedstreamingevent.js.map +1 -0
- package/models/components/executionreviewrequiredstreamingevent.d.ts +45 -0
- package/models/components/executionreviewrequiredstreamingevent.d.ts.map +1 -0
- package/models/components/executionreviewrequiredstreamingevent.js +82 -0
- package/models/components/executionreviewrequiredstreamingevent.js.map +1 -0
- package/models/components/filepart.d.ts +104 -0
- package/models/components/filepart.d.ts.map +1 -0
- package/models/components/filepart.js +134 -0
- package/models/components/filepart.js.map +1 -0
- package/models/components/index.d.ts +22 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +22 -0
- package/models/components/index.js.map +1 -1
- package/models/components/invokedeploymentrequest.d.ts +21 -21
- package/models/components/invokedeploymentrequest.d.ts.map +1 -1
- package/models/components/invokedeploymentrequest.js +27 -28
- package/models/components/invokedeploymentrequest.js.map +1 -1
- package/models/components/textpart.d.ts +31 -0
- package/models/components/textpart.d.ts.map +1 -0
- package/models/components/textpart.js +67 -0
- package/models/components/textpart.js.map +1 -0
- package/models/components/timeoutstreamingevent.d.ts +49 -0
- package/models/components/timeoutstreamingevent.d.ts.map +1 -0
- package/models/components/timeoutstreamingevent.js +85 -0
- package/models/components/timeoutstreamingevent.js.map +1 -0
- package/models/components/toolcallpart.d.ts +45 -0
- package/models/components/toolcallpart.d.ts.map +1 -0
- package/models/components/toolcallpart.js +84 -0
- package/models/components/toolcallpart.js.map +1 -0
- package/models/components/toolexecutionfailedstreamingevent.d.ts +144 -0
- package/models/components/toolexecutionfailedstreamingevent.d.ts.map +1 -0
- package/models/components/toolexecutionfailedstreamingevent.js +223 -0
- package/models/components/toolexecutionfailedstreamingevent.js.map +1 -0
- package/models/components/toolexecutionfinishedstreamingevent.d.ts +129 -0
- package/models/components/toolexecutionfinishedstreamingevent.d.ts.map +1 -0
- package/models/components/toolexecutionfinishedstreamingevent.js +205 -0
- package/models/components/toolexecutionfinishedstreamingevent.js.map +1 -0
- package/models/components/toolexecutionstartedstreamingevent.d.ts +139 -0
- package/models/components/toolexecutionstartedstreamingevent.d.ts.map +1 -0
- package/models/components/toolexecutionstartedstreamingevent.js +217 -0
- package/models/components/toolexecutionstartedstreamingevent.js.map +1 -0
- package/models/components/toolresultpart.d.ts +39 -0
- package/models/components/toolresultpart.d.ts.map +1 -0
- package/models/components/toolresultpart.js +80 -0
- package/models/components/toolresultpart.js.map +1 -0
- package/models/operations/createagentresponserequest.d.ts +56 -165
- package/models/operations/createagentresponserequest.d.ts.map +1 -1
- package/models/operations/createagentresponserequest.js +87 -170
- package/models/operations/createagentresponserequest.js.map +1 -1
- package/models/operations/createbudget.js +2 -2
- package/models/operations/createcontact.js +2 -2
- package/models/operations/createdataset.js +2 -2
- package/models/operations/createdatasetitem.js +8 -8
- package/models/operations/createdatasource.js +2 -2
- package/models/operations/createeval.d.ts +80 -145
- package/models/operations/createeval.d.ts.map +1 -1
- package/models/operations/createeval.js +190 -266
- package/models/operations/createeval.js.map +1 -1
- package/models/operations/createprompt.d.ts +9 -11
- package/models/operations/createprompt.d.ts.map +1 -1
- package/models/operations/createprompt.js +9 -11
- package/models/operations/createprompt.js.map +1 -1
- package/models/operations/createtool.js +12 -12
- package/models/operations/deploymentinvoke.d.ts +9 -11
- package/models/operations/deploymentinvoke.d.ts.map +1 -1
- package/models/operations/deploymentinvoke.js +9 -11
- package/models/operations/deploymentinvoke.js.map +1 -1
- package/models/operations/deployments.d.ts +9 -11
- package/models/operations/deployments.d.ts.map +1 -1
- package/models/operations/deployments.js +9 -11
- package/models/operations/deployments.js.map +1 -1
- package/models/operations/deploymentstream.d.ts +9 -11
- package/models/operations/deploymentstream.d.ts.map +1 -1
- package/models/operations/deploymentstream.js +9 -11
- package/models/operations/deploymentstream.js.map +1 -1
- package/models/operations/fileget.js +2 -2
- package/models/operations/filelist.js +2 -2
- package/models/operations/fileupload.js +2 -2
- package/models/operations/getallprompts.d.ts +9 -11
- package/models/operations/getallprompts.d.ts.map +1 -1
- package/models/operations/getallprompts.js +9 -11
- package/models/operations/getallprompts.js.map +1 -1
- package/models/operations/getalltools.js +12 -12
- package/models/operations/getbudget.js +2 -2
- package/models/operations/getevals.d.ts +14 -79
- package/models/operations/getevals.d.ts.map +1 -1
- package/models/operations/getevals.js +49 -132
- package/models/operations/getevals.js.map +1 -1
- package/models/operations/getoneprompt.d.ts +9 -11
- package/models/operations/getoneprompt.d.ts.map +1 -1
- package/models/operations/getoneprompt.js +9 -11
- package/models/operations/getoneprompt.js.map +1 -1
- package/models/operations/getpromptversion.d.ts +9 -11
- package/models/operations/getpromptversion.d.ts.map +1 -1
- package/models/operations/getpromptversion.js +9 -11
- package/models/operations/getpromptversion.js.map +1 -1
- package/models/operations/invokeagent.d.ts +63 -416
- package/models/operations/invokeagent.d.ts.map +1 -1
- package/models/operations/invokeagent.js +80 -429
- package/models/operations/invokeagent.js.map +1 -1
- package/models/operations/listbudgets.js +2 -2
- package/models/operations/listcontacts.js +2 -2
- package/models/operations/listdatasetdatapoints.js +8 -8
- package/models/operations/listdatasets.js +2 -2
- package/models/operations/listdatasources.js +2 -2
- package/models/operations/listknowledgebases.d.ts +16 -16
- package/models/operations/listknowledgebases.d.ts.map +1 -1
- package/models/operations/listknowledgebases.js +27 -25
- package/models/operations/listknowledgebases.js.map +1 -1
- package/models/operations/listpromptversions.d.ts +9 -11
- package/models/operations/listpromptversions.d.ts.map +1 -1
- package/models/operations/listpromptversions.js +9 -11
- package/models/operations/listpromptversions.js.map +1 -1
- package/models/operations/retrievecontact.js +2 -2
- package/models/operations/retrievedatapoint.js +8 -8
- package/models/operations/retrievedataset.js +2 -2
- package/models/operations/retrievedatasource.js +2 -2
- package/models/operations/retrievetool.js +12 -12
- package/models/operations/runagent.d.ts +49 -402
- package/models/operations/runagent.d.ts.map +1 -1
- package/models/operations/runagent.js +70 -418
- package/models/operations/runagent.js.map +1 -1
- package/models/operations/streamagent.d.ts +238 -3279
- package/models/operations/streamagent.d.ts.map +1 -1
- package/models/operations/streamagent.js +158 -3602
- package/models/operations/streamagent.js.map +1 -1
- package/models/operations/streamrunagent.d.ts +888 -3929
- package/models/operations/streamrunagent.d.ts.map +1 -1
- package/models/operations/streamrunagent.js +165 -3605
- package/models/operations/streamrunagent.js.map +1 -1
- package/models/operations/updatebudget.js +2 -2
- package/models/operations/updatecontact.js +2 -2
- package/models/operations/updatedatapoint.js +8 -8
- package/models/operations/updatedataset.js +2 -2
- package/models/operations/updatedatasource.js +2 -2
- package/models/operations/updateeval.d.ts +14 -79
- package/models/operations/updateeval.d.ts.map +1 -1
- package/models/operations/updateeval.js +51 -134
- package/models/operations/updateeval.js.map +1 -1
- package/models/operations/updatememorystore.d.ts +9 -20
- package/models/operations/updatememorystore.d.ts.map +1 -1
- package/models/operations/updatememorystore.js +9 -14
- package/models/operations/updatememorystore.js.map +1 -1
- package/models/operations/updateprompt.d.ts +18 -22
- package/models/operations/updateprompt.d.ts.map +1 -1
- package/models/operations/updateprompt.js +18 -22
- package/models/operations/updateprompt.js.map +1 -1
- package/models/operations/updatetool.js +14 -14
- package/package.json +1 -1
- package/src/lib/config.ts +3 -3
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/components/actionreviewedstreamingevent.ts +189 -0
- package/src/models/components/actionreviewrequestedstreamingevent.ts +326 -0
- package/src/models/components/agenterroredstreamingevent.ts +142 -0
- package/src/models/components/agentexecutionstartedstreamingevent.ts +145 -0
- package/src/models/components/agenthandedoffstreamingevent.ts +142 -0
- package/src/models/components/agentinactivestreamingevent.ts +857 -0
- package/src/models/components/agentmessagecreatedstreamingevent.ts +396 -0
- package/src/models/components/agentstartedstreamingevent.ts +909 -0
- package/src/models/components/agentthoughtstreamingevent.ts +1419 -0
- package/src/models/components/datapart.ts +71 -0
- package/src/models/components/errorstreamingevent.ts +129 -0
- package/src/models/components/executionnamedstreamingevent.ts +142 -0
- package/src/models/components/executionreviewedstreamingevent.ts +122 -0
- package/src/models/components/executionreviewrequiredstreamingevent.ts +130 -0
- package/src/models/components/filepart.ts +231 -0
- package/src/models/components/index.ts +22 -0
- package/src/models/components/invokedeploymentrequest.ts +66 -52
- package/src/models/components/textpart.ts +68 -0
- package/src/models/components/timeoutstreamingevent.ts +125 -0
- package/src/models/components/toolcallpart.ts +92 -0
- package/src/models/components/toolexecutionfailedstreamingevent.ts +406 -0
- package/src/models/components/toolexecutionfinishedstreamingevent.ts +373 -0
- package/src/models/components/toolexecutionstartedstreamingevent.ts +350 -0
- package/src/models/components/toolresultpart.ts +86 -0
- package/src/models/operations/createagentresponserequest.ts +184 -392
- package/src/models/operations/createbudget.ts +2 -2
- package/src/models/operations/createcontact.ts +2 -2
- package/src/models/operations/createdataset.ts +2 -2
- package/src/models/operations/createdatasetitem.ts +8 -8
- package/src/models/operations/createdatasource.ts +2 -2
- package/src/models/operations/createeval.ts +318 -615
- package/src/models/operations/createprompt.ts +9 -11
- package/src/models/operations/createtool.ts +12 -12
- package/src/models/operations/deploymentinvoke.ts +9 -11
- package/src/models/operations/deployments.ts +9 -11
- package/src/models/operations/deploymentstream.ts +9 -11
- package/src/models/operations/fileget.ts +2 -2
- package/src/models/operations/filelist.ts +2 -2
- package/src/models/operations/fileupload.ts +2 -2
- package/src/models/operations/getallprompts.ts +9 -11
- package/src/models/operations/getalltools.ts +12 -12
- package/src/models/operations/getbudget.ts +2 -2
- package/src/models/operations/getevals.ts +52 -287
- package/src/models/operations/getoneprompt.ts +9 -11
- package/src/models/operations/getpromptversion.ts +9 -11
- package/src/models/operations/invokeagent.ts +180 -1041
- package/src/models/operations/listbudgets.ts +2 -2
- package/src/models/operations/listcontacts.ts +2 -2
- package/src/models/operations/listdatasetdatapoints.ts +8 -8
- package/src/models/operations/listdatasets.ts +2 -2
- package/src/models/operations/listdatasources.ts +2 -2
- package/src/models/operations/listknowledgebases.ts +82 -102
- package/src/models/operations/listpromptversions.ts +9 -11
- package/src/models/operations/retrievecontact.ts +2 -2
- package/src/models/operations/retrievedatapoint.ts +8 -8
- package/src/models/operations/retrievedataset.ts +2 -2
- package/src/models/operations/retrievedatasource.ts +2 -2
- package/src/models/operations/retrievetool.ts +12 -12
- package/src/models/operations/runagent.ts +238 -1140
- package/src/models/operations/streamagent.ts +777 -9305
- package/src/models/operations/streamrunagent.ts +3839 -12309
- package/src/models/operations/updatebudget.ts +2 -2
- package/src/models/operations/updatecontact.ts +2 -2
- package/src/models/operations/updatedatapoint.ts +8 -8
- package/src/models/operations/updatedataset.ts +2 -2
- package/src/models/operations/updatedatasource.ts +2 -2
- package/src/models/operations/updateeval.ts +52 -287
- package/src/models/operations/updatememorystore.ts +9 -20
- package/src/models/operations/updateprompt.ts +18 -22
- package/src/models/operations/updatetool.ts +14 -14
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
} from "../../lib/schemas.js";
|
|
11
11
|
import { ClosedEnum } from "../../types/enums.js";
|
|
12
12
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
13
|
+
import * as components from "../components/index.js";
|
|
13
14
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
14
15
|
|
|
15
16
|
/**
|
|
@@ -773,101 +774,13 @@ export type RunAgentRoleUserMessage = ClosedEnum<
|
|
|
773
774
|
*/
|
|
774
775
|
export type RunAgentRole = RunAgentRoleUserMessage | RunAgentRoleToolMessage;
|
|
775
776
|
|
|
776
|
-
export const RunAgentPublicMessagePartAgentsRequestKind = {
|
|
777
|
-
ToolResult: "tool_result",
|
|
778
|
-
} as const;
|
|
779
|
-
export type RunAgentPublicMessagePartAgentsRequestKind = ClosedEnum<
|
|
780
|
-
typeof RunAgentPublicMessagePartAgentsRequestKind
|
|
781
|
-
>;
|
|
782
|
-
|
|
783
|
-
/**
|
|
784
|
-
* Tool execution result part. Use this ONLY when providing results for a pending tool call from the agent. The tool_call_id must match the ID from the agent's tool call request.
|
|
785
|
-
*/
|
|
786
|
-
export type RunAgentPublicMessagePartToolResultPart = {
|
|
787
|
-
kind: RunAgentPublicMessagePartAgentsRequestKind;
|
|
788
|
-
toolCallId: string;
|
|
789
|
-
result?: any | undefined;
|
|
790
|
-
metadata?: { [k: string]: any } | undefined;
|
|
791
|
-
};
|
|
792
|
-
|
|
793
|
-
export const RunAgentPublicMessagePartAgentsKind = {
|
|
794
|
-
File: "file",
|
|
795
|
-
} as const;
|
|
796
|
-
export type RunAgentPublicMessagePartAgentsKind = ClosedEnum<
|
|
797
|
-
typeof RunAgentPublicMessagePartAgentsKind
|
|
798
|
-
>;
|
|
799
|
-
|
|
800
|
-
/**
|
|
801
|
-
* File in URI format. Check in the model's documentation for the supported mime types for the URI format
|
|
802
|
-
*/
|
|
803
|
-
export type RunAgentFileFileInURIFormat = {
|
|
804
|
-
/**
|
|
805
|
-
* URL for the File content
|
|
806
|
-
*/
|
|
807
|
-
uri: string;
|
|
808
|
-
/**
|
|
809
|
-
* Optional mimeType for the file
|
|
810
|
-
*/
|
|
811
|
-
mimeType?: string | undefined;
|
|
812
|
-
/**
|
|
813
|
-
* Optional name for the file
|
|
814
|
-
*/
|
|
815
|
-
name?: string | undefined;
|
|
816
|
-
};
|
|
817
|
-
|
|
818
|
-
/**
|
|
819
|
-
* Binary in base64 format. Check in the model's documentation for the supported mime types for the binary format.
|
|
820
|
-
*/
|
|
821
|
-
export type RunAgentFileBinaryFormat = {
|
|
822
|
-
/**
|
|
823
|
-
* base64 encoded content of the file
|
|
824
|
-
*/
|
|
825
|
-
bytes: string;
|
|
826
|
-
/**
|
|
827
|
-
* Optional mimeType for the file
|
|
828
|
-
*/
|
|
829
|
-
mimeType?: string | undefined;
|
|
830
|
-
/**
|
|
831
|
-
* Optional name for the file
|
|
832
|
-
*/
|
|
833
|
-
name?: string | undefined;
|
|
834
|
-
};
|
|
835
|
-
|
|
836
|
-
export type RunAgentPublicMessagePartFile =
|
|
837
|
-
| RunAgentFileBinaryFormat
|
|
838
|
-
| RunAgentFileFileInURIFormat;
|
|
839
|
-
|
|
840
|
-
/**
|
|
841
|
-
* File attachment part. Use this to send files (images, documents, etc.) to the agent for processing.
|
|
842
|
-
*/
|
|
843
|
-
export type RunAgentPublicMessagePartFilePart = {
|
|
844
|
-
kind: RunAgentPublicMessagePartAgentsKind;
|
|
845
|
-
file: RunAgentFileBinaryFormat | RunAgentFileFileInURIFormat;
|
|
846
|
-
metadata?: { [k: string]: any } | undefined;
|
|
847
|
-
};
|
|
848
|
-
|
|
849
|
-
export const RunAgentPublicMessagePartKind = {
|
|
850
|
-
Text: "text",
|
|
851
|
-
} as const;
|
|
852
|
-
export type RunAgentPublicMessagePartKind = ClosedEnum<
|
|
853
|
-
typeof RunAgentPublicMessagePartKind
|
|
854
|
-
>;
|
|
855
|
-
|
|
856
|
-
/**
|
|
857
|
-
* Text content part. Use this to send text messages to the agent.
|
|
858
|
-
*/
|
|
859
|
-
export type RunAgentPublicMessagePartTextPart = {
|
|
860
|
-
kind: RunAgentPublicMessagePartKind;
|
|
861
|
-
text: string;
|
|
862
|
-
};
|
|
863
|
-
|
|
864
777
|
/**
|
|
865
778
|
* Message part that can be provided by users. Use "text" for regular messages, "file" for attachments, or "tool_result" when responding to tool call requests.
|
|
866
779
|
*/
|
|
867
780
|
export type RunAgentPublicMessagePart =
|
|
868
|
-
|
|
|
869
|
-
|
|
|
870
|
-
|
|
|
781
|
+
| components.TextPart
|
|
782
|
+
| components.FilePart
|
|
783
|
+
| components.ToolResultPart;
|
|
871
784
|
|
|
872
785
|
/**
|
|
873
786
|
* The A2A format message containing the task for the agent to perform.
|
|
@@ -885,9 +798,7 @@ export type RunAgentA2AMessage = {
|
|
|
885
798
|
* A2A message parts (text, file, or tool_result only)
|
|
886
799
|
*/
|
|
887
800
|
parts: Array<
|
|
888
|
-
|
|
|
889
|
-
| RunAgentPublicMessagePartFilePart
|
|
890
|
-
| RunAgentPublicMessagePartToolResultPart
|
|
801
|
+
components.TextPart | components.FilePart | components.ToolResultPart
|
|
891
802
|
>;
|
|
892
803
|
};
|
|
893
804
|
|
|
@@ -1809,132 +1720,12 @@ export type RunAgentExtendedMessageRole = ClosedEnum<
|
|
|
1809
1720
|
typeof RunAgentExtendedMessageRole
|
|
1810
1721
|
>;
|
|
1811
1722
|
|
|
1812
|
-
export const RunAgentPartsAgentsResponse200ApplicationJSONKind = {
|
|
1813
|
-
ToolResult: "tool_result",
|
|
1814
|
-
} as const;
|
|
1815
|
-
export type RunAgentPartsAgentsResponse200ApplicationJSONKind = ClosedEnum<
|
|
1816
|
-
typeof RunAgentPartsAgentsResponse200ApplicationJSONKind
|
|
1817
|
-
>;
|
|
1818
|
-
|
|
1819
|
-
/**
|
|
1820
|
-
* The result of a tool execution. Contains the tool call ID for correlation and the result data from the tool invocation.
|
|
1821
|
-
*/
|
|
1822
|
-
export type RunAgentPartsToolResultPart = {
|
|
1823
|
-
kind: RunAgentPartsAgentsResponse200ApplicationJSONKind;
|
|
1824
|
-
toolCallId: string;
|
|
1825
|
-
result?: any | undefined;
|
|
1826
|
-
metadata?: { [k: string]: any } | undefined;
|
|
1827
|
-
};
|
|
1828
|
-
|
|
1829
|
-
export const RunAgentPartsAgentsResponse200Kind = {
|
|
1830
|
-
ToolCall: "tool_call",
|
|
1831
|
-
} as const;
|
|
1832
|
-
export type RunAgentPartsAgentsResponse200Kind = ClosedEnum<
|
|
1833
|
-
typeof RunAgentPartsAgentsResponse200Kind
|
|
1834
|
-
>;
|
|
1835
|
-
|
|
1836
|
-
/**
|
|
1837
|
-
* A tool invocation request from an agent. Contains the tool name, unique call ID, and arguments for the tool execution.
|
|
1838
|
-
*/
|
|
1839
|
-
export type PartsToolCallPart = {
|
|
1840
|
-
kind: RunAgentPartsAgentsResponse200Kind;
|
|
1841
|
-
toolName: string;
|
|
1842
|
-
toolCallId: string;
|
|
1843
|
-
arguments: { [k: string]: any };
|
|
1844
|
-
metadata?: { [k: string]: any } | undefined;
|
|
1845
|
-
};
|
|
1846
|
-
|
|
1847
|
-
export const RunAgentPartsAgentsResponseKind = {
|
|
1848
|
-
File: "file",
|
|
1849
|
-
} as const;
|
|
1850
|
-
export type RunAgentPartsAgentsResponseKind = ClosedEnum<
|
|
1851
|
-
typeof RunAgentPartsAgentsResponseKind
|
|
1852
|
-
>;
|
|
1853
|
-
|
|
1854
|
-
/**
|
|
1855
|
-
* File in URI format. Check in the model's documentation for the supported mime types for the URI format
|
|
1856
|
-
*/
|
|
1857
|
-
export type RunAgentFileAgentsFileInURIFormat = {
|
|
1858
|
-
/**
|
|
1859
|
-
* URL for the File content
|
|
1860
|
-
*/
|
|
1861
|
-
uri: string;
|
|
1862
|
-
/**
|
|
1863
|
-
* Optional mimeType for the file
|
|
1864
|
-
*/
|
|
1865
|
-
mimeType?: string | undefined;
|
|
1866
|
-
/**
|
|
1867
|
-
* Optional name for the file
|
|
1868
|
-
*/
|
|
1869
|
-
name?: string | undefined;
|
|
1870
|
-
};
|
|
1871
|
-
|
|
1872
|
-
/**
|
|
1873
|
-
* Binary in base64 format. Check in the model's documentation for the supported mime types for the binary format.
|
|
1874
|
-
*/
|
|
1875
|
-
export type RunAgentFileAgentsBinaryFormat = {
|
|
1876
|
-
/**
|
|
1877
|
-
* base64 encoded content of the file
|
|
1878
|
-
*/
|
|
1879
|
-
bytes: string;
|
|
1880
|
-
/**
|
|
1881
|
-
* Optional mimeType for the file
|
|
1882
|
-
*/
|
|
1883
|
-
mimeType?: string | undefined;
|
|
1884
|
-
/**
|
|
1885
|
-
* Optional name for the file
|
|
1886
|
-
*/
|
|
1887
|
-
name?: string | undefined;
|
|
1888
|
-
};
|
|
1889
|
-
|
|
1890
|
-
export type RunAgentPartsFile =
|
|
1891
|
-
| RunAgentFileAgentsBinaryFormat
|
|
1892
|
-
| RunAgentFileAgentsFileInURIFormat;
|
|
1893
|
-
|
|
1894
|
-
/**
|
|
1895
|
-
* A file content part that can contain either base64-encoded bytes or a URI reference. Used for images, documents, and other binary content in agent communications.
|
|
1896
|
-
*/
|
|
1897
|
-
export type RunAgentPartsFilePart = {
|
|
1898
|
-
kind: RunAgentPartsAgentsResponseKind;
|
|
1899
|
-
file: RunAgentFileAgentsBinaryFormat | RunAgentFileAgentsFileInURIFormat;
|
|
1900
|
-
metadata?: { [k: string]: any } | undefined;
|
|
1901
|
-
};
|
|
1902
|
-
|
|
1903
|
-
export const RunAgentPartsAgentsKind = {
|
|
1904
|
-
Data: "data",
|
|
1905
|
-
} as const;
|
|
1906
|
-
export type RunAgentPartsAgentsKind = ClosedEnum<
|
|
1907
|
-
typeof RunAgentPartsAgentsKind
|
|
1908
|
-
>;
|
|
1909
|
-
|
|
1910
|
-
/**
|
|
1911
|
-
* A structured data part containing JSON-serializable key-value pairs. Used for passing structured information between agents and tools.
|
|
1912
|
-
*/
|
|
1913
|
-
export type PartsDataPart = {
|
|
1914
|
-
kind: RunAgentPartsAgentsKind;
|
|
1915
|
-
data: { [k: string]: any };
|
|
1916
|
-
metadata?: { [k: string]: any } | undefined;
|
|
1917
|
-
};
|
|
1918
|
-
|
|
1919
|
-
export const RunAgentPartsKind = {
|
|
1920
|
-
Text: "text",
|
|
1921
|
-
} as const;
|
|
1922
|
-
export type RunAgentPartsKind = ClosedEnum<typeof RunAgentPartsKind>;
|
|
1923
|
-
|
|
1924
|
-
/**
|
|
1925
|
-
* A text content part containing plain text or markdown. Used for agent messages, user input, and text-based responses.
|
|
1926
|
-
*/
|
|
1927
|
-
export type RunAgentPartsTextPart = {
|
|
1928
|
-
kind: RunAgentPartsKind;
|
|
1929
|
-
text: string;
|
|
1930
|
-
};
|
|
1931
|
-
|
|
1932
1723
|
export type RunAgentParts =
|
|
1933
|
-
|
|
|
1934
|
-
|
|
|
1935
|
-
|
|
|
1936
|
-
|
|
|
1937
|
-
|
|
|
1724
|
+
| (components.ToolCallPart & { kind: "tool_call" })
|
|
1725
|
+
| (components.TextPart & { kind: "text" })
|
|
1726
|
+
| (components.DataPart & { kind: "data" })
|
|
1727
|
+
| (components.FilePart & { kind: "file" })
|
|
1728
|
+
| (components.ToolResultPart & { kind: "tool_result" });
|
|
1938
1729
|
|
|
1939
1730
|
/**
|
|
1940
1731
|
* Optional A2A message providing additional context about the current status
|
|
@@ -1947,11 +1738,11 @@ export type RunAgentTaskStatusMessage = {
|
|
|
1947
1738
|
*/
|
|
1948
1739
|
role: RunAgentExtendedMessageRole;
|
|
1949
1740
|
parts: Array<
|
|
1950
|
-
|
|
|
1951
|
-
|
|
|
1952
|
-
|
|
|
1953
|
-
|
|
|
1954
|
-
|
|
|
1741
|
+
| (components.ToolCallPart & { kind: "tool_call" })
|
|
1742
|
+
| (components.TextPart & { kind: "text" })
|
|
1743
|
+
| (components.DataPart & { kind: "data" })
|
|
1744
|
+
| (components.FilePart & { kind: "file" })
|
|
1745
|
+
| (components.ToolResultPart & { kind: "tool_result" })
|
|
1955
1746
|
>;
|
|
1956
1747
|
};
|
|
1957
1748
|
|
|
@@ -4009,522 +3800,196 @@ export function runAgentRoleFromJSON(
|
|
|
4009
3800
|
}
|
|
4010
3801
|
|
|
4011
3802
|
/** @internal */
|
|
4012
|
-
export const
|
|
4013
|
-
|
|
4014
|
-
.nativeEnum(RunAgentPublicMessagePartAgentsRequestKind);
|
|
4015
|
-
/** @internal */
|
|
4016
|
-
export const RunAgentPublicMessagePartAgentsRequestKind$outboundSchema:
|
|
4017
|
-
z.ZodNativeEnum<typeof RunAgentPublicMessagePartAgentsRequestKind> =
|
|
4018
|
-
RunAgentPublicMessagePartAgentsRequestKind$inboundSchema;
|
|
4019
|
-
|
|
4020
|
-
/** @internal */
|
|
4021
|
-
export const RunAgentPublicMessagePartToolResultPart$inboundSchema: z.ZodType<
|
|
4022
|
-
RunAgentPublicMessagePartToolResultPart,
|
|
3803
|
+
export const RunAgentPublicMessagePart$inboundSchema: z.ZodType<
|
|
3804
|
+
RunAgentPublicMessagePart,
|
|
4023
3805
|
z.ZodTypeDef,
|
|
4024
3806
|
unknown
|
|
4025
|
-
> = z.
|
|
4026
|
-
|
|
4027
|
-
|
|
4028
|
-
|
|
4029
|
-
|
|
4030
|
-
}).transform((v) => {
|
|
4031
|
-
return remap$(v, {
|
|
4032
|
-
"tool_call_id": "toolCallId",
|
|
4033
|
-
});
|
|
4034
|
-
});
|
|
3807
|
+
> = z.union([
|
|
3808
|
+
components.TextPart$inboundSchema,
|
|
3809
|
+
components.FilePart$inboundSchema,
|
|
3810
|
+
components.ToolResultPart$inboundSchema,
|
|
3811
|
+
]);
|
|
4035
3812
|
/** @internal */
|
|
4036
|
-
export type
|
|
4037
|
-
|
|
4038
|
-
|
|
4039
|
-
|
|
4040
|
-
metadata?: { [k: string]: any } | undefined;
|
|
4041
|
-
};
|
|
3813
|
+
export type RunAgentPublicMessagePart$Outbound =
|
|
3814
|
+
| components.TextPart$Outbound
|
|
3815
|
+
| components.FilePart$Outbound
|
|
3816
|
+
| components.ToolResultPart$Outbound;
|
|
4042
3817
|
|
|
4043
3818
|
/** @internal */
|
|
4044
|
-
export const
|
|
4045
|
-
|
|
3819
|
+
export const RunAgentPublicMessagePart$outboundSchema: z.ZodType<
|
|
3820
|
+
RunAgentPublicMessagePart$Outbound,
|
|
4046
3821
|
z.ZodTypeDef,
|
|
4047
|
-
|
|
4048
|
-
> = z.
|
|
4049
|
-
|
|
4050
|
-
|
|
4051
|
-
|
|
4052
|
-
|
|
4053
|
-
}).transform((v) => {
|
|
4054
|
-
return remap$(v, {
|
|
4055
|
-
toolCallId: "tool_call_id",
|
|
4056
|
-
});
|
|
4057
|
-
});
|
|
3822
|
+
RunAgentPublicMessagePart
|
|
3823
|
+
> = z.union([
|
|
3824
|
+
components.TextPart$outboundSchema,
|
|
3825
|
+
components.FilePart$outboundSchema,
|
|
3826
|
+
components.ToolResultPart$outboundSchema,
|
|
3827
|
+
]);
|
|
4058
3828
|
|
|
4059
|
-
export function
|
|
4060
|
-
|
|
4061
|
-
RunAgentPublicMessagePartToolResultPart,
|
|
3829
|
+
export function runAgentPublicMessagePartToJSON(
|
|
3830
|
+
runAgentPublicMessagePart: RunAgentPublicMessagePart,
|
|
4062
3831
|
): string {
|
|
4063
3832
|
return JSON.stringify(
|
|
4064
|
-
|
|
4065
|
-
runAgentPublicMessagePartToolResultPart,
|
|
4066
|
-
),
|
|
3833
|
+
RunAgentPublicMessagePart$outboundSchema.parse(runAgentPublicMessagePart),
|
|
4067
3834
|
);
|
|
4068
3835
|
}
|
|
4069
|
-
export function
|
|
3836
|
+
export function runAgentPublicMessagePartFromJSON(
|
|
4070
3837
|
jsonString: string,
|
|
4071
|
-
): SafeParseResult<
|
|
4072
|
-
RunAgentPublicMessagePartToolResultPart,
|
|
4073
|
-
SDKValidationError
|
|
4074
|
-
> {
|
|
3838
|
+
): SafeParseResult<RunAgentPublicMessagePart, SDKValidationError> {
|
|
4075
3839
|
return safeParse(
|
|
4076
3840
|
jsonString,
|
|
4077
|
-
(x) =>
|
|
4078
|
-
|
|
4079
|
-
JSON.parse(x),
|
|
4080
|
-
),
|
|
4081
|
-
`Failed to parse 'RunAgentPublicMessagePartToolResultPart' from JSON`,
|
|
3841
|
+
(x) => RunAgentPublicMessagePart$inboundSchema.parse(JSON.parse(x)),
|
|
3842
|
+
`Failed to parse 'RunAgentPublicMessagePart' from JSON`,
|
|
4082
3843
|
);
|
|
4083
3844
|
}
|
|
4084
3845
|
|
|
4085
3846
|
/** @internal */
|
|
4086
|
-
export const
|
|
4087
|
-
|
|
4088
|
-
> = z.nativeEnum(RunAgentPublicMessagePartAgentsKind);
|
|
4089
|
-
/** @internal */
|
|
4090
|
-
export const RunAgentPublicMessagePartAgentsKind$outboundSchema:
|
|
4091
|
-
z.ZodNativeEnum<typeof RunAgentPublicMessagePartAgentsKind> =
|
|
4092
|
-
RunAgentPublicMessagePartAgentsKind$inboundSchema;
|
|
4093
|
-
|
|
4094
|
-
/** @internal */
|
|
4095
|
-
export const RunAgentFileFileInURIFormat$inboundSchema: z.ZodType<
|
|
4096
|
-
RunAgentFileFileInURIFormat,
|
|
3847
|
+
export const RunAgentA2AMessage$inboundSchema: z.ZodType<
|
|
3848
|
+
RunAgentA2AMessage,
|
|
4097
3849
|
z.ZodTypeDef,
|
|
4098
3850
|
unknown
|
|
4099
3851
|
> = z.object({
|
|
4100
|
-
|
|
4101
|
-
|
|
4102
|
-
|
|
3852
|
+
messageId: z.string().optional(),
|
|
3853
|
+
role: z.union([
|
|
3854
|
+
RunAgentRoleUserMessage$inboundSchema,
|
|
3855
|
+
RunAgentRoleToolMessage$inboundSchema,
|
|
3856
|
+
]),
|
|
3857
|
+
parts: z.array(
|
|
3858
|
+
z.union([
|
|
3859
|
+
components.TextPart$inboundSchema,
|
|
3860
|
+
components.FilePart$inboundSchema,
|
|
3861
|
+
components.ToolResultPart$inboundSchema,
|
|
3862
|
+
]),
|
|
3863
|
+
),
|
|
4103
3864
|
});
|
|
4104
3865
|
/** @internal */
|
|
4105
|
-
export type
|
|
4106
|
-
|
|
4107
|
-
|
|
4108
|
-
|
|
3866
|
+
export type RunAgentA2AMessage$Outbound = {
|
|
3867
|
+
messageId?: string | undefined;
|
|
3868
|
+
role: string | string;
|
|
3869
|
+
parts: Array<
|
|
3870
|
+
| components.TextPart$Outbound
|
|
3871
|
+
| components.FilePart$Outbound
|
|
3872
|
+
| components.ToolResultPart$Outbound
|
|
3873
|
+
>;
|
|
4109
3874
|
};
|
|
4110
3875
|
|
|
4111
3876
|
/** @internal */
|
|
4112
|
-
export const
|
|
4113
|
-
|
|
3877
|
+
export const RunAgentA2AMessage$outboundSchema: z.ZodType<
|
|
3878
|
+
RunAgentA2AMessage$Outbound,
|
|
4114
3879
|
z.ZodTypeDef,
|
|
4115
|
-
|
|
3880
|
+
RunAgentA2AMessage
|
|
4116
3881
|
> = z.object({
|
|
4117
|
-
|
|
4118
|
-
|
|
4119
|
-
|
|
3882
|
+
messageId: z.string().optional(),
|
|
3883
|
+
role: z.union([
|
|
3884
|
+
RunAgentRoleUserMessage$outboundSchema,
|
|
3885
|
+
RunAgentRoleToolMessage$outboundSchema,
|
|
3886
|
+
]),
|
|
3887
|
+
parts: z.array(
|
|
3888
|
+
z.union([
|
|
3889
|
+
components.TextPart$outboundSchema,
|
|
3890
|
+
components.FilePart$outboundSchema,
|
|
3891
|
+
components.ToolResultPart$outboundSchema,
|
|
3892
|
+
]),
|
|
3893
|
+
),
|
|
4120
3894
|
});
|
|
4121
3895
|
|
|
4122
|
-
export function
|
|
4123
|
-
|
|
3896
|
+
export function runAgentA2AMessageToJSON(
|
|
3897
|
+
runAgentA2AMessage: RunAgentA2AMessage,
|
|
4124
3898
|
): string {
|
|
4125
3899
|
return JSON.stringify(
|
|
4126
|
-
|
|
4127
|
-
runAgentFileFileInURIFormat,
|
|
4128
|
-
),
|
|
3900
|
+
RunAgentA2AMessage$outboundSchema.parse(runAgentA2AMessage),
|
|
4129
3901
|
);
|
|
4130
3902
|
}
|
|
4131
|
-
export function
|
|
3903
|
+
export function runAgentA2AMessageFromJSON(
|
|
4132
3904
|
jsonString: string,
|
|
4133
|
-
): SafeParseResult<
|
|
3905
|
+
): SafeParseResult<RunAgentA2AMessage, SDKValidationError> {
|
|
4134
3906
|
return safeParse(
|
|
4135
3907
|
jsonString,
|
|
4136
|
-
(x) =>
|
|
4137
|
-
`Failed to parse '
|
|
3908
|
+
(x) => RunAgentA2AMessage$inboundSchema.parse(JSON.parse(x)),
|
|
3909
|
+
`Failed to parse 'RunAgentA2AMessage' from JSON`,
|
|
4138
3910
|
);
|
|
4139
3911
|
}
|
|
4140
3912
|
|
|
4141
3913
|
/** @internal */
|
|
4142
|
-
export const
|
|
4143
|
-
|
|
3914
|
+
export const RunAgentContact$inboundSchema: z.ZodType<
|
|
3915
|
+
RunAgentContact,
|
|
4144
3916
|
z.ZodTypeDef,
|
|
4145
3917
|
unknown
|
|
4146
3918
|
> = z.object({
|
|
4147
|
-
|
|
4148
|
-
|
|
4149
|
-
|
|
3919
|
+
id: z.string(),
|
|
3920
|
+
display_name: z.string().optional(),
|
|
3921
|
+
email: z.string().optional(),
|
|
3922
|
+
metadata: z.array(z.record(z.any())).optional(),
|
|
3923
|
+
logo_url: z.string().optional(),
|
|
3924
|
+
tags: z.array(z.string()).optional(),
|
|
3925
|
+
}).transform((v) => {
|
|
3926
|
+
return remap$(v, {
|
|
3927
|
+
"display_name": "displayName",
|
|
3928
|
+
"logo_url": "logoUrl",
|
|
3929
|
+
});
|
|
4150
3930
|
});
|
|
4151
3931
|
/** @internal */
|
|
4152
|
-
export type
|
|
4153
|
-
|
|
4154
|
-
|
|
4155
|
-
|
|
3932
|
+
export type RunAgentContact$Outbound = {
|
|
3933
|
+
id: string;
|
|
3934
|
+
display_name?: string | undefined;
|
|
3935
|
+
email?: string | undefined;
|
|
3936
|
+
metadata?: Array<{ [k: string]: any }> | undefined;
|
|
3937
|
+
logo_url?: string | undefined;
|
|
3938
|
+
tags?: Array<string> | undefined;
|
|
4156
3939
|
};
|
|
4157
3940
|
|
|
4158
3941
|
/** @internal */
|
|
4159
|
-
export const
|
|
4160
|
-
|
|
3942
|
+
export const RunAgentContact$outboundSchema: z.ZodType<
|
|
3943
|
+
RunAgentContact$Outbound,
|
|
4161
3944
|
z.ZodTypeDef,
|
|
4162
|
-
|
|
3945
|
+
RunAgentContact
|
|
4163
3946
|
> = z.object({
|
|
4164
|
-
|
|
4165
|
-
|
|
4166
|
-
|
|
3947
|
+
id: z.string(),
|
|
3948
|
+
displayName: z.string().optional(),
|
|
3949
|
+
email: z.string().optional(),
|
|
3950
|
+
metadata: z.array(z.record(z.any())).optional(),
|
|
3951
|
+
logoUrl: z.string().optional(),
|
|
3952
|
+
tags: z.array(z.string()).optional(),
|
|
3953
|
+
}).transform((v) => {
|
|
3954
|
+
return remap$(v, {
|
|
3955
|
+
displayName: "display_name",
|
|
3956
|
+
logoUrl: "logo_url",
|
|
3957
|
+
});
|
|
4167
3958
|
});
|
|
4168
3959
|
|
|
4169
|
-
export function
|
|
4170
|
-
|
|
3960
|
+
export function runAgentContactToJSON(
|
|
3961
|
+
runAgentContact: RunAgentContact,
|
|
4171
3962
|
): string {
|
|
4172
|
-
return JSON.stringify(
|
|
4173
|
-
RunAgentFileBinaryFormat$outboundSchema.parse(runAgentFileBinaryFormat),
|
|
4174
|
-
);
|
|
3963
|
+
return JSON.stringify(RunAgentContact$outboundSchema.parse(runAgentContact));
|
|
4175
3964
|
}
|
|
4176
|
-
export function
|
|
3965
|
+
export function runAgentContactFromJSON(
|
|
4177
3966
|
jsonString: string,
|
|
4178
|
-
): SafeParseResult<
|
|
3967
|
+
): SafeParseResult<RunAgentContact, SDKValidationError> {
|
|
4179
3968
|
return safeParse(
|
|
4180
3969
|
jsonString,
|
|
4181
|
-
(x) =>
|
|
4182
|
-
`Failed to parse '
|
|
3970
|
+
(x) => RunAgentContact$inboundSchema.parse(JSON.parse(x)),
|
|
3971
|
+
`Failed to parse 'RunAgentContact' from JSON`,
|
|
4183
3972
|
);
|
|
4184
3973
|
}
|
|
4185
3974
|
|
|
4186
3975
|
/** @internal */
|
|
4187
|
-
export const
|
|
4188
|
-
|
|
3976
|
+
export const RunAgentThread$inboundSchema: z.ZodType<
|
|
3977
|
+
RunAgentThread,
|
|
4189
3978
|
z.ZodTypeDef,
|
|
4190
3979
|
unknown
|
|
4191
|
-
> = z.
|
|
4192
|
-
z.
|
|
4193
|
-
z.
|
|
4194
|
-
|
|
3980
|
+
> = z.object({
|
|
3981
|
+
id: z.string(),
|
|
3982
|
+
tags: z.array(z.string()).optional(),
|
|
3983
|
+
});
|
|
4195
3984
|
/** @internal */
|
|
4196
|
-
export type
|
|
4197
|
-
|
|
4198
|
-
|
|
|
3985
|
+
export type RunAgentThread$Outbound = {
|
|
3986
|
+
id: string;
|
|
3987
|
+
tags?: Array<string> | undefined;
|
|
3988
|
+
};
|
|
4199
3989
|
|
|
4200
3990
|
/** @internal */
|
|
4201
|
-
export const
|
|
4202
|
-
|
|
4203
|
-
z.ZodTypeDef,
|
|
4204
|
-
RunAgentPublicMessagePartFile
|
|
4205
|
-
> = z.union([
|
|
4206
|
-
z.lazy(() => RunAgentFileBinaryFormat$outboundSchema),
|
|
4207
|
-
z.lazy(() => RunAgentFileFileInURIFormat$outboundSchema),
|
|
4208
|
-
]);
|
|
4209
|
-
|
|
4210
|
-
export function runAgentPublicMessagePartFileToJSON(
|
|
4211
|
-
runAgentPublicMessagePartFile: RunAgentPublicMessagePartFile,
|
|
4212
|
-
): string {
|
|
4213
|
-
return JSON.stringify(
|
|
4214
|
-
RunAgentPublicMessagePartFile$outboundSchema.parse(
|
|
4215
|
-
runAgentPublicMessagePartFile,
|
|
4216
|
-
),
|
|
4217
|
-
);
|
|
4218
|
-
}
|
|
4219
|
-
export function runAgentPublicMessagePartFileFromJSON(
|
|
4220
|
-
jsonString: string,
|
|
4221
|
-
): SafeParseResult<RunAgentPublicMessagePartFile, SDKValidationError> {
|
|
4222
|
-
return safeParse(
|
|
4223
|
-
jsonString,
|
|
4224
|
-
(x) => RunAgentPublicMessagePartFile$inboundSchema.parse(JSON.parse(x)),
|
|
4225
|
-
`Failed to parse 'RunAgentPublicMessagePartFile' from JSON`,
|
|
4226
|
-
);
|
|
4227
|
-
}
|
|
4228
|
-
|
|
4229
|
-
/** @internal */
|
|
4230
|
-
export const RunAgentPublicMessagePartFilePart$inboundSchema: z.ZodType<
|
|
4231
|
-
RunAgentPublicMessagePartFilePart,
|
|
4232
|
-
z.ZodTypeDef,
|
|
4233
|
-
unknown
|
|
4234
|
-
> = z.object({
|
|
4235
|
-
kind: RunAgentPublicMessagePartAgentsKind$inboundSchema,
|
|
4236
|
-
file: z.union([
|
|
4237
|
-
z.lazy(() => RunAgentFileBinaryFormat$inboundSchema),
|
|
4238
|
-
z.lazy(() => RunAgentFileFileInURIFormat$inboundSchema),
|
|
4239
|
-
]),
|
|
4240
|
-
metadata: z.record(z.any()).optional(),
|
|
4241
|
-
});
|
|
4242
|
-
/** @internal */
|
|
4243
|
-
export type RunAgentPublicMessagePartFilePart$Outbound = {
|
|
4244
|
-
kind: string;
|
|
4245
|
-
file:
|
|
4246
|
-
| RunAgentFileBinaryFormat$Outbound
|
|
4247
|
-
| RunAgentFileFileInURIFormat$Outbound;
|
|
4248
|
-
metadata?: { [k: string]: any } | undefined;
|
|
4249
|
-
};
|
|
4250
|
-
|
|
4251
|
-
/** @internal */
|
|
4252
|
-
export const RunAgentPublicMessagePartFilePart$outboundSchema: z.ZodType<
|
|
4253
|
-
RunAgentPublicMessagePartFilePart$Outbound,
|
|
4254
|
-
z.ZodTypeDef,
|
|
4255
|
-
RunAgentPublicMessagePartFilePart
|
|
4256
|
-
> = z.object({
|
|
4257
|
-
kind: RunAgentPublicMessagePartAgentsKind$outboundSchema,
|
|
4258
|
-
file: z.union([
|
|
4259
|
-
z.lazy(() => RunAgentFileBinaryFormat$outboundSchema),
|
|
4260
|
-
z.lazy(() => RunAgentFileFileInURIFormat$outboundSchema),
|
|
4261
|
-
]),
|
|
4262
|
-
metadata: z.record(z.any()).optional(),
|
|
4263
|
-
});
|
|
4264
|
-
|
|
4265
|
-
export function runAgentPublicMessagePartFilePartToJSON(
|
|
4266
|
-
runAgentPublicMessagePartFilePart: RunAgentPublicMessagePartFilePart,
|
|
4267
|
-
): string {
|
|
4268
|
-
return JSON.stringify(
|
|
4269
|
-
RunAgentPublicMessagePartFilePart$outboundSchema.parse(
|
|
4270
|
-
runAgentPublicMessagePartFilePart,
|
|
4271
|
-
),
|
|
4272
|
-
);
|
|
4273
|
-
}
|
|
4274
|
-
export function runAgentPublicMessagePartFilePartFromJSON(
|
|
4275
|
-
jsonString: string,
|
|
4276
|
-
): SafeParseResult<RunAgentPublicMessagePartFilePart, SDKValidationError> {
|
|
4277
|
-
return safeParse(
|
|
4278
|
-
jsonString,
|
|
4279
|
-
(x) => RunAgentPublicMessagePartFilePart$inboundSchema.parse(JSON.parse(x)),
|
|
4280
|
-
`Failed to parse 'RunAgentPublicMessagePartFilePart' from JSON`,
|
|
4281
|
-
);
|
|
4282
|
-
}
|
|
4283
|
-
|
|
4284
|
-
/** @internal */
|
|
4285
|
-
export const RunAgentPublicMessagePartKind$inboundSchema: z.ZodNativeEnum<
|
|
4286
|
-
typeof RunAgentPublicMessagePartKind
|
|
4287
|
-
> = z.nativeEnum(RunAgentPublicMessagePartKind);
|
|
4288
|
-
/** @internal */
|
|
4289
|
-
export const RunAgentPublicMessagePartKind$outboundSchema: z.ZodNativeEnum<
|
|
4290
|
-
typeof RunAgentPublicMessagePartKind
|
|
4291
|
-
> = RunAgentPublicMessagePartKind$inboundSchema;
|
|
4292
|
-
|
|
4293
|
-
/** @internal */
|
|
4294
|
-
export const RunAgentPublicMessagePartTextPart$inboundSchema: z.ZodType<
|
|
4295
|
-
RunAgentPublicMessagePartTextPart,
|
|
4296
|
-
z.ZodTypeDef,
|
|
4297
|
-
unknown
|
|
4298
|
-
> = z.object({
|
|
4299
|
-
kind: RunAgentPublicMessagePartKind$inboundSchema,
|
|
4300
|
-
text: z.string(),
|
|
4301
|
-
});
|
|
4302
|
-
/** @internal */
|
|
4303
|
-
export type RunAgentPublicMessagePartTextPart$Outbound = {
|
|
4304
|
-
kind: string;
|
|
4305
|
-
text: string;
|
|
4306
|
-
};
|
|
4307
|
-
|
|
4308
|
-
/** @internal */
|
|
4309
|
-
export const RunAgentPublicMessagePartTextPart$outboundSchema: z.ZodType<
|
|
4310
|
-
RunAgentPublicMessagePartTextPart$Outbound,
|
|
4311
|
-
z.ZodTypeDef,
|
|
4312
|
-
RunAgentPublicMessagePartTextPart
|
|
4313
|
-
> = z.object({
|
|
4314
|
-
kind: RunAgentPublicMessagePartKind$outboundSchema,
|
|
4315
|
-
text: z.string(),
|
|
4316
|
-
});
|
|
4317
|
-
|
|
4318
|
-
export function runAgentPublicMessagePartTextPartToJSON(
|
|
4319
|
-
runAgentPublicMessagePartTextPart: RunAgentPublicMessagePartTextPart,
|
|
4320
|
-
): string {
|
|
4321
|
-
return JSON.stringify(
|
|
4322
|
-
RunAgentPublicMessagePartTextPart$outboundSchema.parse(
|
|
4323
|
-
runAgentPublicMessagePartTextPart,
|
|
4324
|
-
),
|
|
4325
|
-
);
|
|
4326
|
-
}
|
|
4327
|
-
export function runAgentPublicMessagePartTextPartFromJSON(
|
|
4328
|
-
jsonString: string,
|
|
4329
|
-
): SafeParseResult<RunAgentPublicMessagePartTextPart, SDKValidationError> {
|
|
4330
|
-
return safeParse(
|
|
4331
|
-
jsonString,
|
|
4332
|
-
(x) => RunAgentPublicMessagePartTextPart$inboundSchema.parse(JSON.parse(x)),
|
|
4333
|
-
`Failed to parse 'RunAgentPublicMessagePartTextPart' from JSON`,
|
|
4334
|
-
);
|
|
4335
|
-
}
|
|
4336
|
-
|
|
4337
|
-
/** @internal */
|
|
4338
|
-
export const RunAgentPublicMessagePart$inboundSchema: z.ZodType<
|
|
4339
|
-
RunAgentPublicMessagePart,
|
|
4340
|
-
z.ZodTypeDef,
|
|
4341
|
-
unknown
|
|
4342
|
-
> = z.union([
|
|
4343
|
-
z.lazy(() => RunAgentPublicMessagePartTextPart$inboundSchema),
|
|
4344
|
-
z.lazy(() => RunAgentPublicMessagePartFilePart$inboundSchema),
|
|
4345
|
-
z.lazy(() => RunAgentPublicMessagePartToolResultPart$inboundSchema),
|
|
4346
|
-
]);
|
|
4347
|
-
/** @internal */
|
|
4348
|
-
export type RunAgentPublicMessagePart$Outbound =
|
|
4349
|
-
| RunAgentPublicMessagePartTextPart$Outbound
|
|
4350
|
-
| RunAgentPublicMessagePartFilePart$Outbound
|
|
4351
|
-
| RunAgentPublicMessagePartToolResultPart$Outbound;
|
|
4352
|
-
|
|
4353
|
-
/** @internal */
|
|
4354
|
-
export const RunAgentPublicMessagePart$outboundSchema: z.ZodType<
|
|
4355
|
-
RunAgentPublicMessagePart$Outbound,
|
|
4356
|
-
z.ZodTypeDef,
|
|
4357
|
-
RunAgentPublicMessagePart
|
|
4358
|
-
> = z.union([
|
|
4359
|
-
z.lazy(() => RunAgentPublicMessagePartTextPart$outboundSchema),
|
|
4360
|
-
z.lazy(() => RunAgentPublicMessagePartFilePart$outboundSchema),
|
|
4361
|
-
z.lazy(() => RunAgentPublicMessagePartToolResultPart$outboundSchema),
|
|
4362
|
-
]);
|
|
4363
|
-
|
|
4364
|
-
export function runAgentPublicMessagePartToJSON(
|
|
4365
|
-
runAgentPublicMessagePart: RunAgentPublicMessagePart,
|
|
4366
|
-
): string {
|
|
4367
|
-
return JSON.stringify(
|
|
4368
|
-
RunAgentPublicMessagePart$outboundSchema.parse(runAgentPublicMessagePart),
|
|
4369
|
-
);
|
|
4370
|
-
}
|
|
4371
|
-
export function runAgentPublicMessagePartFromJSON(
|
|
4372
|
-
jsonString: string,
|
|
4373
|
-
): SafeParseResult<RunAgentPublicMessagePart, SDKValidationError> {
|
|
4374
|
-
return safeParse(
|
|
4375
|
-
jsonString,
|
|
4376
|
-
(x) => RunAgentPublicMessagePart$inboundSchema.parse(JSON.parse(x)),
|
|
4377
|
-
`Failed to parse 'RunAgentPublicMessagePart' from JSON`,
|
|
4378
|
-
);
|
|
4379
|
-
}
|
|
4380
|
-
|
|
4381
|
-
/** @internal */
|
|
4382
|
-
export const RunAgentA2AMessage$inboundSchema: z.ZodType<
|
|
4383
|
-
RunAgentA2AMessage,
|
|
4384
|
-
z.ZodTypeDef,
|
|
4385
|
-
unknown
|
|
4386
|
-
> = z.object({
|
|
4387
|
-
messageId: z.string().optional(),
|
|
4388
|
-
role: z.union([
|
|
4389
|
-
RunAgentRoleUserMessage$inboundSchema,
|
|
4390
|
-
RunAgentRoleToolMessage$inboundSchema,
|
|
4391
|
-
]),
|
|
4392
|
-
parts: z.array(
|
|
4393
|
-
z.union([
|
|
4394
|
-
z.lazy(() => RunAgentPublicMessagePartTextPart$inboundSchema),
|
|
4395
|
-
z.lazy(() => RunAgentPublicMessagePartFilePart$inboundSchema),
|
|
4396
|
-
z.lazy(() => RunAgentPublicMessagePartToolResultPart$inboundSchema),
|
|
4397
|
-
]),
|
|
4398
|
-
),
|
|
4399
|
-
});
|
|
4400
|
-
/** @internal */
|
|
4401
|
-
export type RunAgentA2AMessage$Outbound = {
|
|
4402
|
-
messageId?: string | undefined;
|
|
4403
|
-
role: string | string;
|
|
4404
|
-
parts: Array<
|
|
4405
|
-
| RunAgentPublicMessagePartTextPart$Outbound
|
|
4406
|
-
| RunAgentPublicMessagePartFilePart$Outbound
|
|
4407
|
-
| RunAgentPublicMessagePartToolResultPart$Outbound
|
|
4408
|
-
>;
|
|
4409
|
-
};
|
|
4410
|
-
|
|
4411
|
-
/** @internal */
|
|
4412
|
-
export const RunAgentA2AMessage$outboundSchema: z.ZodType<
|
|
4413
|
-
RunAgentA2AMessage$Outbound,
|
|
4414
|
-
z.ZodTypeDef,
|
|
4415
|
-
RunAgentA2AMessage
|
|
4416
|
-
> = z.object({
|
|
4417
|
-
messageId: z.string().optional(),
|
|
4418
|
-
role: z.union([
|
|
4419
|
-
RunAgentRoleUserMessage$outboundSchema,
|
|
4420
|
-
RunAgentRoleToolMessage$outboundSchema,
|
|
4421
|
-
]),
|
|
4422
|
-
parts: z.array(
|
|
4423
|
-
z.union([
|
|
4424
|
-
z.lazy(() => RunAgentPublicMessagePartTextPart$outboundSchema),
|
|
4425
|
-
z.lazy(() => RunAgentPublicMessagePartFilePart$outboundSchema),
|
|
4426
|
-
z.lazy(() => RunAgentPublicMessagePartToolResultPart$outboundSchema),
|
|
4427
|
-
]),
|
|
4428
|
-
),
|
|
4429
|
-
});
|
|
4430
|
-
|
|
4431
|
-
export function runAgentA2AMessageToJSON(
|
|
4432
|
-
runAgentA2AMessage: RunAgentA2AMessage,
|
|
4433
|
-
): string {
|
|
4434
|
-
return JSON.stringify(
|
|
4435
|
-
RunAgentA2AMessage$outboundSchema.parse(runAgentA2AMessage),
|
|
4436
|
-
);
|
|
4437
|
-
}
|
|
4438
|
-
export function runAgentA2AMessageFromJSON(
|
|
4439
|
-
jsonString: string,
|
|
4440
|
-
): SafeParseResult<RunAgentA2AMessage, SDKValidationError> {
|
|
4441
|
-
return safeParse(
|
|
4442
|
-
jsonString,
|
|
4443
|
-
(x) => RunAgentA2AMessage$inboundSchema.parse(JSON.parse(x)),
|
|
4444
|
-
`Failed to parse 'RunAgentA2AMessage' from JSON`,
|
|
4445
|
-
);
|
|
4446
|
-
}
|
|
4447
|
-
|
|
4448
|
-
/** @internal */
|
|
4449
|
-
export const RunAgentContact$inboundSchema: z.ZodType<
|
|
4450
|
-
RunAgentContact,
|
|
4451
|
-
z.ZodTypeDef,
|
|
4452
|
-
unknown
|
|
4453
|
-
> = z.object({
|
|
4454
|
-
id: z.string(),
|
|
4455
|
-
display_name: z.string().optional(),
|
|
4456
|
-
email: z.string().optional(),
|
|
4457
|
-
metadata: z.array(z.record(z.any())).optional(),
|
|
4458
|
-
logo_url: z.string().optional(),
|
|
4459
|
-
tags: z.array(z.string()).optional(),
|
|
4460
|
-
}).transform((v) => {
|
|
4461
|
-
return remap$(v, {
|
|
4462
|
-
"display_name": "displayName",
|
|
4463
|
-
"logo_url": "logoUrl",
|
|
4464
|
-
});
|
|
4465
|
-
});
|
|
4466
|
-
/** @internal */
|
|
4467
|
-
export type RunAgentContact$Outbound = {
|
|
4468
|
-
id: string;
|
|
4469
|
-
display_name?: string | undefined;
|
|
4470
|
-
email?: string | undefined;
|
|
4471
|
-
metadata?: Array<{ [k: string]: any }> | undefined;
|
|
4472
|
-
logo_url?: string | undefined;
|
|
4473
|
-
tags?: Array<string> | undefined;
|
|
4474
|
-
};
|
|
4475
|
-
|
|
4476
|
-
/** @internal */
|
|
4477
|
-
export const RunAgentContact$outboundSchema: z.ZodType<
|
|
4478
|
-
RunAgentContact$Outbound,
|
|
4479
|
-
z.ZodTypeDef,
|
|
4480
|
-
RunAgentContact
|
|
4481
|
-
> = z.object({
|
|
4482
|
-
id: z.string(),
|
|
4483
|
-
displayName: z.string().optional(),
|
|
4484
|
-
email: z.string().optional(),
|
|
4485
|
-
metadata: z.array(z.record(z.any())).optional(),
|
|
4486
|
-
logoUrl: z.string().optional(),
|
|
4487
|
-
tags: z.array(z.string()).optional(),
|
|
4488
|
-
}).transform((v) => {
|
|
4489
|
-
return remap$(v, {
|
|
4490
|
-
displayName: "display_name",
|
|
4491
|
-
logoUrl: "logo_url",
|
|
4492
|
-
});
|
|
4493
|
-
});
|
|
4494
|
-
|
|
4495
|
-
export function runAgentContactToJSON(
|
|
4496
|
-
runAgentContact: RunAgentContact,
|
|
4497
|
-
): string {
|
|
4498
|
-
return JSON.stringify(RunAgentContact$outboundSchema.parse(runAgentContact));
|
|
4499
|
-
}
|
|
4500
|
-
export function runAgentContactFromJSON(
|
|
4501
|
-
jsonString: string,
|
|
4502
|
-
): SafeParseResult<RunAgentContact, SDKValidationError> {
|
|
4503
|
-
return safeParse(
|
|
4504
|
-
jsonString,
|
|
4505
|
-
(x) => RunAgentContact$inboundSchema.parse(JSON.parse(x)),
|
|
4506
|
-
`Failed to parse 'RunAgentContact' from JSON`,
|
|
4507
|
-
);
|
|
4508
|
-
}
|
|
4509
|
-
|
|
4510
|
-
/** @internal */
|
|
4511
|
-
export const RunAgentThread$inboundSchema: z.ZodType<
|
|
4512
|
-
RunAgentThread,
|
|
4513
|
-
z.ZodTypeDef,
|
|
4514
|
-
unknown
|
|
4515
|
-
> = z.object({
|
|
4516
|
-
id: z.string(),
|
|
4517
|
-
tags: z.array(z.string()).optional(),
|
|
4518
|
-
});
|
|
4519
|
-
/** @internal */
|
|
4520
|
-
export type RunAgentThread$Outbound = {
|
|
4521
|
-
id: string;
|
|
4522
|
-
tags?: Array<string> | undefined;
|
|
4523
|
-
};
|
|
4524
|
-
|
|
4525
|
-
/** @internal */
|
|
4526
|
-
export const RunAgentThread$outboundSchema: z.ZodType<
|
|
4527
|
-
RunAgentThread$Outbound,
|
|
3991
|
+
export const RunAgentThread$outboundSchema: z.ZodType<
|
|
3992
|
+
RunAgentThread$Outbound,
|
|
4528
3993
|
z.ZodTypeDef,
|
|
4529
3994
|
RunAgentThread
|
|
4530
3995
|
> = z.object({
|
|
@@ -4790,7 +4255,7 @@ export function schemaFromJSON(
|
|
|
4790
4255
|
/** @internal */
|
|
4791
4256
|
export const Tools$inboundSchema: z.ZodType<Tools, z.ZodTypeDef, unknown> = z
|
|
4792
4257
|
.object({
|
|
4793
|
-
id: z.string().default("
|
|
4258
|
+
id: z.string().default("01KAXXWAVCJE3AZ7BYS51PDTJY"),
|
|
4794
4259
|
name: z.string(),
|
|
4795
4260
|
description: z.string().optional(),
|
|
4796
4261
|
schema: z.lazy(() => Schema$inboundSchema),
|
|
@@ -4809,7 +4274,7 @@ export const Tools$outboundSchema: z.ZodType<
|
|
|
4809
4274
|
z.ZodTypeDef,
|
|
4810
4275
|
Tools
|
|
4811
4276
|
> = z.object({
|
|
4812
|
-
id: z.string().default("
|
|
4277
|
+
id: z.string().default("01KAXXWAVCJE3AZ7BYS51PDTJY"),
|
|
4813
4278
|
name: z.string(),
|
|
4814
4279
|
description: z.string().optional(),
|
|
4815
4280
|
schema: z.lazy(() => Schema$outboundSchema),
|
|
@@ -6965,460 +6430,39 @@ export const RunAgentExtendedMessageRole$outboundSchema: z.ZodNativeEnum<
|
|
|
6965
6430
|
typeof RunAgentExtendedMessageRole
|
|
6966
6431
|
> = RunAgentExtendedMessageRole$inboundSchema;
|
|
6967
6432
|
|
|
6968
|
-
/** @internal */
|
|
6969
|
-
export const RunAgentPartsAgentsResponse200ApplicationJSONKind$inboundSchema:
|
|
6970
|
-
z.ZodNativeEnum<typeof RunAgentPartsAgentsResponse200ApplicationJSONKind> = z
|
|
6971
|
-
.nativeEnum(RunAgentPartsAgentsResponse200ApplicationJSONKind);
|
|
6972
|
-
/** @internal */
|
|
6973
|
-
export const RunAgentPartsAgentsResponse200ApplicationJSONKind$outboundSchema:
|
|
6974
|
-
z.ZodNativeEnum<typeof RunAgentPartsAgentsResponse200ApplicationJSONKind> =
|
|
6975
|
-
RunAgentPartsAgentsResponse200ApplicationJSONKind$inboundSchema;
|
|
6976
|
-
|
|
6977
|
-
/** @internal */
|
|
6978
|
-
export const RunAgentPartsToolResultPart$inboundSchema: z.ZodType<
|
|
6979
|
-
RunAgentPartsToolResultPart,
|
|
6980
|
-
z.ZodTypeDef,
|
|
6981
|
-
unknown
|
|
6982
|
-
> = z.object({
|
|
6983
|
-
kind: RunAgentPartsAgentsResponse200ApplicationJSONKind$inboundSchema,
|
|
6984
|
-
tool_call_id: z.string(),
|
|
6985
|
-
result: z.any().optional(),
|
|
6986
|
-
metadata: z.record(z.any()).optional(),
|
|
6987
|
-
}).transform((v) => {
|
|
6988
|
-
return remap$(v, {
|
|
6989
|
-
"tool_call_id": "toolCallId",
|
|
6990
|
-
});
|
|
6991
|
-
});
|
|
6992
|
-
/** @internal */
|
|
6993
|
-
export type RunAgentPartsToolResultPart$Outbound = {
|
|
6994
|
-
kind: string;
|
|
6995
|
-
tool_call_id: string;
|
|
6996
|
-
result?: any | undefined;
|
|
6997
|
-
metadata?: { [k: string]: any } | undefined;
|
|
6998
|
-
};
|
|
6999
|
-
|
|
7000
|
-
/** @internal */
|
|
7001
|
-
export const RunAgentPartsToolResultPart$outboundSchema: z.ZodType<
|
|
7002
|
-
RunAgentPartsToolResultPart$Outbound,
|
|
7003
|
-
z.ZodTypeDef,
|
|
7004
|
-
RunAgentPartsToolResultPart
|
|
7005
|
-
> = z.object({
|
|
7006
|
-
kind: RunAgentPartsAgentsResponse200ApplicationJSONKind$outboundSchema,
|
|
7007
|
-
toolCallId: z.string(),
|
|
7008
|
-
result: z.any().optional(),
|
|
7009
|
-
metadata: z.record(z.any()).optional(),
|
|
7010
|
-
}).transform((v) => {
|
|
7011
|
-
return remap$(v, {
|
|
7012
|
-
toolCallId: "tool_call_id",
|
|
7013
|
-
});
|
|
7014
|
-
});
|
|
7015
|
-
|
|
7016
|
-
export function runAgentPartsToolResultPartToJSON(
|
|
7017
|
-
runAgentPartsToolResultPart: RunAgentPartsToolResultPart,
|
|
7018
|
-
): string {
|
|
7019
|
-
return JSON.stringify(
|
|
7020
|
-
RunAgentPartsToolResultPart$outboundSchema.parse(
|
|
7021
|
-
runAgentPartsToolResultPart,
|
|
7022
|
-
),
|
|
7023
|
-
);
|
|
7024
|
-
}
|
|
7025
|
-
export function runAgentPartsToolResultPartFromJSON(
|
|
7026
|
-
jsonString: string,
|
|
7027
|
-
): SafeParseResult<RunAgentPartsToolResultPart, SDKValidationError> {
|
|
7028
|
-
return safeParse(
|
|
7029
|
-
jsonString,
|
|
7030
|
-
(x) => RunAgentPartsToolResultPart$inboundSchema.parse(JSON.parse(x)),
|
|
7031
|
-
`Failed to parse 'RunAgentPartsToolResultPart' from JSON`,
|
|
7032
|
-
);
|
|
7033
|
-
}
|
|
7034
|
-
|
|
7035
|
-
/** @internal */
|
|
7036
|
-
export const RunAgentPartsAgentsResponse200Kind$inboundSchema: z.ZodNativeEnum<
|
|
7037
|
-
typeof RunAgentPartsAgentsResponse200Kind
|
|
7038
|
-
> = z.nativeEnum(RunAgentPartsAgentsResponse200Kind);
|
|
7039
|
-
/** @internal */
|
|
7040
|
-
export const RunAgentPartsAgentsResponse200Kind$outboundSchema: z.ZodNativeEnum<
|
|
7041
|
-
typeof RunAgentPartsAgentsResponse200Kind
|
|
7042
|
-
> = RunAgentPartsAgentsResponse200Kind$inboundSchema;
|
|
7043
|
-
|
|
7044
|
-
/** @internal */
|
|
7045
|
-
export const PartsToolCallPart$inboundSchema: z.ZodType<
|
|
7046
|
-
PartsToolCallPart,
|
|
7047
|
-
z.ZodTypeDef,
|
|
7048
|
-
unknown
|
|
7049
|
-
> = z.object({
|
|
7050
|
-
kind: RunAgentPartsAgentsResponse200Kind$inboundSchema,
|
|
7051
|
-
tool_name: z.string(),
|
|
7052
|
-
tool_call_id: z.string(),
|
|
7053
|
-
arguments: z.record(z.any()),
|
|
7054
|
-
metadata: z.record(z.any()).optional(),
|
|
7055
|
-
}).transform((v) => {
|
|
7056
|
-
return remap$(v, {
|
|
7057
|
-
"tool_name": "toolName",
|
|
7058
|
-
"tool_call_id": "toolCallId",
|
|
7059
|
-
});
|
|
7060
|
-
});
|
|
7061
|
-
/** @internal */
|
|
7062
|
-
export type PartsToolCallPart$Outbound = {
|
|
7063
|
-
kind: string;
|
|
7064
|
-
tool_name: string;
|
|
7065
|
-
tool_call_id: string;
|
|
7066
|
-
arguments: { [k: string]: any };
|
|
7067
|
-
metadata?: { [k: string]: any } | undefined;
|
|
7068
|
-
};
|
|
7069
|
-
|
|
7070
|
-
/** @internal */
|
|
7071
|
-
export const PartsToolCallPart$outboundSchema: z.ZodType<
|
|
7072
|
-
PartsToolCallPart$Outbound,
|
|
7073
|
-
z.ZodTypeDef,
|
|
7074
|
-
PartsToolCallPart
|
|
7075
|
-
> = z.object({
|
|
7076
|
-
kind: RunAgentPartsAgentsResponse200Kind$outboundSchema,
|
|
7077
|
-
toolName: z.string(),
|
|
7078
|
-
toolCallId: z.string(),
|
|
7079
|
-
arguments: z.record(z.any()),
|
|
7080
|
-
metadata: z.record(z.any()).optional(),
|
|
7081
|
-
}).transform((v) => {
|
|
7082
|
-
return remap$(v, {
|
|
7083
|
-
toolName: "tool_name",
|
|
7084
|
-
toolCallId: "tool_call_id",
|
|
7085
|
-
});
|
|
7086
|
-
});
|
|
7087
|
-
|
|
7088
|
-
export function partsToolCallPartToJSON(
|
|
7089
|
-
partsToolCallPart: PartsToolCallPart,
|
|
7090
|
-
): string {
|
|
7091
|
-
return JSON.stringify(
|
|
7092
|
-
PartsToolCallPart$outboundSchema.parse(partsToolCallPart),
|
|
7093
|
-
);
|
|
7094
|
-
}
|
|
7095
|
-
export function partsToolCallPartFromJSON(
|
|
7096
|
-
jsonString: string,
|
|
7097
|
-
): SafeParseResult<PartsToolCallPart, SDKValidationError> {
|
|
7098
|
-
return safeParse(
|
|
7099
|
-
jsonString,
|
|
7100
|
-
(x) => PartsToolCallPart$inboundSchema.parse(JSON.parse(x)),
|
|
7101
|
-
`Failed to parse 'PartsToolCallPart' from JSON`,
|
|
7102
|
-
);
|
|
7103
|
-
}
|
|
7104
|
-
|
|
7105
|
-
/** @internal */
|
|
7106
|
-
export const RunAgentPartsAgentsResponseKind$inboundSchema: z.ZodNativeEnum<
|
|
7107
|
-
typeof RunAgentPartsAgentsResponseKind
|
|
7108
|
-
> = z.nativeEnum(RunAgentPartsAgentsResponseKind);
|
|
7109
|
-
/** @internal */
|
|
7110
|
-
export const RunAgentPartsAgentsResponseKind$outboundSchema: z.ZodNativeEnum<
|
|
7111
|
-
typeof RunAgentPartsAgentsResponseKind
|
|
7112
|
-
> = RunAgentPartsAgentsResponseKind$inboundSchema;
|
|
7113
|
-
|
|
7114
|
-
/** @internal */
|
|
7115
|
-
export const RunAgentFileAgentsFileInURIFormat$inboundSchema: z.ZodType<
|
|
7116
|
-
RunAgentFileAgentsFileInURIFormat,
|
|
7117
|
-
z.ZodTypeDef,
|
|
7118
|
-
unknown
|
|
7119
|
-
> = z.object({
|
|
7120
|
-
uri: z.string(),
|
|
7121
|
-
mimeType: z.string().optional(),
|
|
7122
|
-
name: z.string().optional(),
|
|
7123
|
-
});
|
|
7124
|
-
/** @internal */
|
|
7125
|
-
export type RunAgentFileAgentsFileInURIFormat$Outbound = {
|
|
7126
|
-
uri: string;
|
|
7127
|
-
mimeType?: string | undefined;
|
|
7128
|
-
name?: string | undefined;
|
|
7129
|
-
};
|
|
7130
|
-
|
|
7131
|
-
/** @internal */
|
|
7132
|
-
export const RunAgentFileAgentsFileInURIFormat$outboundSchema: z.ZodType<
|
|
7133
|
-
RunAgentFileAgentsFileInURIFormat$Outbound,
|
|
7134
|
-
z.ZodTypeDef,
|
|
7135
|
-
RunAgentFileAgentsFileInURIFormat
|
|
7136
|
-
> = z.object({
|
|
7137
|
-
uri: z.string(),
|
|
7138
|
-
mimeType: z.string().optional(),
|
|
7139
|
-
name: z.string().optional(),
|
|
7140
|
-
});
|
|
7141
|
-
|
|
7142
|
-
export function runAgentFileAgentsFileInURIFormatToJSON(
|
|
7143
|
-
runAgentFileAgentsFileInURIFormat: RunAgentFileAgentsFileInURIFormat,
|
|
7144
|
-
): string {
|
|
7145
|
-
return JSON.stringify(
|
|
7146
|
-
RunAgentFileAgentsFileInURIFormat$outboundSchema.parse(
|
|
7147
|
-
runAgentFileAgentsFileInURIFormat,
|
|
7148
|
-
),
|
|
7149
|
-
);
|
|
7150
|
-
}
|
|
7151
|
-
export function runAgentFileAgentsFileInURIFormatFromJSON(
|
|
7152
|
-
jsonString: string,
|
|
7153
|
-
): SafeParseResult<RunAgentFileAgentsFileInURIFormat, SDKValidationError> {
|
|
7154
|
-
return safeParse(
|
|
7155
|
-
jsonString,
|
|
7156
|
-
(x) => RunAgentFileAgentsFileInURIFormat$inboundSchema.parse(JSON.parse(x)),
|
|
7157
|
-
`Failed to parse 'RunAgentFileAgentsFileInURIFormat' from JSON`,
|
|
7158
|
-
);
|
|
7159
|
-
}
|
|
7160
|
-
|
|
7161
|
-
/** @internal */
|
|
7162
|
-
export const RunAgentFileAgentsBinaryFormat$inboundSchema: z.ZodType<
|
|
7163
|
-
RunAgentFileAgentsBinaryFormat,
|
|
7164
|
-
z.ZodTypeDef,
|
|
7165
|
-
unknown
|
|
7166
|
-
> = z.object({
|
|
7167
|
-
bytes: z.string(),
|
|
7168
|
-
mimeType: z.string().optional(),
|
|
7169
|
-
name: z.string().optional(),
|
|
7170
|
-
});
|
|
7171
|
-
/** @internal */
|
|
7172
|
-
export type RunAgentFileAgentsBinaryFormat$Outbound = {
|
|
7173
|
-
bytes: string;
|
|
7174
|
-
mimeType?: string | undefined;
|
|
7175
|
-
name?: string | undefined;
|
|
7176
|
-
};
|
|
7177
|
-
|
|
7178
|
-
/** @internal */
|
|
7179
|
-
export const RunAgentFileAgentsBinaryFormat$outboundSchema: z.ZodType<
|
|
7180
|
-
RunAgentFileAgentsBinaryFormat$Outbound,
|
|
7181
|
-
z.ZodTypeDef,
|
|
7182
|
-
RunAgentFileAgentsBinaryFormat
|
|
7183
|
-
> = z.object({
|
|
7184
|
-
bytes: z.string(),
|
|
7185
|
-
mimeType: z.string().optional(),
|
|
7186
|
-
name: z.string().optional(),
|
|
7187
|
-
});
|
|
7188
|
-
|
|
7189
|
-
export function runAgentFileAgentsBinaryFormatToJSON(
|
|
7190
|
-
runAgentFileAgentsBinaryFormat: RunAgentFileAgentsBinaryFormat,
|
|
7191
|
-
): string {
|
|
7192
|
-
return JSON.stringify(
|
|
7193
|
-
RunAgentFileAgentsBinaryFormat$outboundSchema.parse(
|
|
7194
|
-
runAgentFileAgentsBinaryFormat,
|
|
7195
|
-
),
|
|
7196
|
-
);
|
|
7197
|
-
}
|
|
7198
|
-
export function runAgentFileAgentsBinaryFormatFromJSON(
|
|
7199
|
-
jsonString: string,
|
|
7200
|
-
): SafeParseResult<RunAgentFileAgentsBinaryFormat, SDKValidationError> {
|
|
7201
|
-
return safeParse(
|
|
7202
|
-
jsonString,
|
|
7203
|
-
(x) => RunAgentFileAgentsBinaryFormat$inboundSchema.parse(JSON.parse(x)),
|
|
7204
|
-
`Failed to parse 'RunAgentFileAgentsBinaryFormat' from JSON`,
|
|
7205
|
-
);
|
|
7206
|
-
}
|
|
7207
|
-
|
|
7208
|
-
/** @internal */
|
|
7209
|
-
export const RunAgentPartsFile$inboundSchema: z.ZodType<
|
|
7210
|
-
RunAgentPartsFile,
|
|
7211
|
-
z.ZodTypeDef,
|
|
7212
|
-
unknown
|
|
7213
|
-
> = z.union([
|
|
7214
|
-
z.lazy(() => RunAgentFileAgentsBinaryFormat$inboundSchema),
|
|
7215
|
-
z.lazy(() => RunAgentFileAgentsFileInURIFormat$inboundSchema),
|
|
7216
|
-
]);
|
|
7217
|
-
/** @internal */
|
|
7218
|
-
export type RunAgentPartsFile$Outbound =
|
|
7219
|
-
| RunAgentFileAgentsBinaryFormat$Outbound
|
|
7220
|
-
| RunAgentFileAgentsFileInURIFormat$Outbound;
|
|
7221
|
-
|
|
7222
|
-
/** @internal */
|
|
7223
|
-
export const RunAgentPartsFile$outboundSchema: z.ZodType<
|
|
7224
|
-
RunAgentPartsFile$Outbound,
|
|
7225
|
-
z.ZodTypeDef,
|
|
7226
|
-
RunAgentPartsFile
|
|
7227
|
-
> = z.union([
|
|
7228
|
-
z.lazy(() => RunAgentFileAgentsBinaryFormat$outboundSchema),
|
|
7229
|
-
z.lazy(() => RunAgentFileAgentsFileInURIFormat$outboundSchema),
|
|
7230
|
-
]);
|
|
7231
|
-
|
|
7232
|
-
export function runAgentPartsFileToJSON(
|
|
7233
|
-
runAgentPartsFile: RunAgentPartsFile,
|
|
7234
|
-
): string {
|
|
7235
|
-
return JSON.stringify(
|
|
7236
|
-
RunAgentPartsFile$outboundSchema.parse(runAgentPartsFile),
|
|
7237
|
-
);
|
|
7238
|
-
}
|
|
7239
|
-
export function runAgentPartsFileFromJSON(
|
|
7240
|
-
jsonString: string,
|
|
7241
|
-
): SafeParseResult<RunAgentPartsFile, SDKValidationError> {
|
|
7242
|
-
return safeParse(
|
|
7243
|
-
jsonString,
|
|
7244
|
-
(x) => RunAgentPartsFile$inboundSchema.parse(JSON.parse(x)),
|
|
7245
|
-
`Failed to parse 'RunAgentPartsFile' from JSON`,
|
|
7246
|
-
);
|
|
7247
|
-
}
|
|
7248
|
-
|
|
7249
|
-
/** @internal */
|
|
7250
|
-
export const RunAgentPartsFilePart$inboundSchema: z.ZodType<
|
|
7251
|
-
RunAgentPartsFilePart,
|
|
7252
|
-
z.ZodTypeDef,
|
|
7253
|
-
unknown
|
|
7254
|
-
> = z.object({
|
|
7255
|
-
kind: RunAgentPartsAgentsResponseKind$inboundSchema,
|
|
7256
|
-
file: z.union([
|
|
7257
|
-
z.lazy(() => RunAgentFileAgentsBinaryFormat$inboundSchema),
|
|
7258
|
-
z.lazy(() => RunAgentFileAgentsFileInURIFormat$inboundSchema),
|
|
7259
|
-
]),
|
|
7260
|
-
metadata: z.record(z.any()).optional(),
|
|
7261
|
-
});
|
|
7262
|
-
/** @internal */
|
|
7263
|
-
export type RunAgentPartsFilePart$Outbound = {
|
|
7264
|
-
kind: string;
|
|
7265
|
-
file:
|
|
7266
|
-
| RunAgentFileAgentsBinaryFormat$Outbound
|
|
7267
|
-
| RunAgentFileAgentsFileInURIFormat$Outbound;
|
|
7268
|
-
metadata?: { [k: string]: any } | undefined;
|
|
7269
|
-
};
|
|
7270
|
-
|
|
7271
|
-
/** @internal */
|
|
7272
|
-
export const RunAgentPartsFilePart$outboundSchema: z.ZodType<
|
|
7273
|
-
RunAgentPartsFilePart$Outbound,
|
|
7274
|
-
z.ZodTypeDef,
|
|
7275
|
-
RunAgentPartsFilePart
|
|
7276
|
-
> = z.object({
|
|
7277
|
-
kind: RunAgentPartsAgentsResponseKind$outboundSchema,
|
|
7278
|
-
file: z.union([
|
|
7279
|
-
z.lazy(() => RunAgentFileAgentsBinaryFormat$outboundSchema),
|
|
7280
|
-
z.lazy(() => RunAgentFileAgentsFileInURIFormat$outboundSchema),
|
|
7281
|
-
]),
|
|
7282
|
-
metadata: z.record(z.any()).optional(),
|
|
7283
|
-
});
|
|
7284
|
-
|
|
7285
|
-
export function runAgentPartsFilePartToJSON(
|
|
7286
|
-
runAgentPartsFilePart: RunAgentPartsFilePart,
|
|
7287
|
-
): string {
|
|
7288
|
-
return JSON.stringify(
|
|
7289
|
-
RunAgentPartsFilePart$outboundSchema.parse(runAgentPartsFilePart),
|
|
7290
|
-
);
|
|
7291
|
-
}
|
|
7292
|
-
export function runAgentPartsFilePartFromJSON(
|
|
7293
|
-
jsonString: string,
|
|
7294
|
-
): SafeParseResult<RunAgentPartsFilePart, SDKValidationError> {
|
|
7295
|
-
return safeParse(
|
|
7296
|
-
jsonString,
|
|
7297
|
-
(x) => RunAgentPartsFilePart$inboundSchema.parse(JSON.parse(x)),
|
|
7298
|
-
`Failed to parse 'RunAgentPartsFilePart' from JSON`,
|
|
7299
|
-
);
|
|
7300
|
-
}
|
|
7301
|
-
|
|
7302
|
-
/** @internal */
|
|
7303
|
-
export const RunAgentPartsAgentsKind$inboundSchema: z.ZodNativeEnum<
|
|
7304
|
-
typeof RunAgentPartsAgentsKind
|
|
7305
|
-
> = z.nativeEnum(RunAgentPartsAgentsKind);
|
|
7306
|
-
/** @internal */
|
|
7307
|
-
export const RunAgentPartsAgentsKind$outboundSchema: z.ZodNativeEnum<
|
|
7308
|
-
typeof RunAgentPartsAgentsKind
|
|
7309
|
-
> = RunAgentPartsAgentsKind$inboundSchema;
|
|
7310
|
-
|
|
7311
|
-
/** @internal */
|
|
7312
|
-
export const PartsDataPart$inboundSchema: z.ZodType<
|
|
7313
|
-
PartsDataPart,
|
|
7314
|
-
z.ZodTypeDef,
|
|
7315
|
-
unknown
|
|
7316
|
-
> = z.object({
|
|
7317
|
-
kind: RunAgentPartsAgentsKind$inboundSchema,
|
|
7318
|
-
data: z.record(z.any()),
|
|
7319
|
-
metadata: z.record(z.any()).optional(),
|
|
7320
|
-
});
|
|
7321
|
-
/** @internal */
|
|
7322
|
-
export type PartsDataPart$Outbound = {
|
|
7323
|
-
kind: string;
|
|
7324
|
-
data: { [k: string]: any };
|
|
7325
|
-
metadata?: { [k: string]: any } | undefined;
|
|
7326
|
-
};
|
|
7327
|
-
|
|
7328
|
-
/** @internal */
|
|
7329
|
-
export const PartsDataPart$outboundSchema: z.ZodType<
|
|
7330
|
-
PartsDataPart$Outbound,
|
|
7331
|
-
z.ZodTypeDef,
|
|
7332
|
-
PartsDataPart
|
|
7333
|
-
> = z.object({
|
|
7334
|
-
kind: RunAgentPartsAgentsKind$outboundSchema,
|
|
7335
|
-
data: z.record(z.any()),
|
|
7336
|
-
metadata: z.record(z.any()).optional(),
|
|
7337
|
-
});
|
|
7338
|
-
|
|
7339
|
-
export function partsDataPartToJSON(partsDataPart: PartsDataPart): string {
|
|
7340
|
-
return JSON.stringify(PartsDataPart$outboundSchema.parse(partsDataPart));
|
|
7341
|
-
}
|
|
7342
|
-
export function partsDataPartFromJSON(
|
|
7343
|
-
jsonString: string,
|
|
7344
|
-
): SafeParseResult<PartsDataPart, SDKValidationError> {
|
|
7345
|
-
return safeParse(
|
|
7346
|
-
jsonString,
|
|
7347
|
-
(x) => PartsDataPart$inboundSchema.parse(JSON.parse(x)),
|
|
7348
|
-
`Failed to parse 'PartsDataPart' from JSON`,
|
|
7349
|
-
);
|
|
7350
|
-
}
|
|
7351
|
-
|
|
7352
|
-
/** @internal */
|
|
7353
|
-
export const RunAgentPartsKind$inboundSchema: z.ZodNativeEnum<
|
|
7354
|
-
typeof RunAgentPartsKind
|
|
7355
|
-
> = z.nativeEnum(RunAgentPartsKind);
|
|
7356
|
-
/** @internal */
|
|
7357
|
-
export const RunAgentPartsKind$outboundSchema: z.ZodNativeEnum<
|
|
7358
|
-
typeof RunAgentPartsKind
|
|
7359
|
-
> = RunAgentPartsKind$inboundSchema;
|
|
7360
|
-
|
|
7361
|
-
/** @internal */
|
|
7362
|
-
export const RunAgentPartsTextPart$inboundSchema: z.ZodType<
|
|
7363
|
-
RunAgentPartsTextPart,
|
|
7364
|
-
z.ZodTypeDef,
|
|
7365
|
-
unknown
|
|
7366
|
-
> = z.object({
|
|
7367
|
-
kind: RunAgentPartsKind$inboundSchema,
|
|
7368
|
-
text: z.string(),
|
|
7369
|
-
});
|
|
7370
|
-
/** @internal */
|
|
7371
|
-
export type RunAgentPartsTextPart$Outbound = {
|
|
7372
|
-
kind: string;
|
|
7373
|
-
text: string;
|
|
7374
|
-
};
|
|
7375
|
-
|
|
7376
|
-
/** @internal */
|
|
7377
|
-
export const RunAgentPartsTextPart$outboundSchema: z.ZodType<
|
|
7378
|
-
RunAgentPartsTextPart$Outbound,
|
|
7379
|
-
z.ZodTypeDef,
|
|
7380
|
-
RunAgentPartsTextPart
|
|
7381
|
-
> = z.object({
|
|
7382
|
-
kind: RunAgentPartsKind$outboundSchema,
|
|
7383
|
-
text: z.string(),
|
|
7384
|
-
});
|
|
7385
|
-
|
|
7386
|
-
export function runAgentPartsTextPartToJSON(
|
|
7387
|
-
runAgentPartsTextPart: RunAgentPartsTextPart,
|
|
7388
|
-
): string {
|
|
7389
|
-
return JSON.stringify(
|
|
7390
|
-
RunAgentPartsTextPart$outboundSchema.parse(runAgentPartsTextPart),
|
|
7391
|
-
);
|
|
7392
|
-
}
|
|
7393
|
-
export function runAgentPartsTextPartFromJSON(
|
|
7394
|
-
jsonString: string,
|
|
7395
|
-
): SafeParseResult<RunAgentPartsTextPart, SDKValidationError> {
|
|
7396
|
-
return safeParse(
|
|
7397
|
-
jsonString,
|
|
7398
|
-
(x) => RunAgentPartsTextPart$inboundSchema.parse(JSON.parse(x)),
|
|
7399
|
-
`Failed to parse 'RunAgentPartsTextPart' from JSON`,
|
|
7400
|
-
);
|
|
7401
|
-
}
|
|
7402
|
-
|
|
7403
6433
|
/** @internal */
|
|
7404
6434
|
export const RunAgentParts$inboundSchema: z.ZodType<
|
|
7405
6435
|
RunAgentParts,
|
|
7406
6436
|
z.ZodTypeDef,
|
|
7407
6437
|
unknown
|
|
7408
6438
|
> = z.union([
|
|
7409
|
-
|
|
7410
|
-
|
|
7411
|
-
|
|
7412
|
-
|
|
7413
|
-
|
|
6439
|
+
components.ToolCallPart$inboundSchema.and(
|
|
6440
|
+
z.object({ kind: z.literal("tool_call") }).transform((v) => ({
|
|
6441
|
+
kind: v.kind,
|
|
6442
|
+
})),
|
|
6443
|
+
),
|
|
6444
|
+
components.TextPart$inboundSchema.and(
|
|
6445
|
+
z.object({ kind: z.literal("text") }).transform((v) => ({ kind: v.kind })),
|
|
6446
|
+
),
|
|
6447
|
+
components.DataPart$inboundSchema.and(
|
|
6448
|
+
z.object({ kind: z.literal("data") }).transform((v) => ({ kind: v.kind })),
|
|
6449
|
+
),
|
|
6450
|
+
components.FilePart$inboundSchema.and(
|
|
6451
|
+
z.object({ kind: z.literal("file") }).transform((v) => ({ kind: v.kind })),
|
|
6452
|
+
),
|
|
6453
|
+
components.ToolResultPart$inboundSchema.and(
|
|
6454
|
+
z.object({ kind: z.literal("tool_result") }).transform((v) => ({
|
|
6455
|
+
kind: v.kind,
|
|
6456
|
+
})),
|
|
6457
|
+
),
|
|
7414
6458
|
]);
|
|
7415
6459
|
/** @internal */
|
|
7416
6460
|
export type RunAgentParts$Outbound =
|
|
7417
|
-
|
|
|
7418
|
-
|
|
|
7419
|
-
|
|
|
7420
|
-
|
|
|
7421
|
-
|
|
|
6461
|
+
| (components.ToolCallPart$Outbound & { kind: "tool_call" })
|
|
6462
|
+
| (components.TextPart$Outbound & { kind: "text" })
|
|
6463
|
+
| (components.DataPart$Outbound & { kind: "data" })
|
|
6464
|
+
| (components.FilePart$Outbound & { kind: "file" })
|
|
6465
|
+
| (components.ToolResultPart$Outbound & { kind: "tool_result" });
|
|
7422
6466
|
|
|
7423
6467
|
/** @internal */
|
|
7424
6468
|
export const RunAgentParts$outboundSchema: z.ZodType<
|
|
@@ -7426,11 +6470,25 @@ export const RunAgentParts$outboundSchema: z.ZodType<
|
|
|
7426
6470
|
z.ZodTypeDef,
|
|
7427
6471
|
RunAgentParts
|
|
7428
6472
|
> = z.union([
|
|
7429
|
-
|
|
7430
|
-
|
|
7431
|
-
|
|
7432
|
-
|
|
7433
|
-
|
|
6473
|
+
components.ToolCallPart$outboundSchema.and(
|
|
6474
|
+
z.object({ kind: z.literal("tool_call") }).transform((v) => ({
|
|
6475
|
+
kind: v.kind,
|
|
6476
|
+
})),
|
|
6477
|
+
),
|
|
6478
|
+
components.TextPart$outboundSchema.and(
|
|
6479
|
+
z.object({ kind: z.literal("text") }).transform((v) => ({ kind: v.kind })),
|
|
6480
|
+
),
|
|
6481
|
+
components.DataPart$outboundSchema.and(
|
|
6482
|
+
z.object({ kind: z.literal("data") }).transform((v) => ({ kind: v.kind })),
|
|
6483
|
+
),
|
|
6484
|
+
components.FilePart$outboundSchema.and(
|
|
6485
|
+
z.object({ kind: z.literal("file") }).transform((v) => ({ kind: v.kind })),
|
|
6486
|
+
),
|
|
6487
|
+
components.ToolResultPart$outboundSchema.and(
|
|
6488
|
+
z.object({ kind: z.literal("tool_result") }).transform((v) => ({
|
|
6489
|
+
kind: v.kind,
|
|
6490
|
+
})),
|
|
6491
|
+
),
|
|
7434
6492
|
]);
|
|
7435
6493
|
|
|
7436
6494
|
export function runAgentPartsToJSON(runAgentParts: RunAgentParts): string {
|
|
@@ -7457,11 +6515,31 @@ export const RunAgentTaskStatusMessage$inboundSchema: z.ZodType<
|
|
|
7457
6515
|
role: RunAgentExtendedMessageRole$inboundSchema,
|
|
7458
6516
|
parts: z.array(
|
|
7459
6517
|
z.union([
|
|
7460
|
-
|
|
7461
|
-
|
|
7462
|
-
|
|
7463
|
-
|
|
7464
|
-
|
|
6518
|
+
components.ToolCallPart$inboundSchema.and(
|
|
6519
|
+
z.object({ kind: z.literal("tool_call") }).transform((v) => ({
|
|
6520
|
+
kind: v.kind,
|
|
6521
|
+
})),
|
|
6522
|
+
),
|
|
6523
|
+
components.TextPart$inboundSchema.and(
|
|
6524
|
+
z.object({ kind: z.literal("text") }).transform((v) => ({
|
|
6525
|
+
kind: v.kind,
|
|
6526
|
+
})),
|
|
6527
|
+
),
|
|
6528
|
+
components.DataPart$inboundSchema.and(
|
|
6529
|
+
z.object({ kind: z.literal("data") }).transform((v) => ({
|
|
6530
|
+
kind: v.kind,
|
|
6531
|
+
})),
|
|
6532
|
+
),
|
|
6533
|
+
components.FilePart$inboundSchema.and(
|
|
6534
|
+
z.object({ kind: z.literal("file") }).transform((v) => ({
|
|
6535
|
+
kind: v.kind,
|
|
6536
|
+
})),
|
|
6537
|
+
),
|
|
6538
|
+
components.ToolResultPart$inboundSchema.and(
|
|
6539
|
+
z.object({ kind: z.literal("tool_result") }).transform((v) => ({
|
|
6540
|
+
kind: v.kind,
|
|
6541
|
+
})),
|
|
6542
|
+
),
|
|
7465
6543
|
]),
|
|
7466
6544
|
),
|
|
7467
6545
|
});
|
|
@@ -7471,11 +6549,11 @@ export type RunAgentTaskStatusMessage$Outbound = {
|
|
|
7471
6549
|
messageId: string;
|
|
7472
6550
|
role: string;
|
|
7473
6551
|
parts: Array<
|
|
7474
|
-
|
|
|
7475
|
-
|
|
|
7476
|
-
|
|
|
7477
|
-
|
|
|
7478
|
-
|
|
|
6552
|
+
| (components.ToolCallPart$Outbound & { kind: "tool_call" })
|
|
6553
|
+
| (components.TextPart$Outbound & { kind: "text" })
|
|
6554
|
+
| (components.DataPart$Outbound & { kind: "data" })
|
|
6555
|
+
| (components.FilePart$Outbound & { kind: "file" })
|
|
6556
|
+
| (components.ToolResultPart$Outbound & { kind: "tool_result" })
|
|
7479
6557
|
>;
|
|
7480
6558
|
};
|
|
7481
6559
|
|
|
@@ -7490,11 +6568,31 @@ export const RunAgentTaskStatusMessage$outboundSchema: z.ZodType<
|
|
|
7490
6568
|
role: RunAgentExtendedMessageRole$outboundSchema,
|
|
7491
6569
|
parts: z.array(
|
|
7492
6570
|
z.union([
|
|
7493
|
-
|
|
7494
|
-
|
|
7495
|
-
|
|
7496
|
-
|
|
7497
|
-
|
|
6571
|
+
components.ToolCallPart$outboundSchema.and(
|
|
6572
|
+
z.object({ kind: z.literal("tool_call") }).transform((v) => ({
|
|
6573
|
+
kind: v.kind,
|
|
6574
|
+
})),
|
|
6575
|
+
),
|
|
6576
|
+
components.TextPart$outboundSchema.and(
|
|
6577
|
+
z.object({ kind: z.literal("text") }).transform((v) => ({
|
|
6578
|
+
kind: v.kind,
|
|
6579
|
+
})),
|
|
6580
|
+
),
|
|
6581
|
+
components.DataPart$outboundSchema.and(
|
|
6582
|
+
z.object({ kind: z.literal("data") }).transform((v) => ({
|
|
6583
|
+
kind: v.kind,
|
|
6584
|
+
})),
|
|
6585
|
+
),
|
|
6586
|
+
components.FilePart$outboundSchema.and(
|
|
6587
|
+
z.object({ kind: z.literal("file") }).transform((v) => ({
|
|
6588
|
+
kind: v.kind,
|
|
6589
|
+
})),
|
|
6590
|
+
),
|
|
6591
|
+
components.ToolResultPart$outboundSchema.and(
|
|
6592
|
+
z.object({ kind: z.literal("tool_result") }).transform((v) => ({
|
|
6593
|
+
kind: v.kind,
|
|
6594
|
+
})),
|
|
6595
|
+
),
|
|
7498
6596
|
]),
|
|
7499
6597
|
),
|
|
7500
6598
|
});
|