@inconvoai/node 0.3.1 → 0.5.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 (267) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/README.md +54 -22
  3. package/client.d.mts +0 -9
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +0 -9
  6. package/client.d.ts.map +1 -1
  7. package/client.js +0 -9
  8. package/client.js.map +1 -1
  9. package/client.mjs +0 -9
  10. package/client.mjs.map +1 -1
  11. package/index.d.mts +1 -1
  12. package/index.d.ts +1 -1
  13. package/package.json +1 -1
  14. package/resources/agents/agents.d.mts +12 -0
  15. package/resources/agents/agents.d.mts.map +1 -1
  16. package/resources/agents/agents.d.ts +12 -0
  17. package/resources/agents/agents.d.ts.map +1 -1
  18. package/resources/agents/agents.js +12 -0
  19. package/resources/agents/agents.js.map +1 -1
  20. package/resources/agents/agents.mjs +12 -0
  21. package/resources/agents/agents.mjs.map +1 -1
  22. package/resources/{conversations → agents/conversations}/conversations.d.mts +59 -10
  23. package/resources/agents/conversations/conversations.d.mts.map +1 -0
  24. package/resources/{conversations → agents/conversations}/conversations.d.ts +59 -10
  25. package/resources/agents/conversations/conversations.d.ts.map +1 -0
  26. package/resources/agents/conversations/conversations.js +64 -0
  27. package/resources/agents/conversations/conversations.js.map +1 -0
  28. package/resources/agents/conversations/conversations.mjs +59 -0
  29. package/resources/agents/conversations/conversations.mjs.map +1 -0
  30. package/resources/{conversations → agents/conversations}/index.d.mts +1 -1
  31. package/resources/agents/conversations/index.d.mts.map +1 -0
  32. package/resources/{conversations → agents/conversations}/index.d.ts +1 -1
  33. package/resources/agents/conversations/index.d.ts.map +1 -0
  34. package/resources/agents/conversations/index.js.map +1 -0
  35. package/resources/agents/conversations/index.mjs.map +1 -0
  36. package/resources/{conversations → agents/conversations}/response/feedback.d.mts +39 -5
  37. package/resources/agents/conversations/response/feedback.d.mts.map +1 -0
  38. package/resources/{conversations → agents/conversations}/response/feedback.d.ts +39 -5
  39. package/resources/agents/conversations/response/feedback.d.ts.map +1 -0
  40. package/resources/agents/conversations/response/feedback.js +50 -0
  41. package/resources/agents/conversations/response/feedback.js.map +1 -0
  42. package/resources/agents/conversations/response/feedback.mjs +46 -0
  43. package/resources/agents/conversations/response/feedback.mjs.map +1 -0
  44. package/resources/agents/conversations/response/index.d.mts.map +1 -0
  45. package/resources/agents/conversations/response/index.d.ts.map +1 -0
  46. package/resources/agents/conversations/response/index.js.map +1 -0
  47. package/resources/agents/conversations/response/index.mjs.map +1 -0
  48. package/resources/{conversations → agents/conversations}/response/response.d.mts +41 -9
  49. package/resources/agents/conversations/response/response.d.mts.map +1 -0
  50. package/resources/{conversations → agents/conversations}/response/response.d.ts +41 -9
  51. package/resources/agents/conversations/response/response.d.ts.map +1 -0
  52. package/resources/{conversations → agents/conversations}/response/response.js +24 -11
  53. package/resources/agents/conversations/response/response.js.map +1 -0
  54. package/resources/{conversations → agents/conversations}/response/response.mjs +23 -10
  55. package/resources/agents/conversations/response/response.mjs.map +1 -0
  56. package/resources/agents/conversations/response.d.mts.map +1 -0
  57. package/resources/agents/conversations/response.d.ts.map +1 -0
  58. package/resources/{conversations → agents/conversations}/response.js +1 -1
  59. package/resources/agents/conversations/response.js.map +1 -0
  60. package/resources/agents/conversations/response.mjs.map +1 -0
  61. package/resources/agents/conversations.d.mts.map +1 -0
  62. package/resources/agents/conversations.d.ts.map +1 -0
  63. package/resources/{conversations.js → agents/conversations.js} +1 -1
  64. package/resources/agents/conversations.js.map +1 -0
  65. package/resources/agents/conversations.mjs.map +1 -0
  66. package/resources/agents/data-summary.d.mts +7 -1
  67. package/resources/agents/data-summary.d.mts.map +1 -1
  68. package/resources/agents/data-summary.d.ts +7 -1
  69. package/resources/agents/data-summary.d.ts.map +1 -1
  70. package/resources/agents/data-summary.js +9 -2
  71. package/resources/agents/data-summary.js.map +1 -1
  72. package/resources/agents/data-summary.mjs +9 -2
  73. package/resources/agents/data-summary.mjs.map +1 -1
  74. package/resources/agents/datasets/context.d.mts +115 -0
  75. package/resources/agents/datasets/context.d.mts.map +1 -0
  76. package/resources/agents/datasets/context.d.ts +115 -0
  77. package/resources/agents/datasets/context.d.ts.map +1 -0
  78. package/resources/agents/datasets/context.js +64 -0
  79. package/resources/agents/datasets/context.js.map +1 -0
  80. package/resources/agents/datasets/context.mjs +60 -0
  81. package/resources/agents/datasets/context.mjs.map +1 -0
  82. package/resources/agents/datasets/datasets.d.mts +14 -0
  83. package/resources/agents/datasets/datasets.d.mts.map +1 -0
  84. package/resources/agents/datasets/datasets.d.ts +14 -0
  85. package/resources/agents/datasets/datasets.d.ts.map +1 -0
  86. package/resources/agents/datasets/datasets.js +21 -0
  87. package/resources/agents/datasets/datasets.js.map +1 -0
  88. package/resources/agents/datasets/datasets.mjs +16 -0
  89. package/resources/agents/datasets/datasets.mjs.map +1 -0
  90. package/resources/agents/datasets/index.d.mts +4 -0
  91. package/resources/agents/datasets/index.d.mts.map +1 -0
  92. package/resources/agents/datasets/index.d.ts +4 -0
  93. package/resources/agents/datasets/index.d.ts.map +1 -0
  94. package/resources/agents/datasets/index.js +11 -0
  95. package/resources/agents/datasets/index.js.map +1 -0
  96. package/resources/agents/datasets/index.mjs +5 -0
  97. package/resources/agents/datasets/index.mjs.map +1 -0
  98. package/resources/agents/datasets/user.d.mts +98 -0
  99. package/resources/agents/datasets/user.d.mts.map +1 -0
  100. package/resources/agents/datasets/user.d.ts +98 -0
  101. package/resources/agents/datasets/user.d.ts.map +1 -0
  102. package/resources/agents/datasets/user.js +59 -0
  103. package/resources/agents/datasets/user.js.map +1 -0
  104. package/resources/agents/datasets/user.mjs +55 -0
  105. package/resources/agents/datasets/user.mjs.map +1 -0
  106. package/resources/agents/datasets.d.mts +2 -0
  107. package/resources/agents/datasets.d.mts.map +1 -0
  108. package/resources/agents/datasets.d.ts +2 -0
  109. package/resources/agents/datasets.d.ts.map +1 -0
  110. package/resources/agents/datasets.js +6 -0
  111. package/resources/agents/datasets.js.map +1 -0
  112. package/resources/agents/datasets.mjs +3 -0
  113. package/resources/agents/datasets.mjs.map +1 -0
  114. package/resources/agents/index.d.mts +3 -0
  115. package/resources/agents/index.d.mts.map +1 -1
  116. package/resources/agents/index.d.ts +3 -0
  117. package/resources/agents/index.d.ts.map +1 -1
  118. package/resources/agents/index.js +7 -1
  119. package/resources/agents/index.js.map +1 -1
  120. package/resources/agents/index.mjs +3 -0
  121. package/resources/agents/index.mjs.map +1 -1
  122. package/resources/agents/mcp-servers/index.d.mts +3 -0
  123. package/resources/agents/mcp-servers/index.d.mts.map +1 -0
  124. package/resources/agents/mcp-servers/index.d.ts +3 -0
  125. package/resources/agents/mcp-servers/index.d.ts.map +1 -0
  126. package/resources/agents/mcp-servers/index.js.map +1 -0
  127. package/resources/agents/mcp-servers/index.mjs.map +1 -0
  128. package/resources/agents/mcp-servers/mcp-servers.d.mts +10 -0
  129. package/resources/agents/mcp-servers/mcp-servers.d.mts.map +1 -0
  130. package/resources/agents/mcp-servers/mcp-servers.d.ts +10 -0
  131. package/resources/agents/mcp-servers/mcp-servers.d.ts.map +1 -0
  132. package/resources/{mcp-servers → agents/mcp-servers}/mcp-servers.js +2 -2
  133. package/resources/agents/mcp-servers/mcp-servers.js.map +1 -0
  134. package/resources/{mcp-servers → agents/mcp-servers}/mcp-servers.mjs +2 -2
  135. package/resources/agents/mcp-servers/mcp-servers.mjs.map +1 -0
  136. package/resources/agents/mcp-servers/tenants.d.mts +79 -0
  137. package/resources/agents/mcp-servers/tenants.d.mts.map +1 -0
  138. package/resources/agents/mcp-servers/tenants.d.ts +79 -0
  139. package/resources/agents/mcp-servers/tenants.d.ts.map +1 -0
  140. package/resources/agents/mcp-servers/tenants.js +50 -0
  141. package/resources/agents/mcp-servers/tenants.js.map +1 -0
  142. package/resources/agents/mcp-servers/tenants.mjs +46 -0
  143. package/resources/agents/mcp-servers/tenants.mjs.map +1 -0
  144. package/resources/agents/mcp-servers.d.mts.map +1 -0
  145. package/resources/agents/mcp-servers.d.ts.map +1 -0
  146. package/resources/{mcp-servers.js → agents/mcp-servers.js} +1 -1
  147. package/resources/agents/mcp-servers.js.map +1 -0
  148. package/resources/agents/mcp-servers.mjs.map +1 -0
  149. package/resources/index.d.mts +0 -3
  150. package/resources/index.d.mts.map +1 -1
  151. package/resources/index.d.ts +0 -3
  152. package/resources/index.d.ts.map +1 -1
  153. package/resources/index.js +1 -7
  154. package/resources/index.js.map +1 -1
  155. package/resources/index.mjs +0 -3
  156. package/resources/index.mjs.map +1 -1
  157. package/src/client.ts +0 -47
  158. package/src/index.ts +1 -1
  159. package/src/resources/agents/agents.ts +36 -0
  160. package/src/resources/{conversations → agents/conversations}/conversations.ts +81 -15
  161. package/src/resources/{conversations → agents/conversations}/index.ts +1 -0
  162. package/src/resources/agents/conversations/response/feedback.ts +121 -0
  163. package/src/resources/{conversations → agents/conversations}/response/response.ts +56 -17
  164. package/src/resources/agents/data-summary.ts +9 -2
  165. package/src/resources/agents/datasets/context.ts +174 -0
  166. package/src/resources/agents/datasets/datasets.ts +53 -0
  167. package/src/resources/agents/datasets/index.ts +21 -0
  168. package/src/resources/agents/datasets/user.ts +151 -0
  169. package/src/resources/agents/datasets.ts +3 -0
  170. package/src/resources/agents/index.ts +12 -0
  171. package/src/resources/{mcp-servers → agents/mcp-servers}/index.ts +1 -0
  172. package/src/resources/{mcp-servers → agents/mcp-servers}/mcp-servers.ts +9 -2
  173. package/src/resources/agents/mcp-servers/tenants.ts +108 -0
  174. package/src/resources/index.ts +0 -19
  175. package/src/version.ts +1 -1
  176. package/version.d.mts +1 -1
  177. package/version.d.ts +1 -1
  178. package/version.js +1 -1
  179. package/version.mjs +1 -1
  180. package/resources/conversations/conversations.d.mts.map +0 -1
  181. package/resources/conversations/conversations.d.ts.map +0 -1
  182. package/resources/conversations/conversations.js +0 -40
  183. package/resources/conversations/conversations.js.map +0 -1
  184. package/resources/conversations/conversations.mjs +0 -35
  185. package/resources/conversations/conversations.mjs.map +0 -1
  186. package/resources/conversations/index.d.mts.map +0 -1
  187. package/resources/conversations/index.d.ts.map +0 -1
  188. package/resources/conversations/index.js.map +0 -1
  189. package/resources/conversations/index.mjs.map +0 -1
  190. package/resources/conversations/response/feedback.d.mts.map +0 -1
  191. package/resources/conversations/response/feedback.d.ts.map +0 -1
  192. package/resources/conversations/response/feedback.js +0 -30
  193. package/resources/conversations/response/feedback.js.map +0 -1
  194. package/resources/conversations/response/feedback.mjs +0 -26
  195. package/resources/conversations/response/feedback.mjs.map +0 -1
  196. package/resources/conversations/response/index.d.mts.map +0 -1
  197. package/resources/conversations/response/index.d.ts.map +0 -1
  198. package/resources/conversations/response/index.js.map +0 -1
  199. package/resources/conversations/response/index.mjs.map +0 -1
  200. package/resources/conversations/response/response.d.mts.map +0 -1
  201. package/resources/conversations/response/response.d.ts.map +0 -1
  202. package/resources/conversations/response/response.js.map +0 -1
  203. package/resources/conversations/response/response.mjs.map +0 -1
  204. package/resources/conversations/response.d.mts.map +0 -1
  205. package/resources/conversations/response.d.ts.map +0 -1
  206. package/resources/conversations/response.js.map +0 -1
  207. package/resources/conversations/response.mjs.map +0 -1
  208. package/resources/conversations.d.mts.map +0 -1
  209. package/resources/conversations.d.ts.map +0 -1
  210. package/resources/conversations.js.map +0 -1
  211. package/resources/conversations.mjs.map +0 -1
  212. package/resources/datasets.d.mts +0 -67
  213. package/resources/datasets.d.mts.map +0 -1
  214. package/resources/datasets.d.ts +0 -67
  215. package/resources/datasets.d.ts.map +0 -1
  216. package/resources/datasets.js +0 -30
  217. package/resources/datasets.js.map +0 -1
  218. package/resources/datasets.mjs +0 -26
  219. package/resources/datasets.mjs.map +0 -1
  220. package/resources/mcp-servers/index.d.mts +0 -3
  221. package/resources/mcp-servers/index.d.mts.map +0 -1
  222. package/resources/mcp-servers/index.d.ts +0 -3
  223. package/resources/mcp-servers/index.d.ts.map +0 -1
  224. package/resources/mcp-servers/index.js.map +0 -1
  225. package/resources/mcp-servers/index.mjs.map +0 -1
  226. package/resources/mcp-servers/mcp-servers.d.mts +0 -10
  227. package/resources/mcp-servers/mcp-servers.d.mts.map +0 -1
  228. package/resources/mcp-servers/mcp-servers.d.ts +0 -10
  229. package/resources/mcp-servers/mcp-servers.d.ts.map +0 -1
  230. package/resources/mcp-servers/mcp-servers.js.map +0 -1
  231. package/resources/mcp-servers/mcp-servers.mjs.map +0 -1
  232. package/resources/mcp-servers/tenants.d.mts +0 -63
  233. package/resources/mcp-servers/tenants.d.mts.map +0 -1
  234. package/resources/mcp-servers/tenants.d.ts +0 -63
  235. package/resources/mcp-servers/tenants.d.ts.map +0 -1
  236. package/resources/mcp-servers/tenants.js +0 -47
  237. package/resources/mcp-servers/tenants.js.map +0 -1
  238. package/resources/mcp-servers/tenants.mjs +0 -43
  239. package/resources/mcp-servers/tenants.mjs.map +0 -1
  240. package/resources/mcp-servers.d.mts.map +0 -1
  241. package/resources/mcp-servers.d.ts.map +0 -1
  242. package/resources/mcp-servers.js.map +0 -1
  243. package/resources/mcp-servers.mjs.map +0 -1
  244. package/src/resources/conversations/response/feedback.ts +0 -85
  245. package/src/resources/datasets.ts +0 -102
  246. package/src/resources/mcp-servers/tenants.ts +0 -81
  247. /package/resources/{conversations → agents/conversations}/index.js +0 -0
  248. /package/resources/{conversations → agents/conversations}/index.mjs +0 -0
  249. /package/resources/{conversations → agents/conversations}/response/index.d.mts +0 -0
  250. /package/resources/{conversations → agents/conversations}/response/index.d.ts +0 -0
  251. /package/resources/{conversations → agents/conversations}/response/index.js +0 -0
  252. /package/resources/{conversations → agents/conversations}/response/index.mjs +0 -0
  253. /package/resources/{conversations → agents/conversations}/response.d.mts +0 -0
  254. /package/resources/{conversations → agents/conversations}/response.d.ts +0 -0
  255. /package/resources/{conversations → agents/conversations}/response.mjs +0 -0
  256. /package/resources/{conversations.d.mts → agents/conversations.d.mts} +0 -0
  257. /package/resources/{conversations.d.ts → agents/conversations.d.ts} +0 -0
  258. /package/resources/{conversations.mjs → agents/conversations.mjs} +0 -0
  259. /package/resources/{mcp-servers → agents/mcp-servers}/index.js +0 -0
  260. /package/resources/{mcp-servers → agents/mcp-servers}/index.mjs +0 -0
  261. /package/resources/{mcp-servers.d.mts → agents/mcp-servers.d.mts} +0 -0
  262. /package/resources/{mcp-servers.d.ts → agents/mcp-servers.d.ts} +0 -0
  263. /package/resources/{mcp-servers.mjs → agents/mcp-servers.mjs} +0 -0
  264. /package/src/resources/{conversations → agents/conversations}/response/index.ts +0 -0
  265. /package/src/resources/{conversations → agents/conversations}/response.ts +0 -0
  266. /package/src/resources/{conversations.ts → agents/conversations.ts} +0 -0
  267. /package/src/resources/{mcp-servers.ts → agents/mcp-servers.ts} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"data-summary.js","sourceRoot":"","sources":["../../src/resources/agents/data-summary.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAIlD,MAAa,WAAY,SAAQ,sBAAW;IAC1C;;OAEG;IACH,QAAQ,CAAC,OAAwB;QAC/B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF;AAPD,kCAOC"}
