@orq-ai/node 3.5.13 → 3.6.0-rc.11

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 (394) hide show
  1. package/README.md +6 -0
  2. package/bin/mcp-server.js +4828 -608
  3. package/bin/mcp-server.js.map +44 -35
  4. package/docs/sdks/datasets/README.md +91 -4
  5. package/docs/sdks/deployments/README.md +89 -0
  6. package/docs/sdks/knowledge/README.md +81 -4
  7. package/docs/sdks/prompts/README.md +4 -4
  8. package/funcs/datasetsCreateExperiment.d.ts +16 -0
  9. package/funcs/datasetsCreateExperiment.d.ts.map +1 -0
  10. package/funcs/datasetsCreateExperiment.js +118 -0
  11. package/funcs/datasetsCreateExperiment.js.map +1 -0
  12. package/funcs/deploymentsCreateExperiment.d.ts +16 -0
  13. package/funcs/deploymentsCreateExperiment.d.ts.map +1 -0
  14. package/funcs/deploymentsCreateExperiment.js +118 -0
  15. package/funcs/deploymentsCreateExperiment.js.map +1 -0
  16. package/funcs/knowledgeSearch.d.ts +16 -0
  17. package/funcs/knowledgeSearch.d.ts.map +1 -0
  18. package/funcs/knowledgeSearch.js +118 -0
  19. package/funcs/knowledgeSearch.js.map +1 -0
  20. package/jsr.json +1 -1
  21. package/lib/config.d.ts +2 -2
  22. package/lib/config.js +2 -2
  23. package/lib/config.js.map +1 -1
  24. package/mcp-server/mcp-server.js +1 -1
  25. package/mcp-server/mcp-server.js.map +1 -1
  26. package/mcp-server/server.d.ts.map +1 -1
  27. package/mcp-server/server.js +7 -1
  28. package/mcp-server/server.js.map +1 -1
  29. package/mcp-server/tools/datasetsCreateExperiment.d.ts +8 -0
  30. package/mcp-server/tools/datasetsCreateExperiment.d.ts.map +1 -0
  31. package/mcp-server/tools/datasetsCreateExperiment.js +64 -0
  32. package/mcp-server/tools/datasetsCreateExperiment.js.map +1 -0
  33. package/mcp-server/tools/deploymentsCreateExperiment.d.ts +8 -0
  34. package/mcp-server/tools/deploymentsCreateExperiment.d.ts.map +1 -0
  35. package/mcp-server/tools/deploymentsCreateExperiment.js +64 -0
  36. package/mcp-server/tools/deploymentsCreateExperiment.js.map +1 -0
  37. package/mcp-server/tools/knowledgeSearch.d.ts +8 -0
  38. package/mcp-server/tools/knowledgeSearch.d.ts.map +1 -0
  39. package/mcp-server/tools/knowledgeSearch.js +64 -0
  40. package/mcp-server/tools/knowledgeSearch.js.map +1 -0
  41. package/models/components/deployments.d.ts +1442 -67
  42. package/models/components/deployments.d.ts.map +1 -1
  43. package/models/components/deployments.js +1881 -126
  44. package/models/components/deployments.js.map +1 -1
  45. package/models/operations/bulkcreatedatapoints.js +2 -2
  46. package/models/operations/createchunk.d.ts +32 -17
  47. package/models/operations/createchunk.d.ts.map +1 -1
  48. package/models/operations/createchunk.js +30 -19
  49. package/models/operations/createchunk.js.map +1 -1
  50. package/models/operations/createcontact.js +2 -2
  51. package/models/operations/createdataset.js +2 -2
  52. package/models/operations/createdatasetexperiment.d.ts +140 -0
  53. package/models/operations/createdatasetexperiment.d.ts.map +1 -0
  54. package/models/operations/createdatasetexperiment.js +188 -0
  55. package/models/operations/createdatasetexperiment.js.map +1 -0
  56. package/models/operations/createdatasetitem.js +2 -2
  57. package/models/operations/createdatasource.js +2 -2
  58. package/models/operations/createdeploymentexperiment.d.ts +152 -0
  59. package/models/operations/createdeploymentexperiment.d.ts.map +1 -0
  60. package/models/operations/createdeploymentexperiment.js +189 -0
  61. package/models/operations/createdeploymentexperiment.js.map +1 -0
  62. package/models/operations/deploymentcreatemetric.d.ts +240 -28
  63. package/models/operations/deploymentcreatemetric.d.ts.map +1 -1
  64. package/models/operations/deploymentcreatemetric.js +236 -29
  65. package/models/operations/deploymentcreatemetric.js.map +1 -1
  66. package/models/operations/deploymentgetconfig.d.ts +1428 -53
  67. package/models/operations/deploymentgetconfig.d.ts.map +1 -1
  68. package/models/operations/deploymentgetconfig.js +1876 -120
  69. package/models/operations/deploymentgetconfig.js.map +1 -1
  70. package/models/operations/deploymentinvoke.d.ts +34 -4
  71. package/models/operations/deploymentinvoke.d.ts.map +1 -1
  72. package/models/operations/deploymentinvoke.js +30 -4
  73. package/models/operations/deploymentinvoke.js.map +1 -1
  74. package/models/operations/deploymentstream.d.ts +1425 -50
  75. package/models/operations/deploymentstream.d.ts.map +1 -1
  76. package/models/operations/deploymentstream.js +1840 -88
  77. package/models/operations/deploymentstream.js.map +1 -1
  78. package/models/operations/fileget.js +2 -2
  79. package/models/operations/filelist.js +2 -2
  80. package/models/operations/fileupload.d.ts +15 -15
  81. package/models/operations/fileupload.d.ts.map +1 -1
  82. package/models/operations/fileupload.js +20 -21
  83. package/models/operations/fileupload.js.map +1 -1
  84. package/models/operations/getonechunk.d.ts +24 -3
  85. package/models/operations/getonechunk.d.ts.map +1 -1
  86. package/models/operations/getonechunk.js +26 -3
  87. package/models/operations/getonechunk.js.map +1 -1
  88. package/models/operations/index.d.ts +3 -0
  89. package/models/operations/index.d.ts.map +1 -1
  90. package/models/operations/index.js +3 -0
  91. package/models/operations/index.js.map +1 -1
  92. package/models/operations/listchunks.d.ts +24 -3
  93. package/models/operations/listchunks.d.ts.map +1 -1
  94. package/models/operations/listchunks.js +26 -3
  95. package/models/operations/listchunks.js.map +1 -1
  96. package/models/operations/listdatasetdatapoints.js +2 -2
  97. package/models/operations/listdatasets.js +2 -2
  98. package/models/operations/listdatasources.js +2 -2
  99. package/models/operations/retrievedatapoint.js +2 -2
  100. package/models/operations/retrievedataset.js +2 -2
  101. package/models/operations/retrievedatasource.js +2 -2
  102. package/models/operations/searchknowledge.d.ts +1379 -0
  103. package/models/operations/searchknowledge.d.ts.map +1 -0
  104. package/models/operations/searchknowledge.js +1817 -0
  105. package/models/operations/searchknowledge.js.map +1 -0
  106. package/models/operations/updatechunk.d.ts +32 -17
  107. package/models/operations/updatechunk.d.ts.map +1 -1
  108. package/models/operations/updatechunk.js +30 -19
  109. package/models/operations/updatechunk.js.map +1 -1
  110. package/models/operations/updatedatapoint.js +2 -2
  111. package/models/operations/updatedataset.js +2 -2
  112. package/models/operations/updatedatasource.js +2 -2
  113. package/package.json +3 -2
  114. package/sdk/datasets.d.ts +7 -0
  115. package/sdk/datasets.d.ts.map +1 -1
  116. package/sdk/datasets.js +10 -0
  117. package/sdk/datasets.js.map +1 -1
  118. package/sdk/deployments.d.ts +7 -0
  119. package/sdk/deployments.d.ts.map +1 -1
  120. package/sdk/deployments.js +10 -0
  121. package/sdk/deployments.js.map +1 -1
  122. package/sdk/knowledge.d.ts +7 -0
  123. package/sdk/knowledge.d.ts.map +1 -1
  124. package/sdk/knowledge.js +10 -0
  125. package/sdk/knowledge.js.map +1 -1
  126. package/src/lib/config.ts +2 -2
  127. package/src/mcp-server/mcp-server.ts +1 -1
  128. package/src/mcp-server/server.ts +7 -1
  129. package/src/models/components/deployments.ts +3655 -165
  130. package/src/models/operations/bulkcreatedatapoints.ts +2 -2
  131. package/src/models/operations/createchunk.ts +65 -35
  132. package/src/models/operations/createcontact.ts +2 -2
  133. package/src/models/operations/createdataset.ts +2 -2
  134. package/src/models/operations/createdatasetitem.ts +2 -2
  135. package/src/models/operations/createdatasource.ts +2 -2
  136. package/src/models/operations/deploymentcreatemetric.ts +517 -40
  137. package/src/models/operations/deploymentgetconfig.ts +3656 -118
  138. package/src/models/operations/deploymentinvoke.ts +64 -8
  139. package/src/models/operations/deploymentstream.ts +3997 -116
  140. package/src/models/operations/fileget.ts +2 -2
  141. package/src/models/operations/filelist.ts +2 -2
  142. package/src/models/operations/fileupload.ts +37 -34
  143. package/src/models/operations/getonechunk.ts +55 -5
  144. package/src/models/operations/index.ts +3 -0
  145. package/src/models/operations/listchunks.ts +55 -5
  146. package/src/models/operations/listdatasetdatapoints.ts +2 -2
  147. package/src/models/operations/listdatasets.ts +2 -2
  148. package/src/models/operations/listdatasources.ts +2 -2
  149. package/src/models/operations/retrievedatapoint.ts +2 -2
  150. package/src/models/operations/retrievedataset.ts +2 -2
  151. package/src/models/operations/retrievedatasource.ts +2 -2
  152. package/src/models/operations/updatechunk.ts +65 -35
  153. package/src/models/operations/updatedatapoint.ts +2 -2
  154. package/src/models/operations/updatedataset.ts +2 -2
  155. package/src/models/operations/updatedatasource.ts +2 -2
  156. package/src/sdk/datasets.ts +18 -0
  157. package/src/sdk/deployments.ts +18 -0
  158. package/src/sdk/knowledge.ts +18 -0
  159. package/packages/orq-rc/FUNCTIONS.md +0 -106
  160. package/packages/orq-rc/README.md +0 -707
  161. package/packages/orq-rc/RUNTIMES.md +0 -48
  162. package/packages/orq-rc/docs/sdks/contacts/README.md +0 -84
  163. package/packages/orq-rc/docs/sdks/datasets/README.md +0 -1027
  164. package/packages/orq-rc/docs/sdks/deployments/README.md +0 -405
  165. package/packages/orq-rc/docs/sdks/feedback/README.md +0 -92
  166. package/packages/orq-rc/docs/sdks/files/README.md +0 -311
  167. package/packages/orq-rc/docs/sdks/knowledge/README.md +0 -1273
  168. package/packages/orq-rc/docs/sdks/metrics/README.md +0 -86
  169. package/packages/orq-rc/docs/sdks/models/README.md +0 -79
  170. package/packages/orq-rc/docs/sdks/orq/README.md +0 -10
  171. package/packages/orq-rc/docs/sdks/prompts/README.md +0 -576
  172. package/packages/orq-rc/docs/sdks/remoteconfigs/README.md +0 -80
  173. package/packages/orq-rc/jsr.json +0 -28
  174. package/packages/orq-rc/package-lock.json +0 -3217
  175. package/packages/orq-rc/package.json +0 -45
  176. package/packages/orq-rc/src/core.ts +0 -13
  177. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -154
  178. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -161
  179. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -159
  180. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -161
  181. package/packages/orq-rc/src/funcs/datasetsCreateDatapoints.ts +0 -165
  182. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -161
  183. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -176
  184. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -161
  185. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -168
  186. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -169
  187. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -175
  188. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -170
  189. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -173
  190. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -162
  191. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -170
  192. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -170
  193. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -162
  194. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -178
  195. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -154
  196. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -174
  197. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -158
  198. package/packages/orq-rc/src/funcs/filesGet.ts +0 -160
  199. package/packages/orq-rc/src/funcs/filesList.ts +0 -161
  200. package/packages/orq-rc/src/funcs/knowledgeCreate.ts +0 -152
  201. package/packages/orq-rc/src/funcs/knowledgeCreateChunks.ts +0 -165
  202. package/packages/orq-rc/src/funcs/knowledgeCreateDatasource.ts +0 -160
  203. package/packages/orq-rc/src/funcs/knowledgeDelete.ts +0 -161
  204. package/packages/orq-rc/src/funcs/knowledgeDeleteChunk.ts +0 -168
  205. package/packages/orq-rc/src/funcs/knowledgeDeleteDatasource.ts +0 -167
  206. package/packages/orq-rc/src/funcs/knowledgeList.ts +0 -163
  207. package/packages/orq-rc/src/funcs/knowledgeListChunks.ts +0 -172
  208. package/packages/orq-rc/src/funcs/knowledgeListDatasources.ts +0 -168
  209. package/packages/orq-rc/src/funcs/knowledgeRetrieve.ts +0 -160
  210. package/packages/orq-rc/src/funcs/knowledgeRetrieveChunk.ts +0 -167
  211. package/packages/orq-rc/src/funcs/knowledgeRetrieveDatasource.ts +0 -163
  212. package/packages/orq-rc/src/funcs/knowledgeUpdate.ts +0 -158
  213. package/packages/orq-rc/src/funcs/knowledgeUpdateChunk.ts +0 -168
  214. package/packages/orq-rc/src/funcs/knowledgeUpdateDatasource.ts +0 -164
  215. package/packages/orq-rc/src/funcs/modelsList.ts +0 -136
  216. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -154
  217. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -158
  218. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -175
  219. package/packages/orq-rc/src/funcs/promptsList.ts +0 -161
  220. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -167
  221. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -160
  222. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -167
  223. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -155
  224. package/packages/orq-rc/src/hooks/global.ts +0 -44
  225. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  226. package/packages/orq-rc/src/hooks/index.ts +0 -6
  227. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  228. package/packages/orq-rc/src/hooks/types.ts +0 -110
  229. package/packages/orq-rc/src/index.ts +0 -7
  230. package/packages/orq-rc/src/lib/base64.ts +0 -37
  231. package/packages/orq-rc/src/lib/config.ts +0 -70
  232. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  233. package/packages/orq-rc/src/lib/encodings.ts +0 -483
  234. package/packages/orq-rc/src/lib/env.ts +0 -73
  235. package/packages/orq-rc/src/lib/event-streams.ts +0 -264
  236. package/packages/orq-rc/src/lib/files.ts +0 -40
  237. package/packages/orq-rc/src/lib/http.ts +0 -323
  238. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  239. package/packages/orq-rc/src/lib/logger.ts +0 -9
  240. package/packages/orq-rc/src/lib/matchers.ts +0 -345
  241. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  242. package/packages/orq-rc/src/lib/retries.ts +0 -218
  243. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  244. package/packages/orq-rc/src/lib/sdks.ts +0 -401
  245. package/packages/orq-rc/src/lib/security.ts +0 -261
  246. package/packages/orq-rc/src/lib/url.ts +0 -33
  247. package/packages/orq-rc/src/mcp-server/cli/start/command.ts +0 -125
  248. package/packages/orq-rc/src/mcp-server/cli/start/impl.ts +0 -140
  249. package/packages/orq-rc/src/mcp-server/cli.ts +0 -13
  250. package/packages/orq-rc/src/mcp-server/console-logger.ts +0 -71
  251. package/packages/orq-rc/src/mcp-server/extensions.ts +0 -17
  252. package/packages/orq-rc/src/mcp-server/mcp-server.ts +0 -26
  253. package/packages/orq-rc/src/mcp-server/prompts.ts +0 -117
  254. package/packages/orq-rc/src/mcp-server/resources.ts +0 -172
  255. package/packages/orq-rc/src/mcp-server/scopes.ts +0 -7
  256. package/packages/orq-rc/src/mcp-server/server.ts +0 -163
  257. package/packages/orq-rc/src/mcp-server/shared.ts +0 -75
  258. package/packages/orq-rc/src/mcp-server/tools/contactsCreate.ts +0 -37
  259. package/packages/orq-rc/src/mcp-server/tools/datasetsClear.ts +0 -35
  260. package/packages/orq-rc/src/mcp-server/tools/datasetsCreate.ts +0 -37
  261. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoint.ts +0 -37
  262. package/packages/orq-rc/src/mcp-server/tools/datasetsCreateDatapoints.ts +0 -37
  263. package/packages/orq-rc/src/mcp-server/tools/datasetsDelete.ts +0 -35
  264. package/packages/orq-rc/src/mcp-server/tools/datasetsDeleteDatapoint.ts +0 -35
  265. package/packages/orq-rc/src/mcp-server/tools/datasetsList.ts +0 -37
  266. package/packages/orq-rc/src/mcp-server/tools/datasetsListDatapoints.ts +0 -37
  267. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieve.ts +0 -37
  268. package/packages/orq-rc/src/mcp-server/tools/datasetsRetrieveDatapoint.ts +0 -37
  269. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdate.ts +0 -37
  270. package/packages/orq-rc/src/mcp-server/tools/datasetsUpdateDatapoint.ts +0 -35
  271. package/packages/orq-rc/src/mcp-server/tools/deploymentsGetConfig.ts +0 -37
  272. package/packages/orq-rc/src/mcp-server/tools/deploymentsInvoke.ts +0 -37
  273. package/packages/orq-rc/src/mcp-server/tools/deploymentsList.ts +0 -37
  274. package/packages/orq-rc/src/mcp-server/tools/deploymentsMetricsCreate.ts +0 -37
  275. package/packages/orq-rc/src/mcp-server/tools/deploymentsStream.ts +0 -37
  276. package/packages/orq-rc/src/mcp-server/tools/feedbackCreate.ts +0 -37
  277. package/packages/orq-rc/src/mcp-server/tools/filesCreate.ts +0 -37
  278. package/packages/orq-rc/src/mcp-server/tools/filesDelete.ts +0 -33
  279. package/packages/orq-rc/src/mcp-server/tools/filesGet.ts +0 -37
  280. package/packages/orq-rc/src/mcp-server/tools/filesList.ts +0 -37
  281. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreate.ts +0 -35
  282. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateChunks.ts +0 -35
  283. package/packages/orq-rc/src/mcp-server/tools/knowledgeCreateDatasource.ts +0 -35
  284. package/packages/orq-rc/src/mcp-server/tools/knowledgeDelete.ts +0 -35
  285. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteChunk.ts +0 -33
  286. package/packages/orq-rc/src/mcp-server/tools/knowledgeDeleteDatasource.ts +0 -35
  287. package/packages/orq-rc/src/mcp-server/tools/knowledgeList.ts +0 -37
  288. package/packages/orq-rc/src/mcp-server/tools/knowledgeListChunks.ts +0 -35
  289. package/packages/orq-rc/src/mcp-server/tools/knowledgeListDatasources.ts +0 -35
  290. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieve.ts +0 -37
  291. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveChunk.ts +0 -35
  292. package/packages/orq-rc/src/mcp-server/tools/knowledgeRetrieveDatasource.ts +0 -35
  293. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdate.ts +0 -35
  294. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateChunk.ts +0 -35
  295. package/packages/orq-rc/src/mcp-server/tools/knowledgeUpdateDatasource.ts +0 -35
  296. package/packages/orq-rc/src/mcp-server/tools/modelsList.ts +0 -30
  297. package/packages/orq-rc/src/mcp-server/tools/promptsCreate.ts +0 -35
  298. package/packages/orq-rc/src/mcp-server/tools/promptsDelete.ts +0 -33
  299. package/packages/orq-rc/src/mcp-server/tools/promptsGetVersion.ts +0 -37
  300. package/packages/orq-rc/src/mcp-server/tools/promptsList.ts +0 -37
  301. package/packages/orq-rc/src/mcp-server/tools/promptsListVersions.ts +0 -37
  302. package/packages/orq-rc/src/mcp-server/tools/promptsRetrieve.ts +0 -37
  303. package/packages/orq-rc/src/mcp-server/tools/promptsUpdate.ts +0 -35
  304. package/packages/orq-rc/src/mcp-server/tools/remoteconfigsRetrieve.ts +0 -36
  305. package/packages/orq-rc/src/mcp-server/tools.ts +0 -129
  306. package/packages/orq-rc/src/models/components/deployments.ts +0 -7749
  307. package/packages/orq-rc/src/models/components/index.ts +0 -6
  308. package/packages/orq-rc/src/models/components/security.ts +0 -71
  309. package/packages/orq-rc/src/models/errors/apierror.ts +0 -27
  310. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -71
  311. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -82
  312. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  313. package/packages/orq-rc/src/models/errors/index.ts +0 -10
  314. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -97
  315. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -71
  316. package/packages/orq-rc/src/models/operations/bulkcreatedatapoints.ts +0 -1828
  317. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -75
  318. package/packages/orq-rc/src/models/operations/createchunk.ts +0 -432
  319. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -256
  320. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -296
  321. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -1752
  322. package/packages/orq-rc/src/models/operations/createdatasource.ts +0 -852
  323. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -286
  324. package/packages/orq-rc/src/models/operations/createknowledge.ts +0 -846
  325. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -3691
  326. package/packages/orq-rc/src/models/operations/deletechunk.ts +0 -96
  327. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -81
  328. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -75
  329. package/packages/orq-rc/src/models/operations/deletedatasource.ts +0 -87
  330. package/packages/orq-rc/src/models/operations/deleteknowledge.ts +0 -78
  331. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -69
  332. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -5435
  333. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -9694
  334. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -1255
  335. package/packages/orq-rc/src/models/operations/deployments.ts +0 -2128
  336. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -9946
  337. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -78
  338. package/packages/orq-rc/src/models/operations/fileget.ts +0 -223
  339. package/packages/orq-rc/src/models/operations/filelist.ts +0 -337
  340. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -327
  341. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -2100
  342. package/packages/orq-rc/src/models/operations/getonechunk.ts +0 -315
  343. package/packages/orq-rc/src/models/operations/getoneknowledge.ts +0 -537
  344. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -1966
  345. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -1962
  346. package/packages/orq-rc/src/models/operations/index.ts +0 -54
  347. package/packages/orq-rc/src/models/operations/listchunks.ts +0 -494
  348. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -1077
  349. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -406
  350. package/packages/orq-rc/src/models/operations/listdatasources.ts +0 -447
  351. package/packages/orq-rc/src/models/operations/listknowledgebases.ts +0 -663
  352. package/packages/orq-rc/src/models/operations/listmodels.ts +0 -273
  353. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -2096
  354. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -190
  355. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -930
  356. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -288
  357. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +0 -273
  358. package/packages/orq-rc/src/models/operations/updatechunk.ts +0 -448
  359. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -1741
  360. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -393
  361. package/packages/orq-rc/src/models/operations/updatedatasource.ts +0 -345
  362. package/packages/orq-rc/src/models/operations/updateknowledge.ts +0 -980
  363. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -3873
  364. package/packages/orq-rc/src/sdk/contacts.ts +0 -27
  365. package/packages/orq-rc/src/sdk/datasets.ts +0 -240
  366. package/packages/orq-rc/src/sdk/deployments.ts +0 -107
  367. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  368. package/packages/orq-rc/src/sdk/files.ts +0 -78
  369. package/packages/orq-rc/src/sdk/index.ts +0 -5
  370. package/packages/orq-rc/src/sdk/knowledge.ts +0 -264
  371. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  372. package/packages/orq-rc/src/sdk/models.ts +0 -25
  373. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  374. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  375. package/packages/orq-rc/src/sdk/sdk.ts +0 -61
  376. package/packages/orq-rc/src/types/async.ts +0 -68
  377. package/packages/orq-rc/src/types/blobs.ts +0 -31
  378. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  379. package/packages/orq-rc/src/types/enums.ts +0 -16
  380. package/packages/orq-rc/src/types/fp.ts +0 -50
  381. package/packages/orq-rc/src/types/index.ts +0 -11
  382. package/packages/orq-rc/src/types/operations.ts +0 -105
  383. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  384. package/packages/orq-rc/src/types/streams.ts +0 -21
  385. package/packages/orq-rc/tsconfig.json +0 -41
  386. /package/{packages/orq-rc/src → src}/funcs/datasetsCreateExperiment.ts +0 -0
  387. /package/{packages/orq-rc/src → src}/funcs/deploymentsCreateExperiment.ts +0 -0
  388. /package/{packages/orq-rc/src → src}/funcs/knowledgeSearch.ts +0 -0
  389. /package/{packages/orq-rc/src → src}/mcp-server/tools/datasetsCreateExperiment.ts +0 -0
  390. /package/{packages/orq-rc/src → src}/mcp-server/tools/deploymentsCreateExperiment.ts +0 -0
  391. /package/{packages/orq-rc/src → src}/mcp-server/tools/knowledgeSearch.ts +0 -0
  392. /package/{packages/orq-rc/src → src}/models/operations/createdatasetexperiment.ts +0 -0
  393. /package/{packages/orq-rc/src → src}/models/operations/createdeploymentexperiment.ts +0 -0
  394. /package/{packages/orq-rc/src → src}/models/operations/searchknowledge.ts +0 -0
