mavenagi 1.0.5 → 1.0.6

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 (341) hide show
  1. package/Client.d.ts +3 -0
  2. package/Client.js +17 -12
  3. package/README.md +30 -13
  4. package/api/resources/actions/client/Client.js +3 -3
  5. package/api/resources/analytics/client/Client.d.ts +78 -0
  6. package/api/resources/analytics/client/Client.js +174 -0
  7. package/api/resources/analytics/client/index.d.ts +1 -0
  8. package/api/resources/analytics/client/index.js +2 -0
  9. package/api/resources/analytics/index.d.ts +2 -0
  10. package/api/resources/analytics/index.js +18 -0
  11. package/api/resources/analytics/types/Average.d.ts +9 -0
  12. package/api/resources/analytics/types/Average.js +5 -0
  13. package/api/resources/analytics/types/BasicMetric.d.ts +8 -0
  14. package/api/resources/analytics/types/BasicMetric.js +5 -0
  15. package/api/resources/analytics/types/ColumnDefinition.d.ts +10 -0
  16. package/api/resources/analytics/types/ColumnDefinition.js +5 -0
  17. package/api/resources/analytics/types/ConversationAnalyticsRequest.d.ts +8 -0
  18. package/api/resources/analytics/types/ConversationAnalyticsRequest.js +5 -0
  19. package/api/resources/analytics/types/ConversationRow.d.ts +13 -0
  20. package/api/resources/analytics/types/ConversationRow.js +5 -0
  21. package/api/resources/analytics/types/ConversationTableRequest.d.ts +50 -0
  22. package/api/resources/analytics/types/ConversationTableRequest.js +5 -0
  23. package/api/resources/analytics/types/ConversationTableResponse.d.ts +129 -0
  24. package/api/resources/analytics/types/ConversationTableResponse.js +5 -0
  25. package/api/resources/analytics/types/Count.d.ts +8 -0
  26. package/api/resources/analytics/types/Count.js +5 -0
  27. package/api/resources/analytics/types/DistinctCount.d.ts +10 -0
  28. package/api/resources/analytics/types/DistinctCount.js +5 -0
  29. package/api/resources/analytics/types/GroupBy.d.ts +12 -0
  30. package/api/resources/analytics/types/GroupBy.js +5 -0
  31. package/api/resources/analytics/types/Max.d.ts +9 -0
  32. package/api/resources/analytics/types/Max.js +5 -0
  33. package/api/resources/analytics/types/Median.d.ts +9 -0
  34. package/api/resources/analytics/types/Median.js +5 -0
  35. package/api/resources/analytics/types/Metric.d.ts +35 -0
  36. package/api/resources/analytics/types/Metric.js +5 -0
  37. package/api/resources/analytics/types/Min.d.ts +9 -0
  38. package/api/resources/analytics/types/Min.js +5 -0
  39. package/api/resources/analytics/types/Percentile.d.ts +11 -0
  40. package/api/resources/analytics/types/Percentile.js +5 -0
  41. package/api/resources/analytics/types/Sum.d.ts +9 -0
  42. package/api/resources/analytics/types/Sum.js +5 -0
  43. package/api/resources/analytics/types/index.d.ts +16 -0
  44. package/api/resources/analytics/types/index.js +32 -0
  45. package/api/resources/analyticsCommons/index.d.ts +1 -0
  46. package/api/resources/analyticsCommons/index.js +17 -0
  47. package/api/resources/analyticsCommons/types/CellData.d.ts +32 -0
  48. package/api/resources/analyticsCommons/types/CellData.js +5 -0
  49. package/api/resources/analyticsCommons/types/FieldValue.d.ts +33 -0
  50. package/api/resources/analyticsCommons/types/FieldValue.js +5 -0
  51. package/api/resources/analyticsCommons/types/Range.d.ts +9 -0
  52. package/api/resources/analyticsCommons/types/Range.js +5 -0
  53. package/api/resources/analyticsCommons/types/TimeInterval.d.ts +11 -0
  54. package/api/resources/analyticsCommons/types/TimeInterval.js +13 -0
  55. package/api/resources/analyticsCommons/types/index.d.ts +4 -0
  56. package/api/resources/analyticsCommons/types/index.js +20 -0
  57. package/api/resources/appSettings/client/Client.js +1 -1
  58. package/api/resources/commons/types/ConversationPrecondition.d.ts +4 -1
  59. package/api/resources/commons/types/ConversationResponse.d.ts +10 -1
  60. package/api/resources/commons/types/ConversationSummary.d.ts +10 -0
  61. package/api/resources/commons/types/ConversationSummary.js +5 -0
  62. package/api/resources/commons/types/EntityId.d.ts +6 -7
  63. package/api/resources/commons/types/EntityIdFilter.d.ts +7 -0
  64. package/api/resources/commons/types/EntityIdFilter.js +5 -0
  65. package/api/resources/commons/types/EntityIdWithoutAgent.d.ts +13 -0
  66. package/api/resources/commons/types/EntityIdWithoutAgent.js +5 -0
  67. package/api/resources/commons/types/ResponseConfigPrecondition.d.ts +11 -0
  68. package/api/resources/commons/types/ResponseConfigPrecondition.js +5 -0
  69. package/api/resources/commons/types/index.d.ts +4 -0
  70. package/api/resources/commons/types/index.js +4 -0
  71. package/api/resources/conversation/client/Client.d.ts +47 -4
  72. package/api/resources/conversation/client/Client.js +124 -14
  73. package/api/resources/conversation/client/requests/ConversationDeleteRequest.d.ts +19 -0
  74. package/api/resources/conversation/client/requests/ConversationDeleteRequest.js +5 -0
  75. package/api/resources/conversation/client/requests/index.d.ts +1 -0
  76. package/api/resources/conversation/types/AskRequest.d.ts +1 -1
  77. package/api/resources/conversation/types/ConversationField.d.ts +26 -0
  78. package/api/resources/conversation/types/ConversationField.js +28 -0
  79. package/api/resources/conversation/types/ConversationFilter.d.ts +21 -0
  80. package/api/resources/conversation/types/ConversationFilter.js +5 -0
  81. package/api/resources/conversation/types/Quality.d.ts +9 -0
  82. package/api/resources/conversation/types/Quality.js +11 -0
  83. package/api/resources/conversation/types/QualityReason.d.ts +15 -0
  84. package/api/resources/conversation/types/QualityReason.js +17 -0
  85. package/api/resources/conversation/types/index.d.ts +4 -0
  86. package/api/resources/conversation/types/index.js +4 -0
  87. package/api/resources/index.d.ts +4 -0
  88. package/api/resources/index.js +5 -1
  89. package/api/resources/knowledge/client/Client.js +7 -7
  90. package/api/resources/translations/client/Client.js +1 -1
  91. package/api/resources/triggers/client/Client.js +3 -3
  92. package/api/resources/users/client/Client.js +2 -2
  93. package/dist/Client.d.ts +3 -0
  94. package/dist/Client.js +17 -12
  95. package/dist/api/resources/actions/client/Client.js +3 -3
  96. package/dist/api/resources/analytics/client/Client.d.ts +78 -0
  97. package/dist/api/resources/analytics/client/Client.js +174 -0
  98. package/dist/api/resources/analytics/client/index.d.ts +1 -0
  99. package/dist/api/resources/analytics/client/index.js +2 -0
  100. package/dist/api/resources/analytics/index.d.ts +2 -0
  101. package/dist/api/resources/analytics/index.js +18 -0
  102. package/dist/api/resources/analytics/types/Average.d.ts +9 -0
  103. package/dist/api/resources/analytics/types/Average.js +5 -0
  104. package/dist/api/resources/analytics/types/BasicMetric.d.ts +8 -0
  105. package/dist/api/resources/analytics/types/BasicMetric.js +5 -0
  106. package/dist/api/resources/analytics/types/ColumnDefinition.d.ts +10 -0
  107. package/dist/api/resources/analytics/types/ColumnDefinition.js +5 -0
  108. package/dist/api/resources/analytics/types/ConversationAnalyticsRequest.d.ts +8 -0
  109. package/dist/api/resources/analytics/types/ConversationAnalyticsRequest.js +5 -0
  110. package/dist/api/resources/analytics/types/ConversationRow.d.ts +13 -0
  111. package/dist/api/resources/analytics/types/ConversationRow.js +5 -0
  112. package/dist/api/resources/analytics/types/ConversationTableRequest.d.ts +50 -0
  113. package/dist/api/resources/analytics/types/ConversationTableRequest.js +5 -0
  114. package/dist/api/resources/analytics/types/ConversationTableResponse.d.ts +129 -0
  115. package/dist/api/resources/analytics/types/ConversationTableResponse.js +5 -0
  116. package/dist/api/resources/analytics/types/Count.d.ts +8 -0
  117. package/dist/api/resources/analytics/types/Count.js +5 -0
  118. package/dist/api/resources/analytics/types/DistinctCount.d.ts +10 -0
  119. package/dist/api/resources/analytics/types/DistinctCount.js +5 -0
  120. package/dist/api/resources/analytics/types/GroupBy.d.ts +12 -0
  121. package/dist/api/resources/analytics/types/GroupBy.js +5 -0
  122. package/dist/api/resources/analytics/types/Max.d.ts +9 -0
  123. package/dist/api/resources/analytics/types/Max.js +5 -0
  124. package/dist/api/resources/analytics/types/Median.d.ts +9 -0
  125. package/dist/api/resources/analytics/types/Median.js +5 -0
  126. package/dist/api/resources/analytics/types/Metric.d.ts +35 -0
  127. package/dist/api/resources/analytics/types/Metric.js +5 -0
  128. package/dist/api/resources/analytics/types/Min.d.ts +9 -0
  129. package/dist/api/resources/analytics/types/Min.js +5 -0
  130. package/dist/api/resources/analytics/types/Percentile.d.ts +11 -0
  131. package/dist/api/resources/analytics/types/Percentile.js +5 -0
  132. package/dist/api/resources/analytics/types/Sum.d.ts +9 -0
  133. package/dist/api/resources/analytics/types/Sum.js +5 -0
  134. package/dist/api/resources/analytics/types/index.d.ts +16 -0
  135. package/dist/api/resources/analytics/types/index.js +32 -0
  136. package/dist/api/resources/analyticsCommons/index.d.ts +1 -0
  137. package/dist/api/resources/analyticsCommons/index.js +17 -0
  138. package/dist/api/resources/analyticsCommons/types/CellData.d.ts +32 -0
  139. package/dist/api/resources/analyticsCommons/types/CellData.js +5 -0
  140. package/dist/api/resources/analyticsCommons/types/FieldValue.d.ts +33 -0
  141. package/dist/api/resources/analyticsCommons/types/FieldValue.js +5 -0
  142. package/dist/api/resources/analyticsCommons/types/Range.d.ts +9 -0
  143. package/dist/api/resources/analyticsCommons/types/Range.js +5 -0
  144. package/dist/api/resources/analyticsCommons/types/TimeInterval.d.ts +11 -0
  145. package/dist/api/resources/analyticsCommons/types/TimeInterval.js +13 -0
  146. package/dist/api/resources/analyticsCommons/types/index.d.ts +4 -0
  147. package/dist/api/resources/analyticsCommons/types/index.js +20 -0
  148. package/dist/api/resources/appSettings/client/Client.js +1 -1
  149. package/dist/api/resources/commons/types/ConversationPrecondition.d.ts +4 -1
  150. package/dist/api/resources/commons/types/ConversationResponse.d.ts +10 -1
  151. package/dist/api/resources/commons/types/ConversationSummary.d.ts +10 -0
  152. package/dist/api/resources/commons/types/ConversationSummary.js +5 -0
  153. package/dist/api/resources/commons/types/EntityId.d.ts +6 -7
  154. package/dist/api/resources/commons/types/EntityIdFilter.d.ts +7 -0
  155. package/dist/api/resources/commons/types/EntityIdFilter.js +5 -0
  156. package/dist/api/resources/commons/types/EntityIdWithoutAgent.d.ts +13 -0
  157. package/dist/api/resources/commons/types/EntityIdWithoutAgent.js +5 -0
  158. package/dist/api/resources/commons/types/ResponseConfigPrecondition.d.ts +11 -0
  159. package/dist/api/resources/commons/types/ResponseConfigPrecondition.js +5 -0
  160. package/dist/api/resources/commons/types/index.d.ts +4 -0
  161. package/dist/api/resources/commons/types/index.js +4 -0
  162. package/dist/api/resources/conversation/client/Client.d.ts +47 -4
  163. package/dist/api/resources/conversation/client/Client.js +124 -14
  164. package/dist/api/resources/conversation/client/requests/ConversationDeleteRequest.d.ts +19 -0
  165. package/dist/api/resources/conversation/client/requests/ConversationDeleteRequest.js +5 -0
  166. package/dist/api/resources/conversation/client/requests/index.d.ts +1 -0
  167. package/dist/api/resources/conversation/types/AskRequest.d.ts +1 -1
  168. package/dist/api/resources/conversation/types/ConversationField.d.ts +26 -0
  169. package/dist/api/resources/conversation/types/ConversationField.js +28 -0
  170. package/dist/api/resources/conversation/types/ConversationFilter.d.ts +21 -0
  171. package/dist/api/resources/conversation/types/ConversationFilter.js +5 -0
  172. package/dist/api/resources/conversation/types/Quality.d.ts +9 -0
  173. package/dist/api/resources/conversation/types/Quality.js +11 -0
  174. package/dist/api/resources/conversation/types/QualityReason.d.ts +15 -0
  175. package/dist/api/resources/conversation/types/QualityReason.js +17 -0
  176. package/dist/api/resources/conversation/types/index.d.ts +4 -0
  177. package/dist/api/resources/conversation/types/index.js +4 -0
  178. package/dist/api/resources/index.d.ts +4 -0
  179. package/dist/api/resources/index.js +5 -1
  180. package/dist/api/resources/knowledge/client/Client.js +7 -7
  181. package/dist/api/resources/translations/client/Client.js +1 -1
  182. package/dist/api/resources/triggers/client/Client.js +3 -3
  183. package/dist/api/resources/users/client/Client.js +2 -2
  184. package/dist/serialization/resources/analytics/index.d.ts +1 -0
  185. package/dist/serialization/resources/analytics/index.js +17 -0
  186. package/dist/serialization/resources/analytics/types/Average.d.ts +12 -0
  187. package/dist/serialization/resources/analytics/types/Average.js +34 -0
  188. package/dist/serialization/resources/analytics/types/BasicMetric.d.ts +13 -0
  189. package/dist/serialization/resources/analytics/types/BasicMetric.js +34 -0
  190. package/dist/serialization/resources/analytics/types/ColumnDefinition.d.ts +14 -0
  191. package/dist/serialization/resources/analytics/types/ColumnDefinition.js +35 -0
  192. package/dist/serialization/resources/analytics/types/ConversationAnalyticsRequest.d.ts +13 -0
  193. package/dist/serialization/resources/analytics/types/ConversationAnalyticsRequest.js +34 -0
  194. package/dist/serialization/resources/analytics/types/ConversationRow.d.ts +16 -0
  195. package/dist/serialization/resources/analytics/types/ConversationRow.js +37 -0
  196. package/dist/serialization/resources/analytics/types/ConversationTableRequest.d.ts +18 -0
  197. package/dist/serialization/resources/analytics/types/ConversationTableRequest.js +41 -0
  198. package/dist/serialization/resources/analytics/types/ConversationTableResponse.d.ts +14 -0
  199. package/dist/serialization/resources/analytics/types/ConversationTableResponse.js +35 -0
  200. package/dist/serialization/resources/analytics/types/Count.d.ts +11 -0
  201. package/dist/serialization/resources/analytics/types/Count.js +31 -0
  202. package/dist/serialization/resources/analytics/types/DistinctCount.d.ts +12 -0
  203. package/dist/serialization/resources/analytics/types/DistinctCount.js +32 -0
  204. package/dist/serialization/resources/analytics/types/GroupBy.d.ts +16 -0
  205. package/dist/serialization/resources/analytics/types/GroupBy.js +37 -0
  206. package/dist/serialization/resources/analytics/types/Max.d.ts +12 -0
  207. package/dist/serialization/resources/analytics/types/Max.js +34 -0
  208. package/dist/serialization/resources/analytics/types/Median.d.ts +12 -0
  209. package/dist/serialization/resources/analytics/types/Median.js +34 -0
  210. package/dist/serialization/resources/analytics/types/Metric.d.ts +42 -0
  211. package/dist/serialization/resources/analytics/types/Metric.js +53 -0
  212. package/dist/serialization/resources/analytics/types/Min.d.ts +12 -0
  213. package/dist/serialization/resources/analytics/types/Min.js +34 -0
  214. package/dist/serialization/resources/analytics/types/Percentile.d.ts +13 -0
  215. package/dist/serialization/resources/analytics/types/Percentile.js +36 -0
  216. package/dist/serialization/resources/analytics/types/Sum.d.ts +12 -0
  217. package/dist/serialization/resources/analytics/types/Sum.js +34 -0
  218. package/dist/serialization/resources/analytics/types/index.d.ts +16 -0
  219. package/dist/serialization/resources/analytics/types/index.js +32 -0
  220. package/dist/serialization/resources/analyticsCommons/index.d.ts +1 -0
  221. package/dist/serialization/resources/analyticsCommons/index.js +17 -0
  222. package/dist/serialization/resources/analyticsCommons/types/CellData.d.ts +30 -0
  223. package/dist/serialization/resources/analyticsCommons/types/CellData.js +52 -0
  224. package/dist/serialization/resources/analyticsCommons/types/FieldValue.d.ts +38 -0
  225. package/dist/serialization/resources/analyticsCommons/types/FieldValue.js +56 -0
  226. package/dist/serialization/resources/analyticsCommons/types/Range.d.ts +13 -0
  227. package/dist/serialization/resources/analyticsCommons/types/Range.js +34 -0
  228. package/dist/serialization/resources/analyticsCommons/types/TimeInterval.d.ts +10 -0
  229. package/dist/serialization/resources/analyticsCommons/types/TimeInterval.js +31 -0
  230. package/dist/serialization/resources/analyticsCommons/types/index.d.ts +4 -0
  231. package/dist/serialization/resources/analyticsCommons/types/index.js +20 -0
  232. package/dist/serialization/resources/commons/types/ConversationPrecondition.d.ts +5 -1
  233. package/dist/serialization/resources/commons/types/ConversationPrecondition.js +2 -0
  234. package/dist/serialization/resources/commons/types/ConversationResponse.d.ts +3 -0
  235. package/dist/serialization/resources/commons/types/ConversationResponse.js +3 -0
  236. package/dist/serialization/resources/commons/types/ConversationSummary.d.ts +14 -0
  237. package/dist/serialization/resources/commons/types/ConversationSummary.js +35 -0
  238. package/dist/serialization/resources/commons/types/EntityId.d.ts +2 -5
  239. package/dist/serialization/resources/commons/types/EntityId.js +2 -5
  240. package/dist/serialization/resources/commons/types/EntityIdFilter.d.ts +13 -0
  241. package/dist/serialization/resources/commons/types/EntityIdFilter.js +34 -0
  242. package/dist/serialization/resources/commons/types/EntityIdWithoutAgent.d.ts +15 -0
  243. package/dist/serialization/resources/commons/types/EntityIdWithoutAgent.js +38 -0
  244. package/dist/serialization/resources/commons/types/ResponseConfigPrecondition.d.ts +18 -0
  245. package/dist/serialization/resources/commons/types/ResponseConfigPrecondition.js +41 -0
  246. package/dist/serialization/resources/commons/types/index.d.ts +4 -0
  247. package/dist/serialization/resources/commons/types/index.js +4 -0
  248. package/dist/serialization/resources/conversation/types/ConversationField.d.ts +10 -0
  249. package/dist/serialization/resources/conversation/types/ConversationField.js +52 -0
  250. package/dist/serialization/resources/conversation/types/ConversationFilter.d.ts +32 -0
  251. package/dist/serialization/resources/conversation/types/ConversationFilter.js +53 -0
  252. package/dist/serialization/resources/conversation/types/Quality.d.ts +10 -0
  253. package/dist/serialization/resources/conversation/types/Quality.js +35 -0
  254. package/dist/serialization/resources/conversation/types/QualityReason.d.ts +10 -0
  255. package/dist/serialization/resources/conversation/types/QualityReason.js +41 -0
  256. package/dist/serialization/resources/conversation/types/index.d.ts +4 -0
  257. package/dist/serialization/resources/conversation/types/index.js +4 -0
  258. package/dist/serialization/resources/index.d.ts +4 -0
  259. package/dist/serialization/resources/index.js +5 -1
  260. package/dist/version.d.ts +1 -1
  261. package/dist/version.js +1 -1
  262. package/package.json +1 -1
  263. package/reference.md +203 -4
  264. package/serialization/resources/analytics/index.d.ts +1 -0
  265. package/serialization/resources/analytics/index.js +17 -0
  266. package/serialization/resources/analytics/types/Average.d.ts +12 -0
  267. package/serialization/resources/analytics/types/Average.js +34 -0
  268. package/serialization/resources/analytics/types/BasicMetric.d.ts +13 -0
  269. package/serialization/resources/analytics/types/BasicMetric.js +34 -0
  270. package/serialization/resources/analytics/types/ColumnDefinition.d.ts +14 -0
  271. package/serialization/resources/analytics/types/ColumnDefinition.js +35 -0
  272. package/serialization/resources/analytics/types/ConversationAnalyticsRequest.d.ts +13 -0
  273. package/serialization/resources/analytics/types/ConversationAnalyticsRequest.js +34 -0
  274. package/serialization/resources/analytics/types/ConversationRow.d.ts +16 -0
  275. package/serialization/resources/analytics/types/ConversationRow.js +37 -0
  276. package/serialization/resources/analytics/types/ConversationTableRequest.d.ts +18 -0
  277. package/serialization/resources/analytics/types/ConversationTableRequest.js +41 -0
  278. package/serialization/resources/analytics/types/ConversationTableResponse.d.ts +14 -0
  279. package/serialization/resources/analytics/types/ConversationTableResponse.js +35 -0
  280. package/serialization/resources/analytics/types/Count.d.ts +11 -0
  281. package/serialization/resources/analytics/types/Count.js +31 -0
  282. package/serialization/resources/analytics/types/DistinctCount.d.ts +12 -0
  283. package/serialization/resources/analytics/types/DistinctCount.js +32 -0
  284. package/serialization/resources/analytics/types/GroupBy.d.ts +16 -0
  285. package/serialization/resources/analytics/types/GroupBy.js +37 -0
  286. package/serialization/resources/analytics/types/Max.d.ts +12 -0
  287. package/serialization/resources/analytics/types/Max.js +34 -0
  288. package/serialization/resources/analytics/types/Median.d.ts +12 -0
  289. package/serialization/resources/analytics/types/Median.js +34 -0
  290. package/serialization/resources/analytics/types/Metric.d.ts +42 -0
  291. package/serialization/resources/analytics/types/Metric.js +53 -0
  292. package/serialization/resources/analytics/types/Min.d.ts +12 -0
  293. package/serialization/resources/analytics/types/Min.js +34 -0
  294. package/serialization/resources/analytics/types/Percentile.d.ts +13 -0
  295. package/serialization/resources/analytics/types/Percentile.js +36 -0
  296. package/serialization/resources/analytics/types/Sum.d.ts +12 -0
  297. package/serialization/resources/analytics/types/Sum.js +34 -0
  298. package/serialization/resources/analytics/types/index.d.ts +16 -0
  299. package/serialization/resources/analytics/types/index.js +32 -0
  300. package/serialization/resources/analyticsCommons/index.d.ts +1 -0
  301. package/serialization/resources/analyticsCommons/index.js +17 -0
  302. package/serialization/resources/analyticsCommons/types/CellData.d.ts +30 -0
  303. package/serialization/resources/analyticsCommons/types/CellData.js +52 -0
  304. package/serialization/resources/analyticsCommons/types/FieldValue.d.ts +38 -0
  305. package/serialization/resources/analyticsCommons/types/FieldValue.js +56 -0
  306. package/serialization/resources/analyticsCommons/types/Range.d.ts +13 -0
  307. package/serialization/resources/analyticsCommons/types/Range.js +34 -0
  308. package/serialization/resources/analyticsCommons/types/TimeInterval.d.ts +10 -0
  309. package/serialization/resources/analyticsCommons/types/TimeInterval.js +31 -0
  310. package/serialization/resources/analyticsCommons/types/index.d.ts +4 -0
  311. package/serialization/resources/analyticsCommons/types/index.js +20 -0
  312. package/serialization/resources/commons/types/ConversationPrecondition.d.ts +5 -1
  313. package/serialization/resources/commons/types/ConversationPrecondition.js +2 -0
  314. package/serialization/resources/commons/types/ConversationResponse.d.ts +3 -0
  315. package/serialization/resources/commons/types/ConversationResponse.js +3 -0
  316. package/serialization/resources/commons/types/ConversationSummary.d.ts +14 -0
  317. package/serialization/resources/commons/types/ConversationSummary.js +35 -0
  318. package/serialization/resources/commons/types/EntityId.d.ts +2 -5
  319. package/serialization/resources/commons/types/EntityId.js +2 -5
  320. package/serialization/resources/commons/types/EntityIdFilter.d.ts +13 -0
  321. package/serialization/resources/commons/types/EntityIdFilter.js +34 -0
  322. package/serialization/resources/commons/types/EntityIdWithoutAgent.d.ts +15 -0
  323. package/serialization/resources/commons/types/EntityIdWithoutAgent.js +38 -0
  324. package/serialization/resources/commons/types/ResponseConfigPrecondition.d.ts +18 -0
  325. package/serialization/resources/commons/types/ResponseConfigPrecondition.js +41 -0
  326. package/serialization/resources/commons/types/index.d.ts +4 -0
  327. package/serialization/resources/commons/types/index.js +4 -0
  328. package/serialization/resources/conversation/types/ConversationField.d.ts +10 -0
  329. package/serialization/resources/conversation/types/ConversationField.js +52 -0
  330. package/serialization/resources/conversation/types/ConversationFilter.d.ts +32 -0
  331. package/serialization/resources/conversation/types/ConversationFilter.js +53 -0
  332. package/serialization/resources/conversation/types/Quality.d.ts +10 -0
  333. package/serialization/resources/conversation/types/Quality.js +35 -0
  334. package/serialization/resources/conversation/types/QualityReason.d.ts +10 -0
  335. package/serialization/resources/conversation/types/QualityReason.js +41 -0
  336. package/serialization/resources/conversation/types/index.d.ts +4 -0
  337. package/serialization/resources/conversation/types/index.js +4 -0
  338. package/serialization/resources/index.d.ts +4 -0
  339. package/serialization/resources/index.js +5 -1
  340. package/version.d.ts +1 -1
  341. package/version.js +1 -1
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./FieldValue"), exports);
18
+ __exportStar(require("./TimeInterval"), exports);
19
+ __exportStar(require("./Range"), exports);
20
+ __exportStar(require("./CellData"), exports);
@@ -67,7 +67,7 @@ class AppSettings {
67
67
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
68
68
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, "v1/app-settings"),
69
69
  method: "GET",
