@orq-ai/node 4.0.2 → 4.1.0-rc.0

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 (497) 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 -910
  85. package/packages/orq-rc/RUNTIMES.md +0 -48
  86. package/packages/orq-rc/docs/sdks/agents/README.md +0 -1363
  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 -139
  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 -172
  112. package/packages/orq-rc/src/funcs/agentsDelete.ts +0 -176
  113. package/packages/orq-rc/src/funcs/agentsInvoke.ts +0 -167
  114. package/packages/orq-rc/src/funcs/agentsList.ts +0 -167
  115. package/packages/orq-rc/src/funcs/agentsListActions.ts +0 -169
  116. package/packages/orq-rc/src/funcs/agentsListTasks.ts +0 -183
  117. package/packages/orq-rc/src/funcs/agentsResponsesCreate.ts +0 -168
  118. package/packages/orq-rc/src/funcs/agentsRetrieve.ts +0 -175
  119. package/packages/orq-rc/src/funcs/agentsRetrieveAction.ts +0 -173
  120. package/packages/orq-rc/src/funcs/agentsRetrieveTask.ts +0 -179
  121. package/packages/orq-rc/src/funcs/agentsRun.ts +0 -163
  122. package/packages/orq-rc/src/funcs/agentsStream.ts +0 -191
  123. package/packages/orq-rc/src/funcs/agentsStreamRun.ts +0 -189
  124. package/packages/orq-rc/src/funcs/agentsUpdate.ts +0 -176
  125. package/packages/orq-rc/src/funcs/budgetsCreate.ts +0 -160
  126. package/packages/orq-rc/src/funcs/budgetsDelete.ts +0 -167
  127. package/packages/orq-rc/src/funcs/budgetsGet.ts +0 -166
  128. package/packages/orq-rc/src/funcs/budgetsList.ts +0 -170
  129. package/packages/orq-rc/src/funcs/budgetsUpdate.ts +0 -167
  130. package/packages/orq-rc/src/funcs/chunkingParse.ts +0 -160
  131. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -165
  132. package/packages/orq-rc/src/funcs/contactsDelete.ts +0 -176
  133. package/packages/orq-rc/src/funcs/contactsList.ts +0 -169
  134. package/packages/orq-rc/src/funcs/contactsRetrieve.ts +0 -175
  135. package/packages/orq-rc/src/funcs/contactsUpdate.ts +0 -176
  136. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -167
  137. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -165
  138. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -171
  139. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -167
  140. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -182
  141. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -167
  142. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -174
  143. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -175
  144. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -181
  145. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -176
  146. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -179
  147. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -168
  148. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -176
  149. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -176
  150. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -168
  151. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -183
  152. package/packages/orq-rc/src/funcs/evalsAll.ts +0 -173
  153. package/packages/orq-rc/src/funcs/evalsCreate.ts +0 -169
  154. package/packages/orq-rc/src/funcs/evalsDelete.ts +0 -173
  155. package/packages/orq-rc/src/funcs/evalsUpdate.ts +0 -173
  156. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -160
  157. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -187
  158. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -164
  159. package/packages/orq-rc/src/funcs/filesGet.ts +0 -166
  160. package/packages/orq-rc/src/funcs/filesList.ts +0 -167
  161. package/packages/orq-rc/src/funcs/knowledgeCreate.ts +0 -158
  162. package/packages/orq-rc/src/funcs/knowledgeCreateChunks.ts +0 -171
  163. package/packages/orq-rc/src/funcs/knowledgeCreateDatasource.ts +0 -166
  164. package/packages/orq-rc/src/funcs/knowledgeDelete.ts +0 -167
  165. package/packages/orq-rc/src/funcs/knowledgeDeleteChunk.ts +0 -174
  166. package/packages/orq-rc/src/funcs/knowledgeDeleteChunks.ts +0 -170
  167. package/packages/orq-rc/src/funcs/knowledgeDeleteDatasource.ts +0 -173
  168. package/packages/orq-rc/src/funcs/knowledgeGetChunksCount.ts +0 -170
  169. package/packages/orq-rc/src/funcs/knowledgeList.ts +0 -169
  170. package/packages/orq-rc/src/funcs/knowledgeListChunks.ts +0 -178
  171. package/packages/orq-rc/src/funcs/knowledgeListChunksPaginated.ts +0 -171
  172. package/packages/orq-rc/src/funcs/knowledgeListDatasources.ts +0 -174
  173. package/packages/orq-rc/src/funcs/knowledgeRetrieve.ts +0 -166
  174. package/packages/orq-rc/src/funcs/knowledgeRetrieveChunk.ts +0 -173
  175. package/packages/orq-rc/src/funcs/knowledgeRetrieveDatasource.ts +0 -169
  176. package/packages/orq-rc/src/funcs/knowledgeSearch.ts +0 -167
  177. package/packages/orq-rc/src/funcs/knowledgeUpdate.ts +0 -164
  178. package/packages/orq-rc/src/funcs/knowledgeUpdateChunk.ts +0 -174
  179. package/packages/orq-rc/src/funcs/knowledgeUpdateDatasource.ts +0 -170
  180. package/packages/orq-rc/src/funcs/memoryStoresCreate.ts +0 -162
  181. package/packages/orq-rc/src/funcs/memoryStoresCreateDocument.ts +0 -175
  182. package/packages/orq-rc/src/funcs/memoryStoresCreateMemory.ts +0 -170
  183. package/packages/orq-rc/src/funcs/memoryStoresDelete.ts +0 -168
  184. package/packages/orq-rc/src/funcs/memoryStoresDeleteDocument.ts +0 -184
  185. package/packages/orq-rc/src/funcs/memoryStoresDeleteMemory.ts +0 -179
  186. package/packages/orq-rc/src/funcs/memoryStoresList.ts +0 -178
  187. package/packages/orq-rc/src/funcs/memoryStoresListDocuments.ts +0 -181
  188. package/packages/orq-rc/src/funcs/memoryStoresListMemories.ts +0 -176
  189. package/packages/orq-rc/src/funcs/memoryStoresRetrieve.ts +0 -177
  190. package/packages/orq-rc/src/funcs/memoryStoresRetrieveDocument.ts +0 -178
  191. package/packages/orq-rc/src/funcs/memoryStoresRetrieveMemory.ts +0 -173
  192. package/packages/orq-rc/src/funcs/memoryStoresUpdate.ts +0 -168
  193. package/packages/orq-rc/src/funcs/memoryStoresUpdateDocument.ts +0 -179
  194. package/packages/orq-rc/src/funcs/memoryStoresUpdateMemory.ts +0 -174
  195. package/packages/orq-rc/src/funcs/modelsList.ts +0 -142
  196. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -160
  197. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -164
  198. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -181
  199. package/packages/orq-rc/src/funcs/promptsList.ts +0 -167
  200. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -173
  201. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -166
  202. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -173
  203. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -161
  204. package/packages/orq-rc/src/funcs/toolsCreate.ts +0 -172
  205. package/packages/orq-rc/src/funcs/toolsDelete.ts +0 -167
  206. package/packages/orq-rc/src/funcs/toolsList.ts +0 -176
  207. package/packages/orq-rc/src/funcs/toolsRetrieve.ts +0 -166
  208. package/packages/orq-rc/src/funcs/toolsUpdate.ts +0 -176
  209. package/packages/orq-rc/src/hooks/global.ts +0 -44
  210. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  211. package/packages/orq-rc/src/hooks/index.ts +0 -6
  212. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  213. package/packages/orq-rc/src/hooks/types.ts +0 -112
  214. package/packages/orq-rc/src/index.ts +0 -9
  215. package/packages/orq-rc/src/lib/base64.ts +0 -37
  216. package/packages/orq-rc/src/lib/config.ts +0 -74
  217. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  218. package/packages/orq-rc/src/lib/encodings.ts +0 -483
  219. package/packages/orq-rc/src/lib/env.ts +0 -89
  220. package/packages/orq-rc/src/lib/event-streams.ts +0 -135
  221. package/packages/orq-rc/src/lib/files.ts +0 -82
  222. package/packages/orq-rc/src/lib/http.ts +0 -323
  223. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  224. package/packages/orq-rc/src/lib/logger.ts +0 -9
  225. package/packages/orq-rc/src/lib/matchers.ts +0 -345
  226. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  227. package/packages/orq-rc/src/lib/retries.ts +0 -218
  228. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  229. package/packages/orq-rc/src/lib/sdks.ts +0 -407
  230. package/packages/orq-rc/src/lib/security.ts +0 -264
  231. package/packages/orq-rc/src/lib/url.ts +0 -33
  232. package/packages/orq-rc/src/mcp-server/cli/start/command.ts +0 -111
  233. package/packages/orq-rc/src/mcp-server/cli/start/impl.ts +0 -136
  234. package/packages/orq-rc/src/mcp-server/cli.ts +0 -13
  235. package/packages/orq-rc/src/mcp-server/console-logger.ts +0 -71
  236. package/packages/orq-rc/src/mcp-server/extensions.ts +0 -17
  237. package/packages/orq-rc/src/mcp-server/mcp-server.ts +0 -26
  238. package/packages/orq-rc/src/mcp-server/prompts.ts +0 -117
  239. package/packages/orq-rc/src/mcp-server/resources.ts +0 -172
  240. package/packages/orq-rc/src/mcp-server/scopes.ts +0 -7
  241. package/packages/orq-rc/src/mcp-server/server.ts +0 -259
  242. package/packages/orq-rc/src/mcp-server/shared.ts +0 -74
  243. package/packages/orq-rc/src/mcp-server/tools/agentsCreate.ts +0 -37
  244. package/packages/orq-rc/src/mcp-server/tools/agentsDelete.ts +0 -35
  245. package/packages/orq-rc/src/mcp-server/tools/agentsInvoke.ts +0 -37
  246. package/packages/orq-rc/src/mcp-server/tools/agentsList.ts +0 -37
  247. package/packages/orq-rc/src/mcp-server/tools/agentsListActions.ts +0 -35
  248. package/packages/orq-rc/src/mcp-server/tools/agentsListTasks.ts +0 -37
  249. package/packages/orq-rc/src/mcp-server/tools/agentsResponsesCreate.ts +0 -37
  250. package/packages/orq-rc/src/mcp-server/tools/agentsRetrieve.ts +0 -37
  251. package/packages/orq-rc/src/mcp-server/tools/agentsRetrieveAction.ts +0 -35
  252. package/packages/orq-rc/src/mcp-server/tools/agentsRetrieveTask.ts +0 -37
  253. package/packages/orq-rc/src/mcp-server/tools/agentsRun.ts +0 -37
  254. package/packages/orq-rc/src/mcp-server/tools/agentsStream.ts +0 -37
  255. package/packages/orq-rc/src/mcp-server/tools/agentsStreamRun.ts +0 -37
  256. package/packages/orq-rc/src/mcp-server/tools/agentsUpdate.ts +0 -37
  257. package/packages/orq-rc/src/mcp-server/tools/budgetsCreate.ts +0 -37
  258. package/packages/orq-rc/src/mcp-server/tools/budgetsDelete.ts +0 -35
  259. package/packages/orq-rc/src/mcp-server/tools/budgetsGet.ts +0 -37
  260. package/packages/orq-rc/src/mcp-server/tools/budgetsList.ts +0 -37
  261. package/packages/orq-rc/src/mcp-server/tools/budgetsUpdate.ts +0 -37
  262. package/packages/orq-rc/src/mcp-server/tools/chunkingParse.ts +0 -37
  263. package/packages/orq-rc/src/mcp-server/tools/contactsCreate.ts +0 -37
  264. package/packages/orq-rc/src/mcp-server/tools/contactsDelete.ts +0 -35
  265. package/packages/orq-rc/src/mcp-server/tools/contactsList.ts +0 -37
  266. package/packages/orq-rc/src/mcp-server/tools/contactsRetrieve.ts +0 -37
  267. package/packages/orq-rc/src/mcp-server/tools/contactsUpdate.ts +0 -37
  268. package/packages/orq-rc/src/mcp-server/tools/datasetsClear.ts +0 -35
  269. package/packages/orq-rc/src/mcp-server/tools/datasetsCreate.ts +0 -37
  270. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoint.ts +0 -37
  271. package/packages/orq-rc/src/mcp-server/tools/datasetsDelete.ts +0 -35
  272. package/packages/orq-rc/src/mcp-server/tools/datasetsDeleteDatapoint.ts +0 -35
  273. package/packages/orq-rc/src/mcp-server/tools/datasetsList.ts +0 -37
  274. package/packages/orq-rc/src/mcp-server/tools/datasetsListDatapoints.ts +0 -37
  275. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieve.ts +0 -37
  276. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieveDatapoint.ts +0 -37
  277. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdate.ts +0 -37
  278. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdateDatapoint.ts +0 -35
  279. package/packages/orq-rc/src/mcp-server/tools/deploymentsGetConfig.ts +0 -37
  280. package/packages/orq-rc/src/mcp-server/tools/deploymentsInvoke.ts +0 -37
  281. package/packages/orq-rc/src/mcp-server/tools/deploymentsList.ts +0 -37
  282. package/packages/orq-rc/src/mcp-server/tools/deploymentsMetricsCreate.ts +0 -37
  283. package/packages/orq-rc/src/mcp-server/tools/deploymentsStream.ts +0 -37
  284. package/packages/orq-rc/src/mcp-server/tools/evalsAll.ts +0 -35
  285. package/packages/orq-rc/src/mcp-server/tools/evalsCreate.ts +0 -35
  286. package/packages/orq-rc/src/mcp-server/tools/evalsDelete.ts +0 -33
  287. package/packages/orq-rc/src/mcp-server/tools/evalsUpdate.ts +0 -35
  288. package/packages/orq-rc/src/mcp-server/tools/feedbackCreate.ts +0 -37
  289. package/packages/orq-rc/src/mcp-server/tools/filesCreate.ts +0 -37
  290. package/packages/orq-rc/src/mcp-server/tools/filesDelete.ts +0 -33
  291. package/packages/orq-rc/src/mcp-server/tools/filesGet.ts +0 -37
  292. package/packages/orq-rc/src/mcp-server/tools/filesList.ts +0 -37
  293. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreate.ts +0 -35
  294. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateChunks.ts +0 -35
  295. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateDatasource.ts +0 -35
  296. package/packages/orq-rc/src/mcp-server/tools/knowledgeDelete.ts +0 -35
  297. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteChunk.ts +0 -33
  298. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteChunks.ts +0 -35
  299. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteDatasource.ts +0 -35
  300. package/packages/orq-rc/src/mcp-server/tools/knowledgeGetChunksCount.ts +0 -35
  301. package/packages/orq-rc/src/mcp-server/tools/knowledgeList.ts +0 -37
  302. package/packages/orq-rc/src/mcp-server/tools/knowledgeListChunks.ts +0 -35
  303. package/packages/orq-rc/src/mcp-server/tools/knowledgeListChunksPaginated.ts +0 -35
  304. package/packages/orq-rc/src/mcp-server/tools/knowledgeListDatasources.ts +0 -35
  305. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieve.ts +0 -37
  306. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveChunk.ts +0 -35
  307. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveDatasource.ts +0 -35
  308. package/packages/orq-rc/src/mcp-server/tools/knowledgeSearch.ts +0 -37
  309. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdate.ts +0 -35
  310. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateChunk.ts +0 -35
  311. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateDatasource.ts +0 -35
  312. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreate.ts +0 -35
  313. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreateDocument.ts +0 -37
  314. package/packages/orq-rc/src/mcp-server/tools/memoryStoresCreateMemory.ts +0 -37
  315. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDelete.ts +0 -35
  316. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDeleteDocument.ts +0 -40
  317. package/packages/orq-rc/src/mcp-server/tools/memoryStoresDeleteMemory.ts +0 -40
  318. package/packages/orq-rc/src/mcp-server/tools/memoryStoresList.ts +0 -37
  319. package/packages/orq-rc/src/mcp-server/tools/memoryStoresListDocuments.ts +0 -37
  320. package/packages/orq-rc/src/mcp-server/tools/memoryStoresListMemories.ts +0 -37
  321. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieve.ts +0 -37
  322. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieveDocument.ts +0 -37
  323. package/packages/orq-rc/src/mcp-server/tools/memoryStoresRetrieveMemory.ts +0 -37
  324. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdate.ts +0 -37
  325. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdateDocument.ts +0 -37
  326. package/packages/orq-rc/src/mcp-server/tools/memoryStoresUpdateMemory.ts +0 -37
  327. package/packages/orq-rc/src/mcp-server/tools/modelsList.ts +0 -30
  328. package/packages/orq-rc/src/mcp-server/tools/promptsCreate.ts +0 -35
  329. package/packages/orq-rc/src/mcp-server/tools/promptsDelete.ts +0 -33
  330. package/packages/orq-rc/src/mcp-server/tools/promptsGetVersion.ts +0 -37
  331. package/packages/orq-rc/src/mcp-server/tools/promptsList.ts +0 -37
  332. package/packages/orq-rc/src/mcp-server/tools/promptsListVersions.ts +0 -37
  333. package/packages/orq-rc/src/mcp-server/tools/promptsRetrieve.ts +0 -37
  334. package/packages/orq-rc/src/mcp-server/tools/promptsUpdate.ts +0 -35
  335. package/packages/orq-rc/src/mcp-server/tools/remoteconfigsRetrieve.ts +0 -36
  336. package/packages/orq-rc/src/mcp-server/tools/toolsCreate.ts +0 -37
  337. package/packages/orq-rc/src/mcp-server/tools/toolsDelete.ts +0 -35
  338. package/packages/orq-rc/src/mcp-server/tools/toolsList.ts +0 -37
  339. package/packages/orq-rc/src/mcp-server/tools/toolsRetrieve.ts +0 -37
  340. package/packages/orq-rc/src/mcp-server/tools/toolsUpdate.ts +0 -37
  341. package/packages/orq-rc/src/mcp-server/tools.ts +0 -129
  342. package/packages/orq-rc/src/models/components/index.ts +0 -6
  343. package/packages/orq-rc/src/models/components/invokedeploymentrequest.ts +0 -6261
  344. package/packages/orq-rc/src/models/components/security.ts +0 -56
  345. package/packages/orq-rc/src/models/errors/apierror.ts +0 -40
  346. package/packages/orq-rc/src/models/errors/createagent.ts +0 -67
  347. package/packages/orq-rc/src/models/errors/createeval.ts +0 -67
  348. package/packages/orq-rc/src/models/errors/deleteagent.ts +0 -67
  349. package/packages/orq-rc/src/models/errors/deletecontact.ts +0 -78
  350. package/packages/orq-rc/src/models/errors/deleteeval.ts +0 -67
  351. package/packages/orq-rc/src/models/errors/getagent.ts +0 -67
  352. package/packages/orq-rc/src/models/errors/getevals.ts +0 -67
  353. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -67
  354. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -77
  355. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  356. package/packages/orq-rc/src/models/errors/index.ts +0 -27
  357. package/packages/orq-rc/src/models/errors/listagenttasks.ts +0 -67
  358. package/packages/orq-rc/src/models/errors/orqerror.ts +0 -35
  359. package/packages/orq-rc/src/models/errors/responsevalidationerror.ts +0 -50
  360. package/packages/orq-rc/src/models/errors/retrievecontact.ts +0 -78
  361. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -109
  362. package/packages/orq-rc/src/models/errors/streamagent.ts +0 -67
  363. package/packages/orq-rc/src/models/errors/streamrunagent.ts +0 -67
  364. package/packages/orq-rc/src/models/errors/updateagent.ts +0 -67
  365. package/packages/orq-rc/src/models/errors/updatecontact.ts +0 -70
  366. package/packages/orq-rc/src/models/errors/updateeval.ts +0 -67
  367. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -67
  368. package/packages/orq-rc/src/models/errors/updatetool.ts +0 -78
  369. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -63
  370. package/packages/orq-rc/src/models/operations/createagent.ts +0 -8057
  371. package/packages/orq-rc/src/models/operations/createagentresponse.ts +0 -1339
  372. package/packages/orq-rc/src/models/operations/createbudget.ts +0 -582
  373. package/packages/orq-rc/src/models/operations/createchunk.ts +0 -341
  374. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -237
  375. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -257
  376. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -5379
  377. package/packages/orq-rc/src/models/operations/createdatasource.ts +0 -694
  378. package/packages/orq-rc/src/models/operations/createeval.ts +0 -6857
  379. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -226
  380. package/packages/orq-rc/src/models/operations/createknowledge.ts +0 -1489
  381. package/packages/orq-rc/src/models/operations/creatememory.ts +0 -229
  382. package/packages/orq-rc/src/models/operations/creatememorydocument.ts +0 -242
  383. package/packages/orq-rc/src/models/operations/creatememorystore.ts +0 -310
  384. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -6179
  385. package/packages/orq-rc/src/models/operations/createtool.ts +0 -3956
  386. package/packages/orq-rc/src/models/operations/deleteagent.ts +0 -63
  387. package/packages/orq-rc/src/models/operations/deletebudget.ts +0 -54
  388. package/packages/orq-rc/src/models/operations/deletechunk.ts +0 -81
  389. package/packages/orq-rc/src/models/operations/deletechunks.ts +0 -198
  390. package/packages/orq-rc/src/models/operations/deletecontact.ts +0 -54
  391. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -72
  392. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -63
  393. package/packages/orq-rc/src/models/operations/deletedatasource.ts +0 -72
  394. package/packages/orq-rc/src/models/operations/deleteeval.ts +0 -51
  395. package/packages/orq-rc/src/models/operations/deleteknowledge.ts +0 -63
  396. package/packages/orq-rc/src/models/operations/deletememory.ts +0 -72
  397. package/packages/orq-rc/src/models/operations/deletememorydocument.ts +0 -83
  398. package/packages/orq-rc/src/models/operations/deletememorystore.ts +0 -63
  399. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -54
  400. package/packages/orq-rc/src/models/operations/deletetool.ts +0 -60
  401. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -5091
  402. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -8055
  403. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -980
  404. package/packages/orq-rc/src/models/operations/deployments.ts +0 -2054
  405. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -8269
  406. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -63
  407. package/packages/orq-rc/src/models/operations/fileget.ts +0 -181
  408. package/packages/orq-rc/src/models/operations/filelist.ts +0 -268
  409. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -258
  410. package/packages/orq-rc/src/models/operations/getagent.ts +0 -3480
  411. package/packages/orq-rc/src/models/operations/getagenttask.ts +0 -2389
  412. package/packages/orq-rc/src/models/operations/getallmemories.ts +0 -261
  413. package/packages/orq-rc/src/models/operations/getallmemorydocuments.ts +0 -280
  414. package/packages/orq-rc/src/models/operations/getallmemorystores.ts +0 -325
  415. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -2033
  416. package/packages/orq-rc/src/models/operations/getalltools.ts +0 -2292
  417. package/packages/orq-rc/src/models/operations/getbudget.ts +0 -357
  418. package/packages/orq-rc/src/models/operations/getchunkscount.ts +0 -185
  419. package/packages/orq-rc/src/models/operations/getevals.ts +0 -5543
  420. package/packages/orq-rc/src/models/operations/getonechunk.ts +0 -258
  421. package/packages/orq-rc/src/models/operations/getoneknowledge.ts +0 -1070
  422. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -1924
  423. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -1942
  424. package/packages/orq-rc/src/models/operations/index.ts +0 -102
  425. package/packages/orq-rc/src/models/operations/invokeagent.ts +0 -1930
  426. package/packages/orq-rc/src/models/operations/listactions.ts +0 -427
  427. package/packages/orq-rc/src/models/operations/listagents.ts +0 -3626
  428. package/packages/orq-rc/src/models/operations/listagenttasks.ts +0 -2614
  429. package/packages/orq-rc/src/models/operations/listbudgets.ts +0 -494
  430. package/packages/orq-rc/src/models/operations/listchunks.ts +0 -395
  431. package/packages/orq-rc/src/models/operations/listchunkspaginated.ts +0 -408
  432. package/packages/orq-rc/src/models/operations/listcontacts.ts +0 -413
  433. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -3169
  434. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -334
  435. package/packages/orq-rc/src/models/operations/listdatasources.ts +0 -363
  436. package/packages/orq-rc/src/models/operations/listknowledgebases.ts +0 -1068
  437. package/packages/orq-rc/src/models/operations/listmodels.ts +0 -207
  438. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -2041
  439. package/packages/orq-rc/src/models/operations/parse.ts +0 -1013
  440. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -146
  441. package/packages/orq-rc/src/models/operations/retrieveaction.ts +0 -354
  442. package/packages/orq-rc/src/models/operations/retrievecontact.ts +0 -180
  443. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -2985
  444. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -246
  445. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +0 -231
  446. package/packages/orq-rc/src/models/operations/retrievememory.ts +0 -171
  447. package/packages/orq-rc/src/models/operations/retrievememorydocument.ts +0 -189
  448. package/packages/orq-rc/src/models/operations/retrievememorystore.ts +0 -234
  449. package/packages/orq-rc/src/models/operations/retrievetool.ts +0 -2347
  450. package/packages/orq-rc/src/models/operations/runagent.ts +0 -7617
  451. package/packages/orq-rc/src/models/operations/searchknowledge.ts +0 -2775
  452. package/packages/orq-rc/src/models/operations/streamagent.ts +0 -9732
  453. package/packages/orq-rc/src/models/operations/streamrunagent.ts +0 -15831
  454. package/packages/orq-rc/src/models/operations/updateagent.ts +0 -8649
  455. package/packages/orq-rc/src/models/operations/updatebudget.ts +0 -502
  456. package/packages/orq-rc/src/models/operations/updatechunk.ts +0 -361
  457. package/packages/orq-rc/src/models/operations/updatecontact.ts +0 -280
  458. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -5374
  459. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -326
  460. package/packages/orq-rc/src/models/operations/updatedatasource.ts +0 -288
  461. package/packages/orq-rc/src/models/operations/updateeval.ts +0 -7197
  462. package/packages/orq-rc/src/models/operations/updateknowledge.ts +0 -1925
  463. package/packages/orq-rc/src/models/operations/updatememory.ts +0 -238
  464. package/packages/orq-rc/src/models/operations/updatememorydocument.ts +0 -251
  465. package/packages/orq-rc/src/models/operations/updatememorystore.ts +0 -463
  466. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -6410
  467. package/packages/orq-rc/src/models/operations/updatetool.ts +0 -4279
  468. package/packages/orq-rc/src/sdk/agents.ts +0 -244
  469. package/packages/orq-rc/src/sdk/budgets.ts +0 -99
  470. package/packages/orq-rc/src/sdk/chunking.ts +0 -27
  471. package/packages/orq-rc/src/sdk/contacts.ts +0 -99
  472. package/packages/orq-rc/src/sdk/datasets.ts +0 -204
  473. package/packages/orq-rc/src/sdk/deployments.ts +0 -89
  474. package/packages/orq-rc/src/sdk/evals.ts +0 -69
  475. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  476. package/packages/orq-rc/src/sdk/files.ts +0 -78
  477. package/packages/orq-rc/src/sdk/index.ts +0 -5
  478. package/packages/orq-rc/src/sdk/knowledge.ts +0 -309
  479. package/packages/orq-rc/src/sdk/memorystores.ts +0 -286
  480. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  481. package/packages/orq-rc/src/sdk/models.ts +0 -25
  482. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  483. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  484. package/packages/orq-rc/src/sdk/responses.ts +0 -27
  485. package/packages/orq-rc/src/sdk/sdk.ts +0 -97
  486. package/packages/orq-rc/src/sdk/tools.ts +0 -99
  487. package/packages/orq-rc/src/types/async.ts +0 -68
  488. package/packages/orq-rc/src/types/blobs.ts +0 -32
  489. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  490. package/packages/orq-rc/src/types/enums.ts +0 -45
  491. package/packages/orq-rc/src/types/fp.ts +0 -50
  492. package/packages/orq-rc/src/types/index.ts +0 -11
  493. package/packages/orq-rc/src/types/operations.ts +0 -105
  494. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  495. package/packages/orq-rc/src/types/streams.ts +0 -21
  496. package/packages/orq-rc/src/types/unrecognized.ts +0 -27
  497. package/packages/orq-rc/tsconfig.json +0 -41