@@ -1,2096 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod";
6
- import { remap as remap$ } from "../../lib/primitives.js";
7
- import { safeParse } from "../../lib/schemas.js";
8
- import { ClosedEnum } from "../../types/enums.js";
9
- import { Result as SafeParseResult } from "../../types/fp.js";
10
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
-
12
- export type ListPromptVersionsRequest = {
13
- promptId: string;
14
- /**
15
- * A limit on the number of objects to be returned. Limit can range between 1 and 50, and the default is 10
16
- */
17
- limit?: number | undefined;
18
- /**
19
- * A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 20 objects, ending with `01JJ1HDHN79XAS7A01WB3HYSDB`, your subsequent call can include `after=01JJ1HDHN79XAS7A01WB3HYSDB` in order to fetch the next page of the list.
20
- */
21
- startingAfter?: string | undefined;
22
- /**
23
- * A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 20 objects, starting with `01JJ1HDHN79XAS7A01WB3HYSDB`, your subsequent call can include `before=01JJ1HDHN79XAS7A01WB3HYSDB` in order to fetch the previous page of the list.
24
- */
25
- endingBefore?: string | undefined;
26
- };
27
-
28
- export const ListPromptVersionsObject = {
29
- List: "list",
30
- } as const;
31
- export type ListPromptVersionsObject = ClosedEnum<
32
- typeof ListPromptVersionsObject
33
- >;
34
-
35
- /**
36
- * The modality of the model
37
- */
38
- export const ListPromptVersionsModelType = {
39
- Chat: "chat",
40
- Completion: "completion",
41
- Embedding: "embedding",
42
- Vision: "vision",
43
- Image: "image",
44
- Tts: "tts",
45
- Stt: "stt",
46
- Rerank: "rerank",
47
- Moderations: "moderations",
48
- } as const;
49
- /**
50
- * The modality of the model
51
- */
52
- export type ListPromptVersionsModelType = ClosedEnum<
53
- typeof ListPromptVersionsModelType
54
- >;
55
-
56
- /**
57
- * Only supported on `image` models.
58
- */
59
- export const ListPromptVersionsFormat = {
60
- Url: "url",
61
- B64Json: "b64_json",
62
- Text: "text",
63
- JsonObject: "json_object",
64
- } as const;
65
- /**
66
- * Only supported on `image` models.
67
- */
68
- export type ListPromptVersionsFormat = ClosedEnum<
69
- typeof ListPromptVersionsFormat
70
- >;
71
-
72
- export const ListPromptVersionsResponseFormatPromptsType = {
73
- JsonObject: "json_object",
74
- } as const;
75
- export type ListPromptVersionsResponseFormatPromptsType = ClosedEnum<
76
- typeof ListPromptVersionsResponseFormatPromptsType
77
- >;
78
-
79
- export type ListPromptVersionsResponseFormat2 = {
80
- type: ListPromptVersionsResponseFormatPromptsType;
81
- };
82
-
83
- export const ListPromptVersionsResponseFormatType = {
84
- JsonSchema: "json_schema",
85
- } as const;
86
- export type ListPromptVersionsResponseFormatType = ClosedEnum<
87
- typeof ListPromptVersionsResponseFormatType
88
- >;
89
-
90
- export type ListPromptVersionsResponseFormatJsonSchema = {
91
- name: string;
92
- strict: boolean;
93
- schema: { [k: string]: any };
94
- };
95
-
96
- export type ListPromptVersionsResponseFormat1 = {
97
- type: ListPromptVersionsResponseFormatType;
98
- jsonSchema: ListPromptVersionsResponseFormatJsonSchema;
99
- };
100
-
101
- /**
102
- * An object specifying the format that the model must output.
103
- *
104
- * @remarks
105
- *
106
- * Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured Outputs which ensures the model will match your supplied JSON schema
107
- *
108
- * Setting to `{ "type": "json_object" }` enables JSON mode, which ensures the message the model generates is valid JSON.
109
- *
110
- * Important: when using JSON mode, you must also instruct the model to produce JSON yourself via a system or user message. Without this, the model may generate an unending stream of whitespace until the generation reaches the token limit, resulting in a long-running and seemingly "stuck" request. Also note that the message content may be partially cut off if finish_reason="length", which indicates the generation exceeded max_tokens or the conversation exceeded the max context length.
111
- */
112
- export type ListPromptVersionsResponseFormat =
113
- | ListPromptVersionsResponseFormat2
114
- | ListPromptVersionsResponseFormat1;
115
-
116
- /**
117
- * The version of photoReal to use. Must be v1 or v2. Only available for `leonardoai` provider
118
- */
119
- export const ListPromptVersionsPhotoRealVersion = {
120
- V1: "v1",
121
- V2: "v2",
122
- } as const;
123
- /**
124
- * The version of photoReal to use. Must be v1 or v2. Only available for `leonardoai` provider
125
- */
126
- export type ListPromptVersionsPhotoRealVersion = ClosedEnum<
127
- typeof ListPromptVersionsPhotoRealVersion
128
- >;
129
-
130
- /**
131
- * The format to return the embeddings
132
- */
133
- export const ListPromptVersionsEncodingFormat = {
134
- Float: "float",
135
- Base64: "base64",
136
- } as const;
137
- /**
138
- * The format to return the embeddings
139
- */
140
- export type ListPromptVersionsEncodingFormat = ClosedEnum<
141
- typeof ListPromptVersionsEncodingFormat
142
- >;
143
-
144
- /**
145
- * Constrains effort on reasoning for reasoning models. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response.
146
- */
147
- export const ListPromptVersionsReasoningEffort = {
148
- Low: "low",
149
- Medium: "medium",
150
- High: "high",
151
- } as const;
152
- /**
153
- * Constrains effort on reasoning for reasoning models. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response.
154
- */
155
- export type ListPromptVersionsReasoningEffort = ClosedEnum<
156
- typeof ListPromptVersionsReasoningEffort
157
- >;
158
-
159
- /**
160
- * Model Parameters: Not all parameters apply to every model
161
- */
162
- export type ListPromptVersionsModelParameters = {
163
- /**
164
- * Only supported on `chat` and `completion` models.
165
- */
166
- temperature?: number | undefined;
167
- /**
168
- * Only supported on `chat` and `completion` models.
169
- */
170
- maxTokens?: number | undefined;
171
- /**
172
- * Only supported on `chat` and `completion` models.
173
- */
174
- topK?: number | undefined;
175
- /**
176
- * Only supported on `chat` and `completion` models.
177
- */
178
- topP?: number | undefined;
179
- /**
180
- * Only supported on `chat` and `completion` models.
181
- */
182
- frequencyPenalty?: number | undefined;
183
- /**
184
- * Only supported on `chat` and `completion` models.
185
- */
186
- presencePenalty?: number | undefined;
187
- /**
188
- * Only supported on `image` models.
189
- */
190
- numImages?: number | undefined;
191
- /**
192
- * Best effort deterministic seed for the model. Currently only OpenAI models support these
193
- */
194
- seed?: number | undefined;
195
- /**
196
- * Only supported on `image` models.
197
- */
198
- format?: ListPromptVersionsFormat | undefined;
199
- /**
200
- * Only supported on `image` models.
201
- */
202
- dimensions?: string | undefined;
203
- /**
204
- * Only supported on `image` models.
205
- */
206
- quality?: string | undefined;
207
- /**
208
- * Only supported on `image` models.
209
- */
210
- style?: string | undefined;
211
- /**
212
- * An object specifying the format that the model must output.
213
- *
214
- * @remarks
215
- *
216
- * Setting to `{ "type": "json_schema", "json_schema": {...} }` enables Structured Outputs which ensures the model will match your supplied JSON schema
217
- *
218
- * Setting to `{ "type": "json_object" }` enables JSON mode, which ensures the message the model generates is valid JSON.
219
- *
220
- * Important: when using JSON mode, you must also instruct the model to produce JSON yourself via a system or user message. Without this, the model may generate an unending stream of whitespace until the generation reaches the token limit, resulting in a long-running and seemingly "stuck" request. Also note that the message content may be partially cut off if finish_reason="length", which indicates the generation exceeded max_tokens or the conversation exceeded the max context length.
221
- */
222
- responseFormat?:
223
- | ListPromptVersionsResponseFormat2
224
- | ListPromptVersionsResponseFormat1
225
- | null
226
- | undefined;
227
- /**
228
- * The version of photoReal to use. Must be v1 or v2. Only available for `leonardoai` provider
229
- */
230
- photoRealVersion?: ListPromptVersionsPhotoRealVersion | undefined;
231
- /**
232
- * The format to return the embeddings
233
- */
234
- encodingFormat?: ListPromptVersionsEncodingFormat | undefined;
235
- /**
236
- * Constrains effort on reasoning for reasoning models. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response.
237
- */
238
- reasoningEffort?: ListPromptVersionsReasoningEffort | undefined;
239
- /**
240
- * Gives the model enhanced reasoning capabilities for complex tasks. A value of 0 disables thinking. The minimum budget tokens for thinking are 1024. The Budget Tokens should never exceed the Max Tokens parameter. Only supported by `Anthropic`
241
- */
242
- budgetTokens?: number | undefined;
243
- };
244
-
245
- export const ListPromptVersionsProvider = {
246
- Cohere: "cohere",
247
- Openai: "openai",
248
- Anthropic: "anthropic",
249
- Huggingface: "huggingface",
250
- Replicate: "replicate",
251
- Google: "google",
252
- GoogleAi: "google-ai",
253
- Azure: "azure",
254
- Aws: "aws",
255
- Anyscale: "anyscale",
256
- Perplexity: "perplexity",
257
- Groq: "groq",
258
- Fal: "fal",
259
- Leonardoai: "leonardoai",
260
- Nvidia: "nvidia",
261
- Jina: "jina",
262
- Togetherai: "togetherai",
263
- Elevenlabs: "elevenlabs",
264
- } as const;
265
- export type ListPromptVersionsProvider = ClosedEnum<
266
- typeof ListPromptVersionsProvider
267
- >;
268
-
269
- /**
270
- * The role of the prompt message
271
- */
272
- export const ListPromptVersionsRole = {
273
- System: "system",
274
- Assistant: "assistant",
275
- User: "user",
276
- Exception: "exception",
277
- Tool: "tool",
278
- Prompt: "prompt",
279
- Correction: "correction",
280
- ExpectedOutput: "expected_output",
281
- } as const;
282
- /**
283
- * The role of the prompt message
284
- */
285
- export type ListPromptVersionsRole = ClosedEnum<typeof ListPromptVersionsRole>;
286
-
287
- export const ListPromptVersions2PromptsType = {
288
- ImageUrl: "image_url",
289
- } as const;
290
- export type ListPromptVersions2PromptsType = ClosedEnum<
291
- typeof ListPromptVersions2PromptsType
292
- >;
293
-
294
- export type ListPromptVersions2ImageUrl = {
295
- /**
296
- * The orq.ai id of the image
297
- */
298
- id?: string | undefined;
299
- /**
300
- * Either a URL of the image or the base64 encoded data URI.
301
- */
302
- url: string;
303
- /**
304
- * Specifies the detail level of the image. Currently only supported with OpenAI models
305
- */
306
- detail?: string | undefined;
307
- };
308
-
309
- /**
310
- * The image part of the prompt message. Only supported with vision models.
311
- */
312
- export type ListPromptVersions22 = {
313
- type: ListPromptVersions2PromptsType;
314
- imageUrl: ListPromptVersions2ImageUrl;
315
- };
316
-
317
- export const ListPromptVersions2Type = {
318
- Text: "text",
319
- } as const;
320
- export type ListPromptVersions2Type = ClosedEnum<
321
- typeof ListPromptVersions2Type
322
- >;
323
-
324
- /**
325
- * Text content part of a prompt message
326
- */
327
- export type ListPromptVersions21 = {
328
- type: ListPromptVersions2Type;
329
- text: string;
330
- };
331
-
332
- export type ListPromptVersionsContent2 =
333
- | ListPromptVersions21
334
- | ListPromptVersions22;
335
-
336
- /**
337
- * The contents of the user message. Either the text content of the message or an array of content parts with a defined type, each can be of type `text` or `image_url` when passing in images. You can pass multiple images by adding multiple `image_url` content parts.
338
- */
339
- export type ListPromptVersionsContent =
340
- | string
341
- | Array<ListPromptVersions21 | ListPromptVersions22>;
342
-
343
- export const ListPromptVersionsType = {
344
- Function: "function",
345
- } as const;
346
- export type ListPromptVersionsType = ClosedEnum<typeof ListPromptVersionsType>;
347
-
348
- export type ListPromptVersionsFunction = {
349
- name: string;
350
- /**
351
- * JSON string arguments for the functions
352
- */
353
- arguments: string;
354
- };
355
-
356
- export type ListPromptVersionsToolCalls = {
357
- id?: string | undefined;
358
- index?: number | undefined;
359
- type: ListPromptVersionsType;
360
- function: ListPromptVersionsFunction;
361
- };
362
-
363
- export type ListPromptVersionsMessages = {
364
- /**
365
- * The role of the prompt message
366
- */
367
- role: ListPromptVersionsRole;
368
- /**
369
- * The contents of the user message. Either the text content of the message or an array of content parts with a defined type, each can be of type `text` or `image_url` when passing in images. You can pass multiple images by adding multiple `image_url` content parts.
370
- */
371
- content: string | Array<ListPromptVersions21 | ListPromptVersions22>;
372
- toolCalls?: Array<ListPromptVersionsToolCalls> | undefined;
373
- toolCallId?: string | undefined;
374
- };
375
-
376
- /**
377
- * A list of messages compatible with the openAI schema
378
- */
379
- export type ListPromptVersionsPromptConfig = {
380
- stream?: boolean | undefined;
381
- model?: string | undefined;
382
- /**
383
- * The id of the resource
384
- */
385
- modelDbId?: string | undefined;
386
- /**
387
- * The modality of the model
388
- */
389
- modelType?: ListPromptVersionsModelType | undefined;
390
- /**
391
- * Model Parameters: Not all parameters apply to every model
392
- */
393
- modelParameters?: ListPromptVersionsModelParameters | undefined;
394
- provider?: ListPromptVersionsProvider | undefined;
395
- /**
396
- * The id of the resource
397
- */
398
- integrationId?: string | null | undefined;
399
- version?: string | undefined;
400
- messages: Array<ListPromptVersionsMessages>;
401
- };
402
-
403
- export const ListPromptVersionsUseCases = {
404
- AgentsSimulations: "Agents simulations",
405
- Agents: "Agents",
406
- APIInteraction: "API interaction",
407
- AutonomousAgents: "Autonomous Agents",
408
- Chatbots: "Chatbots",
409
- Classification: "Classification",
410
- CodeUnderstanding: "Code understanding",
411
- CodeWriting: "Code writing",
412
- Conversation: "Conversation",
413
- DocumentsQA: "Documents QA",
414
- Evaluation: "Evaluation",
415
- Extraction: "Extraction",
416
- MultiModal: "Multi-modal",
417
- SelfChecking: "Self-checking",
418
- SentimentAnalysis: "Sentiment analysis",
419
- Sql: "SQL",
420
- Summarization: "Summarization",
421
- Tagging: "Tagging",
422
- TranslationDocument: "Translation (document)",
423
- TranslationSentences: "Translation (sentences)",
424
- } as const;
425
- export type ListPromptVersionsUseCases = ClosedEnum<
426
- typeof ListPromptVersionsUseCases
427
- >;
428
-
429
- /**
430
- * The language that the prompt is written in. Use this field to categorize the prompt for your own purpose
431
- */
432
- export const ListPromptVersionsLanguage = {
433
- Chinese: "Chinese",
434
- Dutch: "Dutch",
435
- English: "English",
436
- French: "French",
437
- German: "German",
438
- Russian: "Russian",
439
- Spanish: "Spanish",
440
- } as const;
441
- /**
442
- * The language that the prompt is written in. Use this field to categorize the prompt for your own purpose
443
- */
444
- export type ListPromptVersionsLanguage = ClosedEnum<
445
- typeof ListPromptVersionsLanguage
446
- >;
447
-
448
- export type ListPromptVersionsMetadata = {
449
- /**
450
- * A list of use cases that the prompt is meant to be used for. Use this field to categorize the prompt for your own purpose
451
- */
452
- useCases?: Array<ListPromptVersionsUseCases> | undefined;
453
- /**
454
- * The language that the prompt is written in. Use this field to categorize the prompt for your own purpose
455
- */
456
- language?: ListPromptVersionsLanguage | null | undefined;
457
- };
458
-
459
- export type ListPromptVersionsData = {
460
- id: string;
461
- createdById?: string | null | undefined;
462
- updatedById?: string | null | undefined;
463
- /**
464
- * The prompt’s description, meant to be displayable in the UI. Use this field to optionally store a long form explanation of the prompt for your own purpose
465
- */
466
- description?: string | null | undefined;
467
- /**
468
- * A list of messages compatible with the openAI schema
469
- */
470
- promptConfig: ListPromptVersionsPromptConfig;
471
- metadata?: ListPromptVersionsMetadata | undefined;
472
- timestamp: string;
473
- };
474
-
475
- /**
476
- * Prompt versions retrieved.
477
- */
478
- export type ListPromptVersionsResponseBody = {
479
- object: ListPromptVersionsObject;
480
- data: Array<ListPromptVersionsData>;
481
- hasMore: boolean;
482
- };
483
-
484
- /** @internal */
485
- export const ListPromptVersionsRequest$inboundSchema: z.ZodType<
486
- ListPromptVersionsRequest,
487
- z.ZodTypeDef,
488
- unknown
489
- > = z.object({
490
- prompt_id: z.string(),
491
- limit: z.number().default(10),
492
- starting_after: z.string().optional(),
493
- ending_before: z.string().optional(),
494
- }).transform((v) => {
495
- return remap$(v, {
496
- "prompt_id": "promptId",
497
- "starting_after": "startingAfter",
498
- "ending_before": "endingBefore",
499
- });
500
- });
501
-
502
- /** @internal */
503
- export type ListPromptVersionsRequest$Outbound = {
504
- prompt_id: string;
505
- limit: number;
506
- starting_after?: string | undefined;
507
- ending_before?: string | undefined;
508
- };
509
-
510
- /** @internal */
511
- export const ListPromptVersionsRequest$outboundSchema: z.ZodType<
512
- ListPromptVersionsRequest$Outbound,
513
- z.ZodTypeDef,
514
- ListPromptVersionsRequest
515
- > = z.object({
516
- promptId: z.string(),
517
- limit: z.number().default(10),
518
- startingAfter: z.string().optional(),
519
- endingBefore: z.string().optional(),
520
- }).transform((v) => {
521
- return remap$(v, {
522
- promptId: "prompt_id",
523
- startingAfter: "starting_after",
524
- endingBefore: "ending_before",
525
- });
526
- });
527
-
528
- /**
529
- * @internal
530
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
531
- */
532
- export namespace ListPromptVersionsRequest$ {
533
- /** @deprecated use `ListPromptVersionsRequest$inboundSchema` instead. */
534
- export const inboundSchema = ListPromptVersionsRequest$inboundSchema;
535
- /** @deprecated use `ListPromptVersionsRequest$outboundSchema` instead. */
536
- export const outboundSchema = ListPromptVersionsRequest$outboundSchema;
537
- /** @deprecated use `ListPromptVersionsRequest$Outbound` instead. */
538
- export type Outbound = ListPromptVersionsRequest$Outbound;
539
- }
540
-
541
- export function listPromptVersionsRequestToJSON(
542
- listPromptVersionsRequest: ListPromptVersionsRequest,
543
- ): string {
544
- return JSON.stringify(
545
- ListPromptVersionsRequest$outboundSchema.parse(listPromptVersionsRequest),
546
- );
547
- }
548
-
549
- export function listPromptVersionsRequestFromJSON(
550
- jsonString: string,
551
- ): SafeParseResult<ListPromptVersionsRequest, SDKValidationError> {
552
- return safeParse(
553
- jsonString,
554
- (x) => ListPromptVersionsRequest$inboundSchema.parse(JSON.parse(x)),
555
- `Failed to parse 'ListPromptVersionsRequest' from JSON`,
556
- );
557
- }
558
-
559
- /** @internal */
560
- export const ListPromptVersionsObject$inboundSchema: z.ZodNativeEnum<
561
- typeof ListPromptVersionsObject
562
- > = z.nativeEnum(ListPromptVersionsObject);
563
-
564
- /** @internal */
565
- export const ListPromptVersionsObject$outboundSchema: z.ZodNativeEnum<
566
- typeof ListPromptVersionsObject
567
- > = ListPromptVersionsObject$inboundSchema;
568
-
569
- /**
570
- * @internal
571
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
572
- */
573
- export namespace ListPromptVersionsObject$ {
574
- /** @deprecated use `ListPromptVersionsObject$inboundSchema` instead. */
575
- export const inboundSchema = ListPromptVersionsObject$inboundSchema;
576
- /** @deprecated use `ListPromptVersionsObject$outboundSchema` instead. */
577
- export const outboundSchema = ListPromptVersionsObject$outboundSchema;
578
- }
579
-
580
- /** @internal */
581
- export const ListPromptVersionsModelType$inboundSchema: z.ZodNativeEnum<
582
- typeof ListPromptVersionsModelType
583
- > = z.nativeEnum(ListPromptVersionsModelType);
584
-
585
- /** @internal */
586
- export const ListPromptVersionsModelType$outboundSchema: z.ZodNativeEnum<
587
- typeof ListPromptVersionsModelType
588
- > = ListPromptVersionsModelType$inboundSchema;
589
-
590
- /**
591
- * @internal
592
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
593
- */
594
- export namespace ListPromptVersionsModelType$ {
595
- /** @deprecated use `ListPromptVersionsModelType$inboundSchema` instead. */
596
- export const inboundSchema = ListPromptVersionsModelType$inboundSchema;
597
- /** @deprecated use `ListPromptVersionsModelType$outboundSchema` instead. */
598
- export const outboundSchema = ListPromptVersionsModelType$outboundSchema;
599
- }
600
-
601
- /** @internal */
602
- export const ListPromptVersionsFormat$inboundSchema: z.ZodNativeEnum<
603
- typeof ListPromptVersionsFormat
604
- > = z.nativeEnum(ListPromptVersionsFormat);
605
-
606
- /** @internal */
607
- export const ListPromptVersionsFormat$outboundSchema: z.ZodNativeEnum<
608
- typeof ListPromptVersionsFormat
609
- > = ListPromptVersionsFormat$inboundSchema;
610
-
611
- /**
612
- * @internal
613
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
614
- */
615
- export namespace ListPromptVersionsFormat$ {
616
- /** @deprecated use `ListPromptVersionsFormat$inboundSchema` instead. */
617
- export const inboundSchema = ListPromptVersionsFormat$inboundSchema;
618
- /** @deprecated use `ListPromptVersionsFormat$outboundSchema` instead. */
619
- export const outboundSchema = ListPromptVersionsFormat$outboundSchema;
620
- }
621
-
622
- /** @internal */
623
- export const ListPromptVersionsResponseFormatPromptsType$inboundSchema:
624
- z.ZodNativeEnum<typeof ListPromptVersionsResponseFormatPromptsType> = z
625
- .nativeEnum(ListPromptVersionsResponseFormatPromptsType);
626
-
627
- /** @internal */
628
- export const ListPromptVersionsResponseFormatPromptsType$outboundSchema:
629
- z.ZodNativeEnum<typeof ListPromptVersionsResponseFormatPromptsType> =
630
- ListPromptVersionsResponseFormatPromptsType$inboundSchema;
631
-
632
- /**
633
- * @internal
634
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
635
- */
636
- export namespace ListPromptVersionsResponseFormatPromptsType$ {
637
- /** @deprecated use `ListPromptVersionsResponseFormatPromptsType$inboundSchema` instead. */
638
- export const inboundSchema =
639
- ListPromptVersionsResponseFormatPromptsType$inboundSchema;
640
- /** @deprecated use `ListPromptVersionsResponseFormatPromptsType$outboundSchema` instead. */
641
- export const outboundSchema =
642
- ListPromptVersionsResponseFormatPromptsType$outboundSchema;
643
- }
644
-
645
- /** @internal */
646
- export const ListPromptVersionsResponseFormat2$inboundSchema: z.ZodType<
647
- ListPromptVersionsResponseFormat2,
648
- z.ZodTypeDef,
649
- unknown
650
- > = z.object({
651
- type: ListPromptVersionsResponseFormatPromptsType$inboundSchema,
652
- });
653
-
654
- /** @internal */
655
- export type ListPromptVersionsResponseFormat2$Outbound = {
656
- type: string;
657
- };
658
-
659
- /** @internal */
660
- export const ListPromptVersionsResponseFormat2$outboundSchema: z.ZodType<
661
- ListPromptVersionsResponseFormat2$Outbound,
662
- z.ZodTypeDef,
663
- ListPromptVersionsResponseFormat2
664
- > = z.object({
665
- type: ListPromptVersionsResponseFormatPromptsType$outboundSchema,
666
- });
667
-
668
- /**
669
- * @internal
670
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
671
- */
672
- export namespace ListPromptVersionsResponseFormat2$ {
673
- /** @deprecated use `ListPromptVersionsResponseFormat2$inboundSchema` instead. */
674
- export const inboundSchema = ListPromptVersionsResponseFormat2$inboundSchema;
675
- /** @deprecated use `ListPromptVersionsResponseFormat2$outboundSchema` instead. */
676
- export const outboundSchema =
677
- ListPromptVersionsResponseFormat2$outboundSchema;
678
- /** @deprecated use `ListPromptVersionsResponseFormat2$Outbound` instead. */
679
- export type Outbound = ListPromptVersionsResponseFormat2$Outbound;
680
- }
681
-
682
- export function listPromptVersionsResponseFormat2ToJSON(
683
- listPromptVersionsResponseFormat2: ListPromptVersionsResponseFormat2,
684
- ): string {
685
- return JSON.stringify(
686
- ListPromptVersionsResponseFormat2$outboundSchema.parse(
687
- listPromptVersionsResponseFormat2,
688
- ),
689
- );
690
- }
691
-
692
- export function listPromptVersionsResponseFormat2FromJSON(
693
- jsonString: string,
694
- ): SafeParseResult<ListPromptVersionsResponseFormat2, SDKValidationError> {
695
- return safeParse(
696
- jsonString,
697
- (x) => ListPromptVersionsResponseFormat2$inboundSchema.parse(JSON.parse(x)),
698
- `Failed to parse 'ListPromptVersionsResponseFormat2' from JSON`,
699
- );
700
- }
701
-
702
- /** @internal */
703
- export const ListPromptVersionsResponseFormatType$inboundSchema:
704
- z.ZodNativeEnum<typeof ListPromptVersionsResponseFormatType> = z.nativeEnum(
705
- ListPromptVersionsResponseFormatType,
706
- );
707
-
708
- /** @internal */
709
- export const ListPromptVersionsResponseFormatType$outboundSchema:
710
- z.ZodNativeEnum<typeof ListPromptVersionsResponseFormatType> =
711
- ListPromptVersionsResponseFormatType$inboundSchema;
712
-
713
- /**
714
- * @internal
715
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
716
- */
717
- export namespace ListPromptVersionsResponseFormatType$ {
718
- /** @deprecated use `ListPromptVersionsResponseFormatType$inboundSchema` instead. */
719
- export const inboundSchema =
720
- ListPromptVersionsResponseFormatType$inboundSchema;
721
- /** @deprecated use `ListPromptVersionsResponseFormatType$outboundSchema` instead. */
722
- export const outboundSchema =
723
- ListPromptVersionsResponseFormatType$outboundSchema;
724
- }
725
-
726
- /** @internal */
727
- export const ListPromptVersionsResponseFormatJsonSchema$inboundSchema:
728
- z.ZodType<ListPromptVersionsResponseFormatJsonSchema, z.ZodTypeDef, unknown> =
729
- z.object({
730
- name: z.string(),
731
- strict: z.boolean(),
732
- schema: z.record(z.any()),
733
- });
734
-
735
- /** @internal */
736
- export type ListPromptVersionsResponseFormatJsonSchema$Outbound = {
737
- name: string;
738
- strict: boolean;
739
- schema: { [k: string]: any };
740
- };
741
-
742
- /** @internal */
743
- export const ListPromptVersionsResponseFormatJsonSchema$outboundSchema:
744
- z.ZodType<
745
- ListPromptVersionsResponseFormatJsonSchema$Outbound,
746
- z.ZodTypeDef,
747
- ListPromptVersionsResponseFormatJsonSchema
748
- > = z.object({
749
- name: z.string(),
750
- strict: z.boolean(),
751
- schema: z.record(z.any()),
752
- });
753
-
754
- /**
755
- * @internal
756
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
757
- */
758
- export namespace ListPromptVersionsResponseFormatJsonSchema$ {
759
- /** @deprecated use `ListPromptVersionsResponseFormatJsonSchema$inboundSchema` instead. */
760
- export const inboundSchema =
761
- ListPromptVersionsResponseFormatJsonSchema$inboundSchema;
762
- /** @deprecated use `ListPromptVersionsResponseFormatJsonSchema$outboundSchema` instead. */
763
- export const outboundSchema =
764
- ListPromptVersionsResponseFormatJsonSchema$outboundSchema;
765
- /** @deprecated use `ListPromptVersionsResponseFormatJsonSchema$Outbound` instead. */
766
- export type Outbound = ListPromptVersionsResponseFormatJsonSchema$Outbound;
767
- }
768
-
769
- export function listPromptVersionsResponseFormatJsonSchemaToJSON(
770
- listPromptVersionsResponseFormatJsonSchema:
771
- ListPromptVersionsResponseFormatJsonSchema,
772
- ): string {
773
- return JSON.stringify(
774
- ListPromptVersionsResponseFormatJsonSchema$outboundSchema.parse(
775
- listPromptVersionsResponseFormatJsonSchema,
776
- ),
777
- );
778
- }
779
-
780
- export function listPromptVersionsResponseFormatJsonSchemaFromJSON(
781
- jsonString: string,
782
- ): SafeParseResult<
783
- ListPromptVersionsResponseFormatJsonSchema,
784
- SDKValidationError
785
- > {
786
- return safeParse(
787
- jsonString,
788
- (x) =>
789
- ListPromptVersionsResponseFormatJsonSchema$inboundSchema.parse(
790
- JSON.parse(x),
791
- ),
792
- `Failed to parse 'ListPromptVersionsResponseFormatJsonSchema' from JSON`,
793
- );
794
- }
795
-
796
- /** @internal */
797
- export const ListPromptVersionsResponseFormat1$inboundSchema: z.ZodType<
798
- ListPromptVersionsResponseFormat1,
799
- z.ZodTypeDef,
800
- unknown
801
- > = z.object({
802
- type: ListPromptVersionsResponseFormatType$inboundSchema,
803
- json_schema: z.lazy(() =>
804
- ListPromptVersionsResponseFormatJsonSchema$inboundSchema
805
- ),
806
- }).transform((v) => {
807
- return remap$(v, {
808
- "json_schema": "jsonSchema",
809
- });
810
- });
811
-
812
- /** @internal */
813
- export type ListPromptVersionsResponseFormat1$Outbound = {
814
- type: string;
815
- json_schema: ListPromptVersionsResponseFormatJsonSchema$Outbound;
816
- };
817
-
818
- /** @internal */
819
- export const ListPromptVersionsResponseFormat1$outboundSchema: z.ZodType<
820
- ListPromptVersionsResponseFormat1$Outbound,
821
- z.ZodTypeDef,
822
- ListPromptVersionsResponseFormat1
823
- > = z.object({
824
- type: ListPromptVersionsResponseFormatType$outboundSchema,
825
- jsonSchema: z.lazy(() =>
826
- ListPromptVersionsResponseFormatJsonSchema$outboundSchema
827
- ),
828
- }).transform((v) => {
829
- return remap$(v, {
830
- jsonSchema: "json_schema",
831
- });
832
- });
833
-
834
- /**
835
- * @internal
836
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
837
- */
838
- export namespace ListPromptVersionsResponseFormat1$ {
839
- /** @deprecated use `ListPromptVersionsResponseFormat1$inboundSchema` instead. */
840
- export const inboundSchema = ListPromptVersionsResponseFormat1$inboundSchema;
841
- /** @deprecated use `ListPromptVersionsResponseFormat1$outboundSchema` instead. */
842
- export const outboundSchema =
843
- ListPromptVersionsResponseFormat1$outboundSchema;
844
- /** @deprecated use `ListPromptVersionsResponseFormat1$Outbound` instead. */
845
- export type Outbound = ListPromptVersionsResponseFormat1$Outbound;
846
- }
847
-
848
- export function listPromptVersionsResponseFormat1ToJSON(
849
- listPromptVersionsResponseFormat1: ListPromptVersionsResponseFormat1,
850
- ): string {
851
- return JSON.stringify(
852
- ListPromptVersionsResponseFormat1$outboundSchema.parse(
853
- listPromptVersionsResponseFormat1,
854
- ),
855
- );
856
- }
857
-
858
- export function listPromptVersionsResponseFormat1FromJSON(
859
- jsonString: string,
860
- ): SafeParseResult<ListPromptVersionsResponseFormat1, SDKValidationError> {
861
- return safeParse(
862
- jsonString,
863
- (x) => ListPromptVersionsResponseFormat1$inboundSchema.parse(JSON.parse(x)),
864
- `Failed to parse 'ListPromptVersionsResponseFormat1' from JSON`,
865
- );
866
- }
867
-
868
- /** @internal */
869
- export const ListPromptVersionsResponseFormat$inboundSchema: z.ZodType<
870
- ListPromptVersionsResponseFormat,
871
- z.ZodTypeDef,
872
- unknown
873
- > = z.union([
874
- z.lazy(() => ListPromptVersionsResponseFormat2$inboundSchema),
875
- z.lazy(() => ListPromptVersionsResponseFormat1$inboundSchema),
876
- ]);
877
-
878
- /** @internal */
879
- export type ListPromptVersionsResponseFormat$Outbound =
880
- | ListPromptVersionsResponseFormat2$Outbound
881
- | ListPromptVersionsResponseFormat1$Outbound;
882
-
883
- /** @internal */
884
- export const ListPromptVersionsResponseFormat$outboundSchema: z.ZodType<
885
- ListPromptVersionsResponseFormat$Outbound,
886
- z.ZodTypeDef,
887
- ListPromptVersionsResponseFormat
888
- > = z.union([
889
- z.lazy(() => ListPromptVersionsResponseFormat2$outboundSchema),
890
- z.lazy(() => ListPromptVersionsResponseFormat1$outboundSchema),
891
- ]);
892
-
893
- /**
894
- * @internal
895
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
896
- */
897
- export namespace ListPromptVersionsResponseFormat$ {
898
- /** @deprecated use `ListPromptVersionsResponseFormat$inboundSchema` instead. */
899
- export const inboundSchema = ListPromptVersionsResponseFormat$inboundSchema;
900
- /** @deprecated use `ListPromptVersionsResponseFormat$outboundSchema` instead. */
901
- export const outboundSchema = ListPromptVersionsResponseFormat$outboundSchema;
902
- /** @deprecated use `ListPromptVersionsResponseFormat$Outbound` instead. */
903
- export type Outbound = ListPromptVersionsResponseFormat$Outbound;
904
- }
905
-
906
- export function listPromptVersionsResponseFormatToJSON(
907
- listPromptVersionsResponseFormat: ListPromptVersionsResponseFormat,
908
- ): string {
909
- return JSON.stringify(
910
- ListPromptVersionsResponseFormat$outboundSchema.parse(
911
- listPromptVersionsResponseFormat,
912
- ),
913
- );
914
- }
915
-
916
- export function listPromptVersionsResponseFormatFromJSON(
917
- jsonString: string,
918
- ): SafeParseResult<ListPromptVersionsResponseFormat, SDKValidationError> {
919
- return safeParse(
920
- jsonString,
921
- (x) => ListPromptVersionsResponseFormat$inboundSchema.parse(JSON.parse(x)),
922
- `Failed to parse 'ListPromptVersionsResponseFormat' from JSON`,
923
- );
924
- }
925
-
926
- /** @internal */
927
- export const ListPromptVersionsPhotoRealVersion$inboundSchema: z.ZodNativeEnum<
928
- typeof ListPromptVersionsPhotoRealVersion
929
- > = z.nativeEnum(ListPromptVersionsPhotoRealVersion);
930
-
931
- /** @internal */
932
- export const ListPromptVersionsPhotoRealVersion$outboundSchema: z.ZodNativeEnum<
933
- typeof ListPromptVersionsPhotoRealVersion
934
- > = ListPromptVersionsPhotoRealVersion$inboundSchema;
935
-
936
- /**
937
- * @internal
938
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
939
- */
940
- export namespace ListPromptVersionsPhotoRealVersion$ {
941
- /** @deprecated use `ListPromptVersionsPhotoRealVersion$inboundSchema` instead. */
942
- export const inboundSchema = ListPromptVersionsPhotoRealVersion$inboundSchema;
943
- /** @deprecated use `ListPromptVersionsPhotoRealVersion$outboundSchema` instead. */
944
- export const outboundSchema =
945
- ListPromptVersionsPhotoRealVersion$outboundSchema;
946
- }
947
-
948
- /** @internal */
949
- export const ListPromptVersionsEncodingFormat$inboundSchema: z.ZodNativeEnum<
950
- typeof ListPromptVersionsEncodingFormat
951
- > = z.nativeEnum(ListPromptVersionsEncodingFormat);
952
-
953
- /** @internal */
954
- export const ListPromptVersionsEncodingFormat$outboundSchema: z.ZodNativeEnum<
955
- typeof ListPromptVersionsEncodingFormat
956
- > = ListPromptVersionsEncodingFormat$inboundSchema;
957
-
958
- /**
959
- * @internal
960
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
961
- */
962
- export namespace ListPromptVersionsEncodingFormat$ {
963
- /** @deprecated use `ListPromptVersionsEncodingFormat$inboundSchema` instead. */
964
- export const inboundSchema = ListPromptVersionsEncodingFormat$inboundSchema;
965
- /** @deprecated use `ListPromptVersionsEncodingFormat$outboundSchema` instead. */
966
- export const outboundSchema = ListPromptVersionsEncodingFormat$outboundSchema;
967
- }
968
-
969
- /** @internal */
970
- export const ListPromptVersionsReasoningEffort$inboundSchema: z.ZodNativeEnum<
971
- typeof ListPromptVersionsReasoningEffort
972
- > = z.nativeEnum(ListPromptVersionsReasoningEffort);
973
-
974
- /** @internal */
975
- export const ListPromptVersionsReasoningEffort$outboundSchema: z.ZodNativeEnum<
976
- typeof ListPromptVersionsReasoningEffort
977
- > = ListPromptVersionsReasoningEffort$inboundSchema;
978
-
979
- /**
980
- * @internal
981
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
982
- */
983
- export namespace ListPromptVersionsReasoningEffort$ {
984
- /** @deprecated use `ListPromptVersionsReasoningEffort$inboundSchema` instead. */
985
- export const inboundSchema = ListPromptVersionsReasoningEffort$inboundSchema;
986
- /** @deprecated use `ListPromptVersionsReasoningEffort$outboundSchema` instead. */
987
- export const outboundSchema =
988
- ListPromptVersionsReasoningEffort$outboundSchema;
989
- }
990
-
991
- /** @internal */
992
- export const ListPromptVersionsModelParameters$inboundSchema: z.ZodType<
993
- ListPromptVersionsModelParameters,
994
- z.ZodTypeDef,
995
- unknown
996
- > = z.object({
997
- temperature: z.number().optional(),
998
- maxTokens: z.number().optional(),
999
- topK: z.number().optional(),
1000
- topP: z.number().optional(),
1001
- frequencyPenalty: z.number().optional(),
1002
- presencePenalty: z.number().optional(),
1003
- numImages: z.number().optional(),
1004
- seed: z.number().optional(),
1005
- format: ListPromptVersionsFormat$inboundSchema.optional(),
1006
- dimensions: z.string().optional(),
1007
- quality: z.string().optional(),
1008
- style: z.string().optional(),
1009
- responseFormat: z.nullable(
1010
- z.union([
1011
- z.lazy(() => ListPromptVersionsResponseFormat2$inboundSchema),
1012
- z.lazy(() => ListPromptVersionsResponseFormat1$inboundSchema),
1013
- ]),
1014
- ).optional(),
1015
- photoRealVersion: ListPromptVersionsPhotoRealVersion$inboundSchema.optional(),
1016
- encoding_format: ListPromptVersionsEncodingFormat$inboundSchema.optional(),
1017
- reasoningEffort: ListPromptVersionsReasoningEffort$inboundSchema.optional(),
1018
- budgetTokens: z.number().optional(),
1019
- }).transform((v) => {
1020
- return remap$(v, {
1021
- "encoding_format": "encodingFormat",
1022
- });
1023
- });
1024
-
1025
- /** @internal */
1026
- export type ListPromptVersionsModelParameters$Outbound = {
1027
- temperature?: number | undefined;
1028
- maxTokens?: number | undefined;
1029
- topK?: number | undefined;
1030
- topP?: number | undefined;
1031
- frequencyPenalty?: number | undefined;
1032
- presencePenalty?: number | undefined;
1033
- numImages?: number | undefined;
1034
- seed?: number | undefined;
1035
- format?: string | undefined;
1036
- dimensions?: string | undefined;
1037
- quality?: string | undefined;
1038
- style?: string | undefined;
1039
- responseFormat?:
1040
- | ListPromptVersionsResponseFormat2$Outbound
1041
- | ListPromptVersionsResponseFormat1$Outbound
1042
- | null
1043
- | undefined;
1044
- photoRealVersion?: string | undefined;
1045
- encoding_format?: string | undefined;
1046
- reasoningEffort?: string | undefined;
1047
- budgetTokens?: number | undefined;
1048
- };
1049
-
1050
- /** @internal */
1051
- export const ListPromptVersionsModelParameters$outboundSchema: z.ZodType<
1052
- ListPromptVersionsModelParameters$Outbound,
1053
- z.ZodTypeDef,
1054
- ListPromptVersionsModelParameters
1055
- > = z.object({
1056
- temperature: z.number().optional(),
1057
- maxTokens: z.number().optional(),
1058
- topK: z.number().optional(),
1059
- topP: z.number().optional(),
1060
- frequencyPenalty: z.number().optional(),
1061
- presencePenalty: z.number().optional(),
1062
- numImages: z.number().optional(),
1063
- seed: z.number().optional(),
1064
- format: ListPromptVersionsFormat$outboundSchema.optional(),
1065
- dimensions: z.string().optional(),
1066
- quality: z.string().optional(),
1067
- style: z.string().optional(),
1068
- responseFormat: z.nullable(
1069
- z.union([
1070
- z.lazy(() => ListPromptVersionsResponseFormat2$outboundSchema),
1071
- z.lazy(() => ListPromptVersionsResponseFormat1$outboundSchema),
1072
- ]),
1073
- ).optional(),
1074
- photoRealVersion: ListPromptVersionsPhotoRealVersion$outboundSchema
1075
- .optional(),
1076
- encodingFormat: ListPromptVersionsEncodingFormat$outboundSchema.optional(),
1077
- reasoningEffort: ListPromptVersionsReasoningEffort$outboundSchema.optional(),
1078
- budgetTokens: z.number().optional(),
1079
- }).transform((v) => {
1080
- return remap$(v, {
1081
- encodingFormat: "encoding_format",
1082
- });
1083
- });
1084
-
1085
- /**
1086
- * @internal
1087
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1088
- */
1089
- export namespace ListPromptVersionsModelParameters$ {
1090
- /** @deprecated use `ListPromptVersionsModelParameters$inboundSchema` instead. */
1091
- export const inboundSchema = ListPromptVersionsModelParameters$inboundSchema;
1092
- /** @deprecated use `ListPromptVersionsModelParameters$outboundSchema` instead. */
1093
- export const outboundSchema =
1094
- ListPromptVersionsModelParameters$outboundSchema;
1095
- /** @deprecated use `ListPromptVersionsModelParameters$Outbound` instead. */
1096
- export type Outbound = ListPromptVersionsModelParameters$Outbound;
1097
- }
1098
-
1099
- export function listPromptVersionsModelParametersToJSON(
1100
- listPromptVersionsModelParameters: ListPromptVersionsModelParameters,
1101
- ): string {
1102
- return JSON.stringify(
1103
- ListPromptVersionsModelParameters$outboundSchema.parse(
1104
- listPromptVersionsModelParameters,
1105
- ),
1106
- );
1107
- }
1108
-
1109
- export function listPromptVersionsModelParametersFromJSON(
1110
- jsonString: string,
1111
- ): SafeParseResult<ListPromptVersionsModelParameters, SDKValidationError> {
1112
- return safeParse(
1113
- jsonString,
1114
- (x) => ListPromptVersionsModelParameters$inboundSchema.parse(JSON.parse(x)),
1115
- `Failed to parse 'ListPromptVersionsModelParameters' from JSON`,
1116
- );
1117
- }
1118
-
1119
- /** @internal */
1120
- export const ListPromptVersionsProvider$inboundSchema: z.ZodNativeEnum<
1121
- typeof ListPromptVersionsProvider
1122
- > = z.nativeEnum(ListPromptVersionsProvider);
1123
-
1124
- /** @internal */
1125
- export const ListPromptVersionsProvider$outboundSchema: z.ZodNativeEnum<
1126
- typeof ListPromptVersionsProvider
1127
- > = ListPromptVersionsProvider$inboundSchema;
1128
-
1129
- /**
1130
- * @internal
1131
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1132
- */
1133
- export namespace ListPromptVersionsProvider$ {
1134
- /** @deprecated use `ListPromptVersionsProvider$inboundSchema` instead. */
1135
- export const inboundSchema = ListPromptVersionsProvider$inboundSchema;
1136
- /** @deprecated use `ListPromptVersionsProvider$outboundSchema` instead. */
1137
- export const outboundSchema = ListPromptVersionsProvider$outboundSchema;
1138
- }
1139
-
1140
- /** @internal */
1141
- export const ListPromptVersionsRole$inboundSchema: z.ZodNativeEnum<
1142
- typeof ListPromptVersionsRole
1143
- > = z.nativeEnum(ListPromptVersionsRole);
1144
-
1145
- /** @internal */
1146
- export const ListPromptVersionsRole$outboundSchema: z.ZodNativeEnum<
1147
- typeof ListPromptVersionsRole
1148
- > = ListPromptVersionsRole$inboundSchema;
1149
-
1150
- /**
1151
- * @internal
1152
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1153
- */
1154
- export namespace ListPromptVersionsRole$ {
1155
- /** @deprecated use `ListPromptVersionsRole$inboundSchema` instead. */
1156
- export const inboundSchema = ListPromptVersionsRole$inboundSchema;
1157
- /** @deprecated use `ListPromptVersionsRole$outboundSchema` instead. */
1158
- export const outboundSchema = ListPromptVersionsRole$outboundSchema;
1159
- }
1160
-
1161
- /** @internal */
1162
- export const ListPromptVersions2PromptsType$inboundSchema: z.ZodNativeEnum<
1163
- typeof ListPromptVersions2PromptsType
1164
- > = z.nativeEnum(ListPromptVersions2PromptsType);
1165
-
1166
- /** @internal */
1167
- export const ListPromptVersions2PromptsType$outboundSchema: z.ZodNativeEnum<
1168
- typeof ListPromptVersions2PromptsType
1169
- > = ListPromptVersions2PromptsType$inboundSchema;
1170
-
1171
- /**
1172
- * @internal
1173
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1174
- */
1175
- export namespace ListPromptVersions2PromptsType$ {
1176
- /** @deprecated use `ListPromptVersions2PromptsType$inboundSchema` instead. */
1177
- export const inboundSchema = ListPromptVersions2PromptsType$inboundSchema;
1178
- /** @deprecated use `ListPromptVersions2PromptsType$outboundSchema` instead. */
1179
- export const outboundSchema = ListPromptVersions2PromptsType$outboundSchema;
1180
- }
1181
-
1182
- /** @internal */
1183
- export const ListPromptVersions2ImageUrl$inboundSchema: z.ZodType<
1184
- ListPromptVersions2ImageUrl,
1185
- z.ZodTypeDef,
1186
- unknown
1187
- > = z.object({
1188
- id: z.string().optional(),
1189
- url: z.string(),
1190
- detail: z.string().optional(),
1191
- });
1192
-
1193
- /** @internal */
1194
- export type ListPromptVersions2ImageUrl$Outbound = {
1195
- id?: string | undefined;
1196
- url: string;
1197
- detail?: string | undefined;
1198
- };
1199
-
1200
- /** @internal */
1201
- export const ListPromptVersions2ImageUrl$outboundSchema: z.ZodType<
1202
- ListPromptVersions2ImageUrl$Outbound,
1203
- z.ZodTypeDef,
1204
- ListPromptVersions2ImageUrl
1205
- > = z.object({
1206
- id: z.string().optional(),
1207
- url: z.string(),
1208
- detail: z.string().optional(),
1209
- });
1210
-
1211
- /**
1212
- * @internal
1213
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1214
- */
1215
- export namespace ListPromptVersions2ImageUrl$ {
1216
- /** @deprecated use `ListPromptVersions2ImageUrl$inboundSchema` instead. */
1217
- export const inboundSchema = ListPromptVersions2ImageUrl$inboundSchema;
1218
- /** @deprecated use `ListPromptVersions2ImageUrl$outboundSchema` instead. */
1219
- export const outboundSchema = ListPromptVersions2ImageUrl$outboundSchema;
1220
- /** @deprecated use `ListPromptVersions2ImageUrl$Outbound` instead. */
1221
- export type Outbound = ListPromptVersions2ImageUrl$Outbound;
1222
- }
1223
-
1224
- export function listPromptVersions2ImageUrlToJSON(
1225
- listPromptVersions2ImageUrl: ListPromptVersions2ImageUrl,
1226
- ): string {
1227
- return JSON.stringify(
1228
- ListPromptVersions2ImageUrl$outboundSchema.parse(
1229
- listPromptVersions2ImageUrl,
1230
- ),
1231
- );
1232
- }
1233
-
1234
- export function listPromptVersions2ImageUrlFromJSON(
1235
- jsonString: string,
1236
- ): SafeParseResult<ListPromptVersions2ImageUrl, SDKValidationError> {
1237
- return safeParse(
1238
- jsonString,
1239
- (x) => ListPromptVersions2ImageUrl$inboundSchema.parse(JSON.parse(x)),
1240
- `Failed to parse 'ListPromptVersions2ImageUrl' from JSON`,
1241
- );
1242
- }
1243
-
1244
- /** @internal */
1245
- export const ListPromptVersions22$inboundSchema: z.ZodType<
1246
- ListPromptVersions22,
1247
- z.ZodTypeDef,
1248
- unknown
1249
- > = z.object({
1250
- type: ListPromptVersions2PromptsType$inboundSchema,
1251
- image_url: z.lazy(() => ListPromptVersions2ImageUrl$inboundSchema),
1252
- }).transform((v) => {
1253
- return remap$(v, {
1254
- "image_url": "imageUrl",
1255
- });
1256
- });
1257
-
1258
- /** @internal */
1259
- export type ListPromptVersions22$Outbound = {
1260
- type: string;
1261
- image_url: ListPromptVersions2ImageUrl$Outbound;
1262
- };
1263
-
1264
- /** @internal */
1265
- export const ListPromptVersions22$outboundSchema: z.ZodType<
1266
- ListPromptVersions22$Outbound,
1267
- z.ZodTypeDef,
1268
- ListPromptVersions22
1269
- > = z.object({
1270
- type: ListPromptVersions2PromptsType$outboundSchema,
1271
- imageUrl: z.lazy(() => ListPromptVersions2ImageUrl$outboundSchema),
1272
- }).transform((v) => {
1273
- return remap$(v, {
1274
- imageUrl: "image_url",
1275
- });
1276
- });
1277
-
1278
- /**
1279
- * @internal
1280
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1281
- */
1282
- export namespace ListPromptVersions22$ {
1283
- /** @deprecated use `ListPromptVersions22$inboundSchema` instead. */
1284
- export const inboundSchema = ListPromptVersions22$inboundSchema;
1285
- /** @deprecated use `ListPromptVersions22$outboundSchema` instead. */
1286
- export const outboundSchema = ListPromptVersions22$outboundSchema;
1287
- /** @deprecated use `ListPromptVersions22$Outbound` instead. */
1288
- export type Outbound = ListPromptVersions22$Outbound;
1289
- }
1290
-
1291
- export function listPromptVersions22ToJSON(
1292
- listPromptVersions22: ListPromptVersions22,
1293
- ): string {
1294
- return JSON.stringify(
1295
- ListPromptVersions22$outboundSchema.parse(listPromptVersions22),
1296
- );
1297
- }
1298
-
1299
- export function listPromptVersions22FromJSON(
1300
- jsonString: string,
1301
- ): SafeParseResult<ListPromptVersions22, SDKValidationError> {
1302
- return safeParse(
1303
- jsonString,
1304
- (x) => ListPromptVersions22$inboundSchema.parse(JSON.parse(x)),
1305
- `Failed to parse 'ListPromptVersions22' from JSON`,
1306
- );
1307
- }
1308
-
1309
- /** @internal */
1310
- export const ListPromptVersions2Type$inboundSchema: z.ZodNativeEnum<
1311
- typeof ListPromptVersions2Type
1312
- > = z.nativeEnum(ListPromptVersions2Type);
1313
-
1314
- /** @internal */
1315
- export const ListPromptVersions2Type$outboundSchema: z.ZodNativeEnum<
1316
- typeof ListPromptVersions2Type
1317
- > = ListPromptVersions2Type$inboundSchema;
1318
-
1319
- /**
1320
- * @internal
1321
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1322
- */
1323
- export namespace ListPromptVersions2Type$ {
1324
- /** @deprecated use `ListPromptVersions2Type$inboundSchema` instead. */
1325
- export const inboundSchema = ListPromptVersions2Type$inboundSchema;
1326
- /** @deprecated use `ListPromptVersions2Type$outboundSchema` instead. */
1327
- export const outboundSchema = ListPromptVersions2Type$outboundSchema;
1328
- }
1329
-
1330
- /** @internal */
1331
- export const ListPromptVersions21$inboundSchema: z.ZodType<
1332
- ListPromptVersions21,
1333
- z.ZodTypeDef,
1334
- unknown
1335
- > = z.object({
1336
- type: ListPromptVersions2Type$inboundSchema,
1337
- text: z.string(),
1338
- });
1339
-
1340
- /** @internal */
1341
- export type ListPromptVersions21$Outbound = {
1342
- type: string;
1343
- text: string;
1344
- };
1345
-
1346
- /** @internal */
1347
- export const ListPromptVersions21$outboundSchema: z.ZodType<
1348
- ListPromptVersions21$Outbound,
1349
- z.ZodTypeDef,
1350
- ListPromptVersions21
1351
- > = z.object({
1352
- type: ListPromptVersions2Type$outboundSchema,
1353
- text: z.string(),
1354
- });
1355
-
1356
- /**
1357
- * @internal
1358
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1359
- */
1360
- export namespace ListPromptVersions21$ {
1361
- /** @deprecated use `ListPromptVersions21$inboundSchema` instead. */
1362
- export const inboundSchema = ListPromptVersions21$inboundSchema;
1363
- /** @deprecated use `ListPromptVersions21$outboundSchema` instead. */
1364
- export const outboundSchema = ListPromptVersions21$outboundSchema;
1365
- /** @deprecated use `ListPromptVersions21$Outbound` instead. */
1366
- export type Outbound = ListPromptVersions21$Outbound;
1367
- }
1368
-
1369
- export function listPromptVersions21ToJSON(
1370
- listPromptVersions21: ListPromptVersions21,
1371
- ): string {
1372
- return JSON.stringify(
1373
- ListPromptVersions21$outboundSchema.parse(listPromptVersions21),
1374
- );
1375
- }
1376
-
1377
- export function listPromptVersions21FromJSON(
1378
- jsonString: string,
1379
- ): SafeParseResult<ListPromptVersions21, SDKValidationError> {
1380
- return safeParse(
1381
- jsonString,
1382
- (x) => ListPromptVersions21$inboundSchema.parse(JSON.parse(x)),
1383
- `Failed to parse 'ListPromptVersions21' from JSON`,
1384
- );
1385
- }
1386
-
1387
- /** @internal */
1388
- export const ListPromptVersionsContent2$inboundSchema: z.ZodType<
1389
- ListPromptVersionsContent2,
1390
- z.ZodTypeDef,
1391
- unknown
1392
- > = z.union([
1393
- z.lazy(() => ListPromptVersions21$inboundSchema),
1394
- z.lazy(() => ListPromptVersions22$inboundSchema),
1395
- ]);
1396
-
1397
- /** @internal */
1398
- export type ListPromptVersionsContent2$Outbound =
1399
- | ListPromptVersions21$Outbound
1400
- | ListPromptVersions22$Outbound;
1401
-
1402
- /** @internal */
1403
- export const ListPromptVersionsContent2$outboundSchema: z.ZodType<
1404
- ListPromptVersionsContent2$Outbound,
1405
- z.ZodTypeDef,
1406
- ListPromptVersionsContent2
1407
- > = z.union([
1408
- z.lazy(() => ListPromptVersions21$outboundSchema),
1409
- z.lazy(() => ListPromptVersions22$outboundSchema),
1410
- ]);
1411
-
1412
- /**
1413
- * @internal
1414
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1415
- */
1416
- export namespace ListPromptVersionsContent2$ {
1417
- /** @deprecated use `ListPromptVersionsContent2$inboundSchema` instead. */
1418
- export const inboundSchema = ListPromptVersionsContent2$inboundSchema;
1419
- /** @deprecated use `ListPromptVersionsContent2$outboundSchema` instead. */
1420
- export const outboundSchema = ListPromptVersionsContent2$outboundSchema;
1421
- /** @deprecated use `ListPromptVersionsContent2$Outbound` instead. */
1422
- export type Outbound = ListPromptVersionsContent2$Outbound;
1423
- }
1424
-
1425
- export function listPromptVersionsContent2ToJSON(
1426
- listPromptVersionsContent2: ListPromptVersionsContent2,
1427
- ): string {
1428
- return JSON.stringify(
1429
- ListPromptVersionsContent2$outboundSchema.parse(listPromptVersionsContent2),
1430
- );
1431
- }
1432
-
1433
- export function listPromptVersionsContent2FromJSON(
1434
- jsonString: string,
1435
- ): SafeParseResult<ListPromptVersionsContent2, SDKValidationError> {
1436
- return safeParse(
1437
- jsonString,
1438
- (x) => ListPromptVersionsContent2$inboundSchema.parse(JSON.parse(x)),
1439
- `Failed to parse 'ListPromptVersionsContent2' from JSON`,
1440
- );
1441
- }
1442
-
1443
- /** @internal */
1444
- export const ListPromptVersionsContent$inboundSchema: z.ZodType<
1445
- ListPromptVersionsContent,
1446
- z.ZodTypeDef,
1447
- unknown
1448
- > = z.union([
1449
- z.string(),
1450
- z.array(z.union([
1451
- z.lazy(() => ListPromptVersions21$inboundSchema),
1452
- z.lazy(() => ListPromptVersions22$inboundSchema),
1453
- ])),
1454
- ]);
1455
-
1456
- /** @internal */
1457
- export type ListPromptVersionsContent$Outbound =
1458
- | string
1459
- | Array<ListPromptVersions21$Outbound | ListPromptVersions22$Outbound>;
1460
-
1461
- /** @internal */
1462
- export const ListPromptVersionsContent$outboundSchema: z.ZodType<
1463
- ListPromptVersionsContent$Outbound,
1464
- z.ZodTypeDef,
1465
- ListPromptVersionsContent
1466
- > = z.union([
1467
- z.string(),
1468
- z.array(z.union([
1469
- z.lazy(() => ListPromptVersions21$outboundSchema),
1470
- z.lazy(() => ListPromptVersions22$outboundSchema),
1471
- ])),
1472
- ]);
1473
-
1474
- /**
1475
- * @internal
1476
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1477
- */
1478
- export namespace ListPromptVersionsContent$ {
1479
- /** @deprecated use `ListPromptVersionsContent$inboundSchema` instead. */
1480
- export const inboundSchema = ListPromptVersionsContent$inboundSchema;
1481
- /** @deprecated use `ListPromptVersionsContent$outboundSchema` instead. */
1482
- export const outboundSchema = ListPromptVersionsContent$outboundSchema;
1483
- /** @deprecated use `ListPromptVersionsContent$Outbound` instead. */
1484
- export type Outbound = ListPromptVersionsContent$Outbound;
1485
- }
1486
-
1487
- export function listPromptVersionsContentToJSON(
1488
- listPromptVersionsContent: ListPromptVersionsContent,
1489
- ): string {
1490
- return JSON.stringify(
1491
- ListPromptVersionsContent$outboundSchema.parse(listPromptVersionsContent),
1492
- );
1493
- }
1494
-
1495
- export function listPromptVersionsContentFromJSON(
1496
- jsonString: string,
1497
- ): SafeParseResult<ListPromptVersionsContent, SDKValidationError> {
1498
- return safeParse(
1499
- jsonString,
1500
- (x) => ListPromptVersionsContent$inboundSchema.parse(JSON.parse(x)),
1501
- `Failed to parse 'ListPromptVersionsContent' from JSON`,
1502
- );
1503
- }
1504
-
1505
- /** @internal */
1506
- export const ListPromptVersionsType$inboundSchema: z.ZodNativeEnum<
1507
- typeof ListPromptVersionsType
1508
- > = z.nativeEnum(ListPromptVersionsType);
1509
-
1510
- /** @internal */
1511
- export const ListPromptVersionsType$outboundSchema: z.ZodNativeEnum<
1512
- typeof ListPromptVersionsType
1513
- > = ListPromptVersionsType$inboundSchema;
1514
-
1515
- /**
1516
- * @internal
1517
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1518
- */
1519
- export namespace ListPromptVersionsType$ {
1520
- /** @deprecated use `ListPromptVersionsType$inboundSchema` instead. */
1521
- export const inboundSchema = ListPromptVersionsType$inboundSchema;
1522
- /** @deprecated use `ListPromptVersionsType$outboundSchema` instead. */
1523
- export const outboundSchema = ListPromptVersionsType$outboundSchema;
1524
- }
1525
-
1526
- /** @internal */
1527
- export const ListPromptVersionsFunction$inboundSchema: z.ZodType<
1528
- ListPromptVersionsFunction,
1529
- z.ZodTypeDef,
1530
- unknown
1531
- > = z.object({
1532
- name: z.string(),
1533
- arguments: z.string(),
1534
- });
1535
-
1536
- /** @internal */
1537
- export type ListPromptVersionsFunction$Outbound = {
1538
- name: string;
1539
- arguments: string;
1540
- };
1541
-
1542
- /** @internal */
1543
- export const ListPromptVersionsFunction$outboundSchema: z.ZodType<
1544
- ListPromptVersionsFunction$Outbound,
1545
- z.ZodTypeDef,
1546
- ListPromptVersionsFunction
1547
- > = z.object({
1548
- name: z.string(),
1549
- arguments: z.string(),
1550
- });
1551
-
1552
- /**
1553
- * @internal
1554
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1555
- */
1556
- export namespace ListPromptVersionsFunction$ {
1557
- /** @deprecated use `ListPromptVersionsFunction$inboundSchema` instead. */
1558
- export const inboundSchema = ListPromptVersionsFunction$inboundSchema;
1559
- /** @deprecated use `ListPromptVersionsFunction$outboundSchema` instead. */
1560
- export const outboundSchema = ListPromptVersionsFunction$outboundSchema;
1561
- /** @deprecated use `ListPromptVersionsFunction$Outbound` instead. */
1562
- export type Outbound = ListPromptVersionsFunction$Outbound;
1563
- }
1564
-
1565
- export function listPromptVersionsFunctionToJSON(
1566
- listPromptVersionsFunction: ListPromptVersionsFunction,
1567
- ): string {
1568
- return JSON.stringify(
1569
- ListPromptVersionsFunction$outboundSchema.parse(listPromptVersionsFunction),
1570
- );
1571
- }
1572
-
1573
- export function listPromptVersionsFunctionFromJSON(
1574
- jsonString: string,
1575
- ): SafeParseResult<ListPromptVersionsFunction, SDKValidationError> {
1576
- return safeParse(
1577
- jsonString,
1578
- (x) => ListPromptVersionsFunction$inboundSchema.parse(JSON.parse(x)),
1579
- `Failed to parse 'ListPromptVersionsFunction' from JSON`,
1580
- );
1581
- }
1582
-
1583
- /** @internal */
1584
- export const ListPromptVersionsToolCalls$inboundSchema: z.ZodType<
1585
- ListPromptVersionsToolCalls,
1586
- z.ZodTypeDef,
1587
- unknown
1588
- > = z.object({
1589
- id: z.string().optional(),
1590
- index: z.number().optional(),
1591
- type: ListPromptVersionsType$inboundSchema,
1592
- function: z.lazy(() => ListPromptVersionsFunction$inboundSchema),
1593
- });
1594
-
1595
- /** @internal */
1596
- export type ListPromptVersionsToolCalls$Outbound = {
1597
- id?: string | undefined;
1598
- index?: number | undefined;
1599
- type: string;
1600
- function: ListPromptVersionsFunction$Outbound;
1601
- };
1602
-
1603
- /** @internal */
1604
- export const ListPromptVersionsToolCalls$outboundSchema: z.ZodType<
1605
- ListPromptVersionsToolCalls$Outbound,
1606
- z.ZodTypeDef,
1607
- ListPromptVersionsToolCalls
1608
- > = z.object({
1609
- id: z.string().optional(),
1610
- index: z.number().optional(),
1611
- type: ListPromptVersionsType$outboundSchema,
1612
- function: z.lazy(() => ListPromptVersionsFunction$outboundSchema),
1613
- });
1614
-
1615
- /**
1616
- * @internal
1617
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1618
- */
1619
- export namespace ListPromptVersionsToolCalls$ {
1620
- /** @deprecated use `ListPromptVersionsToolCalls$inboundSchema` instead. */
1621
- export const inboundSchema = ListPromptVersionsToolCalls$inboundSchema;
1622
- /** @deprecated use `ListPromptVersionsToolCalls$outboundSchema` instead. */
1623
- export const outboundSchema = ListPromptVersionsToolCalls$outboundSchema;
1624
- /** @deprecated use `ListPromptVersionsToolCalls$Outbound` instead. */
1625
- export type Outbound = ListPromptVersionsToolCalls$Outbound;
1626
- }
1627
-
1628
- export function listPromptVersionsToolCallsToJSON(
1629
- listPromptVersionsToolCalls: ListPromptVersionsToolCalls,
1630
- ): string {
1631
- return JSON.stringify(
1632
- ListPromptVersionsToolCalls$outboundSchema.parse(
1633
- listPromptVersionsToolCalls,
1634
- ),
1635
- );
1636
- }
1637
-
1638
- export function listPromptVersionsToolCallsFromJSON(
1639
- jsonString: string,
1640
- ): SafeParseResult<ListPromptVersionsToolCalls, SDKValidationError> {
1641
- return safeParse(
1642
- jsonString,
1643
- (x) => ListPromptVersionsToolCalls$inboundSchema.parse(JSON.parse(x)),
1644
- `Failed to parse 'ListPromptVersionsToolCalls' from JSON`,
1645
- );
1646
- }
1647
-
1648
- /** @internal */
1649
- export const ListPromptVersionsMessages$inboundSchema: z.ZodType<
1650
- ListPromptVersionsMessages,
1651
- z.ZodTypeDef,
1652
- unknown
1653
- > = z.object({
1654
- role: ListPromptVersionsRole$inboundSchema,
1655
- content: z.union([
1656
- z.string(),
1657
- z.array(z.union([
1658
- z.lazy(() => ListPromptVersions21$inboundSchema),
1659
- z.lazy(() => ListPromptVersions22$inboundSchema),
1660
- ])),
1661
- ]),
1662
- tool_calls: z.array(z.lazy(() => ListPromptVersionsToolCalls$inboundSchema))
1663
- .optional(),
1664
- tool_call_id: z.string().optional(),
1665
- }).transform((v) => {
1666
- return remap$(v, {
1667
- "tool_calls": "toolCalls",
1668
- "tool_call_id": "toolCallId",
1669
- });
1670
- });
1671
-
1672
- /** @internal */
1673
- export type ListPromptVersionsMessages$Outbound = {
1674
- role: string;
1675
- content:
1676
- | string
1677
- | Array<ListPromptVersions21$Outbound | ListPromptVersions22$Outbound>;
1678
- tool_calls?: Array<ListPromptVersionsToolCalls$Outbound> | undefined;
1679
- tool_call_id?: string | undefined;
1680
- };
1681
-
1682
- /** @internal */
1683
- export const ListPromptVersionsMessages$outboundSchema: z.ZodType<
1684
- ListPromptVersionsMessages$Outbound,
1685
- z.ZodTypeDef,
1686
- ListPromptVersionsMessages
1687
- > = z.object({
1688
- role: ListPromptVersionsRole$outboundSchema,
1689
- content: z.union([
1690
- z.string(),
1691
- z.array(z.union([
1692
- z.lazy(() => ListPromptVersions21$outboundSchema),
1693
- z.lazy(() => ListPromptVersions22$outboundSchema),
1694
- ])),
1695
- ]),
1696
- toolCalls: z.array(z.lazy(() => ListPromptVersionsToolCalls$outboundSchema))
1697
- .optional(),
1698
- toolCallId: z.string().optional(),
1699
- }).transform((v) => {
1700
- return remap$(v, {
1701
- toolCalls: "tool_calls",
1702
- toolCallId: "tool_call_id",
1703
- });
1704
- });
1705
-
1706
- /**
1707
- * @internal
1708
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1709
- */
1710
- export namespace ListPromptVersionsMessages$ {
1711
- /** @deprecated use `ListPromptVersionsMessages$inboundSchema` instead. */
1712
- export const inboundSchema = ListPromptVersionsMessages$inboundSchema;
1713
- /** @deprecated use `ListPromptVersionsMessages$outboundSchema` instead. */
1714
- export const outboundSchema = ListPromptVersionsMessages$outboundSchema;
1715
- /** @deprecated use `ListPromptVersionsMessages$Outbound` instead. */
1716
- export type Outbound = ListPromptVersionsMessages$Outbound;
1717
- }
1718
-
1719
- export function listPromptVersionsMessagesToJSON(
1720
- listPromptVersionsMessages: ListPromptVersionsMessages,
1721
- ): string {
1722
- return JSON.stringify(
1723
- ListPromptVersionsMessages$outboundSchema.parse(listPromptVersionsMessages),
1724
- );
1725
- }
1726
-
1727
- export function listPromptVersionsMessagesFromJSON(
1728
- jsonString: string,
1729
- ): SafeParseResult<ListPromptVersionsMessages, SDKValidationError> {
1730
- return safeParse(
1731
- jsonString,
1732
- (x) => ListPromptVersionsMessages$inboundSchema.parse(JSON.parse(x)),
1733
- `Failed to parse 'ListPromptVersionsMessages' from JSON`,
1734
- );
1735
- }
1736
-
1737
- /** @internal */
1738
- export const ListPromptVersionsPromptConfig$inboundSchema: z.ZodType<
1739
- ListPromptVersionsPromptConfig,
1740
- z.ZodTypeDef,
1741
- unknown
1742
- > = z.object({
1743
- stream: z.boolean().optional(),
1744
- model: z.string().optional(),
1745
- model_db_id: z.string().optional(),
1746
- model_type: ListPromptVersionsModelType$inboundSchema.optional(),
1747
- model_parameters: z.lazy(() =>
1748
- ListPromptVersionsModelParameters$inboundSchema
1749
- ).optional(),
1750
- provider: ListPromptVersionsProvider$inboundSchema.optional(),
1751
- integration_id: z.nullable(z.string()).optional(),
1752
- version: z.string().optional(),
1753
- messages: z.array(z.lazy(() => ListPromptVersionsMessages$inboundSchema)),
1754
- }).transform((v) => {
1755
- return remap$(v, {
1756
- "model_db_id": "modelDbId",
1757
- "model_type": "modelType",
1758
- "model_parameters": "modelParameters",
1759
- "integration_id": "integrationId",
1760
- });
1761
- });
1762
-
1763
- /** @internal */
1764
- export type ListPromptVersionsPromptConfig$Outbound = {
1765
- stream?: boolean | undefined;
1766
- model?: string | undefined;
1767
- model_db_id?: string | undefined;
1768
- model_type?: string | undefined;
1769
- model_parameters?: ListPromptVersionsModelParameters$Outbound | undefined;
1770
- provider?: string | undefined;
1771
- integration_id?: string | null | undefined;
1772
- version?: string | undefined;
1773
- messages: Array<ListPromptVersionsMessages$Outbound>;
1774
- };
1775
-
1776
- /** @internal */
1777
- export const ListPromptVersionsPromptConfig$outboundSchema: z.ZodType<
1778
- ListPromptVersionsPromptConfig$Outbound,
1779
- z.ZodTypeDef,
1780
- ListPromptVersionsPromptConfig
1781
- > = z.object({
1782
- stream: z.boolean().optional(),
1783
- model: z.string().optional(),
1784
- modelDbId: z.string().optional(),
1785
- modelType: ListPromptVersionsModelType$outboundSchema.optional(),
1786
- modelParameters: z.lazy(() =>
1787
- ListPromptVersionsModelParameters$outboundSchema
1788
- ).optional(),
1789
- provider: ListPromptVersionsProvider$outboundSchema.optional(),
1790
- integrationId: z.nullable(z.string()).optional(),
1791
- version: z.string().optional(),
1792
- messages: z.array(z.lazy(() => ListPromptVersionsMessages$outboundSchema)),
1793
- }).transform((v) => {
1794
- return remap$(v, {
1795
- modelDbId: "model_db_id",
1796
- modelType: "model_type",
1797
- modelParameters: "model_parameters",
1798
- integrationId: "integration_id",
1799
- });
1800
- });
1801
-
1802
- /**
1803
- * @internal
1804
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1805
- */
1806
- export namespace ListPromptVersionsPromptConfig$ {
1807
- /** @deprecated use `ListPromptVersionsPromptConfig$inboundSchema` instead. */
1808
- export const inboundSchema = ListPromptVersionsPromptConfig$inboundSchema;
1809
- /** @deprecated use `ListPromptVersionsPromptConfig$outboundSchema` instead. */
1810
- export const outboundSchema = ListPromptVersionsPromptConfig$outboundSchema;
1811
- /** @deprecated use `ListPromptVersionsPromptConfig$Outbound` instead. */
1812
- export type Outbound = ListPromptVersionsPromptConfig$Outbound;
1813
- }
1814
-
1815
- export function listPromptVersionsPromptConfigToJSON(
1816
- listPromptVersionsPromptConfig: ListPromptVersionsPromptConfig,
1817
- ): string {
1818
- return JSON.stringify(
1819
- ListPromptVersionsPromptConfig$outboundSchema.parse(
1820
- listPromptVersionsPromptConfig,
1821
- ),
1822
- );
1823
- }
1824
-
1825
- export function listPromptVersionsPromptConfigFromJSON(
1826
- jsonString: string,
1827
- ): SafeParseResult<ListPromptVersionsPromptConfig, SDKValidationError> {
1828
- return safeParse(
1829
- jsonString,
1830
- (x) => ListPromptVersionsPromptConfig$inboundSchema.parse(JSON.parse(x)),
1831
- `Failed to parse 'ListPromptVersionsPromptConfig' from JSON`,
1832
- );
1833
- }
1834
-
1835
- /** @internal */
1836
- export const ListPromptVersionsUseCases$inboundSchema: z.ZodNativeEnum<
1837
- typeof ListPromptVersionsUseCases
1838
- > = z.nativeEnum(ListPromptVersionsUseCases);
1839
-
1840
- /** @internal */
1841
- export const ListPromptVersionsUseCases$outboundSchema: z.ZodNativeEnum<
1842
- typeof ListPromptVersionsUseCases
1843
- > = ListPromptVersionsUseCases$inboundSchema;
1844
-
1845
- /**
1846
- * @internal
1847
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1848
- */
1849
- export namespace ListPromptVersionsUseCases$ {
1850
- /** @deprecated use `ListPromptVersionsUseCases$inboundSchema` instead. */
1851
- export const inboundSchema = ListPromptVersionsUseCases$inboundSchema;
1852
- /** @deprecated use `ListPromptVersionsUseCases$outboundSchema` instead. */
1853
- export const outboundSchema = ListPromptVersionsUseCases$outboundSchema;
1854
- }
1855
-
1856
- /** @internal */
1857
- export const ListPromptVersionsLanguage$inboundSchema: z.ZodNativeEnum<
1858
- typeof ListPromptVersionsLanguage
1859
- > = z.nativeEnum(ListPromptVersionsLanguage);
1860
-
1861
- /** @internal */
1862
- export const ListPromptVersionsLanguage$outboundSchema: z.ZodNativeEnum<
1863
- typeof ListPromptVersionsLanguage
1864
- > = ListPromptVersionsLanguage$inboundSchema;
1865
-
1866
- /**
1867
- * @internal
1868
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1869
- */
1870
- export namespace ListPromptVersionsLanguage$ {
1871
- /** @deprecated use `ListPromptVersionsLanguage$inboundSchema` instead. */
1872
- export const inboundSchema = ListPromptVersionsLanguage$inboundSchema;
1873
- /** @deprecated use `ListPromptVersionsLanguage$outboundSchema` instead. */
1874
- export const outboundSchema = ListPromptVersionsLanguage$outboundSchema;
1875
- }
1876
-
1877
- /** @internal */
1878
- export const ListPromptVersionsMetadata$inboundSchema: z.ZodType<
1879
- ListPromptVersionsMetadata,
1880
- z.ZodTypeDef,
1881
- unknown
1882
- > = z.object({
1883
- use_cases: z.array(ListPromptVersionsUseCases$inboundSchema).optional(),
1884
- language: z.nullable(ListPromptVersionsLanguage$inboundSchema).optional(),
1885
- }).transform((v) => {
1886
- return remap$(v, {
1887
- "use_cases": "useCases",
1888
- });
1889
- });
1890
-
1891
- /** @internal */
1892
- export type ListPromptVersionsMetadata$Outbound = {
1893
- use_cases?: Array<string> | undefined;
1894
- language?: string | null | undefined;
1895
- };
1896
-
1897
- /** @internal */
1898
- export const ListPromptVersionsMetadata$outboundSchema: z.ZodType<
1899
- ListPromptVersionsMetadata$Outbound,
1900
- z.ZodTypeDef,
1901
- ListPromptVersionsMetadata
1902
- > = z.object({
1903
- useCases: z.array(ListPromptVersionsUseCases$outboundSchema).optional(),
1904
- language: z.nullable(ListPromptVersionsLanguage$outboundSchema).optional(),
1905
- }).transform((v) => {
1906
- return remap$(v, {
1907
- useCases: "use_cases",
1908
- });
1909
- });
1910
-
1911
- /**
1912
- * @internal
1913
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
1914
- */
1915
- export namespace ListPromptVersionsMetadata$ {
1916
- /** @deprecated use `ListPromptVersionsMetadata$inboundSchema` instead. */
1917
- export const inboundSchema = ListPromptVersionsMetadata$inboundSchema;
1918
- /** @deprecated use `ListPromptVersionsMetadata$outboundSchema` instead. */
1919
- export const outboundSchema = ListPromptVersionsMetadata$outboundSchema;
1920
- /** @deprecated use `ListPromptVersionsMetadata$Outbound` instead. */
1921
- export type Outbound = ListPromptVersionsMetadata$Outbound;
1922
- }
1923
-
1924
- export function listPromptVersionsMetadataToJSON(
1925
- listPromptVersionsMetadata: ListPromptVersionsMetadata,
1926
- ): string {
1927
- return JSON.stringify(
1928
- ListPromptVersionsMetadata$outboundSchema.parse(listPromptVersionsMetadata),
1929
- );
1930
- }
1931
-
1932
- export function listPromptVersionsMetadataFromJSON(
1933
- jsonString: string,
1934
- ): SafeParseResult<ListPromptVersionsMetadata, SDKValidationError> {
1935
- return safeParse(
1936
- jsonString,
1937
- (x) => ListPromptVersionsMetadata$inboundSchema.parse(JSON.parse(x)),
1938
- `Failed to parse 'ListPromptVersionsMetadata' from JSON`,
1939
- );
1940
- }
1941
-
1942
- /** @internal */
1943
- export const ListPromptVersionsData$inboundSchema: z.ZodType<
1944
- ListPromptVersionsData,
1945
- z.ZodTypeDef,
1946
- unknown
1947
- > = z.object({
1948
- _id: z.string(),
1949
- created_by_id: z.nullable(z.string()).optional(),
1950
- updated_by_id: z.nullable(z.string()).optional(),
1951
- description: z.nullable(z.string()).optional(),
1952
- prompt_config: z.lazy(() => ListPromptVersionsPromptConfig$inboundSchema),
1953
- metadata: z.lazy(() => ListPromptVersionsMetadata$inboundSchema).optional(),
1954
- timestamp: z.string(),
1955
- }).transform((v) => {
1956
- return remap$(v, {
1957
- "_id": "id",
1958
- "created_by_id": "createdById",
1959
- "updated_by_id": "updatedById",
1960
- "prompt_config": "promptConfig",
1961
- });
1962
- });
1963
-
1964
- /** @internal */
1965
- export type ListPromptVersionsData$Outbound = {
1966
- _id: string;
1967
- created_by_id?: string | null | undefined;
1968
- updated_by_id?: string | null | undefined;
1969
- description?: string | null | undefined;
1970
- prompt_config: ListPromptVersionsPromptConfig$Outbound;
1971
- metadata?: ListPromptVersionsMetadata$Outbound | undefined;
1972
- timestamp: string;
1973
- };
1974
-
1975
- /** @internal */
1976
- export const ListPromptVersionsData$outboundSchema: z.ZodType<
1977
- ListPromptVersionsData$Outbound,
1978
- z.ZodTypeDef,
1979
- ListPromptVersionsData
1980
- > = z.object({
1981
- id: z.string(),
1982
- createdById: z.nullable(z.string()).optional(),
1983
- updatedById: z.nullable(z.string()).optional(),
1984
- description: z.nullable(z.string()).optional(),
1985
- promptConfig: z.lazy(() => ListPromptVersionsPromptConfig$outboundSchema),
1986
- metadata: z.lazy(() => ListPromptVersionsMetadata$outboundSchema).optional(),
1987
- timestamp: z.string(),
1988
- }).transform((v) => {
1989
- return remap$(v, {
1990
- id: "_id",
1991
- createdById: "created_by_id",
1992
- updatedById: "updated_by_id",
1993
- promptConfig: "prompt_config",
1994
- });
1995
- });
1996
-
1997
- /**
1998
- * @internal
1999
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
2000
- */
2001
- export namespace ListPromptVersionsData$ {
2002
- /** @deprecated use `ListPromptVersionsData$inboundSchema` instead. */
2003
- export const inboundSchema = ListPromptVersionsData$inboundSchema;
2004
- /** @deprecated use `ListPromptVersionsData$outboundSchema` instead. */
2005
- export const outboundSchema = ListPromptVersionsData$outboundSchema;
2006
- /** @deprecated use `ListPromptVersionsData$Outbound` instead. */
2007
- export type Outbound = ListPromptVersionsData$Outbound;
2008
- }
2009
-
2010
- export function listPromptVersionsDataToJSON(
2011
- listPromptVersionsData: ListPromptVersionsData,
2012
- ): string {
2013
- return JSON.stringify(
2014
- ListPromptVersionsData$outboundSchema.parse(listPromptVersionsData),
2015
- );
2016
- }
2017
-
2018
- export function listPromptVersionsDataFromJSON(
2019
- jsonString: string,
2020
- ): SafeParseResult<ListPromptVersionsData, SDKValidationError> {
2021
- return safeParse(
2022
- jsonString,
2023
- (x) => ListPromptVersionsData$inboundSchema.parse(JSON.parse(x)),
2024
- `Failed to parse 'ListPromptVersionsData' from JSON`,
2025
- );
2026
- }
2027
-
2028
- /** @internal */
2029
- export const ListPromptVersionsResponseBody$inboundSchema: z.ZodType<
2030
- ListPromptVersionsResponseBody,
2031
- z.ZodTypeDef,
2032
- unknown
2033
- > = z.object({
2034
- object: ListPromptVersionsObject$inboundSchema,
2035
- data: z.array(z.lazy(() => ListPromptVersionsData$inboundSchema)),
2036
- has_more: z.boolean(),
2037
- }).transform((v) => {
2038
- return remap$(v, {
2039
- "has_more": "hasMore",
2040
- });
2041
- });
2042
-
2043
- /** @internal */
2044
- export type ListPromptVersionsResponseBody$Outbound = {
2045
- object: string;
2046
- data: Array<ListPromptVersionsData$Outbound>;
2047
- has_more: boolean;
2048
- };
2049
-
2050
- /** @internal */
2051
- export const ListPromptVersionsResponseBody$outboundSchema: z.ZodType<
2052
- ListPromptVersionsResponseBody$Outbound,
2053
- z.ZodTypeDef,
2054
- ListPromptVersionsResponseBody
2055
- > = z.object({
2056
- object: ListPromptVersionsObject$outboundSchema,
2057
- data: z.array(z.lazy(() => ListPromptVersionsData$outboundSchema)),
2058
- hasMore: z.boolean(),
2059
- }).transform((v) => {
2060
- return remap$(v, {
2061
- hasMore: "has_more",
2062
- });
2063
- });
2064
-
2065
- /**
2066
- * @internal
2067
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
2068
- */
2069
- export namespace ListPromptVersionsResponseBody$ {
2070
- /** @deprecated use `ListPromptVersionsResponseBody$inboundSchema` instead. */
2071
- export const inboundSchema = ListPromptVersionsResponseBody$inboundSchema;
2072
- /** @deprecated use `ListPromptVersionsResponseBody$outboundSchema` instead. */
2073
- export const outboundSchema = ListPromptVersionsResponseBody$outboundSchema;
2074
- /** @deprecated use `ListPromptVersionsResponseBody$Outbound` instead. */
2075
- export type Outbound = ListPromptVersionsResponseBody$Outbound;
2076
- }
2077
-
2078
- export function listPromptVersionsResponseBodyToJSON(
2079
- listPromptVersionsResponseBody: ListPromptVersionsResponseBody,
2080
- ): string {
2081
- return JSON.stringify(
2082
- ListPromptVersionsResponseBody$outboundSchema.parse(
2083
- listPromptVersionsResponseBody,
2084
- ),
2085
- );
2086
- }
2087
-
2088
- export function listPromptVersionsResponseBodyFromJSON(
2089
- jsonString: string,
2090
- ): SafeParseResult<ListPromptVersionsResponseBody, SDKValidationError> {
2091
- return safeParse(
2092
- jsonString,
2093
- (x) => ListPromptVersionsResponseBody$inboundSchema.parse(JSON.parse(x)),
2094
- `Failed to parse 'ListPromptVersionsResponseBody' from JSON`,
2095
- );
2096
- }