mavenagi 1.0.7 → 1.0.8

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 (883) hide show
  1. package/Client.d.ts +5 -0
  2. package/Client.js +13 -8
  3. package/README.md +17 -17
  4. package/api/resources/actions/client/Client.d.ts +2 -0
  5. package/api/resources/actions/client/Client.js +27 -17
  6. package/api/resources/analytics/client/Client.d.ts +2 -0
  7. package/api/resources/analytics/client/Client.js +27 -17
  8. package/api/resources/analytics/types/CellData.d.ts +1 -1
  9. package/api/resources/analytics/types/ChartResponse.d.ts +1 -1
  10. package/api/resources/analytics/types/{BarChartRequest.d.ts → ConversationBarChartRequest.d.ts} +1 -1
  11. package/api/resources/analytics/types/ConversationChartRequest.d.ts +4 -4
  12. package/{dist/api/resources/analytics/types/DateHistogramRequest.d.ts → api/resources/analytics/types/ConversationDateHistogramRequest.d.ts} +1 -1
  13. package/api/resources/analytics/types/ConversationMetric.d.ts +1 -1
  14. package/api/resources/analytics/types/{PieChartRequest.d.ts → ConversationPieChartRequest.d.ts} +1 -1
  15. package/api/resources/analytics/types/ConversationTableRequest.d.ts +2 -1
  16. package/api/resources/analytics/types/FeedbackMetric.d.ts +1 -1
  17. package/api/resources/analytics/types/FeedbackTableRequest.d.ts +1 -0
  18. package/api/resources/analytics/types/FieldValue.d.ts +1 -1
  19. package/api/resources/analytics/types/TimeInterval.d.ts +1 -1
  20. package/api/resources/analytics/types/index.d.ts +3 -3
  21. package/api/resources/analytics/types/index.js +3 -3
  22. package/api/resources/appSettings/client/Client.d.ts +2 -0
  23. package/api/resources/appSettings/client/Client.js +21 -11
  24. package/api/resources/commons/errors/BadRequestError.js +17 -7
  25. package/api/resources/commons/errors/NotFoundError.js +17 -7
  26. package/api/resources/commons/errors/ServerError.js +17 -7
  27. package/api/resources/commons/types/ActionParameterType.d.ts +1 -1
  28. package/api/resources/commons/types/AppUserIdentifyingPropertyType.d.ts +1 -1
  29. package/api/resources/commons/types/BotConversationMessageType.d.ts +1 -1
  30. package/api/resources/commons/types/BotResponse.d.ts +1 -1
  31. package/api/resources/commons/types/Capability.d.ts +1 -1
  32. package/api/resources/commons/types/ChartSpecSchema.d.ts +1 -1
  33. package/api/resources/commons/types/ConversationBase.d.ts +3 -1
  34. package/api/resources/commons/types/ConversationInformation.d.ts +8 -0
  35. package/api/resources/commons/types/ConversationMessageResponse.d.ts +1 -1
  36. package/api/resources/commons/types/ConversationPrecondition.d.ts +1 -1
  37. package/api/resources/commons/types/ConversationResponse.d.ts +2 -0
  38. package/api/resources/commons/types/DocumentInformation.d.ts +12 -0
  39. package/api/resources/commons/types/EntityType.d.ts +3 -1
  40. package/api/resources/commons/types/EntityType.js +2 -0
  41. package/api/resources/commons/types/EventTriggerType.d.ts +2 -1
  42. package/api/resources/commons/types/EventTriggerType.js +1 -0
  43. package/api/resources/commons/types/FeedbackType.d.ts +1 -1
  44. package/api/resources/commons/types/InboxItem.d.ts +19 -0
  45. package/api/resources/commons/types/InboxItemBase.d.ts +14 -0
  46. package/api/resources/commons/types/InboxItemBase.js +5 -0
  47. package/api/resources/commons/types/InboxItemDuplicateDocuments.d.ts +12 -0
  48. package/api/resources/commons/types/InboxItemDuplicateDocuments.js +5 -0
  49. package/api/resources/commons/types/InboxItemDuplicateKnowledgeBase.d.ts +12 -0
  50. package/api/resources/commons/types/InboxItemDuplicateKnowledgeBase.js +5 -0
  51. package/api/resources/commons/types/InboxItemFix.d.ts +16 -0
  52. package/api/resources/commons/types/InboxItemFix.js +5 -0
  53. package/api/resources/commons/types/InboxItemFixAddDocument.d.ts +10 -0
  54. package/api/resources/commons/types/InboxItemFixAddDocument.js +5 -0
  55. package/api/resources/commons/types/InboxItemFixBase.d.ts +8 -0
  56. package/api/resources/commons/types/InboxItemFixBase.js +5 -0
  57. package/api/resources/commons/types/InboxItemFixDeactivateDocument.d.ts +8 -0
  58. package/api/resources/commons/types/InboxItemFixDeactivateDocument.js +5 -0
  59. package/api/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.d.ts +8 -0
  60. package/api/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.js +5 -0
  61. package/api/resources/commons/types/InboxItemKnowledgeBaseAlert.d.ts +10 -0
  62. package/api/resources/commons/types/InboxItemKnowledgeBaseAlert.js +5 -0
  63. package/api/resources/commons/types/InboxItemMissingKnowledge.d.ts +10 -0
  64. package/api/resources/commons/types/InboxItemMissingKnowledge.js +5 -0
  65. package/api/resources/commons/types/InboxItemStatus.d.ts +26 -0
  66. package/api/resources/commons/types/InboxItemStatus.js +13 -0
  67. package/api/resources/commons/types/InboxItemType.d.ts +22 -0
  68. package/api/resources/commons/types/InboxItemType.js +12 -0
  69. package/api/resources/commons/types/KnowledgeBaseInformation.d.ts +8 -0
  70. package/api/resources/commons/types/KnowledgeBaseInformation.js +5 -0
  71. package/api/resources/commons/types/Page.d.ts +13 -0
  72. package/api/resources/commons/types/Page.js +5 -0
  73. package/api/resources/commons/types/Precondition.d.ts +1 -1
  74. package/api/resources/commons/types/PreconditionGroupOperator.d.ts +1 -1
  75. package/api/resources/commons/types/PreconditionOperator.d.ts +1 -1
  76. package/api/resources/commons/types/ResponseLength.d.ts +1 -1
  77. package/api/resources/commons/types/Sentiment.d.ts +1 -1
  78. package/api/resources/commons/types/UserConversationMessageType.d.ts +1 -1
  79. package/api/resources/commons/types/VisibilityType.d.ts +1 -1
  80. package/api/resources/commons/types/index.d.ts +17 -0
  81. package/api/resources/commons/types/index.js +17 -0
  82. package/api/resources/conversation/client/Client.d.ts +36 -1
  83. package/api/resources/conversation/client/Client.js +153 -44
  84. package/api/resources/conversation/types/ConversationField.d.ts +2 -1
  85. package/api/resources/conversation/types/ConversationField.js +1 -0
  86. package/api/resources/conversation/types/ConversationFilter.d.ts +1 -0
  87. package/api/resources/conversation/types/ConversationMetadata.d.ts +20 -0
  88. package/api/resources/conversation/types/ConversationMetadata.js +5 -0
  89. package/api/resources/conversation/types/FeedbackField.d.ts +1 -1
  90. package/api/resources/conversation/types/NumericConversationField.d.ts +2 -1
  91. package/api/resources/conversation/types/NumericConversationField.js +1 -0
  92. package/api/resources/conversation/types/Quality.d.ts +1 -1
  93. package/api/resources/conversation/types/QualityReason.d.ts +1 -1
  94. package/api/resources/conversation/types/ResolutionStatus.d.ts +9 -0
  95. package/api/resources/conversation/types/ResolutionStatus.js +11 -0
  96. package/api/resources/conversation/types/StreamResponse.d.ts +1 -1
  97. package/api/resources/conversation/types/UpdateMetadataRequest.d.ts +18 -0
  98. package/api/resources/conversation/types/UpdateMetadataRequest.js +5 -0
  99. package/api/resources/conversation/types/index.d.ts +3 -0
  100. package/api/resources/conversation/types/index.js +3 -0
  101. package/api/resources/inbox/client/Client.d.ts +121 -0
  102. package/api/resources/inbox/client/Client.js +488 -0
  103. package/api/resources/inbox/client/index.d.ts +1 -0
  104. package/api/resources/inbox/client/index.js +17 -0
  105. package/api/resources/inbox/client/requests/InboxItemFixRequest.d.ts +15 -0
  106. package/api/resources/inbox/client/requests/InboxItemFixRequest.js +5 -0
  107. package/api/resources/inbox/client/requests/InboxItemIgnoreRequest.d.ts +15 -0
  108. package/api/resources/inbox/client/requests/InboxItemIgnoreRequest.js +5 -0
  109. package/api/resources/inbox/client/requests/InboxItemRequest.d.ts +15 -0
  110. package/api/resources/inbox/client/requests/InboxItemRequest.js +5 -0
  111. package/api/resources/inbox/client/requests/index.d.ts +3 -0
  112. package/api/resources/inbox/client/requests/index.js +2 -0
  113. package/api/resources/inbox/index.d.ts +2 -0
  114. package/api/resources/inbox/index.js +18 -0
  115. package/api/resources/inbox/types/AddDocumentFixRequest.d.ts +10 -0
  116. package/api/resources/inbox/types/AddDocumentFixRequest.js +5 -0
  117. package/api/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +9 -0
  118. package/api/resources/inbox/types/ApplyInboxItemFixRequest.js +5 -0
  119. package/api/resources/inbox/types/BaseInboxSearchRequest.d.ts +9 -0
  120. package/api/resources/inbox/types/BaseInboxSearchRequest.js +5 -0
  121. package/api/resources/inbox/types/InboxSearchRequest.d.ts +14 -0
  122. package/api/resources/inbox/types/InboxSearchRequest.js +5 -0
  123. package/api/resources/inbox/types/InboxSearchResponse.d.ts +8 -0
  124. package/api/resources/inbox/types/InboxSearchResponse.js +5 -0
  125. package/api/resources/inbox/types/index.d.ts +5 -0
  126. package/api/resources/inbox/types/index.js +21 -0
  127. package/api/resources/index.d.ts +3 -0
  128. package/api/resources/index.js +21 -8
  129. package/api/resources/knowledge/client/Client.d.ts +2 -0
  130. package/api/resources/knowledge/client/Client.js +39 -29
  131. package/api/resources/knowledge/types/KnowledgeBaseType.d.ts +1 -1
  132. package/api/resources/knowledge/types/KnowledgeBaseVersionType.d.ts +1 -1
  133. package/api/resources/knowledge/types/KnowledgeDocumentContentType.d.ts +1 -1
  134. package/api/resources/translations/client/Client.d.ts +2 -0
  135. package/api/resources/translations/client/Client.js +21 -11
  136. package/api/resources/triggers/client/Client.d.ts +2 -0
  137. package/api/resources/triggers/client/Client.js +27 -17
  138. package/api/resources/users/client/Client.d.ts +2 -0
  139. package/api/resources/users/client/Client.js +31 -21
  140. package/core/auth/BearerToken.d.ts +1 -1
  141. package/core/fetcher/APIResponse.d.ts +1 -1
  142. package/core/fetcher/Fetcher.d.ts +2 -2
  143. package/core/fetcher/Fetcher.js +6 -5
  144. package/core/fetcher/Supplier.d.ts +1 -1
  145. package/core/fetcher/createRequestUrl.d.ts +1 -1
  146. package/core/fetcher/createRequestUrl.js +1 -2
  147. package/core/fetcher/getFetchFn.js +18 -9
  148. package/core/fetcher/getHeader.js +1 -2
  149. package/core/fetcher/getRequestBody.js +5 -5
  150. package/core/fetcher/getResponseBody.js +1 -2
  151. package/core/fetcher/makeRequest.d.ts +1 -1
  152. package/core/fetcher/requestWithRetries.js +4 -5
  153. package/core/fetcher/signals.d.ts +0 -1
  154. package/core/fetcher/signals.js +2 -3
  155. package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
  156. package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
  157. package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
  158. package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
  159. package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
  160. package/core/index.js +17 -7
  161. package/core/json.d.ts +15 -0
  162. package/core/json.js +24 -0
  163. package/core/runtime/runtime.d.ts +1 -1
  164. package/core/runtime/runtime.js +51 -41
  165. package/core/schemas/Schema.d.ts +7 -5
  166. package/core/schemas/Schema.js +2 -0
  167. package/core/schemas/builders/bigint/bigint.d.ts +1 -1
  168. package/core/schemas/builders/bigint/bigint.js +22 -19
  169. package/core/schemas/builders/date/date.js +1 -2
  170. package/core/schemas/builders/enum/enum.js +1 -2
  171. package/core/schemas/builders/lazy/lazy.d.ts +1 -1
  172. package/core/schemas/builders/lazy/lazy.js +3 -4
  173. package/core/schemas/builders/lazy/lazyObject.js +1 -2
  174. package/core/schemas/builders/list/list.js +1 -2
  175. package/core/schemas/builders/literals/booleanLiteral.js +1 -2
  176. package/core/schemas/builders/literals/stringLiteral.js +1 -2
  177. package/core/schemas/builders/object/object.d.ts +1 -1
  178. package/core/schemas/builders/object/object.js +3 -3
  179. package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
  180. package/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
  181. package/core/schemas/builders/object/property.js +2 -3
  182. package/core/schemas/builders/object/types.d.ts +11 -11
  183. package/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
  184. package/core/schemas/builders/object-like/types.d.ts +1 -1
  185. package/core/schemas/builders/record/record.js +2 -4
  186. package/core/schemas/builders/record/types.d.ts +2 -2
  187. package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
  188. package/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
  189. package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
  190. package/core/schemas/builders/set/set.js +1 -2
  191. package/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
  192. package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
  193. package/core/schemas/builders/union/discriminant.js +1 -2
  194. package/core/schemas/builders/union/types.d.ts +6 -6
  195. package/core/schemas/builders/union/union.d.ts +1 -1
  196. package/core/schemas/builders/union/union.js +1 -2
  197. package/core/schemas/utils/MaybePromise.d.ts +1 -1
  198. package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
  199. package/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
  200. package/core/schemas/utils/entries.d.ts +1 -1
  201. package/core/schemas/utils/entries.js +1 -2
  202. package/core/schemas/utils/filterObject.d.ts +1 -1
  203. package/core/schemas/utils/filterObject.js +1 -2
  204. package/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
  205. package/core/schemas/utils/isPlainObject.js +1 -2
  206. package/core/schemas/utils/keys.d.ts +1 -1
  207. package/core/schemas/utils/keys.js +1 -2
  208. package/core/schemas/utils/maybeSkipValidation.js +1 -2
  209. package/core/schemas/utils/partition.js +1 -2
  210. package/core/streaming-fetcher/Stream.d.ts +0 -1
  211. package/core/streaming-fetcher/Stream.js +20 -21
  212. package/dist/Client.d.ts +5 -0
  213. package/dist/Client.js +13 -8
  214. package/dist/api/resources/actions/client/Client.d.ts +2 -0
  215. package/dist/api/resources/actions/client/Client.js +27 -17
  216. package/dist/api/resources/analytics/client/Client.d.ts +2 -0
  217. package/dist/api/resources/analytics/client/Client.js +27 -17
  218. package/dist/api/resources/analytics/types/CellData.d.ts +1 -1
  219. package/dist/api/resources/analytics/types/ChartResponse.d.ts +1 -1
  220. package/dist/api/resources/analytics/types/{BarChartRequest.d.ts → ConversationBarChartRequest.d.ts} +1 -1
  221. package/dist/api/resources/analytics/types/ConversationBarChartRequest.js +5 -0
  222. package/dist/api/resources/analytics/types/ConversationChartRequest.d.ts +4 -4
  223. package/{api/resources/analytics/types/DateHistogramRequest.d.ts → dist/api/resources/analytics/types/ConversationDateHistogramRequest.d.ts} +1 -1
  224. package/dist/api/resources/analytics/types/ConversationDateHistogramRequest.js +5 -0
  225. package/dist/api/resources/analytics/types/ConversationMetric.d.ts +1 -1
  226. package/dist/api/resources/analytics/types/{PieChartRequest.d.ts → ConversationPieChartRequest.d.ts} +1 -1
  227. package/dist/api/resources/analytics/types/ConversationPieChartRequest.js +5 -0
  228. package/dist/api/resources/analytics/types/ConversationTableRequest.d.ts +2 -1
  229. package/dist/api/resources/analytics/types/FeedbackMetric.d.ts +1 -1
  230. package/dist/api/resources/analytics/types/FeedbackTableRequest.d.ts +1 -0
  231. package/dist/api/resources/analytics/types/FieldValue.d.ts +1 -1
  232. package/dist/api/resources/analytics/types/TimeInterval.d.ts +1 -1
  233. package/dist/api/resources/analytics/types/index.d.ts +3 -3
  234. package/dist/api/resources/analytics/types/index.js +3 -3
  235. package/dist/api/resources/appSettings/client/Client.d.ts +2 -0
  236. package/dist/api/resources/appSettings/client/Client.js +21 -11
  237. package/dist/api/resources/commons/errors/BadRequestError.js +17 -7
  238. package/dist/api/resources/commons/errors/NotFoundError.js +17 -7
  239. package/dist/api/resources/commons/errors/ServerError.js +17 -7
  240. package/dist/api/resources/commons/types/ActionParameterType.d.ts +1 -1
  241. package/dist/api/resources/commons/types/AppUserIdentifyingPropertyType.d.ts +1 -1
  242. package/dist/api/resources/commons/types/BotConversationMessageType.d.ts +1 -1
  243. package/dist/api/resources/commons/types/BotResponse.d.ts +1 -1
  244. package/dist/api/resources/commons/types/Capability.d.ts +1 -1
  245. package/dist/api/resources/commons/types/ChartSpecSchema.d.ts +1 -1
  246. package/dist/api/resources/commons/types/ConversationBase.d.ts +3 -1
  247. package/dist/api/resources/commons/types/ConversationInformation.d.ts +8 -0
  248. package/dist/api/resources/commons/types/ConversationInformation.js +5 -0
  249. package/dist/api/resources/commons/types/ConversationMessageResponse.d.ts +1 -1
  250. package/dist/api/resources/commons/types/ConversationPrecondition.d.ts +1 -1
  251. package/dist/api/resources/commons/types/ConversationResponse.d.ts +2 -0
  252. package/dist/api/resources/commons/types/DocumentInformation.d.ts +12 -0
  253. package/dist/api/resources/commons/types/DocumentInformation.js +5 -0
  254. package/dist/api/resources/commons/types/EntityType.d.ts +3 -1
  255. package/dist/api/resources/commons/types/EntityType.js +2 -0
  256. package/dist/api/resources/commons/types/EventTriggerType.d.ts +2 -1
  257. package/dist/api/resources/commons/types/EventTriggerType.js +1 -0
  258. package/dist/api/resources/commons/types/FeedbackType.d.ts +1 -1
  259. package/dist/api/resources/commons/types/InboxItem.d.ts +19 -0
  260. package/dist/api/resources/commons/types/InboxItem.js +5 -0
  261. package/dist/api/resources/commons/types/InboxItemBase.d.ts +14 -0
  262. package/dist/api/resources/commons/types/InboxItemBase.js +5 -0
  263. package/dist/api/resources/commons/types/InboxItemDuplicateDocuments.d.ts +12 -0
  264. package/dist/api/resources/commons/types/InboxItemDuplicateDocuments.js +5 -0
  265. package/dist/api/resources/commons/types/InboxItemDuplicateKnowledgeBase.d.ts +12 -0
  266. package/dist/api/resources/commons/types/InboxItemDuplicateKnowledgeBase.js +5 -0
  267. package/dist/api/resources/commons/types/InboxItemFix.d.ts +16 -0
  268. package/dist/api/resources/commons/types/InboxItemFix.js +5 -0
  269. package/dist/api/resources/commons/types/InboxItemFixAddDocument.d.ts +10 -0
  270. package/dist/api/resources/commons/types/InboxItemFixAddDocument.js +5 -0
  271. package/dist/api/resources/commons/types/InboxItemFixBase.d.ts +8 -0
  272. package/dist/api/resources/commons/types/InboxItemFixBase.js +5 -0
  273. package/dist/api/resources/commons/types/InboxItemFixDeactivateDocument.d.ts +8 -0
  274. package/dist/api/resources/commons/types/InboxItemFixDeactivateDocument.js +5 -0
  275. package/dist/api/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.d.ts +8 -0
  276. package/dist/api/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.js +5 -0
  277. package/dist/api/resources/commons/types/InboxItemKnowledgeBaseAlert.d.ts +10 -0
  278. package/dist/api/resources/commons/types/InboxItemKnowledgeBaseAlert.js +5 -0
  279. package/dist/api/resources/commons/types/InboxItemMissingKnowledge.d.ts +10 -0
  280. package/dist/api/resources/commons/types/InboxItemMissingKnowledge.js +5 -0
  281. package/dist/api/resources/commons/types/InboxItemStatus.d.ts +26 -0
  282. package/dist/api/resources/commons/types/InboxItemStatus.js +13 -0
  283. package/dist/api/resources/commons/types/InboxItemType.d.ts +22 -0
  284. package/dist/api/resources/commons/types/InboxItemType.js +12 -0
  285. package/dist/api/resources/commons/types/KnowledgeBaseInformation.d.ts +8 -0
  286. package/dist/api/resources/commons/types/KnowledgeBaseInformation.js +5 -0
  287. package/dist/api/resources/commons/types/Page.d.ts +13 -0
  288. package/dist/api/resources/commons/types/Page.js +5 -0
  289. package/dist/api/resources/commons/types/Precondition.d.ts +1 -1
  290. package/dist/api/resources/commons/types/PreconditionGroupOperator.d.ts +1 -1
  291. package/dist/api/resources/commons/types/PreconditionOperator.d.ts +1 -1
  292. package/dist/api/resources/commons/types/ResponseLength.d.ts +1 -1
  293. package/dist/api/resources/commons/types/Sentiment.d.ts +1 -1
  294. package/dist/api/resources/commons/types/UserConversationMessageType.d.ts +1 -1
  295. package/dist/api/resources/commons/types/VisibilityType.d.ts +1 -1
  296. package/dist/api/resources/commons/types/index.d.ts +17 -0
  297. package/dist/api/resources/commons/types/index.js +17 -0
  298. package/dist/api/resources/conversation/client/Client.d.ts +36 -1
  299. package/dist/api/resources/conversation/client/Client.js +153 -44
  300. package/dist/api/resources/conversation/types/ConversationField.d.ts +2 -1
  301. package/dist/api/resources/conversation/types/ConversationField.js +1 -0
  302. package/dist/api/resources/conversation/types/ConversationFilter.d.ts +1 -0
  303. package/dist/api/resources/conversation/types/ConversationMetadata.d.ts +20 -0
  304. package/dist/api/resources/conversation/types/ConversationMetadata.js +5 -0
  305. package/dist/api/resources/conversation/types/FeedbackField.d.ts +1 -1
  306. package/dist/api/resources/conversation/types/NumericConversationField.d.ts +2 -1
  307. package/dist/api/resources/conversation/types/NumericConversationField.js +1 -0
  308. package/dist/api/resources/conversation/types/Quality.d.ts +1 -1
  309. package/dist/api/resources/conversation/types/QualityReason.d.ts +1 -1
  310. package/dist/api/resources/conversation/types/ResolutionStatus.d.ts +9 -0
  311. package/dist/api/resources/conversation/types/ResolutionStatus.js +11 -0
  312. package/dist/api/resources/conversation/types/StreamResponse.d.ts +1 -1
  313. package/dist/api/resources/conversation/types/UpdateMetadataRequest.d.ts +18 -0
  314. package/dist/api/resources/conversation/types/UpdateMetadataRequest.js +5 -0
  315. package/dist/api/resources/conversation/types/index.d.ts +3 -0
  316. package/dist/api/resources/conversation/types/index.js +3 -0
  317. package/dist/api/resources/inbox/client/Client.d.ts +121 -0
  318. package/dist/api/resources/inbox/client/Client.js +488 -0
  319. package/dist/api/resources/inbox/client/index.d.ts +1 -0
  320. package/dist/api/resources/inbox/client/index.js +17 -0
  321. package/dist/api/resources/inbox/client/requests/InboxItemFixRequest.d.ts +15 -0
  322. package/dist/api/resources/inbox/client/requests/InboxItemFixRequest.js +5 -0
  323. package/dist/api/resources/inbox/client/requests/InboxItemIgnoreRequest.d.ts +15 -0
  324. package/dist/api/resources/inbox/client/requests/InboxItemIgnoreRequest.js +5 -0
  325. package/dist/api/resources/inbox/client/requests/InboxItemRequest.d.ts +15 -0
  326. package/dist/api/resources/inbox/client/requests/InboxItemRequest.js +5 -0
  327. package/dist/api/resources/inbox/client/requests/index.d.ts +3 -0
  328. package/dist/api/resources/inbox/client/requests/index.js +2 -0
  329. package/dist/api/resources/inbox/index.d.ts +2 -0
  330. package/dist/api/resources/inbox/index.js +18 -0
  331. package/dist/api/resources/inbox/types/AddDocumentFixRequest.d.ts +10 -0
  332. package/dist/api/resources/inbox/types/AddDocumentFixRequest.js +5 -0
  333. package/dist/api/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +9 -0
  334. package/dist/api/resources/inbox/types/ApplyInboxItemFixRequest.js +5 -0
  335. package/dist/api/resources/inbox/types/BaseInboxSearchRequest.d.ts +9 -0
  336. package/dist/api/resources/inbox/types/BaseInboxSearchRequest.js +5 -0
  337. package/dist/api/resources/inbox/types/InboxSearchRequest.d.ts +14 -0
  338. package/dist/api/resources/inbox/types/InboxSearchRequest.js +5 -0
  339. package/dist/api/resources/inbox/types/InboxSearchResponse.d.ts +8 -0
  340. package/dist/api/resources/inbox/types/InboxSearchResponse.js +5 -0
  341. package/dist/api/resources/inbox/types/index.d.ts +5 -0
  342. package/dist/api/resources/inbox/types/index.js +21 -0
  343. package/dist/api/resources/index.d.ts +3 -0
  344. package/dist/api/resources/index.js +21 -8
  345. package/dist/api/resources/knowledge/client/Client.d.ts +2 -0
  346. package/dist/api/resources/knowledge/client/Client.js +39 -29
  347. package/dist/api/resources/knowledge/types/KnowledgeBaseType.d.ts +1 -1
  348. package/dist/api/resources/knowledge/types/KnowledgeBaseVersionType.d.ts +1 -1
  349. package/dist/api/resources/knowledge/types/KnowledgeDocumentContentType.d.ts +1 -1
  350. package/dist/api/resources/translations/client/Client.d.ts +2 -0
  351. package/dist/api/resources/translations/client/Client.js +21 -11
  352. package/dist/api/resources/triggers/client/Client.d.ts +2 -0
  353. package/dist/api/resources/triggers/client/Client.js +27 -17
  354. package/dist/api/resources/users/client/Client.d.ts +2 -0
  355. package/dist/api/resources/users/client/Client.js +31 -21
  356. package/dist/core/auth/BearerToken.d.ts +1 -1
  357. package/dist/core/fetcher/APIResponse.d.ts +1 -1
  358. package/dist/core/fetcher/Fetcher.d.ts +2 -2
  359. package/dist/core/fetcher/Fetcher.js +6 -5
  360. package/dist/core/fetcher/Supplier.d.ts +1 -1
  361. package/dist/core/fetcher/createRequestUrl.d.ts +1 -1
  362. package/dist/core/fetcher/createRequestUrl.js +1 -2
  363. package/dist/core/fetcher/getFetchFn.js +18 -9
  364. package/dist/core/fetcher/getHeader.js +1 -2
  365. package/dist/core/fetcher/getRequestBody.js +5 -5
  366. package/dist/core/fetcher/getResponseBody.js +1 -2
  367. package/dist/core/fetcher/makeRequest.d.ts +1 -1
  368. package/dist/core/fetcher/requestWithRetries.js +4 -5
  369. package/dist/core/fetcher/signals.d.ts +0 -1
  370. package/dist/core/fetcher/signals.js +2 -3
  371. package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -1
  372. package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +6 -4
  373. package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +1 -1
  374. package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +1 -1
  375. package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +18 -9
  376. package/dist/core/index.js +17 -7
  377. package/dist/core/json.d.ts +15 -0
  378. package/dist/core/json.js +24 -0
  379. package/dist/core/runtime/runtime.d.ts +1 -1
  380. package/dist/core/runtime/runtime.js +51 -41
  381. package/dist/core/schemas/Schema.d.ts +7 -5
  382. package/dist/core/schemas/Schema.js +2 -0
  383. package/dist/core/schemas/builders/bigint/bigint.d.ts +1 -1
  384. package/dist/core/schemas/builders/bigint/bigint.js +22 -19
  385. package/dist/core/schemas/builders/date/date.js +1 -2
  386. package/dist/core/schemas/builders/enum/enum.js +1 -2
  387. package/dist/core/schemas/builders/lazy/lazy.d.ts +1 -1
  388. package/dist/core/schemas/builders/lazy/lazy.js +3 -4
  389. package/dist/core/schemas/builders/lazy/lazyObject.js +1 -2
  390. package/dist/core/schemas/builders/list/list.js +1 -2
  391. package/dist/core/schemas/builders/literals/booleanLiteral.js +1 -2
  392. package/dist/core/schemas/builders/literals/stringLiteral.js +1 -2
  393. package/dist/core/schemas/builders/object/object.d.ts +1 -1
  394. package/dist/core/schemas/builders/object/object.js +3 -3
  395. package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +3 -3
  396. package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +1 -2
  397. package/dist/core/schemas/builders/object/property.js +2 -3
  398. package/dist/core/schemas/builders/object/types.d.ts +11 -11
  399. package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +2 -3
  400. package/dist/core/schemas/builders/object-like/types.d.ts +1 -1
  401. package/dist/core/schemas/builders/record/record.js +2 -4
  402. package/dist/core/schemas/builders/record/types.d.ts +2 -2
  403. package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +4 -0
  404. package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +67 -4
  405. package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +1 -2
  406. package/dist/core/schemas/builders/set/set.js +1 -2
  407. package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +4 -4
  408. package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +1 -2
  409. package/dist/core/schemas/builders/union/discriminant.js +1 -2
  410. package/dist/core/schemas/builders/union/types.d.ts +6 -6
  411. package/dist/core/schemas/builders/union/union.d.ts +1 -1
  412. package/dist/core/schemas/builders/union/union.js +1 -2
  413. package/dist/core/schemas/utils/MaybePromise.d.ts +1 -1
  414. package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +4 -4
  415. package/dist/core/schemas/utils/createIdentitySchemaCreator.js +1 -2
  416. package/dist/core/schemas/utils/entries.d.ts +1 -1
  417. package/dist/core/schemas/utils/entries.js +1 -2
  418. package/dist/core/schemas/utils/filterObject.d.ts +1 -1
  419. package/dist/core/schemas/utils/filterObject.js +1 -2
  420. package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +1 -2
  421. package/dist/core/schemas/utils/isPlainObject.js +1 -2
  422. package/dist/core/schemas/utils/keys.d.ts +1 -1
  423. package/dist/core/schemas/utils/keys.js +1 -2
  424. package/dist/core/schemas/utils/maybeSkipValidation.js +1 -2
  425. package/dist/core/schemas/utils/partition.js +1 -2
  426. package/dist/core/streaming-fetcher/Stream.d.ts +0 -1
  427. package/dist/core/streaming-fetcher/Stream.js +20 -21
  428. package/dist/environments.d.ts +1 -1
  429. package/dist/errors/MavenAGIError.js +2 -1
  430. package/dist/index.d.ts +1 -0
  431. package/dist/index.js +19 -8
  432. package/dist/serialization/resources/actions/types/ActionRequest.js +17 -7
  433. package/dist/serialization/resources/analytics/types/BarChartResponse.js +17 -7
  434. package/dist/serialization/resources/analytics/types/CellData.js +17 -7
  435. package/dist/serialization/resources/analytics/types/ChartResponse.js +17 -7
  436. package/dist/serialization/resources/analytics/types/ColumnDefinitionBase.js +17 -7
  437. package/dist/serialization/resources/analytics/types/ConversationAnalyticsRequest.js +17 -7
  438. package/dist/serialization/resources/analytics/types/ConversationAverage.js +17 -7
  439. package/dist/serialization/resources/analytics/types/{BarChartRequest.d.ts → ConversationBarChartRequest.d.ts} +2 -2
  440. package/dist/serialization/resources/analytics/types/{BarChartRequest.js → ConversationBarChartRequest.js} +19 -9
  441. package/dist/serialization/resources/analytics/types/ConversationBasicMetric.js +17 -7
  442. package/dist/serialization/resources/analytics/types/ConversationChartRequest.d.ts +6 -6
  443. package/dist/serialization/resources/analytics/types/ConversationChartRequest.js +23 -13
  444. package/dist/serialization/resources/analytics/types/ConversationColumnDefinition.js +17 -7
  445. package/dist/serialization/resources/analytics/types/ConversationCount.js +17 -7
  446. package/{serialization/resources/analytics/types/DateHistogramRequest.d.ts → dist/serialization/resources/analytics/types/ConversationDateHistogramRequest.d.ts} +2 -2
  447. package/{serialization/resources/analytics/types/DateHistogramRequest.js → dist/serialization/resources/analytics/types/ConversationDateHistogramRequest.js} +19 -9
  448. package/dist/serialization/resources/analytics/types/ConversationDistinctCount.js +17 -7
  449. package/dist/serialization/resources/analytics/types/ConversationGroupBy.js +17 -7
  450. package/dist/serialization/resources/analytics/types/ConversationMax.js +17 -7
  451. package/dist/serialization/resources/analytics/types/ConversationMedian.js +17 -7
  452. package/dist/serialization/resources/analytics/types/ConversationMetric.js +17 -7
  453. package/dist/serialization/resources/analytics/types/ConversationMin.js +17 -7
  454. package/dist/serialization/resources/analytics/types/ConversationNumericMetric.js +17 -7
  455. package/dist/serialization/resources/analytics/types/ConversationPercentile.js +17 -7
  456. package/{serialization/resources/analytics/types/PieChartRequest.d.ts → dist/serialization/resources/analytics/types/ConversationPieChartRequest.d.ts} +2 -2
  457. package/{serialization/resources/analytics/types/PieChartRequest.js → dist/serialization/resources/analytics/types/ConversationPieChartRequest.js} +19 -9
  458. package/dist/serialization/resources/analytics/types/ConversationRow.js +17 -7
  459. package/dist/serialization/resources/analytics/types/ConversationSum.js +17 -7
  460. package/dist/serialization/resources/analytics/types/ConversationTableRequest.js +17 -7
  461. package/dist/serialization/resources/analytics/types/ConversationTableResponse.js +17 -7
  462. package/dist/serialization/resources/analytics/types/DateHistogramResponse.js +17 -7
  463. package/dist/serialization/resources/analytics/types/FeedbackAnalyticsRequest.js +17 -7
  464. package/dist/serialization/resources/analytics/types/FeedbackColumnDefinition.js +17 -7
  465. package/dist/serialization/resources/analytics/types/FeedbackCount.js +17 -7
  466. package/dist/serialization/resources/analytics/types/FeedbackDistinctCount.js +17 -7
  467. package/dist/serialization/resources/analytics/types/FeedbackGroupBy.js +17 -7
  468. package/dist/serialization/resources/analytics/types/FeedbackMetric.js +17 -7
  469. package/dist/serialization/resources/analytics/types/FeedbackRow.js +17 -7
  470. package/dist/serialization/resources/analytics/types/FeedbackTableRequest.js +17 -7
  471. package/dist/serialization/resources/analytics/types/FeedbackTableResponse.js +17 -7
  472. package/dist/serialization/resources/analytics/types/FieldValue.js +17 -7
  473. package/dist/serialization/resources/analytics/types/GroupByBase.js +17 -7
  474. package/dist/serialization/resources/analytics/types/LabeledPoint.js +17 -7
  475. package/dist/serialization/resources/analytics/types/PieChartResponse.js +17 -7
  476. package/dist/serialization/resources/analytics/types/Range.js +17 -7
  477. package/dist/serialization/resources/analytics/types/RowBase.js +17 -7
  478. package/dist/serialization/resources/analytics/types/Series.js +17 -7
  479. package/dist/serialization/resources/analytics/types/TableResponseBase.js +17 -7
  480. package/dist/serialization/resources/analytics/types/TimeDataPoint.js +17 -7
  481. package/dist/serialization/resources/analytics/types/TimeInterval.js +17 -7
  482. package/dist/serialization/resources/analytics/types/TimeSeries.js +17 -7
  483. package/dist/serialization/resources/analytics/types/index.d.ts +3 -3
  484. package/dist/serialization/resources/analytics/types/index.js +3 -3
  485. package/dist/serialization/resources/appSettings/client/get.js +17 -7
  486. package/dist/serialization/resources/appSettings/client/index.js +17 -7
  487. package/dist/serialization/resources/commons/types/ActionBase.js +17 -7
  488. package/dist/serialization/resources/commons/types/ActionEnumOption.js +17 -7
  489. package/dist/serialization/resources/commons/types/ActionFormField.js +17 -7
  490. package/dist/serialization/resources/commons/types/ActionParameter.js +17 -7
  491. package/dist/serialization/resources/commons/types/ActionParameterType.js +17 -7
  492. package/dist/serialization/resources/commons/types/ActionResponse.js +17 -7
  493. package/dist/serialization/resources/commons/types/AppUser.js +17 -7
  494. package/dist/serialization/resources/commons/types/AppUserIdentifier.js +17 -7
  495. package/dist/serialization/resources/commons/types/AppUserIdentifyingPropertyType.js +17 -7
  496. package/dist/serialization/resources/commons/types/AppUserRequest.js +17 -7
  497. package/dist/serialization/resources/commons/types/AppUserResponse.js +17 -7
  498. package/dist/serialization/resources/commons/types/BotActionFormResponse.js +17 -7
  499. package/dist/serialization/resources/commons/types/BotChartResponse.js +17 -7
  500. package/dist/serialization/resources/commons/types/BotConversationMessageType.js +17 -7
  501. package/dist/serialization/resources/commons/types/BotMessage.js +17 -7
  502. package/dist/serialization/resources/commons/types/BotResponse.js +17 -7
  503. package/dist/serialization/resources/commons/types/BotResponseMetadata.js +17 -7
  504. package/dist/serialization/resources/commons/types/BotTextResponse.js +17 -7
  505. package/dist/serialization/resources/commons/types/Capability.js +17 -7
  506. package/dist/serialization/resources/commons/types/ChartSpecSchema.js +17 -7
  507. package/dist/serialization/resources/commons/types/ConversationAnalysis.js +17 -7
  508. package/dist/serialization/resources/commons/types/ConversationBase.d.ts +1 -0
  509. package/dist/serialization/resources/commons/types/ConversationBase.js +18 -7
  510. package/dist/serialization/resources/commons/types/ConversationExecutedActionPrecondition.js +17 -7
  511. package/dist/serialization/resources/commons/types/ConversationInformation.d.ts +13 -0
  512. package/dist/serialization/resources/commons/types/ConversationInformation.js +44 -0
  513. package/dist/serialization/resources/commons/types/ConversationMessageBase.js +17 -7
  514. package/dist/serialization/resources/commons/types/ConversationMessageResponse.js +17 -7
  515. package/dist/serialization/resources/commons/types/ConversationPrecondition.js +17 -7
  516. package/dist/serialization/resources/commons/types/ConversationResponse.js +17 -7
  517. package/dist/serialization/resources/commons/types/ConversationSummary.js +17 -7
  518. package/dist/serialization/resources/commons/types/DocumentInformation.d.ts +15 -0
  519. package/dist/serialization/resources/commons/types/DocumentInformation.js +46 -0
  520. package/dist/serialization/resources/commons/types/EntityId.js +17 -7
  521. package/dist/serialization/resources/commons/types/EntityIdBase.js +17 -7
  522. package/dist/serialization/resources/commons/types/EntityIdFilter.js +17 -7
  523. package/dist/serialization/resources/commons/types/EntityIdWithoutAgent.js +17 -7
  524. package/dist/serialization/resources/commons/types/EntityType.d.ts +1 -1
  525. package/dist/serialization/resources/commons/types/EntityType.js +19 -7
  526. package/dist/serialization/resources/commons/types/ErrorMessage.js +17 -7
  527. package/dist/serialization/resources/commons/types/EventTriggerBase.js +17 -7
  528. package/dist/serialization/resources/commons/types/EventTriggerResponse.js +17 -7
  529. package/dist/serialization/resources/commons/types/EventTriggerType.d.ts +1 -1
  530. package/dist/serialization/resources/commons/types/EventTriggerType.js +18 -8
  531. package/dist/serialization/resources/commons/types/Feedback.js +17 -7
  532. package/dist/serialization/resources/commons/types/FeedbackBase.js +17 -7
  533. package/dist/serialization/resources/commons/types/FeedbackType.js +17 -7
  534. package/dist/serialization/resources/commons/types/InboxItem.d.ts +26 -0
  535. package/dist/serialization/resources/commons/types/InboxItem.js +55 -0
  536. package/dist/serialization/resources/commons/types/InboxItemBase.d.ts +17 -0
  537. package/dist/serialization/resources/commons/types/InboxItemBase.js +48 -0
  538. package/dist/serialization/resources/commons/types/InboxItemDuplicateDocuments.d.ts +17 -0
  539. package/dist/serialization/resources/commons/types/InboxItemDuplicateDocuments.js +50 -0
  540. package/dist/serialization/resources/commons/types/InboxItemDuplicateKnowledgeBase.d.ts +17 -0
  541. package/dist/serialization/resources/commons/types/InboxItemDuplicateKnowledgeBase.js +50 -0
  542. package/dist/serialization/resources/commons/types/InboxItemFix.d.ts +22 -0
  543. package/dist/serialization/resources/commons/types/InboxItemFix.js +53 -0
  544. package/dist/serialization/resources/commons/types/InboxItemFixAddDocument.d.ts +14 -0
  545. package/dist/serialization/resources/commons/types/InboxItemFixAddDocument.js +47 -0
  546. package/dist/serialization/resources/commons/types/InboxItemFixBase.d.ts +13 -0
  547. package/dist/serialization/resources/commons/types/InboxItemFixBase.js +44 -0
  548. package/dist/serialization/resources/commons/types/InboxItemFixDeactivateDocument.d.ts +14 -0
  549. package/dist/serialization/resources/commons/types/InboxItemFixDeactivateDocument.js +47 -0
  550. package/dist/serialization/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.d.ts +14 -0
  551. package/dist/serialization/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.js +47 -0
  552. package/dist/serialization/resources/commons/types/InboxItemKnowledgeBaseAlert.d.ts +16 -0
  553. package/dist/serialization/resources/commons/types/InboxItemKnowledgeBaseAlert.js +49 -0
  554. package/dist/serialization/resources/commons/types/InboxItemMissingKnowledge.d.ts +16 -0
  555. package/dist/serialization/resources/commons/types/InboxItemMissingKnowledge.js +49 -0
  556. package/dist/serialization/resources/commons/types/InboxItemStatus.d.ts +10 -0
  557. package/dist/serialization/resources/commons/types/InboxItemStatus.js +41 -0
  558. package/dist/serialization/resources/commons/types/InboxItemType.d.ts +10 -0
  559. package/dist/serialization/resources/commons/types/InboxItemType.js +46 -0
  560. package/dist/serialization/resources/commons/types/KnowledgeBaseInformation.d.ts +13 -0
  561. package/dist/serialization/resources/commons/types/KnowledgeBaseInformation.js +44 -0
  562. package/dist/serialization/resources/commons/types/MetadataPrecondition.js +17 -7
  563. package/dist/serialization/resources/commons/types/Page.d.ts +15 -0
  564. package/dist/serialization/resources/commons/types/Page.js +46 -0
  565. package/dist/serialization/resources/commons/types/Precondition.js +17 -7
  566. package/dist/serialization/resources/commons/types/PreconditionBase.js +17 -7
  567. package/dist/serialization/resources/commons/types/PreconditionGroup.js +17 -7
  568. package/dist/serialization/resources/commons/types/PreconditionGroupOperator.js +17 -7
  569. package/dist/serialization/resources/commons/types/PreconditionOperator.js +17 -7
  570. package/dist/serialization/resources/commons/types/ResponseConfig.js +17 -7
  571. package/dist/serialization/resources/commons/types/ResponseConfigPrecondition.js +17 -7
  572. package/dist/serialization/resources/commons/types/ResponseLength.js +17 -7
  573. package/dist/serialization/resources/commons/types/Sentiment.js +17 -7
  574. package/dist/serialization/resources/commons/types/Source.js +17 -7
  575. package/dist/serialization/resources/commons/types/TagsPrecondition.js +17 -7
  576. package/dist/serialization/resources/commons/types/UserConversationMessageType.js +17 -7
  577. package/dist/serialization/resources/commons/types/UserData.js +17 -7
  578. package/dist/serialization/resources/commons/types/UserMessage.js +17 -7
  579. package/dist/serialization/resources/commons/types/UserMessageAttachment.js +17 -7
  580. package/dist/serialization/resources/commons/types/UserMessageBase.js +17 -7
  581. package/dist/serialization/resources/commons/types/VisibilityType.js +17 -7
  582. package/dist/serialization/resources/commons/types/index.d.ts +17 -0
  583. package/dist/serialization/resources/commons/types/index.js +17 -0
  584. package/dist/serialization/resources/conversation/client/addConversationMetadata.js +17 -7
  585. package/dist/serialization/resources/conversation/client/appendNewMessages.js +17 -7
  586. package/dist/serialization/resources/conversation/client/index.js +17 -7
  587. package/dist/serialization/resources/conversation/types/AskRequest.js +17 -7
  588. package/dist/serialization/resources/conversation/types/AskStreamActionEvent.js +17 -7
  589. package/dist/serialization/resources/conversation/types/AskStreamChartEvent.js +17 -7
  590. package/dist/serialization/resources/conversation/types/AskStreamEndEvent.js +17 -7
  591. package/dist/serialization/resources/conversation/types/AskStreamMetadataEvent.js +17 -7
  592. package/dist/serialization/resources/conversation/types/AskStreamStartEvent.js +17 -7
  593. package/dist/serialization/resources/conversation/types/AskStreamTextEvent.js +17 -7
  594. package/dist/serialization/resources/conversation/types/Attachment.js +17 -7
  595. package/dist/serialization/resources/conversation/types/CategorizationResponse.js +17 -7
  596. package/dist/serialization/resources/conversation/types/ConversationField.d.ts +1 -1
  597. package/dist/serialization/resources/conversation/types/ConversationField.js +18 -7
  598. package/dist/serialization/resources/conversation/types/ConversationFilter.d.ts +2 -0
  599. package/dist/serialization/resources/conversation/types/ConversationFilter.js +19 -7
  600. package/dist/serialization/resources/conversation/types/ConversationMessageRequest.js +17 -7
  601. package/dist/serialization/resources/conversation/types/ConversationMetadata.d.ts +12 -0
  602. package/dist/serialization/resources/conversation/types/ConversationMetadata.js +43 -0
  603. package/dist/serialization/resources/conversation/types/ConversationRequest.js +17 -7
  604. package/dist/serialization/resources/conversation/types/FeedbackField.js +17 -7
  605. package/dist/serialization/resources/conversation/types/FeedbackFilter.js +17 -7
  606. package/dist/serialization/resources/conversation/types/FeedbackRequest.js +17 -7
  607. package/dist/serialization/resources/conversation/types/GenerateMavenSuggestionsRequest.js +17 -7
  608. package/dist/serialization/resources/conversation/types/NumericConversationField.d.ts +1 -1
  609. package/dist/serialization/resources/conversation/types/NumericConversationField.js +18 -7
  610. package/dist/serialization/resources/conversation/types/Quality.js +17 -7
  611. package/dist/serialization/resources/conversation/types/QualityReason.js +17 -7
  612. package/dist/serialization/resources/conversation/types/ResolutionStatus.d.ts +10 -0
  613. package/dist/serialization/resources/conversation/types/ResolutionStatus.js +41 -0
  614. package/dist/serialization/resources/conversation/types/StreamResponse.js +17 -7
  615. package/dist/serialization/resources/conversation/types/SubmitActionFormRequest.js +17 -7
  616. package/dist/serialization/resources/conversation/types/UpdateMetadataRequest.d.ts +13 -0
  617. package/dist/serialization/resources/conversation/types/UpdateMetadataRequest.js +44 -0
  618. package/dist/serialization/resources/conversation/types/index.d.ts +3 -0
  619. package/dist/serialization/resources/conversation/types/index.js +3 -0
  620. package/dist/serialization/resources/inbox/index.d.ts +1 -0
  621. package/dist/serialization/resources/inbox/index.js +17 -0
  622. package/dist/serialization/resources/inbox/types/AddDocumentFixRequest.d.ts +14 -0
  623. package/dist/serialization/resources/inbox/types/AddDocumentFixRequest.js +45 -0
  624. package/dist/serialization/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +14 -0
  625. package/dist/serialization/resources/inbox/types/ApplyInboxItemFixRequest.js +45 -0
  626. package/dist/serialization/resources/inbox/types/BaseInboxSearchRequest.d.ts +13 -0
  627. package/dist/serialization/resources/inbox/types/BaseInboxSearchRequest.js +44 -0
  628. package/dist/serialization/resources/inbox/types/InboxSearchRequest.d.ts +18 -0
  629. package/dist/serialization/resources/inbox/types/InboxSearchRequest.js +51 -0
  630. package/dist/serialization/resources/inbox/types/InboxSearchResponse.d.ts +14 -0
  631. package/dist/serialization/resources/inbox/types/InboxSearchResponse.js +47 -0
  632. package/dist/serialization/resources/inbox/types/index.d.ts +5 -0
  633. package/dist/serialization/resources/inbox/types/index.js +21 -0
  634. package/dist/serialization/resources/index.d.ts +2 -0
  635. package/dist/serialization/resources/index.js +20 -8
  636. package/dist/serialization/resources/knowledge/types/BaseKnowledgeDocument.js +17 -7
  637. package/dist/serialization/resources/knowledge/types/KnowledgeBaseProperties.js +17 -7
  638. package/dist/serialization/resources/knowledge/types/KnowledgeBaseRequest.js +17 -7
  639. package/dist/serialization/resources/knowledge/types/KnowledgeBaseResponse.js +17 -7
  640. package/dist/serialization/resources/knowledge/types/KnowledgeBaseType.js +17 -7
  641. package/dist/serialization/resources/knowledge/types/KnowledgeBaseVersion.js +17 -7
  642. package/dist/serialization/resources/knowledge/types/KnowledgeBaseVersionType.js +17 -7
  643. package/dist/serialization/resources/knowledge/types/KnowledgeDocumentContentType.js +17 -7
  644. package/dist/serialization/resources/knowledge/types/KnowledgeDocumentRequest.js +17 -7
  645. package/dist/serialization/resources/knowledge/types/KnowledgeDocumentResponse.js +17 -7
  646. package/dist/serialization/resources/translations/types/TranslationRequest.js +17 -7
  647. package/dist/serialization/resources/translations/types/TranslationResponse.js +17 -7
  648. package/dist/serialization/resources/triggers/types/EventTriggerRequest.js +17 -7
  649. package/dist/version.d.ts +1 -1
  650. package/dist/version.js +1 -1
  651. package/environments.d.ts +1 -1
  652. package/errors/MavenAGIError.js +2 -1
  653. package/index.d.ts +1 -0
  654. package/index.js +19 -8
  655. package/{jest.config.js → jest.config.mjs} +4 -1
  656. package/package.json +16 -16
  657. package/reference.md +461 -15
  658. package/scripts/rename-to-esm-files.js +115 -0
  659. package/serialization/resources/actions/types/ActionRequest.js +17 -7
  660. package/serialization/resources/analytics/types/BarChartResponse.js +17 -7
  661. package/serialization/resources/analytics/types/CellData.js +17 -7
  662. package/serialization/resources/analytics/types/ChartResponse.js +17 -7
  663. package/serialization/resources/analytics/types/ColumnDefinitionBase.js +17 -7
  664. package/serialization/resources/analytics/types/ConversationAnalyticsRequest.js +17 -7
  665. package/serialization/resources/analytics/types/ConversationAverage.js +17 -7
  666. package/serialization/resources/analytics/types/{BarChartRequest.d.ts → ConversationBarChartRequest.d.ts} +2 -2
  667. package/serialization/resources/analytics/types/{BarChartRequest.js → ConversationBarChartRequest.js} +19 -9
  668. package/serialization/resources/analytics/types/ConversationBasicMetric.js +17 -7
  669. package/serialization/resources/analytics/types/ConversationChartRequest.d.ts +6 -6
  670. package/serialization/resources/analytics/types/ConversationChartRequest.js +23 -13
  671. package/serialization/resources/analytics/types/ConversationColumnDefinition.js +17 -7
  672. package/serialization/resources/analytics/types/ConversationCount.js +17 -7
  673. package/{dist/serialization/resources/analytics/types/DateHistogramRequest.d.ts → serialization/resources/analytics/types/ConversationDateHistogramRequest.d.ts} +2 -2
  674. package/{dist/serialization/resources/analytics/types/DateHistogramRequest.js → serialization/resources/analytics/types/ConversationDateHistogramRequest.js} +19 -9
  675. package/serialization/resources/analytics/types/ConversationDistinctCount.js +17 -7
  676. package/serialization/resources/analytics/types/ConversationGroupBy.js +17 -7
  677. package/serialization/resources/analytics/types/ConversationMax.js +17 -7
  678. package/serialization/resources/analytics/types/ConversationMedian.js +17 -7
  679. package/serialization/resources/analytics/types/ConversationMetric.js +17 -7
  680. package/serialization/resources/analytics/types/ConversationMin.js +17 -7
  681. package/serialization/resources/analytics/types/ConversationNumericMetric.js +17 -7
  682. package/serialization/resources/analytics/types/ConversationPercentile.js +17 -7
  683. package/{dist/serialization/resources/analytics/types/PieChartRequest.d.ts → serialization/resources/analytics/types/ConversationPieChartRequest.d.ts} +2 -2
  684. package/{dist/serialization/resources/analytics/types/PieChartRequest.js → serialization/resources/analytics/types/ConversationPieChartRequest.js} +19 -9
  685. package/serialization/resources/analytics/types/ConversationRow.js +17 -7
  686. package/serialization/resources/analytics/types/ConversationSum.js +17 -7
  687. package/serialization/resources/analytics/types/ConversationTableRequest.js +17 -7
  688. package/serialization/resources/analytics/types/ConversationTableResponse.js +17 -7
  689. package/serialization/resources/analytics/types/DateHistogramResponse.js +17 -7
  690. package/serialization/resources/analytics/types/FeedbackAnalyticsRequest.js +17 -7
  691. package/serialization/resources/analytics/types/FeedbackColumnDefinition.js +17 -7
  692. package/serialization/resources/analytics/types/FeedbackCount.js +17 -7
  693. package/serialization/resources/analytics/types/FeedbackDistinctCount.js +17 -7
  694. package/serialization/resources/analytics/types/FeedbackGroupBy.js +17 -7
  695. package/serialization/resources/analytics/types/FeedbackMetric.js +17 -7
  696. package/serialization/resources/analytics/types/FeedbackRow.js +17 -7
  697. package/serialization/resources/analytics/types/FeedbackTableRequest.js +17 -7
  698. package/serialization/resources/analytics/types/FeedbackTableResponse.js +17 -7
  699. package/serialization/resources/analytics/types/FieldValue.js +17 -7
  700. package/serialization/resources/analytics/types/GroupByBase.js +17 -7
  701. package/serialization/resources/analytics/types/LabeledPoint.js +17 -7
  702. package/serialization/resources/analytics/types/PieChartResponse.js +17 -7
  703. package/serialization/resources/analytics/types/Range.js +17 -7
  704. package/serialization/resources/analytics/types/RowBase.js +17 -7
  705. package/serialization/resources/analytics/types/Series.js +17 -7
  706. package/serialization/resources/analytics/types/TableResponseBase.js +17 -7
  707. package/serialization/resources/analytics/types/TimeDataPoint.js +17 -7
  708. package/serialization/resources/analytics/types/TimeInterval.js +17 -7
  709. package/serialization/resources/analytics/types/TimeSeries.js +17 -7
  710. package/serialization/resources/analytics/types/index.d.ts +3 -3
  711. package/serialization/resources/analytics/types/index.js +3 -3
  712. package/serialization/resources/appSettings/client/get.js +17 -7
  713. package/serialization/resources/appSettings/client/index.js +17 -7
  714. package/serialization/resources/commons/types/ActionBase.js +17 -7
  715. package/serialization/resources/commons/types/ActionEnumOption.js +17 -7
  716. package/serialization/resources/commons/types/ActionFormField.js +17 -7
  717. package/serialization/resources/commons/types/ActionParameter.js +17 -7
  718. package/serialization/resources/commons/types/ActionParameterType.js +17 -7
  719. package/serialization/resources/commons/types/ActionResponse.js +17 -7
  720. package/serialization/resources/commons/types/AppUser.js +17 -7
  721. package/serialization/resources/commons/types/AppUserIdentifier.js +17 -7
  722. package/serialization/resources/commons/types/AppUserIdentifyingPropertyType.js +17 -7
  723. package/serialization/resources/commons/types/AppUserRequest.js +17 -7
  724. package/serialization/resources/commons/types/AppUserResponse.js +17 -7
  725. package/serialization/resources/commons/types/BotActionFormResponse.js +17 -7
  726. package/serialization/resources/commons/types/BotChartResponse.js +17 -7
  727. package/serialization/resources/commons/types/BotConversationMessageType.js +17 -7
  728. package/serialization/resources/commons/types/BotMessage.js +17 -7
  729. package/serialization/resources/commons/types/BotResponse.js +17 -7
  730. package/serialization/resources/commons/types/BotResponseMetadata.js +17 -7
  731. package/serialization/resources/commons/types/BotTextResponse.js +17 -7
  732. package/serialization/resources/commons/types/Capability.js +17 -7
  733. package/serialization/resources/commons/types/ChartSpecSchema.js +17 -7
  734. package/serialization/resources/commons/types/ConversationAnalysis.js +17 -7
  735. package/serialization/resources/commons/types/ConversationBase.d.ts +1 -0
  736. package/serialization/resources/commons/types/ConversationBase.js +18 -7
  737. package/serialization/resources/commons/types/ConversationExecutedActionPrecondition.js +17 -7
  738. package/serialization/resources/commons/types/ConversationInformation.d.ts +13 -0
  739. package/serialization/resources/commons/types/ConversationInformation.js +44 -0
  740. package/serialization/resources/commons/types/ConversationMessageBase.js +17 -7
  741. package/serialization/resources/commons/types/ConversationMessageResponse.js +17 -7
  742. package/serialization/resources/commons/types/ConversationPrecondition.js +17 -7
  743. package/serialization/resources/commons/types/ConversationResponse.js +17 -7
  744. package/serialization/resources/commons/types/ConversationSummary.js +17 -7
  745. package/serialization/resources/commons/types/DocumentInformation.d.ts +15 -0
  746. package/serialization/resources/commons/types/DocumentInformation.js +46 -0
  747. package/serialization/resources/commons/types/EntityId.js +17 -7
  748. package/serialization/resources/commons/types/EntityIdBase.js +17 -7
  749. package/serialization/resources/commons/types/EntityIdFilter.js +17 -7
  750. package/serialization/resources/commons/types/EntityIdWithoutAgent.js +17 -7
  751. package/serialization/resources/commons/types/EntityType.d.ts +1 -1
  752. package/serialization/resources/commons/types/EntityType.js +19 -7
  753. package/serialization/resources/commons/types/ErrorMessage.js +17 -7
  754. package/serialization/resources/commons/types/EventTriggerBase.js +17 -7
  755. package/serialization/resources/commons/types/EventTriggerResponse.js +17 -7
  756. package/serialization/resources/commons/types/EventTriggerType.d.ts +1 -1
  757. package/serialization/resources/commons/types/EventTriggerType.js +18 -8
  758. package/serialization/resources/commons/types/Feedback.js +17 -7
  759. package/serialization/resources/commons/types/FeedbackBase.js +17 -7
  760. package/serialization/resources/commons/types/FeedbackType.js +17 -7
  761. package/serialization/resources/commons/types/InboxItem.d.ts +26 -0
  762. package/serialization/resources/commons/types/InboxItem.js +55 -0
  763. package/serialization/resources/commons/types/InboxItemBase.d.ts +17 -0
  764. package/serialization/resources/commons/types/InboxItemBase.js +48 -0
  765. package/serialization/resources/commons/types/InboxItemDuplicateDocuments.d.ts +17 -0
  766. package/serialization/resources/commons/types/InboxItemDuplicateDocuments.js +50 -0
  767. package/serialization/resources/commons/types/InboxItemDuplicateKnowledgeBase.d.ts +17 -0
  768. package/serialization/resources/commons/types/InboxItemDuplicateKnowledgeBase.js +50 -0
  769. package/serialization/resources/commons/types/InboxItemFix.d.ts +22 -0
  770. package/serialization/resources/commons/types/InboxItemFix.js +53 -0
  771. package/serialization/resources/commons/types/InboxItemFixAddDocument.d.ts +14 -0
  772. package/serialization/resources/commons/types/InboxItemFixAddDocument.js +47 -0
  773. package/serialization/resources/commons/types/InboxItemFixBase.d.ts +13 -0
  774. package/serialization/resources/commons/types/InboxItemFixBase.js +44 -0
  775. package/serialization/resources/commons/types/InboxItemFixDeactivateDocument.d.ts +14 -0
  776. package/serialization/resources/commons/types/InboxItemFixDeactivateDocument.js +47 -0
  777. package/serialization/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.d.ts +14 -0
  778. package/serialization/resources/commons/types/InboxItemFixDeactivateKnowledgeBase.js +47 -0
  779. package/serialization/resources/commons/types/InboxItemKnowledgeBaseAlert.d.ts +16 -0
  780. package/serialization/resources/commons/types/InboxItemKnowledgeBaseAlert.js +49 -0
  781. package/serialization/resources/commons/types/InboxItemMissingKnowledge.d.ts +16 -0
  782. package/serialization/resources/commons/types/InboxItemMissingKnowledge.js +49 -0
  783. package/serialization/resources/commons/types/InboxItemStatus.d.ts +10 -0
  784. package/serialization/resources/commons/types/InboxItemStatus.js +41 -0
  785. package/serialization/resources/commons/types/InboxItemType.d.ts +10 -0
  786. package/serialization/resources/commons/types/InboxItemType.js +46 -0
  787. package/serialization/resources/commons/types/KnowledgeBaseInformation.d.ts +13 -0
  788. package/serialization/resources/commons/types/KnowledgeBaseInformation.js +44 -0
  789. package/serialization/resources/commons/types/MetadataPrecondition.js +17 -7
  790. package/serialization/resources/commons/types/Page.d.ts +15 -0
  791. package/serialization/resources/commons/types/Page.js +46 -0
  792. package/serialization/resources/commons/types/Precondition.js +17 -7
  793. package/serialization/resources/commons/types/PreconditionBase.js +17 -7
  794. package/serialization/resources/commons/types/PreconditionGroup.js +17 -7
  795. package/serialization/resources/commons/types/PreconditionGroupOperator.js +17 -7
  796. package/serialization/resources/commons/types/PreconditionOperator.js +17 -7
  797. package/serialization/resources/commons/types/ResponseConfig.js +17 -7
  798. package/serialization/resources/commons/types/ResponseConfigPrecondition.js +17 -7
  799. package/serialization/resources/commons/types/ResponseLength.js +17 -7
  800. package/serialization/resources/commons/types/Sentiment.js +17 -7
  801. package/serialization/resources/commons/types/Source.js +17 -7
  802. package/serialization/resources/commons/types/TagsPrecondition.js +17 -7
  803. package/serialization/resources/commons/types/UserConversationMessageType.js +17 -7
  804. package/serialization/resources/commons/types/UserData.js +17 -7
  805. package/serialization/resources/commons/types/UserMessage.js +17 -7
  806. package/serialization/resources/commons/types/UserMessageAttachment.js +17 -7
  807. package/serialization/resources/commons/types/UserMessageBase.js +17 -7
  808. package/serialization/resources/commons/types/VisibilityType.js +17 -7
  809. package/serialization/resources/commons/types/index.d.ts +17 -0
  810. package/serialization/resources/commons/types/index.js +17 -0
  811. package/serialization/resources/conversation/client/addConversationMetadata.js +17 -7
  812. package/serialization/resources/conversation/client/appendNewMessages.js +17 -7
  813. package/serialization/resources/conversation/client/index.js +17 -7
  814. package/serialization/resources/conversation/types/AskRequest.js +17 -7
  815. package/serialization/resources/conversation/types/AskStreamActionEvent.js +17 -7
  816. package/serialization/resources/conversation/types/AskStreamChartEvent.js +17 -7
  817. package/serialization/resources/conversation/types/AskStreamEndEvent.js +17 -7
  818. package/serialization/resources/conversation/types/AskStreamMetadataEvent.js +17 -7
  819. package/serialization/resources/conversation/types/AskStreamStartEvent.js +17 -7
  820. package/serialization/resources/conversation/types/AskStreamTextEvent.js +17 -7
  821. package/serialization/resources/conversation/types/Attachment.js +17 -7
  822. package/serialization/resources/conversation/types/CategorizationResponse.js +17 -7
  823. package/serialization/resources/conversation/types/ConversationField.d.ts +1 -1
  824. package/serialization/resources/conversation/types/ConversationField.js +18 -7
  825. package/serialization/resources/conversation/types/ConversationFilter.d.ts +2 -0
  826. package/serialization/resources/conversation/types/ConversationFilter.js +19 -7
  827. package/serialization/resources/conversation/types/ConversationMessageRequest.js +17 -7
  828. package/serialization/resources/conversation/types/ConversationMetadata.d.ts +12 -0
  829. package/serialization/resources/conversation/types/ConversationMetadata.js +43 -0
  830. package/serialization/resources/conversation/types/ConversationRequest.js +17 -7
  831. package/serialization/resources/conversation/types/FeedbackField.js +17 -7
  832. package/serialization/resources/conversation/types/FeedbackFilter.js +17 -7
  833. package/serialization/resources/conversation/types/FeedbackRequest.js +17 -7
  834. package/serialization/resources/conversation/types/GenerateMavenSuggestionsRequest.js +17 -7
  835. package/serialization/resources/conversation/types/NumericConversationField.d.ts +1 -1
  836. package/serialization/resources/conversation/types/NumericConversationField.js +18 -7
  837. package/serialization/resources/conversation/types/Quality.js +17 -7
  838. package/serialization/resources/conversation/types/QualityReason.js +17 -7
  839. package/serialization/resources/conversation/types/ResolutionStatus.d.ts +10 -0
  840. package/serialization/resources/conversation/types/ResolutionStatus.js +41 -0
  841. package/serialization/resources/conversation/types/StreamResponse.js +17 -7
  842. package/serialization/resources/conversation/types/SubmitActionFormRequest.js +17 -7
  843. package/serialization/resources/conversation/types/UpdateMetadataRequest.d.ts +13 -0
  844. package/serialization/resources/conversation/types/UpdateMetadataRequest.js +44 -0
  845. package/serialization/resources/conversation/types/index.d.ts +3 -0
  846. package/serialization/resources/conversation/types/index.js +3 -0
  847. package/serialization/resources/inbox/index.d.ts +1 -0
  848. package/serialization/resources/inbox/index.js +17 -0
  849. package/serialization/resources/inbox/types/AddDocumentFixRequest.d.ts +14 -0
  850. package/serialization/resources/inbox/types/AddDocumentFixRequest.js +45 -0
  851. package/serialization/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +14 -0
  852. package/serialization/resources/inbox/types/ApplyInboxItemFixRequest.js +45 -0
  853. package/serialization/resources/inbox/types/BaseInboxSearchRequest.d.ts +13 -0
  854. package/serialization/resources/inbox/types/BaseInboxSearchRequest.js +44 -0
  855. package/serialization/resources/inbox/types/InboxSearchRequest.d.ts +18 -0
  856. package/serialization/resources/inbox/types/InboxSearchRequest.js +51 -0
  857. package/serialization/resources/inbox/types/InboxSearchResponse.d.ts +14 -0
  858. package/serialization/resources/inbox/types/InboxSearchResponse.js +47 -0
  859. package/serialization/resources/inbox/types/index.d.ts +5 -0
  860. package/serialization/resources/inbox/types/index.js +21 -0
  861. package/serialization/resources/index.d.ts +2 -0
  862. package/serialization/resources/index.js +20 -8
  863. package/serialization/resources/knowledge/types/BaseKnowledgeDocument.js +17 -7
  864. package/serialization/resources/knowledge/types/KnowledgeBaseProperties.js +17 -7
  865. package/serialization/resources/knowledge/types/KnowledgeBaseRequest.js +17 -7
  866. package/serialization/resources/knowledge/types/KnowledgeBaseResponse.js +17 -7
  867. package/serialization/resources/knowledge/types/KnowledgeBaseType.js +17 -7
  868. package/serialization/resources/knowledge/types/KnowledgeBaseVersion.js +17 -7
  869. package/serialization/resources/knowledge/types/KnowledgeBaseVersionType.js +17 -7
  870. package/serialization/resources/knowledge/types/KnowledgeDocumentContentType.js +17 -7
  871. package/serialization/resources/knowledge/types/KnowledgeDocumentRequest.js +17 -7
  872. package/serialization/resources/knowledge/types/KnowledgeDocumentResponse.js +17 -7
  873. package/serialization/resources/translations/types/TranslationRequest.js +17 -7
  874. package/serialization/resources/translations/types/TranslationResponse.js +17 -7
  875. package/serialization/resources/triggers/types/EventTriggerRequest.js +17 -7
  876. package/version.d.ts +1 -1
  877. package/version.js +1 -1
  878. /package/api/resources/analytics/types/{BarChartRequest.js → ConversationBarChartRequest.js} +0 -0
  879. /package/api/resources/analytics/types/{DateHistogramRequest.js → ConversationDateHistogramRequest.js} +0 -0
  880. /package/api/resources/analytics/types/{PieChartRequest.js → ConversationPieChartRequest.js} +0 -0
  881. /package/{dist/api/resources/analytics/types/BarChartRequest.js → api/resources/commons/types/ConversationInformation.js} +0 -0
  882. /package/{dist/api/resources/analytics/types/DateHistogramRequest.js → api/resources/commons/types/DocumentInformation.js} +0 -0
  883. /package/{dist/api/resources/analytics/types/PieChartRequest.js → api/resources/commons/types/InboxItem.js} +0 -0
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.toJson = void 0;
4
+ exports.fromJson = fromJson;
5
+ /**
6
+ * Serialize a value to JSON
7
+ * @param value A JavaScript value, usually an object or array, to be converted.
8
+ * @param replacer A function that transforms the results.
9
+ * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.
10
+ * @returns JSON string
11
+ */
12
+ const toJson = (value, replacer, space) => {
13
+ return JSON.stringify(value, replacer, space);
14
+ };
15
+ exports.toJson = toJson;
16
+ /**
17
+ * Parse JSON string to object, array, or other type
18
+ * @param text A valid JSON string.
19
+ * @param reviver A function that transforms the results. This function is called for each member of the object. If a member contains nested objects, the nested objects are transformed before the parent object is.
20
+ * @returns Parsed object, array, or other type
21
+ */
22
+ function fromJson(text, reviver) {
23
+ return JSON.parse(text, reviver);
24
+ }
@@ -3,7 +3,7 @@
3
3
  */
