@purpleschool/gptbot 0.9.96 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (344) hide show
  1. package/api/controllers/http/auth.ts +1 -0
  2. package/api/controllers/http/b2b.ts +1 -0
  3. package/api/controllers/http/index.ts +4 -0
  4. package/api/controllers/http/interior-design.ts +14 -0
  5. package/api/controllers/http/marketplace-card.ts +14 -0
  6. package/api/controllers/http/page.ts +2 -0
  7. package/api/controllers/http/payment.ts +1 -0
  8. package/api/controllers/http/product.ts +1 -0
  9. package/api/controllers/http/solving-edu-task.ts +14 -0
  10. package/api/controllers/http/subscription.ts +2 -1
  11. package/api/controllers/http/team-account.ts +21 -0
  12. package/api/routes.ts +125 -2
  13. package/build/api/controllers/http/auth.js +1 -0
  14. package/build/api/controllers/http/b2b.js +1 -0
  15. package/build/api/controllers/http/index.js +4 -0
  16. package/build/api/controllers/http/interior-design.js +16 -0
  17. package/build/api/controllers/http/marketplace-card.js +16 -0
  18. package/build/api/controllers/http/page.js +2 -0
  19. package/build/api/controllers/http/payment.js +1 -0
  20. package/build/api/controllers/http/product.js +1 -0
  21. package/build/api/controllers/http/solving-edu-task.js +16 -0
  22. package/build/api/controllers/http/subscription.js +2 -1
  23. package/build/api/controllers/http/team-account.js +23 -0
  24. package/build/api/routes.js +93 -2
  25. package/build/commands/b2b/get-b2b-documentation.command.js +99 -0
  26. package/build/commands/b2b/index.js +2 -0
  27. package/build/commands/b2b/send-text-request.command.js +2 -5
  28. package/build/commands/b2b/upload-b2b-file.command.js +12 -0
  29. package/build/commands/cabinet/get-user-statistics-by-month.command.js +4 -0
  30. package/build/commands/chat/archive-all.command.js +1 -4
  31. package/build/commands/chat/check-limit.command.js +7 -0
  32. package/build/commands/chat/create-chat.command.js +0 -1
  33. package/build/commands/chat/find-chats.command.js +1 -1
  34. package/build/commands/chat/get-last-active-chat-command.js +0 -1
  35. package/build/commands/index.js +3 -0
  36. package/build/commands/message/create-text-message.command.js +1 -0
  37. package/build/commands/page/find-pages-by-criteria.command.js +36 -0
  38. package/build/commands/page/index.js +1 -0
  39. package/build/commands/payment/find-payments-by-criteria.command.js +53 -0
  40. package/build/commands/payment/index.js +1 -0
  41. package/build/commands/product/buy-product.command.js +25 -1
  42. package/build/commands/product/index.js +1 -0
  43. package/build/commands/product/refund-product.command.js +15 -0
  44. package/build/commands/subscription/buy-subscription.command.js +24 -1
  45. package/build/commands/subscription/index.js +1 -1
  46. package/build/commands/subscription/refund-subscription.command.js +15 -0
  47. package/build/commands/subscription/upgrade-subscription.command.js +25 -1
  48. package/build/commands/team-account/accept-team-account-invite.command.js +14 -0
  49. package/build/commands/team-account/create-manual-team-product.command.js +15 -0
  50. package/build/commands/team-account/create-manual-team-subscription.command.js +16 -0
  51. package/build/commands/team-account/create-team-account.command.js +16 -0
  52. package/build/commands/team-account/find-current-team-account-products.command.js +11 -0
  53. package/build/commands/team-account/find-current-team-account-subscriptions.command.js +11 -0
  54. package/build/commands/team-account/find-team-account-members.command.js +11 -0
  55. package/build/commands/team-account/find-team-account-operations.command.js +15 -0
  56. package/build/commands/team-account/find-team-account-products.command.js +11 -0
  57. package/build/commands/team-account/find-team-account-subscriptions.command.js +11 -0
  58. package/build/commands/team-account/find-team-accounts-by-name.command.js +18 -0
  59. package/build/commands/team-account/get-my-team-account.command.js +11 -0
  60. package/build/commands/team-account/get-team-account-balance.command.js +15 -0
  61. package/build/commands/team-account/index.js +33 -0
  62. package/build/commands/team-account/invite-team-account-member.command.js +17 -0
  63. package/build/commands/team-account/refund-team-account-balance.command.js +14 -0
  64. package/build/commands/team-account/remove-team-account-member.command.js +15 -0
  65. package/build/commands/team-account/update-team-account-member.command.js +23 -0
  66. package/build/commands/team-account/update-team-account.command.js +18 -0
  67. package/build/commands/team-to-product/add-team-to-product.command.js +16 -0
  68. package/build/commands/team-to-product/get-team-to-product-by-uuid.command.js +14 -0
  69. package/build/commands/team-to-product/get-team-to-products.command.js +14 -0
  70. package/build/commands/team-to-product/index.js +20 -0
  71. package/build/commands/team-to-product/update-team-to-product.command.js +21 -0
  72. package/build/commands/team-to-subscription/add-team-to-subscription.command.js +20 -0
  73. package/build/commands/team-to-subscription/get-team-to-subscription-by-uuid.command.js +14 -0
  74. package/build/commands/team-to-subscription/get-team-to-subscriptions.command.js +14 -0
  75. package/build/commands/team-to-subscription/index.js +20 -0
  76. package/build/commands/team-to-subscription/update-team-to-subscription.command.js +31 -0
  77. package/build/commands/tools/image-editor/image-editor.command.js +1 -0
  78. package/build/commands/tools/image-editor/retry-image-editor-job.command.js +1 -0
  79. package/build/commands/tools/index.js +3 -0
  80. package/build/commands/tools/interior-design/delete-all-interior-design-jobs.command.js +8 -0
  81. package/build/commands/tools/interior-design/delete-interior-design-job-by-uuid.command.js +11 -0
  82. package/build/commands/tools/interior-design/find-interior-design-job-by-uuid.command.js +14 -0
  83. package/build/commands/tools/interior-design/find-interior-design-jobs.command.js +18 -0
  84. package/build/commands/tools/interior-design/get-interior-design-tool-config.command.js +11 -0
  85. package/build/commands/tools/interior-design/index.js +25 -0
  86. package/build/commands/tools/interior-design/interior-design.command.js +20 -0
  87. package/build/commands/tools/interior-design/retry-interior-design-job.command.js +25 -0
  88. package/build/commands/tools/interior-design/set-reaction-to-interior-design-job.command.js +28 -0
  89. package/build/commands/tools/interior-design/update-interior-design-job-title.command.js +17 -0
  90. package/build/commands/tools/marketplace-card/delete-all-marketplace-card-jobs.command.js +10 -0
  91. package/build/commands/tools/marketplace-card/delete-marketplace-card-by-uuid.command.js +13 -0
  92. package/build/commands/tools/marketplace-card/execute-marketplace-card.command.js +48 -0
  93. package/build/commands/tools/marketplace-card/find-marketplace-card-job-by-uuid.command.js +14 -0
  94. package/build/commands/tools/marketplace-card/find-marketplace-card-jobs.command.js +18 -0
  95. package/build/commands/tools/marketplace-card/get-marketplace-card-config.command.js +11 -0
  96. package/build/commands/tools/marketplace-card/index.js +25 -0
  97. package/build/commands/tools/marketplace-card/retry-marketplace-card-job.command.js +51 -0
  98. package/build/commands/tools/marketplace-card/set-reaction-to-marketplace-card.command.js +28 -0
  99. package/build/commands/tools/marketplace-card/update-marketplace-card-job-title.command.js +17 -0
  100. package/build/commands/tools/solving-edu-task/delete-all-solving-edu-task-jobs.command.js +10 -0
  101. package/build/commands/tools/solving-edu-task/delete-solving-edu-task-job-by-uuid.command.js +13 -0
  102. package/build/commands/tools/solving-edu-task/find-solving-edu-task-job-by-uuid.command.js +14 -0
  103. package/build/commands/tools/solving-edu-task/find-solving-edu-task-jobs.command.js +18 -0
  104. package/build/commands/tools/solving-edu-task/get-solving-edu-task-tool-config.command.js +11 -0
  105. package/build/commands/tools/solving-edu-task/index.js +25 -0
  106. package/build/commands/tools/solving-edu-task/retry-solving-edu-task-job.command.js +23 -0
  107. package/build/commands/tools/solving-edu-task/set-reaction-to-solving-edu-task-job.command.js +28 -0
  108. package/build/commands/tools/solving-edu-task/solving-edu-task.command.js +30 -0
  109. package/build/commands/tools/solving-edu-task/update-solving-edu-task-job-title.command.js +17 -0
  110. package/build/commands/user/get-me.command.js +2 -1
  111. package/build/commands/user/get-user-payments.command.js +3 -1
  112. package/build/constants/ai-model/enums/index.js +0 -1
  113. package/build/constants/billing/enums/billing-scope.enum.js +8 -0
  114. package/build/constants/{errors → billing/enums}/index.js +1 -2
  115. package/build/constants/billing/index.js +17 -0
  116. package/build/constants/cabinet/enums/index.js +1 -0
  117. package/build/constants/cabinet/enums/statistics-metric-type.enum.js +8 -0
  118. package/build/constants/index.js +2 -1
  119. package/build/constants/model/enums/unified-model-content-type.enum.js +2 -1
  120. package/build/constants/page/enums/index.js +1 -0
  121. package/build/constants/page/enums/page-sort-by.enum.js +8 -0
  122. package/build/constants/payment/enums/index.js +1 -0
  123. package/build/constants/payment/enums/payment-provider.enum.js +8 -0
  124. package/build/constants/product/enums/product-status.enum.js +1 -0
  125. package/build/constants/subscription/enums/subscription-feature-type.enum.js +5 -1
  126. package/build/constants/subscription/enums/subscription-status.enum.js +1 -0
  127. package/build/constants/subscription/enums/user-to-subscription-marks.enum.js +1 -0
  128. package/build/constants/team-account/enums/index.js +20 -0
  129. package/build/constants/team-account/enums/team-account-invite-status.enum.js +10 -0
  130. package/build/constants/team-account/enums/team-account-member-role.enum.js +9 -0
  131. package/build/constants/team-account/enums/team-account-member-status.enum.js +11 -0
  132. package/build/constants/team-account/enums/team-account-operation-type.enum.js +10 -0
  133. package/build/constants/team-account/index.js +17 -0
  134. package/build/constants/tool/enums/index.js +0 -1
  135. package/build/constants/transaction/enums/user-balance-status.enum.js +3 -0
  136. package/build/constants/ui-notification/enums/ui-notification-type.enum.js +1 -0
  137. package/build/constants/user/enums/user-status.js +1 -0
  138. package/build/helpers/index.js +1 -0
  139. package/build/helpers/interior-design/calculate-interior-design-price.helper.js +13 -0
  140. package/build/helpers/interior-design/index.js +17 -0
  141. package/build/models/ai-model.schema.js +0 -1
  142. package/build/models/b2b/b2b-completions-stream-chunk.schema.js +10 -0
  143. package/build/models/b2b/b2b-file-upload-response.schema.js +11 -0
  144. package/build/models/b2b/index.js +18 -0
  145. package/build/models/chat.schema.js +1 -1
  146. package/build/models/community/community-post-media-data.schema.js +1 -0
  147. package/build/models/index.js +3 -0
  148. package/build/models/json-value.schema.js +13 -0
  149. package/build/models/message.schema.js +1 -0
  150. package/build/models/payment.schema.js +8 -3
  151. package/build/models/product.schema.js +2 -0
  152. package/build/models/prompt.schema.js +0 -2
  153. package/build/models/subscription-feature.schema.js +24 -3
  154. package/build/models/subscription.schema.js +1 -0
  155. package/build/models/team-account/index.js +22 -0
  156. package/build/models/team-account/team-account-invite.schema.js +20 -0
  157. package/build/models/team-account/team-account-member.schema.js +17 -0
  158. package/build/models/team-account/team-account-operation.schema.js +12 -0
  159. package/build/models/team-account/team-account.schema.js +14 -0
  160. package/build/models/team-account/team-to-product.schema.js +21 -0
  161. package/build/models/team-account/team-to-subscription.schema.js +31 -0
  162. package/build/models/tools/image-editor/image-editor-job.schema.js +1 -0
  163. package/build/models/tools/image-editor/image-editor-model.schema.js +6 -0
  164. package/build/models/tools/image-generation/image-generation-model.schema.js +8 -5
  165. package/build/models/tools/index.js +3 -0
  166. package/build/models/tools/interior-design/index.js +19 -0
  167. package/build/models/tools/interior-design/interior-design-config.schema.js +23 -0
  168. package/build/models/tools/interior-design/interior-design-job.schema.js +27 -0
  169. package/build/models/tools/interior-design/interior-design-model.schema.js +34 -0
  170. package/build/models/tools/marketplace-card/index.js +18 -0
  171. package/build/models/tools/marketplace-card/marketplace-card-config.schema.js +30 -0
  172. package/build/models/tools/marketplace-card/marketplace-card-job.schema.js +24 -0
  173. package/build/models/tools/solving-edu-task/index.js +19 -0
  174. package/build/models/tools/solving-edu-task/solving-edu-task-config.schema.js +8 -0
  175. package/build/models/tools/solving-edu-task/solving-edu-task-job.schema.js +25 -0
  176. package/build/models/tools/solving-edu-task/solving-edu-task-model.schema.js +22 -0
  177. package/build/models/tools/video-editor/video-editor-job.schema.js +14 -1
  178. package/build/models/user-profile.schema.js +1 -0
  179. package/commands/b2b/get-b2b-documentation.command.ts +121 -0
  180. package/commands/b2b/index.ts +2 -0
  181. package/commands/b2b/send-text-request.command.ts +2 -5
  182. package/commands/b2b/upload-b2b-file.command.ts +14 -0
  183. package/commands/cabinet/get-user-statistics-by-month.command.ts +5 -1
  184. package/commands/chat/archive-all.command.ts +2 -4
  185. package/commands/chat/check-limit.command.ts +7 -0
  186. package/commands/chat/create-chat.command.ts +0 -1
  187. package/commands/chat/find-chats.command.ts +2 -5
  188. package/commands/chat/get-last-active-chat-command.ts +0 -1
  189. package/commands/index.ts +3 -0
  190. package/commands/message/create-text-message.command.ts +1 -0
  191. package/commands/page/find-pages-by-criteria.command.ts +50 -0
  192. package/commands/page/index.ts +1 -0
  193. package/commands/payment/find-payments-by-criteria.command.ts +63 -0
  194. package/commands/payment/index.ts +1 -0
  195. package/commands/product/buy-product.command.ts +27 -1
  196. package/commands/product/index.ts +1 -0
  197. package/commands/product/refund-product.command.ts +17 -0
  198. package/commands/subscription/buy-subscription.command.ts +26 -1
  199. package/commands/subscription/index.ts +1 -1
  200. package/commands/subscription/refund-subscription.command.ts +17 -0
  201. package/commands/subscription/upgrade-subscription.command.ts +27 -1
  202. package/commands/team-account/accept-team-account-invite.command.ts +16 -0
  203. package/commands/team-account/create-manual-team-product.command.ts +17 -0
  204. package/commands/team-account/create-manual-team-subscription.command.ts +18 -0
  205. package/commands/team-account/create-team-account.command.ts +18 -0
  206. package/commands/team-account/find-current-team-account-products.command.ts +10 -0
  207. package/commands/team-account/find-current-team-account-subscriptions.command.ts +10 -0
  208. package/commands/team-account/find-team-account-members.command.ts +10 -0
  209. package/commands/team-account/find-team-account-operations.command.ts +17 -0
  210. package/commands/team-account/find-team-account-products.command.ts +10 -0
  211. package/commands/team-account/find-team-account-subscriptions.command.ts +10 -0
  212. package/commands/team-account/find-team-accounts-by-name.command.ts +20 -0
  213. package/commands/team-account/get-my-team-account.command.ts +10 -0
  214. package/commands/team-account/get-team-account-balance.command.ts +14 -0
  215. package/commands/team-account/index.ts +17 -0
  216. package/commands/team-account/invite-team-account-member.command.ts +19 -0
  217. package/commands/team-account/refund-team-account-balance.command.ts +16 -0
  218. package/commands/team-account/remove-team-account-member.command.ts +17 -0
  219. package/commands/team-account/update-team-account-member.command.ts +25 -0
  220. package/commands/team-account/update-team-account.command.ts +24 -0
  221. package/commands/team-to-product/add-team-to-product.command.ts +18 -0
  222. package/commands/team-to-product/get-team-to-product-by-uuid.command.ts +16 -0
  223. package/commands/team-to-product/get-team-to-products.command.ts +16 -0
  224. package/commands/team-to-product/index.ts +4 -0
  225. package/commands/team-to-product/update-team-to-product.command.ts +26 -0
  226. package/commands/team-to-subscription/add-team-to-subscription.command.ts +22 -0
  227. package/commands/team-to-subscription/get-team-to-subscription-by-uuid.command.ts +16 -0
  228. package/commands/team-to-subscription/get-team-to-subscriptions.command.ts +16 -0
  229. package/commands/team-to-subscription/index.ts +4 -0
  230. package/commands/team-to-subscription/update-team-to-subscription.command.ts +36 -0
  231. package/commands/tools/image-editor/image-editor.command.ts +1 -0
  232. package/commands/tools/image-editor/retry-image-editor-job.command.ts +1 -0
  233. package/commands/tools/index.ts +3 -0
  234. package/commands/tools/interior-design/delete-all-interior-design-jobs.command.ts +6 -0
  235. package/commands/tools/interior-design/delete-interior-design-job-by-uuid.command.ts +11 -0
  236. package/commands/tools/interior-design/find-interior-design-job-by-uuid.command.ts +16 -0
  237. package/commands/tools/interior-design/find-interior-design-jobs.command.ts +18 -0
  238. package/commands/tools/interior-design/get-interior-design-tool-config.command.ts +10 -0
  239. package/commands/tools/interior-design/index.ts +9 -0
  240. package/commands/tools/interior-design/interior-design.command.ts +21 -0
  241. package/commands/tools/interior-design/retry-interior-design-job.command.ts +27 -0
  242. package/commands/tools/interior-design/set-reaction-to-interior-design-job.command.ts +33 -0
  243. package/commands/tools/interior-design/update-interior-design-job-title.command.ts +19 -0
  244. package/commands/tools/marketplace-card/delete-all-marketplace-card-jobs.command.ts +8 -0
  245. package/commands/tools/marketplace-card/delete-marketplace-card-by-uuid.command.ts +13 -0
  246. package/commands/tools/marketplace-card/execute-marketplace-card.command.ts +53 -0
  247. package/commands/tools/marketplace-card/find-marketplace-card-job-by-uuid.command.ts +16 -0
  248. package/commands/tools/marketplace-card/find-marketplace-card-jobs.command.ts +18 -0
  249. package/commands/tools/marketplace-card/get-marketplace-card-config.command.ts +9 -0
  250. package/commands/tools/marketplace-card/index.ts +9 -0
  251. package/commands/tools/marketplace-card/retry-marketplace-card-job.command.ts +57 -0
  252. package/commands/tools/marketplace-card/set-reaction-to-marketplace-card.command.ts +33 -0
  253. package/commands/tools/marketplace-card/update-marketplace-card-job-title.command.ts +19 -0
  254. package/commands/tools/solving-edu-task/delete-all-solving-edu-task-jobs.command.ts +8 -0
  255. package/commands/tools/solving-edu-task/delete-solving-edu-task-job-by-uuid.command.ts +13 -0
  256. package/commands/tools/solving-edu-task/find-solving-edu-task-job-by-uuid.command.ts +16 -0
  257. package/commands/tools/solving-edu-task/find-solving-edu-task-jobs.command.ts +18 -0
  258. package/commands/tools/solving-edu-task/get-solving-edu-task-tool-config.command.ts +9 -0
  259. package/commands/tools/solving-edu-task/index.ts +9 -0
  260. package/commands/tools/solving-edu-task/retry-solving-edu-task-job.command.ts +25 -0
  261. package/commands/tools/solving-edu-task/set-reaction-to-solving-edu-task-job.command.ts +33 -0
  262. package/commands/tools/solving-edu-task/solving-edu-task.command.ts +31 -0
  263. package/commands/tools/solving-edu-task/update-solving-edu-task-job-title.command.ts +19 -0
  264. package/commands/user/get-me.command.ts +2 -1
  265. package/commands/user/get-user-payments.command.ts +4 -2
  266. package/constants/ai-model/enums/index.ts +0 -1
  267. package/constants/billing/enums/billing-scope.enum.ts +4 -0
  268. package/constants/billing/enums/index.ts +1 -0
  269. package/constants/billing/index.ts +1 -0
  270. package/constants/cabinet/enums/index.ts +1 -0
  271. package/constants/cabinet/enums/statistics-metric-type.enum.ts +4 -0
  272. package/constants/index.ts +2 -1
  273. package/constants/model/enums/unified-model-content-type.enum.ts +2 -1
  274. package/constants/page/enums/index.ts +1 -0
  275. package/constants/page/enums/page-sort-by.enum.ts +4 -0
  276. package/constants/payment/enums/index.ts +1 -0
  277. package/constants/payment/enums/payment-provider.enum.ts +4 -0
  278. package/constants/product/enums/product-status.enum.ts +1 -0
  279. package/constants/subscription/enums/subscription-feature-type.enum.ts +5 -1
  280. package/constants/subscription/enums/subscription-status.enum.ts +1 -0
  281. package/constants/subscription/enums/user-to-subscription-marks.enum.ts +1 -0
  282. package/constants/team-account/enums/index.ts +4 -0
  283. package/constants/team-account/enums/team-account-invite-status.enum.ts +6 -0
  284. package/constants/team-account/enums/team-account-member-role.enum.ts +5 -0
  285. package/constants/team-account/enums/team-account-member-status.enum.ts +7 -0
  286. package/constants/team-account/enums/team-account-operation-type.enum.ts +6 -0
  287. package/constants/team-account/index.ts +1 -0
  288. package/constants/tool/enums/index.ts +0 -1
  289. package/constants/transaction/enums/user-balance-status.enum.ts +3 -0
  290. package/constants/ui-notification/enums/ui-notification-type.enum.ts +1 -0
  291. package/constants/user/enums/user-status.ts +1 -0
  292. package/helpers/index.ts +1 -0
  293. package/helpers/interior-design/calculate-interior-design-price.helper.ts +23 -0
  294. package/helpers/interior-design/index.ts +1 -0
  295. package/models/ai-model.schema.ts +3 -7
  296. package/models/b2b/b2b-completions-stream-chunk.schema.ts +10 -0
  297. package/models/b2b/b2b-file-upload-response.schema.ts +14 -0
  298. package/models/b2b/index.ts +2 -0
  299. package/models/chat.schema.ts +1 -1
  300. package/models/community/community-post-media-data.schema.ts +1 -0
  301. package/models/index.ts +3 -0
  302. package/models/json-value.schema.ts +23 -0
  303. package/models/message.schema.ts +1 -0
  304. package/models/payment.schema.ts +7 -2
  305. package/models/product.schema.ts +2 -0
  306. package/models/prompt.schema.ts +0 -2
  307. package/models/subscription-feature.schema.ts +32 -7
  308. package/models/subscription.schema.ts +7 -1
  309. package/models/team-account/index.ts +6 -0
  310. package/models/team-account/team-account-invite.schema.ts +18 -0
  311. package/models/team-account/team-account-member.schema.ts +15 -0
  312. package/models/team-account/team-account-operation.schema.ts +10 -0
  313. package/models/team-account/team-account.schema.ts +12 -0
  314. package/models/team-account/team-to-product.schema.ts +20 -0
  315. package/models/team-account/team-to-subscription.schema.ts +33 -0
  316. package/models/tools/image-editor/image-editor-job.schema.ts +1 -0
  317. package/models/tools/image-editor/image-editor-model.schema.ts +9 -0
  318. package/models/tools/image-generation/image-generation-model.schema.ts +8 -5
  319. package/models/tools/index.ts +3 -0
  320. package/models/tools/interior-design/index.ts +3 -0
  321. package/models/tools/interior-design/interior-design-config.schema.ts +29 -0
  322. package/models/tools/interior-design/interior-design-job.schema.ts +32 -0
  323. package/models/tools/interior-design/interior-design-model.schema.ts +45 -0
  324. package/models/tools/marketplace-card/index.ts +2 -0
  325. package/models/tools/marketplace-card/marketplace-card-config.schema.ts +33 -0
  326. package/models/tools/marketplace-card/marketplace-card-job.schema.ts +25 -0
  327. package/models/tools/solving-edu-task/index.ts +3 -0
  328. package/models/tools/solving-edu-task/solving-edu-task-config.schema.ts +8 -0
  329. package/models/tools/solving-edu-task/solving-edu-task-job.schema.ts +28 -0
  330. package/models/tools/solving-edu-task/solving-edu-task-model.schema.ts +25 -0
  331. package/models/tools/video-editor/video-editor-job.schema.ts +14 -1
  332. package/models/user-profile.schema.ts +1 -0
  333. package/package.json +1 -1
  334. package/build/commands/subscription/create-custom-subscription-plan.command.js +0 -24
  335. package/build/constants/ai-model/enums/ai-model-content-type.enum.js +0 -7
  336. package/build/constants/errors/errors.js +0 -4351
  337. package/build/constants/errors/verbose.js +0 -9
  338. package/build/constants/tool/enums/tool-type.enum.js +0 -12
  339. package/commands/subscription/create-custom-subscription-plan.command.ts +0 -26
  340. package/constants/ai-model/enums/ai-model-content-type.enum.ts +0 -7
  341. package/constants/errors/errors.ts +0 -4391
  342. package/constants/errors/index.ts +0 -2
  343. package/constants/errors/verbose.ts +0 -7
  344. package/constants/tool/enums/tool-type.enum.ts +0 -8
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.UpdateSolvingEduTaskJobTitleCommand = void 0;
4
+ const zod_1 = require("zod");
5
+ const models_1 = require("../../../models");
6
+ var UpdateSolvingEduTaskJobTitleCommand;
7
+ (function (UpdateSolvingEduTaskJobTitleCommand) {
8
+ UpdateSolvingEduTaskJobTitleCommand.RequestSchema = zod_1.z.object({
9
+ title: zod_1.z.string(),
10
+ });
11
+ UpdateSolvingEduTaskJobTitleCommand.RequestParamsSchema = zod_1.z.object({
12
+ uuid: zod_1.z.string().uuid(),
13
+ });
14
+ UpdateSolvingEduTaskJobTitleCommand.ResponseSchema = zod_1.z.object({
15
+ data: models_1.SolvingEduTaskJobSchema,
16
+ });
17
+ })(UpdateSolvingEduTaskJobTitleCommand || (exports.UpdateSolvingEduTaskJobTitleCommand = UpdateSolvingEduTaskJobTitleCommand = {}));
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GetMeCommand = void 0;
4
- const constants_1 = require("../../constants");
5
4
  const zod_1 = require("zod");
