cadenya 0.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (514) hide show
  1. package/CHANGELOG.md +259 -0
  2. package/LICENSE +201 -0
  3. package/README.md +389 -0
  4. package/api-promise.d.mts +2 -0
  5. package/api-promise.d.mts.map +1 -0
  6. package/api-promise.d.ts +2 -0
  7. package/api-promise.d.ts.map +1 -0
  8. package/api-promise.js +6 -0
  9. package/api-promise.js.map +1 -0
  10. package/api-promise.mjs +2 -0
  11. package/api-promise.mjs.map +1 -0
  12. package/client.d.mts +221 -0
  13. package/client.d.mts.map +1 -0
  14. package/client.d.ts +221 -0
  15. package/client.d.ts.map +1 -0
  16. package/client.js +511 -0
  17. package/client.js.map +1 -0
  18. package/client.mjs +507 -0
  19. package/client.mjs.map +1 -0
  20. package/core/api-promise.d.mts +46 -0
  21. package/core/api-promise.d.mts.map +1 -0
  22. package/core/api-promise.d.ts +46 -0
  23. package/core/api-promise.d.ts.map +1 -0
  24. package/core/api-promise.js +74 -0
  25. package/core/api-promise.js.map +1 -0
  26. package/core/api-promise.mjs +70 -0
  27. package/core/api-promise.mjs.map +1 -0
  28. package/core/error.d.mts +46 -0
  29. package/core/error.d.mts.map +1 -0
  30. package/core/error.d.ts +46 -0
  31. package/core/error.d.ts.map +1 -0
  32. package/core/error.js +113 -0
  33. package/core/error.js.map +1 -0
  34. package/core/error.mjs +97 -0
  35. package/core/error.mjs.map +1 -0
  36. package/core/pagination.d.mts +59 -0
  37. package/core/pagination.d.mts.map +1 -0
  38. package/core/pagination.d.ts +59 -0
  39. package/core/pagination.d.ts.map +1 -0
  40. package/core/pagination.js +101 -0
  41. package/core/pagination.js.map +1 -0
  42. package/core/pagination.mjs +95 -0
  43. package/core/pagination.mjs.map +1 -0
  44. package/core/resource.d.mts +6 -0
  45. package/core/resource.d.mts.map +1 -0
  46. package/core/resource.d.ts +6 -0
  47. package/core/resource.d.ts.map +1 -0
  48. package/core/resource.js +11 -0
  49. package/core/resource.js.map +1 -0
  50. package/core/resource.mjs +7 -0
  51. package/core/resource.mjs.map +1 -0
  52. package/core/uploads.d.mts +3 -0
  53. package/core/uploads.d.mts.map +1 -0
  54. package/core/uploads.d.ts +3 -0
  55. package/core/uploads.d.ts.map +1 -0
  56. package/core/uploads.js +6 -0
  57. package/core/uploads.js.map +1 -0
  58. package/core/uploads.mjs +2 -0
  59. package/core/uploads.mjs.map +1 -0
  60. package/error.d.mts +2 -0
  61. package/error.d.mts.map +1 -0
  62. package/error.d.ts +2 -0
  63. package/error.d.ts.map +1 -0
  64. package/error.js +6 -0
  65. package/error.js.map +1 -0
  66. package/error.mjs +2 -0
  67. package/error.mjs.map +1 -0
  68. package/index.d.mts +7 -0
  69. package/index.d.mts.map +1 -0
  70. package/index.d.ts +7 -0
  71. package/index.d.ts.map +1 -0
  72. package/index.js +32 -0
  73. package/index.js.map +1 -0
  74. package/index.mjs +8 -0
  75. package/index.mjs.map +1 -0
  76. package/internal/builtin-types.d.mts +73 -0
  77. package/internal/builtin-types.d.mts.map +1 -0
  78. package/internal/builtin-types.d.ts +73 -0
  79. package/internal/builtin-types.d.ts.map +1 -0
  80. package/internal/builtin-types.js +4 -0
  81. package/internal/builtin-types.js.map +1 -0
  82. package/internal/builtin-types.mjs +3 -0
  83. package/internal/builtin-types.mjs.map +1 -0
  84. package/internal/detect-platform.d.mts +15 -0
  85. package/internal/detect-platform.d.mts.map +1 -0
  86. package/internal/detect-platform.d.ts +15 -0
  87. package/internal/detect-platform.d.ts.map +1 -0
  88. package/internal/detect-platform.js +162 -0
  89. package/internal/detect-platform.js.map +1 -0
  90. package/internal/detect-platform.mjs +157 -0
  91. package/internal/detect-platform.mjs.map +1 -0
  92. package/internal/errors.d.mts +3 -0
  93. package/internal/errors.d.mts.map +1 -0
  94. package/internal/errors.d.ts +3 -0
  95. package/internal/errors.d.ts.map +1 -0
  96. package/internal/errors.js +41 -0
  97. package/internal/errors.js.map +1 -0
  98. package/internal/errors.mjs +36 -0
  99. package/internal/errors.mjs.map +1 -0
  100. package/internal/headers.d.mts +20 -0
  101. package/internal/headers.d.mts.map +1 -0
  102. package/internal/headers.d.ts +20 -0
  103. package/internal/headers.d.ts.map +1 -0
  104. package/internal/headers.js +79 -0
  105. package/internal/headers.js.map +1 -0
  106. package/internal/headers.mjs +74 -0
  107. package/internal/headers.mjs.map +1 -0
  108. package/internal/parse.d.mts +12 -0
  109. package/internal/parse.d.mts.map +1 -0
  110. package/internal/parse.d.ts +12 -0
  111. package/internal/parse.d.ts.map +1 -0
  112. package/internal/parse.js +40 -0
  113. package/internal/parse.js.map +1 -0
  114. package/internal/parse.mjs +37 -0
  115. package/internal/parse.mjs.map +1 -0
  116. package/internal/request-options.d.mts +75 -0
  117. package/internal/request-options.d.mts.map +1 -0
  118. package/internal/request-options.d.ts +75 -0
  119. package/internal/request-options.d.ts.map +1 -0
  120. package/internal/request-options.js +14 -0
  121. package/internal/request-options.js.map +1 -0
  122. package/internal/request-options.mjs +10 -0
  123. package/internal/request-options.mjs.map +1 -0
  124. package/internal/shim-types.d.mts +17 -0
  125. package/internal/shim-types.d.mts.map +1 -0
  126. package/internal/shim-types.d.ts +17 -0
  127. package/internal/shim-types.d.ts.map +1 -0
  128. package/internal/shim-types.js +4 -0
  129. package/internal/shim-types.js.map +1 -0
  130. package/internal/shim-types.mjs +3 -0
  131. package/internal/shim-types.mjs.map +1 -0
  132. package/internal/shims.d.mts +20 -0
  133. package/internal/shims.d.mts.map +1 -0
  134. package/internal/shims.d.ts +20 -0
  135. package/internal/shims.d.ts.map +1 -0
  136. package/internal/shims.js +92 -0
  137. package/internal/shims.js.map +1 -0
  138. package/internal/shims.mjs +85 -0
  139. package/internal/shims.mjs.map +1 -0
  140. package/internal/to-file.d.mts +45 -0
  141. package/internal/to-file.d.mts.map +1 -0
  142. package/internal/to-file.d.ts +45 -0
  143. package/internal/to-file.d.ts.map +1 -0
  144. package/internal/to-file.js +91 -0
  145. package/internal/to-file.js.map +1 -0
  146. package/internal/to-file.mjs +88 -0
  147. package/internal/to-file.mjs.map +1 -0
  148. package/internal/tslib.js +81 -0
  149. package/internal/tslib.mjs +17 -0
  150. package/internal/types.d.mts +69 -0
  151. package/internal/types.d.mts.map +1 -0
  152. package/internal/types.d.ts +69 -0
  153. package/internal/types.d.ts.map +1 -0
  154. package/internal/types.js +4 -0
  155. package/internal/types.js.map +1 -0
  156. package/internal/types.mjs +3 -0
  157. package/internal/types.mjs.map +1 -0
  158. package/internal/uploads.d.mts +42 -0
  159. package/internal/uploads.d.mts.map +1 -0
  160. package/internal/uploads.d.ts +42 -0
  161. package/internal/uploads.d.ts.map +1 -0
  162. package/internal/uploads.js +141 -0
  163. package/internal/uploads.js.map +1 -0
  164. package/internal/uploads.mjs +131 -0
  165. package/internal/uploads.mjs.map +1 -0
  166. package/internal/utils/base64.d.mts +3 -0
  167. package/internal/utils/base64.d.mts.map +1 -0
  168. package/internal/utils/base64.d.ts +3 -0
  169. package/internal/utils/base64.d.ts.map +1 -0
  170. package/internal/utils/base64.js +38 -0
  171. package/internal/utils/base64.js.map +1 -0
  172. package/internal/utils/base64.mjs +33 -0
  173. package/internal/utils/base64.mjs.map +1 -0
  174. package/internal/utils/bytes.d.mts +4 -0
  175. package/internal/utils/bytes.d.mts.map +1 -0
  176. package/internal/utils/bytes.d.ts +4 -0
  177. package/internal/utils/bytes.d.ts.map +1 -0
  178. package/internal/utils/bytes.js +31 -0
  179. package/internal/utils/bytes.js.map +1 -0
  180. package/internal/utils/bytes.mjs +26 -0
  181. package/internal/utils/bytes.mjs.map +1 -0
  182. package/internal/utils/env.d.mts +9 -0
  183. package/internal/utils/env.d.mts.map +1 -0
  184. package/internal/utils/env.d.ts +9 -0
  185. package/internal/utils/env.d.ts.map +1 -0
  186. package/internal/utils/env.js +22 -0
  187. package/internal/utils/env.js.map +1 -0
  188. package/internal/utils/env.mjs +18 -0
  189. package/internal/utils/env.mjs.map +1 -0
  190. package/internal/utils/log.d.mts +37 -0
  191. package/internal/utils/log.d.mts.map +1 -0
  192. package/internal/utils/log.d.ts +37 -0
  193. package/internal/utils/log.d.ts.map +1 -0
  194. package/internal/utils/log.js +85 -0
  195. package/internal/utils/log.js.map +1 -0
  196. package/internal/utils/log.mjs +79 -0
  197. package/internal/utils/log.mjs.map +1 -0
  198. package/internal/utils/path.d.mts +15 -0
  199. package/internal/utils/path.d.mts.map +1 -0
  200. package/internal/utils/path.d.ts +15 -0
  201. package/internal/utils/path.d.ts.map +1 -0
  202. package/internal/utils/path.js +79 -0
  203. package/internal/utils/path.js.map +1 -0
  204. package/internal/utils/path.mjs +74 -0
  205. package/internal/utils/path.mjs.map +1 -0
  206. package/internal/utils/sleep.d.mts +2 -0
  207. package/internal/utils/sleep.d.mts.map +1 -0
  208. package/internal/utils/sleep.d.ts +2 -0
  209. package/internal/utils/sleep.d.ts.map +1 -0
  210. package/internal/utils/sleep.js +7 -0
  211. package/internal/utils/sleep.js.map +1 -0
  212. package/internal/utils/sleep.mjs +3 -0
  213. package/internal/utils/sleep.mjs.map +1 -0
  214. package/internal/utils/uuid.d.mts +5 -0
  215. package/internal/utils/uuid.d.mts.map +1 -0
  216. package/internal/utils/uuid.d.ts +5 -0
  217. package/internal/utils/uuid.d.ts.map +1 -0
  218. package/internal/utils/uuid.js +19 -0
  219. package/internal/utils/uuid.js.map +1 -0
  220. package/internal/utils/uuid.mjs +15 -0
  221. package/internal/utils/uuid.mjs.map +1 -0
  222. package/internal/utils/values.d.mts +18 -0
  223. package/internal/utils/values.d.mts.map +1 -0
  224. package/internal/utils/values.d.ts +18 -0
  225. package/internal/utils/values.d.ts.map +1 -0
  226. package/internal/utils/values.js +112 -0
  227. package/internal/utils/values.js.map +1 -0
  228. package/internal/utils/values.mjs +94 -0
  229. package/internal/utils/values.mjs.map +1 -0
  230. package/internal/utils.d.mts +7 -0
  231. package/internal/utils.d.mts.map +1 -0
  232. package/internal/utils.d.ts +7 -0
  233. package/internal/utils.d.ts.map +1 -0
  234. package/internal/utils.js +11 -0
  235. package/internal/utils.js.map +1 -0
  236. package/internal/utils.mjs +8 -0
  237. package/internal/utils.mjs.map +1 -0
  238. package/package.json +148 -0
  239. package/pagination.d.mts +2 -0
  240. package/pagination.d.mts.map +1 -0
  241. package/pagination.d.ts +2 -0
  242. package/pagination.d.ts.map +1 -0
  243. package/pagination.js +6 -0
  244. package/pagination.js.map +1 -0
  245. package/pagination.mjs +2 -0
  246. package/pagination.mjs.map +1 -0
  247. package/resource.d.mts +2 -0
  248. package/resource.d.mts.map +1 -0
  249. package/resource.d.ts +2 -0
  250. package/resource.d.ts.map +1 -0
  251. package/resource.js +6 -0
  252. package/resource.js.map +1 -0
  253. package/resource.mjs +2 -0
  254. package/resource.mjs.map +1 -0
  255. package/resources/account.d.mts +31 -0
  256. package/resources/account.d.mts.map +1 -0
  257. package/resources/account.d.ts +31 -0
  258. package/resources/account.d.ts.map +1 -0
  259. package/resources/account.js +16 -0
  260. package/resources/account.js.map +1 -0
  261. package/resources/account.mjs +12 -0
  262. package/resources/account.mjs.map +1 -0
  263. package/resources/agents/agents.d.mts +132 -0
  264. package/resources/agents/agents.d.mts.map +1 -0
  265. package/resources/agents/agents.d.ts +132 -0
  266. package/resources/agents/agents.d.ts.map +1 -0
  267. package/resources/agents/agents.js +57 -0
  268. package/resources/agents/agents.js.map +1 -0
  269. package/resources/agents/agents.mjs +52 -0
  270. package/resources/agents/agents.mjs.map +1 -0
  271. package/resources/agents/index.d.mts +4 -0
  272. package/resources/agents/index.d.mts.map +1 -0
  273. package/resources/agents/index.d.ts +4 -0
  274. package/resources/agents/index.d.ts.map +1 -0
  275. package/resources/agents/index.js +11 -0
  276. package/resources/agents/index.js.map +1 -0
  277. package/resources/agents/index.mjs +5 -0
  278. package/resources/agents/index.mjs.map +1 -0
  279. package/resources/agents/variations.d.mts +236 -0
  280. package/resources/agents/variations.d.mts.map +1 -0
  281. package/resources/agents/variations.d.ts +236 -0
  282. package/resources/agents/variations.d.ts.map +1 -0
  283. package/resources/agents/variations.js +51 -0
  284. package/resources/agents/variations.js.map +1 -0
  285. package/resources/agents/variations.mjs +47 -0
  286. package/resources/agents/variations.mjs.map +1 -0
  287. package/resources/agents/webhook-deliveries.d.mts +55 -0
  288. package/resources/agents/webhook-deliveries.d.mts.map +1 -0
  289. package/resources/agents/webhook-deliveries.d.ts +55 -0
  290. package/resources/agents/webhook-deliveries.d.ts.map +1 -0
  291. package/resources/agents/webhook-deliveries.js +17 -0
  292. package/resources/agents/webhook-deliveries.js.map +1 -0
  293. package/resources/agents/webhook-deliveries.mjs +13 -0
  294. package/resources/agents/webhook-deliveries.mjs.map +1 -0
  295. package/resources/agents.d.mts +2 -0
  296. package/resources/agents.d.mts.map +1 -0
  297. package/resources/agents.d.ts +2 -0
  298. package/resources/agents.d.ts.map +1 -0
  299. package/resources/agents.js +6 -0
  300. package/resources/agents.js.map +1 -0
  301. package/resources/agents.mjs +3 -0
  302. package/resources/agents.mjs.map +1 -0
  303. package/resources/api-keys.d.mts +109 -0
  304. package/resources/api-keys.d.mts.map +1 -0
  305. package/resources/api-keys.d.ts +109 -0
  306. package/resources/api-keys.d.ts.map +1 -0
  307. package/resources/api-keys.js +53 -0
  308. package/resources/api-keys.js.map +1 -0
  309. package/resources/api-keys.mjs +49 -0
  310. package/resources/api-keys.mjs.map +1 -0
  311. package/resources/document-namespaces.d.mts +91 -0
  312. package/resources/document-namespaces.d.mts.map +1 -0
  313. package/resources/document-namespaces.d.ts +91 -0
  314. package/resources/document-namespaces.d.ts.map +1 -0
  315. package/resources/document-namespaces.js +48 -0
  316. package/resources/document-namespaces.js.map +1 -0
  317. package/resources/document-namespaces.mjs +44 -0
  318. package/resources/document-namespaces.mjs.map +1 -0
  319. package/resources/documents.d.mts +968 -0
  320. package/resources/documents.d.mts.map +1 -0
  321. package/resources/documents.d.ts +968 -0
  322. package/resources/documents.d.ts.map +1 -0
  323. package/resources/documents.js +45 -0
  324. package/resources/documents.js.map +1 -0
  325. package/resources/documents.mjs +41 -0
  326. package/resources/documents.mjs.map +1 -0
  327. package/resources/index.d.mts +12 -0
  328. package/resources/index.d.mts.map +1 -0
  329. package/resources/index.d.ts +12 -0
  330. package/resources/index.d.ts.map +1 -0
  331. package/resources/index.js +27 -0
  332. package/resources/index.js.map +1 -0
  333. package/resources/index.mjs +13 -0
  334. package/resources/index.mjs.map +1 -0
  335. package/resources/objectives/index.d.mts +3 -0
  336. package/resources/objectives/index.d.mts.map +1 -0
  337. package/resources/objectives/index.d.ts +3 -0
  338. package/resources/objectives/index.d.ts.map +1 -0
  339. package/resources/objectives/index.js +9 -0
  340. package/resources/objectives/index.js.map +1 -0
  341. package/resources/objectives/index.mjs +4 -0
  342. package/resources/objectives/index.mjs.map +1 -0
  343. package/resources/objectives/objectives.d.mts +521 -0
  344. package/resources/objectives/objectives.d.mts.map +1 -0
  345. package/resources/objectives/objectives.d.ts +521 -0
  346. package/resources/objectives/objectives.d.ts.map +1 -0
  347. package/resources/objectives/objectives.js +63 -0
  348. package/resources/objectives/objectives.js.map +1 -0
  349. package/resources/objectives/objectives.mjs +58 -0
  350. package/resources/objectives/objectives.mjs.map +1 -0
  351. package/resources/objectives/tool-calls.d.mts +120 -0
  352. package/resources/objectives/tool-calls.d.mts.map +1 -0
  353. package/resources/objectives/tool-calls.d.ts +120 -0
  354. package/resources/objectives/tool-calls.d.ts.map +1 -0
  355. package/resources/objectives/tool-calls.js +42 -0
  356. package/resources/objectives/tool-calls.js.map +1 -0
  357. package/resources/objectives/tool-calls.mjs +38 -0
  358. package/resources/objectives/tool-calls.mjs.map +1 -0
  359. package/resources/objectives.d.mts +2 -0
  360. package/resources/objectives.d.mts.map +1 -0
  361. package/resources/objectives.d.ts +2 -0
  362. package/resources/objectives.d.ts.map +1 -0
  363. package/resources/objectives.js +6 -0
  364. package/resources/objectives.js.map +1 -0
  365. package/resources/objectives.mjs +3 -0
  366. package/resources/objectives.mjs.map +1 -0
  367. package/resources/search.d.mts +24 -0
  368. package/resources/search.d.mts.map +1 -0
  369. package/resources/search.d.ts +24 -0
  370. package/resources/search.d.ts.map +1 -0
  371. package/resources/search.js +15 -0
  372. package/resources/search.js.map +1 -0
  373. package/resources/search.mjs +11 -0
  374. package/resources/search.mjs.map +1 -0
  375. package/resources/shared.d.mts +176 -0
  376. package/resources/shared.d.mts.map +1 -0
  377. package/resources/shared.d.ts +176 -0
  378. package/resources/shared.d.ts.map +1 -0
  379. package/resources/shared.js +4 -0
  380. package/resources/shared.js.map +1 -0
  381. package/resources/shared.mjs +3 -0
  382. package/resources/shared.mjs.map +1 -0
  383. package/resources/tool-sets/index.d.mts +3 -0
  384. package/resources/tool-sets/index.d.mts.map +1 -0
  385. package/resources/tool-sets/index.d.ts +3 -0
  386. package/resources/tool-sets/index.d.ts.map +1 -0
  387. package/resources/tool-sets/index.js +9 -0
  388. package/resources/tool-sets/index.js.map +1 -0
  389. package/resources/tool-sets/index.mjs +4 -0
  390. package/resources/tool-sets/index.mjs.map +1 -0
  391. package/resources/tool-sets/tool-sets.d.mts +240 -0
  392. package/resources/tool-sets/tool-sets.d.mts.map +1 -0
  393. package/resources/tool-sets/tool-sets.d.ts +240 -0
  394. package/resources/tool-sets/tool-sets.d.ts.map +1 -0
  395. package/resources/tool-sets/tool-sets.js +62 -0
  396. package/resources/tool-sets/tool-sets.js.map +1 -0
  397. package/resources/tool-sets/tool-sets.mjs +57 -0
  398. package/resources/tool-sets/tool-sets.mjs.map +1 -0
  399. package/resources/tool-sets/tools.d.mts +130 -0
  400. package/resources/tool-sets/tools.d.mts.map +1 -0
  401. package/resources/tool-sets/tools.d.ts +130 -0
  402. package/resources/tool-sets/tools.d.ts.map +1 -0
  403. package/resources/tool-sets/tools.js +51 -0
  404. package/resources/tool-sets/tools.js.map +1 -0
  405. package/resources/tool-sets/tools.mjs +47 -0
  406. package/resources/tool-sets/tools.mjs.map +1 -0
  407. package/resources/tool-sets.d.mts +2 -0
  408. package/resources/tool-sets.d.mts.map +1 -0
  409. package/resources/tool-sets.d.ts +2 -0
  410. package/resources/tool-sets.d.ts.map +1 -0
  411. package/resources/tool-sets.js +6 -0
  412. package/resources/tool-sets.js.map +1 -0
  413. package/resources/tool-sets.mjs +3 -0
  414. package/resources/tool-sets.mjs.map +1 -0
  415. package/resources/workspace-secrets.d.mts +70 -0
  416. package/resources/workspace-secrets.d.mts.map +1 -0
  417. package/resources/workspace-secrets.d.ts +70 -0
  418. package/resources/workspace-secrets.d.ts.map +1 -0
  419. package/resources/workspace-secrets.js +48 -0
  420. package/resources/workspace-secrets.js.map +1 -0
  421. package/resources/workspace-secrets.mjs +44 -0
  422. package/resources/workspace-secrets.mjs.map +1 -0
  423. package/resources/workspaces.d.mts +37 -0
  424. package/resources/workspaces.d.mts.map +1 -0
  425. package/resources/workspaces.d.ts +37 -0
  426. package/resources/workspaces.d.ts.map +1 -0
  427. package/resources/workspaces.js +25 -0
  428. package/resources/workspaces.js.map +1 -0
  429. package/resources/workspaces.mjs +21 -0
  430. package/resources/workspaces.mjs.map +1 -0
  431. package/resources.d.mts +2 -0
  432. package/resources.d.mts.map +1 -0
  433. package/resources.d.ts +2 -0
  434. package/resources.d.ts.map +1 -0
  435. package/resources.js +5 -0
  436. package/resources.js.map +1 -0
  437. package/resources.mjs +2 -0
  438. package/resources.mjs.map +1 -0
  439. package/src/api-promise.ts +2 -0
  440. package/src/client.ts +1036 -0
  441. package/src/core/README.md +3 -0
  442. package/src/core/api-promise.ts +92 -0
  443. package/src/core/error.ts +130 -0
  444. package/src/core/pagination.ts +163 -0
  445. package/src/core/resource.ts +11 -0
  446. package/src/core/uploads.ts +2 -0
  447. package/src/error.ts +2 -0
  448. package/src/index.ts +23 -0
  449. package/src/internal/README.md +3 -0
  450. package/src/internal/builtin-types.ts +93 -0
  451. package/src/internal/detect-platform.ts +196 -0
  452. package/src/internal/errors.ts +33 -0
  453. package/src/internal/headers.ts +97 -0
  454. package/src/internal/parse.ts +56 -0
  455. package/src/internal/request-options.ts +91 -0
  456. package/src/internal/shim-types.ts +26 -0
  457. package/src/internal/shims.ts +107 -0
  458. package/src/internal/to-file.ts +154 -0
  459. package/src/internal/types.ts +95 -0
  460. package/src/internal/uploads.ts +187 -0
  461. package/src/internal/utils/base64.ts +40 -0
  462. package/src/internal/utils/bytes.ts +32 -0
  463. package/src/internal/utils/env.ts +18 -0
  464. package/src/internal/utils/log.ts +126 -0
  465. package/src/internal/utils/path.ts +88 -0
  466. package/src/internal/utils/sleep.ts +3 -0
  467. package/src/internal/utils/uuid.ts +17 -0
  468. package/src/internal/utils/values.ts +105 -0
  469. package/src/internal/utils.ts +8 -0
  470. package/src/lib/.keep +4 -0
  471. package/src/pagination.ts +2 -0
  472. package/src/resource.ts +2 -0
  473. package/src/resources/account.ts +42 -0
  474. package/src/resources/agents/agents.ts +244 -0
  475. package/src/resources/agents/index.ts +36 -0
  476. package/src/resources/agents/variations.ts +329 -0
  477. package/src/resources/agents/webhook-deliveries.ts +92 -0
  478. package/src/resources/agents.ts +3 -0
  479. package/src/resources/api-keys.ts +157 -0
  480. package/src/resources/document-namespaces.ts +145 -0
  481. package/src/resources/documents.ts +1239 -0
  482. package/src/resources/index.ts +118 -0
  483. package/src/resources/objectives/index.ts +26 -0
  484. package/src/resources/objectives/objectives.ts +739 -0
  485. package/src/resources/objectives/tool-calls.ts +182 -0
  486. package/src/resources/objectives.ts +3 -0
  487. package/src/resources/search.ts +39 -0
  488. package/src/resources/shared.ts +203 -0
  489. package/src/resources/tool-sets/index.ts +37 -0
  490. package/src/resources/tool-sets/tool-sets.ts +369 -0
  491. package/src/resources/tool-sets/tools.ts +208 -0
  492. package/src/resources/tool-sets.ts +3 -0
  493. package/src/resources/workspace-secrets.ts +120 -0
  494. package/src/resources/workspaces.ts +60 -0
  495. package/src/resources.ts +1 -0
  496. package/src/tsconfig.json +11 -0
  497. package/src/uploads.ts +2 -0
  498. package/src/version.ts +1 -0
  499. package/uploads.d.mts +2 -0
  500. package/uploads.d.mts.map +1 -0
  501. package/uploads.d.ts +2 -0
  502. package/uploads.d.ts.map +1 -0
  503. package/uploads.js +6 -0
  504. package/uploads.js.map +1 -0
  505. package/uploads.mjs +2 -0
  506. package/uploads.mjs.map +1 -0
  507. package/version.d.mts +2 -0
  508. package/version.d.mts.map +1 -0
  509. package/version.d.ts +2 -0
  510. package/version.d.ts.map +1 -0
  511. package/version.js +5 -0
  512. package/version.js.map +1 -0
  513. package/version.mjs +2 -0
  514. package/version.mjs.map +1 -0