70
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
70
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
71
71
  contentType: "application/json",
72
72
  requestType: "json",
73
73
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -2,7 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as MavenAGI from "../../../index";
5
- export declare type ConversationPrecondition = MavenAGI.ConversationPrecondition.Tags | MavenAGI.ConversationPrecondition.Metadata | MavenAGI.ConversationPrecondition.ActionExecuted;
5
+ export declare type ConversationPrecondition = MavenAGI.ConversationPrecondition.Tags | MavenAGI.ConversationPrecondition.Metadata | MavenAGI.ConversationPrecondition.ActionExecuted | MavenAGI.ConversationPrecondition.ResponseConfig;
6
6
  export declare namespace ConversationPrecondition {
7
7
  interface Tags extends MavenAGI.TagsPrecondition {
8
8
  conversationPreconditionType: "tags";
@@ -13,4 +13,7 @@ export declare namespace ConversationPrecondition {
13
13
  interface ActionExecuted extends MavenAGI.ConversationExecutedActionPrecondition {
14
14
  conversationPreconditionType: "actionExecuted";
15
15
  }
16
+ interface ResponseConfig extends MavenAGI.ResponseConfigPrecondition {
17
+ conversationPreconditionType: "responseConfig";
18
+ }
16
19
  }
@@ -12,10 +12,15 @@ import * as MavenAGI from "../../../index";
12
12
  * agentId: "support",
13
13
  * type: MavenAGI.EntityType.Conversation
14
14
  * },
15
+ * deleted: false,
15
16
  * analysis: {
16
17
  * resolutionStatus: "Resolved",
17
18
  * sentiment: MavenAGI.Sentiment.Positive
18
19
  * },
20
+ * summary: {
21
+ * actionIds: [],
22
+ * incompleteActionIds: []
23
+ * },
19
24
  * messages: [{
20
25
  * type: "user",
21
26
  * userMessageType: MavenAGI.UserConversationMessageType.User,
@@ -59,6 +64,10 @@ export interface ConversationResponse extends MavenAGI.ConversationBase {
59
64
  conversationId: MavenAGI.EntityId;
60
65
  /** The messages in the conversation */
61
66
  messages: MavenAGI.ConversationMessageResponse[];
62
- /** An analysis of the conversation. */
67
+ /** An analysis of the conversation. Fields are generated by Maven via an analysis of user messages. This object is calculated on a delay. Fields will not be up to date on ask requests. */
63
68
  analysis: MavenAGI.ConversationAnalysis;
69
+ /** A summary of the conversation. Fields are calculated from conversation data. Unlike analysis, all fields can be derived from other data available in the API. This object is provided as a convenience and is calculated on a delay. Fields will not be up to date on ask requests. */
70
+ summary: MavenAGI.ConversationSummary;
71
+ /** Whether the conversation user-specific data has been deleted. See `deleteConversation` for details. */
72
+ deleted: boolean;
64
73
  }
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as MavenAGI from "../../../index";
5
+ export interface ConversationSummary {
6
+ /** The IDs of the actions that were taken by Maven in the conversation */
7
+ actionIds: MavenAGI.EntityIdWithoutAgent[];
8
+ /** The IDs of the actions that were taken by Maven but not completed in the conversation. Occurs when the user is shown an action form but does not submit it. */
9
+ incompleteActionIds: MavenAGI.EntityIdWithoutAgent[];
10
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -2,13 +2,12 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as MavenAGI from "../../../index";
5
- export interface EntityId extends MavenAGI.EntityIdBase {
6
- /** The object type */
7
- type: MavenAGI.EntityType;
8
- /** The ID of the application that created this object */
9
- appId: string;
10
- /** The ID of the organization that this object belongs too */
5
+ /**
6
+ * A fully specified object ID, unique across the entire system.
7
+ */
8
+ export interface EntityId extends MavenAGI.EntityIdWithoutAgent {
9
+ /** The ID of the organization that this object belongs to */
11
10
  organizationId: string;
12
- /** The ID of the agent that this object belongs too */
11
+ /** The ID of the agent that this object belongs to */
13
12
  agentId: string;
14
13
  }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export interface EntityIdFilter {
5
+ referenceId: string;
6
+ appId: string;
7
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as MavenAGI from "../../../index";
5
+ /**
6
+ * The organizationId and agentId are inferred from the context.
7
+ */
8
+ export interface EntityIdWithoutAgent extends MavenAGI.EntityIdBase {
9
+ /** The object type */
10
+ type: MavenAGI.EntityType;
11
+ /** The ID of the application that created this object */
12
+ appId: string;
13
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as MavenAGI from "../../../index";
5
+ export interface ResponseConfigPrecondition extends MavenAGI.PreconditionBase {
6
+ useMarkdown?: boolean;
7
+ useForms?: boolean;
8
+ useImages?: boolean;
9
+ isCopilot?: boolean;
10
+ responseLength?: MavenAGI.ResponseLength;
11
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,6 +1,8 @@
1
1
  export * from "./ErrorMessage";
2
2
  export * from "./EntityType";
3
3
  export * from "./EntityIdBase";
4
+ export * from "./EntityIdWithoutAgent";
5
+ export * from "./EntityIdFilter";
4
6
  export * from "./EntityId";
5
7
  export * from "./FeedbackBase";
6
8
  export * from "./FeedbackType";
@@ -18,6 +20,7 @@ export * from "./EventTriggerType";
18
20
  export * from "./ActionParameterType";
19
21
  export * from "./ActionEnumOption";
20
22
  export * from "./Sentiment";
23
+ export * from "./ConversationSummary";
21
24
  export * from "./ConversationAnalysis";
22
25
  export * from "./ResponseLength";
23
26
  export * from "./Capability";
@@ -48,6 +51,7 @@ export * from "./PreconditionOperator";
48
51
  export * from "./PreconditionBase";
49
52
  export * from "./MetadataPrecondition";
50
53
  export * from "./ConversationPrecondition";
54
+ export * from "./ResponseConfigPrecondition";
51
55
  export * from "./PreconditionGroupOperator";
52
56
  export * from "./PreconditionGroup";
53
57
  export * from "./TagsPrecondition";
@@ -17,6 +17,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./ErrorMessage"), exports);
18
18
  __exportStar(require("./EntityType"), exports);
19
19
  __exportStar(require("./EntityIdBase"), exports);
20
+ __exportStar(require("./EntityIdWithoutAgent"), exports);
21
+ __exportStar(require("./EntityIdFilter"), exports);
20
22
  __exportStar(require("./EntityId"), exports);
21
23
  __exportStar(require("./FeedbackBase"), exports);
22
24
  __exportStar(require("./FeedbackType"), exports);
@@ -34,6 +36,7 @@ __exportStar(require("./EventTriggerType"), exports);
34
36
  __exportStar(require("./ActionParameterType"), exports);
35
37
  __exportStar(require("./ActionEnumOption"), exports);
36
38
  __exportStar(require("./Sentiment"), exports);
39
+ __exportStar(require("./ConversationSummary"), exports);
37
40
  __exportStar(require("./ConversationAnalysis"), exports);
38
41
  __exportStar(require("./ResponseLength"), exports);
39
42
  __exportStar(require("./Capability"), exports);
@@ -64,6 +67,7 @@ __exportStar(require("./PreconditionOperator"), exports);
64
67
  __exportStar(require("./PreconditionBase"), exports);
65
68
  __exportStar(require("./MetadataPrecondition"), exports);
66
69
  __exportStar(require("./ConversationPrecondition"), exports);
70
+ __exportStar(require("./ResponseConfigPrecondition"), exports);
67
71
  __exportStar(require("./PreconditionGroupOperator"), exports);
68
72
  __exportStar(require("./PreconditionGroup"), exports);
69
73
  __exportStar(require("./TagsPrecondition"), exports);
@@ -76,7 +76,30 @@ export declare class Conversation {
76
76
  */
77
77
  get(conversationId: string, request?: MavenAGI.ConversationGetRequest, requestOptions?: Conversation.RequestOptions): Promise<MavenAGI.ConversationResponse>;
78
78
  /**
79
- * Append messages to an existing conversation. The conversation must be initialized first. If a message with the same id already exists, it will be ignored.
79
+ * Wipes a conversation of all user data.
80
+ * The conversation ID will still exist and non-user specific data will still be retained.
81
+ * Attempts to modify or add messages to the conversation will throw an error.
82
+ *
83
+ * <Warning>This is a destructive operation and cannot be undone. <br/><br/>
84
+ * The exact fields cleared include: the conversation subject, userRequest, agentResponse.
85
+ * As well as the text response, followup questions, and backend LLM prompt of all messages.</Warning>
86
+ *
87
+ * @param {string} conversationId - The ID of the conversation to delete
88
+ * @param {MavenAGI.ConversationDeleteRequest} request
89
+ * @param {Conversation.RequestOptions} requestOptions - Request-specific configuration.
90
+ *
91
+ * @throws {@link MavenAGI.NotFoundError}
92
+ * @throws {@link MavenAGI.BadRequestError}
93
+ * @throws {@link MavenAGI.ServerError}
94
+ *
95
+ * @example
96
+ * await client.conversation.delete("conversation-0", {
97
+ * reason: "GDPR deletion request 1234."
98
+ * })
99
+ */
100
+ delete(conversationId: string, request: MavenAGI.ConversationDeleteRequest, requestOptions?: Conversation.RequestOptions): Promise<void>;
101
+ /**
102
+ * Append messages to an existing conversation. The conversation must be initialized first. If a message with the same ID already exists, it will be ignored. Messages do not allow modification.
80
103
  *
81
104
  * @param {string} conversationId - The ID of the conversation to append messages to
82
105
  * @param {MavenAGI.ConversationMessageRequest[]} request
@@ -99,7 +122,15 @@ export declare class Conversation {
99
122
  */
100
123
  appendNewMessages(conversationId: string, request: MavenAGI.ConversationMessageRequest[], requestOptions?: Conversation.RequestOptions): Promise<MavenAGI.ConversationResponse>;
101
124
  /**
102
- * Ask a question
125
+ * Get an answer from Maven for a given user question. If the user question or its answer already exists,
126
+ * they will be reused and will not be updated. Messages do not allow modification once generated.
127
+ *
128
+ * Concurrency Behavior:
129
+ * - If another API call is made for the same user question while a response is mid-stream, partial answers may be returned.
130
+ * - The second caller will receive a truncated or partial response depending on where the first stream is in its processing. The first caller's stream will remain unaffected and continue delivering the full response.
131
+ *
132
+ * Known Limitation:
133
+ * - The API does not currently expose metadata indicating whether a response or message is incomplete. This will be addressed in a future update.
103
134
  *
104
135
  * @param {string} conversationId - The ID of a new or existing conversation to use as context for the question
105
136
  * @param {MavenAGI.AskRequest} request
@@ -130,11 +161,23 @@ export declare class Conversation {
130
161
  */
131
162
  ask(conversationId: string, request: MavenAGI.AskRequest, requestOptions?: Conversation.RequestOptions): Promise<MavenAGI.ConversationResponse>;
132
163
  /**
133
- * Ask a question with a streaming response. The response will be sent as a stream of events. The text portions of stream responses should be concatenated to form the full response text. Action and metadata events should overwrite past data and do not need concatenation.
164
+ * Get an answer from Maven for a given user question with a streaming response. The response will be sent as a stream of events.
165
+ * The text portions of stream responses should be concatenated to form the full response text.
166
+ * Action and metadata events should overwrite past data and do not need concatenation.
167
+ *
168
+ * If the user question or its answer already exists, they will be reused and will not be updated.
169
+ * Messages do not allow modification once generated.
170
+ *
171
+ * Concurrency Behavior:
172
+ * - If another API call is made for the same user question while a response is mid-stream, partial answers may be returned.
173
+ * - The second caller will receive a truncated or partial response depending on where the first stream is in its processing. The first caller's stream will remain unaffected and continue delivering the full response.
174
+ *
175
+ * Known Limitation:
176
+ * - The API does not currently expose metadata indicating whether a response or message is incomplete. This will be addressed in a future update.
134
177
  */
135
178
  askStream(conversationId: string, request: MavenAGI.AskRequest, requestOptions?: Conversation.RequestOptions): Promise<core.Stream<MavenAGI.StreamResponse>>;
136
179
  /**
137
- * Generate a response suggestion for each requested message id in a conversation
180
+ * This method is deprecated and will be removed in a future release. Use either `ask` or `askStream` instead.
138
181
  *
139
182
  * @param {string} conversationId - The ID of a conversation the messages belong to
140
183
  * @param {MavenAGI.GenerateMavenSuggestionsRequest} request
@@ -81,7 +81,7 @@ class Conversation {
81
81
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
82
82
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, "/v1/conversations"),
83
83
  method: "POST",
84
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
84
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
85
85
  contentType: "application/json",
86
86
  requestType: "json",
87
87
  body: serializers.ConversationRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -167,7 +167,7 @@ class Conversation {
167
167
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
168
168
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}`),
169
169
  method: "GET",
170
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
170
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
171
171
  contentType: "application/json",
172
172
  queryParameters: _queryParams,
173
173
  requestType: "json",
@@ -229,7 +229,97 @@ class Conversation {
229
229
  });
230
230
  }
231
231
  /**
232
- * Append messages to an existing conversation. The conversation must be initialized first. If a message with the same id already exists, it will be ignored.
232
+ * Wipes a conversation of all user data.
233
+ * The conversation ID will still exist and non-user specific data will still be retained.
234
+ * Attempts to modify or add messages to the conversation will throw an error.
235
+ *
236
+ * <Warning>This is a destructive operation and cannot be undone. <br/><br/>
237
+ * The exact fields cleared include: the conversation subject, userRequest, agentResponse.
238
+ * As well as the text response, followup questions, and backend LLM prompt of all messages.</Warning>
239
+ *
240
+ * @param {string} conversationId - The ID of the conversation to delete
241
+ * @param {MavenAGI.ConversationDeleteRequest} request
242
+ * @param {Conversation.RequestOptions} requestOptions - Request-specific configuration.
243
+ *
244
+ * @throws {@link MavenAGI.NotFoundError}
245
+ * @throws {@link MavenAGI.BadRequestError}
246
+ * @throws {@link MavenAGI.ServerError}
247
+ *
248
+ * @example
249
+ * await client.conversation.delete("conversation-0", {
250
+ * reason: "GDPR deletion request 1234."
251
+ * })
252
+ */
253
+ delete(conversationId, request, requestOptions) {
254
+ var _a, _b;
255
+ return __awaiter(this, void 0, void 0, function* () {
256
+ const { appId, reason } = request;
257
+ const _queryParams = {};
258
+ if (appId != null) {
259
+ _queryParams["appId"] = appId;
260
+ }
261
+ _queryParams["reason"] = reason;
262
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
263
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}`),
264
+ method: "DELETE",
265
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
266
+ contentType: "application/json",
267
+ queryParameters: _queryParams,
268
+ requestType: "json",
269
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
270
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
271
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
272
+ });
273
+ if (_response.ok) {
274
+ return;
275
+ }
276
+ if (_response.error.reason === "status-code") {
277
+ switch (_response.error.statusCode) {
278
+ case 404:
279
+ throw new MavenAGI.NotFoundError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
280
+ unrecognizedObjectKeys: "passthrough",
281
+ allowUnrecognizedUnionMembers: true,
282
+ allowUnrecognizedEnumValues: true,
283
+ breadcrumbsPrefix: ["response"],
284
+ }));
285
+ case 400:
286
+ throw new MavenAGI.BadRequestError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
287
+ unrecognizedObjectKeys: "passthrough",
288
+ allowUnrecognizedUnionMembers: true,
289
+ allowUnrecognizedEnumValues: true,
290
+ breadcrumbsPrefix: ["response"],
291
+ }));
292
+ case 500:
293
+ throw new MavenAGI.ServerError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
294
+ unrecognizedObjectKeys: "passthrough",
295
+ allowUnrecognizedUnionMembers: true,
296
+ allowUnrecognizedEnumValues: true,
297
+ breadcrumbsPrefix: ["response"],
298
+ }));
299
+ default:
300
+ throw new errors.MavenAGIError({
301
+ statusCode: _response.error.statusCode,
302
+ body: _response.error.body,
303
+ });
304
+ }
305
+ }
306
+ switch (_response.error.reason) {
307
+ case "non-json":
308
+ throw new errors.MavenAGIError({
309
+ statusCode: _response.error.statusCode,
310
+ body: _response.error.rawBody,
311
+ });
312
+ case "timeout":
313
+ throw new errors.MavenAGITimeoutError("Timeout exceeded when calling DELETE /v1/conversations/{conversationId}.");
314
+ case "unknown":
315
+ throw new errors.MavenAGIError({
316
+ message: _response.error.errorMessage,
317
+ });
318
+ }
319
+ });
320
+ }
321
+ /**
322
+ * Append messages to an existing conversation. The conversation must be initialized first. If a message with the same ID already exists, it will be ignored. Messages do not allow modification.
233
323
  *
234
324
  * @param {string} conversationId - The ID of the conversation to append messages to
235
325
  * @param {MavenAGI.ConversationMessageRequest[]} request
@@ -256,7 +346,7 @@ class Conversation {
256
346
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
257
347
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/messages`),
258
348
  method: "POST",
259
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
349
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
260
350
  contentType: "application/json",
261
351
  requestType: "json",
262
352
  body: serializers.conversation.appendNewMessages.Request.jsonOrThrow(request, {
@@ -320,7 +410,15 @@ class Conversation {
320
410
  });
321
411
  }
322
412
  /**
323
- * Ask a question
413
+ * Get an answer from Maven for a given user question. If the user question or its answer already exists,
414
+ * they will be reused and will not be updated. Messages do not allow modification once generated.
415
+ *
416
+ * Concurrency Behavior:
417
+ * - If another API call is made for the same user question while a response is mid-stream, partial answers may be returned.
418
+ * - The second caller will receive a truncated or partial response depending on where the first stream is in its processing. The first caller's stream will remain unaffected and continue delivering the full response.
419
+ *
420
+ * Known Limitation:
421
+ * - The API does not currently expose metadata indicating whether a response or message is incomplete. This will be addressed in a future update.
324
422
  *
325
423
  * @param {string} conversationId - The ID of a new or existing conversation to use as context for the question
326
424
  * @param {MavenAGI.AskRequest} request
@@ -355,7 +453,7 @@ class Conversation {
355
453
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
356
454
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/ask`),
357
455
  method: "POST",
358
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
456
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
359
457
  contentType: "application/json",
360
458
  requestType: "json",
361
459
  body: serializers.AskRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -417,7 +515,19 @@ class Conversation {
417
515
  });
418
516
  }
419
517
  /**
420
- * Ask a question with a streaming response. The response will be sent as a stream of events. The text portions of stream responses should be concatenated to form the full response text. Action and metadata events should overwrite past data and do not need concatenation.
518
+ * Get an answer from Maven for a given user question with a streaming response. The response will be sent as a stream of events.
519
+ * The text portions of stream responses should be concatenated to form the full response text.
520
+ * Action and metadata events should overwrite past data and do not need concatenation.
521
+ *
522
+ * If the user question or its answer already exists, they will be reused and will not be updated.
523
+ * Messages do not allow modification once generated.
524
+ *
525
+ * Concurrency Behavior:
526
+ * - If another API call is made for the same user question while a response is mid-stream, partial answers may be returned.
527
+ * - The second caller will receive a truncated or partial response depending on where the first stream is in its processing. The first caller's stream will remain unaffected and continue delivering the full response.
528
+ *
529
+ * Known Limitation:
530
+ * - The API does not currently expose metadata indicating whether a response or message is incomplete. This will be addressed in a future update.
421
531
  */
422
532
  askStream(conversationId, request, requestOptions) {
423
533
  var _a, _b;
@@ -425,7 +535,7 @@ class Conversation {
425
535
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
426
536
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/ask_stream`),
427
537
  method: "POST",
428
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
538
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
429
539
  contentType: "application/json",
430
540
  requestType: "json",
431
541
  body: serializers.AskRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -498,7 +608,7 @@ class Conversation {
498
608
  });
499
609
  }
500
610
  /**
501
- * Generate a response suggestion for each requested message id in a conversation
611
+ * This method is deprecated and will be removed in a future release. Use either `ask` or `askStream` instead.
502
612
  *
503
613
  * @param {string} conversationId - The ID of a conversation the messages belong to
504
614
  * @param {MavenAGI.GenerateMavenSuggestionsRequest} request
@@ -523,7 +633,7 @@ class Conversation {
523
633
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
524
634
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/generate_maven_suggestions`),
525
635
  method: "POST",
526
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
636
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
527
637
  contentType: "application/json",
528
638
  requestType: "json",
529
639
  body: serializers.GenerateMavenSuggestionsRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -603,7 +713,7 @@ class Conversation {
603
713
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
604
714
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/categorize`),
605
715
  method: "POST",
606
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
716
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
607
717
  contentType: "application/json",
608
718
  requestType: "json",
609
719
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -697,7 +807,7 @@ class Conversation {
697
807
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
698
808
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, "/v1/conversations/feedback"),
699
809
  method: "POST",
700
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
810
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
701
811
  contentType: "application/json",
702
812
  requestType: "json",
703
813
  body: serializers.FeedbackRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -785,7 +895,7 @@ class Conversation {
785
895
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
786
896
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/submit-form`),
787
897
  method: "POST",
788
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
898
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
789
899
  contentType: "application/json",
790
900
  requestType: "json",
791
901
  body: serializers.SubmitActionFormRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
@@ -868,7 +978,7 @@ class Conversation {
868
978
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
869
979
  url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/metadata`),
870
980
  method: "POST",
871
- headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.5", "User-Agent": "mavenagi/1.0.5", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
981
+ headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Organization-Id": yield core.Supplier.get(this._options.organizationId), "X-Agent-Id": yield core.Supplier.get(this._options.agentId), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "mavenagi", "X-Fern-SDK-Version": "1.0.6", "User-Agent": "mavenagi/1.0.6", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
872
982
  contentType: "application/json",
873
983
  requestType: "json",
874
984
  body: serializers.conversation.addConversationMetadata.Request.jsonOrThrow(request, {
@@ -0,0 +1,19 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * reason: "GDPR deletion request 1234."
8
+ * }
9
+ */
10
+ export interface ConversationDeleteRequest {
11
+ /**
12
+ * The App ID of the conversation to delete. If not provided the ID of the calling app will be used.
13
+ */
14
+ appId?: string;
15
+ /**
16
+ * The reason for deleting the conversation. This message will replace all user messages in the conversation.
17
+ */
18
+ reason: string;
19
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1 +1,2 @@
1
1
  export { type ConversationGetRequest } from "./ConversationGetRequest";
2
+ export { type ConversationDeleteRequest } from "./ConversationDeleteRequest";
@@ -23,7 +23,7 @@ import * as MavenAGI from "../../../index";
23
23
  * }
24
24
  */
25
25
  export interface AskRequest {
26
- /** Externally supplied ID to uniquely identify this message within the conversation */
26
+ /** Externally supplied ID to uniquely identify this message within the conversation. If a message with this ID already exists it will be reused and will not be updated. */
27
27
  conversationMessageId: MavenAGI.EntityIdBase;
28
28
  /** Externally supplied ID to uniquely identify the user that created this message */
29
29
  userId: MavenAGI.EntityIdBase;