5
+ const constants_1 = require("../../constants");
6
6
  const models_1 = require("../../models");
7
7
  var GetMeCommand;
8
8
  (function (GetMeCommand) {
@@ -15,6 +15,7 @@ var GetMeCommand;
15
15
  role: zod_1.z.nativeEnum(constants_1.ROLE),
16
16
  signupMethod: zod_1.z.nativeEnum(constants_1.SIGNUP_METHOD),
17
17
  telegramId: zod_1.z.number().nullable(),
18
+ telegramUserName: zod_1.z.string().nullable(),
18
19
  webmasterId: zod_1.z.string().uuid().nullable(),
19
20
  profile: models_1.UserProfileResponseSchema,
20
21
  }),
@@ -21,6 +21,8 @@ var GetUserPaymentsCommand;
21
21
  })
22
22
  .partial();
23
23
  GetUserPaymentsCommand.ResponseSchema = zod_1.default.object({
24
- data: zod_1.default.array(models_1.PaymentWithDescriptionSchema),
24
+ data: zod_1.default.array(models_1.PaymentWithUserDataSchema),
25
+ page: zod_1.default.number(),
26
+ totalPages: zod_1.default.number(),
25
27
  });
26
28
  })(GetUserPaymentsCommand || (exports.GetUserPaymentsCommand = GetUserPaymentsCommand = {}));
