@orq-ai/node 4.0.5 → 4.1.0-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (484) hide show
  1. package/bin/mcp-server.js +214 -217
  2. package/bin/mcp-server.js.map +39 -39
  3. package/docs/sdks/agents/README.md +8 -4
  4. package/docs/sdks/budgets/README.md +4 -2
  5. package/docs/sdks/tools/README.md +2 -2
  6. package/examples/package-lock.json +4 -7
  7. package/jsr.json +1 -1
  8. package/lib/config.d.ts +2 -2
  9. package/lib/config.js +2 -2
  10. package/lib/config.js.map +1 -1
  11. package/mcp-server/mcp-server.js +1 -1
  12. package/mcp-server/mcp-server.js.map +1 -1
  13. package/mcp-server/server.js +1 -1
  14. package/mcp-server/server.js.map +1 -1
  15. package/models/operations/createbudget.js +2 -2
  16. package/models/operations/createcontact.js +2 -2
  17. package/models/operations/createdataset.js +2 -2
  18. package/models/operations/createdatasetitem.js +8 -8
  19. package/models/operations/createdatasource.js +2 -2
  20. package/models/operations/createeval.js +28 -28
  21. package/models/operations/createtool.js +12 -12
  22. package/models/operations/fileget.js +2 -2
  23. package/models/operations/filelist.js +2 -2
  24. package/models/operations/fileupload.js +2 -2
  25. package/models/operations/getalltools.js +12 -12
  26. package/models/operations/getbudget.js +2 -2
  27. package/models/operations/getevals.js +28 -28
  28. package/models/operations/listbudgets.js +2 -2
  29. package/models/operations/listcontacts.js +2 -2
  30. package/models/operations/listdatasetdatapoints.js +8 -8
  31. package/models/operations/listdatasets.js +2 -2
  32. package/models/operations/listdatasources.js +2 -2
  33. package/models/operations/retrievecontact.js +2 -2
  34. package/models/operations/retrievedatapoint.js +8 -8
  35. package/models/operations/retrievedataset.js +2 -2
  36. package/models/operations/retrievedatasource.js +2 -2
  37. package/models/operations/retrievetool.js +12 -12
  38. package/models/operations/runagent.js +2 -2
  39. package/models/operations/streamrunagent.js +2 -2
  40. package/models/operations/updatebudget.js +2 -2
  41. package/models/operations/updatecontact.js +2 -2
  42. package/models/operations/updatedatapoint.js +8 -8
  43. package/models/operations/updatedataset.js +2 -2
  44. package/models/operations/updatedatasource.js +2 -2
  45. package/models/operations/updateeval.js +28 -28
  46. package/models/operations/updatetool.js +14 -14
  47. package/package.json +4 -3
  48. package/src/lib/config.ts +2 -2
  49. package/src/mcp-server/mcp-server.ts +1 -1
  50. package/src/mcp-server/server.ts +1 -1
  51. package/src/models/operations/createbudget.ts +2 -2
  52. package/src/models/operations/createcontact.ts +2 -2
  53. package/src/models/operations/createdataset.ts +2 -2
  54. package/src/models/operations/createdatasetitem.ts +8 -8
  55. package/src/models/operations/createdatasource.ts +2 -2
  56. package/src/models/operations/createeval.ts +28 -28
  57. package/src/models/operations/createtool.ts +12 -12
  58. package/src/models/operations/fileget.ts +2 -2
  59. package/src/models/operations/filelist.ts +2 -2
  60. package/src/models/operations/fileupload.ts +2 -2
  61. package/src/models/operations/getalltools.ts +12 -12
  62. package/src/models/operations/getbudget.ts +2 -2
  63. package/src/models/operations/getevals.ts +28 -28
  64. package/src/models/operations/listbudgets.ts +2 -2
  65. package/src/models/operations/listcontacts.ts +2 -2
  66. package/src/models/operations/listdatasetdatapoints.ts +8 -8
  67. package/src/models/operations/listdatasets.ts +2 -2
  68. package/src/models/operations/listdatasources.ts +2 -2
  69. package/src/models/operations/retrievecontact.ts +2 -2
  70. package/src/models/operations/retrievedatapoint.ts +8 -8
  71. package/src/models/operations/retrievedataset.ts +2 -2
  72. package/src/models/operations/retrievedatasource.ts +2 -2
  73. package/src/models/operations/retrievetool.ts +12 -12
  74. package/src/models/operations/runagent.ts +2 -2
  75. package/src/models/operations/streamrunagent.ts +2 -2
  76. package/src/models/operations/updatebudget.ts +2 -2
  77. package/src/models/operations/updatecontact.ts +2 -2
  78. package/src/models/operations/updatedatapoint.ts +8 -8
  79. package/src/models/operations/updatedataset.ts +2 -2
  80. package/src/models/operations/updatedatasource.ts +2 -2
  81. package/src/models/operations/updateeval.ts +28 -28
  82. package/src/models/operations/updatetool.ts +14 -14
  83. package/packages/orq-rc/FUNCTIONS.md +0 -103
  84. package/packages/orq-rc/README.md +0 -901
  85. package/packages/orq-rc/RUNTIMES.md +0 -48
  86. package/packages/orq-rc/docs/sdks/agents/README.md +0 -1064
  87. package/packages/orq-rc/docs/sdks/budgets/README.md +0 -401
  88. package/packages/orq-rc/docs/sdks/chunking/README.md +0 -97
  89. package/packages/orq-rc/docs/sdks/contacts/README.md +0 -450
  90. package/packages/orq-rc/docs/sdks/datasets/README.md +0 -836
  91. package/packages/orq-rc/docs/sdks/deployments/README.md +0 -312
  92. package/packages/orq-rc/docs/sdks/evals/README.md +0 -339
  93. package/packages/orq-rc/docs/sdks/feedback/README.md +0 -89
  94. package/packages/orq-rc/docs/sdks/files/README.md +0 -301
  95. package/packages/orq-rc/docs/sdks/knowledge/README.md +0 -1487
  96. package/packages/orq-rc/docs/sdks/memorystores/README.md +0 -1171
  97. package/packages/orq-rc/docs/sdks/metrics/README.md +0 -83
  98. package/packages/orq-rc/docs/sdks/models/README.md +0 -76
  99. package/packages/orq-rc/docs/sdks/prompts/README.md +0 -591
  100. package/packages/orq-rc/docs/sdks/remoteconfigs/README.md +0 -77
  101. package/packages/orq-rc/docs/sdks/responses/README.md +0 -134
  102. package/packages/orq-rc/docs/sdks/tools/README.md +0 -420
  103. package/packages/orq-rc/examples/README.md +0 -31
  104. package/packages/orq-rc/examples/contactsCreate.example.ts +0 -42
  105. package/packages/orq-rc/examples/package-lock.json +0 -619
  106. package/packages/orq-rc/examples/package.json +0 -18
  107. package/packages/orq-rc/jsr.json +0 -28
  108. package/packages/orq-rc/package-lock.json +0 -3047
  109. package/packages/orq-rc/package.json +0 -40
  110. package/packages/orq-rc/src/core.ts +0 -13
  111. package/packages/orq-rc/src/funcs/agentsCreate.ts +0 -174
  112. package/packages/orq-rc/src/funcs/agentsDelete.ts +0 -180
  113. package/packages/orq-rc/src/funcs/agentsInvoke.ts +0 -177
  114. package/packages/orq-rc/src/funcs/agentsList.ts +0 -179
  115. package/packages/orq-rc/src/funcs/agentsResponsesCreate.ts +0 -179
  116. package/packages/orq-rc/src/funcs/agentsRetrieve.ts +0 -180
  117. package/packages/orq-rc/src/funcs/agentsRun.ts +0 -165
  118. package/packages/orq-rc/src/funcs/agentsStream.ts +0 -201
  119. package/packages/orq-rc/src/funcs/agentsStreamRun.ts +0 -191
  120. package/packages/orq-rc/src/funcs/agentsUpdate.ts +0 -184
  121. package/packages/orq-rc/src/funcs/budgetsCreate.ts +0 -160
  122. package/packages/orq-rc/src/funcs/budgetsDelete.ts +0 -167
  123. package/packages/orq-rc/src/funcs/budgetsGet.ts +0 -166
  124. package/packages/orq-rc/src/funcs/budgetsList.ts +0 -170
  125. package/packages/orq-rc/src/funcs/budgetsUpdate.ts +0 -167
  126. package/packages/orq-rc/src/funcs/chunkingParse.ts +0 -160
  127. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -165
  128. package/packages/orq-rc/src/funcs/contactsDelete.ts +0 -176
  129. package/packages/orq-rc/src/funcs/contactsList.ts +0 -169
  130. package/packages/orq-rc/src/funcs/contactsRetrieve.ts +0 -175
  131. package/packages/orq-rc/src/funcs/contactsUpdate.ts +0 -176
  132. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -167
  133. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -165
  134. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -171
  135. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -167
  136. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -182
  137. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -167
  138. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -174
  139. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -175
  140. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -181
  141. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -176
  142. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -179
  143. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -168
  144. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -176
  145. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -176
  146. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -168
  147. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -183
  148. package/packages/orq-rc/src/funcs/evalsAll.ts +0 -173
  149. package/packages/orq-rc/src/funcs/evalsCreate.ts +0 -169
  150. package/packages/orq-rc/src/funcs/evalsDelete.ts +0 -173
  151. package/packages/orq-rc/src/funcs/evalsUpdate.ts +0 -173
  152. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -160
  153. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -187
  154. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -164
  155. package/packages/orq-rc/src/funcs/filesGet.ts +0 -166
  156. package/packages/orq-rc/src/funcs/filesList.ts +0 -167
  157. package/packages/orq-rc/src/funcs/knowledgeCreate.ts +0 -158
  158. package/packages/orq-rc/src/funcs/knowledgeCreateChunks.ts +0 -171
  159. package/packages/orq-rc/src/funcs/knowledgeCreateDatasource.ts +0 -166
  160. package/packages/orq-rc/src/funcs/knowledgeDelete.ts +0 -167
  161. package/packages/orq-rc/src/funcs/knowledgeDeleteChunk.ts +0 -174
  162. package/packages/orq-rc/src/funcs/knowledgeDeleteChunks.ts +0 -170
  163. package/packages/orq-rc/src/funcs/knowledgeDeleteDatasource.ts +0 -173
  164. package/packages/orq-rc/src/funcs/knowledgeGetChunksCount.ts +0 -170
  165. package/packages/orq-rc/src/funcs/knowledgeList.ts +0 -169
  166. package/packages/orq-rc/src/funcs/knowledgeListChunks.ts +0 -178
  167. package/packages/orq-rc/src/funcs/knowledgeListChunksPaginated.ts +0 -171
  168. package/packages/orq-rc/src/funcs/knowledgeListDatasources.ts +0 -174
  169. package/packages/orq-rc/src/funcs/knowledgeRetrieve.ts +0 -166
  170. package/packages/orq-rc/src/funcs/knowledgeRetrieveChunk.ts +0 -173
  171. package/packages/orq-rc/src/funcs/knowledgeRetrieveDatasource.ts +0 -169
  172. package/packages/orq-rc/src/funcs/knowledgeSearch.ts +0 -167
  173. package/packages/orq-rc/src/funcs/knowledgeUpdate.ts +0 -164
  174. package/packages/orq-rc/src/funcs/knowledgeUpdateChunk.ts +0 -174
  175. package/packages/orq-rc/src/funcs/knowledgeUpdateDatasource.ts +0 -170
  176. package/packages/orq-rc/src/funcs/memoryStoresCreate.ts +0 -162
  177. package/packages/orq-rc/src/funcs/memoryStoresCreateDocument.ts +0 -175
  178. package/packages/orq-rc/src/funcs/memoryStoresCreateMemory.ts +0 -170
  179. package/packages/orq-rc/src/funcs/memoryStoresDelete.ts +0 -168
  180. package/packages/orq-rc/src/funcs/memoryStoresDeleteDocument.ts +0 -184
  181. package/packages/orq-rc/src/funcs/memoryStoresDeleteMemory.ts +0 -179
  182. package/packages/orq-rc/src/funcs/memoryStoresList.ts +0 -178
  183. package/packages/orq-rc/src/funcs/memoryStoresListDocuments.ts +0 -181
  184. package/packages/orq-rc/src/funcs/memoryStoresListMemories.ts +0 -176
  185. package/packages/orq-rc/src/funcs/memoryStoresRetrieve.ts +0 -177
  186. package/packages/orq-rc/src/funcs/memoryStoresRetrieveDocument.ts +0 -178
  187. package/packages/orq-rc/src/funcs/memoryStoresRetrieveMemory.ts +0 -173
  188. package/packages/orq-rc/src/funcs/memoryStoresUpdate.ts +0 -168
  189. package/packages/orq-rc/src/funcs/memoryStoresUpdateDocument.ts +0 -179
  190. package/packages/orq-rc/src/funcs/memoryStoresUpdateMemory.ts +0 -174
  191. package/packages/orq-rc/src/funcs/modelsList.ts +0 -142
  192. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -160
  193. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -164
  194. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -181
  195. package/packages/orq-rc/src/funcs/promptsList.ts +0 -167
  196. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -173
  197. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -166
  198. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -173
  199. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -161
  200. package/packages/orq-rc/src/funcs/toolsCreate.ts +0 -172
  201. package/packages/orq-rc/src/funcs/toolsDelete.ts +0 -167
  202. package/packages/orq-rc/src/funcs/toolsList.ts +0 -176
  203. package/packages/orq-rc/src/funcs/toolsRetrieve.ts +0 -166
  204. package/packages/orq-rc/src/funcs/toolsUpdate.ts +0 -176
  205. package/packages/orq-rc/src/hooks/global.ts +0 -44
  206. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  207. package/packages/orq-rc/src/hooks/index.ts +0 -6
  208. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  209. package/packages/orq-rc/src/hooks/types.ts +0 -112
  210. package/packages/orq-rc/src/index.ts +0 -9
  211. package/packages/orq-rc/src/lib/base64.ts +0 -37
  212. package/packages/orq-rc/src/lib/config.ts +0 -74
  213. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  214. package/packages/orq-rc/src/lib/encodings.ts +0 -483
  215. package/packages/orq-rc/src/lib/env.ts +0 -89
  216. package/packages/orq-rc/src/lib/event-streams.ts +0 -135
  217. package/packages/orq-rc/src/lib/files.ts +0 -82
  218. package/packages/orq-rc/src/lib/http.ts +0 -323
  219. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  220. package/packages/orq-rc/src/lib/logger.ts +0 -9
  221. package/packages/orq-rc/src/lib/matchers.ts +0 -345
  222. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  223. package/packages/orq-rc/src/lib/retries.ts +0 -218
  224. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  225. package/packages/orq-rc/src/lib/sdks.ts +0 -407
  226. package/packages/orq-rc/src/lib/security.ts +0 -264
  227. package/packages/orq-rc/src/lib/url.ts +0 -33
  228. package/packages/orq-rc/src/mcp-server/cli/start/command.ts +0 -111
  229. package/packages/orq-rc/src/mcp-server/cli/start/impl.ts +0 -136
  230. package/packages/orq-rc/src/mcp-server/cli.ts +0 -13
  231. package/packages/orq-rc/src/mcp-server/console-logger.ts +0 -71
  232. package/packages/orq-rc/src/mcp-server/extensions.ts +0 -17
  233. package/packages/orq-rc/src/mcp-server/mcp-server.ts +0 -26
  234. package/packages/orq-rc/src/mcp-server/prompts.ts +0 -117
  235. package/packages/orq-rc/src/mcp-server/resources.ts +0 -172
  236. package/packages/orq-rc/src/mcp-server/scopes.ts +0 -7
  237. package/packages/orq-rc/src/mcp-server/server.ts +0 -251
  238. package/packages/orq-rc/src/mcp-server/shared.ts +0 -74
  239. package/packages/orq-rc/src/mcp-server/tools/agentsCreate.ts +0 -37
  240. package/packages/orq-rc/src/mcp-server/tools/agentsDelete.ts +0 -35
  241. package/packages/orq-rc/src/mcp-server/tools/agentsInvoke.ts +0 -40
  242. package/packages/orq-rc/src/mcp-server/tools/agentsList.ts +0 -41
  243. package/packages/orq-rc/src/mcp-server/tools/agentsResponsesCreate.ts +0 -41
  244. package/packages/orq-rc/src/mcp-server/tools/agentsRetrieve.ts +0 -37
  245. package/packages/orq-rc/src/mcp-server/tools/agentsRun.ts +0 -37
  246. package/packages/orq-rc/src/mcp-server/tools/agentsStream.ts +0 -40
  247. package/packages/orq-rc/src/mcp-server/tools/agentsStreamRun.ts +0 -37
  248. package/packages/orq-rc/src/mcp-server/tools/agentsUpdate.ts +0 -41
  249. package/packages/orq-rc/src/mcp-server/tools/budgetsCreate.ts +0 -37
  250. package/packages/orq-rc/src/mcp-server/tools/budgetsDelete.ts +0 -35
  251. package/packages/orq-rc/src/mcp-server/tools/budgetsGet.ts +0 -37
  252. package/packages/orq-rc/src/mcp-server/tools/budgetsList.ts +0 -37
  253. package/packages/orq-rc/src/mcp-server/tools/budgetsUpdate.ts +0 -37
  254. package/packages/orq-rc/src/mcp-server/tools/chunkingParse.ts +0 -37
  255. package/packages/orq-rc/src/mcp-server/tools/contactsCreate.ts +0 -37
  256. package/packages/orq-rc/src/mcp-server/tools/contactsDelete.ts +0 -35
  257. package/packages/orq-rc/src/mcp-server/tools/contactsList.ts +0 -37
  258. package/packages/orq-rc/src/mcp-server/tools/contactsRetrieve.ts +0 -37
  259. package/packages/orq-rc/src/mcp-server/tools/contactsUpdate.ts +0 -37
  260. package/packages/orq-rc/src/mcp-server/tools/datasetsClear.ts +0 -35
  261. package/packages/orq-rc/src/mcp-server/tools/datasetsCreate.ts +0 -37
  262. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoint.ts +0 -37
  263. package/packages/orq-rc/src/mcp-server/tools/datasetsDelete.ts +0 -35
  264. package/packages/orq-rc/src/mcp-server/tools/datasetsDeleteDatapoint.ts +0 -35
  265. package/packages/orq-rc/src/mcp-server/tools/datasetsList.ts +0 -37
  266. package/packages/orq-rc/src/mcp-server/tools/datasetsListDatapoints.ts +0 -37
  267. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieve.ts +0 -37
  268. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieveDatapoint.ts +0 -37
  269. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdate.ts +0 -37
  270. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdateDatapoint.ts +0 -35
  271. package/packages/orq-rc/src/mcp-server/tools/deploymentsGetConfig.ts +0 -37
  272. package/packages/orq-rc/src/mcp-server/tools/deploymentsInvoke.ts +0 -37
  273. package/packages/orq-rc/src/mcp-server/tools/deploymentsList.ts +0 -37
  274. package/packages/orq-rc/src/mcp-server/tools/deploymentsMetricsCreate.ts +0 -37
  275. package/packages/orq-rc/src/mcp-server/tools/deploymentsStream.ts +0 -37
  276. package/packages/orq-rc/src/mcp-server/tools/evalsAll.ts +0 -35
  277. package/packages/orq-rc/src/mcp-server/tools/evalsCreate.ts +0 -35
  278. package/packages/orq-rc/src/mcp-server/tools/evalsDelete.ts +0 -33
  279. package/packages/orq-rc/src/mcp-server/tools/evalsUpdate.ts +0 -35
  280. package/packages/orq-rc/src/mcp-server/tools/feedbackCreate.ts +0 -37
  281. package/packages/orq-rc/src/mcp-server/tools/filesCreate.ts +0 -37
  282. package/packages/orq-rc/src/mcp-server/tools/filesDelete.ts +0 -33
  283. package/packages/orq-rc/src/mcp-server/tools/filesGet.ts +0 -37
  284. package/packages/orq-rc/src/mcp-server/tools/filesList.ts +0 -37
  285. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreate.ts +0 -35
  286. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateChunks.ts +0 -35
  287. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateDatasource.ts +0 -35
  288. package/packages/orq-rc/src/mcp-server/tools/knowledgeDelete.ts +0 -35
  289. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteChunk.ts +0 -33
  290. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteChunks.ts +0 -35
  291. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteDatasource.ts +0 -35
  292. package/packages/orq-rc/src/mcp-server/tools/knowledgeGetChunksCount.ts +0 -35
  293. package/packages/orq-rc/src/mcp-server/tools/knowledgeList.ts +0 -37
  294. package/packages/orq-rc/src/mcp-server/tools/knowledgeListChunks.ts +0 -35
  295. package/packages/orq-rc/src/mcp-server/tools/knowledgeListChunksPaginated.ts +0 -35
  296. package/packages/orq-rc/src/mcp-server/tools/knowledgeListDatasources.ts +0 -35
  297. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieve.ts +0 -37
  298. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveChunk.ts +0 -35
  299. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveDatasource.ts +0 -35
  300. package/packages/orq-rc/src/mcp-server/tools/knowledgeSearch.ts +0 -37
  301. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdate.ts +0 -35
  302. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateChunk.ts +0 -35
  303. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateDatasource.ts +0 -35
  304. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreate.ts +0 -35
  305. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreateDocument.ts +0 -37
  306. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreateMemory.ts +0 -37
  307. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDelete.ts +0 -35
  308. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDeleteDocument.ts +0 -40
  309. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDeleteMemory.ts +0 -40
  310. package/packages/orq-rc/src/mcp-server/tools/memoryStoresList.ts +0 -37
  311. package/packages/orq-rc/src/mcp-server/tools/memoryStoresListDocuments.ts +0 -37
  312. package/packages/orq-rc/src/mcp-server/tools/memoryStoresListMemories.ts +0 -37
  313. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieve.ts +0 -37
  314. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieveDocument.ts +0 -37
  315. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieveMemory.ts +0 -37
  316. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdate.ts +0 -37
  317. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdateDocument.ts +0 -37
  318. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdateMemory.ts +0 -37
  319. package/packages/orq-rc/src/mcp-server/tools/modelsList.ts +0 -30
  320. package/packages/orq-rc/src/mcp-server/tools/promptsCreate.ts +0 -35
  321. package/packages/orq-rc/src/mcp-server/tools/promptsDelete.ts +0 -33
  322. package/packages/orq-rc/src/mcp-server/tools/promptsGetVersion.ts +0 -37
  323. package/packages/orq-rc/src/mcp-server/tools/promptsList.ts +0 -37
  324. package/packages/orq-rc/src/mcp-server/tools/promptsListVersions.ts +0 -37
  325. package/packages/orq-rc/src/mcp-server/tools/promptsRetrieve.ts +0 -37
  326. package/packages/orq-rc/src/mcp-server/tools/promptsUpdate.ts +0 -35
  327. package/packages/orq-rc/src/mcp-server/tools/remoteconfigsRetrieve.ts +0 -36
  328. package/packages/orq-rc/src/mcp-server/tools/toolsCreate.ts +0 -37
  329. package/packages/orq-rc/src/mcp-server/tools/toolsDelete.ts +0 -35
  330. package/packages/orq-rc/src/mcp-server/tools/toolsList.ts +0 -37
  331. package/packages/orq-rc/src/mcp-server/tools/toolsRetrieve.ts +0 -37
  332. package/packages/orq-rc/src/mcp-server/tools/toolsUpdate.ts +0 -37
  333. package/packages/orq-rc/src/mcp-server/tools.ts +0 -129
  334. package/packages/orq-rc/src/models/components/index.ts +0 -6
  335. package/packages/orq-rc/src/models/components/invokedeploymentrequest.ts +0 -6261
  336. package/packages/orq-rc/src/models/components/security.ts +0 -56
  337. package/packages/orq-rc/src/models/errors/apierror.ts +0 -40
  338. package/packages/orq-rc/src/models/errors/createagentrequest.ts +0 -67
  339. package/packages/orq-rc/src/models/errors/createeval.ts +0 -67
  340. package/packages/orq-rc/src/models/errors/deleteagent.ts +0 -67
  341. package/packages/orq-rc/src/models/errors/deletecontact.ts +0 -78
  342. package/packages/orq-rc/src/models/errors/deleteeval.ts +0 -67
  343. package/packages/orq-rc/src/models/errors/getevals.ts +0 -67
  344. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -67
  345. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -77
  346. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  347. package/packages/orq-rc/src/models/errors/index.ts +0 -26
  348. package/packages/orq-rc/src/models/errors/orqerror.ts +0 -35
  349. package/packages/orq-rc/src/models/errors/responsevalidationerror.ts +0 -50
  350. package/packages/orq-rc/src/models/errors/retrieveagentrequest.ts +0 -67
  351. package/packages/orq-rc/src/models/errors/retrievecontact.ts +0 -78
  352. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -109
  353. package/packages/orq-rc/src/models/errors/streamagent.ts +0 -67
  354. package/packages/orq-rc/src/models/errors/streamrunagent.ts +0 -67
  355. package/packages/orq-rc/src/models/errors/updateagent.ts +0 -67
  356. package/packages/orq-rc/src/models/errors/updatecontact.ts +0 -70
  357. package/packages/orq-rc/src/models/errors/updateeval.ts +0 -67
  358. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -67
  359. package/packages/orq-rc/src/models/errors/updatetool.ts +0 -78
  360. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -63
  361. package/packages/orq-rc/src/models/operations/createagentrequest.ts +0 -8215
  362. package/packages/orq-rc/src/models/operations/createagentresponserequest.ts +0 -1353
  363. package/packages/orq-rc/src/models/operations/createbudget.ts +0 -582
  364. package/packages/orq-rc/src/models/operations/createchunk.ts +0 -341
  365. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -237
  366. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -257
  367. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -5379
  368. package/packages/orq-rc/src/models/operations/createdatasource.ts +0 -694
  369. package/packages/orq-rc/src/models/operations/createeval.ts +0 -6857
  370. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -226
  371. package/packages/orq-rc/src/models/operations/createknowledge.ts +0 -1489
  372. package/packages/orq-rc/src/models/operations/creatememory.ts +0 -229
  373. package/packages/orq-rc/src/models/operations/creatememorydocument.ts +0 -242
  374. package/packages/orq-rc/src/models/operations/creatememorystore.ts +0 -310
  375. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -6179
  376. package/packages/orq-rc/src/models/operations/createtool.ts +0 -3956
  377. package/packages/orq-rc/src/models/operations/deleteagent.ts +0 -63
  378. package/packages/orq-rc/src/models/operations/deletebudget.ts +0 -54
  379. package/packages/orq-rc/src/models/operations/deletechunk.ts +0 -81
  380. package/packages/orq-rc/src/models/operations/deletechunks.ts +0 -198
  381. package/packages/orq-rc/src/models/operations/deletecontact.ts +0 -54
  382. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -72
  383. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -63
  384. package/packages/orq-rc/src/models/operations/deletedatasource.ts +0 -72
  385. package/packages/orq-rc/src/models/operations/deleteeval.ts +0 -51
  386. package/packages/orq-rc/src/models/operations/deleteknowledge.ts +0 -63
  387. package/packages/orq-rc/src/models/operations/deletememory.ts +0 -72
  388. package/packages/orq-rc/src/models/operations/deletememorydocument.ts +0 -83
  389. package/packages/orq-rc/src/models/operations/deletememorystore.ts +0 -63
  390. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -54
  391. package/packages/orq-rc/src/models/operations/deletetool.ts +0 -60
  392. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -5091
  393. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -8055
  394. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -980
  395. package/packages/orq-rc/src/models/operations/deployments.ts +0 -2054
  396. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -8269
  397. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -63
  398. package/packages/orq-rc/src/models/operations/fileget.ts +0 -181
  399. package/packages/orq-rc/src/models/operations/filelist.ts +0 -268
  400. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -258
  401. package/packages/orq-rc/src/models/operations/getallmemories.ts +0 -261
  402. package/packages/orq-rc/src/models/operations/getallmemorydocuments.ts +0 -280
  403. package/packages/orq-rc/src/models/operations/getallmemorystores.ts +0 -325
  404. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -2033
  405. package/packages/orq-rc/src/models/operations/getalltools.ts +0 -2292
  406. package/packages/orq-rc/src/models/operations/getbudget.ts +0 -357
  407. package/packages/orq-rc/src/models/operations/getchunkscount.ts +0 -185
  408. package/packages/orq-rc/src/models/operations/getevals.ts +0 -5543
  409. package/packages/orq-rc/src/models/operations/getonechunk.ts +0 -258
  410. package/packages/orq-rc/src/models/operations/getoneknowledge.ts +0 -1070
  411. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -1924
  412. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -1942
  413. package/packages/orq-rc/src/models/operations/index.ts +0 -98
  414. package/packages/orq-rc/src/models/operations/invokeagent.ts +0 -1893
  415. package/packages/orq-rc/src/models/operations/listagents.ts +0 -3614
  416. package/packages/orq-rc/src/models/operations/listbudgets.ts +0 -494
  417. package/packages/orq-rc/src/models/operations/listchunks.ts +0 -395
  418. package/packages/orq-rc/src/models/operations/listchunkspaginated.ts +0 -408
  419. package/packages/orq-rc/src/models/operations/listcontacts.ts +0 -413
  420. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -3169
  421. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -334
  422. package/packages/orq-rc/src/models/operations/listdatasources.ts +0 -363
  423. package/packages/orq-rc/src/models/operations/listknowledgebases.ts +0 -1068
  424. package/packages/orq-rc/src/models/operations/listmodels.ts +0 -207
  425. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -2041
  426. package/packages/orq-rc/src/models/operations/parse.ts +0 -1013
  427. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -146
  428. package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +0 -3741
  429. package/packages/orq-rc/src/models/operations/retrievecontact.ts +0 -180
  430. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -2985
  431. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -246
  432. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +0 -231
  433. package/packages/orq-rc/src/models/operations/retrievememory.ts +0 -171
  434. package/packages/orq-rc/src/models/operations/retrievememorydocument.ts +0 -189
  435. package/packages/orq-rc/src/models/operations/retrievememorystore.ts +0 -234
  436. package/packages/orq-rc/src/models/operations/retrievetool.ts +0 -2347
  437. package/packages/orq-rc/src/models/operations/runagent.ts +0 -7613
  438. package/packages/orq-rc/src/models/operations/searchknowledge.ts +0 -2775
  439. package/packages/orq-rc/src/models/operations/streamagent.ts +0 -9732
  440. package/packages/orq-rc/src/models/operations/streamrunagent.ts +0 -15817
  441. package/packages/orq-rc/src/models/operations/updateagent.ts +0 -8649
  442. package/packages/orq-rc/src/models/operations/updatebudget.ts +0 -502
  443. package/packages/orq-rc/src/models/operations/updatechunk.ts +0 -361
  444. package/packages/orq-rc/src/models/operations/updatecontact.ts +0 -280
  445. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -5374
  446. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -326
  447. package/packages/orq-rc/src/models/operations/updatedatasource.ts +0 -288
  448. package/packages/orq-rc/src/models/operations/updateeval.ts +0 -7197
  449. package/packages/orq-rc/src/models/operations/updateknowledge.ts +0 -1925
  450. package/packages/orq-rc/src/models/operations/updatememory.ts +0 -238
  451. package/packages/orq-rc/src/models/operations/updatememorydocument.ts +0 -251
  452. package/packages/orq-rc/src/models/operations/updatememorystore.ts +0 -463
  453. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -6410
  454. package/packages/orq-rc/src/models/operations/updatetool.ts +0 -4279
  455. package/packages/orq-rc/src/sdk/agents.ts +0 -196
  456. package/packages/orq-rc/src/sdk/budgets.ts +0 -99
  457. package/packages/orq-rc/src/sdk/chunking.ts +0 -27
  458. package/packages/orq-rc/src/sdk/contacts.ts +0 -99
  459. package/packages/orq-rc/src/sdk/datasets.ts +0 -204
  460. package/packages/orq-rc/src/sdk/deployments.ts +0 -89
  461. package/packages/orq-rc/src/sdk/evals.ts +0 -69
  462. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  463. package/packages/orq-rc/src/sdk/files.ts +0 -78
  464. package/packages/orq-rc/src/sdk/index.ts +0 -5
  465. package/packages/orq-rc/src/sdk/knowledge.ts +0 -309
  466. package/packages/orq-rc/src/sdk/memorystores.ts +0 -286
  467. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  468. package/packages/orq-rc/src/sdk/models.ts +0 -25
  469. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  470. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  471. package/packages/orq-rc/src/sdk/responses.ts +0 -29
  472. package/packages/orq-rc/src/sdk/sdk.ts +0 -97
  473. package/packages/orq-rc/src/sdk/tools.ts +0 -99
  474. package/packages/orq-rc/src/types/async.ts +0 -68
  475. package/packages/orq-rc/src/types/blobs.ts +0 -32
  476. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  477. package/packages/orq-rc/src/types/enums.ts +0 -45
  478. package/packages/orq-rc/src/types/fp.ts +0 -50
  479. package/packages/orq-rc/src/types/index.ts +0 -11
  480. package/packages/orq-rc/src/types/operations.ts +0 -105
  481. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  482. package/packages/orq-rc/src/types/streams.ts +0 -21
  483. package/packages/orq-rc/src/types/unrecognized.ts +0 -27
  484. package/packages/orq-rc/tsconfig.json +0 -41