1
+ {"version":3,"file":"data-summary.js","sourceRoot":"","sources":["../../src/resources/agents/data-summary.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAGlD,uDAAiD;AAEjD,MAAa,WAAY,SAAQ,sBAAW;IAC1C;;;;;;;;OAQG;IACH,QAAQ,CAAC,OAAe,EAAE,OAAwB;QAChD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,OAAO,eAAe,EAAE,OAAO,CAAC,CAAC;IAC1E,CAAC;CACF;AAbD,kCAaC"}
@@ -1,11 +1,18 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
  import { APIResource } from "../../core/resource.mjs";
3
+ import { path } from "../../internal/utils/path.mjs";
3
4
  export class DataSummary extends APIResource {
4
5
  /**
5
6
  * Retrieve a summary of data available to the agent
7
+ *
8
+ * @example
9
+ * ```ts
10
+ * const dataSummary =
11
+ * await client.agents.dataSummary.retrieve('agentId');
12
+ * ```
6
13
  */
7
- retrieve(options) {
8
- return this._client.get('/agents/data-summary', options);
14
+ retrieve(agentID, options) {
15
+ return this._client.get(path `/agents/${agentID}/data-summary`, options);
9
16
  }
10
17
  }
11
18
  //# sourceMappingURL=data-summary.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"data-summary.mjs","sourceRoot":"","sources":["../../src/resources/agents/data-summary.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB,MAAM,OAAO,WAAY,SAAQ,WAAW;IAC1C;;OAEG;IACH,QAAQ,CAAC,OAAwB;QAC/B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,OAAO,CAAC,CAAC;IAC3D,CAAC;CACF"}
1
+ {"version":3,"file":"data-summary.mjs","sourceRoot":"","sources":["../../src/resources/agents/data-summary.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;OAQG;IACH,QAAQ,CAAC,OAAe,EAAE,OAAwB;QAChD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,WAAW,OAAO,eAAe,EAAE,OAAO,CAAC,CAAC;IAC1E,CAAC;CACF"}
@@ -0,0 +1,115 @@
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import { APIPromise } from "../../../core/api-promise.mjs";
3
+ import { type Uploadable } from "../../../core/uploads.mjs";
4
+ import { RequestOptions } from "../../../internal/request-options.mjs";
5
+ export declare class Context extends APIResource {
6
+ /**
7
+ * List all dataset files scoped to a context value. These files are shared with
8
+ * all users who have this context value.
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const contexts = await client.agents.datasets.context.list(
13
+ * 'org_456',
14
+ * { agentId: 'agentId', contextKey: 'orgId' },
15
+ * );
16
+ * ```
17
+ */
18
+ list(contextValue: string, params: ContextListParams, options?: RequestOptions): APIPromise<ContextListResponse>;
19
+ /**
20
+ * Delete a dataset file scoped to a context value.
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const context = await client.agents.datasets.context.delete(
25
+ * 'shared_data.csv',
26
+ * {
27
+ * agentId: 'agentId',
28
+ * contextKey: 'orgId',
29
+ * contextValue: 'org_456',
30
+ * },
31
+ * );
32
+ * ```
33
+ */
34
+ delete(filename: string, params: ContextDeleteParams, options?: RequestOptions): APIPromise<ContextDeleteResponse>;
35
+ /**
36
+ * Upload a dataset file scoped to a context value. This file will be shared with
37
+ * all users who have this context value.
38
+ *
39
+ * @example
40
+ * ```ts
41
+ * const response =
42
+ * await client.agents.datasets.context.upload('org_456', {
43
+ * agentId: 'agentId',
44
+ * contextKey: 'orgId',
45
+ * file: fs.createReadStream('path/to/file'),
46
+ * });
47
+ * ```
48
+ */
49
+ upload(contextValue: string, params: ContextUploadParams, options?: RequestOptions): APIPromise<ContextUploadResponse>;
50
+ }
51
+ export interface ContextListResponse {
52
+ files: Array<string>;
53
+ }
54
+ export interface ContextDeleteResponse {
55
+ file: string;
56
+ success: boolean;
57
+ error?: string;
58
+ }
59
+ export interface ContextUploadResponse {
60
+ file: ContextUploadResponse.File;
61
+ error?: string;
62
+ }
63
+ export declare namespace ContextUploadResponse {
64
+ interface File {
65
+ name: string;
66
+ path: string;
67
+ size: number;
68
+ }
69
+ }
70
+ export interface ContextListParams {
71
+ /**
72
+ * The unique identifier of the agent
73
+ */
74
+ agentId: string;
75
+ /**
76
+ * The context key (e.g., "orgId", "teamId")
77
+ */
78
+ contextKey: string;
79
+ }
80
+ export interface ContextDeleteParams {
81
+ /**
82
+ * The unique identifier of the agent
83
+ */
84
+ agentId: string;
85
+ /**
86
+ * The context key (e.g., "orgId", "teamId")
87
+ */
88
+ contextKey: string;
89
+ /**
90
+ * The context value
91
+ */
92
+ contextValue: string;
93
+ }
94
+ export interface ContextUploadParams {
95
+ /**
96
+ * Path param: The unique identifier of the agent
97
+ */
98
+ agentId: string;
99
+ /**
100
+ * Path param: The context key (e.g., "orgId", "teamId")
101
+ */
102
+ contextKey: string;
103
+ /**
104
+ * Body param: The file to upload (CSV or JSON, max 10MB)
105
+ */
106
+ file: Uploadable;
107
+ /**
108
+ * Body param: Optional notes or description for the dataset
109
+ */
110
+ notes?: string;
111
+ }
112
+ export declare namespace Context {
113
+ export { type ContextListResponse as ContextListResponse, type ContextDeleteResponse as ContextDeleteResponse, type ContextUploadResponse as ContextUploadResponse, type ContextListParams as ContextListParams, type ContextDeleteParams as ContextDeleteParams, type ContextUploadParams as ContextUploadParams, };
114
+ }
115
+ //# sourceMappingURL=context.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.mts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/context.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,KAAK,UAAU,EAAE;OACnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,iBAAiB,EACzB,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,mBAAmB,CAAC;IAKlC;;;;;;;;;;;;;;OAcG;IACH,MAAM,CACJ,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,mBAAmB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,qBAAqB,CAAC;IAQpC;;;;;;;;;;;;;OAaG;IACH,MAAM,CACJ,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,mBAAmB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,qBAAqB,CAAC;CAOrC;AAED,MAAM,W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0,0 +1,115 @@
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import { APIPromise } from "../../../core/api-promise.js";
3
+ import { type Uploadable } from "../../../core/uploads.js";
4
+ import { RequestOptions } from "../../../internal/request-options.js";
5
+ export declare class Context extends APIResource {
6
+ /**
7
+ * List all dataset files scoped to a context value. These files are shared with
8
+ * all users who have this context value.
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const contexts = await client.agents.datasets.context.list(
13
+ * 'org_456',
14
+ * { agentId: 'agentId', contextKey: 'orgId' },
15
+ * );
16
+ * ```
17
+ */
18
+ list(contextValue: string, params: ContextListParams, options?: RequestOptions): APIPromise<ContextListResponse>;
19
+ /**
20
+ * Delete a dataset file scoped to a context value.
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const context = await client.agents.datasets.context.delete(
25
+ * 'shared_data.csv',
26
+ * {
27
+ * agentId: 'agentId',
28
+ * contextKey: 'orgId',
29
+ * contextValue: 'org_456',
30
+ * },
31
+ * );
32
+ * ```
33
+ */
34
+ delete(filename: string, params: ContextDeleteParams, options?: RequestOptions): APIPromise<ContextDeleteResponse>;
35
+ /**
36
+ * Upload a dataset file scoped to a context value. This file will be shared with
37
+ * all users who have this context value.
38
+ *
39
+ * @example
40
+ * ```ts
41
+ * const response =
42
+ * await client.agents.datasets.context.upload('org_456', {
43
+ * agentId: 'agentId',
44
+ * contextKey: 'orgId',
45
+ * file: fs.createReadStream('path/to/file'),
46
+ * });
47
+ * ```
48
+ */
49
+ upload(contextValue: string, params: ContextUploadParams, options?: RequestOptions): APIPromise<ContextUploadResponse>;
50
+ }
51
+ export interface ContextListResponse {
52
+ files: Array<string>;
53
+ }
54
+ export interface ContextDeleteResponse {
55
+ file: string;
56
+ success: boolean;
57
+ error?: string;
58
+ }
59
+ export interface ContextUploadResponse {
60
+ file: ContextUploadResponse.File;
61
+ error?: string;
62
+ }
63
+ export declare namespace ContextUploadResponse {
64
+ interface File {
65
+ name: string;
66
+ path: string;
67
+ size: number;
68
+ }
69
+ }
70
+ export interface ContextListParams {
71
+ /**
72
+ * The unique identifier of the agent
73
+ */
74
+ agentId: string;
75
+ /**
76
+ * The context key (e.g., "orgId", "teamId")
77
+ */
78
+ contextKey: string;
79
+ }
80
+ export interface ContextDeleteParams {
81
+ /**
82
+ * The unique identifier of the agent
83
+ */
84
+ agentId: string;
85
+ /**
86
+ * The context key (e.g., "orgId", "teamId")
87
+ */
88
+ contextKey: string;
89
+ /**
90
+ * The context value
91
+ */
92
+ contextValue: string;
93
+ }
94
+ export interface ContextUploadParams {
95
+ /**
96
+ * Path param: The unique identifier of the agent
97
+ */
98
+ agentId: string;
99
+ /**
100
+ * Path param: The context key (e.g., "orgId", "teamId")
101
+ */
102
+ contextKey: string;
103
+ /**
104
+ * Body param: The file to upload (CSV or JSON, max 10MB)
105
+ */
106
+ file: Uploadable;
107
+ /**
108
+ * Body param: Optional notes or description for the dataset
109
+ */
110
+ notes?: string;
111
+ }
112
+ export declare namespace Context {
113
+ export { type ContextListResponse as ContextListResponse, type ContextDeleteResponse as ContextDeleteResponse, type ContextUploadResponse as ContextUploadResponse, type ContextListParams as ContextListParams, type ContextDeleteParams as ContextDeleteParams, type ContextUploadParams as ContextUploadParams, };
114
+ }
115
+ //# sourceMappingURL=context.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/context.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,KAAK,UAAU,EAAE;OACnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE,iBAAiB,EACzB,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,mBAAmB,CAAC;IAKlC;;;;;;;;;;;;;;OAcG;IACH,MAAM,CACJ,QAAQ,EAAE,MAAM,EA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AAO,CAAC;IAC/B,OAAO,EACL,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -0,0 +1,64 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Context = void 0;
5
+ const resource_1 = require("../../../core/resource.js");
6
+ const uploads_1 = require("../../../internal/uploads.js");
7
+ const path_1 = require("../../../internal/utils/path.js");
8
+ class Context extends resource_1.APIResource {
9
+ /**
10
+ * List all dataset files scoped to a context value. These files are shared with
11
+ * all users who have this context value.
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * const contexts = await client.agents.datasets.context.list(
16
+ * 'org_456',
17
+ * { agentId: 'agentId', contextKey: 'orgId' },
18
+ * );
19
+ * ```
20
+ */
21
+ list(contextValue, params, options) {
22
+ const { agentId, contextKey } = params;
23
+ return this._client.get((0, path_1.path) `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}`, options);
24
+ }
25
+ /**
26
+ * Delete a dataset file scoped to a context value.
27
+ *
28
+ * @example
29
+ * ```ts
30
+ * const context = await client.agents.datasets.context.delete(
31
+ * 'shared_data.csv',
32
+ * {
33
+ * agentId: 'agentId',
34
+ * contextKey: 'orgId',
35
+ * contextValue: 'org_456',
36
+ * },
37
+ * );
38
+ * ```
39
+ */
40
+ delete(filename, params, options) {
41
+ const { agentId, contextKey, contextValue } = params;
42
+ return this._client.delete((0, path_1.path) `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}/${filename}`, options);
43
+ }
44
+ /**
45
+ * Upload a dataset file scoped to a context value. This file will be shared with
46
+ * all users who have this context value.
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * const response =
51
+ * await client.agents.datasets.context.upload('org_456', {
52
+ * agentId: 'agentId',
53
+ * contextKey: 'orgId',
54
+ * file: fs.createReadStream('path/to/file'),
55
+ * });
56
+ * ```
57
+ */
58
+ upload(contextValue, params, options) {
59
+ const { agentId, contextKey, ...body } = params;
60
+ return this._client.post((0, path_1.path) `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}`, (0, uploads_1.multipartFormRequestOptions)({ body, ...options }, this._client));
61
+ }
62
+ }
63
+ exports.Context = Context;
64
+ //# sourceMappingURL=context.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.js","sourceRoot":"","sources":["../../../src/resources/agents/datasets/context.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAIrD,0DAAwE;AACxE,0DAAoD;AAEpD,MAAa,OAAQ,SAAQ,sBAAW;IACtC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,YAAoB,EACpB,MAAyB,EACzB,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IAC5G,CAAC;IAED;;;;;;;;;;;;;;OAcG;IACH,MAAM,CACJ,QAAgB,EAChB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,GAAG,MAAM,CAAC;QACrD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CACxB,IAAA,WAAI,EAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,IAAI,QAAQ,EAAE,EACnF,OAAO,CACR,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;;;OAaG;IACH,MAAM,CACJ,YAAoB,EACpB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QAChD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CACtB,IAAA,WAAI,EAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,EAAE,EACvE,IAAA,qCAA2B,EAAC,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,EAAE,IAAI,CAAC,OAAO,CAAC,CAChE,CAAC;IACJ,CAAC;CACF;AA1ED,0BA0EC"}
@@ -0,0 +1,60 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../../core/resource.mjs";
3
+ import { multipartFormRequestOptions } from "../../../internal/uploads.mjs";
4
+ import { path } from "../../../internal/utils/path.mjs";
5
+ export class Context extends APIResource {
6
+ /**
7
+ * List all dataset files scoped to a context value. These files are shared with
8
+ * all users who have this context value.
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const contexts = await client.agents.datasets.context.list(
13
+ * 'org_456',
14
+ * { agentId: 'agentId', contextKey: 'orgId' },
15
+ * );
16
+ * ```
17
+ */
18
+ list(contextValue, params, options) {
19
+ const { agentId, contextKey } = params;
20
+ return this._client.get(path `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}`, options);
21
+ }
22
+ /**
23
+ * Delete a dataset file scoped to a context value.
24
+ *
25
+ * @example
26
+ * ```ts
27
+ * const context = await client.agents.datasets.context.delete(
28
+ * 'shared_data.csv',
29
+ * {
30
+ * agentId: 'agentId',
31
+ * contextKey: 'orgId',
32
+ * contextValue: 'org_456',
33
+ * },
34
+ * );
35
+ * ```
36
+ */
37
+ delete(filename, params, options) {
38
+ const { agentId, contextKey, contextValue } = params;
39
+ return this._client.delete(path `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}/${filename}`, options);
40
+ }
41
+ /**
42
+ * Upload a dataset file scoped to a context value. This file will be shared with
43
+ * all users who have this context value.
44
+ *
45
+ * @example
46
+ * ```ts
47
+ * const response =
48
+ * await client.agents.datasets.context.upload('org_456', {
49
+ * agentId: 'agentId',
50
+ * contextKey: 'orgId',
51
+ * file: fs.createReadStream('path/to/file'),
52
+ * });
53
+ * ```
54
+ */
55
+ upload(contextValue, params, options) {
56
+ const { agentId, contextKey, ...body } = params;
57
+ return this._client.post(path `/agents/${agentId}/datasets/context/${contextKey}/${contextValue}`, multipartFormRequestOptions({ body, ...options }, this._client));
58
+ }
59
+ }
60
+ //# sourceMappingURL=context.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.mjs","sourceRoot":"","sources":["../../../src/resources/agents/datasets/context.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,2BAA2B,EAAE;OAC/B,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;OAWG;IACH,IAAI,CACF,YAAoB,EACpB,MAAyB,EACzB,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IAC5G,CAAC;IAED;;;;;;;;;;;;;;OAcG;IACH,MAAM,CACJ,QAAgB,EAChB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,GAAG,MAAM,CAAC;QACrD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CACxB,IAAI,CAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,IAAI,QAAQ,EAAE,EACnF,OAAO,CACR,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;;;OAaG;IACH,MAAM,CACJ,YAAoB,EACpB,MAA2B,EAC3B,OAAwB;QAExB,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QAChD,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CACtB,IAAI,CAAA,WAAW,OAAO,qBAAqB,UAAU,IAAI,YAAY,EAAE,EACvE,2BAA2B,CAAC,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,EAAE,IAAI,CAAC,OAAO,CAAC,CAChE,CAAC;IACJ,CAAC;CACF"}
@@ -0,0 +1,14 @@
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import * as ContextAPI from "./context.mjs";
3
+ import { Context, ContextDeleteParams, ContextDeleteResponse, ContextListParams, ContextListResponse, ContextUploadParams, ContextUploadResponse } from "./context.mjs";
4
+ import * as UserAPI from "./user.mjs";
5
+ import { User, UserDeleteParams, UserDeleteResponse, UserListParams, UserListResponse, UserUploadParams, UserUploadResponse } from "./user.mjs";
6
+ export declare class Datasets extends APIResource {
7
+ user: UserAPI.User;
8
+ context: ContextAPI.Context;
9
+ }
10
+ export declare namespace Datasets {
11
+ export { User as User, type UserListResponse as UserListResponse, type UserDeleteResponse as UserDeleteResponse, type UserUploadResponse as UserUploadResponse, type UserListParams as UserListParams, type UserDeleteParams as UserDeleteParams, type UserUploadParams as UserUploadParams, };
12
+ export { Context as Context, type ContextListResponse as ContextListResponse, type ContextDeleteResponse as ContextDeleteResponse, type ContextUploadResponse as ContextUploadResponse, type ContextListParams as ContextListParams, type ContextDeleteParams as ContextDeleteParams, type ContextUploadParams as ContextUploadParams, };
13
+ }
14
+ //# sourceMappingURL=datasets.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"datasets.d.mts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/datasets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,EACL,OAAO,EACP,mBAAmB,EACnB,qBAAqB,EACrB,iBAAiB,EACjB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB;OACM,KAAK,OAAO;OACZ,EACL,IAAI,EACJ,gBAAgB,EAChB,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,gBAAgB,EAChB,kBAAkB,EACnB;AAED,qBAAa,QAAS,SAAQ,WAAW;IACvC,IAAI,EAAE,OAAO,CAAC,IAAI,CAAkC;IACpD,OAAO,EAAE,UAAU,CAAC,OAAO,CAAwC;CACpE;AAKD,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,IAAI,IAAI,IAAI,EACZ,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EACL,OAAO,IAAI,OAAO,EAClB,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -0,0 +1,14 @@
1
+ import { APIResource } from "../../../core/resource.js";
2
+ import * as ContextAPI from "./context.js";
3
+ import { Context, ContextDeleteParams, ContextDeleteResponse, ContextListParams, ContextListResponse, ContextUploadParams, ContextUploadResponse } from "./context.js";
4
+ import * as UserAPI from "./user.js";
5
+ import { User, UserDeleteParams, UserDeleteResponse, UserListParams, UserListResponse, UserUploadParams, UserUploadResponse } from "./user.js";
6
+ export declare class Datasets extends APIResource {
7
+ user: UserAPI.User;
8
+ context: ContextAPI.Context;
9
+ }
10
+ export declare namespace Datasets {
11
+ export { User as User, type UserListResponse as UserListResponse, type UserDeleteResponse as UserDeleteResponse, type UserUploadResponse as UserUploadResponse, type UserListParams as UserListParams, type UserDeleteParams as UserDeleteParams, type UserUploadParams as UserUploadParams, };
12
+ export { Context as Context, type ContextListResponse as ContextListResponse, type ContextDeleteResponse as ContextDeleteResponse, type ContextUploadResponse as ContextUploadResponse, type ContextListParams as ContextListParams, type ContextDeleteParams as ContextDeleteParams, type ContextUploadParams as ContextUploadParams, };
13
+ }
14
+ //# sourceMappingURL=datasets.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"datasets.d.ts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/datasets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,EACL,OAAO,EACP,mBAAmB,EACnB,qBAAqB,EACrB,iBAAiB,EACjB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB;OACM,KAAK,OAAO;OACZ,EACL,IAAI,EACJ,gBAAgB,EAChB,kBAAkB,EAClB,cAAc,EACd,gBAAgB,EAChB,gBAAgB,EAChB,kBAAkB,EACnB;AAED,qBAAa,QAAS,SAAQ,WAAW;IACvC,IAAI,EAAE,OAAO,CAAC,IAAI,CAAkC;IACpD,OAAO,EAAE,UAAU,CAAC,OAAO,CAAwC;CACpE;AAKD,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,IAAI,IAAI,IAAI,EACZ,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,gBAAgB,IAAI,gBAAgB,GAC1C,CAAC;IAEF,OAAO,EACL,OAAO,IAAI,OAAO,EAClB,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Datasets = void 0;
5
+ const tslib_1 = require("../../../internal/tslib.js");
6
+ const resource_1 = require("../../../core/resource.js");
7
+ const ContextAPI = tslib_1.__importStar(require("./context.js"));
8
+ const context_1 = require("./context.js");
9
+ const UserAPI = tslib_1.__importStar(require("./user.js"));
10
+ const user_1 = require("./user.js");
11
+ class Datasets extends resource_1.APIResource {
12
+ constructor() {
13
+ super(...arguments);
14
+ this.user = new UserAPI.User(this._client);
15
+ this.context = new ContextAPI.Context(this._client);
16
+ }
17
+ }
18
+ exports.Datasets = Datasets;
19
+ Datasets.User = user_1.User;
20
+ Datasets.Context = context_1.Context;
21
+ //# sourceMappingURL=datasets.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"datasets.js","sourceRoot":"","sources":["../../../src/resources/agents/datasets/datasets.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AACrD,iEAAwC;AACxC,0CAQmB;AACnB,2DAAkC;AAClC,oCAQgB;AAEhB,MAAa,QAAS,SAAQ,sBAAW;IAAzC;;QACE,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACpD,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACrE,CAAC;CAAA;AAHD,4BAGC;AAED,QAAQ,CAAC,IAAI,GAAG,WAAI,CAAC;AACrB,QAAQ,CAAC,OAAO,GAAG,iBAAO,CAAC"}
@@ -0,0 +1,16 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../../../core/resource.mjs";
3
+ import * as ContextAPI from "./context.mjs";
4
+ import { Context, } from "./context.mjs";
5
+ import * as UserAPI from "./user.mjs";
6
+ import { User, } from "./user.mjs";
7
+ export class Datasets extends APIResource {
8
+ constructor() {
9
+ super(...arguments);
10
+ this.user = new UserAPI.User(this._client);
11
+ this.context = new ContextAPI.Context(this._client);
12
+ }
13
+ }
14
+ Datasets.User = User;
15
+ Datasets.Context = Context;
16
+ //# sourceMappingURL=datasets.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"datasets.mjs","sourceRoot":"","sources":["../../../src/resources/agents/datasets/datasets.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,EACL,OAAO,GAOR;OACM,KAAK,OAAO;OACZ,EACL,IAAI,GAOL;AAED,MAAM,OAAO,QAAS,SAAQ,WAAW;IAAzC;;QACE,SAAI,GAAiB,IAAI,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QACpD,YAAO,GAAuB,IAAI,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IACrE,CAAC;CAAA;AAED,QAAQ,CAAC,IAAI,GAAG,IAAI,CAAC;AACrB,QAAQ,CAAC,OAAO,GAAG,OAAO,CAAC"}
@@ -0,0 +1,4 @@
1
+ export { Context, type ContextListResponse, type ContextDeleteResponse, type ContextUploadResponse, type ContextListParams, type ContextDeleteParams, type ContextUploadParams, } from "./context.mjs";
2
+ export { Datasets } from "./datasets.mjs";
3
+ export { User, type UserListResponse, type UserDeleteResponse, type UserUploadResponse, type UserListParams, type UserDeleteParams, type UserUploadParams, } from "./user.mjs";
4
+ //# sourceMappingURL=index.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/index.ts"],"names":[],"mappings":"OAEO,EACL,OAAO,EACP,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB;OACM,EAAE,QAAQ,EAAE;OACZ,EACL,IAAI,EACJ,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,GACtB"}
@@ -0,0 +1,4 @@
1
+ export { Context, type ContextListResponse, type ContextDeleteResponse, type ContextUploadResponse, type ContextListParams, type ContextDeleteParams, type ContextUploadParams, } from "./context.js";
2
+ export { Datasets } from "./datasets.js";
3
+ export { User, type UserListResponse, type UserDeleteResponse, type UserUploadResponse, type UserListParams, type UserDeleteParams, type UserUploadParams, } from "./user.js";
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/index.ts"],"names":[],"mappings":"OAEO,EACL,OAAO,EACP,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB;OACM,EAAE,QAAQ,EAAE;OACZ,EACL,IAAI,EACJ,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,GACtB"}
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.User = exports.Datasets = exports.Context = void 0;
5
+ var context_1 = require("./context.js");
6
+ Object.defineProperty(exports, "Context", { enumerable: true, get: function () { return context_1.Context; } });
7
+ var datasets_1 = require("./datasets.js");
8
+ Object.defineProperty(exports, "Datasets", { enumerable: true, get: function () { return datasets_1.Datasets; } });
9
+ var user_1 = require("./user.js");
10
+ Object.defineProperty(exports, "User", { enumerable: true, get: function () { return user_1.User; } });
11
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/agents/datasets/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wCAQmB;AAPjB,kGAAA,OAAO,OAAA;AAQT,0CAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,kCAQgB;AAPd,4FAAA,IAAI,OAAA"}
@@ -0,0 +1,5 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ export { Context, } from "./context.mjs";
3
+ export { Datasets } from "./datasets.mjs";
4
+ export { User, } from "./user.mjs";
5
+ //# sourceMappingURL=index.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/agents/datasets/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,OAAO,GAOR;OACM,EAAE,QAAQ,EAAE;OACZ,EACL,IAAI,GAOL"}
@@ -0,0 +1,98 @@
1
+ import { APIResource } from "../../../core/resource.mjs";
2
+ import { APIPromise } from "../../../core/api-promise.mjs";
3
+ import { type Uploadable } from "../../../core/uploads.mjs";
4
+ import { RequestOptions } from "../../../internal/request-options.mjs";
5
+ export declare class User extends APIResource {
6
+ /**
7
+ * List all dataset files scoped to a specific user.
8
+ *
9
+ * @example
10
+ * ```ts
11
+ * const users = await client.agents.datasets.user.list(
12
+ * 'user_123',
13
+ * { agentId: 'agentId' },
14
+ * );
15
+ * ```
16
+ */
17
+ list(userIdentifier: string, params: UserListParams, options?: RequestOptions): APIPromise<UserListResponse>;
18
+ /**
19
+ * Delete a dataset file scoped to a specific user.
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * const user = await client.agents.datasets.user.delete(
24
+ * 'data.csv',
25
+ * { agentId: 'agentId', userIdentifier: 'user_123' },
26
+ * );
27
+ * ```
28
+ */
29
+ delete(filename: string, params: UserDeleteParams, options?: RequestOptions): APIPromise<UserDeleteResponse>;
30
+ /**
31
+ * Upload a dataset file scoped to a specific user.
32
+ *
33
+ * @example
34
+ * ```ts
35
+ * const response = await client.agents.datasets.user.upload(
36
+ * 'user_123',
37
+ * {
38
+ * agentId: 'agentId',
39
+ * file: fs.createReadStream('path/to/file'),
40
+ * },
41
+ * );
42
+ * ```
43
+ */
44
+ upload(userIdentifier: string, params: UserUploadParams, options?: RequestOptions): APIPromise<UserUploadResponse>;
45
+ }
46
+ export interface UserListResponse {
47
+ files: Array<string>;
48
+ }
49
+ export interface UserDeleteResponse {
50
+ file: string;
51
+ success: boolean;
52
+ error?: string;
53
+ }
54
+ export interface UserUploadResponse {
55
+ file: UserUploadResponse.File;
56
+ error?: string;
57
+ }
58
+ export declare namespace UserUploadResponse {
59
+ interface File {
60
+ name: string;
61
+ path: string;
62
+ size: number;
63
+ }
64
+ }
65
+ export interface UserListParams {
66
+ /**
67
+ * The unique identifier of the agent
68
+ */
69
+ agentId: string;
70
+ }
71
+ export interface UserDeleteParams {
72
+ /**
73
+ * The unique identifier of the agent
74
+ */
75
+ agentId: string;
76
+ /**
77
+ * The user identifier
78
+ */
79
+ userIdentifier: string;
80
+ }
81
+ export interface UserUploadParams {
82
+ /**
83
+ * Path param: The unique identifier of the agent
84
+ */
85
+ agentId: string;
86
+ /**
87
+ * Body param: The file to upload (CSV or JSON, max 10MB)
88
+ */
89
+ file: Uploadable;
90
+ /**
91
+ * Body param: Optional notes or description for the dataset
92
+ */
93
+ notes?: string;
94
+ }
95
+ export declare namespace User {
96
+ export { type UserListResponse as UserListResponse, type UserDeleteResponse as UserDeleteResponse, type UserUploadResponse as UserUploadResponse, type UserListParams as UserListParams, type UserDeleteParams as UserDeleteParams, type UserUploadParams as UserUploadParams, };
97
+ }
98
+ //# sourceMappingURL=user.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"user.d.mts","sourceRoot":"","sources":["../../../src/resources/agents/datasets/user.ts"],"names":[],"mappings":"O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