@@ -15,7 +15,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./ai-model-config-selector-type.enum"), exports);
18
- __exportStar(require("./ai-model-content-type.enum"), exports);
19
18
  __exportStar(require("./ai-model-feature.enum"), exports);
20
19
  __exportStar(require("./ai-model-status.enum"), exports);
21
20
  __exportStar(require("./ai-model-strategy.enum"), exports);
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BILLING_SCOPE = void 0;
4
+ var BILLING_SCOPE;
5
+ (function (BILLING_SCOPE) {
6
+ BILLING_SCOPE["USER"] = "user";
7
+ BILLING_SCOPE["TEAM"] = "team";
8
+ })(BILLING_SCOPE || (exports.BILLING_SCOPE = BILLING_SCOPE = {}));
@@ -14,5 +14,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./verbose"), exports);
18
- __exportStar(require("./errors"), exports);
17
+ __exportStar(require("./billing-scope.enum"), exports);
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./enums"), exports);
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./group-by.enum"), exports);
18
+ __exportStar(require("./statistics-metric-type.enum"), exports);
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.STATISTICS_METRIC_TYPE = void 0;
4
+ var STATISTICS_METRIC_TYPE;
5
+ (function (STATISTICS_METRIC_TYPE) {
6
+ STATISTICS_METRIC_TYPE["REQUESTS"] = "requests";
7
+ STATISTICS_METRIC_TYPE["TOKENS"] = "tokens";
8
+ })(STATISTICS_METRIC_TYPE || (exports.STATISTICS_METRIC_TYPE = STATISTICS_METRIC_TYPE = {}));
@@ -16,13 +16,13 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./ai-model"), exports);
18
18
  __exportStar(require("./blog"), exports);
