@orq-ai/node 4.4.0 → 4.5.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 (451) hide show
  1. package/examples/package-lock.json +4 -7
  2. package/jsr.json +1 -1
  3. package/lib/config.d.ts +2 -2
  4. package/lib/config.js +2 -2
  5. package/lib/config.js.map +1 -1
  6. package/models/components/partdoneevent.js +1 -1
  7. package/models/components/reasoningpart.js +1 -1
  8. package/models/operations/createcontact.js +1 -1
  9. package/models/operations/createdataset.js +1 -1
  10. package/models/operations/createdatasetitem.js +4 -4
  11. package/models/operations/createdatasource.js +1 -1
  12. package/models/operations/createeval.js +16 -16
  13. package/models/operations/createidentity.js +1 -1
  14. package/models/operations/createtool.js +6 -6
  15. package/models/operations/fileget.js +1 -1
  16. package/models/operations/filelist.js +1 -1
  17. package/models/operations/fileupload.js +1 -1
  18. package/models/operations/getalltools.js +6 -6
  19. package/models/operations/getevals.js +16 -16
  20. package/models/operations/listdatasetdatapoints.js +4 -4
  21. package/models/operations/listdatasets.js +1 -1
  22. package/models/operations/listdatasources.js +1 -1
  23. package/models/operations/listidentities.js +1 -1
  24. package/models/operations/retrievedatapoint.js +4 -4
  25. package/models/operations/retrievedataset.js +1 -1
  26. package/models/operations/retrievedatasource.js +1 -1
  27. package/models/operations/retrieveidentity.js +1 -1
  28. package/models/operations/retrievetool.js +6 -6
  29. package/models/operations/runagent.js +1 -1
  30. package/models/operations/streamrunagent.js +1 -1
  31. package/models/operations/updatedatapoint.js +4 -4
  32. package/models/operations/updatedataset.js +1 -1
  33. package/models/operations/updatedatasource.js +1 -1
  34. package/models/operations/updateeval.js +16 -16
  35. package/models/operations/updateidentity.js +1 -1
  36. package/models/operations/updatetool.js +7 -7
  37. package/package.json +4 -3
  38. package/src/lib/config.ts +2 -2
  39. package/src/models/components/partdoneevent.ts +1 -1
  40. package/src/models/components/reasoningpart.ts +1 -1
  41. package/src/models/operations/createcontact.ts +1 -1
  42. package/src/models/operations/createdataset.ts +1 -1
  43. package/src/models/operations/createdatasetitem.ts +4 -4
  44. package/src/models/operations/createdatasource.ts +1 -1
  45. package/src/models/operations/createeval.ts +16 -16
  46. package/src/models/operations/createidentity.ts +1 -1
  47. package/src/models/operations/createtool.ts +6 -6
  48. package/src/models/operations/fileget.ts +1 -1
  49. package/src/models/operations/filelist.ts +1 -1
  50. package/src/models/operations/fileupload.ts +1 -1
  51. package/src/models/operations/getalltools.ts +6 -6
  52. package/src/models/operations/getevals.ts +16 -16
  53. package/src/models/operations/listdatasetdatapoints.ts +4 -4
  54. package/src/models/operations/listdatasets.ts +1 -1
  55. package/src/models/operations/listdatasources.ts +1 -1
  56. package/src/models/operations/listidentities.ts +1 -1
  57. package/src/models/operations/retrievedatapoint.ts +4 -4
  58. package/src/models/operations/retrievedataset.ts +1 -1
  59. package/src/models/operations/retrievedatasource.ts +1 -1
  60. package/src/models/operations/retrieveidentity.ts +1 -1
  61. package/src/models/operations/retrievetool.ts +6 -6
  62. package/src/models/operations/runagent.ts +1 -1
  63. package/src/models/operations/streamrunagent.ts +1 -1
  64. package/src/models/operations/updatedatapoint.ts +4 -4
  65. package/src/models/operations/updatedataset.ts +1 -1
  66. package/src/models/operations/updatedatasource.ts +1 -1
  67. package/src/models/operations/updateeval.ts +16 -16
  68. package/src/models/operations/updateidentity.ts +1 -1
  69. package/src/models/operations/updatetool.ts +7 -7
  70. package/_speakeasy/.github/action-inputs-config.json +0 -53
  71. package/_speakeasy/.github/action-security-config.json +0 -88
  72. package/packages/orq-rc/examples/contactsCreate.example.ts +0 -42
  73. package/packages/orq-rc/examples/package-lock.json +0 -610
  74. package/packages/orq-rc/examples/package.json +0 -18
  75. package/packages/orq-rc/jsr.json +0 -28
  76. package/packages/orq-rc/package-lock.json +0 -1740
  77. package/packages/orq-rc/package.json +0 -30
  78. package/packages/orq-rc/src/core.ts +0 -13
  79. package/packages/orq-rc/src/funcs/agentsCreate.ts +0 -161
  80. package/packages/orq-rc/src/funcs/agentsDelete.ts +0 -180
  81. package/packages/orq-rc/src/funcs/agentsInvoke.ts +0 -177
  82. package/packages/orq-rc/src/funcs/agentsList.ts +0 -179
  83. package/packages/orq-rc/src/funcs/agentsResponsesCreate.ts +0 -183
  84. package/packages/orq-rc/src/funcs/agentsRetrieve.ts +0 -180
  85. package/packages/orq-rc/src/funcs/agentsRun.ts +0 -162
  86. package/packages/orq-rc/src/funcs/agentsStream.ts +0 -201
  87. package/packages/orq-rc/src/funcs/agentsStreamRun.ts +0 -186
  88. package/packages/orq-rc/src/funcs/agentsUpdate.ts +0 -184
  89. package/packages/orq-rc/src/funcs/annotationsCreate.ts +0 -171
  90. package/packages/orq-rc/src/funcs/annotationsDelete.ts +0 -171
  91. package/packages/orq-rc/src/funcs/chunkingParse.ts +0 -160
  92. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -160
  93. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -167
  94. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -165
  95. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -171
  96. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -167
  97. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -182
  98. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -167
  99. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -174
  100. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -175
  101. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -181
  102. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -176
  103. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -179
  104. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -168
  105. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -176
  106. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -176
  107. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -168
  108. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -183
  109. package/packages/orq-rc/src/funcs/evalsAll.ts +0 -173
  110. package/packages/orq-rc/src/funcs/evalsCreate.ts +0 -169
  111. package/packages/orq-rc/src/funcs/evalsDelete.ts +0 -173
  112. package/packages/orq-rc/src/funcs/evalsInvoke.ts +0 -181
  113. package/packages/orq-rc/src/funcs/evalsUpdate.ts +0 -173
  114. package/packages/orq-rc/src/funcs/evaluatorsGetV2EvaluatorsIdVersions.ts +0 -183
  115. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -160
  116. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -187
  117. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -164
  118. package/packages/orq-rc/src/funcs/filesGet.ts +0 -166
  119. package/packages/orq-rc/src/funcs/filesList.ts +0 -167
  120. package/packages/orq-rc/src/funcs/identitiesCreate.ts +0 -165
  121. package/packages/orq-rc/src/funcs/identitiesDelete.ts +0 -176
  122. package/packages/orq-rc/src/funcs/identitiesList.ts +0 -170
  123. package/packages/orq-rc/src/funcs/identitiesRetrieve.ts +0 -175
  124. package/packages/orq-rc/src/funcs/identitiesUpdate.ts +0 -176
  125. package/packages/orq-rc/src/funcs/knowledgeCreate.ts +0 -158
  126. package/packages/orq-rc/src/funcs/knowledgeCreateChunks.ts +0 -171
  127. package/packages/orq-rc/src/funcs/knowledgeCreateDatasource.ts +0 -166
  128. package/packages/orq-rc/src/funcs/knowledgeDelete.ts +0 -167
  129. package/packages/orq-rc/src/funcs/knowledgeDeleteChunk.ts +0 -174
  130. package/packages/orq-rc/src/funcs/knowledgeDeleteChunks.ts +0 -170
  131. package/packages/orq-rc/src/funcs/knowledgeDeleteDatasource.ts +0 -173
  132. package/packages/orq-rc/src/funcs/knowledgeGetChunksCount.ts +0 -170
  133. package/packages/orq-rc/src/funcs/knowledgeList.ts +0 -169
  134. package/packages/orq-rc/src/funcs/knowledgeListChunks.ts +0 -178
  135. package/packages/orq-rc/src/funcs/knowledgeListChunksPaginated.ts +0 -171
  136. package/packages/orq-rc/src/funcs/knowledgeListDatasources.ts +0 -174
  137. package/packages/orq-rc/src/funcs/knowledgeRetrieve.ts +0 -166
  138. package/packages/orq-rc/src/funcs/knowledgeRetrieveChunk.ts +0 -173
  139. package/packages/orq-rc/src/funcs/knowledgeRetrieveDatasource.ts +0 -169
  140. package/packages/orq-rc/src/funcs/knowledgeSearch.ts +0 -167
  141. package/packages/orq-rc/src/funcs/knowledgeUpdate.ts +0 -164
  142. package/packages/orq-rc/src/funcs/knowledgeUpdateChunk.ts +0 -174
  143. package/packages/orq-rc/src/funcs/knowledgeUpdateDatasource.ts +0 -170
  144. package/packages/orq-rc/src/funcs/memoryStoresCreate.ts +0 -162
  145. package/packages/orq-rc/src/funcs/memoryStoresCreateDocument.ts +0 -176
  146. package/packages/orq-rc/src/funcs/memoryStoresCreateMemory.ts +0 -170
  147. package/packages/orq-rc/src/funcs/memoryStoresDelete.ts +0 -168
  148. package/packages/orq-rc/src/funcs/memoryStoresDeleteDocument.ts +0 -185
  149. package/packages/orq-rc/src/funcs/memoryStoresDeleteMemory.ts +0 -180
  150. package/packages/orq-rc/src/funcs/memoryStoresList.ts +0 -178
  151. package/packages/orq-rc/src/funcs/memoryStoresListDocuments.ts +0 -184
  152. package/packages/orq-rc/src/funcs/memoryStoresListMemories.ts +0 -177
  153. package/packages/orq-rc/src/funcs/memoryStoresRetrieve.ts +0 -177
  154. package/packages/orq-rc/src/funcs/memoryStoresRetrieveDocument.ts +0 -179
  155. package/packages/orq-rc/src/funcs/memoryStoresRetrieveMemory.ts +0 -174
  156. package/packages/orq-rc/src/funcs/memoryStoresUpdate.ts +0 -168
  157. package/packages/orq-rc/src/funcs/memoryStoresUpdateDocument.ts +0 -180
  158. package/packages/orq-rc/src/funcs/memoryStoresUpdateMemory.ts +0 -175
  159. package/packages/orq-rc/src/funcs/modelsList.ts +0 -142
  160. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -160
  161. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -173
  162. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -181
  163. package/packages/orq-rc/src/funcs/promptsList.ts +0 -167
  164. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -173
  165. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -166
  166. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -173
  167. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -161
  168. package/packages/orq-rc/src/funcs/routerAudioSpeechCreate.ts +0 -161
  169. package/packages/orq-rc/src/funcs/routerAudioTranscriptionsCreate.ts +0 -262
  170. package/packages/orq-rc/src/funcs/routerAudioTranslationsCreate.ts +0 -252
  171. package/packages/orq-rc/src/funcs/routerChatCompletionsCreate.ts +0 -168
  172. package/packages/orq-rc/src/funcs/routerCompletionsCreate.ts +0 -168
  173. package/packages/orq-rc/src/funcs/routerEmbeddingsCreate.ts +0 -161
  174. package/packages/orq-rc/src/funcs/routerImagesEditsCreate.ts +0 -222
  175. package/packages/orq-rc/src/funcs/routerImagesGenerationsCreate.ts +0 -160
  176. package/packages/orq-rc/src/funcs/routerImagesVariationsCreate.ts +0 -218
  177. package/packages/orq-rc/src/funcs/routerModerationsCreate.ts +0 -167
  178. package/packages/orq-rc/src/funcs/routerOcr.ts +0 -158
  179. package/packages/orq-rc/src/funcs/routerRerankCreate.ts +0 -160
  180. package/packages/orq-rc/src/funcs/routerResponsesCreate.ts +0 -167
  181. package/packages/orq-rc/src/funcs/toolsCreate.ts +0 -163
  182. package/packages/orq-rc/src/funcs/toolsDelete.ts +0 -167
  183. package/packages/orq-rc/src/funcs/toolsGetV2ToolsToolIdVersions.ts +0 -183
  184. package/packages/orq-rc/src/funcs/toolsGetV2ToolsToolIdVersionsVersionId.ts +0 -190
  185. package/packages/orq-rc/src/funcs/toolsList.ts +0 -176
  186. package/packages/orq-rc/src/funcs/toolsRetrieve.ts +0 -166
  187. package/packages/orq-rc/src/funcs/toolsUpdate.ts +0 -176
  188. package/packages/orq-rc/src/hooks/global.ts +0 -44
  189. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  190. package/packages/orq-rc/src/hooks/index.ts +0 -6
  191. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  192. package/packages/orq-rc/src/hooks/types.ts +0 -112
  193. package/packages/orq-rc/src/index.ts +0 -9
  194. package/packages/orq-rc/src/lib/base64.ts +0 -37
  195. package/packages/orq-rc/src/lib/config.ts +0 -74
  196. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  197. package/packages/orq-rc/src/lib/encodings.ts +0 -497
  198. package/packages/orq-rc/src/lib/env.ts +0 -89
  199. package/packages/orq-rc/src/lib/event-streams.ts +0 -152
  200. package/packages/orq-rc/src/lib/files.ts +0 -82
  201. package/packages/orq-rc/src/lib/http.ts +0 -323
  202. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  203. package/packages/orq-rc/src/lib/logger.ts +0 -9
  204. package/packages/orq-rc/src/lib/matchers.ts +0 -345
  205. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  206. package/packages/orq-rc/src/lib/retries.ts +0 -218
  207. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  208. package/packages/orq-rc/src/lib/sdks.ts +0 -407
  209. package/packages/orq-rc/src/lib/security.ts +0 -264
  210. package/packages/orq-rc/src/lib/url.ts +0 -33
  211. package/packages/orq-rc/src/models/components/actionreviewedstreamingevent.ts +0 -99
  212. package/packages/orq-rc/src/models/components/actionreviewrequestedstreamingevent.ts +0 -185
  213. package/packages/orq-rc/src/models/components/agenterroredstreamingevent.ts +0 -73
  214. package/packages/orq-rc/src/models/components/agentexecutionstartedstreamingevent.ts +0 -91
  215. package/packages/orq-rc/src/models/components/agenthandedoffstreamingevent.ts +0 -71
  216. package/packages/orq-rc/src/models/components/agentinactivestreamingevent.ts +0 -507
  217. package/packages/orq-rc/src/models/components/agentmessagecreatedstreamingevent.ts +0 -165
  218. package/packages/orq-rc/src/models/components/agentresponsemessage.ts +0 -103
  219. package/packages/orq-rc/src/models/components/agentstartedstreamingevent.ts +0 -517
  220. package/packages/orq-rc/src/models/components/agentthoughtstreamingevent.ts +0 -807
  221. package/packages/orq-rc/src/models/components/audiocontentpartschema.ts +0 -136
  222. package/packages/orq-rc/src/models/components/createagentresponse.ts +0 -299
  223. package/packages/orq-rc/src/models/components/datapart.ts +0 -38
  224. package/packages/orq-rc/src/models/components/errorpart.ts +0 -58
  225. package/packages/orq-rc/src/models/components/errorstreamingevent.ts +0 -66
  226. package/packages/orq-rc/src/models/components/executionnamedstreamingevent.ts +0 -71
  227. package/packages/orq-rc/src/models/components/executionreviewedstreamingevent.ts +0 -61
  228. package/packages/orq-rc/src/models/components/executionreviewrequiredstreamingevent.ts +0 -67
  229. package/packages/orq-rc/src/models/components/filecontentpartschema.ts +0 -87
  230. package/packages/orq-rc/src/models/components/filepart.ts +0 -218
  231. package/packages/orq-rc/src/models/components/imagecontentpartschema.ts +0 -268
  232. package/packages/orq-rc/src/models/components/index.ts +0 -56
  233. package/packages/orq-rc/src/models/components/invokedeploymentrequest.ts +0 -3450
  234. package/packages/orq-rc/src/models/components/partdelta.ts +0 -39
  235. package/packages/orq-rc/src/models/components/partdeltaevent.ts +0 -73
  236. package/packages/orq-rc/src/models/components/partdoneevent.ts +0 -139
  237. package/packages/orq-rc/src/models/components/publiccontact.ts +0 -71
  238. package/packages/orq-rc/src/models/components/publicidentity.ts +0 -69
  239. package/packages/orq-rc/src/models/components/reasoningpart.ts +0 -62
  240. package/packages/orq-rc/src/models/components/reasoningpartschema.ts +0 -71
  241. package/packages/orq-rc/src/models/components/redactedreasoningpartschema.ts +0 -66
  242. package/packages/orq-rc/src/models/components/refusalpartschema.ts +0 -64
  243. package/packages/orq-rc/src/models/components/responsedoneevent.ts +0 -318
  244. package/packages/orq-rc/src/models/components/responsefailedevent.ts +0 -72
  245. package/packages/orq-rc/src/models/components/responsestartedevent.ts +0 -91
  246. package/packages/orq-rc/src/models/components/responsestreamingevent.ts +0 -85
  247. package/packages/orq-rc/src/models/components/reviewoutcome.ts +0 -23
  248. package/packages/orq-rc/src/models/components/security.ts +0 -32
  249. package/packages/orq-rc/src/models/components/textcontentpartschema.ts +0 -207
  250. package/packages/orq-rc/src/models/components/textpart.ts +0 -54
  251. package/packages/orq-rc/src/models/components/thinkingconfigdisabledschema.ts +0 -59
  252. package/packages/orq-rc/src/models/components/thinkingconfigenabledschema.ts +0 -106
  253. package/packages/orq-rc/src/models/components/timeoutstreamingevent.ts +0 -64
  254. package/packages/orq-rc/src/models/components/toolcallpart.ts +0 -51
  255. package/packages/orq-rc/src/models/components/tooldoneevent.ts +0 -77
  256. package/packages/orq-rc/src/models/components/toolexecutionfailedstreamingevent.ts +0 -230
  257. package/packages/orq-rc/src/models/components/toolexecutionfinishedstreamingevent.ts +0 -214
  258. package/packages/orq-rc/src/models/components/toolexecutionstartedstreamingevent.ts +0 -200
  259. package/packages/orq-rc/src/models/components/toolfailedevent.ts +0 -77
  260. package/packages/orq-rc/src/models/components/toolresultpart.ts +0 -71
  261. package/packages/orq-rc/src/models/components/toolreviewdoneevent.ts +0 -78
  262. package/packages/orq-rc/src/models/components/toolreviewrequestedevent.ts +0 -87
  263. package/packages/orq-rc/src/models/components/toolstartedevent.ts +0 -82
  264. package/packages/orq-rc/src/models/errors/apierror.ts +0 -40
  265. package/packages/orq-rc/src/models/errors/createeval.ts +0 -51
  266. package/packages/orq-rc/src/models/errors/createmoderation.ts +0 -84
  267. package/packages/orq-rc/src/models/errors/createtranscription.ts +0 -87
  268. package/packages/orq-rc/src/models/errors/createtranslation.ts +0 -87
  269. package/packages/orq-rc/src/models/errors/deleteagent.ts +0 -51
  270. package/packages/orq-rc/src/models/errors/deleteeval.ts +0 -51
  271. package/packages/orq-rc/src/models/errors/deleteidentity.ts +0 -62
  272. package/packages/orq-rc/src/models/errors/deleteprompt.ts +0 -51
  273. package/packages/orq-rc/src/models/errors/getevals.ts +0 -51
  274. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -51
  275. package/packages/orq-rc/src/models/errors/getv2evaluatorsidversions.ts +0 -51
  276. package/packages/orq-rc/src/models/errors/getv2toolstoolidversions.ts +0 -51
  277. package/packages/orq-rc/src/models/errors/getv2toolstoolidversionsversionid.ts +0 -52
  278. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -59
  279. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  280. package/packages/orq-rc/src/models/errors/index.ts +0 -33
  281. package/packages/orq-rc/src/models/errors/invokeeval.ts +0 -141
  282. package/packages/orq-rc/src/models/errors/orqerror.ts +0 -35
  283. package/packages/orq-rc/src/models/errors/responsevalidationerror.ts +0 -50
  284. package/packages/orq-rc/src/models/errors/retrieveagentrequest.ts +0 -51
  285. package/packages/orq-rc/src/models/errors/retrieveidentity.ts +0 -62
  286. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -109
  287. package/packages/orq-rc/src/models/errors/streamagent.ts +0 -51
  288. package/packages/orq-rc/src/models/errors/streamrunagent.ts +0 -51
  289. package/packages/orq-rc/src/models/errors/updateagent.ts +0 -51
  290. package/packages/orq-rc/src/models/errors/updateeval.ts +0 -51
  291. package/packages/orq-rc/src/models/errors/updateidentity.ts +0 -54
  292. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -51
  293. package/packages/orq-rc/src/models/errors/updatetool.ts +0 -62
  294. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -39
  295. package/packages/orq-rc/src/models/operations/createagentrequest.ts +0 -7093
  296. package/packages/orq-rc/src/models/operations/createagentresponserequest.ts +0 -609
  297. package/packages/orq-rc/src/models/operations/createannotation.ts +0 -162
  298. package/packages/orq-rc/src/models/operations/createchatcompletion.ts +0 -6381
  299. package/packages/orq-rc/src/models/operations/createchunk.ts +0 -222
  300. package/packages/orq-rc/src/models/operations/createcompletion.ts +0 -3413
  301. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -156
  302. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -162
  303. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -2551
  304. package/packages/orq-rc/src/models/operations/createdatasource.ts +0 -437
  305. package/packages/orq-rc/src/models/operations/createembedding.ts +0 -947
  306. package/packages/orq-rc/src/models/operations/createeval.ts +0 -4170
  307. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -144
  308. package/packages/orq-rc/src/models/operations/createidentity.ts +0 -162
  309. package/packages/orq-rc/src/models/operations/createimage.ts +0 -1028
  310. package/packages/orq-rc/src/models/operations/createimageedit.ts +0 -1045
  311. package/packages/orq-rc/src/models/operations/createimagevariation.ts +0 -1067
  312. package/packages/orq-rc/src/models/operations/createknowledge.ts +0 -944
  313. package/packages/orq-rc/src/models/operations/creatememory.ts +0 -142
  314. package/packages/orq-rc/src/models/operations/creatememorydocument.ts +0 -152
  315. package/packages/orq-rc/src/models/operations/creatememorystore.ts +0 -199
  316. package/packages/orq-rc/src/models/operations/createmoderation.ts +0 -664
  317. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -5401
  318. package/packages/orq-rc/src/models/operations/creatererank.ts +0 -890
  319. package/packages/orq-rc/src/models/operations/createresponse.ts +0 -3324
  320. package/packages/orq-rc/src/models/operations/createspeech.ts +0 -700
  321. package/packages/orq-rc/src/models/operations/createtool.ts +0 -2499
  322. package/packages/orq-rc/src/models/operations/createtranscription.ts +0 -955
  323. package/packages/orq-rc/src/models/operations/createtranslation.ts +0 -930
  324. package/packages/orq-rc/src/models/operations/deleteagent.ts +0 -39
  325. package/packages/orq-rc/src/models/operations/deleteannotation.ts +0 -79
  326. package/packages/orq-rc/src/models/operations/deletechunk.ts +0 -53
  327. package/packages/orq-rc/src/models/operations/deletechunks.ts +0 -125
  328. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -46
  329. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -39
  330. package/packages/orq-rc/src/models/operations/deletedatasource.ts +0 -46
  331. package/packages/orq-rc/src/models/operations/deleteeval.ts +0 -31
  332. package/packages/orq-rc/src/models/operations/deleteidentity.ts +0 -34
  333. package/packages/orq-rc/src/models/operations/deleteknowledge.ts +0 -39
  334. package/packages/orq-rc/src/models/operations/deletememory.ts +0 -46
  335. package/packages/orq-rc/src/models/operations/deletememorydocument.ts +0 -55
  336. package/packages/orq-rc/src/models/operations/deletememorystore.ts +0 -39
  337. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -34
  338. package/packages/orq-rc/src/models/operations/deletetool.ts +0 -36
  339. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -2370
  340. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -4525
  341. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -690
  342. package/packages/orq-rc/src/models/operations/deployments.ts +0 -1268
  343. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -4614
  344. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -39
  345. package/packages/orq-rc/src/models/operations/fileget.ts +0 -116
  346. package/packages/orq-rc/src/models/operations/filelist.ts +0 -172
  347. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -170
  348. package/packages/orq-rc/src/models/operations/getallmemories.ts +0 -173
  349. package/packages/orq-rc/src/models/operations/getallmemorydocuments.ts +0 -188
  350. package/packages/orq-rc/src/models/operations/getallmemorystores.ts +0 -200
  351. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -3164
  352. package/packages/orq-rc/src/models/operations/getalltools.ts +0 -1398
  353. package/packages/orq-rc/src/models/operations/getchunkscount.ts +0 -121
  354. package/packages/orq-rc/src/models/operations/getevals.ts +0 -2842
  355. package/packages/orq-rc/src/models/operations/getonechunk.ts +0 -171
  356. package/packages/orq-rc/src/models/operations/getoneknowledge.ts +0 -652
  357. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -3089
  358. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -3134
  359. package/packages/orq-rc/src/models/operations/getv2evaluatorsidversions.ts +0 -162
  360. package/packages/orq-rc/src/models/operations/getv2toolstoolidversions.ts +0 -163
  361. package/packages/orq-rc/src/models/operations/getv2toolstoolidversionsversionid.ts +0 -110
  362. package/packages/orq-rc/src/models/operations/index.ts +0 -113
  363. package/packages/orq-rc/src/models/operations/invokeagent.ts +0 -733
  364. package/packages/orq-rc/src/models/operations/invokeeval.ts +0 -1253
  365. package/packages/orq-rc/src/models/operations/listagents.ts +0 -3018
  366. package/packages/orq-rc/src/models/operations/listchunks.ts +0 -260
  367. package/packages/orq-rc/src/models/operations/listchunkspaginated.ts +0 -263
  368. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -1498
  369. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -205
  370. package/packages/orq-rc/src/models/operations/listdatasources.ts +0 -235
  371. package/packages/orq-rc/src/models/operations/listidentities.ts +0 -275
  372. package/packages/orq-rc/src/models/operations/listknowledgebases.ts +0 -642
  373. package/packages/orq-rc/src/models/operations/listmodels.ts +0 -143
  374. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -3209
  375. package/packages/orq-rc/src/models/operations/parse.ts +0 -777
  376. package/packages/orq-rc/src/models/operations/postv2routerocr.ts +0 -478
  377. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -108
  378. package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +0 -3104
  379. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -1402
  380. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -150
  381. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +0 -152
  382. package/packages/orq-rc/src/models/operations/retrieveidentity.ts +0 -117
  383. package/packages/orq-rc/src/models/operations/retrievememory.ts +0 -112
  384. package/packages/orq-rc/src/models/operations/retrievememorydocument.ts +0 -118
  385. package/packages/orq-rc/src/models/operations/retrievememorystore.ts +0 -144
  386. package/packages/orq-rc/src/models/operations/retrievetool.ts +0 -1379
  387. package/packages/orq-rc/src/models/operations/runagent.ts +0 -5351
  388. package/packages/orq-rc/src/models/operations/searchknowledge.ts +0 -1762
  389. package/packages/orq-rc/src/models/operations/streamagent.ts +0 -629
  390. package/packages/orq-rc/src/models/operations/streamrunagent.ts +0 -5546
  391. package/packages/orq-rc/src/models/operations/updateagent.ts +0 -7447
  392. package/packages/orq-rc/src/models/operations/updatechunk.ts +0 -236
  393. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -2555
  394. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -206
  395. package/packages/orq-rc/src/models/operations/updatedatasource.ts +0 -186
  396. package/packages/orq-rc/src/models/operations/updateeval.ts +0 -4066
  397. package/packages/orq-rc/src/models/operations/updateidentity.ts +0 -189
  398. package/packages/orq-rc/src/models/operations/updateknowledge.ts +0 -1231
  399. package/packages/orq-rc/src/models/operations/updatememory.ts +0 -142
  400. package/packages/orq-rc/src/models/operations/updatememorydocument.ts +0 -159
  401. package/packages/orq-rc/src/models/operations/updatememorystore.ts +0 -246
  402. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -5472
  403. package/packages/orq-rc/src/models/operations/updatetool.ts +0 -2696
  404. package/packages/orq-rc/src/sdk/agents.ts +0 -196
  405. package/packages/orq-rc/src/sdk/annotations.ts +0 -39
  406. package/packages/orq-rc/src/sdk/audio.ts +0 -25
  407. package/packages/orq-rc/src/sdk/chat.ts +0 -13
  408. package/packages/orq-rc/src/sdk/chunking.ts +0 -27
  409. package/packages/orq-rc/src/sdk/completions.ts +0 -32
  410. package/packages/orq-rc/src/sdk/contacts.ts +0 -27
  411. package/packages/orq-rc/src/sdk/datasets.ts +0 -204
  412. package/packages/orq-rc/src/sdk/deployments.ts +0 -89
  413. package/packages/orq-rc/src/sdk/edits.ts +0 -27
  414. package/packages/orq-rc/src/sdk/embeddings.ts +0 -27
  415. package/packages/orq-rc/src/sdk/evals.ts +0 -84
  416. package/packages/orq-rc/src/sdk/evaluators.ts +0 -27
  417. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  418. package/packages/orq-rc/src/sdk/files.ts +0 -78
  419. package/packages/orq-rc/src/sdk/generations.ts +0 -27
  420. package/packages/orq-rc/src/sdk/identities.ts +0 -99
  421. package/packages/orq-rc/src/sdk/images.ts +0 -25
  422. package/packages/orq-rc/src/sdk/index.ts +0 -5
  423. package/packages/orq-rc/src/sdk/knowledge.ts +0 -309
  424. package/packages/orq-rc/src/sdk/memorystores.ts +0 -286
  425. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  426. package/packages/orq-rc/src/sdk/models.ts +0 -25
  427. package/packages/orq-rc/src/sdk/moderations.ts +0 -24
  428. package/packages/orq-rc/src/sdk/orqcompletions.ts +0 -32
  429. package/packages/orq-rc/src/sdk/orqresponses.ts +0 -32
  430. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  431. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  432. package/packages/orq-rc/src/sdk/rerank.ts +0 -27
  433. package/packages/orq-rc/src/sdk/responses.ts +0 -34
  434. package/packages/orq-rc/src/sdk/router.ts +0 -72
  435. package/packages/orq-rc/src/sdk/sdk.ts +0 -115
  436. package/packages/orq-rc/src/sdk/speech.ts +0 -27
  437. package/packages/orq-rc/src/sdk/tools.ts +0 -135
  438. package/packages/orq-rc/src/sdk/transcriptions.ts +0 -24
  439. package/packages/orq-rc/src/sdk/translations.ts +0 -24
  440. package/packages/orq-rc/src/sdk/variations.ts +0 -27
  441. package/packages/orq-rc/src/types/async.ts +0 -68
  442. package/packages/orq-rc/src/types/blobs.ts +0 -32
  443. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  444. package/packages/orq-rc/src/types/enums.ts +0 -45
  445. package/packages/orq-rc/src/types/fp.ts +0 -50
  446. package/packages/orq-rc/src/types/index.ts +0 -11
  447. package/packages/orq-rc/src/types/operations.ts +0 -105
  448. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  449. package/packages/orq-rc/src/types/streams.ts +0 -21
  450. package/packages/orq-rc/src/types/unrecognized.ts +0 -35
  451. package/packages/orq-rc/tsconfig.json +0 -40