@@ -1,1339 +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 RoleToolMessage = {
16
- Tool: "tool",
17
- } as const;
18
- /**
19
- * Message containing tool execution results
20
- */
21
- export type RoleToolMessage = ClosedEnum<typeof RoleToolMessage>;
22
-
23
- /**
24
- * Message from the end user
25
- */
26
- export const RoleUserMessage = {
27
- User: "user",
28
- } as const;
29
- /**
30
- * Message from the end user
31
- */
32
- export type RoleUserMessage = ClosedEnum<typeof RoleUserMessage>;
33
-
34
- /**
35
- * Message role (user or tool for continuing executions)
36
- */
37
- export type CreateAgentResponseRole = RoleUserMessage | RoleToolMessage;
38
-
39
- export const CreateAgentResponsePublicMessagePartKind = {
40
- ToolResult: "tool_result",
41
- } as const;
42
- export type CreateAgentResponsePublicMessagePartKind = ClosedEnum<
43
- typeof CreateAgentResponsePublicMessagePartKind
44
- >;
45
-
46
- /**
47
- * 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.
48
- */
49
- export type ToolResultPart = {
50
- kind: CreateAgentResponsePublicMessagePartKind;
51
- toolCallId: string;
52
- result?: any | undefined;
53
- metadata?: { [k: string]: any } | undefined;
54
- };
55
-
56
- export const PublicMessagePartKind = {
57
- File: "file",
58
- } as const;
59
- export type PublicMessagePartKind = ClosedEnum<typeof PublicMessagePartKind>;
60
-
61
- /**
62
- * File in URI format. Check in the model's documentation for the supported mime types for the URI format
63
- */
64
- export type FileInURIFormat = {
65
- /**
66
- * URL for the File content
67
- */
68
- uri: string;
69
- /**
70
- * Optional mimeType for the file
71
- */
72
- mimeType?: string | undefined;
73
- /**
74
- * Optional name for the file
75
- */
76
- name?: string | undefined;
77
- };
78
-
79
- /**
80
- * Binary in base64 format. Check in the model's documentation for the supported mime types for the binary format.
81
- */
82
- export type BinaryFormat = {
83
- /**
84
- * base64 encoded content of the file
85
- */
86
- bytes: string;
87
- /**
88
- * Optional mimeType for the file
89
- */
90
- mimeType?: string | undefined;
91
- /**
92
- * Optional name for the file
93
- */
94
- name?: string | undefined;
95
- };
96
-
97
- export type PublicMessagePartFile = BinaryFormat | FileInURIFormat;
98
-
99
- /**
100
- * File attachment part. Use this to send files (images, documents, etc.) to the agent for processing.
101
- */
102
- export type FilePart = {
103
- kind: PublicMessagePartKind;
104
- file: BinaryFormat | FileInURIFormat;
105
- metadata?: { [k: string]: any } | undefined;
106
- };
107
-
108
- export const Kind = {
109
- Text: "text",
110
- } as const;
111
- export type Kind = ClosedEnum<typeof Kind>;
112
-
113
- /**
114
- * Text content part. Use this to send text messages to the agent.
115
- */
116
- export type TextPart = {
117
- kind: Kind;
118
- text: string;
119
- };
120
-
121
- /**
122
- * 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.
123
- */
124
- export type PublicMessagePart = TextPart | FilePart | ToolResultPart;
125
-
126
- /**
127
- * The A2A message to send to the agent (user input or tool results)
128
- */
129
- export type A2AMessage = {
130
- /**
131
- * Optional A2A message ID in ULID format
132
- */
133
- messageId?: string | undefined;
134
- /**
135
- * Message role (user or tool for continuing executions)
136
- */
137
- role: RoleUserMessage | RoleToolMessage;
138
- /**
139
- * A2A message parts (text, file, or tool_result only)
140
- */
141
- parts: Array<TextPart | FilePart | ToolResultPart>;
142
- };
143
-
144
- /**
145
- * Information about the contact making the request. If the contact does not exist, it will be created automatically.
146
- */
147
- export type Contact = {
148
- /**
149
- * Unique identifier for the contact
150
- */
151
- id: string;
152
- /**
153
- * Display name of the contact
154
- */
155
- displayName?: string | undefined;
156
- /**
157
- * Email address of the contact
158
- */
159
- email?: string | undefined;
160
- /**
161
- * A hash of key/value pairs containing any other data about the contact
162
- */
163
- metadata?: Array<{ [k: string]: any }> | undefined;
164
- /**
165
- * URL to the contact's avatar or logo
166
- */
167
- logoUrl?: string | undefined;
168
- /**
169
- * A list of tags associated with the contact
170
- */
171
- tags?: Array<string> | undefined;
172
- };
173
-
174
- /**
175
- * Thread information to group related requests
176
- */
177
- export type CreateAgentResponseThread = {
178
- /**
179
- * Unique thread identifier to group related invocations.
180
- */
181
- id: string;
182
- /**
183
- * Optional tags to differentiate or categorize threads
184
- */
185
- tags?: Array<string> | undefined;
186
- };
187
-
188
- /**
189
- * Memory configuration for the agent execution. Used to associate memory stores with specific entities like users or sessions.
190
- */
191
- export type Memory = {
192
- /**
193
- * 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.
194
- */
195
- entityId: string;
196
- };
197
-
198
- export type CreateAgentResponseRequestBody = {
199
- /**
200
- * 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.
201
- */
202
- taskId?: string | undefined;
203
- /**
204
- * The A2A message to send to the agent (user input or tool results)
205
- */
206
- message: A2AMessage;
207
- /**
208
- * Optional variables for template replacement in system prompt, instructions, and messages
209
- */
210
- variables?: { [k: string]: any } | undefined;
211
- /**
212
- * Information about the contact making the request. If the contact does not exist, it will be created automatically.
213
- */
214
- contact?: Contact | undefined;
215
- /**
216
- * Thread information to group related requests
217
- */
218
- thread?: CreateAgentResponseThread | undefined;
219
- /**
220
- * Memory configuration for the agent execution. Used to associate memory stores with specific entities like users or sessions.
221
- */
222
- memory?: Memory | undefined;
223
- /**
224
- * Optional metadata for the agent invocation as key-value pairs that will be included in traces
225
- */
226
- metadata?: { [k: string]: any } | undefined;
227
- /**
228
- * If true, returns immediately without waiting for completion. If false (default), waits until the agent becomes inactive or errors.
229
- */
230
- background?: boolean | undefined;
231
- };
232
-
233
- export type CreateAgentResponseRequest = {
234
- /**
235
- * The key or ID of the agent to invoke
236
- */
237
- agentKey: string;
238
- requestBody?: CreateAgentResponseRequestBody | undefined;
239
- };
240
-
241
- export const CreateAgentResponseAgentsResponsesRole = {
242
- User: "user",
243
- Agent: "agent",
244
- Tool: "tool",
245
- System: "system",
246
- } as const;
247
- export type CreateAgentResponseAgentsResponsesRole = ClosedEnum<
248
- typeof CreateAgentResponseAgentsResponsesRole
249
- >;
250
-
251
- export type Output = {
252
- messageId: string;
253
- role: CreateAgentResponseAgentsResponsesRole;
254
- parts: Array<any>;
255
- metadata?: { [k: string]: any } | undefined;
256
- };
257
-
258
- export type PromptTokensDetails = {
259
- cachedTokens?: number | null | undefined;
260
- /**
261
- * The number of audio input tokens consumed by the request.
262
- */
263
- audioTokens?: number | null | undefined;
264
- };
265
-
266
- export type CompletionTokensDetails = {
267
- reasoningTokens?: number | null | undefined;
268
- acceptedPredictionTokens?: number | null | undefined;
269
- rejectedPredictionTokens?: number | null | undefined;
270
- /**
271
- * The number of audio output tokens produced by the response.
272
- */
273
- audioTokens?: number | null | undefined;
274
- };
275
-
276
- /**
277
- * Token usage from the agent execution
278
- */
279
- export type CreateAgentResponseUsage = {
280
- /**
281
- * Number of tokens in the generated completion.
282
- */
283
- completionTokens?: number | undefined;
284
- /**
285
- * Number of tokens in the prompt.
286
- */
287
- promptTokens?: number | undefined;
288
- /**
289
- * Total number of tokens used in the request (prompt + completion).
290
- */
291
- totalTokens?: number | undefined;
292
- promptTokensDetails?: PromptTokensDetails | null | undefined;
293
- completionTokensDetails?: CompletionTokensDetails | null | undefined;
294
- };
295
-
296
- /**
297
- * Agent response created successfully
298
- */
299
- export type CreateAgentResponseResponseBody = {
300
- /**
301
- * The unique response ID
302
- */
303
- id: string;
304
- /**
305
- * The agent execution task ID
306
- */
307
- taskId: string;
308
- /**
309
- * Array of messages from the agent execution
310
- */
311
- output: Array<Output>;
312
- /**
313
- * ISO timestamp of response creation
314
- */
315
- createdAt: string;
316
- /**
317
- * Model used in provider/model format
318
- */
319
- model: string;
320
- /**
321
- * Token usage from the agent execution
322
- */
323
- usage?: CreateAgentResponseUsage | null | undefined;
324
- };
325
-
326
- /** @internal */
327
- export const RoleToolMessage$inboundSchema: z.ZodNativeEnum<
328
- typeof RoleToolMessage
329
- > = z.nativeEnum(RoleToolMessage);
330
- /** @internal */
331
- export const RoleToolMessage$outboundSchema: z.ZodNativeEnum<
332
- typeof RoleToolMessage
333
- > = RoleToolMessage$inboundSchema;
334
-
335
- /** @internal */
336
- export const RoleUserMessage$inboundSchema: z.ZodNativeEnum<
337
- typeof RoleUserMessage
338
- > = z.nativeEnum(RoleUserMessage);
339
- /** @internal */
340
- export const RoleUserMessage$outboundSchema: z.ZodNativeEnum<
341
- typeof RoleUserMessage
342
- > = RoleUserMessage$inboundSchema;
343
-
344
- /** @internal */
345
- export const CreateAgentResponseRole$inboundSchema: z.ZodType<
346
- CreateAgentResponseRole,
347
- z.ZodTypeDef,
348
- unknown
349
- > = z.union([RoleUserMessage$inboundSchema, RoleToolMessage$inboundSchema]);
350
- /** @internal */
351
- export type CreateAgentResponseRole$Outbound = string | string;
352
-
353
- /** @internal */
354
- export const CreateAgentResponseRole$outboundSchema: z.ZodType<
355
- CreateAgentResponseRole$Outbound,
356
- z.ZodTypeDef,
357
- CreateAgentResponseRole
358
- > = z.union([RoleUserMessage$outboundSchema, RoleToolMessage$outboundSchema]);
359
-
360
- export function createAgentResponseRoleToJSON(
361
- createAgentResponseRole: CreateAgentResponseRole,
362
- ): string {
363
- return JSON.stringify(
364
- CreateAgentResponseRole$outboundSchema.parse(createAgentResponseRole),
365
- );
366
- }
367
- export function createAgentResponseRoleFromJSON(
368
- jsonString: string,
369
- ): SafeParseResult<CreateAgentResponseRole, SDKValidationError> {
370
- return safeParse(
371
- jsonString,
372
- (x) => CreateAgentResponseRole$inboundSchema.parse(JSON.parse(x)),
373
- `Failed to parse 'CreateAgentResponseRole' from JSON`,
374
- );
375
- }
376
-
377
- /** @internal */
378
- export const CreateAgentResponsePublicMessagePartKind$inboundSchema:
379
- z.ZodNativeEnum<typeof CreateAgentResponsePublicMessagePartKind> = z
380
- .nativeEnum(CreateAgentResponsePublicMessagePartKind);
381
- /** @internal */
382
- export const CreateAgentResponsePublicMessagePartKind$outboundSchema:
383
- z.ZodNativeEnum<typeof CreateAgentResponsePublicMessagePartKind> =
384
- CreateAgentResponsePublicMessagePartKind$inboundSchema;
385
-
386
- /** @internal */
387
- export const ToolResultPart$inboundSchema: z.ZodType<
388
- ToolResultPart,
389
- z.ZodTypeDef,
390
- unknown
391
- > = z.object({
392
- kind: CreateAgentResponsePublicMessagePartKind$inboundSchema,
393
- tool_call_id: z.string(),
394
- result: z.any().optional(),
395
- metadata: z.record(z.any()).optional(),
396
- }).transform((v) => {
397
- return remap$(v, {
398
- "tool_call_id": "toolCallId",
399
- });
400
- });
401
- /** @internal */
402
- export type ToolResultPart$Outbound = {
403
- kind: string;
404
- tool_call_id: string;
405
- result?: any | undefined;
406
- metadata?: { [k: string]: any } | undefined;
407
- };
408
-
409
- /** @internal */
410
- export const ToolResultPart$outboundSchema: z.ZodType<
411
- ToolResultPart$Outbound,
412
- z.ZodTypeDef,
413
- ToolResultPart
414
- > = z.object({
415
- kind: CreateAgentResponsePublicMessagePartKind$outboundSchema,
416
- toolCallId: z.string(),
417
- result: z.any().optional(),
418
- metadata: z.record(z.any()).optional(),
419
- }).transform((v) => {
420
- return remap$(v, {
421
- toolCallId: "tool_call_id",
422
- });
423
- });
424
-
425
- export function toolResultPartToJSON(toolResultPart: ToolResultPart): string {
426
- return JSON.stringify(ToolResultPart$outboundSchema.parse(toolResultPart));
427
- }
428
- export function toolResultPartFromJSON(
429
- jsonString: string,
430
- ): SafeParseResult<ToolResultPart, SDKValidationError> {
431
- return safeParse(
432
- jsonString,
433
- (x) => ToolResultPart$inboundSchema.parse(JSON.parse(x)),
434
- `Failed to parse 'ToolResultPart' from JSON`,
435
- );
436
- }
437
-
438
- /** @internal */
439
- export const PublicMessagePartKind$inboundSchema: z.ZodNativeEnum<
440
- typeof PublicMessagePartKind
441
- > = z.nativeEnum(PublicMessagePartKind);
442
- /** @internal */
443
- export const PublicMessagePartKind$outboundSchema: z.ZodNativeEnum<
444
- typeof PublicMessagePartKind
445
- > = PublicMessagePartKind$inboundSchema;
446
-
447
- /** @internal */
448
- export const FileInURIFormat$inboundSchema: z.ZodType<
449
- FileInURIFormat,
450
- z.ZodTypeDef,
451
- unknown
452
- > = z.object({
453
- uri: z.string(),
454
- mimeType: z.string().optional(),
455
- name: z.string().optional(),
456
- });
457
- /** @internal */
458
- export type FileInURIFormat$Outbound = {
459
- uri: string;
460
- mimeType?: string | undefined;
461
- name?: string | undefined;
462
- };
463
-
464
- /** @internal */
465
- export const FileInURIFormat$outboundSchema: z.ZodType<
466
- FileInURIFormat$Outbound,
467
- z.ZodTypeDef,
468
- FileInURIFormat
469
- > = z.object({
470
- uri: z.string(),
471
- mimeType: z.string().optional(),
472
- name: z.string().optional(),
473
- });
474
-
475
- export function fileInURIFormatToJSON(
476
- fileInURIFormat: FileInURIFormat,
477
- ): string {
478
- return JSON.stringify(FileInURIFormat$outboundSchema.parse(fileInURIFormat));
479
- }
480
- export function fileInURIFormatFromJSON(
481
- jsonString: string,
482
- ): SafeParseResult<FileInURIFormat, SDKValidationError> {
483
- return safeParse(
484
- jsonString,
485
- (x) => FileInURIFormat$inboundSchema.parse(JSON.parse(x)),
486
- `Failed to parse 'FileInURIFormat' from JSON`,
487
- );
488
- }
489
-
490
- /** @internal */
491
- export const BinaryFormat$inboundSchema: z.ZodType<
492
- BinaryFormat,
493
- z.ZodTypeDef,
494
- unknown
495
- > = z.object({
496
- bytes: z.string(),
497
- mimeType: z.string().optional(),
498
- name: z.string().optional(),
499
- });
500
- /** @internal */
501
- export type BinaryFormat$Outbound = {
502
- bytes: string;
503
- mimeType?: string | undefined;
504
- name?: string | undefined;
505
- };
506
-
507
- /** @internal */
508
- export const BinaryFormat$outboundSchema: z.ZodType<
509
- BinaryFormat$Outbound,
510
- z.ZodTypeDef,
511
- BinaryFormat
512
- > = z.object({
513
- bytes: z.string(),
514
- mimeType: z.string().optional(),
515
- name: z.string().optional(),
516
- });
517
-
518
- export function binaryFormatToJSON(binaryFormat: BinaryFormat): string {
519
- return JSON.stringify(BinaryFormat$outboundSchema.parse(binaryFormat));
520
- }
521
- export function binaryFormatFromJSON(
522
- jsonString: string,
523
- ): SafeParseResult<BinaryFormat, SDKValidationError> {
524
- return safeParse(
525
- jsonString,
526
- (x) => BinaryFormat$inboundSchema.parse(JSON.parse(x)),
527
- `Failed to parse 'BinaryFormat' from JSON`,
528
- );
529
- }
530
-
531
- /** @internal */
532
- export const PublicMessagePartFile$inboundSchema: z.ZodType<
533
- PublicMessagePartFile,
534
- z.ZodTypeDef,
535
- unknown
536
- > = z.union([
537
- z.lazy(() => BinaryFormat$inboundSchema),
538
- z.lazy(() => FileInURIFormat$inboundSchema),
539
- ]);
540
- /** @internal */
541
- export type PublicMessagePartFile$Outbound =
542
- | BinaryFormat$Outbound
543
- | FileInURIFormat$Outbound;
544
-
545
- /** @internal */
546
- export const PublicMessagePartFile$outboundSchema: z.ZodType<
547
- PublicMessagePartFile$Outbound,
548
- z.ZodTypeDef,
549
- PublicMessagePartFile
550
- > = z.union([
551
- z.lazy(() => BinaryFormat$outboundSchema),
552
- z.lazy(() => FileInURIFormat$outboundSchema),
553
- ]);
554
-
555
- export function publicMessagePartFileToJSON(
556
- publicMessagePartFile: PublicMessagePartFile,
557
- ): string {
558
- return JSON.stringify(
559
- PublicMessagePartFile$outboundSchema.parse(publicMessagePartFile),
560
- );
561
- }
562
- export function publicMessagePartFileFromJSON(
563
- jsonString: string,
564
- ): SafeParseResult<PublicMessagePartFile, SDKValidationError> {
565
- return safeParse(
566
- jsonString,
567
- (x) => PublicMessagePartFile$inboundSchema.parse(JSON.parse(x)),
568
- `Failed to parse 'PublicMessagePartFile' from JSON`,
569
- );
570
- }
571
-
572
- /** @internal */
573
- export const FilePart$inboundSchema: z.ZodType<
574
- FilePart,
575
- z.ZodTypeDef,
576
- unknown
577
- > = z.object({
578
- kind: PublicMessagePartKind$inboundSchema,
579
- file: z.union([
580
- z.lazy(() => BinaryFormat$inboundSchema),
581
- z.lazy(() => FileInURIFormat$inboundSchema),
582
- ]),
583
- metadata: z.record(z.any()).optional(),
584
- });
585
- /** @internal */
586
- export type FilePart$Outbound = {
587
- kind: string;
588
- file: BinaryFormat$Outbound | FileInURIFormat$Outbound;
589
- metadata?: { [k: string]: any } | undefined;
590
- };
591
-
592
- /** @internal */
593
- export const FilePart$outboundSchema: z.ZodType<
594
- FilePart$Outbound,
595
- z.ZodTypeDef,
596
- FilePart
597
- > = z.object({
598
- kind: PublicMessagePartKind$outboundSchema,
599
- file: z.union([
600
- z.lazy(() => BinaryFormat$outboundSchema),
601
- z.lazy(() => FileInURIFormat$outboundSchema),
602
- ]),
603
- metadata: z.record(z.any()).optional(),
604
- });
605
-
606
- export function filePartToJSON(filePart: FilePart): string {
607
- return JSON.stringify(FilePart$outboundSchema.parse(filePart));
608
- }
609
- export function filePartFromJSON(
610
- jsonString: string,
611
- ): SafeParseResult<FilePart, SDKValidationError> {
612
- return safeParse(
613
- jsonString,
614
- (x) => FilePart$inboundSchema.parse(JSON.parse(x)),
615
- `Failed to parse 'FilePart' from JSON`,
616
- );
617
- }
618
-
619
- /** @internal */
620
- export const Kind$inboundSchema: z.ZodNativeEnum<typeof Kind> = z.nativeEnum(
621
- Kind,
622
- );
623
- /** @internal */
624
- export const Kind$outboundSchema: z.ZodNativeEnum<typeof Kind> =
625
- Kind$inboundSchema;
626
-
627
- /** @internal */
628
- export const TextPart$inboundSchema: z.ZodType<
629
- TextPart,
630
- z.ZodTypeDef,
631
- unknown
632
- > = z.object({
633
- kind: Kind$inboundSchema,
634
- text: z.string(),
635
- });
636
- /** @internal */
637
- export type TextPart$Outbound = {
638
- kind: string;
639
- text: string;
640
- };
641
-
642
- /** @internal */
643
- export const TextPart$outboundSchema: z.ZodType<
644
- TextPart$Outbound,
645
- z.ZodTypeDef,
646
- TextPart
647
- > = z.object({
648
- kind: Kind$outboundSchema,
649
- text: z.string(),
650
- });
651
-
652
- export function textPartToJSON(textPart: TextPart): string {
653
- return JSON.stringify(TextPart$outboundSchema.parse(textPart));
654
- }
655
- export function textPartFromJSON(
656
- jsonString: string,
657
- ): SafeParseResult<TextPart, SDKValidationError> {
658
- return safeParse(
659
- jsonString,
660
- (x) => TextPart$inboundSchema.parse(JSON.parse(x)),
661
- `Failed to parse 'TextPart' from JSON`,
662
- );
663
- }
664
-
665
- /** @internal */
666
- export const PublicMessagePart$inboundSchema: z.ZodType<
667
- PublicMessagePart,
668
- z.ZodTypeDef,
669
- unknown
670
- > = z.union([
671
- z.lazy(() => TextPart$inboundSchema),
672
- z.lazy(() => FilePart$inboundSchema),
673
- z.lazy(() => ToolResultPart$inboundSchema),
674
- ]);
675
- /** @internal */
676
- export type PublicMessagePart$Outbound =
677
- | TextPart$Outbound
678
- | FilePart$Outbound
679
- | ToolResultPart$Outbound;
680
-
681
- /** @internal */
682
- export const PublicMessagePart$outboundSchema: z.ZodType<
683
- PublicMessagePart$Outbound,
684
- z.ZodTypeDef,
685
- PublicMessagePart
686
- > = z.union([
687
- z.lazy(() => TextPart$outboundSchema),
688
- z.lazy(() => FilePart$outboundSchema),
689
- z.lazy(() => ToolResultPart$outboundSchema),
690
- ]);
691
-
692
- export function publicMessagePartToJSON(
693
- publicMessagePart: PublicMessagePart,
694
- ): string {
695
- return JSON.stringify(
696
- PublicMessagePart$outboundSchema.parse(publicMessagePart),
697
- );
698
- }
699
- export function publicMessagePartFromJSON(
700
- jsonString: string,
701
- ): SafeParseResult<PublicMessagePart, SDKValidationError> {
702
- return safeParse(
703
- jsonString,
704
- (x) => PublicMessagePart$inboundSchema.parse(JSON.parse(x)),
705
- `Failed to parse 'PublicMessagePart' from JSON`,
706
- );
707
- }
708
-
709
- /** @internal */
710
- export const A2AMessage$inboundSchema: z.ZodType<
711
- A2AMessage,
712
- z.ZodTypeDef,
713
- unknown
714
- > = z.object({
715
- messageId: z.string().optional(),
716
- role: z.union([RoleUserMessage$inboundSchema, RoleToolMessage$inboundSchema]),
717
- parts: z.array(
718
- z.union([
719
- z.lazy(() => TextPart$inboundSchema),
720
- z.lazy(() => FilePart$inboundSchema),
721
- z.lazy(() => ToolResultPart$inboundSchema),
722
- ]),
723
- ),
724
- });
725
- /** @internal */
726
- export type A2AMessage$Outbound = {
727
- messageId?: string | undefined;
728
- role: string | string;
729
- parts: Array<TextPart$Outbound | FilePart$Outbound | ToolResultPart$Outbound>;
730
- };
731
-
732
- /** @internal */
733
- export const A2AMessage$outboundSchema: z.ZodType<
734
- A2AMessage$Outbound,
735
- z.ZodTypeDef,
736
- A2AMessage
737
- > = z.object({
738
- messageId: z.string().optional(),
739
- role: z.union([
740
- RoleUserMessage$outboundSchema,
741
- RoleToolMessage$outboundSchema,
742
- ]),
743
- parts: z.array(
744
- z.union([
745
- z.lazy(() => TextPart$outboundSchema),
746
- z.lazy(() => FilePart$outboundSchema),
747
- z.lazy(() => ToolResultPart$outboundSchema),
748
- ]),
749
- ),
750
- });
751
-
752
- export function a2AMessageToJSON(a2AMessage: A2AMessage): string {
753
- return JSON.stringify(A2AMessage$outboundSchema.parse(a2AMessage));
754
- }
755
- export function a2AMessageFromJSON(
756
- jsonString: string,
757
- ): SafeParseResult<A2AMessage, SDKValidationError> {
758
- return safeParse(
759
- jsonString,
760
- (x) => A2AMessage$inboundSchema.parse(JSON.parse(x)),
761
- `Failed to parse 'A2AMessage' from JSON`,
762
- );
763
- }
764
-
765
- /** @internal */
766
- export const Contact$inboundSchema: z.ZodType<Contact, z.ZodTypeDef, unknown> =
767
- z.object({
768
- id: z.string(),
769
- display_name: z.string().optional(),
770
- email: z.string().optional(),
771
- metadata: z.array(z.record(z.any())).optional(),
772
- logo_url: z.string().optional(),
773
- tags: z.array(z.string()).optional(),
774
- }).transform((v) => {
775
- return remap$(v, {
776
- "display_name": "displayName",
777
- "logo_url": "logoUrl",
778
- });
779
- });
780
- /** @internal */
781
- export type Contact$Outbound = {
782
- id: string;
783
- display_name?: string | undefined;
784
- email?: string | undefined;
785
- metadata?: Array<{ [k: string]: any }> | undefined;
786
- logo_url?: string | undefined;
787
- tags?: Array<string> | undefined;
788
- };
789
-
790
- /** @internal */
791
- export const Contact$outboundSchema: z.ZodType<
792
- Contact$Outbound,
793
- z.ZodTypeDef,
794
- Contact
795
- > = z.object({
796
- id: z.string(),
797
- displayName: z.string().optional(),
798
- email: z.string().optional(),
799
- metadata: z.array(z.record(z.any())).optional(),
800
- logoUrl: z.string().optional(),
801
- tags: z.array(z.string()).optional(),
802
- }).transform((v) => {
803
- return remap$(v, {
804
- displayName: "display_name",
805
- logoUrl: "logo_url",
806
- });
807
- });
808
-
809
- export function contactToJSON(contact: Contact): string {
810
- return JSON.stringify(Contact$outboundSchema.parse(contact));
811
- }
812
- export function contactFromJSON(
813
- jsonString: string,
814
- ): SafeParseResult<Contact, SDKValidationError> {
815
- return safeParse(
816
- jsonString,
817
- (x) => Contact$inboundSchema.parse(JSON.parse(x)),
818
- `Failed to parse 'Contact' from JSON`,
819
- );
820
- }
821
-
822
- /** @internal */
823
- export const CreateAgentResponseThread$inboundSchema: z.ZodType<
824
- CreateAgentResponseThread,
825
- z.ZodTypeDef,
826
- unknown
827
- > = z.object({
828
- id: z.string(),
829
- tags: z.array(z.string()).optional(),
830
- });
831
- /** @internal */
832
- export type CreateAgentResponseThread$Outbound = {
833
- id: string;
834
- tags?: Array<string> | undefined;
835
- };
836
-
837
- /** @internal */
838
- export const CreateAgentResponseThread$outboundSchema: z.ZodType<
839
- CreateAgentResponseThread$Outbound,
840
- z.ZodTypeDef,
841
- CreateAgentResponseThread
842
- > = z.object({
843
- id: z.string(),
844
- tags: z.array(z.string()).optional(),
845
- });
846
-
847
- export function createAgentResponseThreadToJSON(
848
- createAgentResponseThread: CreateAgentResponseThread,
849
- ): string {
850
- return JSON.stringify(
851
- CreateAgentResponseThread$outboundSchema.parse(createAgentResponseThread),
852
- );
853
- }
854
- export function createAgentResponseThreadFromJSON(
855
- jsonString: string,
856
- ): SafeParseResult<CreateAgentResponseThread, SDKValidationError> {
857
- return safeParse(
858
- jsonString,
859
- (x) => CreateAgentResponseThread$inboundSchema.parse(JSON.parse(x)),
860
- `Failed to parse 'CreateAgentResponseThread' from JSON`,
861
- );
862
- }
863
-
864
- /** @internal */
865
- export const Memory$inboundSchema: z.ZodType<Memory, z.ZodTypeDef, unknown> = z
866
- .object({
867
- entity_id: z.string(),
868
- }).transform((v) => {
869
- return remap$(v, {
870
- "entity_id": "entityId",
871
- });
872
- });
873
- /** @internal */
874
- export type Memory$Outbound = {
875
- entity_id: string;
876
- };
877
-
878
- /** @internal */
879
- export const Memory$outboundSchema: z.ZodType<
880
- Memory$Outbound,
881
- z.ZodTypeDef,
882
- Memory
883
- > = z.object({
884
- entityId: z.string(),
885
- }).transform((v) => {
886
- return remap$(v, {
887
- entityId: "entity_id",
888
- });
889
- });
890
-
891
- export function memoryToJSON(memory: Memory): string {
892
- return JSON.stringify(Memory$outboundSchema.parse(memory));
893
- }
894
- export function memoryFromJSON(
895
- jsonString: string,
896
- ): SafeParseResult<Memory, SDKValidationError> {
897
- return safeParse(
898
- jsonString,
899
- (x) => Memory$inboundSchema.parse(JSON.parse(x)),
900
- `Failed to parse 'Memory' from JSON`,
901
- );
902
- }
903
-
904
- /** @internal */
905
- export const CreateAgentResponseRequestBody$inboundSchema: z.ZodType<
906
- CreateAgentResponseRequestBody,
907
- z.ZodTypeDef,
908
- unknown
909
- > = z.object({
910
- task_id: z.string().optional(),
911
- message: z.lazy(() => A2AMessage$inboundSchema),
912
- variables: z.record(z.any()).optional(),
913
- contact: z.lazy(() => Contact$inboundSchema).optional(),
914
- thread: z.lazy(() => CreateAgentResponseThread$inboundSchema).optional(),
915
- memory: z.lazy(() => Memory$inboundSchema).optional(),
916
- metadata: z.record(z.any()).optional(),
917
- background: z.boolean().default(false),
918
- }).transform((v) => {
919
- return remap$(v, {
920
- "task_id": "taskId",
921
- });
922
- });
923
- /** @internal */
924
- export type CreateAgentResponseRequestBody$Outbound = {
925
- task_id?: string | undefined;
926
- message: A2AMessage$Outbound;
927
- variables?: { [k: string]: any } | undefined;
928
- contact?: Contact$Outbound | undefined;
929
- thread?: CreateAgentResponseThread$Outbound | undefined;
930
- memory?: Memory$Outbound | undefined;
931
- metadata?: { [k: string]: any } | undefined;
932
- background: boolean;
933
- };
934
-
935
- /** @internal */
936
- export const CreateAgentResponseRequestBody$outboundSchema: z.ZodType<
937
- CreateAgentResponseRequestBody$Outbound,
938
- z.ZodTypeDef,
939
- CreateAgentResponseRequestBody
940
- > = z.object({
941
- taskId: z.string().optional(),
942
- message: z.lazy(() => A2AMessage$outboundSchema),
943
- variables: z.record(z.any()).optional(),
944
- contact: z.lazy(() => Contact$outboundSchema).optional(),
945
- thread: z.lazy(() => CreateAgentResponseThread$outboundSchema).optional(),
946
- memory: z.lazy(() => Memory$outboundSchema).optional(),
947
- metadata: z.record(z.any()).optional(),
948
- background: z.boolean().default(false),
949
- }).transform((v) => {
950
- return remap$(v, {
951
- taskId: "task_id",
952
- });
953
- });
954
-
955
- export function createAgentResponseRequestBodyToJSON(
956
- createAgentResponseRequestBody: CreateAgentResponseRequestBody,
957
- ): string {
958
- return JSON.stringify(
959
- CreateAgentResponseRequestBody$outboundSchema.parse(
960
- createAgentResponseRequestBody,
961
- ),
962
- );
963
- }
964
- export function createAgentResponseRequestBodyFromJSON(
965
- jsonString: string,
966
- ): SafeParseResult<CreateAgentResponseRequestBody, SDKValidationError> {
967
- return safeParse(
968
- jsonString,
969
- (x) => CreateAgentResponseRequestBody$inboundSchema.parse(JSON.parse(x)),
970
- `Failed to parse 'CreateAgentResponseRequestBody' from JSON`,
971
- );
972
- }
973
-
974
- /** @internal */
975
- export const CreateAgentResponseRequest$inboundSchema: z.ZodType<
976
- CreateAgentResponseRequest,
977
- z.ZodTypeDef,
978
- unknown
979
- > = z.object({
980
- agent_key: z.string(),
981
- RequestBody: z.lazy(() => CreateAgentResponseRequestBody$inboundSchema)
982
- .optional(),
983
- }).transform((v) => {
984
- return remap$(v, {
985
- "agent_key": "agentKey",
986
- "RequestBody": "requestBody",
987
- });
988
- });
989
- /** @internal */
990
- export type CreateAgentResponseRequest$Outbound = {
991
- agent_key: string;
992
- RequestBody?: CreateAgentResponseRequestBody$Outbound | undefined;
993
- };
994
-
995
- /** @internal */
996
- export const CreateAgentResponseRequest$outboundSchema: z.ZodType<
997
- CreateAgentResponseRequest$Outbound,
998
- z.ZodTypeDef,
999
- CreateAgentResponseRequest
1000
- > = z.object({
1001
- agentKey: z.string(),
1002
- requestBody: z.lazy(() => CreateAgentResponseRequestBody$outboundSchema)
1003
- .optional(),
1004
- }).transform((v) => {
1005
- return remap$(v, {
1006
- agentKey: "agent_key",
1007
- requestBody: "RequestBody",
1008
- });
1009
- });
1010
-
1011
- export function createAgentResponseRequestToJSON(
1012
- createAgentResponseRequest: CreateAgentResponseRequest,
1013
- ): string {
1014
- return JSON.stringify(
1015
- CreateAgentResponseRequest$outboundSchema.parse(createAgentResponseRequest),
1016
- );
1017
- }
1018
- export function createAgentResponseRequestFromJSON(
1019
- jsonString: string,
1020
- ): SafeParseResult<CreateAgentResponseRequest, SDKValidationError> {
1021
- return safeParse(
1022
- jsonString,
1023
- (x) => CreateAgentResponseRequest$inboundSchema.parse(JSON.parse(x)),
1024
- `Failed to parse 'CreateAgentResponseRequest' from JSON`,
1025
- );
1026
- }
1027
-
1028
- /** @internal */
1029
- export const CreateAgentResponseAgentsResponsesRole$inboundSchema:
1030
- z.ZodNativeEnum<typeof CreateAgentResponseAgentsResponsesRole> = z.nativeEnum(
1031
- CreateAgentResponseAgentsResponsesRole,
1032
- );
1033
- /** @internal */
1034
- export const CreateAgentResponseAgentsResponsesRole$outboundSchema:
1035
- z.ZodNativeEnum<typeof CreateAgentResponseAgentsResponsesRole> =
1036
- CreateAgentResponseAgentsResponsesRole$inboundSchema;
1037
-
1038
- /** @internal */
1039
- export const Output$inboundSchema: z.ZodType<Output, z.ZodTypeDef, unknown> = z
1040
- .object({
1041
- messageId: z.string(),
1042
- role: CreateAgentResponseAgentsResponsesRole$inboundSchema,
1043
- parts: z.array(z.any()),
1044
- metadata: z.record(z.any()).optional(),
1045
- });
1046
- /** @internal */
1047
- export type Output$Outbound = {
1048
- messageId: string;
1049
- role: string;
1050
- parts: Array<any>;
1051
- metadata?: { [k: string]: any } | undefined;
1052
- };
1053
-
1054
- /** @internal */
1055
- export const Output$outboundSchema: z.ZodType<
1056
- Output$Outbound,
1057
- z.ZodTypeDef,
1058
- Output
1059
- > = z.object({
1060
- messageId: z.string(),
1061
- role: CreateAgentResponseAgentsResponsesRole$outboundSchema,
1062
- parts: z.array(z.any()),
1063
- metadata: z.record(z.any()).optional(),
1064
- });
1065
-
1066
- export function outputToJSON(output: Output): string {
1067
- return JSON.stringify(Output$outboundSchema.parse(output));
1068
- }
1069
- export function outputFromJSON(
1070
- jsonString: string,
1071
- ): SafeParseResult<Output, SDKValidationError> {
1072
- return safeParse(
1073
- jsonString,
1074
- (x) => Output$inboundSchema.parse(JSON.parse(x)),
1075
- `Failed to parse 'Output' from JSON`,
1076
- );
1077
- }
1078
-
1079
- /** @internal */
1080
- export const PromptTokensDetails$inboundSchema: z.ZodType<
1081
- PromptTokensDetails,
1082
- z.ZodTypeDef,
1083
- unknown
1084
- > = z.object({
1085
- cached_tokens: z.nullable(z.number().int()).optional(),
1086
- audio_tokens: z.nullable(z.number().int()).optional(),
1087
- }).transform((v) => {
1088
- return remap$(v, {
1089
- "cached_tokens": "cachedTokens",
1090
- "audio_tokens": "audioTokens",
1091
- });
1092
- });
1093
- /** @internal */
1094
- export type PromptTokensDetails$Outbound = {
1095
- cached_tokens?: number | null | undefined;
1096
- audio_tokens?: number | null | undefined;
1097
- };
1098
-
1099
- /** @internal */
1100
- export const PromptTokensDetails$outboundSchema: z.ZodType<
1101
- PromptTokensDetails$Outbound,
1102
- z.ZodTypeDef,
1103
- PromptTokensDetails
1104
- > = z.object({
1105
- cachedTokens: z.nullable(z.number().int()).optional(),
1106
- audioTokens: z.nullable(z.number().int()).optional(),
1107
- }).transform((v) => {
1108
- return remap$(v, {
1109
- cachedTokens: "cached_tokens",
1110
- audioTokens: "audio_tokens",
1111
- });
1112
- });
1113
-
1114
- export function promptTokensDetailsToJSON(
1115
- promptTokensDetails: PromptTokensDetails,
1116
- ): string {
1117
- return JSON.stringify(
1118
- PromptTokensDetails$outboundSchema.parse(promptTokensDetails),
1119
- );
1120
- }
1121
- export function promptTokensDetailsFromJSON(
1122
- jsonString: string,
1123
- ): SafeParseResult<PromptTokensDetails, SDKValidationError> {
1124
- return safeParse(
1125
- jsonString,
1126
- (x) => PromptTokensDetails$inboundSchema.parse(JSON.parse(x)),
1127
- `Failed to parse 'PromptTokensDetails' from JSON`,
1128
- );
1129
- }
1130
-
1131
- /** @internal */
1132
- export const CompletionTokensDetails$inboundSchema: z.ZodType<
1133
- CompletionTokensDetails,
1134
- z.ZodTypeDef,
1135
- unknown
1136
- > = z.object({
1137
- reasoning_tokens: z.nullable(z.number()).optional(),
1138
- accepted_prediction_tokens: z.nullable(z.number()).optional(),
1139
- rejected_prediction_tokens: z.nullable(z.number()).optional(),
1140
- audio_tokens: z.nullable(z.number().int()).optional(),
1141
- }).transform((v) => {
1142
- return remap$(v, {
1143
- "reasoning_tokens": "reasoningTokens",
1144
- "accepted_prediction_tokens": "acceptedPredictionTokens",
1145
- "rejected_prediction_tokens": "rejectedPredictionTokens",
1146
- "audio_tokens": "audioTokens",
1147
- });
1148
- });
1149
- /** @internal */
1150
- export type CompletionTokensDetails$Outbound = {
1151
- reasoning_tokens?: number | null | undefined;
1152
- accepted_prediction_tokens?: number | null | undefined;
1153
- rejected_prediction_tokens?: number | null | undefined;
1154
- audio_tokens?: number | null | undefined;
1155
- };
1156
-
1157
- /** @internal */
1158
- export const CompletionTokensDetails$outboundSchema: z.ZodType<
1159
- CompletionTokensDetails$Outbound,
1160
- z.ZodTypeDef,
1161
- CompletionTokensDetails
1162
- > = z.object({
1163
- reasoningTokens: z.nullable(z.number()).optional(),
1164
- acceptedPredictionTokens: z.nullable(z.number()).optional(),
1165
- rejectedPredictionTokens: z.nullable(z.number()).optional(),
1166
- audioTokens: z.nullable(z.number().int()).optional(),
1167
- }).transform((v) => {
1168
- return remap$(v, {
1169
- reasoningTokens: "reasoning_tokens",
1170
- acceptedPredictionTokens: "accepted_prediction_tokens",
1171
- rejectedPredictionTokens: "rejected_prediction_tokens",
1172
- audioTokens: "audio_tokens",
1173
- });
1174
- });
1175
-
1176
- export function completionTokensDetailsToJSON(
1177
- completionTokensDetails: CompletionTokensDetails,
1178
- ): string {
1179
- return JSON.stringify(
1180
- CompletionTokensDetails$outboundSchema.parse(completionTokensDetails),
1181
- );
1182
- }
1183
- export function completionTokensDetailsFromJSON(
1184
- jsonString: string,
1185
- ): SafeParseResult<CompletionTokensDetails, SDKValidationError> {
1186
- return safeParse(
1187
- jsonString,
1188
- (x) => CompletionTokensDetails$inboundSchema.parse(JSON.parse(x)),
1189
- `Failed to parse 'CompletionTokensDetails' from JSON`,
1190
- );
1191
- }
1192
-
1193
- /** @internal */
1194
- export const CreateAgentResponseUsage$inboundSchema: z.ZodType<
1195
- CreateAgentResponseUsage,
1196
- z.ZodTypeDef,
1197
- unknown
1198
- > = z.object({
1199
- completion_tokens: z.number().optional(),
1200
- prompt_tokens: z.number().optional(),
1201
- total_tokens: z.number().optional(),
1202
- prompt_tokens_details: z.nullable(
1203
- z.lazy(() => PromptTokensDetails$inboundSchema),
1204
- ).optional(),
1205
- completion_tokens_details: z.nullable(
1206
- z.lazy(() => CompletionTokensDetails$inboundSchema),
1207
- ).optional(),
1208
- }).transform((v) => {
1209
- return remap$(v, {
1210
- "completion_tokens": "completionTokens",
1211
- "prompt_tokens": "promptTokens",
1212
- "total_tokens": "totalTokens",
1213
- "prompt_tokens_details": "promptTokensDetails",
1214
- "completion_tokens_details": "completionTokensDetails",
1215
- });
1216
- });
1217
- /** @internal */
1218
- export type CreateAgentResponseUsage$Outbound = {
1219
- completion_tokens?: number | undefined;
1220
- prompt_tokens?: number | undefined;
1221
- total_tokens?: number | undefined;
1222
- prompt_tokens_details?: PromptTokensDetails$Outbound | null | undefined;
1223
- completion_tokens_details?:
1224
- | CompletionTokensDetails$Outbound
1225
- | null
1226
- | undefined;
1227
- };
1228
-
1229
- /** @internal */
1230
- export const CreateAgentResponseUsage$outboundSchema: z.ZodType<
1231
- CreateAgentResponseUsage$Outbound,
1232
- z.ZodTypeDef,
1233
- CreateAgentResponseUsage
1234
- > = z.object({
1235
- completionTokens: z.number().optional(),
1236
- promptTokens: z.number().optional(),
1237
- totalTokens: z.number().optional(),
1238
- promptTokensDetails: z.nullable(
1239
- z.lazy(() => PromptTokensDetails$outboundSchema),
1240
- ).optional(),
1241
- completionTokensDetails: z.nullable(
1242
- z.lazy(() => CompletionTokensDetails$outboundSchema),
1243
- ).optional(),
1244
- }).transform((v) => {
1245
- return remap$(v, {
1246
- completionTokens: "completion_tokens",
1247
- promptTokens: "prompt_tokens",
1248
- totalTokens: "total_tokens",
1249
- promptTokensDetails: "prompt_tokens_details",
1250
- completionTokensDetails: "completion_tokens_details",
1251
- });
1252
- });
1253
-
1254
- export function createAgentResponseUsageToJSON(
1255
- createAgentResponseUsage: CreateAgentResponseUsage,
1256
- ): string {
1257
- return JSON.stringify(
1258
- CreateAgentResponseUsage$outboundSchema.parse(createAgentResponseUsage),
1259
- );
1260
- }
1261
- export function createAgentResponseUsageFromJSON(
1262
- jsonString: string,
1263
- ): SafeParseResult<CreateAgentResponseUsage, SDKValidationError> {
1264
- return safeParse(
1265
- jsonString,
1266
- (x) => CreateAgentResponseUsage$inboundSchema.parse(JSON.parse(x)),
1267
- `Failed to parse 'CreateAgentResponseUsage' from JSON`,
1268
- );
1269
- }
1270
-
1271
- /** @internal */
1272
- export const CreateAgentResponseResponseBody$inboundSchema: z.ZodType<
1273
- CreateAgentResponseResponseBody,
1274
- z.ZodTypeDef,
1275
- unknown
1276
- > = z.object({
1277
- _id: z.string(),
1278
- task_id: z.string(),
1279
- output: z.array(z.lazy(() => Output$inboundSchema)),
1280
- created_at: z.string(),
1281
- model: z.string(),
1282
- usage: z.nullable(z.lazy(() => CreateAgentResponseUsage$inboundSchema))
1283
- .optional(),
1284
- }).transform((v) => {
1285
- return remap$(v, {
1286
- "_id": "id",
1287
- "task_id": "taskId",
1288
- "created_at": "createdAt",
1289
- });
1290
- });
1291
- /** @internal */
1292
- export type CreateAgentResponseResponseBody$Outbound = {
1293
- _id: string;
1294
- task_id: string;
1295
- output: Array<Output$Outbound>;
1296
- created_at: string;
1297
- model: string;
1298
- usage?: CreateAgentResponseUsage$Outbound | null | undefined;
1299
- };
1300
-
1301
- /** @internal */
1302
- export const CreateAgentResponseResponseBody$outboundSchema: z.ZodType<
1303
- CreateAgentResponseResponseBody$Outbound,
1304
- z.ZodTypeDef,
1305
- CreateAgentResponseResponseBody
1306
- > = z.object({
1307
- id: z.string(),
1308
- taskId: z.string(),
1309
- output: z.array(z.lazy(() => Output$outboundSchema)),
1310
- createdAt: z.string(),
1311
- model: z.string(),
1312
- usage: z.nullable(z.lazy(() => CreateAgentResponseUsage$outboundSchema))
1313
- .optional(),
1314
- }).transform((v) => {
1315
- return remap$(v, {
1316
- id: "_id",
1317
- taskId: "task_id",
1318
- createdAt: "created_at",
1319
- });
1320
- });
1321
-
1322
- export function createAgentResponseResponseBodyToJSON(
1323
- createAgentResponseResponseBody: CreateAgentResponseResponseBody,
1324
- ): string {
1325
- return JSON.stringify(
1326
- CreateAgentResponseResponseBody$outboundSchema.parse(
1327
- createAgentResponseResponseBody,
1328
- ),
1329
- );
1330
- }
1331
- export function createAgentResponseResponseBodyFromJSON(
1332
- jsonString: string,
1333
- ): SafeParseResult<CreateAgentResponseResponseBody, SDKValidationError> {
1334
- return safeParse(
1335
- jsonString,
1336
- (x) => CreateAgentResponseResponseBody$inboundSchema.parse(JSON.parse(x)),
1337
- `Failed to parse 'CreateAgentResponseResponseBody' from JSON`,
1338
- );
1339
- }