19
+ __exportStar(require("./billing"), exports);
19
20
  __exportStar(require("./category"), exports);
20
21
  __exportStar(require("./chat"), exports);
21
22
  __exportStar(require("./cloud-payments"), exports);
22
23
  __exportStar(require("./course"), exports);
23
24
  __exportStar(require("./domains"), exports);
24
25
  __exportStar(require("./email"), exports);
25
- __exportStar(require("./errors"), exports);
26
26
  __exportStar(require("./file"), exports);
27
27
  __exportStar(require("./form-submission"), exports);
28
28
  __exportStar(require("./form-submission"), exports);
@@ -61,3 +61,4 @@ __exportStar(require("./community"), exports);
61
61
  __exportStar(require("./user-profile"), exports);
62
62
  __exportStar(require("./model"), exports);
63
63
  __exportStar(require("./token-reservation"), exports);
64
+ __exportStar(require("./team-account"), exports);
@@ -5,7 +5,6 @@ var UNIFIED_MODEL_CONTENT_TYPE;
5
5
  (function (UNIFIED_MODEL_CONTENT_TYPE) {
6
6
  // AI Model types
7
7
  UNIFIED_MODEL_CONTENT_TYPE["TEXT"] = "TEXT";
8
- UNIFIED_MODEL_CONTENT_TYPE["IMAGE"] = "IMAGE";
9
8
  // Tool types
10
9
  UNIFIED_MODEL_CONTENT_TYPE["IMAGE_EDITOR"] = "IMAGE_EDITOR";
11
10
  UNIFIED_MODEL_CONTENT_TYPE["TEXT_TO_SPEECH"] = "TEXT_TO_SPEECH";
@@ -18,4 +17,6 @@ var UNIFIED_MODEL_CONTENT_TYPE;
18
17
  UNIFIED_MODEL_CONTENT_TYPE["MUSIC"] = "MUSIC";
19
18
  UNIFIED_MODEL_CONTENT_TYPE["NONE"] = "NONE";
20
19
  UNIFIED_MODEL_CONTENT_TYPE["IMAGE_GENERATION"] = "IMAGE_GENERATION";
20
+ UNIFIED_MODEL_CONTENT_TYPE["INTERIOR_DESIGN"] = "INTERIOR_DESIGN";
21
+ UNIFIED_MODEL_CONTENT_TYPE["MARKETPLACE_CARD"] = "MARKETPLACE_CARD";
21
22
  })(UNIFIED_MODEL_CONTENT_TYPE || (exports.UNIFIED_MODEL_CONTENT_TYPE = UNIFIED_MODEL_CONTENT_TYPE = {}));
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./page-type.enum"), exports);
18
+ __exportStar(require("./page-sort-by.enum"), exports);
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PAGE_SORT_BY = void 0;
4
+ var PAGE_SORT_BY;
5
+ (function (PAGE_SORT_BY) {
6
+ PAGE_SORT_BY["CREATED_AT"] = "createdAt";
7
+ PAGE_SORT_BY["UPDATED_AT"] = "updatedAt";
8
+ })(PAGE_SORT_BY || (exports.PAGE_SORT_BY = PAGE_SORT_BY = {}));
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./payment-history-item-type.enum"), exports);
18
18
  __exportStar(require("./payment-status.enum"), exports);