@@ -1,1893 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod/v3";
6
- import { remap as remap$ } from "../../lib/primitives.js";
7
- import { safeParse } from "../../lib/schemas.js";
8
- import { ClosedEnum } from "../../types/enums.js";
9
- import { Result as SafeParseResult } from "../../types/fp.js";
10
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
-
12
- /**
13
- * Message containing tool execution results
14
- */
15
- export const InvokeAgentRoleToolMessage = {
16
- Tool: "tool",
17
- } as const;
18
- /**
19
- * Message containing tool execution results
20
- */
21
- export type InvokeAgentRoleToolMessage = ClosedEnum<
22
- typeof InvokeAgentRoleToolMessage
23
- >;
24
-
25
- /**
26
- * Message from the end user
27
- */
28
- export const InvokeAgentRoleUserMessage = {
29
- User: "user",
30
- } as const;
31
- /**
32
- * Message from the end user
33
- */
34
- export type InvokeAgentRoleUserMessage = ClosedEnum<
35
- typeof InvokeAgentRoleUserMessage
36
- >;
37
-
38
- /**
39
- * Message role (user or tool for continuing executions)
40
- */
41
- export type InvokeAgentRole =
42
- | InvokeAgentRoleUserMessage
43
- | InvokeAgentRoleToolMessage;
44
-
45
- export const InvokeAgentPublicMessagePartAgentsRequestKind = {
46
- ToolResult: "tool_result",
47
- } as const;
48
- export type InvokeAgentPublicMessagePartAgentsRequestKind = ClosedEnum<
49
- typeof InvokeAgentPublicMessagePartAgentsRequestKind
50
- >;
51
-
52
- /**
53
- * 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.
54
- */
55
- export type PublicMessagePartToolResultPart = {
56
- kind: InvokeAgentPublicMessagePartAgentsRequestKind;
57
- toolCallId: string;
58
- result?: any | undefined;
59
- metadata?: { [k: string]: any } | undefined;
60
- };
61
-
62
- export const InvokeAgentPublicMessagePartAgentsKind = {
63
- File: "file",
64
- } as const;
65
- export type InvokeAgentPublicMessagePartAgentsKind = ClosedEnum<
66
- typeof InvokeAgentPublicMessagePartAgentsKind
67
- >;
68
-
69
- /**
70
- * File in URI format. Check in the model's documentation for the supported mime types for the URI format
71
- */
72
- export type FileFileInURIFormat = {
73
- /**
74
- * URL for the File content
75
- */
76
- uri: string;
77
- /**
78
- * Optional mimeType for the file
79
- */
80
- mimeType?: string | undefined;
81
- /**
82
- * Optional name for the file
83
- */
84
- name?: string | undefined;
85
- };
86
-
87
- /**
88
- * Binary in base64 format. Check in the model's documentation for the supported mime types for the binary format.
89
- */
90
- export type FileBinaryFormat = {
91
- /**
92
- * base64 encoded content of the file
93
- */
94
- bytes: string;
95
- /**
96
- * Optional mimeType for the file
97
- */
98
- mimeType?: string | undefined;
99
- /**
100
- * Optional name for the file
101
- */
102
- name?: string | undefined;
103
- };
104
-
105
- export type InvokeAgentPublicMessagePartFile =
106
- | FileBinaryFormat
107
- | FileFileInURIFormat;
108
-
109
- /**
110
- * File attachment part. Use this to send files (images, documents, etc.) to the agent for processing.
111
- */
112
- export type PublicMessagePartFilePart = {
113
- kind: InvokeAgentPublicMessagePartAgentsKind;
114
- file: FileBinaryFormat | FileFileInURIFormat;
115
- metadata?: { [k: string]: any } | undefined;
116
- };
117
-
118
- export const InvokeAgentPublicMessagePartKind = {
119
- Text: "text",
120
- } as const;
121
- export type InvokeAgentPublicMessagePartKind = ClosedEnum<
122
- typeof InvokeAgentPublicMessagePartKind
123
- >;
124
-
125
- /**
126
- * Text content part. Use this to send text messages to the agent.
127
- */
128
- export type PublicMessagePartTextPart = {
129
- kind: InvokeAgentPublicMessagePartKind;
130
- text: string;
131
- };
132
-
133
- /**
134
- * 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.
135
- */
136
- export type InvokeAgentPublicMessagePart =
137
- | PublicMessagePartTextPart
138
- | PublicMessagePartFilePart
139
- | PublicMessagePartToolResultPart;
140
-
141
- /**
142
- * The A2A message to send to the agent (user input or tool results)
143
- */
144
- export type InvokeAgentA2AMessage = {
145
- /**
146
- * Optional A2A message ID in ULID format
147
- */
148
- messageId?: string | undefined;
149
- /**
150
- * Message role (user or tool for continuing executions)
151
- */
152
- role: InvokeAgentRoleUserMessage | InvokeAgentRoleToolMessage;
153
- /**
154
- * A2A message parts (text, file, or tool_result only)
155
- */
156
- parts: Array<
157
- | PublicMessagePartTextPart
158
- | PublicMessagePartFilePart
159
- | PublicMessagePartToolResultPart
160
- >;
161
- };
162
-
163
- /**
164
- * Information about the contact making the request. If the contact does not exist, it will be created automatically.
165
- */
166
- export type InvokeAgentContact = {
167
- /**
168
- * Unique identifier for the contact
169
- */
170
- id: string;
171
- /**
172
- * Display name of the contact
173
- */
174
- displayName?: string | undefined;
175
- /**
176
- * Email address of the contact
177
- */
178
- email?: string | undefined;
179
- /**
180
- * A hash of key/value pairs containing any other data about the contact
181
- */
182
- metadata?: Array<{ [k: string]: any }> | undefined;
183
- /**
184
- * URL to the contact's avatar or logo
185
- */
186
- logoUrl?: string | undefined;
187
- /**
188
- * A list of tags associated with the contact
189
- */
190
- tags?: Array<string> | undefined;
191
- };
192
-
193
- /**
194
- * Thread information to group related requests
195
- */
196
- export type InvokeAgentThread = {
197
- /**
198
- * Unique thread identifier to group related invocations.
199
- */
200
- id: string;
201
- /**
202
- * Optional tags to differentiate or categorize threads
203
- */
204
- tags?: Array<string> | undefined;
205
- };
206
-
207
- /**
208
- * Memory configuration for the agent execution. Used to associate memory stores with specific entities like users or sessions.
209
- */
210
- export type InvokeAgentMemory = {
211
- /**
212
- * An entity ID used to link memory stores to a specific user, session, or conversation. This ID is used to isolate and retrieve memories specific to the entity across agent executions.
213
- */
214
- entityId: string;
215
- };
216
-
217
- export type InvokeAgentRequestBody = {
218
- /**
219
- * Optional task ID to continue an existing agent execution. When provided, the agent will continue the conversation from the existing task state. The task must be in an inactive state to continue.
220
- */
221
- taskId?: string | undefined;
222
- /**
223
- * The A2A message to send to the agent (user input or tool results)
224
- */
225
- message: InvokeAgentA2AMessage;
226
- /**
227
- * Optional variables for template replacement in system prompt, instructions, and messages
228
- */
229
- variables?: { [k: string]: any } | undefined;
230
- /**
231
- * Information about the contact making the request. If the contact does not exist, it will be created automatically.
232
- */
233
- contact?: InvokeAgentContact | undefined;
234
- /**
235
- * Thread information to group related requests
236
- */
237
- thread?: InvokeAgentThread | undefined;
238
- /**
239
- * Memory configuration for the agent execution. Used to associate memory stores with specific entities like users or sessions.
240
- */
241
- memory?: InvokeAgentMemory | undefined;
242
- /**
243
- * Optional metadata for the agent invocation as key-value pairs that will be included in traces
244
- */
245
- metadata?: { [k: string]: any } | undefined;
246
- };
247
-
248
- export type InvokeAgentRequest = {
249
- /**
250
- * The key or ID of the agent to invoke
251
- */
252
- key: string;
253
- requestBody?: InvokeAgentRequestBody | undefined;
254
- };
255
-
256
- /**
257
- * A2A entity type identifier
258
- */
259
- export const InvokeAgentKind = {
260
- Task: "task",
261
- } as const;
262
- /**
263
- * A2A entity type identifier
264
- */
265
- export type InvokeAgentKind = ClosedEnum<typeof InvokeAgentKind>;
266
-
267
- /**
268
- * Current state of the agent task execution. Values: submitted (queued), working (executing), input-required (awaiting user input), completed (finished successfully), failed (error occurred). Note: auth-required, canceled, and rejected statuses are defined for A2A protocol compatibility but are not currently supported in task execution.
269
- */
270
- export const TaskState = {
271
- Submitted: "submitted",
272
- Working: "working",
273
- InputRequired: "input-required",
274
- AuthRequired: "auth-required",
275
- Completed: "completed",
276
- Failed: "failed",
277
- Canceled: "canceled",
278
- Rejected: "rejected",
279
- } as const;
280
- /**
281
- * Current state of the agent task execution. Values: submitted (queued), working (executing), input-required (awaiting user input), completed (finished successfully), failed (error occurred). Note: auth-required, canceled, and rejected statuses are defined for A2A protocol compatibility but are not currently supported in task execution.
282
- */
283
- export type TaskState = ClosedEnum<typeof TaskState>;
284
-
285
- export const InvokeAgentAgentsKind = {
286
- Message: "message",
287
- } as const;
288
- export type InvokeAgentAgentsKind = ClosedEnum<typeof InvokeAgentAgentsKind>;
289
-
290
- /**
291
- * Role of the message sender in the A2A protocol. Values: user (end user), agent (AI agent), tool (tool execution result), system (system instructions/prompts).
292
- */
293
- export const ExtendedMessageRole = {
294
- User: "user",
295
- Agent: "agent",
296
- Tool: "tool",
297
- System: "system",
298
- } as const;
299
- /**
300
- * Role of the message sender in the A2A protocol. Values: user (end user), agent (AI agent), tool (tool execution result), system (system instructions/prompts).
301
- */
302
- export type ExtendedMessageRole = ClosedEnum<typeof ExtendedMessageRole>;
303
-
304
- export const InvokeAgentPartsAgentsResponse200Kind = {
305
- ToolResult: "tool_result",
306
- } as const;
307
- export type InvokeAgentPartsAgentsResponse200Kind = ClosedEnum<
308
- typeof InvokeAgentPartsAgentsResponse200Kind
309
- >;
310
-
311
- /**
312
- * The result of a tool execution. Contains the tool call ID for correlation and the result data from the tool invocation.
313
- */
314
- export type PartsToolResultPart = {
315
- kind: InvokeAgentPartsAgentsResponse200Kind;
316
- toolCallId: string;
317
- result?: any | undefined;
318
- metadata?: { [k: string]: any } | undefined;
319
- };
320
-
321
- export const InvokeAgentPartsAgentsResponseKind = {
322
- ToolCall: "tool_call",
323
- } as const;
324
- export type InvokeAgentPartsAgentsResponseKind = ClosedEnum<
325
- typeof InvokeAgentPartsAgentsResponseKind
326
- >;
327
-
328
- /**
329
- * A tool invocation request from an agent. Contains the tool name, unique call ID, and arguments for the tool execution.
330
- */
331
- export type ToolCallPart = {
332
- kind: InvokeAgentPartsAgentsResponseKind;
333
- toolName: string;
334
- toolCallId: string;
335
- arguments: { [k: string]: any };
336
- metadata?: { [k: string]: any } | undefined;
337
- };
338
-
339
- export const InvokeAgentPartsAgentsKind = {
340
- File: "file",
341
- } as const;
342
- export type InvokeAgentPartsAgentsKind = ClosedEnum<
343
- typeof InvokeAgentPartsAgentsKind
344
- >;
345
-
346
- /**
347
- * File in URI format. Check in the model's documentation for the supported mime types for the URI format
348
- */
349
- export type InvokeAgentFileFileInURIFormat = {
350
- /**
351
- * URL for the File content
352
- */
353
- uri: string;
354
- /**
355
- * Optional mimeType for the file
356
- */
357
- mimeType?: string | undefined;
358
- /**
359
- * Optional name for the file
360
- */
361
- name?: string | undefined;
362
- };
363
-
364
- /**
365
- * Binary in base64 format. Check in the model's documentation for the supported mime types for the binary format.
366
- */
367
- export type InvokeAgentFileBinaryFormat = {
368
- /**
369
- * base64 encoded content of the file
370
- */
371
- bytes: string;
372
- /**
373
- * Optional mimeType for the file
374
- */
375
- mimeType?: string | undefined;
376
- /**
377
- * Optional name for the file
378
- */
379
- name?: string | undefined;
380
- };
381
-
382
- export type PartsFile =
383
- | InvokeAgentFileBinaryFormat
384
- | InvokeAgentFileFileInURIFormat;
385
-
386
- /**
387
- * 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.
388
- */
389
- export type PartsFilePart = {
390
- kind: InvokeAgentPartsAgentsKind;
391
- file: InvokeAgentFileBinaryFormat | InvokeAgentFileFileInURIFormat;
392
- metadata?: { [k: string]: any } | undefined;
393
- };
394
-
395
- export const InvokeAgentPartsKind = {
396
- Data: "data",
397
- } as const;
398
- export type InvokeAgentPartsKind = ClosedEnum<typeof InvokeAgentPartsKind>;
399
-
400
- /**
401
- * A structured data part containing JSON-serializable key-value pairs. Used for passing structured information between agents and tools.
402
- */
403
- export type DataPart = {
404
- kind: InvokeAgentPartsKind;
405
- data: { [k: string]: any };
406
- metadata?: { [k: string]: any } | undefined;
407
- };
408
-
409
- export const PartsKind = {
410
- Text: "text",
411
- } as const;
412
- export type PartsKind = ClosedEnum<typeof PartsKind>;
413
-
414
- /**
415
- * A text content part containing plain text or markdown. Used for agent messages, user input, and text-based responses.
416
- */
417
- export type PartsTextPart = {
418
- kind: PartsKind;
419
- text: string;
420
- };
421
-
422
- export type Parts =
423
- | ToolCallPart
424
- | PartsTextPart
425
- | DataPart
426
- | PartsFilePart
427
- | PartsToolResultPart;
428
-
429
- /**
430
- * Optional A2A message providing additional context about the current status
431
- */
432
- export type TaskStatusMessage = {
433
- kind: InvokeAgentAgentsKind;
434
- messageId: string;
435
- /**
436
- * Role of the message sender in the A2A protocol. Values: user (end user), agent (AI agent), tool (tool execution result), system (system instructions/prompts).
437
- */
438
- role: ExtendedMessageRole;
439
- parts: Array<
440
- | ToolCallPart
441
- | PartsTextPart
442
- | DataPart
443
- | PartsFilePart
444
- | PartsToolResultPart
445
- >;
446
- };
447
-
448
- /**
449
- * Current task status information
450
- */
451
- export type TaskStatus = {
452
- /**
453
- * Current state of the agent task execution. Values: submitted (queued), working (executing), input-required (awaiting user input), completed (finished successfully), failed (error occurred). Note: auth-required, canceled, and rejected statuses are defined for A2A protocol compatibility but are not currently supported in task execution.
454
- */
455
- state: TaskState;
456
- /**
457
- * ISO 8601 timestamp of when the status was updated
458
- */
459
- timestamp?: string | undefined;
460
- /**
461
- * Optional A2A message providing additional context about the current status
462
- */
463
- message?: TaskStatusMessage | undefined;
464
- };
465
-
466
- /**
467
- * Response format following the Agent-to-Agent (A2A) protocol. Returned when starting or continuing an agent task execution.
468
- */
469
- export type InvokeAgentA2ATaskResponse = {
470
- /**
471
- * The unique ID of the created agent execution task
472
- */
473
- id: string;
474
- /**
475
- * The correlation ID for this execution (used for tracking)
476
- */
477
- contextId: string;
478
- /**
479
- * A2A entity type identifier
480
- */
481
- kind: InvokeAgentKind;
482
- /**
483
- * Current task status information
484
- */
485
- status: TaskStatus;
486
- /**
487
- * Task metadata containing workspace_id and trace_id for feedback and tracking
488
- */
489
- metadata?: { [k: string]: any } | undefined;
490
- };
491
-
492
- /** @internal */
493
- export const InvokeAgentRoleToolMessage$inboundSchema: z.ZodNativeEnum<
494
- typeof InvokeAgentRoleToolMessage
495
- > = z.nativeEnum(InvokeAgentRoleToolMessage);
496
- /** @internal */
497
- export const InvokeAgentRoleToolMessage$outboundSchema: z.ZodNativeEnum<
498
- typeof InvokeAgentRoleToolMessage
499
- > = InvokeAgentRoleToolMessage$inboundSchema;
500
-
501
- /** @internal */
502
- export const InvokeAgentRoleUserMessage$inboundSchema: z.ZodNativeEnum<
503
- typeof InvokeAgentRoleUserMessage
504
- > = z.nativeEnum(InvokeAgentRoleUserMessage);
505
- /** @internal */
506
- export const InvokeAgentRoleUserMessage$outboundSchema: z.ZodNativeEnum<
507
- typeof InvokeAgentRoleUserMessage
508
- > = InvokeAgentRoleUserMessage$inboundSchema;
509
-
510
- /** @internal */
511
- export const InvokeAgentRole$inboundSchema: z.ZodType<
512
- InvokeAgentRole,
513
- z.ZodTypeDef,
514
- unknown
515
- > = z.union([
516
- InvokeAgentRoleUserMessage$inboundSchema,
517
- InvokeAgentRoleToolMessage$inboundSchema,
518
- ]);
519
- /** @internal */
520
- export type InvokeAgentRole$Outbound = string | string;
521
-
522
- /** @internal */
523
- export const InvokeAgentRole$outboundSchema: z.ZodType<
524
- InvokeAgentRole$Outbound,
525
- z.ZodTypeDef,
526
- InvokeAgentRole
527
- > = z.union([
528
- InvokeAgentRoleUserMessage$outboundSchema,
529
- InvokeAgentRoleToolMessage$outboundSchema,
530
- ]);
531
-
532
- export function invokeAgentRoleToJSON(
533
- invokeAgentRole: InvokeAgentRole,
534
- ): string {
535
- return JSON.stringify(InvokeAgentRole$outboundSchema.parse(invokeAgentRole));
536
- }
537
- export function invokeAgentRoleFromJSON(
538
- jsonString: string,
539
- ): SafeParseResult<InvokeAgentRole, SDKValidationError> {
540
- return safeParse(
541
- jsonString,
542
- (x) => InvokeAgentRole$inboundSchema.parse(JSON.parse(x)),
543
- `Failed to parse 'InvokeAgentRole' from JSON`,
544
- );
545
- }
546
-
547
- /** @internal */
548
- export const InvokeAgentPublicMessagePartAgentsRequestKind$inboundSchema:
549
- z.ZodNativeEnum<typeof InvokeAgentPublicMessagePartAgentsRequestKind> = z
550
- .nativeEnum(InvokeAgentPublicMessagePartAgentsRequestKind);
551
- /** @internal */
552
- export const InvokeAgentPublicMessagePartAgentsRequestKind$outboundSchema:
553
- z.ZodNativeEnum<typeof InvokeAgentPublicMessagePartAgentsRequestKind> =
554
- InvokeAgentPublicMessagePartAgentsRequestKind$inboundSchema;
555
-
556
- /** @internal */
557
- export const PublicMessagePartToolResultPart$inboundSchema: z.ZodType<
558
- PublicMessagePartToolResultPart,
559
- z.ZodTypeDef,
560
- unknown
561
- > = z.object({
562
- kind: InvokeAgentPublicMessagePartAgentsRequestKind$inboundSchema,
563
- tool_call_id: z.string(),
564
- result: z.any().optional(),
565
- metadata: z.record(z.any()).optional(),
566
- }).transform((v) => {
567
- return remap$(v, {
568
- "tool_call_id": "toolCallId",
569
- });
570
- });
571
- /** @internal */
572
- export type PublicMessagePartToolResultPart$Outbound = {
573
- kind: string;
574
- tool_call_id: string;
575
- result?: any | undefined;
576
- metadata?: { [k: string]: any } | undefined;
577
- };
578
-
579
- /** @internal */
580
- export const PublicMessagePartToolResultPart$outboundSchema: z.ZodType<
581
- PublicMessagePartToolResultPart$Outbound,
582
- z.ZodTypeDef,
583
- PublicMessagePartToolResultPart
584
- > = z.object({
585
- kind: InvokeAgentPublicMessagePartAgentsRequestKind$outboundSchema,
586
- toolCallId: z.string(),
587
- result: z.any().optional(),
588
- metadata: z.record(z.any()).optional(),
589
- }).transform((v) => {
590
- return remap$(v, {
591
- toolCallId: "tool_call_id",
592
- });
593
- });
594
-
595
- export function publicMessagePartToolResultPartToJSON(
596
- publicMessagePartToolResultPart: PublicMessagePartToolResultPart,
597
- ): string {
598
- return JSON.stringify(
599
- PublicMessagePartToolResultPart$outboundSchema.parse(
600
- publicMessagePartToolResultPart,
601
- ),
602
- );
603
- }
604
- export function publicMessagePartToolResultPartFromJSON(
605
- jsonString: string,
606
- ): SafeParseResult<PublicMessagePartToolResultPart, SDKValidationError> {
607
- return safeParse(
608
- jsonString,
609
- (x) => PublicMessagePartToolResultPart$inboundSchema.parse(JSON.parse(x)),
610
- `Failed to parse 'PublicMessagePartToolResultPart' from JSON`,
611
- );
612
- }
613
-
614
- /** @internal */
615
- export const InvokeAgentPublicMessagePartAgentsKind$inboundSchema:
616
- z.ZodNativeEnum<typeof InvokeAgentPublicMessagePartAgentsKind> = z.nativeEnum(
617
- InvokeAgentPublicMessagePartAgentsKind,
618
- );
619
- /** @internal */
620
- export const InvokeAgentPublicMessagePartAgentsKind$outboundSchema:
621
- z.ZodNativeEnum<typeof InvokeAgentPublicMessagePartAgentsKind> =
622
- InvokeAgentPublicMessagePartAgentsKind$inboundSchema;
623
-
624
- /** @internal */
625
- export const FileFileInURIFormat$inboundSchema: z.ZodType<
626
- FileFileInURIFormat,
627
- z.ZodTypeDef,
628
- unknown
629
- > = z.object({
630
- uri: z.string(),
631
- mimeType: z.string().optional(),
632
- name: z.string().optional(),
633
- });
634
- /** @internal */
635
- export type FileFileInURIFormat$Outbound = {
636
- uri: string;
637
- mimeType?: string | undefined;
638
- name?: string | undefined;
639
- };
640
-
641
- /** @internal */
642
- export const FileFileInURIFormat$outboundSchema: z.ZodType<
643
- FileFileInURIFormat$Outbound,
644
- z.ZodTypeDef,
645
- FileFileInURIFormat
646
- > = z.object({
647
- uri: z.string(),
648
- mimeType: z.string().optional(),
649
- name: z.string().optional(),
650
- });
651
-
652
- export function fileFileInURIFormatToJSON(
653
- fileFileInURIFormat: FileFileInURIFormat,
654
- ): string {
655
- return JSON.stringify(
656
- FileFileInURIFormat$outboundSchema.parse(fileFileInURIFormat),
657
- );
658
- }
659
- export function fileFileInURIFormatFromJSON(
660
- jsonString: string,
661
- ): SafeParseResult<FileFileInURIFormat, SDKValidationError> {
662
- return safeParse(
663
- jsonString,
664
- (x) => FileFileInURIFormat$inboundSchema.parse(JSON.parse(x)),
665
- `Failed to parse 'FileFileInURIFormat' from JSON`,
666
- );
667
- }
668
-
669
- /** @internal */
670
- export const FileBinaryFormat$inboundSchema: z.ZodType<
671
- FileBinaryFormat,
672
- z.ZodTypeDef,
673
- unknown
674
- > = z.object({
675
- bytes: z.string(),
676
- mimeType: z.string().optional(),
677
- name: z.string().optional(),
678
- });
679
- /** @internal */
680
- export type FileBinaryFormat$Outbound = {
681
- bytes: string;
682
- mimeType?: string | undefined;
683
- name?: string | undefined;
684
- };
685
-
686
- /** @internal */
687
- export const FileBinaryFormat$outboundSchema: z.ZodType<
688
- FileBinaryFormat$Outbound,
689
- z.ZodTypeDef,
690
- FileBinaryFormat
691
- > = z.object({
692
- bytes: z.string(),
693
- mimeType: z.string().optional(),
694
- name: z.string().optional(),
695
- });
696
-
697
- export function fileBinaryFormatToJSON(
698
- fileBinaryFormat: FileBinaryFormat,
699
- ): string {
700
- return JSON.stringify(
701
- FileBinaryFormat$outboundSchema.parse(fileBinaryFormat),
702
- );
703
- }
704
- export function fileBinaryFormatFromJSON(
705
- jsonString: string,
706
- ): SafeParseResult<FileBinaryFormat, SDKValidationError> {
707
- return safeParse(
708
- jsonString,
709
- (x) => FileBinaryFormat$inboundSchema.parse(JSON.parse(x)),
710
- `Failed to parse 'FileBinaryFormat' from JSON`,
711
- );
712
- }
713
-
714
- /** @internal */
715
- export const InvokeAgentPublicMessagePartFile$inboundSchema: z.ZodType<
716
- InvokeAgentPublicMessagePartFile,
717
- z.ZodTypeDef,
718
- unknown
719
- > = z.union([
720
- z.lazy(() => FileBinaryFormat$inboundSchema),
721
- z.lazy(() => FileFileInURIFormat$inboundSchema),
722
- ]);
723
- /** @internal */
724
- export type InvokeAgentPublicMessagePartFile$Outbound =
725
- | FileBinaryFormat$Outbound
726
- | FileFileInURIFormat$Outbound;
727
-
728
- /** @internal */
729
- export const InvokeAgentPublicMessagePartFile$outboundSchema: z.ZodType<
730
- InvokeAgentPublicMessagePartFile$Outbound,
731
- z.ZodTypeDef,
732
- InvokeAgentPublicMessagePartFile
733
- > = z.union([
734
- z.lazy(() => FileBinaryFormat$outboundSchema),
735
- z.lazy(() => FileFileInURIFormat$outboundSchema),
736
- ]);
737
-
738
- export function invokeAgentPublicMessagePartFileToJSON(
739
- invokeAgentPublicMessagePartFile: InvokeAgentPublicMessagePartFile,
740
- ): string {
741
- return JSON.stringify(
742
- InvokeAgentPublicMessagePartFile$outboundSchema.parse(
743
- invokeAgentPublicMessagePartFile,
744
- ),
745
- );
746
- }
747
- export function invokeAgentPublicMessagePartFileFromJSON(
748
- jsonString: string,
749
- ): SafeParseResult<InvokeAgentPublicMessagePartFile, SDKValidationError> {
750
- return safeParse(
751
- jsonString,
752
- (x) => InvokeAgentPublicMessagePartFile$inboundSchema.parse(JSON.parse(x)),
753
- `Failed to parse 'InvokeAgentPublicMessagePartFile' from JSON`,
754
- );
755
- }
756
-
757
- /** @internal */
758
- export const PublicMessagePartFilePart$inboundSchema: z.ZodType<
759
- PublicMessagePartFilePart,
760
- z.ZodTypeDef,
761
- unknown
762
- > = z.object({
763
- kind: InvokeAgentPublicMessagePartAgentsKind$inboundSchema,
764
- file: z.union([
765
- z.lazy(() => FileBinaryFormat$inboundSchema),
766
- z.lazy(() => FileFileInURIFormat$inboundSchema),
767
- ]),
768
- metadata: z.record(z.any()).optional(),
769
- });
770
- /** @internal */
771
- export type PublicMessagePartFilePart$Outbound = {
772
- kind: string;
773
- file: FileBinaryFormat$Outbound | FileFileInURIFormat$Outbound;
774
- metadata?: { [k: string]: any } | undefined;
775
- };
776
-
777
- /** @internal */
778
- export const PublicMessagePartFilePart$outboundSchema: z.ZodType<
779
- PublicMessagePartFilePart$Outbound,
780
- z.ZodTypeDef,
781
- PublicMessagePartFilePart
782
- > = z.object({
783
- kind: InvokeAgentPublicMessagePartAgentsKind$outboundSchema,
784
- file: z.union([
785
- z.lazy(() => FileBinaryFormat$outboundSchema),
786
- z.lazy(() => FileFileInURIFormat$outboundSchema),
787
- ]),
788
- metadata: z.record(z.any()).optional(),
789
- });
790
-
791
- export function publicMessagePartFilePartToJSON(
792
- publicMessagePartFilePart: PublicMessagePartFilePart,
793
- ): string {
794
- return JSON.stringify(
795
- PublicMessagePartFilePart$outboundSchema.parse(publicMessagePartFilePart),
796
- );
797
- }
798
- export function publicMessagePartFilePartFromJSON(
799
- jsonString: string,
800
- ): SafeParseResult<PublicMessagePartFilePart, SDKValidationError> {
801
- return safeParse(
802
- jsonString,
803
- (x) => PublicMessagePartFilePart$inboundSchema.parse(JSON.parse(x)),
804
- `Failed to parse 'PublicMessagePartFilePart' from JSON`,
805
- );
806
- }
807
-
808
- /** @internal */
809
- export const InvokeAgentPublicMessagePartKind$inboundSchema: z.ZodNativeEnum<
810
- typeof InvokeAgentPublicMessagePartKind
811
- > = z.nativeEnum(InvokeAgentPublicMessagePartKind);
812
- /** @internal */
813
- export const InvokeAgentPublicMessagePartKind$outboundSchema: z.ZodNativeEnum<
814
- typeof InvokeAgentPublicMessagePartKind
815
- > = InvokeAgentPublicMessagePartKind$inboundSchema;
816
-
817
- /** @internal */
818
- export const PublicMessagePartTextPart$inboundSchema: z.ZodType<
819
- PublicMessagePartTextPart,
820
- z.ZodTypeDef,
821
- unknown
822
- > = z.object({
823
- kind: InvokeAgentPublicMessagePartKind$inboundSchema,
824
- text: z.string(),
825
- });
826
- /** @internal */
827
- export type PublicMessagePartTextPart$Outbound = {
828
- kind: string;
829
- text: string;
830
- };
831
-
832
- /** @internal */
833
- export const PublicMessagePartTextPart$outboundSchema: z.ZodType<
834
- PublicMessagePartTextPart$Outbound,
835
- z.ZodTypeDef,
836
- PublicMessagePartTextPart
837
- > = z.object({
838
- kind: InvokeAgentPublicMessagePartKind$outboundSchema,
839
- text: z.string(),
840
- });
841
-
842
- export function publicMessagePartTextPartToJSON(
843
- publicMessagePartTextPart: PublicMessagePartTextPart,
844
- ): string {
845
- return JSON.stringify(
846
- PublicMessagePartTextPart$outboundSchema.parse(publicMessagePartTextPart),
847
- );
848
- }
849
- export function publicMessagePartTextPartFromJSON(
850
- jsonString: string,
851
- ): SafeParseResult<PublicMessagePartTextPart, SDKValidationError> {
852
- return safeParse(
853
- jsonString,
854
- (x) => PublicMessagePartTextPart$inboundSchema.parse(JSON.parse(x)),
855
- `Failed to parse 'PublicMessagePartTextPart' from JSON`,
856
- );
857
- }
858
-
859
- /** @internal */
860
- export const InvokeAgentPublicMessagePart$inboundSchema: z.ZodType<
861
- InvokeAgentPublicMessagePart,
862
- z.ZodTypeDef,
863
- unknown
864
- > = z.union([
865
- z.lazy(() => PublicMessagePartTextPart$inboundSchema),
866
- z.lazy(() => PublicMessagePartFilePart$inboundSchema),
867
- z.lazy(() => PublicMessagePartToolResultPart$inboundSchema),
868
- ]);
869
- /** @internal */
870
- export type InvokeAgentPublicMessagePart$Outbound =
871
- | PublicMessagePartTextPart$Outbound
872
- | PublicMessagePartFilePart$Outbound
873
- | PublicMessagePartToolResultPart$Outbound;
874
-
875
- /** @internal */
876
- export const InvokeAgentPublicMessagePart$outboundSchema: z.ZodType<
877
- InvokeAgentPublicMessagePart$Outbound,
878
- z.ZodTypeDef,
879
- InvokeAgentPublicMessagePart
880
- > = z.union([
881
- z.lazy(() => PublicMessagePartTextPart$outboundSchema),
882
- z.lazy(() => PublicMessagePartFilePart$outboundSchema),
883
- z.lazy(() => PublicMessagePartToolResultPart$outboundSchema),
884
- ]);
885
-
886
- export function invokeAgentPublicMessagePartToJSON(
887
- invokeAgentPublicMessagePart: InvokeAgentPublicMessagePart,
888
- ): string {
889
- return JSON.stringify(
890
- InvokeAgentPublicMessagePart$outboundSchema.parse(
891
- invokeAgentPublicMessagePart,
892
- ),
893
- );
894
- }
895
- export function invokeAgentPublicMessagePartFromJSON(
896
- jsonString: string,
897
- ): SafeParseResult<InvokeAgentPublicMessagePart, SDKValidationError> {
898
- return safeParse(
899
- jsonString,
900
- (x) => InvokeAgentPublicMessagePart$inboundSchema.parse(JSON.parse(x)),
901
- `Failed to parse 'InvokeAgentPublicMessagePart' from JSON`,
902
- );
903
- }
904
-
905
- /** @internal */
906
- export const InvokeAgentA2AMessage$inboundSchema: z.ZodType<
907
- InvokeAgentA2AMessage,
908
- z.ZodTypeDef,
909
- unknown
910
- > = z.object({
911
- messageId: z.string().optional(),
912
- role: z.union([
913
- InvokeAgentRoleUserMessage$inboundSchema,
914
- InvokeAgentRoleToolMessage$inboundSchema,
915
- ]),
916
- parts: z.array(
917
- z.union([
918
- z.lazy(() => PublicMessagePartTextPart$inboundSchema),
919
- z.lazy(() => PublicMessagePartFilePart$inboundSchema),
920
- z.lazy(() => PublicMessagePartToolResultPart$inboundSchema),
921
- ]),
922
- ),
923
- });
924
- /** @internal */
925
- export type InvokeAgentA2AMessage$Outbound = {
926
- messageId?: string | undefined;
927
- role: string | string;
928
- parts: Array<
929
- | PublicMessagePartTextPart$Outbound
930
- | PublicMessagePartFilePart$Outbound
931
- | PublicMessagePartToolResultPart$Outbound
932
- >;
933
- };
934
-
935
- /** @internal */
936
- export const InvokeAgentA2AMessage$outboundSchema: z.ZodType<
937
- InvokeAgentA2AMessage$Outbound,
938
- z.ZodTypeDef,
939
- InvokeAgentA2AMessage
940
- > = z.object({
941
- messageId: z.string().optional(),
942
- role: z.union([
943
- InvokeAgentRoleUserMessage$outboundSchema,
944
- InvokeAgentRoleToolMessage$outboundSchema,
945
- ]),
946
- parts: z.array(
947
- z.union([
948
- z.lazy(() => PublicMessagePartTextPart$outboundSchema),
949
- z.lazy(() => PublicMessagePartFilePart$outboundSchema),
950
- z.lazy(() => PublicMessagePartToolResultPart$outboundSchema),
951
- ]),
952
- ),
953
- });
954
-
955
- export function invokeAgentA2AMessageToJSON(
956
- invokeAgentA2AMessage: InvokeAgentA2AMessage,
957
- ): string {
958
- return JSON.stringify(
959
- InvokeAgentA2AMessage$outboundSchema.parse(invokeAgentA2AMessage),
960
- );
961
- }
962
- export function invokeAgentA2AMessageFromJSON(
963
- jsonString: string,
964
- ): SafeParseResult<InvokeAgentA2AMessage, SDKValidationError> {
965
- return safeParse(
966
- jsonString,
967
- (x) => InvokeAgentA2AMessage$inboundSchema.parse(JSON.parse(x)),
968
- `Failed to parse 'InvokeAgentA2AMessage' from JSON`,
969
- );
970
- }
971
-
972
- /** @internal */
973
- export const InvokeAgentContact$inboundSchema: z.ZodType<
974
- InvokeAgentContact,
975
- z.ZodTypeDef,
976
- unknown
977
- > = z.object({
978
- id: z.string(),
979
- display_name: z.string().optional(),
980
- email: z.string().optional(),
981
- metadata: z.array(z.record(z.any())).optional(),
982
- logo_url: z.string().optional(),
983
- tags: z.array(z.string()).optional(),
984
- }).transform((v) => {
985
- return remap$(v, {
986
- "display_name": "displayName",
987
- "logo_url": "logoUrl",
988
- });
989
- });
990
- /** @internal */
991
- export type InvokeAgentContact$Outbound = {
992
- id: string;
993
- display_name?: string | undefined;
994
- email?: string | undefined;
995
- metadata?: Array<{ [k: string]: any }> | undefined;
996
- logo_url?: string | undefined;
997
- tags?: Array<string> | undefined;
998
- };
999
-
1000
- /** @internal */
1001
- export const InvokeAgentContact$outboundSchema: z.ZodType<
1002
- InvokeAgentContact$Outbound,
1003
- z.ZodTypeDef,
1004
- InvokeAgentContact
1005
- > = z.object({
1006
- id: z.string(),
1007
- displayName: z.string().optional(),
1008
- email: z.string().optional(),
1009
- metadata: z.array(z.record(z.any())).optional(),
1010
- logoUrl: z.string().optional(),
1011
- tags: z.array(z.string()).optional(),
1012
- }).transform((v) => {
1013
- return remap$(v, {
1014
- displayName: "display_name",
1015
- logoUrl: "logo_url",
1016
- });
1017
- });
1018
-
1019
- export function invokeAgentContactToJSON(
1020
- invokeAgentContact: InvokeAgentContact,
1021
- ): string {
1022
- return JSON.stringify(
1023
- InvokeAgentContact$outboundSchema.parse(invokeAgentContact),
1024
- );
1025
- }
1026
- export function invokeAgentContactFromJSON(
1027
- jsonString: string,
1028
- ): SafeParseResult<InvokeAgentContact, SDKValidationError> {
1029
- return safeParse(
1030
- jsonString,
1031
- (x) => InvokeAgentContact$inboundSchema.parse(JSON.parse(x)),
1032
- `Failed to parse 'InvokeAgentContact' from JSON`,
1033
- );
1034
- }
1035
-
1036
- /** @internal */
1037
- export const InvokeAgentThread$inboundSchema: z.ZodType<
1038
- InvokeAgentThread,
1039
- z.ZodTypeDef,
1040
- unknown
1041
- > = z.object({
1042
- id: z.string(),
1043
- tags: z.array(z.string()).optional(),
1044
- });
1045
- /** @internal */
1046
- export type InvokeAgentThread$Outbound = {
1047
- id: string;
1048
- tags?: Array<string> | undefined;
1049
- };
1050
-
1051
- /** @internal */
1052
- export const InvokeAgentThread$outboundSchema: z.ZodType<
1053
- InvokeAgentThread$Outbound,
1054
- z.ZodTypeDef,
1055
- InvokeAgentThread
1056
- > = z.object({
1057
- id: z.string(),
1058
- tags: z.array(z.string()).optional(),
1059
- });
1060
-
1061
- export function invokeAgentThreadToJSON(
1062
- invokeAgentThread: InvokeAgentThread,
1063
- ): string {
1064
- return JSON.stringify(
1065
- InvokeAgentThread$outboundSchema.parse(invokeAgentThread),
1066
- );
1067
- }
1068
- export function invokeAgentThreadFromJSON(
1069
- jsonString: string,
1070
- ): SafeParseResult<InvokeAgentThread, SDKValidationError> {
1071
- return safeParse(
1072
- jsonString,
1073
- (x) => InvokeAgentThread$inboundSchema.parse(JSON.parse(x)),
1074
- `Failed to parse 'InvokeAgentThread' from JSON`,
1075
- );
1076
- }
1077
-
1078
- /** @internal */
1079
- export const InvokeAgentMemory$inboundSchema: z.ZodType<
1080
- InvokeAgentMemory,
1081
- z.ZodTypeDef,
1082
- unknown
1083
- > = z.object({
1084
- entity_id: z.string(),
1085
- }).transform((v) => {
1086
- return remap$(v, {
1087
- "entity_id": "entityId",
1088
- });
1089
- });
1090
- /** @internal */
1091
- export type InvokeAgentMemory$Outbound = {
1092
- entity_id: string;
1093
- };
1094
-
1095
- /** @internal */
1096
- export const InvokeAgentMemory$outboundSchema: z.ZodType<
1097
- InvokeAgentMemory$Outbound,
1098
- z.ZodTypeDef,
1099
- InvokeAgentMemory
1100
- > = z.object({
1101
- entityId: z.string(),
1102
- }).transform((v) => {
1103
- return remap$(v, {
1104
- entityId: "entity_id",
1105
- });
1106
- });
1107
-
1108
- export function invokeAgentMemoryToJSON(
1109
- invokeAgentMemory: InvokeAgentMemory,
1110
- ): string {
1111
- return JSON.stringify(
1112
- InvokeAgentMemory$outboundSchema.parse(invokeAgentMemory),
1113
- );
1114
- }
1115
- export function invokeAgentMemoryFromJSON(
1116
- jsonString: string,
1117
- ): SafeParseResult<InvokeAgentMemory, SDKValidationError> {
1118
- return safeParse(
1119
- jsonString,
1120
- (x) => InvokeAgentMemory$inboundSchema.parse(JSON.parse(x)),
1121
- `Failed to parse 'InvokeAgentMemory' from JSON`,
1122
- );
1123
- }
1124
-
1125
- /** @internal */
1126
- export const InvokeAgentRequestBody$inboundSchema: z.ZodType<
1127
- InvokeAgentRequestBody,
1128
- z.ZodTypeDef,
1129
- unknown
1130
- > = z.object({
1131
- task_id: z.string().optional(),
1132
- message: z.lazy(() => InvokeAgentA2AMessage$inboundSchema),
1133
- variables: z.record(z.any()).optional(),
1134
- contact: z.lazy(() => InvokeAgentContact$inboundSchema).optional(),
1135
- thread: z.lazy(() => InvokeAgentThread$inboundSchema).optional(),
1136
- memory: z.lazy(() => InvokeAgentMemory$inboundSchema).optional(),
1137
- metadata: z.record(z.any()).optional(),
1138
- }).transform((v) => {
1139
- return remap$(v, {
1140
- "task_id": "taskId",
1141
- });
1142
- });
1143
- /** @internal */
1144
- export type InvokeAgentRequestBody$Outbound = {
1145
- task_id?: string | undefined;
1146
- message: InvokeAgentA2AMessage$Outbound;
1147
- variables?: { [k: string]: any } | undefined;
1148
- contact?: InvokeAgentContact$Outbound | undefined;
1149
- thread?: InvokeAgentThread$Outbound | undefined;
1150
- memory?: InvokeAgentMemory$Outbound | undefined;
1151
- metadata?: { [k: string]: any } | undefined;
1152
- };
1153
-
1154
- /** @internal */
1155
- export const InvokeAgentRequestBody$outboundSchema: z.ZodType<
1156
- InvokeAgentRequestBody$Outbound,
1157
- z.ZodTypeDef,
1158
- InvokeAgentRequestBody
1159
- > = z.object({
1160
- taskId: z.string().optional(),
1161
- message: z.lazy(() => InvokeAgentA2AMessage$outboundSchema),
1162
- variables: z.record(z.any()).optional(),
1163
- contact: z.lazy(() => InvokeAgentContact$outboundSchema).optional(),
1164
- thread: z.lazy(() => InvokeAgentThread$outboundSchema).optional(),
1165
- memory: z.lazy(() => InvokeAgentMemory$outboundSchema).optional(),
1166
- metadata: z.record(z.any()).optional(),
1167
- }).transform((v) => {
1168
- return remap$(v, {
1169
- taskId: "task_id",
1170
- });
1171
- });
1172
-
1173
- export function invokeAgentRequestBodyToJSON(
1174
- invokeAgentRequestBody: InvokeAgentRequestBody,
1175
- ): string {
1176
- return JSON.stringify(
1177
- InvokeAgentRequestBody$outboundSchema.parse(invokeAgentRequestBody),
1178
- );
1179
- }
1180
- export function invokeAgentRequestBodyFromJSON(
1181
- jsonString: string,
1182
- ): SafeParseResult<InvokeAgentRequestBody, SDKValidationError> {
1183
- return safeParse(
1184
- jsonString,
1185
- (x) => InvokeAgentRequestBody$inboundSchema.parse(JSON.parse(x)),
1186
- `Failed to parse 'InvokeAgentRequestBody' from JSON`,
1187
- );
1188
- }
1189
-
1190
- /** @internal */
1191
- export const InvokeAgentRequest$inboundSchema: z.ZodType<
1192
- InvokeAgentRequest,
1193
- z.ZodTypeDef,
1194
- unknown
1195
- > = z.object({
1196
- key: z.string(),
1197
- RequestBody: z.lazy(() => InvokeAgentRequestBody$inboundSchema).optional(),
1198
- }).transform((v) => {
1199
- return remap$(v, {
1200
- "RequestBody": "requestBody",
1201
- });
1202
- });
1203
- /** @internal */
1204
- export type InvokeAgentRequest$Outbound = {
1205
- key: string;
1206
- RequestBody?: InvokeAgentRequestBody$Outbound | undefined;
1207
- };
1208
-
1209
- /** @internal */
1210
- export const InvokeAgentRequest$outboundSchema: z.ZodType<
1211
- InvokeAgentRequest$Outbound,
1212
- z.ZodTypeDef,
1213
- InvokeAgentRequest
1214
- > = z.object({
1215
- key: z.string(),
1216
- requestBody: z.lazy(() => InvokeAgentRequestBody$outboundSchema).optional(),
1217
- }).transform((v) => {
1218
- return remap$(v, {
1219
- requestBody: "RequestBody",
1220
- });
1221
- });
1222
-
1223
- export function invokeAgentRequestToJSON(
1224
- invokeAgentRequest: InvokeAgentRequest,
1225
- ): string {
1226
- return JSON.stringify(
1227
- InvokeAgentRequest$outboundSchema.parse(invokeAgentRequest),
1228
- );
1229
- }
1230
- export function invokeAgentRequestFromJSON(
1231
- jsonString: string,
1232
- ): SafeParseResult<InvokeAgentRequest, SDKValidationError> {
1233
- return safeParse(
1234
- jsonString,
1235
- (x) => InvokeAgentRequest$inboundSchema.parse(JSON.parse(x)),
1236
- `Failed to parse 'InvokeAgentRequest' from JSON`,
1237
- );
1238
- }
1239
-
1240
- /** @internal */
1241
- export const InvokeAgentKind$inboundSchema: z.ZodNativeEnum<
1242
- typeof InvokeAgentKind
1243
- > = z.nativeEnum(InvokeAgentKind);
1244
- /** @internal */
1245
- export const InvokeAgentKind$outboundSchema: z.ZodNativeEnum<
1246
- typeof InvokeAgentKind
1247
- > = InvokeAgentKind$inboundSchema;
1248
-
1249
- /** @internal */
1250
- export const TaskState$inboundSchema: z.ZodNativeEnum<typeof TaskState> = z
1251
- .nativeEnum(TaskState);
1252
- /** @internal */
1253
- export const TaskState$outboundSchema: z.ZodNativeEnum<typeof TaskState> =
1254
- TaskState$inboundSchema;
1255
-
1256
- /** @internal */
1257
- export const InvokeAgentAgentsKind$inboundSchema: z.ZodNativeEnum<
1258
- typeof InvokeAgentAgentsKind
1259
- > = z.nativeEnum(InvokeAgentAgentsKind);
1260
- /** @internal */
1261
- export const InvokeAgentAgentsKind$outboundSchema: z.ZodNativeEnum<
1262
- typeof InvokeAgentAgentsKind
1263
- > = InvokeAgentAgentsKind$inboundSchema;
1264
-
1265
- /** @internal */
1266
- export const ExtendedMessageRole$inboundSchema: z.ZodNativeEnum<
1267
- typeof ExtendedMessageRole
1268
- > = z.nativeEnum(ExtendedMessageRole);
1269
- /** @internal */
1270
- export const ExtendedMessageRole$outboundSchema: z.ZodNativeEnum<
1271
- typeof ExtendedMessageRole
1272
- > = ExtendedMessageRole$inboundSchema;
1273
-
1274
- /** @internal */
1275
- export const InvokeAgentPartsAgentsResponse200Kind$inboundSchema:
1276
- z.ZodNativeEnum<typeof InvokeAgentPartsAgentsResponse200Kind> = z.nativeEnum(
1277
- InvokeAgentPartsAgentsResponse200Kind,
1278
- );
1279
- /** @internal */
1280
- export const InvokeAgentPartsAgentsResponse200Kind$outboundSchema:
1281
- z.ZodNativeEnum<typeof InvokeAgentPartsAgentsResponse200Kind> =
1282
- InvokeAgentPartsAgentsResponse200Kind$inboundSchema;
1283
-
1284
- /** @internal */
1285
- export const PartsToolResultPart$inboundSchema: z.ZodType<
1286
- PartsToolResultPart,
1287
- z.ZodTypeDef,
1288
- unknown
1289
- > = z.object({
1290
- kind: InvokeAgentPartsAgentsResponse200Kind$inboundSchema,
1291
- tool_call_id: z.string(),
1292
- result: z.any().optional(),
1293
- metadata: z.record(z.any()).optional(),
1294
- }).transform((v) => {
1295
- return remap$(v, {
1296
- "tool_call_id": "toolCallId",
1297
- });
1298
- });
1299
- /** @internal */
1300
- export type PartsToolResultPart$Outbound = {
1301
- kind: string;
1302
- tool_call_id: string;
1303
- result?: any | undefined;
1304
- metadata?: { [k: string]: any } | undefined;
1305
- };
1306
-
1307
- /** @internal */
1308
- export const PartsToolResultPart$outboundSchema: z.ZodType<
1309
- PartsToolResultPart$Outbound,
1310
- z.ZodTypeDef,
1311
- PartsToolResultPart
1312
- > = z.object({
1313
- kind: InvokeAgentPartsAgentsResponse200Kind$outboundSchema,
1314
- toolCallId: z.string(),
1315
- result: z.any().optional(),
1316
- metadata: z.record(z.any()).optional(),
1317
- }).transform((v) => {
1318
- return remap$(v, {
1319
- toolCallId: "tool_call_id",
1320
- });
1321
- });
1322
-
1323
- export function partsToolResultPartToJSON(
1324
- partsToolResultPart: PartsToolResultPart,
1325
- ): string {
1326
- return JSON.stringify(
1327
- PartsToolResultPart$outboundSchema.parse(partsToolResultPart),
1328
- );
1329
- }
1330
- export function partsToolResultPartFromJSON(
1331
- jsonString: string,
1332
- ): SafeParseResult<PartsToolResultPart, SDKValidationError> {
1333
- return safeParse(
1334
- jsonString,
1335
- (x) => PartsToolResultPart$inboundSchema.parse(JSON.parse(x)),
1336
- `Failed to parse 'PartsToolResultPart' from JSON`,
1337
- );
1338
- }
1339
-
1340
- /** @internal */
1341
- export const InvokeAgentPartsAgentsResponseKind$inboundSchema: z.ZodNativeEnum<
1342
- typeof InvokeAgentPartsAgentsResponseKind
1343
- > = z.nativeEnum(InvokeAgentPartsAgentsResponseKind);
1344
- /** @internal */
1345
- export const InvokeAgentPartsAgentsResponseKind$outboundSchema: z.ZodNativeEnum<
1346
- typeof InvokeAgentPartsAgentsResponseKind
1347
- > = InvokeAgentPartsAgentsResponseKind$inboundSchema;
1348
-
1349
- /** @internal */
1350
- export const ToolCallPart$inboundSchema: z.ZodType<
1351
- ToolCallPart,
1352
- z.ZodTypeDef,
1353
- unknown
1354
- > = z.object({
1355
- kind: InvokeAgentPartsAgentsResponseKind$inboundSchema,
1356
- tool_name: z.string(),
1357
- tool_call_id: z.string(),
1358
- arguments: z.record(z.any()),
1359
- metadata: z.record(z.any()).optional(),
1360
- }).transform((v) => {
1361
- return remap$(v, {
1362
- "tool_name": "toolName",
1363
- "tool_call_id": "toolCallId",
1364
- });
1365
- });
1366
- /** @internal */
1367
- export type ToolCallPart$Outbound = {
1368
- kind: string;
1369
- tool_name: string;
1370
- tool_call_id: string;
1371
- arguments: { [k: string]: any };
1372
- metadata?: { [k: string]: any } | undefined;
1373
- };
1374
-
1375
- /** @internal */
1376
- export const ToolCallPart$outboundSchema: z.ZodType<
1377
- ToolCallPart$Outbound,
1378
- z.ZodTypeDef,
1379
- ToolCallPart
1380
- > = z.object({
1381
- kind: InvokeAgentPartsAgentsResponseKind$outboundSchema,
1382
- toolName: z.string(),
1383
- toolCallId: z.string(),
1384
- arguments: z.record(z.any()),
1385
- metadata: z.record(z.any()).optional(),
1386
- }).transform((v) => {
1387
- return remap$(v, {
1388
- toolName: "tool_name",
1389
- toolCallId: "tool_call_id",
1390
- });
1391
- });
1392
-
1393
- export function toolCallPartToJSON(toolCallPart: ToolCallPart): string {
1394
- return JSON.stringify(ToolCallPart$outboundSchema.parse(toolCallPart));
1395
- }
1396
- export function toolCallPartFromJSON(
1397
- jsonString: string,
1398
- ): SafeParseResult<ToolCallPart, SDKValidationError> {
1399
- return safeParse(
1400
- jsonString,
1401
- (x) => ToolCallPart$inboundSchema.parse(JSON.parse(x)),
1402
- `Failed to parse 'ToolCallPart' from JSON`,
1403
- );
1404
- }
1405
-
1406
- /** @internal */
1407
- export const InvokeAgentPartsAgentsKind$inboundSchema: z.ZodNativeEnum<
1408
- typeof InvokeAgentPartsAgentsKind
1409
- > = z.nativeEnum(InvokeAgentPartsAgentsKind);
1410
- /** @internal */
1411
- export const InvokeAgentPartsAgentsKind$outboundSchema: z.ZodNativeEnum<
1412
- typeof InvokeAgentPartsAgentsKind
1413
- > = InvokeAgentPartsAgentsKind$inboundSchema;
1414
-
1415
- /** @internal */
1416
- export const InvokeAgentFileFileInURIFormat$inboundSchema: z.ZodType<
1417
- InvokeAgentFileFileInURIFormat,
1418
- z.ZodTypeDef,
1419
- unknown
1420
- > = z.object({
1421
- uri: z.string(),
1422
- mimeType: z.string().optional(),
1423
- name: z.string().optional(),
1424
- });
1425
- /** @internal */
1426
- export type InvokeAgentFileFileInURIFormat$Outbound = {
1427
- uri: string;
1428
- mimeType?: string | undefined;
1429
- name?: string | undefined;
1430
- };
1431
-
1432
- /** @internal */
1433
- export const InvokeAgentFileFileInURIFormat$outboundSchema: z.ZodType<
1434
- InvokeAgentFileFileInURIFormat$Outbound,
1435
- z.ZodTypeDef,
1436
- InvokeAgentFileFileInURIFormat
1437
- > = z.object({
1438
- uri: z.string(),
1439
- mimeType: z.string().optional(),
1440
- name: z.string().optional(),
1441
- });
1442
-
1443
- export function invokeAgentFileFileInURIFormatToJSON(
1444
- invokeAgentFileFileInURIFormat: InvokeAgentFileFileInURIFormat,
1445
- ): string {
1446
- return JSON.stringify(
1447
- InvokeAgentFileFileInURIFormat$outboundSchema.parse(
1448
- invokeAgentFileFileInURIFormat,
1449
- ),
1450
- );
1451
- }
1452
- export function invokeAgentFileFileInURIFormatFromJSON(
1453
- jsonString: string,
1454
- ): SafeParseResult<InvokeAgentFileFileInURIFormat, SDKValidationError> {
1455
- return safeParse(
1456
- jsonString,
1457
- (x) => InvokeAgentFileFileInURIFormat$inboundSchema.parse(JSON.parse(x)),
1458
- `Failed to parse 'InvokeAgentFileFileInURIFormat' from JSON`,
1459
- );
1460
- }
1461
-
1462
- /** @internal */
1463
- export const InvokeAgentFileBinaryFormat$inboundSchema: z.ZodType<
1464
- InvokeAgentFileBinaryFormat,
1465
- z.ZodTypeDef,
1466
- unknown
1467
- > = z.object({
1468
- bytes: z.string(),
1469
- mimeType: z.string().optional(),
1470
- name: z.string().optional(),
1471
- });
1472
- /** @internal */
1473
- export type InvokeAgentFileBinaryFormat$Outbound = {
1474
- bytes: string;
1475
- mimeType?: string | undefined;
1476
- name?: string | undefined;
1477
- };
1478
-
1479
- /** @internal */
1480
- export const InvokeAgentFileBinaryFormat$outboundSchema: z.ZodType<
1481
- InvokeAgentFileBinaryFormat$Outbound,
1482
- z.ZodTypeDef,
1483
- InvokeAgentFileBinaryFormat
1484
- > = z.object({
1485
- bytes: z.string(),
1486
- mimeType: z.string().optional(),
1487
- name: z.string().optional(),
1488
- });
1489
-
1490
- export function invokeAgentFileBinaryFormatToJSON(
1491
- invokeAgentFileBinaryFormat: InvokeAgentFileBinaryFormat,
1492
- ): string {
1493
- return JSON.stringify(
1494
- InvokeAgentFileBinaryFormat$outboundSchema.parse(
1495
- invokeAgentFileBinaryFormat,
1496
- ),
1497
- );
1498
- }
1499
- export function invokeAgentFileBinaryFormatFromJSON(
1500
- jsonString: string,
1501
- ): SafeParseResult<InvokeAgentFileBinaryFormat, SDKValidationError> {
1502
- return safeParse(
1503
- jsonString,
1504
- (x) => InvokeAgentFileBinaryFormat$inboundSchema.parse(JSON.parse(x)),
1505
- `Failed to parse 'InvokeAgentFileBinaryFormat' from JSON`,
1506
- );
1507
- }
1508
-
1509
- /** @internal */
1510
- export const PartsFile$inboundSchema: z.ZodType<
1511
- PartsFile,
1512
- z.ZodTypeDef,
1513
- unknown
1514
- > = z.union([
1515
- z.lazy(() => InvokeAgentFileBinaryFormat$inboundSchema),
1516
- z.lazy(() => InvokeAgentFileFileInURIFormat$inboundSchema),
1517
- ]);
1518
- /** @internal */
1519
- export type PartsFile$Outbound =
1520
- | InvokeAgentFileBinaryFormat$Outbound
1521
- | InvokeAgentFileFileInURIFormat$Outbound;
1522
-
1523
- /** @internal */
1524
- export const PartsFile$outboundSchema: z.ZodType<
1525
- PartsFile$Outbound,
1526
- z.ZodTypeDef,
1527
- PartsFile
1528
- > = z.union([
1529
- z.lazy(() => InvokeAgentFileBinaryFormat$outboundSchema),
1530
- z.lazy(() => InvokeAgentFileFileInURIFormat$outboundSchema),
1531
- ]);
1532
-
1533
- export function partsFileToJSON(partsFile: PartsFile): string {
1534
- return JSON.stringify(PartsFile$outboundSchema.parse(partsFile));
1535
- }
1536
- export function partsFileFromJSON(
1537
- jsonString: string,
1538
- ): SafeParseResult<PartsFile, SDKValidationError> {
1539
- return safeParse(
1540
- jsonString,
1541
- (x) => PartsFile$inboundSchema.parse(JSON.parse(x)),
1542
- `Failed to parse 'PartsFile' from JSON`,
1543
- );
1544
- }
1545
-
1546
- /** @internal */
1547
- export const PartsFilePart$inboundSchema: z.ZodType<
1548
- PartsFilePart,
1549
- z.ZodTypeDef,
1550
- unknown
1551
- > = z.object({
1552
- kind: InvokeAgentPartsAgentsKind$inboundSchema,
1553
- file: z.union([
1554
- z.lazy(() => InvokeAgentFileBinaryFormat$inboundSchema),
1555
- z.lazy(() => InvokeAgentFileFileInURIFormat$inboundSchema),
1556
- ]),
1557
- metadata: z.record(z.any()).optional(),
1558
- });
1559
- /** @internal */
1560
- export type PartsFilePart$Outbound = {
1561
- kind: string;
1562
- file:
1563
- | InvokeAgentFileBinaryFormat$Outbound
1564
- | InvokeAgentFileFileInURIFormat$Outbound;
1565
- metadata?: { [k: string]: any } | undefined;
1566
- };
1567
-
1568
- /** @internal */
1569
- export const PartsFilePart$outboundSchema: z.ZodType<
1570
- PartsFilePart$Outbound,
1571
- z.ZodTypeDef,
1572
- PartsFilePart
1573
- > = z.object({
1574
- kind: InvokeAgentPartsAgentsKind$outboundSchema,
1575
- file: z.union([
1576
- z.lazy(() => InvokeAgentFileBinaryFormat$outboundSchema),
1577
- z.lazy(() => InvokeAgentFileFileInURIFormat$outboundSchema),
1578
- ]),
1579
- metadata: z.record(z.any()).optional(),
1580
- });
1581
-
1582
- export function partsFilePartToJSON(partsFilePart: PartsFilePart): string {
1583
- return JSON.stringify(PartsFilePart$outboundSchema.parse(partsFilePart));
1584
- }
1585
- export function partsFilePartFromJSON(
1586
- jsonString: string,
1587
- ): SafeParseResult<PartsFilePart, SDKValidationError> {
1588
- return safeParse(
1589
- jsonString,
1590
- (x) => PartsFilePart$inboundSchema.parse(JSON.parse(x)),
1591
- `Failed to parse 'PartsFilePart' from JSON`,
1592
- );
1593
- }
1594
-
1595
- /** @internal */
1596
- export const InvokeAgentPartsKind$inboundSchema: z.ZodNativeEnum<
1597
- typeof InvokeAgentPartsKind
1598
- > = z.nativeEnum(InvokeAgentPartsKind);
1599
- /** @internal */
1600
- export const InvokeAgentPartsKind$outboundSchema: z.ZodNativeEnum<
1601
- typeof InvokeAgentPartsKind
1602
- > = InvokeAgentPartsKind$inboundSchema;
1603
-
1604
- /** @internal */
1605
- export const DataPart$inboundSchema: z.ZodType<
1606
- DataPart,
1607
- z.ZodTypeDef,
1608
- unknown
1609
- > = z.object({
1610
- kind: InvokeAgentPartsKind$inboundSchema,
1611
- data: z.record(z.any()),
1612
- metadata: z.record(z.any()).optional(),
1613
- });
1614
- /** @internal */
1615
- export type DataPart$Outbound = {
1616
- kind: string;
1617
- data: { [k: string]: any };
1618
- metadata?: { [k: string]: any } | undefined;
1619
- };
1620
-
1621
- /** @internal */
1622
- export const DataPart$outboundSchema: z.ZodType<
1623
- DataPart$Outbound,
1624
- z.ZodTypeDef,
1625
- DataPart
1626
- > = z.object({
1627
- kind: InvokeAgentPartsKind$outboundSchema,
1628
- data: z.record(z.any()),
1629
- metadata: z.record(z.any()).optional(),
1630
- });
1631
-
1632
- export function dataPartToJSON(dataPart: DataPart): string {
1633
- return JSON.stringify(DataPart$outboundSchema.parse(dataPart));
1634
- }
1635
- export function dataPartFromJSON(
1636
- jsonString: string,
1637
- ): SafeParseResult<DataPart, SDKValidationError> {
1638
- return safeParse(
1639
- jsonString,
1640
- (x) => DataPart$inboundSchema.parse(JSON.parse(x)),
1641
- `Failed to parse 'DataPart' from JSON`,
1642
- );
1643
- }
1644
-
1645
- /** @internal */
1646
- export const PartsKind$inboundSchema: z.ZodNativeEnum<typeof PartsKind> = z
1647
- .nativeEnum(PartsKind);
1648
- /** @internal */
1649
- export const PartsKind$outboundSchema: z.ZodNativeEnum<typeof PartsKind> =
1650
- PartsKind$inboundSchema;
1651
-
1652
- /** @internal */
1653
- export const PartsTextPart$inboundSchema: z.ZodType<
1654
- PartsTextPart,
1655
- z.ZodTypeDef,
1656
- unknown
1657
- > = z.object({
1658
- kind: PartsKind$inboundSchema,
1659
- text: z.string(),
1660
- });
1661
- /** @internal */
1662
- export type PartsTextPart$Outbound = {
1663
- kind: string;
1664
- text: string;
1665
- };
1666
-
1667
- /** @internal */
1668
- export const PartsTextPart$outboundSchema: z.ZodType<
1669
- PartsTextPart$Outbound,
1670
- z.ZodTypeDef,
1671
- PartsTextPart
1672
- > = z.object({
1673
- kind: PartsKind$outboundSchema,
1674
- text: z.string(),
1675
- });
1676
-
1677
- export function partsTextPartToJSON(partsTextPart: PartsTextPart): string {
1678
- return JSON.stringify(PartsTextPart$outboundSchema.parse(partsTextPart));
1679
- }
1680
- export function partsTextPartFromJSON(
1681
- jsonString: string,
1682
- ): SafeParseResult<PartsTextPart, SDKValidationError> {
1683
- return safeParse(
1684
- jsonString,
1685
- (x) => PartsTextPart$inboundSchema.parse(JSON.parse(x)),
1686
- `Failed to parse 'PartsTextPart' from JSON`,
1687
- );
1688
- }
1689
-
1690
- /** @internal */
1691
- export const Parts$inboundSchema: z.ZodType<Parts, z.ZodTypeDef, unknown> = z
1692
- .union([
1693
- z.lazy(() => ToolCallPart$inboundSchema),
1694
- z.lazy(() => PartsTextPart$inboundSchema),
1695
- z.lazy(() => DataPart$inboundSchema),
1696
- z.lazy(() => PartsFilePart$inboundSchema),
1697
- z.lazy(() => PartsToolResultPart$inboundSchema),
1698
- ]);
1699
- /** @internal */
1700
- export type Parts$Outbound =
1701
- | ToolCallPart$Outbound
1702
- | PartsTextPart$Outbound
1703
- | DataPart$Outbound
1704
- | PartsFilePart$Outbound
1705
- | PartsToolResultPart$Outbound;
1706
-
1707
- /** @internal */
1708
- export const Parts$outboundSchema: z.ZodType<
1709
- Parts$Outbound,
1710
- z.ZodTypeDef,
1711
- Parts
1712
- > = z.union([
1713
- z.lazy(() => ToolCallPart$outboundSchema),
1714
- z.lazy(() => PartsTextPart$outboundSchema),
1715
- z.lazy(() => DataPart$outboundSchema),
1716
- z.lazy(() => PartsFilePart$outboundSchema),
1717
- z.lazy(() => PartsToolResultPart$outboundSchema),
1718
- ]);
1719
-
1720
- export function partsToJSON(parts: Parts): string {
1721
- return JSON.stringify(Parts$outboundSchema.parse(parts));
1722
- }
1723
- export function partsFromJSON(
1724
- jsonString: string,
1725
- ): SafeParseResult<Parts, SDKValidationError> {
1726
- return safeParse(
1727
- jsonString,
1728
- (x) => Parts$inboundSchema.parse(JSON.parse(x)),
1729
- `Failed to parse 'Parts' from JSON`,
1730
- );
1731
- }
1732
-
1733
- /** @internal */
1734
- export const TaskStatusMessage$inboundSchema: z.ZodType<
1735
- TaskStatusMessage,
1736
- z.ZodTypeDef,
1737
- unknown
1738
- > = z.object({
1739
- kind: InvokeAgentAgentsKind$inboundSchema,
1740
- messageId: z.string(),
1741
- role: ExtendedMessageRole$inboundSchema,
1742
- parts: z.array(
1743
- z.union([
1744
- z.lazy(() => ToolCallPart$inboundSchema),
1745
- z.lazy(() => PartsTextPart$inboundSchema),
1746
- z.lazy(() => DataPart$inboundSchema),
1747
- z.lazy(() => PartsFilePart$inboundSchema),
1748
- z.lazy(() => PartsToolResultPart$inboundSchema),
1749
- ]),
1750
- ),
1751
- });
1752
- /** @internal */
1753
- export type TaskStatusMessage$Outbound = {
1754
- kind: string;
1755
- messageId: string;
1756
- role: string;
1757
- parts: Array<
1758
- | ToolCallPart$Outbound
1759
- | PartsTextPart$Outbound
1760
- | DataPart$Outbound
1761
- | PartsFilePart$Outbound
1762
- | PartsToolResultPart$Outbound
1763
- >;
1764
- };
1765
-
1766
- /** @internal */
1767
- export const TaskStatusMessage$outboundSchema: z.ZodType<
1768
- TaskStatusMessage$Outbound,
1769
- z.ZodTypeDef,
1770
- TaskStatusMessage
1771
- > = z.object({
1772
- kind: InvokeAgentAgentsKind$outboundSchema,
1773
- messageId: z.string(),
1774
- role: ExtendedMessageRole$outboundSchema,
1775
- parts: z.array(
1776
- z.union([
1777
- z.lazy(() => ToolCallPart$outboundSchema),
1778
- z.lazy(() => PartsTextPart$outboundSchema),
1779
- z.lazy(() => DataPart$outboundSchema),
1780
- z.lazy(() => PartsFilePart$outboundSchema),
1781
- z.lazy(() => PartsToolResultPart$outboundSchema),
1782
- ]),
1783
- ),
1784
- });
1785
-
1786
- export function taskStatusMessageToJSON(
1787
- taskStatusMessage: TaskStatusMessage,
1788
- ): string {
1789
- return JSON.stringify(
1790
- TaskStatusMessage$outboundSchema.parse(taskStatusMessage),
1791
- );
1792
- }
1793
- export function taskStatusMessageFromJSON(
1794
- jsonString: string,
1795
- ): SafeParseResult<TaskStatusMessage, SDKValidationError> {
1796
- return safeParse(
1797
- jsonString,
1798
- (x) => TaskStatusMessage$inboundSchema.parse(JSON.parse(x)),
1799
- `Failed to parse 'TaskStatusMessage' from JSON`,
1800
- );
1801
- }
1802
-
1803
- /** @internal */
1804
- export const TaskStatus$inboundSchema: z.ZodType<
1805
- TaskStatus,
1806
- z.ZodTypeDef,
1807
- unknown
1808
- > = z.object({
1809
- state: TaskState$inboundSchema,
1810
- timestamp: z.string().optional(),
1811
- message: z.lazy(() => TaskStatusMessage$inboundSchema).optional(),
1812
- });
1813
- /** @internal */
1814
- export type TaskStatus$Outbound = {
1815
- state: string;
1816
- timestamp?: string | undefined;
1817
- message?: TaskStatusMessage$Outbound | undefined;
1818
- };
1819
-
1820
- /** @internal */
1821
- export const TaskStatus$outboundSchema: z.ZodType<
1822
- TaskStatus$Outbound,
1823
- z.ZodTypeDef,
1824
- TaskStatus
1825
- > = z.object({
1826
- state: TaskState$outboundSchema,
1827
- timestamp: z.string().optional(),
1828
- message: z.lazy(() => TaskStatusMessage$outboundSchema).optional(),
1829
- });
1830
-
1831
- export function taskStatusToJSON(taskStatus: TaskStatus): string {
1832
- return JSON.stringify(TaskStatus$outboundSchema.parse(taskStatus));
1833
- }
1834
- export function taskStatusFromJSON(
1835
- jsonString: string,
1836
- ): SafeParseResult<TaskStatus, SDKValidationError> {
1837
- return safeParse(
1838
- jsonString,
1839
- (x) => TaskStatus$inboundSchema.parse(JSON.parse(x)),
1840
- `Failed to parse 'TaskStatus' from JSON`,
1841
- );
1842
- }
1843
-
1844
- /** @internal */
1845
- export const InvokeAgentA2ATaskResponse$inboundSchema: z.ZodType<
1846
- InvokeAgentA2ATaskResponse,
1847
- z.ZodTypeDef,
1848
- unknown
1849
- > = z.object({
1850
- id: z.string(),
1851
- contextId: z.string(),
1852
- kind: InvokeAgentKind$inboundSchema,
1853
- status: z.lazy(() => TaskStatus$inboundSchema),
1854
- metadata: z.record(z.any()).optional(),
1855
- });
1856
- /** @internal */
1857
- export type InvokeAgentA2ATaskResponse$Outbound = {
1858
- id: string;
1859
- contextId: string;
1860
- kind: string;
1861
- status: TaskStatus$Outbound;
1862
- metadata?: { [k: string]: any } | undefined;
1863
- };
1864
-
1865
- /** @internal */
1866
- export const InvokeAgentA2ATaskResponse$outboundSchema: z.ZodType<
1867
- InvokeAgentA2ATaskResponse$Outbound,
1868
- z.ZodTypeDef,
1869
- InvokeAgentA2ATaskResponse
1870
- > = z.object({
1871
- id: z.string(),
1872
- contextId: z.string(),
1873
- kind: InvokeAgentKind$outboundSchema,
1874
- status: z.lazy(() => TaskStatus$outboundSchema),
1875
- metadata: z.record(z.any()).optional(),
1876
- });
1877
-
1878
- export function invokeAgentA2ATaskResponseToJSON(
1879
- invokeAgentA2ATaskResponse: InvokeAgentA2ATaskResponse,
1880
- ): string {
1881
- return JSON.stringify(
1882
- InvokeAgentA2ATaskResponse$outboundSchema.parse(invokeAgentA2ATaskResponse),
1883
- );
1884
- }
1885
- export function invokeAgentA2ATaskResponseFromJSON(
1886
- jsonString: string,
1887
- ): SafeParseResult<InvokeAgentA2ATaskResponse, SDKValidationError> {
1888
- return safeParse(
1889
- jsonString,
1890
- (x) => InvokeAgentA2ATaskResponse$inboundSchema.parse(JSON.parse(x)),
1891
- `Failed to parse 'InvokeAgentA2ATaskResponse' from JSON`,
1892
- );
1893
- }