@@ -1,2499 +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 {
8
- collectExtraKeys as collectExtraKeys$,
9
- safeParse,
10
- } from "../../lib/schemas.js";
11
- import { ClosedEnum } from "../../types/enums.js";
12
- import { Result as SafeParseResult } from "../../types/fp.js";
13
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
14
-
15
- /**
16
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
17
- */
18
- export const CreateToolRequestBodyToolsRequestStatus = {
19
- Live: "live",
20
- Draft: "draft",
21
- Pending: "pending",
22
- Published: "published",
23
- } as const;
24
- /**
25
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
26
- */
27
- export type CreateToolRequestBodyToolsRequestStatus = ClosedEnum<
28
- typeof CreateToolRequestBodyToolsRequestStatus
29
- >;
30
-
31
- /**
32
- * The type must be "object"
33
- */
34
- export const CreateToolRequestBodyToolsRequest5CodeToolType = {
35
- Object: "object",
36
- } as const;
37
- /**
38
- * The type must be "object"
39
- */
40
- export type CreateToolRequestBodyToolsRequest5CodeToolType = ClosedEnum<
41
- typeof CreateToolRequestBodyToolsRequest5CodeToolType
42
- >;
43
-
44
- /**
45
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
46
- */
47
- export type CreateToolRequestBodyParameters = {
48
- /**
49
- * The type must be "object"
50
- */
51
- type: CreateToolRequestBodyToolsRequest5CodeToolType;
52
- /**
53
- * The properties of the function parameters
54
- */
55
- properties: { [k: string]: any };
56
- /**
57
- * Array of required parameter names
58
- */
59
- required: Array<string>;
60
- additionalProperties?: { [k: string]: any } | undefined;
61
- };
62
-
63
- export const RequestBodyLanguage = {
64
- Python: "python",
65
- } as const;
66
- export type RequestBodyLanguage = ClosedEnum<typeof RequestBodyLanguage>;
67
-
68
- export type RequestBodyCodeTool = {
69
- /**
70
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
71
- */
72
- parameters?: CreateToolRequestBodyParameters | undefined;
73
- language: RequestBodyLanguage;
74
- /**
75
- * The code to execute.
76
- */
77
- code: string;
78
- };
79
-
80
- /**
81
- * Executes code snippets in a sandboxed environment, currently supporting Python.
82
- */
83
- export type RequestBodyCodeExecutionTool = {
84
- /**
85
- * Entity storage path in the format: `project/folder/subfolder/...`
86
- *
87
- * @remarks
88
- *
89
- * The first element identifies the project, followed by nested folders (auto-created as needed).
90
- *
91
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
92
- */
93
- path: string;
94
- /**
95
- * Unique key of the tool as it will be displayed in the UI
96
- */
97
- key: string;
98
- /**
99
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
100
- */
101
- displayName?: string | undefined;
102
- /**
103
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
104
- */
105
- description: string;
106
- /**
107
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
108
- */
109
- status?: CreateToolRequestBodyToolsRequestStatus | undefined;
110
- type: "code";
111
- codeTool: RequestBodyCodeTool;
112
- };
113
-
114
- /**
115
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
116
- */
117
- export const CreateToolRequestBodyToolsStatus = {
118
- Live: "live",
119
- Draft: "draft",
120
- Pending: "pending",
121
- Published: "published",
122
- } as const;
123
- /**
124
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
125
- */
126
- export type CreateToolRequestBodyToolsStatus = ClosedEnum<
127
- typeof CreateToolRequestBodyToolsStatus
128
- >;
129
-
130
- export type RequestBodyHeaders = {
131
- value: string;
132
- encrypted?: boolean | undefined;
133
- };
134
-
135
- /**
136
- * The connection type used by the MCP server
137
- */
138
- export const RequestBodyConnectionType = {
139
- Http: "http",
140
- Sse: "sse",
141
- } as const;
142
- /**
143
- * The connection type used by the MCP server
144
- */
145
- export type RequestBodyConnectionType = ClosedEnum<
146
- typeof RequestBodyConnectionType
147
- >;
148
-
149
- export type RequestBodyMcp = {
150
- /**
151
- * The MCP server URL (cached for execution)
152
- */
153
- serverUrl: string;
154
- /**
155
- * HTTP headers for MCP server requests with encryption support
156
- */
157
- headers?: { [k: string]: RequestBodyHeaders } | undefined;
158
- /**
159
- * The connection type used by the MCP server
160
- */
161
- connectionType: RequestBodyConnectionType;
162
- };
163
-
164
- /**
165
- * A tool from a Model Context Protocol (MCP) server that provides standardized access to external capabilities.
166
- */
167
- export type RequestBodyMCPTool = {
168
- /**
169
- * Entity storage path in the format: `project/folder/subfolder/...`
170
- *
171
- * @remarks
172
- *
173
- * The first element identifies the project, followed by nested folders (auto-created as needed).
174
- *
175
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
176
- */
177
- path: string;
178
- /**
179
- * Unique key of the tool as it will be displayed in the UI
180
- */
181
- key: string;
182
- /**
183
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
184
- */
185
- displayName?: string | undefined;
186
- /**
187
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
188
- */
189
- description: string;
190
- /**
191
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
192
- */
193
- status?: CreateToolRequestBodyToolsStatus | undefined;
194
- type: "mcp";
195
- mcp: RequestBodyMcp;
196
- };
197
-
198
- /**
199
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
200
- */
201
- export const CreateToolRequestBodyStatus = {
202
- Live: "live",
203
- Draft: "draft",
204
- Pending: "pending",
205
- Published: "published",
206
- } as const;
207
- /**
208
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
209
- */
210
- export type CreateToolRequestBodyStatus = ClosedEnum<
211
- typeof CreateToolRequestBodyStatus
212
- >;
213
-
214
- /**
215
- * The HTTP method to use.
216
- */
217
- export const CreateToolRequestBodyMethod = {
218
- Get: "GET",
219
- Post: "POST",
220
- Put: "PUT",
221
- Delete: "DELETE",
222
- } as const;
223
- /**
224
- * The HTTP method to use.
225
- */
226
- export type CreateToolRequestBodyMethod = ClosedEnum<
227
- typeof CreateToolRequestBodyMethod
228
- >;
229
-
230
- export type CreateToolHeaders2 = {
231
- value: string;
232
- encrypted?: boolean | undefined;
233
- };
234
-
235
- export type CreateToolRequestBodyHeaders = CreateToolHeaders2 | string;
236
-
237
- /**
238
- * The blueprint for the HTTP request. The `arguments` field will be used to replace the placeholders in the `url`, `headers`, `body`, and `arguments` fields.
239
- */
240
- export type RequestBodyBlueprint = {
241
- /**
242
- * The URL to send the request to.
243
- */
244
- url: string;
245
- /**
246
- * The HTTP method to use.
247
- */
248
- method: CreateToolRequestBodyMethod;
249
- /**
250
- * The headers to send with the request. Can be a string value or an object with value and encrypted properties.
251
- */
252
- headers?: { [k: string]: CreateToolHeaders2 | string } | undefined;
253
- /**
254
- * The body to send with the request.
255
- */
256
- body?: { [k: string]: any } | undefined;
257
- };
258
-
259
- /**
260
- * The type of the argument.
261
- */
262
- export const CreateToolRequestBodyToolsRequest3Type = {
263
- String: "string",
264
- Number: "number",
265
- Boolean: "boolean",
266
- } as const;
267
- /**
268
- * The type of the argument.
269
- */
270
- export type CreateToolRequestBodyToolsRequest3Type = ClosedEnum<
271
- typeof CreateToolRequestBodyToolsRequest3Type
272
- >;
273
-
274
- /**
275
- * The default value of the argument.
276
- */
277
- export type RequestBodyDefaultValue = string | number | boolean;
278
-
279
- export type RequestBodyArguments = {
280
- /**
281
- * The type of the argument.
282
- */
283
- type: CreateToolRequestBodyToolsRequest3Type;
284
- /**
285
- * A description of the argument.
286
- */
287
- description: string;
288
- /**
289
- * Whether to send the argument to the model. If set to false, the argument will not be sent to the model and needs to be provided by the user or it will be left blank.
290
- */
291
- sendToModel?: boolean | undefined;
292
- /**
293
- * The default value of the argument.
294
- */
295
- defaultValue?: string | number | boolean | undefined;
296
- };
297
-
298
- export type CreateToolRequestBodyHttp = {
299
- /**
300
- * The blueprint for the HTTP request. The `arguments` field will be used to replace the placeholders in the `url`, `headers`, `body`, and `arguments` fields.
301
- */
302
- blueprint: RequestBodyBlueprint;
303
- /**
304
- * The arguments to send with the request. The keys will be used to replace the placeholders in the `blueprint` field.
305
- */
306
- arguments?: { [k: string]: RequestBodyArguments } | undefined;
307
- };
308
-
309
- /**
310
- * Executes HTTP requests to interact with external APIs and web services using customizable blueprints.
311
- */
312
- export type RequestBodyHTTPTool = {
313
- /**
314
- * Entity storage path in the format: `project/folder/subfolder/...`
315
- *
316
- * @remarks
317
- *
318
- * The first element identifies the project, followed by nested folders (auto-created as needed).
319
- *
320
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
321
- */
322
- path: string;
323
- /**
324
- * Unique key of the tool as it will be displayed in the UI
325
- */
326
- key: string;
327
- /**
328
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
329
- */
330
- displayName?: string | undefined;
331
- /**
332
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
333
- */
334
- description: string;
335
- /**
336
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
337
- */
338
- status?: CreateToolRequestBodyStatus | undefined;
339
- type: "http";
340
- http: CreateToolRequestBodyHttp;
341
- };
342
-
343
- /**
344
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
345
- */
346
- export const RequestBodyStatus = {
347
- Live: "live",
348
- Draft: "draft",
349
- Pending: "pending",
350
- Published: "published",
351
- } as const;
352
- /**
353
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
354
- */
355
- export type RequestBodyStatus = ClosedEnum<typeof RequestBodyStatus>;
356
-
357
- /**
358
- * The schema for the response format, described as a JSON Schema object. See the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
359
- */
360
- export type RequestBodySchema = {
361
- /**
362
- * The JSON Schema type
363
- */
364
- type: string;
365
- /**
366
- * The properties of the JSON Schema object
367
- */
368
- properties: { [k: string]: any };
369
- /**
370
- * Array of required property names
371
- */
372
- required: Array<string>;
373
- additionalProperties?: { [k: string]: any } | undefined;
374
- };
375
-
376
- export type RequestBodyJsonSchema = {
377
- /**
378
- * The name of the response format. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
379
- */
380
- name: string;
381
- /**
382
- * A description of what the response format is for. This will be shown to the user.
383
- */
384
- description: string;
385
- /**
386
- * The schema for the response format, described as a JSON Schema object. See the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
387
- */
388
- schema: RequestBodySchema;
389
- /**
390
- * Whether to enable strict schema adherence when generating the output. If set to true, the model will always follow the exact schema defined in the `schema` field. Only a subset of JSON Schema is supported when `strict` is `true`. Only compatible with `OpenAI` models.
391
- */
392
- strict?: boolean | undefined;
393
- };
394
-
395
- /**
396
- * A tool that enforces structured output format using JSON Schema for consistent response formatting.
397
- */
398
- export type RequestBodyJSONSchemaTool = {
399
- /**
400
- * Entity storage path in the format: `project/folder/subfolder/...`
401
- *
402
- * @remarks
403
- *
404
- * The first element identifies the project, followed by nested folders (auto-created as needed).
405
- *
406
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
407
- */
408
- path: string;
409
- /**
410
- * Unique key of the tool as it will be displayed in the UI
411
- */
412
- key: string;
413
- /**
414
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
415
- */
416
- displayName?: string | undefined;
417
- /**
418
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
419
- */
420
- description: string;
421
- /**
422
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
423
- */
424
- status?: RequestBodyStatus | undefined;
425
- type: "json_schema";
426
- jsonSchema: RequestBodyJsonSchema;
427
- };
428
-
429
- /**
430
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
431
- */
432
- export const CreateToolRequestBodyToolsRequest1Status = {
433
- Live: "live",
434
- Draft: "draft",
435
- Pending: "pending",
436
- Published: "published",
437
- } as const;
438
- /**
439
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
440
- */
441
- export type CreateToolRequestBodyToolsRequest1Status = ClosedEnum<
442
- typeof CreateToolRequestBodyToolsRequest1Status
443
- >;
444
-
445
- /**
446
- * The type must be "object"
447
- */
448
- export const CreateToolRequestBodyToolsRequest1Type = {
449
- Object: "object",
450
- } as const;
451
- /**
452
- * The type must be "object"
453
- */
454
- export type CreateToolRequestBodyToolsRequest1Type = ClosedEnum<
455
- typeof CreateToolRequestBodyToolsRequest1Type
456
- >;
457
-
458
- /**
459
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
460
- */
461
- export type RequestBodyParameters = {
462
- /**
463
- * The type must be "object"
464
- */
465
- type: CreateToolRequestBodyToolsRequest1Type;
466
- /**
467
- * The properties of the function parameters
468
- */
469
- properties: { [k: string]: any };
470
- /**
471
- * Array of required parameter names
472
- */
473
- required: Array<string>;
474
- additionalProperties?: { [k: string]: any } | undefined;
475
- };
476
-
477
- export type RequestBodyFunction = {
478
- /**
479
- * The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
480
- */
481
- name: string;
482
- /**
483
- * A description of what the function does, used by the model to choose when and how to call the function.
484
- */
485
- description?: string | undefined;
486
- /**
487
- * Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Currently only compatible with `OpenAI` models.
488
- */
489
- strict?: boolean | undefined;
490
- /**
491
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
492
- */
493
- parameters?: RequestBodyParameters | undefined;
494
- };
495
-
496
- /**
497
- * A custom function tool that allows the model to call predefined functions with structured parameters.
498
- */
499
- export type RequestBodyFunctionTool = {
500
- /**
501
- * Entity storage path in the format: `project/folder/subfolder/...`
502
- *
503
- * @remarks
504
- *
505
- * The first element identifies the project, followed by nested folders (auto-created as needed).
506
- *
507
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
508
- */
509
- path: string;
510
- /**
511
- * Unique key of the tool as it will be displayed in the UI
512
- */
513
- key: string;
514
- /**
515
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
516
- */
517
- displayName?: string | undefined;
518
- /**
519
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
520
- */
521
- description: string;
522
- /**
523
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
524
- */
525
- status?: CreateToolRequestBodyToolsRequest1Status | undefined;
526
- type: "function";
527
- function: RequestBodyFunction;
528
- };
529
-
530
- /**
531
- * The tool to create
532
- */
533
- export type CreateToolRequestBody =
534
- | RequestBodyFunctionTool
535
- | RequestBodyJSONSchemaTool
536
- | RequestBodyHTTPTool
537
- | RequestBodyMCPTool
538
- | RequestBodyCodeExecutionTool;
539
-
540
- /**
541
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
542
- */
543
- export const CreateToolResponseBodyToolsResponse200Status = {
544
- Live: "live",
545
- Draft: "draft",
546
- Pending: "pending",
547
- Published: "published",
548
- } as const;
549
- /**
550
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
551
- */
552
- export type CreateToolResponseBodyToolsResponse200Status = ClosedEnum<
553
- typeof CreateToolResponseBodyToolsResponse200Status
554
- >;
555
-
556
- /**
557
- * The type must be "object"
558
- */
559
- export const CreateToolResponseBodyToolsResponse200ApplicationJson5Type = {
560
- Object: "object",
561
- } as const;
562
- /**
563
- * The type must be "object"
564
- */
565
- export type CreateToolResponseBodyToolsResponse200ApplicationJson5Type =
566
- ClosedEnum<typeof CreateToolResponseBodyToolsResponse200ApplicationJson5Type>;
567
-
568
- /**
569
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
570
- */
571
- export type CreateToolResponseBodyParameters = {
572
- /**
573
- * The type must be "object"
574
- */
575
- type: CreateToolResponseBodyToolsResponse200ApplicationJson5Type;
576
- /**
577
- * The properties of the function parameters
578
- */
579
- properties: { [k: string]: any };
580
- /**
581
- * Array of required parameter names
582
- */
583
- required: Array<string>;
584
- additionalProperties?: { [k: string]: any } | undefined;
585
- };
586
-
587
- export const ResponseBodyLanguage = {
588
- Python: "python",
589
- } as const;
590
- export type ResponseBodyLanguage = ClosedEnum<typeof ResponseBodyLanguage>;
591
-
592
- export type ResponseBodyCodeTool = {
593
- /**
594
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
595
- */
596
- parameters?: CreateToolResponseBodyParameters | undefined;
597
- language: ResponseBodyLanguage;
598
- /**
599
- * The code to execute.
600
- */
601
- code: string;
602
- };
603
-
604
- /**
605
- * Executes code snippets in a sandboxed environment, currently supporting Python.
606
- */
607
- export type ResponseBodyCodeExecutionTool = {
608
- id: string;
609
- /**
610
- * Entity storage path in the format: `project/folder/subfolder/...`
611
- *
612
- * @remarks
613
- *
614
- * The first element identifies the project, followed by nested folders (auto-created as needed).
615
- *
616
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
617
- */
618
- path: string;
619
- /**
620
- * Unique key of the tool as it will be displayed in the UI
621
- */
622
- key: string;
623
- /**
624
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
625
- */
626
- displayName?: string | undefined;
627
- /**
628
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
629
- */
630
- description: string;
631
- /**
632
- * The id of the user that created the tool
633
- */
634
- createdById?: string | undefined;
635
- /**
636
- * The id of the user that last updated the tool
637
- */
638
- updatedById?: string | undefined;
639
- projectId: string;
640
- workspaceId: string;
641
- created: string;
642
- updated: string;
643
- /**
644
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
645
- */
646
- status: CreateToolResponseBodyToolsResponse200Status;
647
- versionHash?: string | undefined;
648
- type: "code";
649
- codeTool: ResponseBodyCodeTool;
650
- };
651
-
652
- /**
653
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
654
- */
655
- export const CreateToolResponseBodyToolsResponseStatus = {
656
- Live: "live",
657
- Draft: "draft",
658
- Pending: "pending",
659
- Published: "published",
660
- } as const;
661
- /**
662
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
663
- */
664
- export type CreateToolResponseBodyToolsResponseStatus = ClosedEnum<
665
- typeof CreateToolResponseBodyToolsResponseStatus
666
- >;
667
-
668
- export type ResponseBodyHeaders = {
669
- value: string;
670
- encrypted: boolean;
671
- };
672
-
673
- export const CreateToolResponseBodyToolsResponse200ApplicationJson4Type = {
674
- Object: "object",
675
- } as const;
676
- export type CreateToolResponseBodyToolsResponse200ApplicationJson4Type =
677
- ClosedEnum<typeof CreateToolResponseBodyToolsResponse200ApplicationJson4Type>;
678
-
679
- export type CreateToolResponseBodySchema = {
680
- type: CreateToolResponseBodyToolsResponse200ApplicationJson4Type;
681
- properties?: { [k: string]: any } | undefined;
682
- required?: Array<string> | undefined;
683
- };
684
-
685
- export type ResponseBodyTools = {
686
- id: string;
687
- name: string;
688
- description?: string | undefined;
689
- schema: CreateToolResponseBodySchema;
690
- };
691
-
692
- /**
693
- * The connection type used by the MCP server
694
- */
695
- export const ResponseBodyConnectionType = {
696
- Http: "http",
697
- Sse: "sse",
698
- } as const;
699
- /**
700
- * The connection type used by the MCP server
701
- */
702
- export type ResponseBodyConnectionType = ClosedEnum<
703
- typeof ResponseBodyConnectionType
704
- >;
705
-
706
- export type ResponseBodyMcp = {
707
- /**
708
- * The MCP server URL (cached for execution)
709
- */
710
- serverUrl: string;
711
- /**
712
- * HTTP headers for MCP server requests with encryption support
713
- */
714
- headers?: { [k: string]: ResponseBodyHeaders } | undefined;
715
- /**
716
- * Array of tools available from the MCP server
717
- */
718
- tools: Array<ResponseBodyTools>;
719
- /**
720
- * The connection type used by the MCP server
721
- */
722
- connectionType: ResponseBodyConnectionType;
723
- };
724
-
725
- /**
726
- * A tool from a Model Context Protocol (MCP) server that provides standardized access to external capabilities.
727
- */
728
- export type ResponseBodyMCPTool = {
729
- id: string;
730
- /**
731
- * Entity storage path in the format: `project/folder/subfolder/...`
732
- *
733
- * @remarks
734
- *
735
- * The first element identifies the project, followed by nested folders (auto-created as needed).
736
- *
737
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
738
- */
739
- path: string;
740
- /**
741
- * Unique key of the tool as it will be displayed in the UI
742
- */
743
- key: string;
744
- /**
745
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
746
- */
747
- displayName?: string | undefined;
748
- /**
749
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
750
- */
751
- description: string;
752
- /**
753
- * The id of the user that created the tool
754
- */
755
- createdById?: string | undefined;
756
- /**
757
- * The id of the user that last updated the tool
758
- */
759
- updatedById?: string | undefined;
760
- projectId: string;
761
- workspaceId: string;
762
- created: string;
763
- updated: string;
764
- /**
765
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
766
- */
767
- status: CreateToolResponseBodyToolsResponseStatus;
768
- versionHash?: string | undefined;
769
- type: "mcp";
770
- mcp: ResponseBodyMcp;
771
- };
772
-
773
- /**
774
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
775
- */
776
- export const CreateToolResponseBodyToolsStatus = {
777
- Live: "live",
778
- Draft: "draft",
779
- Pending: "pending",
780
- Published: "published",
781
- } as const;
782
- /**
783
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
784
- */
785
- export type CreateToolResponseBodyToolsStatus = ClosedEnum<
786
- typeof CreateToolResponseBodyToolsStatus
787
- >;
788
-
789
- /**
790
- * The HTTP method to use.
791
- */
792
- export const CreateToolResponseBodyMethod = {
793
- Get: "GET",
794
- Post: "POST",
795
- Put: "PUT",
796
- Delete: "DELETE",
797
- } as const;
798
- /**
799
- * The HTTP method to use.
800
- */
801
- export type CreateToolResponseBodyMethod = ClosedEnum<
802
- typeof CreateToolResponseBodyMethod
803
- >;
804
-
805
- export type CreateToolHeadersTools2 = {
806
- value: string;
807
- encrypted: boolean;
808
- };
809
-
810
- export type CreateToolResponseBodyHeaders = CreateToolHeadersTools2 | string;
811
-
812
- /**
813
- * The blueprint for the HTTP request. The `arguments` field will be used to replace the placeholders in the `url`, `headers`, `body`, and `arguments` fields.
814
- */
815
- export type ResponseBodyBlueprint = {
816
- /**
817
- * The URL to send the request to.
818
- */
819
- url: string;
820
- /**
821
- * The HTTP method to use.
822
- */
823
- method: CreateToolResponseBodyMethod;
824
- /**
825
- * The headers to send with the request. Can be a string value or an object with value and encrypted properties.
826
- */
827
- headers?: { [k: string]: CreateToolHeadersTools2 | string } | undefined;
828
- /**
829
- * The body to send with the request.
830
- */
831
- body?: { [k: string]: any } | undefined;
832
- };
833
-
834
- /**
835
- * The type of the argument.
836
- */
837
- export const CreateToolResponseBodyToolsResponse200ApplicationJson3Type = {
838
- String: "string",
839
- Number: "number",
840
- Boolean: "boolean",
841
- } as const;
842
- /**
843
- * The type of the argument.
844
- */
845
- export type CreateToolResponseBodyToolsResponse200ApplicationJson3Type =
846
- ClosedEnum<typeof CreateToolResponseBodyToolsResponse200ApplicationJson3Type>;
847
-
848
- /**
849
- * The default value of the argument.
850
- */
851
- export type ResponseBodyDefaultValue = string | number | boolean;
852
-
853
- export type ResponseBodyArguments = {
854
- /**
855
- * The type of the argument.
856
- */
857
- type: CreateToolResponseBodyToolsResponse200ApplicationJson3Type;
858
- /**
859
- * A description of the argument.
860
- */
861
- description: string;
862
- /**
863
- * Whether to send the argument to the model. If set to false, the argument will not be sent to the model and needs to be provided by the user or it will be left blank.
864
- */
865
- sendToModel: boolean;
866
- /**
867
- * The default value of the argument.
868
- */
869
- defaultValue?: string | number | boolean | undefined;
870
- };
871
-
872
- export type CreateToolResponseBodyHttp = {
873
- /**
874
- * The blueprint for the HTTP request. The `arguments` field will be used to replace the placeholders in the `url`, `headers`, `body`, and `arguments` fields.
875
- */
876
- blueprint: ResponseBodyBlueprint;
877
- /**
878
- * The arguments to send with the request. The keys will be used to replace the placeholders in the `blueprint` field.
879
- */
880
- arguments?: { [k: string]: ResponseBodyArguments } | undefined;
881
- };
882
-
883
- /**
884
- * Executes HTTP requests to interact with external APIs and web services using customizable blueprints.
885
- */
886
- export type ResponseBodyHTTPTool = {
887
- id: string;
888
- /**
889
- * Entity storage path in the format: `project/folder/subfolder/...`
890
- *
891
- * @remarks
892
- *
893
- * The first element identifies the project, followed by nested folders (auto-created as needed).
894
- *
895
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
896
- */
897
- path: string;
898
- /**
899
- * Unique key of the tool as it will be displayed in the UI
900
- */
901
- key: string;
902
- /**
903
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
904
- */
905
- displayName?: string | undefined;
906
- /**
907
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
908
- */
909
- description: string;
910
- /**
911
- * The id of the user that created the tool
912
- */
913
- createdById?: string | undefined;
914
- /**
915
- * The id of the user that last updated the tool
916
- */
917
- updatedById?: string | undefined;
918
- projectId: string;
919
- workspaceId: string;
920
- created: string;
921
- updated: string;
922
- /**
923
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
924
- */
925
- status: CreateToolResponseBodyToolsStatus;
926
- versionHash?: string | undefined;
927
- type: "http";
928
- http: CreateToolResponseBodyHttp;
929
- };
930
-
931
- /**
932
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
933
- */
934
- export const CreateToolResponseBodyStatus = {
935
- Live: "live",
936
- Draft: "draft",
937
- Pending: "pending",
938
- Published: "published",
939
- } as const;
940
- /**
941
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
942
- */
943
- export type CreateToolResponseBodyStatus = ClosedEnum<
944
- typeof CreateToolResponseBodyStatus
945
- >;
946
-
947
- /**
948
- * The schema for the response format, described as a JSON Schema object. See the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
949
- */
950
- export type ResponseBodySchema = {
951
- /**
952
- * The JSON Schema type
953
- */
954
- type: string;
955
- /**
956
- * The properties of the JSON Schema object
957
- */
958
- properties: { [k: string]: any };
959
- /**
960
- * Array of required property names
961
- */
962
- required: Array<string>;
963
- additionalProperties?: { [k: string]: any } | undefined;
964
- };
965
-
966
- export type ResponseBodyJsonSchema = {
967
- /**
968
- * The name of the response format. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
969
- */
970
- name: string;
971
- /**
972
- * A description of what the response format is for. This will be shown to the user.
973
- */
974
- description: string;
975
- /**
976
- * The schema for the response format, described as a JSON Schema object. See the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
977
- */
978
- schema: ResponseBodySchema;
979
- /**
980
- * Whether to enable strict schema adherence when generating the output. If set to true, the model will always follow the exact schema defined in the `schema` field. Only a subset of JSON Schema is supported when `strict` is `true`. Only compatible with `OpenAI` models.
981
- */
982
- strict?: boolean | undefined;
983
- };
984
-
985
- /**
986
- * A tool that enforces structured output format using JSON Schema for consistent response formatting.
987
- */
988
- export type ResponseBodyJSONSchemaTool = {
989
- id: string;
990
- /**
991
- * Entity storage path in the format: `project/folder/subfolder/...`
992
- *
993
- * @remarks
994
- *
995
- * The first element identifies the project, followed by nested folders (auto-created as needed).
996
- *
997
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
998
- */
999
- path: string;
1000
- /**
1001
- * Unique key of the tool as it will be displayed in the UI
1002
- */
1003
- key: string;
1004
- /**
1005
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
1006
- */
1007
- displayName?: string | undefined;
1008
- /**
1009
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
1010
- */
1011
- description: string;
1012
- /**
1013
- * The id of the user that created the tool
1014
- */
1015
- createdById?: string | undefined;
1016
- /**
1017
- * The id of the user that last updated the tool
1018
- */
1019
- updatedById?: string | undefined;
1020
- projectId: string;
1021
- workspaceId: string;
1022
- created: string;
1023
- updated: string;
1024
- /**
1025
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1026
- */
1027
- status: CreateToolResponseBodyStatus;
1028
- versionHash?: string | undefined;
1029
- type: "json_schema";
1030
- jsonSchema: ResponseBodyJsonSchema;
1031
- };
1032
-
1033
- /**
1034
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1035
- */
1036
- export const ResponseBodyStatus = {
1037
- Live: "live",
1038
- Draft: "draft",
1039
- Pending: "pending",
1040
- Published: "published",
1041
- } as const;
1042
- /**
1043
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1044
- */
1045
- export type ResponseBodyStatus = ClosedEnum<typeof ResponseBodyStatus>;
1046
-
1047
- /**
1048
- * The type must be "object"
1049
- */
1050
- export const CreateToolResponseBodyToolsResponse200ApplicationJson1Type = {
1051
- Object: "object",
1052
- } as const;
1053
- /**
1054
- * The type must be "object"
1055
- */
1056
- export type CreateToolResponseBodyToolsResponse200ApplicationJson1Type =
1057
- ClosedEnum<typeof CreateToolResponseBodyToolsResponse200ApplicationJson1Type>;
1058
-
1059
- /**
1060
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
1061
- */
1062
- export type ResponseBodyParameters = {
1063
- /**
1064
- * The type must be "object"
1065
- */
1066
- type: CreateToolResponseBodyToolsResponse200ApplicationJson1Type;
1067
- /**
1068
- * The properties of the function parameters
1069
- */
1070
- properties: { [k: string]: any };
1071
- /**
1072
- * Array of required parameter names
1073
- */
1074
- required: Array<string>;
1075
- additionalProperties?: { [k: string]: any } | undefined;
1076
- };
1077
-
1078
- export type CreateToolResponseBodyFunction = {
1079
- /**
1080
- * The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
1081
- */
1082
- name: string;
1083
- /**
1084
- * A description of what the function does, used by the model to choose when and how to call the function.
1085
- */
1086
- description?: string | undefined;
1087
- /**
1088
- * Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Currently only compatible with `OpenAI` models.
1089
- */
1090
- strict?: boolean | undefined;
1091
- /**
1092
- * The parameters the functions accepts, described as a JSON Schema object. See the `OpenAI` [guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.
1093
- */
1094
- parameters?: ResponseBodyParameters | undefined;
1095
- };
1096
-
1097
- /**
1098
- * A custom function tool that allows the model to call predefined functions with structured parameters.
1099
- */
1100
- export type ResponseBodyFunctionTool = {
1101
- id: string;
1102
- /**
1103
- * Entity storage path in the format: `project/folder/subfolder/...`
1104
- *
1105
- * @remarks
1106
- *
1107
- * The first element identifies the project, followed by nested folders (auto-created as needed).
1108
- *
1109
- * With project-based API keys, the first element is treated as a folder name, as the project is predetermined by the API key.
1110
- */
1111
- path: string;
1112
- /**
1113
- * Unique key of the tool as it will be displayed in the UI
1114
- */
1115
- key: string;
1116
- /**
1117
- * The name of the tool as it will be displayed in the UI. This is optional and if not provided, the `key` will be used.
1118
- */
1119
- displayName?: string | undefined;
1120
- /**
1121
- * A description of the tool, used by the model to choose when and how to call the tool. We do recommend using the `description` field as accurate as possible to give enough context to the model to make the right decision.
1122
- */
1123
- description: string;
1124
- /**
1125
- * The id of the user that created the tool
1126
- */
1127
- createdById?: string | undefined;
1128
- /**
1129
- * The id of the user that last updated the tool
1130
- */
1131
- updatedById?: string | undefined;
1132
- projectId: string;
1133
- workspaceId: string;
1134
- created: string;
1135
- updated: string;
1136
- /**
1137
- * The status of the tool. `Live` is the latest version of the tool. `Draft` is a version that is not yet published. `Pending` is a version that is pending approval. `Published` is a version that was live and has been replaced by a new version.
1138
- */
1139
- status: ResponseBodyStatus;
1140
- versionHash?: string | undefined;
1141
- type: "function";
1142
- function: CreateToolResponseBodyFunction;
1143
- };
1144
-
1145
- /**
1146
- * Successfully created the tool.
1147
- */
1148
- export type CreateToolResponseBody =
1149
- | ResponseBodyFunctionTool
1150
- | ResponseBodyJSONSchemaTool
1151
- | ResponseBodyHTTPTool
1152
- | ResponseBodyMCPTool
1153
- | ResponseBodyCodeExecutionTool;
1154
-
1155
- /** @internal */
1156
- export const CreateToolRequestBodyToolsRequestStatus$outboundSchema:
1157
- z.ZodNativeEnum<typeof CreateToolRequestBodyToolsRequestStatus> = z
1158
- .nativeEnum(CreateToolRequestBodyToolsRequestStatus);
1159
-
1160
- /** @internal */
1161
- export const CreateToolRequestBodyToolsRequest5CodeToolType$outboundSchema:
1162
- z.ZodNativeEnum<typeof CreateToolRequestBodyToolsRequest5CodeToolType> = z
1163
- .nativeEnum(CreateToolRequestBodyToolsRequest5CodeToolType);
1164
-
1165
- /** @internal */
1166
- export type CreateToolRequestBodyParameters$Outbound = {
1167
- type: string;
1168
- properties: { [k: string]: any };
1169
- required: Array<string>;
1170
- [additionalProperties: string]: unknown;
1171
- };
1172
-
1173
- /** @internal */
1174
- export const CreateToolRequestBodyParameters$outboundSchema: z.ZodType<
1175
- CreateToolRequestBodyParameters$Outbound,
1176
- z.ZodTypeDef,
1177
- CreateToolRequestBodyParameters
1178
- > = z.object({
1179
- type: CreateToolRequestBodyToolsRequest5CodeToolType$outboundSchema,
1180
- properties: z.record(z.any()),
1181
- required: z.array(z.string()),
1182
- additionalProperties: z.record(z.any()).optional(),
1183
- }).transform((v) => {
1184
- return {
1185
- ...v.additionalProperties,
1186
- ...remap$(v, {
1187
- additionalProperties: null,
1188
- }),
1189
- };
1190
- });
1191
-
1192
- export function createToolRequestBodyParametersToJSON(
1193
- createToolRequestBodyParameters: CreateToolRequestBodyParameters,
1194
- ): string {
1195
- return JSON.stringify(
1196
- CreateToolRequestBodyParameters$outboundSchema.parse(
1197
- createToolRequestBodyParameters,
1198
- ),
1199
- );
1200
- }
1201
-
1202
- /** @internal */
1203
- export const RequestBodyLanguage$outboundSchema: z.ZodNativeEnum<
1204
- typeof RequestBodyLanguage
1205
- > = z.nativeEnum(RequestBodyLanguage);
1206
-
1207
- /** @internal */
1208
- export type RequestBodyCodeTool$Outbound = {
1209
- parameters?: CreateToolRequestBodyParameters$Outbound | undefined;
1210
- language: string;
1211
- code: string;
1212
- };
1213
-
1214
- /** @internal */
1215
- export const RequestBodyCodeTool$outboundSchema: z.ZodType<
1216
- RequestBodyCodeTool$Outbound,
1217
- z.ZodTypeDef,
1218
- RequestBodyCodeTool
1219
- > = z.object({
1220
- parameters: z.lazy(() => CreateToolRequestBodyParameters$outboundSchema)
1221
- .optional(),
1222
- language: RequestBodyLanguage$outboundSchema,
1223
- code: z.string(),
1224
- });
1225
-
1226
- export function requestBodyCodeToolToJSON(
1227
- requestBodyCodeTool: RequestBodyCodeTool,
1228
- ): string {
1229
- return JSON.stringify(
1230
- RequestBodyCodeTool$outboundSchema.parse(requestBodyCodeTool),
1231
- );
1232
- }
1233
-
1234
- /** @internal */
1235
- export type RequestBodyCodeExecutionTool$Outbound = {
1236
- path: string;
1237
- key: string;
1238
- display_name?: string | undefined;
1239
- description: string;
1240
- status: string;
1241
- type: "code";
1242
- code_tool: RequestBodyCodeTool$Outbound;
1243
- };
1244
-
1245
- /** @internal */
1246
- export const RequestBodyCodeExecutionTool$outboundSchema: z.ZodType<
1247
- RequestBodyCodeExecutionTool$Outbound,
1248
- z.ZodTypeDef,
1249
- RequestBodyCodeExecutionTool
1250
- > = z.object({
1251
- path: z.string(),
1252
- key: z.string(),
1253
- displayName: z.string().optional(),
1254
- description: z.string(),
1255
- status: CreateToolRequestBodyToolsRequestStatus$outboundSchema.default(
1256
- "live",
1257
- ),
1258
- type: z.literal("code"),
1259
- codeTool: z.lazy(() => RequestBodyCodeTool$outboundSchema),
1260
- }).transform((v) => {
1261
- return remap$(v, {
1262
- displayName: "display_name",
1263
- codeTool: "code_tool",
1264
- });
1265
- });
1266
-
1267
- export function requestBodyCodeExecutionToolToJSON(
1268
- requestBodyCodeExecutionTool: RequestBodyCodeExecutionTool,
1269
- ): string {
1270
- return JSON.stringify(
1271
- RequestBodyCodeExecutionTool$outboundSchema.parse(
1272
- requestBodyCodeExecutionTool,
1273
- ),
1274
- );
1275
- }
1276
-
1277
- /** @internal */
1278
- export const CreateToolRequestBodyToolsStatus$outboundSchema: z.ZodNativeEnum<
1279
- typeof CreateToolRequestBodyToolsStatus
1280
- > = z.nativeEnum(CreateToolRequestBodyToolsStatus);
1281
-
1282
- /** @internal */
1283
- export type RequestBodyHeaders$Outbound = {
1284
- value: string;
1285
- encrypted: boolean;
1286
- };
1287
-
1288
- /** @internal */
1289
- export const RequestBodyHeaders$outboundSchema: z.ZodType<
1290
- RequestBodyHeaders$Outbound,
1291
- z.ZodTypeDef,
1292
- RequestBodyHeaders
1293
- > = z.object({
1294
- value: z.string(),
1295
- encrypted: z.boolean().default(false),
1296
- });
1297
-
1298
- export function requestBodyHeadersToJSON(
1299
- requestBodyHeaders: RequestBodyHeaders,
1300
- ): string {
1301
- return JSON.stringify(
1302
- RequestBodyHeaders$outboundSchema.parse(requestBodyHeaders),
1303
- );
1304
- }
1305
-
1306
- /** @internal */
1307
- export const RequestBodyConnectionType$outboundSchema: z.ZodNativeEnum<
1308
- typeof RequestBodyConnectionType
1309
- > = z.nativeEnum(RequestBodyConnectionType);
1310
-
1311
- /** @internal */
1312
- export type RequestBodyMcp$Outbound = {
1313
- server_url: string;
1314
- headers?: { [k: string]: RequestBodyHeaders$Outbound } | undefined;
1315
- connection_type: string;
1316
- };
1317
-
1318
- /** @internal */
1319
- export const RequestBodyMcp$outboundSchema: z.ZodType<
1320
- RequestBodyMcp$Outbound,
1321
- z.ZodTypeDef,
1322
- RequestBodyMcp
1323
- > = z.object({
1324
- serverUrl: z.string(),
1325
- headers: z.record(z.lazy(() => RequestBodyHeaders$outboundSchema)).optional(),
1326
- connectionType: RequestBodyConnectionType$outboundSchema,
1327
- }).transform((v) => {
1328
- return remap$(v, {
1329
- serverUrl: "server_url",
1330
- connectionType: "connection_type",
1331
- });
1332
- });
1333
-
1334
- export function requestBodyMcpToJSON(requestBodyMcp: RequestBodyMcp): string {
1335
- return JSON.stringify(RequestBodyMcp$outboundSchema.parse(requestBodyMcp));
1336
- }
1337
-
1338
- /** @internal */
1339
- export type RequestBodyMCPTool$Outbound = {
1340
- path: string;
1341
- key: string;
1342
- display_name?: string | undefined;
1343
- description: string;
1344
- status: string;
1345
- type: "mcp";
1346
- mcp: RequestBodyMcp$Outbound;
1347
- };
1348
-
1349
- /** @internal */
1350
- export const RequestBodyMCPTool$outboundSchema: z.ZodType<
1351
- RequestBodyMCPTool$Outbound,
1352
- z.ZodTypeDef,
1353
- RequestBodyMCPTool
1354
- > = z.object({
1355
- path: z.string(),
1356
- key: z.string(),
1357
- displayName: z.string().optional(),
1358
- description: z.string(),
1359
- status: CreateToolRequestBodyToolsStatus$outboundSchema.default("live"),
1360
- type: z.literal("mcp"),
1361
- mcp: z.lazy(() => RequestBodyMcp$outboundSchema),
1362
- }).transform((v) => {
1363
- return remap$(v, {
1364
- displayName: "display_name",
1365
- });
1366
- });
1367
-
1368
- export function requestBodyMCPToolToJSON(
1369
- requestBodyMCPTool: RequestBodyMCPTool,
1370
- ): string {
1371
- return JSON.stringify(
1372
- RequestBodyMCPTool$outboundSchema.parse(requestBodyMCPTool),
1373
- );
1374
- }
1375
-
1376
- /** @internal */
1377
- export const CreateToolRequestBodyStatus$outboundSchema: z.ZodNativeEnum<
1378
- typeof CreateToolRequestBodyStatus
1379
- > = z.nativeEnum(CreateToolRequestBodyStatus);
1380
-
1381
- /** @internal */
1382
- export const CreateToolRequestBodyMethod$outboundSchema: z.ZodNativeEnum<
1383
- typeof CreateToolRequestBodyMethod
1384
- > = z.nativeEnum(CreateToolRequestBodyMethod);
1385
-
1386
- /** @internal */
1387
- export type CreateToolHeaders2$Outbound = {
1388
- value: string;
1389
- encrypted: boolean;
1390
- };
1391
-
1392
- /** @internal */
1393
- export const CreateToolHeaders2$outboundSchema: z.ZodType<
1394
- CreateToolHeaders2$Outbound,
1395
- z.ZodTypeDef,
1396
- CreateToolHeaders2
1397
- > = z.object({
1398
- value: z.string(),
1399
- encrypted: z.boolean().default(false),
1400
- });
1401
-
1402
- export function createToolHeaders2ToJSON(
1403
- createToolHeaders2: CreateToolHeaders2,
1404
- ): string {
1405
- return JSON.stringify(
1406
- CreateToolHeaders2$outboundSchema.parse(createToolHeaders2),
1407
- );
1408
- }
1409
-
1410
- /** @internal */
1411
- export type CreateToolRequestBodyHeaders$Outbound =
1412
- | CreateToolHeaders2$Outbound
1413
- | string;
1414
-
1415
- /** @internal */
1416
- export const CreateToolRequestBodyHeaders$outboundSchema: z.ZodType<
1417
- CreateToolRequestBodyHeaders$Outbound,
1418
- z.ZodTypeDef,
1419
- CreateToolRequestBodyHeaders
1420
- > = z.union([z.lazy(() => CreateToolHeaders2$outboundSchema), z.string()]);
1421
-
1422
- export function createToolRequestBodyHeadersToJSON(
1423
- createToolRequestBodyHeaders: CreateToolRequestBodyHeaders,
1424
- ): string {
1425
- return JSON.stringify(
1426
- CreateToolRequestBodyHeaders$outboundSchema.parse(
1427
- createToolRequestBodyHeaders,
1428
- ),
1429
- );
1430
- }
1431
-
1432
- /** @internal */
1433
- export type RequestBodyBlueprint$Outbound = {
1434
- url: string;
1435
- method: string;
1436
- headers?: { [k: string]: CreateToolHeaders2$Outbound | string } | undefined;
1437
- body?: { [k: string]: any } | undefined;
1438
- };
1439
-
1440
- /** @internal */
1441
- export const RequestBodyBlueprint$outboundSchema: z.ZodType<
1442
- RequestBodyBlueprint$Outbound,
1443
- z.ZodTypeDef,
1444
- RequestBodyBlueprint
1445
- > = z.object({
1446
- url: z.string(),
1447
- method: CreateToolRequestBodyMethod$outboundSchema,
1448
- headers: z.record(
1449
- z.union([z.lazy(() => CreateToolHeaders2$outboundSchema), z.string()]),
1450
- ).optional(),
1451
- body: z.record(z.any()).optional(),
1452
- });
1453
-
1454
- export function requestBodyBlueprintToJSON(
1455
- requestBodyBlueprint: RequestBodyBlueprint,
1456
- ): string {
1457
- return JSON.stringify(
1458
- RequestBodyBlueprint$outboundSchema.parse(requestBodyBlueprint),
1459
- );
1460
- }
1461
-
1462
- /** @internal */
1463
- export const CreateToolRequestBodyToolsRequest3Type$outboundSchema:
1464
- z.ZodNativeEnum<typeof CreateToolRequestBodyToolsRequest3Type> = z.nativeEnum(
1465
- CreateToolRequestBodyToolsRequest3Type,
1466
- );
1467
-
1468
- /** @internal */
1469
- export type RequestBodyDefaultValue$Outbound = string | number | boolean;
1470
-
1471
- /** @internal */
1472
- export const RequestBodyDefaultValue$outboundSchema: z.ZodType<
1473
- RequestBodyDefaultValue$Outbound,
1474
- z.ZodTypeDef,
1475
- RequestBodyDefaultValue
1476
- > = z.union([z.string(), z.number(), z.boolean()]);
1477
-
1478
- export function requestBodyDefaultValueToJSON(
1479
- requestBodyDefaultValue: RequestBodyDefaultValue,
1480
- ): string {
1481
- return JSON.stringify(
1482
- RequestBodyDefaultValue$outboundSchema.parse(requestBodyDefaultValue),
1483
- );
1484
- }
1485
-
1486
- /** @internal */
1487
- export type RequestBodyArguments$Outbound = {
1488
- type: string;
1489
- description: string;
1490
- send_to_model: boolean;
1491
- default_value?: string | number | boolean | undefined;
1492
- };
1493
-
1494
- /** @internal */
1495
- export const RequestBodyArguments$outboundSchema: z.ZodType<
1496
- RequestBodyArguments$Outbound,
1497
- z.ZodTypeDef,
1498
- RequestBodyArguments
1499
- > = z.object({
1500
- type: CreateToolRequestBodyToolsRequest3Type$outboundSchema,
1501
- description: z.string(),
1502
- sendToModel: z.boolean().default(true),
1503
- defaultValue: z.union([z.string(), z.number(), z.boolean()]).optional(),
1504
- }).transform((v) => {
1505
- return remap$(v, {
1506
- sendToModel: "send_to_model",
1507
- defaultValue: "default_value",
1508
- });
1509
- });
1510
-
1511
- export function requestBodyArgumentsToJSON(
1512
- requestBodyArguments: RequestBodyArguments,
1513
- ): string {
1514
- return JSON.stringify(
1515
- RequestBodyArguments$outboundSchema.parse(requestBodyArguments),
1516
- );
1517
- }
1518
-
1519
- /** @internal */
1520
- export type CreateToolRequestBodyHttp$Outbound = {
1521
- blueprint: RequestBodyBlueprint$Outbound;
1522
- arguments?: { [k: string]: RequestBodyArguments$Outbound } | undefined;
1523
- };
1524
-
1525
- /** @internal */
1526
- export const CreateToolRequestBodyHttp$outboundSchema: z.ZodType<
1527
- CreateToolRequestBodyHttp$Outbound,
1528
- z.ZodTypeDef,
1529
- CreateToolRequestBodyHttp
1530
- > = z.object({
1531
- blueprint: z.lazy(() => RequestBodyBlueprint$outboundSchema),
1532
- arguments: z.record(z.lazy(() => RequestBodyArguments$outboundSchema))
1533
- .optional(),
1534
- });
1535
-
1536
- export function createToolRequestBodyHttpToJSON(
1537
- createToolRequestBodyHttp: CreateToolRequestBodyHttp,
1538
- ): string {
1539
- return JSON.stringify(
1540
- CreateToolRequestBodyHttp$outboundSchema.parse(createToolRequestBodyHttp),
1541
- );
1542
- }
1543
-
1544
- /** @internal */
1545
- export type RequestBodyHTTPTool$Outbound = {
1546
- path: string;
1547
- key: string;
1548
- display_name?: string | undefined;
1549
- description: string;
1550
- status: string;
1551
- type: "http";
1552
- http: CreateToolRequestBodyHttp$Outbound;
1553
- };
1554
-
1555
- /** @internal */
1556
- export const RequestBodyHTTPTool$outboundSchema: z.ZodType<
1557
- RequestBodyHTTPTool$Outbound,
1558
- z.ZodTypeDef,
1559
- RequestBodyHTTPTool
1560
- > = z.object({
1561
- path: z.string(),
1562
- key: z.string(),
1563
- displayName: z.string().optional(),
1564
- description: z.string(),
1565
- status: CreateToolRequestBodyStatus$outboundSchema.default("live"),
1566
- type: z.literal("http"),
1567
- http: z.lazy(() => CreateToolRequestBodyHttp$outboundSchema),
1568
- }).transform((v) => {
1569
- return remap$(v, {
1570
- displayName: "display_name",
1571
- });
1572
- });
1573
-
1574
- export function requestBodyHTTPToolToJSON(
1575
- requestBodyHTTPTool: RequestBodyHTTPTool,
1576
- ): string {
1577
- return JSON.stringify(
1578
- RequestBodyHTTPTool$outboundSchema.parse(requestBodyHTTPTool),
1579
- );
1580
- }
1581
-
1582
- /** @internal */
1583
- export const RequestBodyStatus$outboundSchema: z.ZodNativeEnum<
1584
- typeof RequestBodyStatus
1585
- > = z.nativeEnum(RequestBodyStatus);
1586
-
1587
- /** @internal */
1588
- export type RequestBodySchema$Outbound = {
1589
- type: string;
1590
- properties: { [k: string]: any };
1591
- required: Array<string>;
1592
- [additionalProperties: string]: unknown;
1593
- };
1594
-
1595
- /** @internal */
1596
- export const RequestBodySchema$outboundSchema: z.ZodType<
1597
- RequestBodySchema$Outbound,
1598
- z.ZodTypeDef,
1599
- RequestBodySchema
1600
- > = z.object({
1601
- type: z.string(),
1602
- properties: z.record(z.any()),
1603
- required: z.array(z.string()),
1604
- additionalProperties: z.record(z.any()).optional(),
1605
- }).transform((v) => {
1606
- return {
1607
- ...v.additionalProperties,
1608
- ...remap$(v, {
1609
- additionalProperties: null,
1610
- }),
1611
- };
1612
- });
1613
-
1614
- export function requestBodySchemaToJSON(
1615
- requestBodySchema: RequestBodySchema,
1616
- ): string {
1617
- return JSON.stringify(
1618
- RequestBodySchema$outboundSchema.parse(requestBodySchema),
1619
- );
1620
- }
1621
-
1622
- /** @internal */
1623
- export type RequestBodyJsonSchema$Outbound = {
1624
- name: string;
1625
- description: string;
1626
- schema: RequestBodySchema$Outbound;
1627
- strict?: boolean | undefined;
1628
- };
1629
-
1630
- /** @internal */
1631
- export const RequestBodyJsonSchema$outboundSchema: z.ZodType<
1632
- RequestBodyJsonSchema$Outbound,
1633
- z.ZodTypeDef,
1634
- RequestBodyJsonSchema
1635
- > = z.object({
1636
- name: z.string(),
1637
- description: z.string(),
1638
- schema: z.lazy(() => RequestBodySchema$outboundSchema),
1639
- strict: z.boolean().optional(),
1640
- });
1641
-
1642
- export function requestBodyJsonSchemaToJSON(
1643
- requestBodyJsonSchema: RequestBodyJsonSchema,
1644
- ): string {
1645
- return JSON.stringify(
1646
- RequestBodyJsonSchema$outboundSchema.parse(requestBodyJsonSchema),
1647
- );
1648
- }
1649
-
1650
- /** @internal */
1651
- export type RequestBodyJSONSchemaTool$Outbound = {
1652
- path: string;
1653
- key: string;
1654
- display_name?: string | undefined;
1655
- description: string;
1656
- status: string;
1657
- type: "json_schema";
1658
- json_schema: RequestBodyJsonSchema$Outbound;
1659
- };
1660
-
1661
- /** @internal */
1662
- export const RequestBodyJSONSchemaTool$outboundSchema: z.ZodType<
1663
- RequestBodyJSONSchemaTool$Outbound,
1664
- z.ZodTypeDef,
1665
- RequestBodyJSONSchemaTool
1666
- > = z.object({
1667
- path: z.string(),
1668
- key: z.string(),
1669
- displayName: z.string().optional(),
1670
- description: z.string(),
1671
- status: RequestBodyStatus$outboundSchema.default("live"),
1672
- type: z.literal("json_schema"),
1673
- jsonSchema: z.lazy(() => RequestBodyJsonSchema$outboundSchema),
1674
- }).transform((v) => {
1675
- return remap$(v, {
1676
- displayName: "display_name",
1677
- jsonSchema: "json_schema",
1678
- });
1679
- });
1680
-
1681
- export function requestBodyJSONSchemaToolToJSON(
1682
- requestBodyJSONSchemaTool: RequestBodyJSONSchemaTool,
1683
- ): string {
1684
- return JSON.stringify(
1685
- RequestBodyJSONSchemaTool$outboundSchema.parse(requestBodyJSONSchemaTool),
1686
- );
1687
- }
1688
-
1689
- /** @internal */
1690
- export const CreateToolRequestBodyToolsRequest1Status$outboundSchema:
1691
- z.ZodNativeEnum<typeof CreateToolRequestBodyToolsRequest1Status> = z
1692
- .nativeEnum(CreateToolRequestBodyToolsRequest1Status);
1693
-
1694
- /** @internal */
1695
- export const CreateToolRequestBodyToolsRequest1Type$outboundSchema:
1696
- z.ZodNativeEnum<typeof CreateToolRequestBodyToolsRequest1Type> = z.nativeEnum(
1697
- CreateToolRequestBodyToolsRequest1Type,
1698
- );
1699
-
1700
- /** @internal */
1701
- export type RequestBodyParameters$Outbound = {
1702
- type: string;
1703
- properties: { [k: string]: any };
1704
- required: Array<string>;
1705
- [additionalProperties: string]: unknown;
1706
- };
1707
-
1708
- /** @internal */
1709
- export const RequestBodyParameters$outboundSchema: z.ZodType<
1710
- RequestBodyParameters$Outbound,
1711
- z.ZodTypeDef,
1712
- RequestBodyParameters
1713
- > = z.object({
1714
- type: CreateToolRequestBodyToolsRequest1Type$outboundSchema,
1715
- properties: z.record(z.any()),
1716
- required: z.array(z.string()),
1717
- additionalProperties: z.record(z.any()).optional(),
1718
- }).transform((v) => {
1719
- return {
1720
- ...v.additionalProperties,
1721
- ...remap$(v, {
1722
- additionalProperties: null,
1723
- }),
1724
- };
1725
- });
1726
-
1727
- export function requestBodyParametersToJSON(
1728
- requestBodyParameters: RequestBodyParameters,
1729
- ): string {
1730
- return JSON.stringify(
1731
- RequestBodyParameters$outboundSchema.parse(requestBodyParameters),
1732
- );
1733
- }
1734
-
1735
- /** @internal */
1736
- export type RequestBodyFunction$Outbound = {
1737
- name: string;
1738
- description?: string | undefined;
1739
- strict?: boolean | undefined;
1740
- parameters?: RequestBodyParameters$Outbound | undefined;
1741
- };
1742
-
1743
- /** @internal */
1744
- export const RequestBodyFunction$outboundSchema: z.ZodType<
1745
- RequestBodyFunction$Outbound,
1746
- z.ZodTypeDef,
1747
- RequestBodyFunction
1748
- > = z.object({
1749
- name: z.string(),
1750
- description: z.string().optional(),
1751
- strict: z.boolean().optional(),
1752
- parameters: z.lazy(() => RequestBodyParameters$outboundSchema).optional(),
1753
- });
1754
-
1755
- export function requestBodyFunctionToJSON(
1756
- requestBodyFunction: RequestBodyFunction,
1757
- ): string {
1758
- return JSON.stringify(
1759
- RequestBodyFunction$outboundSchema.parse(requestBodyFunction),
1760
- );
1761
- }
1762
-
1763
- /** @internal */
1764
- export type RequestBodyFunctionTool$Outbound = {
1765
- path: string;
1766
- key: string;
1767
- display_name?: string | undefined;
1768
- description: string;
1769
- status: string;
1770
- type: "function";
1771
- function: RequestBodyFunction$Outbound;
1772
- };
1773
-
1774
- /** @internal */
1775
- export const RequestBodyFunctionTool$outboundSchema: z.ZodType<
1776
- RequestBodyFunctionTool$Outbound,
1777
- z.ZodTypeDef,
1778
- RequestBodyFunctionTool
1779
- > = z.object({
1780
- path: z.string(),
1781
- key: z.string(),
1782
- displayName: z.string().optional(),
1783
- description: z.string(),
1784
- status: CreateToolRequestBodyToolsRequest1Status$outboundSchema.default(
1785
- "live",
1786
- ),
1787
- type: z.literal("function"),
1788
- function: z.lazy(() => RequestBodyFunction$outboundSchema),
1789
- }).transform((v) => {
1790
- return remap$(v, {
1791
- displayName: "display_name",
1792
- });
1793
- });
1794
-
1795
- export function requestBodyFunctionToolToJSON(
1796
- requestBodyFunctionTool: RequestBodyFunctionTool,
1797
- ): string {
1798
- return JSON.stringify(
1799
- RequestBodyFunctionTool$outboundSchema.parse(requestBodyFunctionTool),
1800
- );
1801
- }
1802
-
1803
- /** @internal */
1804
- export type CreateToolRequestBody$Outbound =
1805
- | RequestBodyFunctionTool$Outbound
1806
- | RequestBodyJSONSchemaTool$Outbound
1807
- | RequestBodyHTTPTool$Outbound
1808
- | RequestBodyMCPTool$Outbound
1809
- | RequestBodyCodeExecutionTool$Outbound;
1810
-
1811
- /** @internal */
1812
- export const CreateToolRequestBody$outboundSchema: z.ZodType<
1813
- CreateToolRequestBody$Outbound,
1814
- z.ZodTypeDef,
1815
- CreateToolRequestBody
1816
- > = z.union([
1817
- z.lazy(() => RequestBodyFunctionTool$outboundSchema),
1818
- z.lazy(() => RequestBodyJSONSchemaTool$outboundSchema),
1819
- z.lazy(() => RequestBodyHTTPTool$outboundSchema),
1820
- z.lazy(() => RequestBodyMCPTool$outboundSchema),
1821
- z.lazy(() => RequestBodyCodeExecutionTool$outboundSchema),
1822
- ]);
1823
-
1824
- export function createToolRequestBodyToJSON(
1825
- createToolRequestBody: CreateToolRequestBody,
1826
- ): string {
1827
- return JSON.stringify(
1828
- CreateToolRequestBody$outboundSchema.parse(createToolRequestBody),
1829
- );
1830
- }
1831
-
1832
- /** @internal */
1833
- export const CreateToolResponseBodyToolsResponse200Status$inboundSchema:
1834
- z.ZodNativeEnum<typeof CreateToolResponseBodyToolsResponse200Status> = z
1835
- .nativeEnum(CreateToolResponseBodyToolsResponse200Status);
1836
-
1837
- /** @internal */
1838
- export const CreateToolResponseBodyToolsResponse200ApplicationJson5Type$inboundSchema:
1839
- z.ZodNativeEnum<
1840
- typeof CreateToolResponseBodyToolsResponse200ApplicationJson5Type
1841
- > = z.nativeEnum(CreateToolResponseBodyToolsResponse200ApplicationJson5Type);
1842
-
1843
- /** @internal */
1844
- export const CreateToolResponseBodyParameters$inboundSchema: z.ZodType<
1845
- CreateToolResponseBodyParameters,
1846
- z.ZodTypeDef,
1847
- unknown
1848
- > = collectExtraKeys$(
1849
- z.object({
1850
- type:
1851
- CreateToolResponseBodyToolsResponse200ApplicationJson5Type$inboundSchema,
1852
- properties: z.record(z.any()),
1853
- required: z.array(z.string()),
1854
- }).catchall(z.any()),
1855
- "additionalProperties",
1856
- true,
1857
- );
1858
-
1859
- export function createToolResponseBodyParametersFromJSON(
1860
- jsonString: string,
1861
- ): SafeParseResult<CreateToolResponseBodyParameters, SDKValidationError> {
1862
- return safeParse(
1863
- jsonString,
1864
- (x) => CreateToolResponseBodyParameters$inboundSchema.parse(JSON.parse(x)),
1865
- `Failed to parse 'CreateToolResponseBodyParameters' from JSON`,
1866
- );
1867
- }
1868
-
1869
- /** @internal */
1870
- export const ResponseBodyLanguage$inboundSchema: z.ZodNativeEnum<
1871
- typeof ResponseBodyLanguage
1872
- > = z.nativeEnum(ResponseBodyLanguage);
1873
-
1874
- /** @internal */
1875
- export const ResponseBodyCodeTool$inboundSchema: z.ZodType<
1876
- ResponseBodyCodeTool,
1877
- z.ZodTypeDef,
1878
- unknown
1879
- > = z.object({
1880
- parameters: z.lazy(() => CreateToolResponseBodyParameters$inboundSchema)
1881
- .optional(),
1882
- language: ResponseBodyLanguage$inboundSchema,
1883
- code: z.string(),
1884
- });
1885
-
1886
- export function responseBodyCodeToolFromJSON(
1887
- jsonString: string,
1888
- ): SafeParseResult<ResponseBodyCodeTool, SDKValidationError> {
1889
- return safeParse(
1890
- jsonString,
1891
- (x) => ResponseBodyCodeTool$inboundSchema.parse(JSON.parse(x)),
1892
- `Failed to parse 'ResponseBodyCodeTool' from JSON`,
1893
- );
1894
- }
1895
-
1896
- /** @internal */
1897
- export const ResponseBodyCodeExecutionTool$inboundSchema: z.ZodType<
1898
- ResponseBodyCodeExecutionTool,
1899
- z.ZodTypeDef,
1900
- unknown
1901
- > = z.object({
1902
- _id: z.string().default("tool_01KJ60BRNFQSP0N5Y8EXZR6N6X"),
1903
- path: z.string(),
1904
- key: z.string(),
1905
- display_name: z.string().optional(),
1906
- description: z.string(),
1907
- created_by_id: z.string().optional(),
1908
- updated_by_id: z.string().optional(),
1909
- project_id: z.string(),
1910
- workspace_id: z.string(),
1911
- created: z.string(),
1912
- updated: z.string(),
1913
- status: CreateToolResponseBodyToolsResponse200Status$inboundSchema.default(
1914
- "live",
1915
- ),
1916
- version_hash: z.string().optional(),
1917
- type: z.literal("code"),
1918
- code_tool: z.lazy(() => ResponseBodyCodeTool$inboundSchema),
1919
- }).transform((v) => {
1920
- return remap$(v, {
1921
- "_id": "id",
1922
- "display_name": "displayName",
1923
- "created_by_id": "createdById",
1924
- "updated_by_id": "updatedById",
1925
- "project_id": "projectId",
1926
- "workspace_id": "workspaceId",
1927
- "version_hash": "versionHash",
1928
- "code_tool": "codeTool",
1929
- });
1930
- });
1931
-
1932
- export function responseBodyCodeExecutionToolFromJSON(
1933
- jsonString: string,
1934
- ): SafeParseResult<ResponseBodyCodeExecutionTool, SDKValidationError> {
1935
- return safeParse(
1936
- jsonString,
1937
- (x) => ResponseBodyCodeExecutionTool$inboundSchema.parse(JSON.parse(x)),
1938
- `Failed to parse 'ResponseBodyCodeExecutionTool' from JSON`,
1939
- );
1940
- }
1941
-
1942
- /** @internal */
1943
- export const CreateToolResponseBodyToolsResponseStatus$inboundSchema:
1944
- z.ZodNativeEnum<typeof CreateToolResponseBodyToolsResponseStatus> = z
1945
- .nativeEnum(CreateToolResponseBodyToolsResponseStatus);
1946
-
1947
- /** @internal */
1948
- export const ResponseBodyHeaders$inboundSchema: z.ZodType<
1949
- ResponseBodyHeaders,
1950
- z.ZodTypeDef,
1951
- unknown
1952
- > = z.object({
1953
- value: z.string(),
1954
- encrypted: z.boolean().default(false),
1955
- });
1956
-
1957
- export function responseBodyHeadersFromJSON(
1958
- jsonString: string,
1959
- ): SafeParseResult<ResponseBodyHeaders, SDKValidationError> {
1960
- return safeParse(
1961
- jsonString,
1962
- (x) => ResponseBodyHeaders$inboundSchema.parse(JSON.parse(x)),
1963
- `Failed to parse 'ResponseBodyHeaders' from JSON`,
1964
- );
1965
- }
1966
-
1967
- /** @internal */
1968
- export const CreateToolResponseBodyToolsResponse200ApplicationJson4Type$inboundSchema:
1969
- z.ZodNativeEnum<
1970
- typeof CreateToolResponseBodyToolsResponse200ApplicationJson4Type
1971
- > = z.nativeEnum(CreateToolResponseBodyToolsResponse200ApplicationJson4Type);
1972
-
1973
- /** @internal */
1974
- export const CreateToolResponseBodySchema$inboundSchema: z.ZodType<
1975
- CreateToolResponseBodySchema,
1976
- z.ZodTypeDef,
1977
- unknown
1978
- > = z.object({
1979
- type:
1980
- CreateToolResponseBodyToolsResponse200ApplicationJson4Type$inboundSchema,
1981
- properties: z.record(z.any()).optional(),
1982
- required: z.array(z.string()).optional(),
1983
- });
1984
-
1985
- export function createToolResponseBodySchemaFromJSON(
1986
- jsonString: string,
1987
- ): SafeParseResult<CreateToolResponseBodySchema, SDKValidationError> {
1988
- return safeParse(
1989
- jsonString,
1990
- (x) => CreateToolResponseBodySchema$inboundSchema.parse(JSON.parse(x)),
1991
- `Failed to parse 'CreateToolResponseBodySchema' from JSON`,
1992
- );
1993
- }
1994
-
1995
- /** @internal */
1996
- export const ResponseBodyTools$inboundSchema: z.ZodType<
1997
- ResponseBodyTools,
1998
- z.ZodTypeDef,
1999
- unknown
2000
- > = z.object({
2001
- id: z.string().default("01KJ60BRNE7HM5QP8Z7V3XXXY2"),
2002
- name: z.string(),
2003
- description: z.string().optional(),
2004
- schema: z.lazy(() => CreateToolResponseBodySchema$inboundSchema),
2005
- });
2006
-
2007
- export function responseBodyToolsFromJSON(
2008
- jsonString: string,
2009
- ): SafeParseResult<ResponseBodyTools, SDKValidationError> {
2010
- return safeParse(
2011
- jsonString,
2012
- (x) => ResponseBodyTools$inboundSchema.parse(JSON.parse(x)),
2013
- `Failed to parse 'ResponseBodyTools' from JSON`,
2014
- );
2015
- }
2016
-
2017
- /** @internal */
2018
- export const ResponseBodyConnectionType$inboundSchema: z.ZodNativeEnum<
2019
- typeof ResponseBodyConnectionType
2020
- > = z.nativeEnum(ResponseBodyConnectionType);
2021
-
2022
- /** @internal */
2023
- export const ResponseBodyMcp$inboundSchema: z.ZodType<
2024
- ResponseBodyMcp,
2025
- z.ZodTypeDef,
2026
- unknown
2027
- > = z.object({
2028
- server_url: z.string(),
2029
- headers: z.record(z.lazy(() => ResponseBodyHeaders$inboundSchema)).optional(),
2030
- tools: z.array(z.lazy(() => ResponseBodyTools$inboundSchema)),
2031
- connection_type: ResponseBodyConnectionType$inboundSchema,
2032
- }).transform((v) => {
2033
- return remap$(v, {
2034
- "server_url": "serverUrl",
2035
- "connection_type": "connectionType",
2036
- });
2037
- });
2038
-
2039
- export function responseBodyMcpFromJSON(
2040
- jsonString: string,
2041
- ): SafeParseResult<ResponseBodyMcp, SDKValidationError> {
2042
- return safeParse(
2043
- jsonString,
2044
- (x) => ResponseBodyMcp$inboundSchema.parse(JSON.parse(x)),
2045
- `Failed to parse 'ResponseBodyMcp' from JSON`,
2046
- );
2047
- }
2048
-
2049
- /** @internal */
2050
- export const ResponseBodyMCPTool$inboundSchema: z.ZodType<
2051
- ResponseBodyMCPTool,
2052
- z.ZodTypeDef,
2053
- unknown
2054
- > = z.object({
2055
- _id: z.string().default("tool_01KJ60BRND6MX84FR98EM4VKMW"),
2056
- path: z.string(),
2057
- key: z.string(),
2058
- display_name: z.string().optional(),
2059
- description: z.string(),
2060
- created_by_id: z.string().optional(),
2061
- updated_by_id: z.string().optional(),
2062
- project_id: z.string(),
2063
- workspace_id: z.string(),
2064
- created: z.string(),
2065
- updated: z.string(),
2066
- status: CreateToolResponseBodyToolsResponseStatus$inboundSchema.default(
2067
- "live",
2068
- ),
2069
- version_hash: z.string().optional(),
2070
- type: z.literal("mcp"),
2071
- mcp: z.lazy(() => ResponseBodyMcp$inboundSchema),
2072
- }).transform((v) => {
2073
- return remap$(v, {
2074
- "_id": "id",
2075
- "display_name": "displayName",
2076
- "created_by_id": "createdById",
2077
- "updated_by_id": "updatedById",
2078
- "project_id": "projectId",
2079
- "workspace_id": "workspaceId",
2080
- "version_hash": "versionHash",
2081
- });
2082
- });
2083
-
2084
- export function responseBodyMCPToolFromJSON(
2085
- jsonString: string,
2086
- ): SafeParseResult<ResponseBodyMCPTool, SDKValidationError> {
2087
- return safeParse(
2088
- jsonString,
2089
- (x) => ResponseBodyMCPTool$inboundSchema.parse(JSON.parse(x)),
2090
- `Failed to parse 'ResponseBodyMCPTool' from JSON`,
2091
- );
2092
- }
2093
-
2094
- /** @internal */
2095
- export const CreateToolResponseBodyToolsStatus$inboundSchema: z.ZodNativeEnum<
2096
- typeof CreateToolResponseBodyToolsStatus
2097
- > = z.nativeEnum(CreateToolResponseBodyToolsStatus);
2098
-
2099
- /** @internal */
2100
- export const CreateToolResponseBodyMethod$inboundSchema: z.ZodNativeEnum<
2101
- typeof CreateToolResponseBodyMethod
2102
- > = z.nativeEnum(CreateToolResponseBodyMethod);
2103
-
2104
- /** @internal */
2105
- export const CreateToolHeadersTools2$inboundSchema: z.ZodType<
2106
- CreateToolHeadersTools2,
2107
- z.ZodTypeDef,
2108
- unknown
2109
- > = z.object({
2110
- value: z.string(),
2111
- encrypted: z.boolean().default(false),
2112
- });
2113
-
2114
- export function createToolHeadersTools2FromJSON(
2115
- jsonString: string,
2116
- ): SafeParseResult<CreateToolHeadersTools2, SDKValidationError> {
2117
- return safeParse(
2118
- jsonString,
2119
- (x) => CreateToolHeadersTools2$inboundSchema.parse(JSON.parse(x)),
2120
- `Failed to parse 'CreateToolHeadersTools2' from JSON`,
2121
- );
2122
- }
2123
-
2124
- /** @internal */
2125
- export const CreateToolResponseBodyHeaders$inboundSchema: z.ZodType<
2126
- CreateToolResponseBodyHeaders,
2127
- z.ZodTypeDef,
2128
- unknown
2129
- > = z.union([z.lazy(() => CreateToolHeadersTools2$inboundSchema), z.string()]);
2130
-
2131
- export function createToolResponseBodyHeadersFromJSON(
2132
- jsonString: string,
2133
- ): SafeParseResult<CreateToolResponseBodyHeaders, SDKValidationError> {
2134
- return safeParse(
2135
- jsonString,
2136
- (x) => CreateToolResponseBodyHeaders$inboundSchema.parse(JSON.parse(x)),
2137
- `Failed to parse 'CreateToolResponseBodyHeaders' from JSON`,
2138
- );
2139
- }
2140
-
2141
- /** @internal */
2142
- export const ResponseBodyBlueprint$inboundSchema: z.ZodType<
2143
- ResponseBodyBlueprint,
2144
- z.ZodTypeDef,
2145
- unknown
2146
- > = z.object({
2147
- url: z.string(),
2148
- method: CreateToolResponseBodyMethod$inboundSchema,
2149
- headers: z.record(
2150
- z.union([z.lazy(() => CreateToolHeadersTools2$inboundSchema), z.string()]),
2151
- ).optional(),
2152
- body: z.record(z.any()).optional(),
2153
- });
2154
-
2155
- export function responseBodyBlueprintFromJSON(
2156
- jsonString: string,
2157
- ): SafeParseResult<ResponseBodyBlueprint, SDKValidationError> {
2158
- return safeParse(
2159
- jsonString,
2160
- (x) => ResponseBodyBlueprint$inboundSchema.parse(JSON.parse(x)),
2161
- `Failed to parse 'ResponseBodyBlueprint' from JSON`,
2162
- );
2163
- }
2164
-
2165
- /** @internal */
2166
- export const CreateToolResponseBodyToolsResponse200ApplicationJson3Type$inboundSchema:
2167
- z.ZodNativeEnum<
2168
- typeof CreateToolResponseBodyToolsResponse200ApplicationJson3Type
2169
- > = z.nativeEnum(CreateToolResponseBodyToolsResponse200ApplicationJson3Type);
2170
-
2171
- /** @internal */
2172
- export const ResponseBodyDefaultValue$inboundSchema: z.ZodType<
2173
- ResponseBodyDefaultValue,
2174
- z.ZodTypeDef,
2175
- unknown
2176
- > = z.union([z.string(), z.number(), z.boolean()]);
2177
-
2178
- export function responseBodyDefaultValueFromJSON(
2179
- jsonString: string,
2180
- ): SafeParseResult<ResponseBodyDefaultValue, SDKValidationError> {
2181
- return safeParse(
2182
- jsonString,
2183
- (x) => ResponseBodyDefaultValue$inboundSchema.parse(JSON.parse(x)),
2184
- `Failed to parse 'ResponseBodyDefaultValue' from JSON`,
2185
- );
2186
- }
2187
-
2188
- /** @internal */
2189
- export const ResponseBodyArguments$inboundSchema: z.ZodType<
2190
- ResponseBodyArguments,
2191
- z.ZodTypeDef,
2192
- unknown
2193
- > = z.object({
2194
- type:
2195
- CreateToolResponseBodyToolsResponse200ApplicationJson3Type$inboundSchema,
2196
- description: z.string(),
2197
- send_to_model: z.boolean().default(true),
2198
- default_value: z.union([z.string(), z.number(), z.boolean()]).optional(),
2199
- }).transform((v) => {
2200
- return remap$(v, {
2201
- "send_to_model": "sendToModel",
2202
- "default_value": "defaultValue",
2203
- });
2204
- });
2205
-
2206
- export function responseBodyArgumentsFromJSON(
2207
- jsonString: string,
2208
- ): SafeParseResult<ResponseBodyArguments, SDKValidationError> {
2209
- return safeParse(
2210
- jsonString,
2211
- (x) => ResponseBodyArguments$inboundSchema.parse(JSON.parse(x)),
2212
- `Failed to parse 'ResponseBodyArguments' from JSON`,
2213
- );
2214
- }
2215
-
2216
- /** @internal */
2217
- export const CreateToolResponseBodyHttp$inboundSchema: z.ZodType<
2218
- CreateToolResponseBodyHttp,
2219
- z.ZodTypeDef,
2220
- unknown
2221
- > = z.object({
2222
- blueprint: z.lazy(() => ResponseBodyBlueprint$inboundSchema),
2223
- arguments: z.record(z.lazy(() => ResponseBodyArguments$inboundSchema))
2224
- .optional(),
2225
- });
2226
-
2227
- export function createToolResponseBodyHttpFromJSON(
2228
- jsonString: string,
2229
- ): SafeParseResult<CreateToolResponseBodyHttp, SDKValidationError> {
2230
- return safeParse(
2231
- jsonString,
2232
- (x) => CreateToolResponseBodyHttp$inboundSchema.parse(JSON.parse(x)),
2233
- `Failed to parse 'CreateToolResponseBodyHttp' from JSON`,
2234
- );
2235
- }
2236
-
2237
- /** @internal */
2238
- export const ResponseBodyHTTPTool$inboundSchema: z.ZodType<
2239
- ResponseBodyHTTPTool,
2240
- z.ZodTypeDef,
2241
- unknown
2242
- > = z.object({
2243
- _id: z.string().default("tool_01KJ60BRNB9A30KG30G25V5S27"),
2244
- path: z.string(),
2245
- key: z.string(),
2246
- display_name: z.string().optional(),
2247
- description: z.string(),
2248
- created_by_id: z.string().optional(),
2249
- updated_by_id: z.string().optional(),
2250
- project_id: z.string(),
2251
- workspace_id: z.string(),
2252
- created: z.string(),
2253
- updated: z.string(),
2254
- status: CreateToolResponseBodyToolsStatus$inboundSchema.default("live"),
2255
- version_hash: z.string().optional(),
2256
- type: z.literal("http"),
2257
- http: z.lazy(() => CreateToolResponseBodyHttp$inboundSchema),
2258
- }).transform((v) => {
2259
- return remap$(v, {
2260
- "_id": "id",
2261
- "display_name": "displayName",
2262
- "created_by_id": "createdById",
2263
- "updated_by_id": "updatedById",
2264
- "project_id": "projectId",
2265
- "workspace_id": "workspaceId",
2266
- "version_hash": "versionHash",
2267
- });
2268
- });
2269
-
2270
- export function responseBodyHTTPToolFromJSON(
2271
- jsonString: string,
2272
- ): SafeParseResult<ResponseBodyHTTPTool, SDKValidationError> {
2273
- return safeParse(
2274
- jsonString,
2275
- (x) => ResponseBodyHTTPTool$inboundSchema.parse(JSON.parse(x)),
2276
- `Failed to parse 'ResponseBodyHTTPTool' from JSON`,
2277
- );
2278
- }
2279
-
2280
- /** @internal */
2281
- export const CreateToolResponseBodyStatus$inboundSchema: z.ZodNativeEnum<
2282
- typeof CreateToolResponseBodyStatus
2283
- > = z.nativeEnum(CreateToolResponseBodyStatus);
2284
-
2285
- /** @internal */
2286
- export const ResponseBodySchema$inboundSchema: z.ZodType<
2287
- ResponseBodySchema,
2288
- z.ZodTypeDef,
2289
- unknown
2290
- > = collectExtraKeys$(
2291
- z.object({
2292
- type: z.string(),
2293
- properties: z.record(z.any()),
2294
- required: z.array(z.string()),
2295
- }).catchall(z.any()),
2296
- "additionalProperties",
2297
- true,
2298
- );
2299
-
2300
- export function responseBodySchemaFromJSON(
2301
- jsonString: string,
2302
- ): SafeParseResult<ResponseBodySchema, SDKValidationError> {
2303
- return safeParse(
2304
- jsonString,
2305
- (x) => ResponseBodySchema$inboundSchema.parse(JSON.parse(x)),
2306
- `Failed to parse 'ResponseBodySchema' from JSON`,
2307
- );
2308
- }
2309
-
2310
- /** @internal */
2311
- export const ResponseBodyJsonSchema$inboundSchema: z.ZodType<
2312
- ResponseBodyJsonSchema,
2313
- z.ZodTypeDef,
2314
- unknown
2315
- > = z.object({
2316
- name: z.string(),
2317
- description: z.string(),
2318
- schema: z.lazy(() => ResponseBodySchema$inboundSchema),
2319
- strict: z.boolean().optional(),
2320
- });
2321
-
2322
- export function responseBodyJsonSchemaFromJSON(
2323
- jsonString: string,
2324
- ): SafeParseResult<ResponseBodyJsonSchema, SDKValidationError> {
2325
- return safeParse(
2326
- jsonString,
2327
- (x) => ResponseBodyJsonSchema$inboundSchema.parse(JSON.parse(x)),
2328
- `Failed to parse 'ResponseBodyJsonSchema' from JSON`,
2329
- );
2330
- }
2331
-
2332
- /** @internal */
2333
- export const ResponseBodyJSONSchemaTool$inboundSchema: z.ZodType<
2334
- ResponseBodyJSONSchemaTool,
2335
- z.ZodTypeDef,
2336
- unknown
2337
- > = z.object({
2338
- _id: z.string().default("tool_01KJ60BRN393JK0E6VHEKVNJP0"),
2339
- path: z.string(),
2340
- key: z.string(),
2341
- display_name: z.string().optional(),
2342
- description: z.string(),
2343
- created_by_id: z.string().optional(),
2344
- updated_by_id: z.string().optional(),
2345
- project_id: z.string(),
2346
- workspace_id: z.string(),
2347
- created: z.string(),
2348
- updated: z.string(),
2349
- status: CreateToolResponseBodyStatus$inboundSchema.default("live"),
2350
- version_hash: z.string().optional(),
2351
- type: z.literal("json_schema"),
2352
- json_schema: z.lazy(() => ResponseBodyJsonSchema$inboundSchema),
2353
- }).transform((v) => {
2354
- return remap$(v, {
2355
- "_id": "id",
2356
- "display_name": "displayName",
2357
- "created_by_id": "createdById",
2358
- "updated_by_id": "updatedById",
2359
- "project_id": "projectId",
2360
- "workspace_id": "workspaceId",
2361
- "version_hash": "versionHash",
2362
- "json_schema": "jsonSchema",
2363
- });
2364
- });
2365
-
2366
- export function responseBodyJSONSchemaToolFromJSON(
2367
- jsonString: string,
2368
- ): SafeParseResult<ResponseBodyJSONSchemaTool, SDKValidationError> {
2369
- return safeParse(
2370
- jsonString,
2371
- (x) => ResponseBodyJSONSchemaTool$inboundSchema.parse(JSON.parse(x)),
2372
- `Failed to parse 'ResponseBodyJSONSchemaTool' from JSON`,
2373
- );
2374
- }
2375
-
2376
- /** @internal */
2377
- export const ResponseBodyStatus$inboundSchema: z.ZodNativeEnum<
2378
- typeof ResponseBodyStatus
2379
- > = z.nativeEnum(ResponseBodyStatus);
2380
-
2381
- /** @internal */
2382
- export const CreateToolResponseBodyToolsResponse200ApplicationJson1Type$inboundSchema:
2383
- z.ZodNativeEnum<
2384
- typeof CreateToolResponseBodyToolsResponse200ApplicationJson1Type
2385
- > = z.nativeEnum(CreateToolResponseBodyToolsResponse200ApplicationJson1Type);
2386
-
2387
- /** @internal */
2388
- export const ResponseBodyParameters$inboundSchema: z.ZodType<
2389
- ResponseBodyParameters,
2390
- z.ZodTypeDef,
2391
- unknown
2392
- > = collectExtraKeys$(
2393
- z.object({
2394
- type:
2395
- CreateToolResponseBodyToolsResponse200ApplicationJson1Type$inboundSchema,
2396
- properties: z.record(z.any()),
2397
- required: z.array(z.string()),
2398
- }).catchall(z.any()),
2399
- "additionalProperties",
2400
- true,
2401
- );
2402
-
2403
- export function responseBodyParametersFromJSON(
2404
- jsonString: string,
2405
- ): SafeParseResult<ResponseBodyParameters, SDKValidationError> {
2406
- return safeParse(
2407
- jsonString,
2408
- (x) => ResponseBodyParameters$inboundSchema.parse(JSON.parse(x)),
2409
- `Failed to parse 'ResponseBodyParameters' from JSON`,
2410
- );
2411
- }
2412
-
2413
- /** @internal */
2414
- export const CreateToolResponseBodyFunction$inboundSchema: z.ZodType<
2415
- CreateToolResponseBodyFunction,
2416
- z.ZodTypeDef,
2417
- unknown
2418
- > = z.object({
2419
- name: z.string(),
2420
- description: z.string().optional(),
2421
- strict: z.boolean().optional(),
2422
- parameters: z.lazy(() => ResponseBodyParameters$inboundSchema).optional(),
2423
- });
2424
-
2425
- export function createToolResponseBodyFunctionFromJSON(
2426
- jsonString: string,
2427
- ): SafeParseResult<CreateToolResponseBodyFunction, SDKValidationError> {
2428
- return safeParse(
2429
- jsonString,
2430
- (x) => CreateToolResponseBodyFunction$inboundSchema.parse(JSON.parse(x)),
2431
- `Failed to parse 'CreateToolResponseBodyFunction' from JSON`,
2432
- );
2433
- }
2434
-
2435
- /** @internal */
2436
- export const ResponseBodyFunctionTool$inboundSchema: z.ZodType<
2437
- ResponseBodyFunctionTool,
2438
- z.ZodTypeDef,
2439
- unknown
2440
- > = z.object({
2441
- _id: z.string().default("tool_01KJ60BRN1BVP1PM31X6PSMKJ4"),
2442
- path: z.string(),
2443
- key: z.string(),
2444
- display_name: z.string().optional(),
2445
- description: z.string(),
2446
- created_by_id: z.string().optional(),
2447
- updated_by_id: z.string().optional(),
2448
- project_id: z.string(),
2449
- workspace_id: z.string(),
2450
- created: z.string(),
2451
- updated: z.string(),
2452
- status: ResponseBodyStatus$inboundSchema.default("live"),
2453
- version_hash: z.string().optional(),
2454
- type: z.literal("function"),
2455
- function: z.lazy(() => CreateToolResponseBodyFunction$inboundSchema),
2456
- }).transform((v) => {
2457
- return remap$(v, {
2458
- "_id": "id",
2459
- "display_name": "displayName",
2460
- "created_by_id": "createdById",
2461
- "updated_by_id": "updatedById",
2462
- "project_id": "projectId",
2463
- "workspace_id": "workspaceId",
2464
- "version_hash": "versionHash",
2465
- });
2466
- });
2467
-
2468
- export function responseBodyFunctionToolFromJSON(
2469
- jsonString: string,
2470
- ): SafeParseResult<ResponseBodyFunctionTool, SDKValidationError> {
2471
- return safeParse(
2472
- jsonString,
2473
- (x) => ResponseBodyFunctionTool$inboundSchema.parse(JSON.parse(x)),
2474
- `Failed to parse 'ResponseBodyFunctionTool' from JSON`,
2475
- );
2476
- }
2477
-
2478
- /** @internal */
2479
- export const CreateToolResponseBody$inboundSchema: z.ZodType<
2480
- CreateToolResponseBody,
2481
- z.ZodTypeDef,
2482
- unknown
2483
- > = z.union([
2484
- z.lazy(() => ResponseBodyFunctionTool$inboundSchema),
2485
- z.lazy(() => ResponseBodyJSONSchemaTool$inboundSchema),
2486
- z.lazy(() => ResponseBodyHTTPTool$inboundSchema),
2487
- z.lazy(() => ResponseBodyMCPTool$inboundSchema),
2488
- z.lazy(() => ResponseBodyCodeExecutionTool$inboundSchema),
2489
- ]);
2490
-
2491
- export function createToolResponseBodyFromJSON(
2492
- jsonString: string,
2493
- ): SafeParseResult<CreateToolResponseBody, SDKValidationError> {
2494
- return safeParse(
2495
- jsonString,
2496
- (x) => CreateToolResponseBody$inboundSchema.parse(JSON.parse(x)),
2497
- `Failed to parse 'CreateToolResponseBody' from JSON`,
2498
- );
2499
- }