@@ -0,0 +1,1239 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+ import * as DocumentsAPI from './documents';
5
+ import * as Shared from './shared';
6
+ import { APIPromise } from '../core/api-promise';
7
+ import { CursorPagination, type CursorPaginationParams, PagePromise } from '../core/pagination';
8
+ import { buildHeaders } from '../internal/headers';
9
+ import { RequestOptions } from '../internal/request-options';
10
+ import { path } from '../internal/utils/path';
11
+
12
+ export class Documents extends APIResource {
13
+ /**
14
+ * Creates a new document in the workspace within a namespace
15
+ */
16
+ create(body: DocumentCreateParams, options?: RequestOptions): APIPromise<Document> {
17
+ return this._client.post('/v1/documents', { body, ...options });
18
+ }
19
+
20
+ /**
21
+ * Retrieves a document by ID from the workspace
22
+ */
23
+ retrieve(id: string, options?: RequestOptions): APIPromise<Document> {
24
+ return this._client.get(path`/v1/documents/${id}`, options);
25
+ }
26
+
27
+ /**
28
+ * Updates a document in the workspace
29
+ */
30
+ update(pathID: string, body: DocumentUpdateParams, options?: RequestOptions): APIPromise<Document> {
31
+ return this._client.patch(path`/v1/documents/${pathID}`, { body, ...options });
32
+ }
33
+
34
+ /**
35
+ * Lists all documents in the workspace, optionally filtered by namespace
36
+ */
37
+ list(
38
+ query: DocumentListParams | null | undefined = {},
39
+ options?: RequestOptions,
40
+ ): PagePromise<DocumentsCursorPagination, Document> {
41
+ return this._client.getAPIList('/v1/documents', CursorPagination<Document>, { query, ...options });
42
+ }
43
+
44
+ /**
45
+ * Deletes a document from the workspace
46
+ */
47
+ delete(id: string, options?: RequestOptions): APIPromise<void> {
48
+ return this._client.delete(path`/v1/documents/${id}`, {
49
+ ...options,
50
+ headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
51
+ });
52
+ }
53
+ }
54
+
55
+ export type DocumentsCursorPagination = CursorPagination<Document>;
56
+
57
+ export interface Any {
58
+ /**
59
+ * Contains an arbitrary serialized message along with a @type that describes the
60
+ * type of the serialized message.
61
+ */
62
+ value?: GoogleProtobufAny;
63
+
64
+ yaml?: string;
65
+ }
66
+
67
+ export interface AnyOrExpression {
68
+ any?: Any;
69
+
70
+ expression?: Expression;
71
+ }
72
+
73
+ export interface CallbacksOrReferences {
74
+ additionalProperties?: Array<unknown>;
75
+ }
76
+
77
+ export interface Document {
78
+ /**
79
+ * Holds a set of reusable objects for different aspects of the OAS. All objects
80
+ * defined within the components object will have no effect on the API unless they
81
+ * are explicitly referenced from properties outside the components object.
82
+ */
83
+ components?: Document.Components;
84
+
85
+ /**
86
+ * Allows referencing an external resource for extended documentation.
87
+ */
88
+ externalDocs?: Document.ExternalDocs;
89
+
90
+ /**
91
+ * The object provides metadata about the API. The metadata MAY be used by the
92
+ * clients if needed, and MAY be presented in editing or documentation generation
93
+ * tools for convenience.
94
+ */
95
+ info?: Document.Info;
96
+
97
+ openapi?: string;
98
+
99
+ /**
100
+ * Holds the relative paths to the individual endpoints and their operations. The
101
+ * path is appended to the URL from the `Server Object` in order to construct the
102
+ * full URL. The Paths MAY be empty, due to ACL constraints.
103
+ */
104
+ paths?: Document.Paths;
105
+
106
+ security?: Array<Document.Security>;
107
+
108
+ servers?: Array<Server>;
109
+
110
+ specificationExtension?: Array<NamedAny>;
111
+
112
+ tags?: Array<Document.Tag>;
113
+ }
114
+
115
+ export namespace Document {
116
+ /**
117
+ * Holds a set of reusable objects for different aspects of the OAS. All objects
118
+ * defined within the components object will have no effect on the API unless they
119
+ * are explicitly referenced from properties outside the components object.
120
+ */
121
+ export interface Components {
122
+ callbacks?: DocumentsAPI.CallbacksOrReferences;
123
+
124
+ examples?: Components.Examples;
125
+
126
+ headers?: DocumentsAPI.HeadersOrReferences;
127
+
128
+ links?: Components.Links;
129
+
130
+ parameters?: Components.Parameters;
131
+
132
+ requestBodies?: Components.RequestBodies;
133
+
134
+ responses?: Components.Responses;
135
+
136
+ schemas?: Components.Schemas;
137
+
138
+ securitySchemes?: Components.SecuritySchemes;
139
+
140
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
141
+ }
142
+
143
+ export namespace Components {
144
+ export interface Examples {
145
+ additionalProperties?: Array<Examples.AdditionalProperty>;
146
+ }
147
+
148
+ export namespace Examples {
149
+ /**
150
+ * Automatically-generated message used to represent maps of ExampleOrReference as
151
+ * ordered (name,value) pairs.
152
+ */
153
+ export interface AdditionalProperty {
154
+ /**
155
+ * Map key
156
+ */
157
+ name?: string;
158
+
159
+ /**
160
+ * Mapped value
161
+ */
162
+ value?: AdditionalProperty.Value;
163
+ }
164
+
165
+ export namespace AdditionalProperty {
166
+ /**
167
+ * Mapped value
168
+ */
169
+ export interface Value {
170
+ example?: Value.Example;
171
+
172
+ /**
173
+ * A simple object to allow referencing other components in the specification,
174
+ * internally and externally. The Reference Object is defined by JSON Reference and
175
+ * follows the same structure, behavior and rules. For this specification,
176
+ * reference resolution is accomplished as defined by the JSON Reference
177
+ * specification and not by the JSON Schema specification.
178
+ */
179
+ reference?: DocumentsAPI.Reference;
180
+ }
181
+
182
+ export namespace Value {
183
+ export interface Example {
184
+ description?: string;
185
+
186
+ externalValue?: string;
187
+
188
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
189
+
190
+ summary?: string;
191
+
192
+ value?: DocumentsAPI.Any;
193
+ }
194
+ }
195
+ }
196
+ }
197
+
198
+ export interface Links {
199
+ additionalProperties?: Array<Links.AdditionalProperty>;
200
+ }
201
+
202
+ export namespace Links {
203
+ /**
204
+ * Automatically-generated message used to represent maps of LinkOrReference as
205
+ * ordered (name,value) pairs.
206
+ */
207
+ export interface AdditionalProperty {
208
+ /**
209
+ * Map key
210
+ */
211
+ name?: string;
212
+
213
+ /**
214
+ * Mapped value
215
+ */
216
+ value?: AdditionalProperty.Value;
217
+ }
218
+
219
+ export namespace AdditionalProperty {
220
+ /**
221
+ * Mapped value
222
+ */
223
+ export interface Value {
224
+ /**
225
+ * The `Link object` represents a possible design-time link for a response. The
226
+ * presence of a link does not guarantee the caller's ability to successfully
227
+ * invoke it, rather it provides a known relationship and traversal mechanism
228
+ * between responses and other operations. Unlike _dynamic_ links (i.e. links
229
+ * provided **in** the response payload), the OAS linking mechanism does not
230
+ * require link information in the runtime response. For computing links, and
231
+ * providing instructions to execute them, a runtime expression is used for
232
+ * accessing values in an operation and using them as parameters while invoking the
233
+ * linked operation.
234
+ */
235
+ link?: Value.Link;
236
+
237
+ /**
238
+ * A simple object to allow referencing other components in the specification,
239
+ * internally and externally. The Reference Object is defined by JSON Reference and
240
+ * follows the same structure, behavior and rules. For this specification,
241
+ * reference resolution is accomplished as defined by the JSON Reference
242
+ * specification and not by the JSON Schema specification.
243
+ */
244
+ reference?: DocumentsAPI.Reference;
245
+ }
246
+
247
+ export namespace Value {
248
+ /**
249
+ * The `Link object` represents a possible design-time link for a response. The
250
+ * presence of a link does not guarantee the caller's ability to successfully
251
+ * invoke it, rather it provides a known relationship and traversal mechanism
252
+ * between responses and other operations. Unlike _dynamic_ links (i.e. links
253
+ * provided **in** the response payload), the OAS linking mechanism does not
254
+ * require link information in the runtime response. For computing links, and
255
+ * providing instructions to execute them, a runtime expression is used for
256
+ * accessing values in an operation and using them as parameters while invoking the
257
+ * linked operation.
258
+ */
259
+ export interface Link {
260
+ description?: string;
261
+
262
+ operationId?: string;
263
+
264
+ operationRef?: string;
265
+
266
+ parameters?: DocumentsAPI.AnyOrExpression;
267
+
268
+ requestBody?: DocumentsAPI.AnyOrExpression;
269
+
270
+ /**
271
+ * An object representing a Server.
272
+ */
273
+ server?: DocumentsAPI.Server;
274
+
275
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
276
+ }
277
+ }
278
+ }
279
+ }
280
+
281
+ export interface Parameters {
282
+ additionalProperties?: Array<Parameters.AdditionalProperty>;
283
+ }
284
+
285
+ export namespace Parameters {
286
+ /**
287
+ * Automatically-generated message used to represent maps of ParameterOrReference
288
+ * as ordered (name,value) pairs.
289
+ */
290
+ export interface AdditionalProperty {
291
+ /**
292
+ * Map key
293
+ */
294
+ name?: string;
295
+
296
+ /**
297
+ * Mapped value
298
+ */
299
+ value?: AdditionalProperty.Value;
300
+ }
301
+
302
+ export namespace AdditionalProperty {
303
+ /**
304
+ * Mapped value
305
+ */
306
+ export interface Value {
307
+ /**
308
+ * Describes a single operation parameter. A unique parameter is defined by a
309
+ * combination of a name and location.
310
+ */
311
+ parameter?: Value.Parameter;
312
+
313
+ /**
314
+ * A simple object to allow referencing other components in the specification,
315
+ * internally and externally. The Reference Object is defined by JSON Reference and
316
+ * follows the same structure, behavior and rules. For this specification,
317
+ * reference resolution is accomplished as defined by the JSON Reference
318
+ * specification and not by the JSON Schema specification.
319
+ */
320
+ reference?: DocumentsAPI.Reference;
321
+ }
322
+
323
+ export namespace Value {
324
+ /**
325
+ * Describes a single operation parameter. A unique parameter is defined by a
326
+ * combination of a name and location.
327
+ */
328
+ export interface Parameter {
329
+ allowEmptyValue?: boolean;
330
+
331
+ allowReserved?: boolean;
332
+
333
+ content?: DocumentsAPI.MediaTypes;
334
+
335
+ deprecated?: boolean;
336
+
337
+ description?: string;
338
+
339
+ example?: DocumentsAPI.Any;
340
+
341
+ examples?: Parameter.Examples;
342
+
343
+ explode?: boolean;
344
+
345
+ in?: string;
346
+
347
+ name?: string;
348
+
349
+ required?: boolean;
350
+
351
+ schema?: DocumentsAPI.SchemaOrReference;
352
+
353
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
354
+
355
+ style?: string;
356
+ }
357
+
358
+ export namespace Parameter {
359
+ export interface Examples {
360
+ additionalProperties?: Array<Examples.AdditionalProperty>;
361
+ }
362
+
363
+ export namespace Examples {
364
+ /**
365
+ * Automatically-generated message used to represent maps of ExampleOrReference as
366
+ * ordered (name,value) pairs.
367
+ */
368
+ export interface AdditionalProperty {
369
+ /**
370
+ * Map key
371
+ */
372
+ name?: string;
373
+
374
+ /**
375
+ * Mapped value
376
+ */
377
+ value?: AdditionalProperty.Value;
378
+ }
379
+
380
+ export namespace AdditionalProperty {
381
+ /**
382
+ * Mapped value
383
+ */
384
+ export interface Value {
385
+ example?: Value.Example;
386
+
387
+ /**
388
+ * A simple object to allow referencing other components in the specification,
389
+ * internally and externally. The Reference Object is defined by JSON Reference and
390
+ * follows the same structure, behavior and rules. For this specification,
391
+ * reference resolution is accomplished as defined by the JSON Reference
392
+ * specification and not by the JSON Schema specification.
393
+ */
394
+ reference?: DocumentsAPI.Reference;
395
+ }
396
+
397
+ export namespace Value {
398
+ export interface Example {
399
+ description?: string;
400
+
401
+ externalValue?: string;
402
+
403
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
404
+
405
+ summary?: string;
406
+
407
+ value?: DocumentsAPI.Any;
408
+ }
409
+ }
410
+ }
411
+ }
412
+ }
413
+ }
414
+ }
415
+ }
416
+
417
+ export interface RequestBodies {
418
+ additionalProperties?: Array<RequestBodies.AdditionalProperty>;
419
+ }
420
+
421
+ export namespace RequestBodies {
422
+ /**
423
+ * Automatically-generated message used to represent maps of RequestBodyOrReference
424
+ * as ordered (name,value) pairs.
425
+ */
426
+ export interface AdditionalProperty {
427
+ /**
428
+ * Map key
429
+ */
430
+ name?: string;
431
+
432
+ /**
433
+ * Mapped value
434
+ */
435
+ value?: AdditionalProperty.Value;
436
+ }
437
+
438
+ export namespace AdditionalProperty {
439
+ /**
440
+ * Mapped value
441
+ */
442
+ export interface Value {
443
+ /**
444
+ * A simple object to allow referencing other components in the specification,
445
+ * internally and externally. The Reference Object is defined by JSON Reference and
446
+ * follows the same structure, behavior and rules. For this specification,
447
+ * reference resolution is accomplished as defined by the JSON Reference
448
+ * specification and not by the JSON Schema specification.
449
+ */
450
+ reference?: DocumentsAPI.Reference;
451
+
452
+ /**
453
+ * Describes a single request body.
454
+ */
455
+ requestBody?: Value.RequestBody;
456
+ }
457
+
458
+ export namespace Value {
459
+ /**
460
+ * Describes a single request body.
461
+ */
462
+ export interface RequestBody {
463
+ content?: DocumentsAPI.MediaTypes;
464
+
465
+ description?: string;
466
+
467
+ required?: boolean;
468
+
469
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
470
+ }
471
+ }
472
+ }
473
+ }
474
+
475
+ export interface Responses {
476
+ additionalProperties?: Array<Responses.AdditionalProperty>;
477
+ }
478
+
479
+ export namespace Responses {
480
+ /**
481
+ * Automatically-generated message used to represent maps of ResponseOrReference as
482
+ * ordered (name,value) pairs.
483
+ */
484
+ export interface AdditionalProperty {
485
+ /**
486
+ * Map key
487
+ */
488
+ name?: string;
489
+
490
+ /**
491
+ * Mapped value
492
+ */
493
+ value?: AdditionalProperty.Value;
494
+ }
495
+
496
+ export namespace AdditionalProperty {
497
+ /**
498
+ * Mapped value
499
+ */
500
+ export interface Value {
501
+ /**
502
+ * A simple object to allow referencing other components in the specification,
503
+ * internally and externally. The Reference Object is defined by JSON Reference and
504
+ * follows the same structure, behavior and rules. For this specification,
505
+ * reference resolution is accomplished as defined by the JSON Reference
506
+ * specification and not by the JSON Schema specification.
507
+ */
508
+ reference?: DocumentsAPI.Reference;
509
+
510
+ /**
511
+ * Describes a single response from an API Operation, including design-time, static
512
+ * `links` to operations based on the response.
513
+ */
514
+ response?: Value.Response;
515
+ }
516
+
517
+ export namespace Value {
518
+ /**
519
+ * Describes a single response from an API Operation, including design-time, static
520
+ * `links` to operations based on the response.
521
+ */
522
+ export interface Response {
523
+ content?: DocumentsAPI.MediaTypes;
524
+
525
+ description?: string;
526
+
527
+ headers?: DocumentsAPI.HeadersOrReferences;
528
+
529
+ links?: Response.Links;
530
+
531
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
532
+ }
533
+
534
+ export namespace Response {
535
+ export interface Links {
536
+ additionalProperties?: Array<Links.AdditionalProperty>;
537
+ }
538
+
539
+ export namespace Links {
540
+ /**
541
+ * Automatically-generated message used to represent maps of LinkOrReference as
542
+ * ordered (name,value) pairs.
543
+ */
544
+ export interface AdditionalProperty {
545
+ /**
546
+ * Map key
547
+ */
548
+ name?: string;
549
+
550
+ /**
551
+ * Mapped value
552
+ */
553
+ value?: AdditionalProperty.Value;
554
+ }
555
+
556
+ export namespace AdditionalProperty {
557
+ /**
558
+ * Mapped value
559
+ */
560
+ export interface Value {
561
+ /**
562
+ * The `Link object` represents a possible design-time link for a response. The
563
+ * presence of a link does not guarantee the caller's ability to successfully
564
+ * invoke it, rather it provides a known relationship and traversal mechanism
565
+ * between responses and other operations. Unlike _dynamic_ links (i.e. links
566
+ * provided **in** the response payload), the OAS linking mechanism does not
567
+ * require link information in the runtime response. For computing links, and
568
+ * providing instructions to execute them, a runtime expression is used for
569
+ * accessing values in an operation and using them as parameters while invoking the
570
+ * linked operation.
571
+ */
572
+ link?: Value.Link;
573
+
574
+ /**
575
+ * A simple object to allow referencing other components in the specification,
576
+ * internally and externally. The Reference Object is defined by JSON Reference and
577
+ * follows the same structure, behavior and rules. For this specification,
578
+ * reference resolution is accomplished as defined by the JSON Reference
579
+ * specification and not by the JSON Schema specification.
580
+ */
581
+ reference?: DocumentsAPI.Reference;
582
+ }
583
+
584
+ export namespace Value {
585
+ /**
586
+ * The `Link object` represents a possible design-time link for a response. The
587
+ * presence of a link does not guarantee the caller's ability to successfully
588
+ * invoke it, rather it provides a known relationship and traversal mechanism
589
+ * between responses and other operations. Unlike _dynamic_ links (i.e. links
590
+ * provided **in** the response payload), the OAS linking mechanism does not
591
+ * require link information in the runtime response. For computing links, and
592
+ * providing instructions to execute them, a runtime expression is used for
593
+ * accessing values in an operation and using them as parameters while invoking the
594
+ * linked operation.
595
+ */
596
+ export interface Link {
597
+ description?: string;
598
+
599
+ operationId?: string;
600
+
601
+ operationRef?: string;
602
+
603
+ parameters?: DocumentsAPI.AnyOrExpression;
604
+
605
+ requestBody?: DocumentsAPI.AnyOrExpression;
606
+
607
+ /**
608
+ * An object representing a Server.
609
+ */
610
+ server?: DocumentsAPI.Server;
611
+
612
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
613
+ }
614
+ }
615
+ }
616
+ }
617
+ }
618
+ }
619
+ }
620
+ }
621
+
622
+ export interface Schemas {
623
+ additionalProperties?: Array<DocumentsAPI.NamedSchemaOrReference>;
624
+ }
625
+
626
+ export interface SecuritySchemes {
627
+ additionalProperties?: Array<SecuritySchemes.AdditionalProperty>;
628
+ }
629
+
630
+ export namespace SecuritySchemes {
631
+ /**
632
+ * Automatically-generated message used to represent maps of
633
+ * SecuritySchemeOrReference as ordered (name,value) pairs.
634
+ */
635
+ export interface AdditionalProperty {
636
+ /**
637
+ * Map key
638
+ */
639
+ name?: string;
640
+
641
+ /**
642
+ * Mapped value
643
+ */
644
+ value?: AdditionalProperty.Value;
645
+ }
646
+
647
+ export namespace AdditionalProperty {
648
+ /**
649
+ * Mapped value
650
+ */
651
+ export interface Value {
652
+ /**
653
+ * A simple object to allow referencing other components in the specification,
654
+ * internally and externally. The Reference Object is defined by JSON Reference and
655
+ * follows the same structure, behavior and rules. For this specification,
656
+ * reference resolution is accomplished as defined by the JSON Reference
657
+ * specification and not by the JSON Schema specification.
658
+ */
659
+ reference?: DocumentsAPI.Reference;
660
+
661
+ /**
662
+ * Defines a security scheme that can be used by the operations. Supported schemes
663
+ * are HTTP authentication, an API key (either as a header, a cookie parameter or
664
+ * as a query parameter), mutual TLS (use of a client certificate), OAuth2's common
665
+ * flows (implicit, password, application and access code) as defined in RFC6749,
666
+ * and OpenID Connect. Please note that currently (2019) the implicit flow is about
667
+ * to be deprecated OAuth 2.0 Security Best Current Practice. Recommended for most
668
+ * use case is Authorization Code Grant flow with PKCE.
669
+ */
670
+ securityScheme?: Value.SecurityScheme;
671
+ }
672
+
673
+ export namespace Value {
674
+ /**
675
+ * Defines a security scheme that can be used by the operations. Supported schemes
676
+ * are HTTP authentication, an API key (either as a header, a cookie parameter or
677
+ * as a query parameter), mutual TLS (use of a client certificate), OAuth2's common
678
+ * flows (implicit, password, application and access code) as defined in RFC6749,
679
+ * and OpenID Connect. Please note that currently (2019) the implicit flow is about
680
+ * to be deprecated OAuth 2.0 Security Best Current Practice. Recommended for most
681
+ * use case is Authorization Code Grant flow with PKCE.
682
+ */
683
+ export interface SecurityScheme {
684
+ bearerFormat?: string;
685
+
686
+ description?: string;
687
+
688
+ /**
689
+ * Allows configuration of the supported OAuth Flows.
690
+ */
691
+ flows?: SecurityScheme.Flows;
692
+
693
+ in?: string;
694
+
695
+ name?: string;
696
+
697
+ openIdConnectUrl?: string;
698
+
699
+ scheme?: string;
700
+
701
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
702
+
703
+ type?: string;
704
+ }
705
+
706
+ export namespace SecurityScheme {
707
+ /**
708
+ * Allows configuration of the supported OAuth Flows.
709
+ */
710
+ export interface Flows {
711
+ /**
712
+ * Configuration details for a supported OAuth Flow
713
+ */
714
+ authorizationCode?: DocumentsAPI.OAuthFlow;
715
+
716
+ /**
717
+ * Configuration details for a supported OAuth Flow
718
+ */
719
+ clientCredentials?: DocumentsAPI.OAuthFlow;
720
+
721
+ /**
722
+ * Configuration details for a supported OAuth Flow
723
+ */
724
+ implicit?: DocumentsAPI.OAuthFlow;
725
+
726
+ /**
727
+ * Configuration details for a supported OAuth Flow
728
+ */
729
+ password?: DocumentsAPI.OAuthFlow;
730
+
731
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
732
+ }
733
+ }
734
+ }
735
+ }
736
+ }
737
+ }
738
+
739
+ /**
740
+ * Allows referencing an external resource for extended documentation.
741
+ */
742
+ export interface ExternalDocs {
743
+ description?: string;
744
+
745
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
746
+
747
+ url?: string;
748
+ }
749
+
750
+ /**
751
+ * The object provides metadata about the API. The metadata MAY be used by the
752
+ * clients if needed, and MAY be presented in editing or documentation generation
753
+ * tools for convenience.
754
+ */
755
+ export interface Info {
756
+ /**
757
+ * Contact information for the exposed API.
758
+ */
759
+ contact?: Info.Contact;
760
+
761
+ description?: string;
762
+
763
+ /**
764
+ * License information for the exposed API.
765
+ */
766
+ license?: Info.License;
767
+
768
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
769
+
770
+ summary?: string;
771
+
772
+ termsOfService?: string;
773
+
774
+ title?: string;
775
+
776
+ version?: string;
777
+ }
778
+
779
+ export namespace Info {
780
+ /**
781
+ * Contact information for the exposed API.
782
+ */
783
+ export interface Contact {
784
+ email?: string;
785
+
786
+ name?: string;
787
+
788
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
789
+
790
+ url?: string;
791
+ }
792
+
793
+ /**
794
+ * License information for the exposed API.
795
+ */
796
+ export interface License {
797
+ name?: string;
798
+
799
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
800
+
801
+ url?: string;
802
+ }
803
+ }
804
+
805
+ /**
806
+ * Holds the relative paths to the individual endpoints and their operations. The
807
+ * path is appended to the URL from the `Server Object` in order to construct the
808
+ * full URL. The Paths MAY be empty, due to ACL constraints.
809
+ */
810
+ export interface Paths {
811
+ path?: Array<DocumentsAPI.NamedPathItem>;
812
+
813
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
814
+ }
815
+
816
+ /**
817
+ * Lists the required security schemes to execute this operation. The name used for
818
+ * each property MUST correspond to a security scheme declared in the Security
819
+ * Schemes under the Components Object. Security Requirement Objects that contain
820
+ * multiple schemes require that all schemes MUST be satisfied for a request to be
821
+ * authorized. This enables support for scenarios where multiple query parameters
822
+ * or HTTP headers are required to convey security information. When a list of
823
+ * Security Requirement Objects is defined on the OpenAPI Object or Operation
824
+ * Object, only one of the Security Requirement Objects in the list needs to be
825
+ * satisfied to authorize the request.
826
+ */
827
+ export interface Security {
828
+ additionalProperties?: Array<Security.AdditionalProperty>;
829
+ }
830
+
831
+ export namespace Security {
832
+ /**
833
+ * Automatically-generated message used to represent maps of StringArray as ordered
834
+ * (name,value) pairs.
835
+ */
836
+ export interface AdditionalProperty {
837
+ /**
838
+ * Map key
839
+ */
840
+ name?: string;
841
+
842
+ /**
843
+ * Mapped value
844
+ */
845
+ value?: AdditionalProperty.Value;
846
+ }
847
+
848
+ export namespace AdditionalProperty {
849
+ /**
850
+ * Mapped value
851
+ */
852
+ export interface Value {
853
+ value?: Array<string>;
854
+ }
855
+ }
856
+ }
857
+
858
+ /**
859
+ * Adds metadata to a single tag that is used by the Operation Object. It is not
860
+ * mandatory to have a Tag Object per tag defined in the Operation Object
861
+ * instances.
862
+ */
863
+ export interface Tag {
864
+ description?: string;
865
+
866
+ /**
867
+ * Allows referencing an external resource for extended documentation.
868
+ */
869
+ externalDocs?: Tag.ExternalDocs;
870
+
871
+ name?: string;
872
+
873
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
874
+ }
875
+
876
+ export namespace Tag {
877
+ /**
878
+ * Allows referencing an external resource for extended documentation.
879
+ */
880
+ export interface ExternalDocs {
881
+ description?: string;
882
+
883
+ specificationExtension?: Array<DocumentsAPI.NamedAny>;
884
+
885
+ url?: string;
886
+ }
887
+ }
888
+ }
889
+
890
+ /**
891
+ * DocumentSpec defines the content and properties of a document.
892
+ */
893
+ export interface DocumentSpec {
894
+ /**
895
+ * InlineContent represents content stored directly in the document.
896
+ */
897
+ inlineContent?: DocumentSpecInlineContent;
898
+
899
+ /**
900
+ * RemoteSource represents a reference to an external document.
901
+ */
902
+ remoteSource?: DocumentSpecRemoteSource;
903
+
904
+ /**
905
+ * Status of the document
906
+ */
907
+ status?:
908
+ | 'DOCUMENT_STATUS_UNSPECIFIED'
909
+ | 'DOCUMENT_STATUS_ENABLED'
910
+ | 'DOCUMENT_STATUS_DISABLED'
911
+ | 'DOCUMENT_STATUS_ARCHIVED';
912
+
913
+ /**
914
+ * Human-readable summary of what this document contains
915
+ */
916
+ summary?: string;
917
+
918
+ /**
919
+ * The type of document being stored
920
+ */
921
+ type?:
922
+ | 'DOCUMENT_TYPE_UNSPECIFIED'
923
+ | 'DOCUMENT_TYPE_EPISODIC'
924
+ | 'DOCUMENT_TYPE_SEMANTIC'
925
+ | 'DOCUMENT_TYPE_PROCEDURAL';
926
+ }
927
+
928
+ /**
929
+ * InlineContent represents content stored directly in the document.
930
+ */
931
+ export interface DocumentSpecInlineContent {
932
+ /**
933
+ * The actual content of the document
934
+ */
935
+ content?: string;
936
+
937
+ /**
938
+ * Length of the content in bytes (computed automatically)
939
+ */
940
+ length?: number;
941
+
942
+ /**
943
+ * MIME type of the content (e.g., "text/plain", "application/pdf")
944
+ */
945
+ mimeType?: string;
946
+ }
947
+
948
+ /**
949
+ * RemoteSource represents a reference to an external document.
950
+ */
951
+ export interface DocumentSpecRemoteSource {
952
+ /**
953
+ * HTTP headers to include when fetching the remote source. Useful for
954
+ * authentication, content negotiation, etc.
955
+ */
956
+ headers?: { [key: string]: string };
957
+
958
+ /**
959
+ * HTTP method to use when fetching the remote source (e.g., "GET", "POST").
960
+ * Defaults to GET if not specified.
961
+ */
962
+ method?: string;
963
+
964
+ /**
965
+ * URL pointing to the remote source
966
+ */
967
+ url?: string;
968
+ }
969
+
970
+ export interface Expression {
971
+ additionalProperties?: Array<NamedAny>;
972
+ }
973
+
974
+ /**
975
+ * Contains an arbitrary serialized message along with a @type that describes the
976
+ * type of the serialized message.
977
+ */
978
+ export interface GoogleProtobufAny {
979
+ /**
980
+ * The type of the serialized message.
981
+ */
982
+ '@type'?: string;
983
+
984
+ [k: string]: unknown;
985
+ }
986
+
987
+ export interface HeadersOrReferences {
988
+ additionalProperties?: Array<unknown>;
989
+ }
990
+
991
+ export interface MediaTypes {
992
+ additionalProperties?: Array<unknown>;
993
+ }
994
+
995
+ /**
996
+ * Automatically-generated message used to represent maps of Any as ordered
997
+ * (name,value) pairs.
998
+ */
999
+ export interface NamedAny {
1000
+ /**
1001
+ * Map key
1002
+ */
1003
+ name?: string;
1004
+
1005
+ /**
1006
+ * Mapped value
1007
+ */
1008
+ value?: Any;
1009
+ }
1010
+
1011
+ /**
1012
+ * Automatically-generated message used to represent maps of PathItem as ordered
1013
+ * (name,value) pairs.
1014
+ */
1015
+ export interface NamedPathItem {
1016
+ /**
1017
+ * Map key
1018
+ */
1019
+ name?: string;
1020
+
1021
+ /**
1022
+ * Describes the operations available on a single path. A Path Item MAY be empty,
1023
+ * due to ACL constraints. The path itself is still exposed to the documentation
1024
+ * viewer but they will not know which operations and parameters are available.
1025
+ */
1026
+ value?: unknown;
1027
+ }
1028
+
1029
+ /**
1030
+ * Automatically-generated message used to represent maps of SchemaOrReference as
1031
+ * ordered (name,value) pairs.
1032
+ */
1033
+ export interface NamedSchemaOrReference {
1034
+ /**
1035
+ * Map key
1036
+ */
1037
+ name?: string;
1038
+
1039
+ /**
1040
+ * Mapped value
1041
+ */
1042
+ value?: SchemaOrReference;
1043
+ }
1044
+
1045
+ /**
1046
+ * Automatically-generated message used to represent maps of ServerVariable as
1047
+ * ordered (name,value) pairs.
1048
+ */
1049
+ export interface NamedServerVariable {
1050
+ /**
1051
+ * Map key
1052
+ */
1053
+ name?: string;
1054
+
1055
+ /**
1056
+ * An object representing a Server Variable for server URL template substitution.
1057
+ */
1058
+ value?: ServerVariable;
1059
+ }
1060
+
1061
+ /**
1062
+ * Automatically-generated message used to represent maps of string as ordered
1063
+ * (name,value) pairs.
1064
+ */
1065
+ export interface NamedString {
1066
+ /**
1067
+ * Map key
1068
+ */
1069
+ name?: string;
1070
+
1071
+ /**
1072
+ * Mapped value
1073
+ */
1074
+ value?: string;
1075
+ }
1076
+
1077
+ /**
1078
+ * Configuration details for a supported OAuth Flow
1079
+ */
1080
+ export interface OAuthFlow {
1081
+ authorizationUrl?: string;
1082
+
1083
+ refreshUrl?: string;
1084
+
1085
+ scopes?: Strings;
1086
+
1087
+ specificationExtension?: Array<NamedAny>;
1088
+
1089
+ tokenUrl?: string;
1090
+ }
1091
+
1092
+ /**
1093
+ * A simple object to allow referencing other components in the specification,
1094
+ * internally and externally. The Reference Object is defined by JSON Reference and
1095
+ * follows the same structure, behavior and rules. For this specification,
1096
+ * reference resolution is accomplished as defined by the JSON Reference
1097
+ * specification and not by the JSON Schema specification.
1098
+ */
1099
+ export interface Reference {
1100
+ description?: string;
1101
+
1102
+ Ref?: string;
1103
+
1104
+ summary?: string;
1105
+ }
1106
+
1107
+ export interface SchemaOrReference {
1108
+ /**
1109
+ * A simple object to allow referencing other components in the specification,
1110
+ * internally and externally. The Reference Object is defined by JSON Reference and
1111
+ * follows the same structure, behavior and rules. For this specification,
1112
+ * reference resolution is accomplished as defined by the JSON Reference
1113
+ * specification and not by the JSON Schema specification.
1114
+ */
1115
+ reference?: Reference;
1116
+
1117
+ /**
1118
+ * The Schema Object allows the definition of input and output data types. These
1119
+ * types can be objects, but also primitives and arrays. This object is an extended
1120
+ * subset of the JSON Schema Specification Wright Draft 00. For more information
1121
+ * about the properties, see JSON Schema Core and JSON Schema Validation. Unless
1122
+ * stated otherwise, the property definitions follow the JSON Schema.
1123
+ */
1124
+ schema?: unknown;
1125
+ }
1126
+
1127
+ /**
1128
+ * An object representing a Server.
1129
+ */
1130
+ export interface Server {
1131
+ description?: string;
1132
+
1133
+ specificationExtension?: Array<NamedAny>;
1134
+
1135
+ url?: string;
1136
+
1137
+ variables?: ServerVariables;
1138
+ }
1139
+
1140
+ /**
1141
+ * An object representing a Server Variable for server URL template substitution.
1142
+ */
1143
+ export interface ServerVariable {
1144
+ default?: string;
1145
+
1146
+ description?: string;
1147
+
1148
+ enum?: Array<string>;
1149
+
1150
+ specificationExtension?: Array<NamedAny>;
1151
+ }
1152
+
1153
+ export interface ServerVariables {
1154
+ additionalProperties?: Array<NamedServerVariable>;
1155
+ }
1156
+
1157
+ export interface Strings {
1158
+ additionalProperties?: Array<NamedString>;
1159
+ }
1160
+
1161
+ export interface DocumentCreateParams {
1162
+ /**
1163
+ * Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
1164
+ */
1165
+ metadata?: Shared.ResourceMetadata;
1166
+
1167
+ /**
1168
+ * The namespace this document belongs to. Each document belongs to exactly one
1169
+ * namespace.
1170
+ */
1171
+ namespaceId?: string;
1172
+
1173
+ /**
1174
+ * DocumentSpec defines the content and properties of a document.
1175
+ */
1176
+ spec?: DocumentSpec;
1177
+ }
1178
+
1179
+ export interface DocumentUpdateParams {
1180
+ /**
1181
+ * Unique identifier of the document to update
1182
+ */
1183
+ body_id?: string;
1184
+
1185
+ /**
1186
+ * Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
1187
+ */
1188
+ metadata?: Shared.ResourceMetadata;
1189
+
1190
+ /**
1191
+ * DocumentSpec defines the content and properties of a document.
1192
+ */
1193
+ spec?: DocumentSpec;
1194
+
1195
+ /**
1196
+ * Fields to update (if empty, all fields are updated)
1197
+ */
1198
+ updateMask?: string;
1199
+ }
1200
+
1201
+ export interface DocumentListParams extends CursorPaginationParams {
1202
+ /**
1203
+ * Optional: Filter documents by namespace ID. If provided, only returns documents
1204
+ * that belong to this namespace.
1205
+ */
1206
+ namespaceId?: string;
1207
+ }
1208
+
1209
+ export declare namespace Documents {
1210
+ export {
1211
+ type Any as Any,
1212
+ type AnyOrExpression as AnyOrExpression,
1213
+ type CallbacksOrReferences as CallbacksOrReferences,
1214
+ type Document as Document,
1215
+ type DocumentSpec as DocumentSpec,
1216
+ type DocumentSpecInlineContent as DocumentSpecInlineContent,
1217
+ type DocumentSpecRemoteSource as DocumentSpecRemoteSource,
1218
+ type Expression as Expression,
1219
+ type GoogleProtobufAny as GoogleProtobufAny,
1220
+ type HeadersOrReferences as HeadersOrReferences,
1221
+ type MediaTypes as MediaTypes,
1222
+ type NamedAny as NamedAny,
1223
+ type NamedPathItem as NamedPathItem,
1224
+ type NamedSchemaOrReference as NamedSchemaOrReference,
1225
+ type NamedServerVariable as NamedServerVariable,
1226
+ type NamedString as NamedString,
1227
+ type OAuthFlow as OAuthFlow,
1228
+ type Reference as Reference,
1229
+ type SchemaOrReference as SchemaOrReference,
1230
+ type Server as Server,
1231
+ type ServerVariable as ServerVariable,
1232
+ type ServerVariables as ServerVariables,
1233
+ type Strings as Strings,
1234
+ type DocumentsCursorPagination as DocumentsCursorPagination,
1235
+ type DocumentCreateParams as DocumentCreateParams,
1236
+ type DocumentUpdateParams as DocumentUpdateParams,
1237
+ type DocumentListParams as DocumentListParams,
1238
+ };
1239
+ }