19
19
  __exportStar(require("./payment-sort-by.enum"), exports);
20
+ __exportStar(require("./payment-provider.enum"), exports);
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PAYMENT_PROVIDER = void 0;
4
+ var PAYMENT_PROVIDER;
5
+ (function (PAYMENT_PROVIDER) {
6
+ PAYMENT_PROVIDER["CLOUDPAYMENTS"] = "cloudpayments";
7
+ PAYMENT_PROVIDER["ZENPAYMENTS"] = "zenpayments";
8
+ })(PAYMENT_PROVIDER || (exports.PAYMENT_PROVIDER = PAYMENT_PROVIDER = {}));
@@ -7,4 +7,5 @@ var PRODUCT_STATUS;
7
7
  PRODUCT_STATUS["canceled"] = "canceled";
8
8
  PRODUCT_STATUS["depleted"] = "depleted";
9
9
  PRODUCT_STATUS["expired"] = "expired";
10
+ PRODUCT_STATUS["refunded"] = "refunded";
10
11
  })(PRODUCT_STATUS || (exports.PRODUCT_STATUS = PRODUCT_STATUS = {}));
@@ -11,6 +11,7 @@ var SUBSCRIPTION_FEATURE_TYPE;
11
11
  SUBSCRIPTION_FEATURE_TYPE["ADVANCED_TOOLS_ACCESS"] = "advanced_tools_access";
12
12
  SUBSCRIPTION_FEATURE_TYPE["STT_MODEL_ACCESS"] = "stt_model_access";
13
13
  SUBSCRIPTION_FEATURE_TYPE["TTS_MODEL_ACCESS"] = "tts_model_access";
14
+ SUBSCRIPTION_FEATURE_TYPE["IMAGE_GENERATION_ACCESS"] = "image_generation_access";
14
15
  SUBSCRIPTION_FEATURE_TYPE["IMAGE_GENERATION_QUOTA"] = "image_generation_quota";
15
16
  SUBSCRIPTION_FEATURE_TYPE["TTS_QUOTA"] = "tts_quota";
16
17
  SUBSCRIPTION_FEATURE_TYPE["STT_QUOTA"] = "stt_quota";
@@ -26,12 +27,14 @@ var SUBSCRIPTION_FEATURE_TYPE;
26
27
  SUBSCRIPTION_FEATURE_TYPE["WRITER_MODEL_ACCESS"] = "writer_model_access";
27
28
  SUBSCRIPTION_FEATURE_TYPE["IMAGE_EDITOR_QUOTA"] = "image_editor_quota";
28
29
  SUBSCRIPTION_FEATURE_TYPE["IMAGE_EDITOR_MODEL_ACCESS"] = "image_editor_model_access";
30
+ SUBSCRIPTION_FEATURE_TYPE["INTERIOR_DESIGN_QUOTA"] = "interior_design_quota";
31
+ SUBSCRIPTION_FEATURE_TYPE["INTERIOR_DESIGN_MODEL_ACCESS"] = "interior_design_model_access";
29
32
  })(SUBSCRIPTION_FEATURE_TYPE || (exports.SUBSCRIPTION_FEATURE_TYPE = SUBSCRIPTION_FEATURE_TYPE = {}));
30
33
  var SUBSCRIPTION_FEATURE_KIND;
31
34
  (function (SUBSCRIPTION_FEATURE_KIND) {
32
35
  SUBSCRIPTION_FEATURE_KIND["TEXT"] = "text";
33
36
  SUBSCRIPTION_FEATURE_KIND["AI_MODEL"] = "ai_model";
34
- SUBSCRIPTION_FEATURE_KIND["IMAGE"] = "image";
37
+ SUBSCRIPTION_FEATURE_KIND["IMAGE_GENERATION"] = "image_generation";
35
38
  SUBSCRIPTION_FEATURE_KIND["TTS"] = "tts";
36
39
  SUBSCRIPTION_FEATURE_KIND["STT"] = "stt";
37
40
  SUBSCRIPTION_FEATURE_KIND["PRESENTATIONS"] = "presentations";
@@ -41,4 +44,5 @@ var SUBSCRIPTION_FEATURE_KIND;
41
44
  SUBSCRIPTION_FEATURE_KIND["MUSIC"] = "music";
42
45
  SUBSCRIPTION_FEATURE_KIND["WRITER"] = "writer";
43
46
  SUBSCRIPTION_FEATURE_KIND["IMAGE_EDITOR"] = "image_editor";
47
+ SUBSCRIPTION_FEATURE_KIND["INTERIOR_DESIGN"] = "interior_design";
44
48
  })(SUBSCRIPTION_FEATURE_KIND || (exports.SUBSCRIPTION_FEATURE_KIND = SUBSCRIPTION_FEATURE_KIND = {}));