4
4
  export declare const RUNTIME: Runtime;
5
5
  export interface Runtime {
6
- type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd";
6
+ type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd" | "edge-runtime";
7
7
  version?: string;
8
8
  parsedVersion?: number;
9
9
  }
@@ -1,80 +1,85 @@
1
1
  "use strict";
2
- var _a, _b, _c, _d, _e;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  exports.RUNTIME = void 0;
5
- /**
6
- * A constant that indicates whether the environment the code is running is a Web Browser.
7
- */
8
- const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined";
9
- /**
10
- * A constant that indicates whether the environment the code is running is a Web Worker.
11
- */
12
- const isWebWorker = typeof self === "object" &&
13
- // @ts-ignore
14
- typeof (self === null || self === void 0 ? void 0 : self.importScripts) === "function" &&
15
- (((_a = self.constructor) === null || _a === void 0 ? void 0 : _a.name) === "DedicatedWorkerGlobalScope" ||
16
- ((_b = self.constructor) === null || _b === void 0 ? void 0 : _b.name) === "ServiceWorkerGlobalScope" ||
17
- ((_c = self.constructor) === null || _c === void 0 ? void 0 : _c.name) === "SharedWorkerGlobalScope");
18
- /**
19
- * A constant that indicates whether the environment the code is running is Deno.
20
- */
21
- const isDeno = typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined";
22
- /**
23
- * A constant that indicates whether the environment the code is running is Bun.sh.
24
- */
25
- const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined";
26
- /**
27
- * A constant that indicates whether the environment the code is running is Node.JS.
28
- */
29
- const isNode = typeof process !== "undefined" &&
30
- Boolean(process.version) &&
31
- Boolean((_d = process.versions) === null || _d === void 0 ? void 0 : _d.node) &&
32
- // Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions
33
- !isDeno &&
34
- !isBun;
35
- /**
36
- * A constant that indicates whether the environment the code is running is in React-Native.
37
- * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js
38
- */
39
- const isReactNative = typeof navigator !== "undefined" && (navigator === null || navigator === void 0 ? void 0 : navigator.product) === "ReactNative";
40
- /**
41
- * A constant that indicates whether the environment the code is running is Cloudflare.
42
- * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent
43
- */
44
- const isCloudflare = typeof globalThis !== "undefined" && ((_e = globalThis === null || globalThis === void 0 ? void 0 : globalThis.navigator) === null || _e === void 0 ? void 0 : _e.userAgent) === "Cloudflare-Workers";
45
4
  /**
46
5
  * A constant that indicates which environment and version the SDK is running in.
47
6
  */
48
7
  exports.RUNTIME = evaluateRuntime();
49
8
  function evaluateRuntime() {
9
+ var _a, _b, _c, _d, _e;
10
+ /**
11
+ * A constant that indicates whether the environment the code is running is a Web Browser.
12
+ */
13
+ const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined";
50
14
  if (isBrowser) {
51
15
  return {
52
16
  type: "browser",
53
17
  version: window.navigator.userAgent,
54
18
  };
55
19
  }
20
+ /**
21
+ * A constant that indicates whether the environment the code is running is Cloudflare.
22
+ * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent
23
+ */
24
+ const isCloudflare = typeof globalThis !== "undefined" && ((_a = globalThis === null || globalThis === void 0 ? void 0 : globalThis.navigator) === null || _a === void 0 ? void 0 : _a.userAgent) === "Cloudflare-Workers";
56
25
  if (isCloudflare) {
57
26
  return {
58
27
  type: "workerd",
59
28
  };
60
29
  }
30
+ /**
31
+ * A constant that indicates whether the environment the code is running is Edge Runtime.
32
+ * https://vercel.com/docs/functions/runtimes/edge-runtime#check-if-you're-running-on-the-edge-runtime
33
+ */
34
+ const isEdgeRuntime = typeof EdgeRuntime === "string";
35
+ if (isEdgeRuntime) {
36
+ return {
37
+ type: "edge-runtime",
38
+ };
39
+ }
40
+ /**
41
+ * A constant that indicates whether the environment the code is running is a Web Worker.
42
+ */
43
+ const isWebWorker = typeof self === "object" &&
44
+ // @ts-ignore
45
+ typeof (self === null || self === void 0 ? void 0 : self.importScripts) === "function" &&
46
+ (((_b = self.constructor) === null || _b === void 0 ? void 0 : _b.name) === "DedicatedWorkerGlobalScope" ||
47
+ ((_c = self.constructor) === null || _c === void 0 ? void 0 : _c.name) === "ServiceWorkerGlobalScope" ||
48
+ ((_d = self.constructor) === null || _d === void 0 ? void 0 : _d.name) === "SharedWorkerGlobalScope");
61
49
  if (isWebWorker) {
62
50
  return {
63
51
  type: "web-worker",
64
52
  };
65
53
  }
54
+ /**
55
+ * A constant that indicates whether the environment the code is running is Deno.
56
+ * FYI Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions
57
+ */
58
+ const isDeno = typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined";
66
59
  if (isDeno) {
67
60
  return {
68
61
  type: "deno",
69
62
  version: Deno.version.deno,
70
63
  };
71
64
  }
65
+ /**
66
+ * A constant that indicates whether the environment the code is running is Bun.sh.
67
+ */
68
+ const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined";
72
69
  if (isBun) {
73
70
  return {
74
71
  type: "bun",
75
72
  version: Bun.version,
76
73
  };
77
74
  }
75
+ /**
76
+ * A constant that indicates whether the environment the code is running is Node.JS.
77
+ */
78
+ const isNode = typeof process !== "undefined" &&
79
+ "version" in process &&
80
+ !!process.version &&
81
+ "versions" in process &&
82
+ !!((_e = process.versions) === null || _e === void 0 ? void 0 : _e.node);
78
83
  if (isNode) {
79
84
  return {
80
85
  type: "node",
@@ -82,6 +87,11 @@ function evaluateRuntime() {
82
87
  parsedVersion: Number(process.versions.node.split(".")[0]),
83
88
  };
84
89
  }
90
+ /**
91
+ * A constant that indicates whether the environment the code is running is in React-Native.
92
+ * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js
93
+ */
94
+ const isReactNative = typeof navigator !== "undefined" && (navigator === null || navigator === void 0 ? void 0 : navigator.product) === "ReactNative";
85
95
  if (isReactNative) {
86
96
  return {
87
97
  type: "react-native",
@@ -1,7 +1,7 @@
1
1
  import { SchemaUtils } from "./builders";
2
- export declare type Schema<Raw = unknown, Parsed = unknown> = BaseSchema<Raw, Parsed> & SchemaUtils<Raw, Parsed>;
3
- export declare type inferRaw<S extends Schema> = S extends Schema<infer Raw, any> ? Raw : never;
4
- export declare type inferParsed<S extends Schema> = S extends Schema<any, infer Parsed> ? Parsed : never;
2
+ export type Schema<Raw = unknown, Parsed = unknown> = BaseSchema<Raw, Parsed> & SchemaUtils<Raw, Parsed>;
3
+ export type inferRaw<S extends Schema> = S extends Schema<infer Raw, any> ? Raw : never;
4
+ export type inferParsed<S extends Schema> = S extends Schema<any, infer Parsed> ? Parsed : never;
5
5
  export interface BaseSchema<Raw, Parsed> {
6
6
  parse: (raw: unknown, opts?: SchemaOptions) => MaybeValid<Parsed>;
7
7
  json: (parsed: unknown, opts?: SchemaOptions) => MaybeValid<Raw>;
@@ -24,10 +24,12 @@ export declare const SchemaType: {
24
24
  readonly SET: "set";
25
25
  readonly UNION: "union";
26
26
  readonly UNDISCRIMINATED_UNION: "undiscriminatedUnion";
27
+ readonly NULLABLE: "nullable";
27
28
  readonly OPTIONAL: "optional";
29
+ readonly OPTIONAL_NULLABLE: "optionalNullable";
28
30
  };
29
- export declare type SchemaType = typeof SchemaType[keyof typeof SchemaType];
30
- export declare type MaybeValid<T> = Valid<T> | Invalid;
31
+ export type SchemaType = (typeof SchemaType)[keyof typeof SchemaType];
32
+ export type MaybeValid<T> = Valid<T> | Invalid;
31
33
  export interface Valid<T> {
32
34
  ok: true;
33
35
  value: T;
@@ -18,5 +18,7 @@ exports.SchemaType = {
18
18
  SET: "set",
19
19
  UNION: "union",
20
20
  UNDISCRIMINATED_UNION: "undiscriminatedUnion",
21
+ NULLABLE: "nullable",
21
22
  OPTIONAL: "optional",
23
+ OPTIONAL_NULLABLE: "optionalNullable",
22
24
  };
@@ -1,2 +1,2 @@
1
1
  import { Schema } from "../../Schema";
2
- export declare function bigint(): Schema<string, bigint>;
2
+ export declare function bigint(): Schema<bigint | number, bigint>;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.bigint = void 0;
3
+ exports.bigint = bigint;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
6
6
  const maybeSkipValidation_1 = require("../../utils/maybeSkipValidation");
@@ -8,30 +8,30 @@ const schema_utils_1 = require("../schema-utils");
8
8
  function bigint() {
9
9
  const baseSchema = {
10
10
  parse: (raw, { breadcrumbsPrefix = [] } = {}) => {
11
- if (typeof raw !== "string") {
11
+ if (typeof raw === "bigint") {
12
12
  return {
13
- ok: false,
14
- errors: [
15
- {
16
- path: breadcrumbsPrefix,
17
- message: (0, getErrorMessageForIncorrectType_1.getErrorMessageForIncorrectType)(raw, "string"),
18
- },
19
- ],
13
+ ok: true,
14
+ value: raw,
20
15
  };
21
16
  }
22
- return {
23
- ok: true,
24
- value: BigInt(raw),
25
- };
26
- },
27
- json: (bigint, { breadcrumbsPrefix = [] } = {}) => {
28
- if (typeof bigint === "bigint") {
17
+ if (typeof raw === "number") {
29
18
  return {
30
19
  ok: true,
31
- value: bigint.toString(),
20
+ value: BigInt(raw),
32
21
  };
33
22
  }
34
- else {
23
+ return {
24
+ ok: false,
25
+ errors: [
26
+ {
27
+ path: breadcrumbsPrefix,
28
+ message: (0, getErrorMessageForIncorrectType_1.getErrorMessageForIncorrectType)(raw, "bigint | number"),
29
+ },
30
+ ],
31
+ };
32
+ },
33
+ json: (bigint, { breadcrumbsPrefix = [] } = {}) => {
34
+ if (typeof bigint !== "bigint") {
35
35
  return {
36
36
  ok: false,
37
37
  errors: [
@@ -42,9 +42,12 @@ function bigint() {
42
42
  ],
43
43
  };
44
44
  }
45
+ return {
46
+ ok: true,
47
+ value: bigint,
48
+ };
45
49
  },
46
50
  getType: () => Schema_1.SchemaType.BIGINT,
47
51
  };
48
52
  return Object.assign(Object.assign({}, (0, maybeSkipValidation_1.maybeSkipValidation)(baseSchema)), (0, schema_utils_1.getSchemaUtils)(baseSchema));
49
53
  }
50
- exports.bigint = bigint;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.date = void 0;
3
+ exports.date = date;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
6
6
  const maybeSkipValidation_1 = require("../../utils/maybeSkipValidation");
@@ -60,4 +60,3 @@ function date() {
60
60
  };
61
61
  return Object.assign(Object.assign({}, (0, maybeSkipValidation_1.maybeSkipValidation)(baseSchema)), (0, schema_utils_1.getSchemaUtils)(baseSchema));
62
62
  }
63
- exports.date = date;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.enum_ = void 0;
3
+ exports.enum_ = enum_;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const createIdentitySchemaCreator_1 = require("../../utils/createIdentitySchemaCreator");
6
6
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
@@ -36,4 +36,3 @@ function enum_(values) {
36
36
  });
37
37
  return schemaCreator();
38
38
  }
39
- exports.enum_ = enum_;
@@ -1,5 +1,5 @@
1
1
  import { BaseSchema, Schema } from "../../Schema";
2
- export declare type SchemaGetter<SchemaType extends Schema<any, any>> = () => SchemaType;
2
+ export type SchemaGetter<SchemaType extends Schema<any, any>> = () => SchemaType;
3
3
  export declare function lazy<Raw, Parsed>(getter: SchemaGetter<Schema<Raw, Parsed>>): Schema<Raw, Parsed>;
4
4
  export declare function constructLazyBaseSchema<Raw, Parsed>(getter: SchemaGetter<Schema<Raw, Parsed>>): BaseSchema<Raw, Parsed>;
5
5
  export declare function getMemoizedSchema<SchemaType extends Schema<any, any>>(getter: SchemaGetter<SchemaType>): SchemaType;
@@ -1,12 +1,13 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getMemoizedSchema = exports.constructLazyBaseSchema = exports.lazy = void 0;
3
+ exports.lazy = lazy;
4
+ exports.constructLazyBaseSchema = constructLazyBaseSchema;
5
+ exports.getMemoizedSchema = getMemoizedSchema;
4
6
  const schema_utils_1 = require("../schema-utils");
5
7
  function lazy(getter) {
6
8
  const baseSchema = constructLazyBaseSchema(getter);
7
9
  return Object.assign(Object.assign({}, baseSchema), (0, schema_utils_1.getSchemaUtils)(baseSchema));
8
10
  }
9
- exports.lazy = lazy;
10
11
  function constructLazyBaseSchema(getter) {
11
12
  return {
12
13
  parse: (raw, opts) => getMemoizedSchema(getter).parse(raw, opts),
@@ -14,7 +15,6 @@ function constructLazyBaseSchema(getter) {
14
15
  getType: () => getMemoizedSchema(getter).getType(),
15
16
  };
16
17
  }
17
- exports.constructLazyBaseSchema = constructLazyBaseSchema;
18
18
  function getMemoizedSchema(getter) {
19
19
  const castedGetter = getter;
20
20
  if (castedGetter.__zurg_memoized == null) {
@@ -22,4 +22,3 @@ function getMemoizedSchema(getter) {
22
22
  }
23
23
  return castedGetter.__zurg_memoized;
24
24
  }
25
- exports.getMemoizedSchema = getMemoizedSchema;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.lazyObject = void 0;
3
+ exports.lazyObject = lazyObject;
4
4
  const object_1 = require("../object");
5
5
  const object_like_1 = require("../object-like");
6
6
  const schema_utils_1 = require("../schema-utils");
@@ -9,4 +9,3 @@ function lazyObject(getter) {
9
9
  const baseSchema = Object.assign(Object.assign({}, (0, lazy_1.constructLazyBaseSchema)(getter)), { _getRawProperties: () => (0, lazy_1.getMemoizedSchema)(getter)._getRawProperties(), _getParsedProperties: () => (0, lazy_1.getMemoizedSchema)(getter)._getParsedProperties() });
10
10
  return Object.assign(Object.assign(Object.assign(Object.assign({}, baseSchema), (0, schema_utils_1.getSchemaUtils)(baseSchema)), (0, object_like_1.getObjectLikeUtils)(baseSchema)), (0, object_1.getObjectUtils)(baseSchema));
11
11
  }
12
- exports.lazyObject = lazyObject;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.list = void 0;
3
+ exports.list = list;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
6
6
  const maybeSkipValidation_1 = require("../../utils/maybeSkipValidation");
@@ -19,7 +19,6 @@ function list(schema) {
19
19
  };
20
20
  return Object.assign(Object.assign({}, (0, maybeSkipValidation_1.maybeSkipValidation)(baseSchema)), (0, schema_utils_1.getSchemaUtils)(baseSchema));
21
21
  }
22
- exports.list = list;
23
22
  function validateAndTransformArray(value, transformItem) {
24
23
  if (!Array.isArray(value)) {
25
24
  return {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.booleanLiteral = void 0;
3
+ exports.booleanLiteral = booleanLiteral;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const createIdentitySchemaCreator_1 = require("../../utils/createIdentitySchemaCreator");
6
6
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
@@ -26,4 +26,3 @@ function booleanLiteral(literal) {
26
26
  });
27
27
  return schemaCreator();
28
28
  }
29
- exports.booleanLiteral = booleanLiteral;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.stringLiteral = void 0;
3
+ exports.stringLiteral = stringLiteral;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const createIdentitySchemaCreator_1 = require("../../utils/createIdentitySchemaCreator");
6
6
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
@@ -26,4 +26,3 @@ function stringLiteral(literal) {
26
26
  });
27
27
  return schemaCreator();
28
28
  }
29
- exports.stringLiteral = stringLiteral;
@@ -1,3 +1,3 @@
1
- import { BaseObjectSchema, inferObjectSchemaFromPropertySchemas, ObjectUtils, PropertySchemas } from "./types";
1
+ import { BaseObjectSchema, ObjectUtils, PropertySchemas, inferObjectSchemaFromPropertySchemas } from "./types";
2
2
  export declare function object<ParsedKeys extends string, T extends PropertySchemas<ParsedKeys>>(schemas: T): inferObjectSchemaFromPropertySchemas<T>;
3
3
  export declare function getObjectUtils<Raw, Parsed>(schema: BaseObjectSchema<Raw, Parsed>): ObjectUtils<Raw, Parsed>;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getObjectUtils = exports.object = void 0;
3
+ exports.object = object;
4
+ exports.getObjectUtils = getObjectUtils;
4
5
  const Schema_1 = require("../../Schema");
5
6
  const entries_1 = require("../../utils/entries");
6
7
  const filterObject_1 = require("../../utils/filterObject");
@@ -104,7 +105,6 @@ function object(schemas) {
104
105
  };
105
106
  return Object.assign(Object.assign(Object.assign(Object.assign({}, (0, maybeSkipValidation_1.maybeSkipValidation)(baseSchema)), (0, schema_utils_1.getSchemaUtils)(baseSchema)), (0, object_like_1.getObjectLikeUtils)(baseSchema)), getObjectUtils(baseSchema));
106
107
  }
107
- exports.object = object;
108
108
  function validateAndTransformObject({ value, requiredKeys, getProperty, unrecognizedObjectKeys = "fail", skipValidation = false, breadcrumbsPrefix = [], }) {
109
109
  if (!(0, isPlainObject_1.isPlainObject)(value)) {
110
110
  return {
@@ -224,7 +224,6 @@ function getObjectUtils(schema) {
224
224
  },
225
225
  };
226
226
  }
227
- exports.getObjectUtils = getObjectUtils;
228
227
  function validateAndTransformExtendedObject({ extensionKeys, value, transformBase, transformExtension, }) {
229
228
  const extensionPropertiesSet = new Set(extensionKeys);
230
229
  const [extensionProperties, baseProperties] = (0, partition_1.partition)((0, keys_1.keys)(value), (key) => extensionPropertiesSet.has(key));
@@ -254,6 +253,7 @@ function isSchemaOptional(schema) {
254
253
  case Schema_1.SchemaType.ANY:
255
254
  case Schema_1.SchemaType.UNKNOWN:
256
255
  case Schema_1.SchemaType.OPTIONAL:
256
+ case Schema_1.SchemaType.OPTIONAL_NULLABLE:
257
257
  return true;
258
258
  default:
259
259
  return false;
@@ -1,6 +1,6 @@
1
- import { inferParsedPropertySchema, inferRawObjectFromPropertySchemas, ObjectSchema, PropertySchemas } from "./types";
1
+ import { ObjectSchema, PropertySchemas, inferParsedPropertySchema, inferRawObjectFromPropertySchemas } from "./types";
2
2
  export declare function objectWithoutOptionalProperties<ParsedKeys extends string, T extends PropertySchemas<ParsedKeys>>(schemas: T): inferObjectWithoutOptionalPropertiesSchemaFromPropertySchemas<T>;
3
- export declare type inferObjectWithoutOptionalPropertiesSchemaFromPropertySchemas<T extends PropertySchemas<keyof T>> = ObjectSchema<inferRawObjectFromPropertySchemas<T>, inferParsedObjectWithoutOptionalPropertiesFromPropertySchemas<T>>;
4
- export declare type inferParsedObjectWithoutOptionalPropertiesFromPropertySchemas<T extends PropertySchemas<keyof T>> = {
3
+ export type inferObjectWithoutOptionalPropertiesSchemaFromPropertySchemas<T extends PropertySchemas<keyof T>> = ObjectSchema<inferRawObjectFromPropertySchemas<T>, inferParsedObjectWithoutOptionalPropertiesFromPropertySchemas<T>>;
4
+ export type inferParsedObjectWithoutOptionalPropertiesFromPropertySchemas<T extends PropertySchemas<keyof T>> = {
5
5
  [K in keyof T]: inferParsedPropertySchema<T[K]>;
6
6
  };
@@ -1,8 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.objectWithoutOptionalProperties = void 0;
3
+ exports.objectWithoutOptionalProperties = objectWithoutOptionalProperties;
4
4
  const object_1 = require("./object");
5
5
  function objectWithoutOptionalProperties(schemas) {
6
6
  return (0, object_1.object)(schemas);
7
7
  }
8
- exports.objectWithoutOptionalProperties = objectWithoutOptionalProperties;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isProperty = exports.property = void 0;
3
+ exports.property = property;
4
+ exports.isProperty = isProperty;
4
5
  function property(rawKey, valueSchema) {
5
6
  return {
6
7
  rawKey,
@@ -8,9 +9,7 @@ function property(rawKey, valueSchema) {
8
9
  isProperty: true,
9
10
  };
10
11
  }
11
- exports.property = property;
12
12
  function isProperty(maybeProperty) {
13
13
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
14
14
  return maybeProperty.isProperty;
15
15
  }
16
- exports.isProperty = isProperty;
@@ -1,9 +1,9 @@
1
- import { BaseSchema, inferParsed, inferRaw, Schema } from "../../Schema";
1
+ import { BaseSchema, Schema, inferParsed, inferRaw } from "../../Schema";
2
2
  import { addQuestionMarksToNullableProperties } from "../../utils/addQuestionMarksToNullableProperties";
3
3
  import { ObjectLikeUtils } from "../object-like";
4
4
  import { SchemaUtils } from "../schema-utils";
5
5
  import { Property } from "./property";
6
- export declare type ObjectSchema<Raw, Parsed> = BaseObjectSchema<Raw, Parsed> & ObjectLikeUtils<Raw, Parsed> & ObjectUtils<Raw, Parsed> & SchemaUtils<Raw, Parsed>;
6
+ export type ObjectSchema<Raw, Parsed> = BaseObjectSchema<Raw, Parsed> & ObjectLikeUtils<Raw, Parsed> & ObjectUtils<Raw, Parsed> & SchemaUtils<Raw, Parsed>;
7
7
  export interface BaseObjectSchema<Raw, Parsed> extends BaseSchema<Raw, Parsed> {
8
8
  _getRawProperties: () => (keyof Raw)[];
9
9
  _getParsedProperties: () => (keyof Parsed)[];
@@ -16,16 +16,16 @@ export interface ObjectUtils<Raw, Parsed> {
16
16
  [key: string]: unknown;
17
17
  }>;
18
18
  }
19
- export declare type inferRawObject<O extends ObjectSchema<any, any>> = O extends ObjectSchema<infer Raw, any> ? Raw : never;
20
- export declare type inferParsedObject<O extends ObjectSchema<any, any>> = O extends ObjectSchema<any, infer Parsed> ? Parsed : never;
21
- export declare type inferObjectSchemaFromPropertySchemas<T extends PropertySchemas<keyof T>> = ObjectSchema<inferRawObjectFromPropertySchemas<T>, inferParsedObjectFromPropertySchemas<T>>;
22
- export declare type inferRawObjectFromPropertySchemas<T extends PropertySchemas<keyof T>> = addQuestionMarksToNullableProperties<{
19
+ export type inferRawObject<O extends ObjectSchema<any, any>> = O extends ObjectSchema<infer Raw, any> ? Raw : never;
20
+ export type inferParsedObject<O extends ObjectSchema<any, any>> = O extends ObjectSchema<any, infer Parsed> ? Parsed : never;
21
+ export type inferObjectSchemaFromPropertySchemas<T extends PropertySchemas<keyof T>> = ObjectSchema<inferRawObjectFromPropertySchemas<T>, inferParsedObjectFromPropertySchemas<T>>;
22
+ export type inferRawObjectFromPropertySchemas<T extends PropertySchemas<keyof T>> = addQuestionMarksToNullableProperties<{
23
23
  [ParsedKey in keyof T as inferRawKey<ParsedKey, T[ParsedKey]>]: inferRawPropertySchema<T[ParsedKey]>;
24
24
  }>;
25
- export declare type inferParsedObjectFromPropertySchemas<T extends PropertySchemas<keyof T>> = addQuestionMarksToNullableProperties<{
25
+ export type inferParsedObjectFromPropertySchemas<T extends PropertySchemas<keyof T>> = addQuestionMarksToNullableProperties<{
26
26
  [K in keyof T]: inferParsedPropertySchema<T[K]>;
27
27
  }>;
28
- export declare type PropertySchemas<ParsedKeys extends string | number | symbol> = Record<ParsedKeys, Property<any, any, any> | Schema<any, any>>;
29
- export declare type inferRawPropertySchema<P extends Property<any, any, any> | Schema<any, any>> = P extends Property<any, infer Raw, any> ? Raw : P extends Schema<any, any> ? inferRaw<P> : never;
30
- export declare type inferParsedPropertySchema<P extends Property<any, any, any> | Schema<any, any>> = P extends Property<any, any, infer Parsed> ? Parsed : P extends Schema<any, any> ? inferParsed<P> : never;
31
- export declare type inferRawKey<ParsedKey extends string | number | symbol, P extends Property<any, any, any> | Schema<any, any>> = P extends Property<infer Raw, any, any> ? Raw : ParsedKey;
28
+ export type PropertySchemas<ParsedKeys extends string | number | symbol> = Record<ParsedKeys, Property<any, any, any> | Schema<any, any>>;
29
+ export type inferRawPropertySchema<P extends Property<any, any, any> | Schema<any, any>> = P extends Property<any, infer Raw, any> ? Raw : P extends Schema<any, any> ? inferRaw<P> : never;
30
+ export type inferParsedPropertySchema<P extends Property<any, any, any> | Schema<any, any>> = P extends Property<any, any, infer Parsed> ? Parsed : P extends Schema<any, any> ? inferParsed<P> : never;
31
+ export type inferRawKey<ParsedKey extends string | number | symbol, P extends Property<any, any, any> | Schema<any, any>> = P extends Property<infer Raw, any, any> ? Raw : ParsedKey;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.withParsedProperties = exports.getObjectLikeUtils = void 0;
3
+ exports.getObjectLikeUtils = getObjectLikeUtils;
4
+ exports.withParsedProperties = withParsedProperties;
4
5
  const filterObject_1 = require("../../utils/filterObject");
5
6
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
6
7
  const isPlainObject_1 = require("../../utils/isPlainObject");
@@ -10,7 +11,6 @@ function getObjectLikeUtils(schema) {
10
11
  withParsedProperties: (properties) => withParsedProperties(schema, properties),
11
12
  };
12
13
  }
13
- exports.getObjectLikeUtils = getObjectLikeUtils;
14
14
  /**
15
15
  * object-like utils are defined in one file to resolve issues with circular imports
16
16
  */
@@ -51,4 +51,3 @@ function withParsedProperties(objectLike, properties) {
51
51
  };
52
52
  return Object.assign(Object.assign(Object.assign({}, objectSchema), (0, schema_utils_1.getSchemaUtils)(objectSchema)), getObjectLikeUtils(objectSchema));
53
53
  }
54
- exports.withParsedProperties = withParsedProperties;
@@ -1,5 +1,5 @@
1
1
  import { BaseSchema, Schema } from "../../Schema";
2
- export declare type ObjectLikeSchema<Raw, Parsed> = Schema<Raw, Parsed> & BaseSchema<Raw, Parsed> & ObjectLikeUtils<Raw, Parsed>;
2
+ export type ObjectLikeSchema<Raw, Parsed> = Schema<Raw, Parsed> & BaseSchema<Raw, Parsed> & ObjectLikeUtils<Raw, Parsed>;
3
3
  export interface ObjectLikeUtils<Raw, Parsed> {
4
4
  withParsedProperties: <T extends Record<string, any>>(properties: {
5
5
  [K in keyof T]: T[K] | ((parsed: Parsed) => T[K]);
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.record = void 0;
3
+ exports.record = record;
4
4
  const Schema_1 = require("../../Schema");
5
5
  const entries_1 = require("../../utils/entries");
6
6
  const getErrorMessageForIncorrectType_1 = require("../../utils/getErrorMessageForIncorrectType");
@@ -43,7 +43,6 @@ function record(keySchema, valueSchema) {
43
43
  };
44
44
  return Object.assign(Object.assign({}, (0, maybeSkipValidation_1.maybeSkipValidation)(baseSchema)), (0, schema_utils_1.getSchemaUtils)(baseSchema));
45
45
  }
46
- exports.record = record;
47
46
  function validateAndTransformRecord({ value, isKeyNumeric, transformKey, transformValue, breadcrumbsPrefix = [], }) {
48
47
  if (!(0, isPlainObject_1.isPlainObject)(value)) {
49
48
  return {
@@ -57,8 +56,7 @@ function validateAndTransformRecord({ value, isKeyNumeric, transformKey, transfo
57
56
  };
58
57
  }
59
58
  return (0, entries_1.entries)(value).reduce((accPromise, [stringKey, value]) => {
60
- // skip nullish keys
61
- if (value == null) {
59
+ if (value === undefined) {
62
60
  return accPromise;
63
61
  }
64
62
  const acc = accPromise;
@@ -1,4 +1,4 @@
1
1
  import { BaseSchema } from "../../Schema";
2
2
  import { SchemaUtils } from "../schema-utils";
3
- export declare type RecordSchema<RawKey extends string | number, RawValue, ParsedKey extends string | number, ParsedValue> = BaseRecordSchema<RawKey, RawValue, ParsedKey, ParsedValue> & SchemaUtils<Record<RawKey, RawValue>, Record<ParsedKey, ParsedValue>>;
4
- export declare type BaseRecordSchema<RawKey extends string | number, RawValue, ParsedKey extends string | number, ParsedValue> = BaseSchema<Record<RawKey, RawValue>, Record<ParsedKey, ParsedValue>>;
3
+ export type RecordSchema<RawKey extends string | number, RawValue, ParsedKey extends string | number, ParsedValue> = BaseRecordSchema<RawKey, RawValue, ParsedKey, ParsedValue> & SchemaUtils<Record<RawKey, RawValue>, Record<ParsedKey, ParsedValue>>;
4
+ export type BaseRecordSchema<RawKey extends string | number, RawValue, ParsedKey extends string | number, ParsedValue> = BaseSchema<Record<RawKey, RawValue>, Record<ParsedKey, ParsedValue>>;
@@ -1,6 +1,8 @@
1
1
  import { BaseSchema, Schema, SchemaOptions } from "../../Schema";
2
2
  export interface SchemaUtils<Raw, Parsed> {
3
+ nullable: () => Schema<Raw | null, Parsed | null>;
3
4
  optional: () => Schema<Raw | null | undefined, Parsed | undefined>;
5
+ optionalNullable: () => Schema<Raw | null | undefined, Parsed | null | undefined>;
4
6
  transform: <Transformed>(transformer: SchemaTransformer<Parsed, Transformed>) => Schema<Raw, Transformed>;
5
7
  parseOrThrow: (raw: unknown, opts?: SchemaOptions) => Parsed;
6
8
  jsonOrThrow: (raw: unknown, opts?: SchemaOptions) => Raw;
@@ -13,5 +15,7 @@ export declare function getSchemaUtils<Raw, Parsed>(schema: BaseSchema<Raw, Pars
13
15
  /**
14
16
  * schema utils are defined in one file to resolve issues with circular imports
15
17
  */
18
+ export declare function nullable<Raw, Parsed>(schema: BaseSchema<Raw, Parsed>): Schema<Raw | null, Parsed | null>;
16
19
  export declare function optional<Raw, Parsed>(schema: BaseSchema<Raw, Parsed>): Schema<Raw | null | undefined, Parsed | undefined>;
20
+ export declare function optionalNullable<Raw, Parsed>(schema: BaseSchema<Raw, Parsed>): Schema<Raw | null | undefined, Parsed | null | undefined>;
17
21
  export declare function transform<Raw, Parsed, Transformed>(schema: BaseSchema<Raw, Parsed>, transformer: SchemaTransformer<Parsed, Transformed>): Schema<Raw, Transformed>;