@@ -14,4 +14,5 @@ var SUBSCRIPTION_STATUS;
14
14
  SUBSCRIPTION_STATUS["awaiting_downgrade"] = "awaiting_downgrade";
15
15
  SUBSCRIPTION_STATUS["downgrade_canceled"] = "downgrade_canceled";
16
16
  SUBSCRIPTION_STATUS["deleted"] = "deleted";
17
+ SUBSCRIPTION_STATUS["refunded"] = "refunded";
17
18
  })(SUBSCRIPTION_STATUS || (exports.SUBSCRIPTION_STATUS = SUBSCRIPTION_STATUS = {}));
@@ -5,6 +5,7 @@ var USER_TO_SUBSCRIPTION_MARKS;
5
5
  (function (USER_TO_SUBSCRIPTION_MARKS) {
6
6
  USER_TO_SUBSCRIPTION_MARKS["WITHOUT_AUTO_RENEWAL"] = "WITHOUT_AUTO_RENEWAL";
7
7
  USER_TO_SUBSCRIPTION_MARKS["MOCK"] = "MOCK";
8
+ USER_TO_SUBSCRIPTION_MARKS["MANUAL_GRANT"] = "MANUAL_GRANT";
8
9
  USER_TO_SUBSCRIPTION_MARKS["SENT_RENEWAL_REMINDER"] = "SENT_RENEWAL_REMINDER";
9
10
  USER_TO_SUBSCRIPTION_MARKS["SENT_CANCELLATION_WARNING"] = "SENT_CANCELLATION_WARNING";
10
11
  USER_TO_SUBSCRIPTION_MARKS["SENT_PAST_DUE_RECOVER_REQUEST"] = "SENT_PAST_DUE_RECOVER_REQUEST";
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./team-account-invite-status.enum"), exports);
18
+ __exportStar(require("./team-account-member-role.enum"), exports);
19
+ __exportStar(require("./team-account-member-status.enum"), exports);
20
+ __exportStar(require("./team-account-operation-type.enum"), exports);
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TEAM_ACCOUNT_INVITE_STATUS = void 0;
4
+ var TEAM_ACCOUNT_INVITE_STATUS;
5
+ (function (TEAM_ACCOUNT_INVITE_STATUS) {
6
+ TEAM_ACCOUNT_INVITE_STATUS["PENDING"] = "pending";
7
+ TEAM_ACCOUNT_INVITE_STATUS["ACCEPTED"] = "accepted";
8
+ TEAM_ACCOUNT_INVITE_STATUS["EXPIRED"] = "expired";
9
+ TEAM_ACCOUNT_INVITE_STATUS["REVOKED"] = "revoked";
10
+ })(TEAM_ACCOUNT_INVITE_STATUS || (exports.TEAM_ACCOUNT_INVITE_STATUS = TEAM_ACCOUNT_INVITE_STATUS = {}));
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TEAM_ACCOUNT_MEMBER_ROLE = void 0;
4
+ var TEAM_ACCOUNT_MEMBER_ROLE;
5
+ (function (TEAM_ACCOUNT_MEMBER_ROLE) {
6
+ TEAM_ACCOUNT_MEMBER_ROLE["OWNER"] = "owner";
7
+ TEAM_ACCOUNT_MEMBER_ROLE["ADMIN"] = "admin";
8
+ TEAM_ACCOUNT_MEMBER_ROLE["MEMBER"] = "member";
9
+ })(TEAM_ACCOUNT_MEMBER_ROLE || (exports.TEAM_ACCOUNT_MEMBER_ROLE = TEAM_ACCOUNT_MEMBER_ROLE = {}));
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TEAM_ACCOUNT_MEMBER_STATUS = void 0;
4
+ var TEAM_ACCOUNT_MEMBER_STATUS;
5
+ (function (TEAM_ACCOUNT_MEMBER_STATUS) {
6
+ TEAM_ACCOUNT_MEMBER_STATUS["ACTIVE"] = "active";
7
+ TEAM_ACCOUNT_MEMBER_STATUS["INVITED"] = "invited";
8
+ TEAM_ACCOUNT_MEMBER_STATUS["SUSPENDED"] = "suspended";
9
+ TEAM_ACCOUNT_MEMBER_STATUS["LEFT"] = "left";
10
+ TEAM_ACCOUNT_MEMBER_STATUS["REMOVED"] = "removed";
11
+ })(TEAM_ACCOUNT_MEMBER_STATUS || (exports.TEAM_ACCOUNT_MEMBER_STATUS = TEAM_ACCOUNT_MEMBER_STATUS = {}));
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TEAM_ACCOUNT_OPERATION_TYPE = void 0;
4
+ var TEAM_ACCOUNT_OPERATION_TYPE;
5
+ (function (TEAM_ACCOUNT_OPERATION_TYPE) {
6
+ TEAM_ACCOUNT_OPERATION_TYPE["TOP_UP"] = "top_up";
7
+ TEAM_ACCOUNT_OPERATION_TYPE["WRITE_OFF"] = "write_off";
8
+ TEAM_ACCOUNT_OPERATION_TYPE["REFUND"] = "refund";
9
+ TEAM_ACCOUNT_OPERATION_TYPE["ADJUSTMENT"] = "adjustment";
10
+ })(TEAM_ACCOUNT_OPERATION_TYPE || (exports.TEAM_ACCOUNT_OPERATION_TYPE = TEAM_ACCOUNT_OPERATION_TYPE = {}));
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./enums"), exports);
@@ -16,5 +16,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./tool-content-type.enum"), exports);
18
18
  __exportStar(require("./tool-job-status.enum"), exports);
19
- __exportStar(require("./tool-type.enum"), exports);
20
19
  __exportStar(require("./job-request-origin.enum"), exports);
@@ -3,6 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.USER_BALANCE_STATUS = void 0;
4
4
  var USER_BALANCE_STATUS;
5
5
  (function (USER_BALANCE_STATUS) {
6
+ USER_BALANCE_STATUS["team_subscription_balance"] = "team_subscription_balance";
7
+ USER_BALANCE_STATUS["team_carried_over_balance"] = "team_carried_over_balance";
8
+ USER_BALANCE_STATUS["team_product_balance"] = "team_product_balance";
6
9
  USER_BALANCE_STATUS["bonus_balance"] = "bonus_balance";
7
10
  USER_BALANCE_STATUS["subscription_balance"] = "subscription_balance";
8
11
  USER_BALANCE_STATUS["carried_over_balance"] = "carried_over_balance";
@@ -5,4 +5,5 @@ var UI_NOTIFICATION_TYPE;
5
5
  (function (UI_NOTIFICATION_TYPE) {
6
6
  UI_NOTIFICATION_TYPE["CONNECT_TELEGRAM_BONUS"] = "CONNECT_TELEGRAM_BONUS";
7
7
  UI_NOTIFICATION_TYPE["SUBSCRIPTION_PAST_DUE"] = "SUBSCRIPTION_PAST_DUE";
8
+ UI_NOTIFICATION_TYPE["FRAUD_DETECTED"] = "FRAUD_DETECTED";
8
9
  })(UI_NOTIFICATION_TYPE || (exports.UI_NOTIFICATION_TYPE = UI_NOTIFICATION_TYPE = {}));
@@ -5,6 +5,7 @@ var USER_STATUS;
5
5
  (function (USER_STATUS) {
6
6
  USER_STATUS["ACTIVE"] = "active";
7
7
  USER_STATUS["INACTIVE"] = "inactive";
8
+ USER_STATUS["FRAUD"] = "fraud";
8
9
  USER_STATUS["TG_AUTO_REGISTERED"] = "tg_auto_registered";
9
10
  USER_STATUS["MERGED"] = "merged";
10
11
  USER_STATUS["DELETED"] = "deleted";
@@ -25,3 +25,4 @@ __exportStar(require("./writer"), exports);
25
25
  __exportStar(require("./image-editor"), exports);
26
26
  __exportStar(require("./image-generation"), exports);
27
27
  __exportStar(require("./music"), exports);
28
+ __exportStar(require("./interior-design"), exports);
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.calculateInteriorDesignPrice = calculateInteriorDesignPrice;
4
+ function calculateInteriorDesignPrice({ basePrice, userHasActiveSubscriptionOrProduct, rules, }) {
5
+ let price = basePrice;
6
+ for (const rule of rules !== null && rules !== void 0 ? rules : []) {
7
+ const condition = rule.condition;
8
+ if (condition.withoutSub && userHasActiveSubscriptionOrProduct === false) {
9
+ price += rule.value;
10
+ }
11
+ }
12
+ return price;
13
+ }
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./calculate-interior-design-price.helper"), exports);
@@ -15,7 +15,6 @@ exports.AiModelSchema = zod_1.z.object({
15
15
  order: zod_1.z.number(),
16
16
  canUse: zod_1.z.optional(zod_1.z.boolean()),
17
17
  status: zod_1.z.nativeEnum(constants_1.AI_MODEL_STATUS),
18
- contentType: zod_1.z.enum(Object.values(constants_1.AI_MODEL_CONTENT_TYPE)),
19
18
  features: zod_1.z.array(zod_1.z.nativeEnum(constants_1.AI_MODEL_FEATURE)),
20
19
  iconVariants: zod_1.z.object({
21
20
  light: zod_1.z.object({
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.B2bCompletionsStreamChunkSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.B2bCompletionsStreamChunkSchema = zod_1.z.object({
6
+ data: zod_1.z.object({
7
+ delta: zod_1.z.string().nullable(),
8
+ isFinish: zod_1.z.boolean(),
9
+ }),
10
+ });
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.B2bFileUploadResponseSchema = exports.B2bUploadedFileSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ const file_schema_1 = require("../file.schema");
6
+ exports.B2bUploadedFileSchema = file_schema_1.FileSchema.extend({
7
+ content: zod_1.z.string().nullable(),
8
+ });
9
+ exports.B2bFileUploadResponseSchema = zod_1.z.object({
10
+ data: exports.B2bUploadedFileSchema,
11
+ });
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./b2b-completions-stream-chunk.schema"), exports);
18
+ __exportStar(require("./b2b-file-upload-response.schema"), exports);
@@ -8,7 +8,7 @@ exports.ChatSchema = zod_1.z.object({
8
8
  userId: zod_1.z.nullable(zod_1.z.string().uuid()),
9
9
  unregisteredUserId: zod_1.z.nullable(zod_1.z.string().uuid()),
10
10
  categoryId: zod_1.z.string().uuid(),
11
- aIModelId: zod_1.z.string().uuid(),
11
+ lastUsedAiModelId: zod_1.z.string().uuid().nullable(),
12
12
  title: zod_1.z.string(),
13
13
  chatStatus: zod_1.z.enum(Object.values(constants_1.CHAT_STATUS_ENUM)),
14
14
  folderId: zod_1.z.string().nullable(),
@@ -42,6 +42,7 @@ exports.MusicCommunityMediaSchema = zod_1.z.object({
42
42
  coverUrl: zod_1.z.string(),
43
43
  duration: zod_1.z.number(),
44
44
  title: zod_1.z.string(),
45
+ waveformPeaks: zod_1.z.array(zod_1.z.number()).nullable().optional(),
45
46
  tags: zod_1.z.string(),
46
47
  }),
47
48
  });
@@ -73,3 +73,6 @@ __exportStar(require("./webmaster-click.schema"), exports);
73
73
  __exportStar(require("./api-key.schema"), exports);
74
74
  __exportStar(require("./community"), exports);
75
75
  __exportStar(require("./user-profile.schema"), exports);
76
+ __exportStar(require("./b2b"), exports);
77
+ __exportStar(require("./json-value.schema"), exports);
78
+ __exportStar(require("./team-account"), exports);
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.JsonObjectSchema = exports.JsonValueSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.JsonValueSchema = zod_1.z.lazy(() => zod_1.z.union([
6
+ zod_1.z.string(),
7
+ zod_1.z.number(),
8
+ zod_1.z.boolean(),
9
+ zod_1.z.null(),
10
+ zod_1.z.array(exports.JsonValueSchema),
11
+ zod_1.z.record(exports.JsonValueSchema),
12
+ ]));
13
+ exports.JsonObjectSchema = zod_1.z.record(exports.JsonValueSchema);
@@ -9,6 +9,7 @@ exports.MessageSchema = zod_1.z.object({
9
9
  text: zod_1.z.string().max(10000),
10
10
  chatId: zod_1.z.nullable(zod_1.z.string().uuid()),
11
11
  role: zod_1.z.string(),
12
+ aiModelId: zod_1.z.string().nullable(),
12
13
  tokenUsage: zod_1.z.number(),
13
14
  userReaction: zod_1.z.nativeEnum(constants_1.USER_REACTION).nullable(),
14
15
  files: zod_1.z.array(file_schema_1.FileSchema),
@@ -1,16 +1,21 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PaymentWithDescriptionSchema = exports.PaymentSchema = void 0;
3
+ exports.PaymentWithUserDataSchema = exports.PaymentSchema = void 0;
4
4
  const zod_1 = require("zod");
5
+ const constants_1 = require("../constants");
5
6
  exports.PaymentSchema = zod_1.z.object({
6
7
  uuid: zod_1.z.string().uuid(),
7
- link: zod_1.z.nullable(zod_1.z.string()),
8
8
  status: zod_1.z.string(),
9
9
  sum: zod_1.z.number(),
10
10
  orderId: zod_1.z.string().uuid(),
11
11
  createdAt: zod_1.z.date(),
12
12
  updatedAt: zod_1.z.date(),
13
13
  });
14
- exports.PaymentWithDescriptionSchema = exports.PaymentSchema.extend({
14
+ exports.PaymentWithUserDataSchema = exports.PaymentSchema.extend({
15
15
  description: zod_1.z.string(),
16
+ userId: zod_1.z.string().uuid(),
17
+ email: zod_1.z.string().email(),
18
+ singupMethod: zod_1.z.nativeEnum(constants_1.SIGNUP_METHOD),
19
+ vkId: zod_1.z.string().nullable(),
20
+ yandexId: zod_1.z.string().nullable(),
16
21
  });
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ProductSchema = exports.FeaturesSchema = void 0;
4
4
  const zod_1 = require("zod");
5
+ const constants_1 = require("../constants");
5
6
  const subscription_feature_schema_1 = require("./subscription-feature.schema");
6
7
  exports.FeaturesSchema = zod_1.z.object({
7
8
  icon: zod_1.z.string(),
@@ -12,6 +13,7 @@ exports.ProductSchema = zod_1.z.object({
12
13
  name: zod_1.z.string().min(3).max(16384),
13
14
  requests: zod_1.z.number(),
14
15
  price: zod_1.z.number(),
16
+ billingScope: zod_1.z.nativeEnum(constants_1.BILLING_SCOPE),
15
17
  icon: zod_1.z.string(),
16
18
  icons: zod_1.z.object({
17
19
  light: zod_1.z.object({
@@ -2,11 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.PromptSchema = void 0;
4
4
  const zod_1 = require("zod");
5
- const constants_1 = require("../constants");
6
5
  exports.PromptSchema = zod_1.z.object({
7
6
  uuid: zod_1.z.string().uuid(),
8
7
  content: zod_1.z.string(),
9
- type: zod_1.z.nativeEnum(constants_1.AI_MODEL_CONTENT_TYPE),
10
8
  topicId: zod_1.z.string().uuid().nullable(),
11
9
  title: zod_1.z.string().nullable(),
12
10
  createdAt: zod_1.z.date(),
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SubscriptionFeatureSchema = exports.ImageEditorModelAccessFeatureSchema = exports.ImageEditorQuotaFeatureSchema = exports.WriterModelAccessFeatureSchema = exports.WriterQuotaFeatureSchema = exports.MusicModelAccessFeatureSchema = exports.MusicQuotaFeatureSchema = exports.PresentationQuotaFeatureSchema = exports.VideoModelAccessFeatureSchema = exports.VideoQuotaFeatureSchema = exports.STTQuotaFeatureSchema = exports.STTModelAccessFeatureSchema = exports.TTSQuotaFeatureSchema = exports.ImageGenerationQuotaFeatureSchema = exports.TtsModelAccessFeatureSchema = exports.AdvancedToolsAccessFeatureSchema = exports.WebSearchFeatureSchema = exports.ExtendedContextFeatureSchema = exports.MaxInputLengthFeatureSchema = exports.RequestsQuotaFeatureSchema = exports.AiModelAccessFeatureSchema = exports.CarryoverBalanceFeatureSchema = exports.TokensFeatureSchema = exports.SubscriptionFeatureBaseSchema = void 0;
3
+ exports.SubscriptionFeatureSchema = exports.InteriorDesignModelAccessFeatureSchema = exports.InteriorDesignQuotaFeatureSchema = exports.ImageEditorModelAccessFeatureSchema = exports.ImageEditorQuotaFeatureSchema = exports.WriterModelAccessFeatureSchema = exports.WriterQuotaFeatureSchema = exports.MusicModelAccessFeatureSchema = exports.MusicQuotaFeatureSchema = exports.PresentationQuotaFeatureSchema = exports.VideoModelAccessFeatureSchema = exports.VideoQuotaFeatureSchema = exports.STTQuotaFeatureSchema = exports.STTModelAccessFeatureSchema = exports.TTSQuotaFeatureSchema = exports.ImageGenerationQuotaFeatureSchema = exports.TtsModelAccessFeatureSchema = exports.AdvancedToolsAccessFeatureSchema = exports.WebSearchFeatureSchema = exports.ExtendedContextFeatureSchema = exports.MaxInputLengthFeatureSchema = exports.RequestsQuotaFeatureSchema = exports.ImageGenerationAccessFeatureSchema = exports.AiModelAccessFeatureSchema = exports.CarryoverBalanceFeatureSchema = exports.TokensFeatureSchema = exports.SubscriptionFeatureBaseSchema = void 0;
4
4
  const constants_1 = require("../constants");
5
5
  const zod_1 = require("zod");
6
6
  exports.SubscriptionFeatureBaseSchema = zod_1.z.object({
@@ -36,7 +36,14 @@ exports.AiModelAccessFeatureSchema = exports.SubscriptionFeatureBaseSchema.exten
36
36
  kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.AI_MODEL),
37
37
  order: zod_1.z.number(),
38
38
  modelId: zod_1.z.string(),
39
- contentType: zod_1.z.nativeEnum(constants_1.AI_MODEL_CONTENT_TYPE),
39
+ isAvailable: zod_1.z.boolean(),
40
+ maxInputLength: zod_1.z.number(),
41
+ });
42
+ exports.ImageGenerationAccessFeatureSchema = exports.SubscriptionFeatureBaseSchema.extend({
43
+ type: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_TYPE.IMAGE_GENERATION_ACCESS),
44
+ kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.IMAGE_GENERATION),
45
+ order: zod_1.z.number(),
46
+ modelId: zod_1.z.string(),
40
47
  isAvailable: zod_1.z.boolean(),
41
48
  maxInputLength: zod_1.z.number(),
42
49
  });
@@ -74,7 +81,7 @@ exports.TtsModelAccessFeatureSchema = exports.SubscriptionFeatureBaseSchema.exte
74
81
  modelId: zod_1.z.string(),
75
82
  });
76
83
  exports.ImageGenerationQuotaFeatureSchema = exports.SubscriptionFeatureBaseSchema.extend({
77
- kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.IMAGE),
84
+ kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.IMAGE_GENERATION),
78
85
  type: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_TYPE.IMAGE_GENERATION_QUOTA),
79
86
  value: zod_1.z.number(),
80
87
  });
@@ -143,6 +150,17 @@ exports.ImageEditorModelAccessFeatureSchema = exports.SubscriptionFeatureBaseSch
143
150
  isAvailable: zod_1.z.boolean(),
144
151
  modelId: zod_1.z.string(),
145
152
  });
153
+ exports.InteriorDesignQuotaFeatureSchema = exports.SubscriptionFeatureBaseSchema.extend({
154
+ kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.INTERIOR_DESIGN),
155
+ type: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_TYPE.INTERIOR_DESIGN_QUOTA),
156
+ value: zod_1.z.number(),
157
+ });
158
+ exports.InteriorDesignModelAccessFeatureSchema = exports.SubscriptionFeatureBaseSchema.extend({
159
+ kind: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_KIND.INTERIOR_DESIGN),
160
+ type: zod_1.z.literal(constants_1.SUBSCRIPTION_FEATURE_TYPE.INTERIOR_DESIGN_MODEL_ACCESS),
161
+ isAvailable: zod_1.z.boolean(),
162
+ modelId: zod_1.z.string(),
163
+ });
146
164
  exports.SubscriptionFeatureSchema = zod_1.z.union([
147
165
  exports.AiModelAccessFeatureSchema,
148
166
  exports.RequestsQuotaFeatureSchema,
@@ -166,4 +184,7 @@ exports.SubscriptionFeatureSchema = zod_1.z.union([
166
184
  exports.WriterModelAccessFeatureSchema,
167
185
  exports.ImageEditorQuotaFeatureSchema,
168
186
  exports.ImageEditorModelAccessFeatureSchema,
187
+ exports.InteriorDesignQuotaFeatureSchema,
188
+ exports.InteriorDesignModelAccessFeatureSchema,
189
+ exports.ImageGenerationAccessFeatureSchema,
169
190
  ]);
@@ -10,6 +10,7 @@ exports.SubscriptionSchema = zod_1.z.object({
10
10
  name: zod_1.z.string().min(3).max(16384),
11
11
  requests: zod_1.z.number(),
12
12
  price: zod_1.z.number(),
13
+ billingScope: zod_1.z.nativeEnum(constants_1.BILLING_SCOPE),
13
14
  plan: zod_1.z.nativeEnum(constants_1.SUBSCRIPTION_PLAN),
14
15
  type: zod_1.z.nativeEnum(constants_1.SUBSCRIPTION_TYPE),
15
16
  discount: zod_1.z.number(),