@dalmore/api-contracts 0.0.0-dev.fc1b175 → 0.0.0-dev.fef3ec8

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 (721) hide show
  1. package/README.md +23 -19
  2. package/common/constants.d.ts +43 -0
  3. package/common/constants.js +77 -0
  4. package/common/constants.js.map +1 -0
  5. package/common/helpers/index.d.ts +58 -0
  6. package/common/helpers/index.js +151 -0
  7. package/common/helpers/index.js.map +1 -0
  8. package/common/types/account-contact.types.d.ts +485 -0
  9. package/common/types/account-contact.types.js +75 -0
  10. package/common/types/account-contact.types.js.map +1 -0
  11. package/common/types/account-detail.types.d.ts +304 -0
  12. package/common/types/account-detail.types.js +20 -0
  13. package/common/types/account-detail.types.js.map +1 -0
  14. package/common/types/account-integration.types.d.ts +242 -0
  15. package/common/types/account-integration.types.js +121 -0
  16. package/common/types/account-integration.types.js.map +1 -0
  17. package/common/types/account-manager.types.d.ts +917 -0
  18. package/common/types/account-manager.types.js +89 -0
  19. package/common/types/account-manager.types.js.map +1 -0
  20. package/common/types/account-setting.types.d.ts +140 -0
  21. package/common/types/account-setting.types.js +23 -0
  22. package/common/types/account-setting.types.js.map +1 -0
  23. package/common/types/account.types.d.ts +640 -0
  24. package/common/types/account.types.js +218 -0
  25. package/common/types/account.types.js.map +1 -0
  26. package/common/types/activity.types.d.ts +590 -0
  27. package/common/types/activity.types.js +258 -0
  28. package/common/types/activity.types.js.map +1 -0
  29. package/common/types/address.types.d.ts +89 -0
  30. package/common/types/address.types.js +36 -0
  31. package/common/types/address.types.js.map +1 -0
  32. package/common/types/aic.types.d.ts +434 -0
  33. package/common/types/aic.types.js +170 -0
  34. package/common/types/aic.types.js.map +1 -0
  35. package/common/types/aml.types.d.ts +41 -0
  36. package/common/types/aml.types.js +16 -0
  37. package/common/types/aml.types.js.map +1 -0
  38. package/common/types/api-key-logs.types.d.ts +204 -0
  39. package/common/types/api-key-logs.types.js +52 -0
  40. package/common/types/api-key-logs.types.js.map +1 -0
  41. package/common/types/api-keys.types.d.ts +192 -0
  42. package/common/types/api-keys.types.js +57 -0
  43. package/common/types/api-keys.types.js.map +1 -0
  44. package/common/types/asset.types.d.ts +1100 -0
  45. package/common/types/asset.types.js +353 -0
  46. package/common/types/asset.types.js.map +1 -0
  47. package/common/types/auth.types.d.ts +523 -0
  48. package/common/types/auth.types.js +280 -0
  49. package/common/types/auth.types.js.map +1 -0
  50. package/common/types/batch-jobs.types.d.ts +321 -0
  51. package/common/types/batch-jobs.types.js +111 -0
  52. package/common/types/batch-jobs.types.js.map +1 -0
  53. package/common/types/bonus-tier.types.d.ts +991 -0
  54. package/common/types/bonus-tier.types.js +166 -0
  55. package/common/types/bonus-tier.types.js.map +1 -0
  56. package/common/types/cap-table.types.d.ts +1248 -0
  57. package/common/types/cap-table.types.js +437 -0
  58. package/common/types/cap-table.types.js.map +1 -0
  59. package/common/types/cart.types.d.ts +28 -0
  60. package/common/types/cart.types.js +19 -0
  61. package/common/types/cart.types.js.map +1 -0
  62. package/common/types/checklist-items.types.d.ts +195 -0
  63. package/common/types/checklist-items.types.js +54 -0
  64. package/common/types/checklist-items.types.js.map +1 -0
  65. package/common/types/checklist.types.d.ts +140 -0
  66. package/common/types/checklist.types.js +71 -0
  67. package/common/types/checklist.types.js.map +1 -0
  68. package/common/types/common.types.d.ts +1861 -0
  69. package/common/types/common.types.js +1511 -0
  70. package/common/types/common.types.js.map +1 -0
  71. package/common/types/comply-advantage-api.types.d.ts +3626 -0
  72. package/common/types/comply-advantage-api.types.js +291 -0
  73. package/common/types/comply-advantage-api.types.js.map +1 -0
  74. package/common/types/comply-advantage.types.d.ts +48 -0
  75. package/common/types/comply-advantage.types.js +21 -0
  76. package/common/types/comply-advantage.types.js.map +1 -0
  77. package/common/types/contact-us.types.d.ts +126 -0
  78. package/common/types/contact-us.types.js +91 -0
  79. package/common/types/contact-us.types.js.map +1 -0
  80. package/common/types/countries.types.d.ts +77 -0
  81. package/common/types/countries.types.js +349 -0
  82. package/common/types/countries.types.js.map +1 -0
  83. package/common/types/covered-person.types.d.ts +204 -0
  84. package/common/types/covered-person.types.js +234 -0
  85. package/common/types/covered-person.types.js.map +1 -0
  86. package/common/types/csv.types.d.ts +3612 -0
  87. package/common/types/csv.types.js +290 -0
  88. package/common/types/csv.types.js.map +1 -0
  89. package/common/types/dashboard.types.d.ts +2086 -0
  90. package/common/types/dashboard.types.js +690 -0
  91. package/common/types/dashboard.types.js.map +1 -0
  92. package/common/types/data-record.types.d.ts +347 -0
  93. package/common/types/data-record.types.js +261 -0
  94. package/common/types/data-record.types.js.map +1 -0
  95. package/common/types/data-room.types.d.ts +1277 -0
  96. package/common/types/data-room.types.js +167 -0
  97. package/common/types/data-room.types.js.map +1 -0
  98. package/common/types/default-theme-config.types.d.ts +445 -0
  99. package/common/types/default-theme-config.types.js +63 -0
  100. package/common/types/default-theme-config.types.js.map +1 -0
  101. package/common/types/disbursement-adjustment.types.d.ts +21 -0
  102. package/common/types/disbursement-adjustment.types.js +25 -0
  103. package/common/types/disbursement-adjustment.types.js.map +1 -0
  104. package/common/types/disbursement-approval-user.types.d.ts +935 -0
  105. package/common/types/disbursement-approval-user.types.js +68 -0
  106. package/common/types/disbursement-approval-user.types.js.map +1 -0
  107. package/common/types/disbursement-review.types.d.ts +923 -0
  108. package/common/types/disbursement-review.types.js +76 -0
  109. package/common/types/disbursement-review.types.js.map +1 -0
  110. package/common/types/disbursement-transaction.types.d.ts +621 -0
  111. package/common/types/disbursement-transaction.types.js +51 -0
  112. package/common/types/disbursement-transaction.types.js.map +1 -0
  113. package/common/types/disbursements.types.d.ts +3496 -0
  114. package/common/types/disbursements.types.js +435 -0
  115. package/common/types/disbursements.types.js.map +1 -0
  116. package/common/types/domain-filter.types.d.ts +135 -0
  117. package/common/types/domain-filter.types.js +40 -0
  118. package/common/types/domain-filter.types.js.map +1 -0
  119. package/common/types/email-theme.types.d.ts +1359 -0
  120. package/common/types/email-theme.types.js +318 -0
  121. package/common/types/email-theme.types.js.map +1 -0
  122. package/common/types/entity.types.d.ts +21 -0
  123. package/common/types/entity.types.js +14 -0
  124. package/common/types/entity.types.js.map +1 -0
  125. package/common/types/error-responses.types.d.ts +144 -0
  126. package/common/types/error-responses.types.js +125 -0
  127. package/common/types/error-responses.types.js.map +1 -0
  128. package/common/types/escrow-account.types.d.ts +415 -0
  129. package/common/types/escrow-account.types.js +78 -0
  130. package/common/types/escrow-account.types.js.map +1 -0
  131. package/common/types/exchange-api-key.types.d.ts +1010 -0
  132. package/common/types/exchange-api-key.types.js +90 -0
  133. package/common/types/exchange-api-key.types.js.map +1 -0
  134. package/common/types/exchange-import.types.d.ts +23 -0
  135. package/common/types/exchange-import.types.js +23 -0
  136. package/common/types/exchange-import.types.js.map +1 -0
  137. package/common/types/exchange-provider.types.d.ts +1308 -0
  138. package/common/types/exchange-provider.types.js +268 -0
  139. package/common/types/exchange-provider.types.js.map +1 -0
  140. package/common/types/file.types.d.ts +428 -0
  141. package/common/types/file.types.js +392 -0
  142. package/common/types/file.types.js.map +1 -0
  143. package/common/types/health.types.d.ts +112 -0
  144. package/common/types/health.types.js +22 -0
  145. package/common/types/health.types.js.map +1 -0
  146. package/common/types/i-will-do-it-later.types.d.ts +51 -0
  147. package/common/types/i-will-do-it-later.types.js +30 -0
  148. package/common/types/i-will-do-it-later.types.js.map +1 -0
  149. package/common/types/{index.ts → index.d.ts} +7 -5
  150. package/common/types/index.js +54 -0
  151. package/common/types/index.js.map +1 -0
  152. package/common/types/individuals.types.d.ts +2101 -0
  153. package/common/types/individuals.types.js +500 -0
  154. package/common/types/individuals.types.js.map +1 -0
  155. package/common/types/investor-account.types.d.ts +2996 -0
  156. package/common/types/investor-account.types.js +929 -0
  157. package/common/types/investor-account.types.js.map +1 -0
  158. package/common/types/investorAccountIdSchema.type.js +1 -0
  159. package/common/types/investorAccountIdSchema.type.js.map +1 -0
  160. package/common/types/investors-offering.types.d.ts +399 -0
  161. package/common/types/investors-offering.types.js +50 -0
  162. package/common/types/investors-offering.types.js.map +1 -0
  163. package/common/types/invite.types.d.ts +644 -0
  164. package/common/types/invite.types.js +114 -0
  165. package/common/types/invite.types.js.map +1 -0
  166. package/common/types/issuer-bank-account.types.d.ts +113 -0
  167. package/common/types/issuer-bank-account.types.js +81 -0
  168. package/common/types/issuer-bank-account.types.js.map +1 -0
  169. package/common/types/issuer-offering.types.d.ts +2236 -0
  170. package/common/types/issuer-offering.types.js +605 -0
  171. package/common/types/issuer-offering.types.js.map +1 -0
  172. package/common/types/issuer-payment-method.types.d.ts +1100 -0
  173. package/common/types/issuer-payment-method.types.js +311 -0
  174. package/common/types/issuer-payment-method.types.js.map +1 -0
  175. package/common/types/issuer.types.d.ts +539 -0
  176. package/common/types/issuer.types.js +275 -0
  177. package/common/types/issuer.types.js.map +1 -0
  178. package/common/types/job-item.types.d.ts +230 -0
  179. package/common/types/job-item.types.js +89 -0
  180. package/common/types/job-item.types.js.map +1 -0
  181. package/common/types/jobs.types.d.ts +296 -0
  182. package/common/types/jobs.types.js +150 -0
  183. package/common/types/jobs.types.js.map +1 -0
  184. package/common/types/kyb.types.d.ts +167 -0
  185. package/common/types/kyb.types.js +45 -0
  186. package/common/types/kyb.types.js.map +1 -0
  187. package/common/types/kyc.types.d.ts +2197 -0
  188. package/common/types/kyc.types.js +301 -0
  189. package/common/types/kyc.types.js.map +1 -0
  190. package/common/types/legal-entity.types.d.ts +676 -0
  191. package/common/types/legal-entity.types.js +151 -0
  192. package/common/types/legal-entity.types.js.map +1 -0
  193. package/common/types/login-history.types.d.ts +160 -0
  194. package/common/types/login-history.types.js +39 -0
  195. package/common/types/login-history.types.js.map +1 -0
  196. package/common/types/mail-template.types.d.ts +595 -0
  197. package/common/types/mail-template.types.js +401 -0
  198. package/common/types/mail-template.types.js.map +1 -0
  199. package/common/types/north-cap-integration.types.d.ts +1303 -0
  200. package/common/types/north-cap-integration.types.js +145 -0
  201. package/common/types/north-cap-integration.types.js.map +1 -0
  202. package/common/types/note.types.d.ts +216 -0
  203. package/common/types/note.types.js +82 -0
  204. package/common/types/note.types.js.map +1 -0
  205. package/common/types/notification.types.d.ts +2690 -0
  206. package/common/types/notification.types.js +411 -0
  207. package/common/types/notification.types.js.map +1 -0
  208. package/common/types/notion-api.types.d.ts +3626 -0
  209. package/common/types/notion-api.types.js +271 -0
  210. package/common/types/notion-api.types.js.map +1 -0
  211. package/common/types/notion-database.types.d.ts +191 -0
  212. package/common/types/notion-database.types.js +95 -0
  213. package/common/types/notion-database.types.js.map +1 -0
  214. package/common/types/notion-page.types.d.ts +3482 -0
  215. package/common/types/notion-page.types.js +208 -0
  216. package/common/types/notion-page.types.js.map +1 -0
  217. package/common/types/offering-reports.types.d.ts +525 -0
  218. package/common/types/offering-reports.types.js +111 -0
  219. package/common/types/offering-reports.types.js.map +1 -0
  220. package/common/types/offering-submission.types.d.ts +785 -0
  221. package/common/types/offering-submission.types.js +291 -0
  222. package/common/types/offering-submission.types.js.map +1 -0
  223. package/common/types/offering.types.d.ts +2859 -0
  224. package/common/types/offering.types.js +832 -0
  225. package/common/types/offering.types.js.map +1 -0
  226. package/common/types/page-revision.types.d.ts +74 -0
  227. package/common/types/page-revision.types.js +68 -0
  228. package/common/types/page-revision.types.js.map +1 -0
  229. package/common/types/page.types.d.ts +540 -0
  230. package/common/types/page.types.js +361 -0
  231. package/common/types/page.types.js.map +1 -0
  232. package/common/types/password.type.d.ts +2 -0
  233. package/common/types/password.type.js +14 -0
  234. package/common/types/password.type.js.map +1 -0
  235. package/common/types/payment-methods.types.d.ts +1165 -0
  236. package/common/types/payment-methods.types.js +381 -0
  237. package/common/types/payment-methods.types.js.map +1 -0
  238. package/common/types/phone.type.d.ts +12 -0
  239. package/common/types/phone.type.js +29 -0
  240. package/common/types/phone.type.js.map +1 -0
  241. package/common/types/portfolio.types.d.ts +185 -0
  242. package/common/types/portfolio.types.js +36 -0
  243. package/common/types/portfolio.types.js.map +1 -0
  244. package/common/types/privacy-policy-and-tos.types.d.ts +2 -0
  245. package/common/types/{privacy-policy-and-tos.types.ts → privacy-policy-and-tos.types.js} +1 -1
  246. package/common/types/privacy-policy-and-tos.types.js.map +1 -0
  247. package/common/types/queue.types.d.ts +22 -0
  248. package/common/types/queue.types.js +73 -0
  249. package/common/types/queue.types.js.map +1 -0
  250. package/common/types/registered-reps.types.d.ts +6 -0
  251. package/common/types/registered-reps.types.js +21 -0
  252. package/common/types/registered-reps.types.js.map +1 -0
  253. package/common/types/rejection-reasons.types.d.ts +35 -0
  254. package/common/types/rejection-reasons.types.js +49 -0
  255. package/common/types/rejection-reasons.types.js.map +1 -0
  256. package/common/types/reports.types.d.ts +345 -0
  257. package/common/types/reports.types.js +69 -0
  258. package/common/types/reports.types.js.map +1 -0
  259. package/common/types/review.types.d.ts +419 -0
  260. package/common/types/review.types.js +101 -0
  261. package/common/types/review.types.js.map +1 -0
  262. package/common/types/role.types.d.ts +30 -0
  263. package/common/types/role.types.js +21 -0
  264. package/common/types/role.types.js.map +1 -0
  265. package/common/types/secondary-customer.types.d.ts +586 -0
  266. package/common/types/secondary-customer.types.js +39 -0
  267. package/common/types/secondary-customer.types.js.map +1 -0
  268. package/common/types/secondary-issuer.types.d.ts +283 -0
  269. package/common/types/secondary-issuer.types.js +37 -0
  270. package/common/types/secondary-issuer.types.js.map +1 -0
  271. package/common/types/secondary-order.types.d.ts +508 -0
  272. package/common/types/secondary-order.types.js +40 -0
  273. package/common/types/secondary-order.types.js.map +1 -0
  274. package/common/types/secondary-security.types.d.ts +175 -0
  275. package/common/types/secondary-security.types.js +45 -0
  276. package/common/types/secondary-security.types.js.map +1 -0
  277. package/common/types/secondary-trade.entity.d.ts +16 -0
  278. package/common/types/secondary-trade.entity.js +12 -0
  279. package/common/types/secondary-trade.entity.js.map +1 -0
  280. package/common/types/secondary-trade.types.d.ts +465 -0
  281. package/common/types/secondary-trade.types.js +61 -0
  282. package/common/types/secondary-trade.types.js.map +1 -0
  283. package/common/types/secure-request.types.d.ts +171 -0
  284. package/common/types/secure-request.types.js +51 -0
  285. package/common/types/secure-request.types.js.map +1 -0
  286. package/common/types/signer.types.d.ts +3406 -0
  287. package/common/types/signer.types.js +532 -0
  288. package/common/types/signer.types.js.map +1 -0
  289. package/common/types/site-link.types.d.ts +875 -0
  290. package/common/types/site-link.types.js +126 -0
  291. package/common/types/site-link.types.js.map +1 -0
  292. package/common/types/site-settings.types.d.ts +1673 -0
  293. package/common/types/site-settings.types.js +500 -0
  294. package/common/types/site-settings.types.js.map +1 -0
  295. package/common/types/site.types.d.ts +1481 -0
  296. package/common/types/site.types.js +213 -0
  297. package/common/types/site.types.js.map +1 -0
  298. package/common/types/sms.types.d.ts +40 -0
  299. package/common/types/sms.types.js +27 -0
  300. package/common/types/sms.types.js.map +1 -0
  301. package/common/types/state-machine.types.d.ts +591 -0
  302. package/common/types/state-machine.types.js +144 -0
  303. package/common/types/state-machine.types.js.map +1 -0
  304. package/common/types/states.types.d.ts +77 -0
  305. package/common/types/states.types.js +137 -0
  306. package/common/types/states.types.js.map +1 -0
  307. package/common/types/subdoc-preview.types.d.ts +379 -0
  308. package/common/types/subdoc-preview.types.js +24 -0
  309. package/common/types/subdoc-preview.types.js.map +1 -0
  310. package/common/types/task.types.d.ts +545 -0
  311. package/common/types/task.types.js +214 -0
  312. package/common/types/task.types.js.map +1 -0
  313. package/common/types/trade-adjustment.type.d.ts +40 -0
  314. package/common/types/trade-adjustment.type.js +26 -0
  315. package/common/types/trade-adjustment.type.js.map +1 -0
  316. package/common/types/trade-line-item.types.d.ts +353 -0
  317. package/common/types/trade-line-item.types.js +103 -0
  318. package/common/types/trade-line-item.types.js.map +1 -0
  319. package/common/types/trade.types.d.ts +2012 -0
  320. package/common/types/trade.types.js +800 -0
  321. package/common/types/trade.types.js.map +1 -0
  322. package/common/types/transaction.types.d.ts +476 -0
  323. package/common/types/transaction.types.js +199 -0
  324. package/common/types/transaction.types.js.map +1 -0
  325. package/common/types/trusted-contact.types.d.ts +440 -0
  326. package/common/types/trusted-contact.types.js +95 -0
  327. package/common/types/trusted-contact.types.js.map +1 -0
  328. package/common/types/typography.types.d.ts +52 -0
  329. package/common/types/typography.types.js +67 -0
  330. package/common/types/typography.types.js.map +1 -0
  331. package/common/types/user-manual.types.d.ts +287 -0
  332. package/common/types/user-manual.types.js +192 -0
  333. package/common/types/user-manual.types.js.map +1 -0
  334. package/common/types/user-setting.types.d.ts +273 -0
  335. package/common/types/user-setting.types.js +85 -0
  336. package/common/types/user-setting.types.js.map +1 -0
  337. package/common/types/user.types.d.ts +1977 -0
  338. package/common/types/user.types.js +225 -0
  339. package/common/types/user.types.js.map +1 -0
  340. package/common/types/webhook.types.d.ts +10829 -0
  341. package/common/types/webhook.types.js +658 -0
  342. package/common/types/webhook.types.js.map +1 -0
  343. package/common/types/zapier.types.d.ts +126 -0
  344. package/common/types/zapier.types.js +247 -0
  345. package/common/types/zapier.types.js.map +1 -0
  346. package/common/types/zip.type.d.ts +35 -0
  347. package/common/types/zip.type.js +28 -0
  348. package/common/types/zip.type.js.map +1 -0
  349. package/contracts/clients/accounts/index.d.ts +308 -0
  350. package/contracts/clients/accounts/index.js +43 -0
  351. package/contracts/clients/accounts/index.js.map +1 -0
  352. package/contracts/clients/aic/index.d.ts +280 -0
  353. package/contracts/clients/aic/index.js +47 -0
  354. package/contracts/clients/aic/index.js.map +1 -0
  355. package/contracts/clients/api-key-logs/index.d.ts +287 -0
  356. package/contracts/clients/api-key-logs/index.js +37 -0
  357. package/contracts/clients/api-key-logs/index.js.map +1 -0
  358. package/contracts/clients/api-keys/index.d.ts +374 -0
  359. package/contracts/clients/api-keys/index.js +59 -0
  360. package/contracts/clients/api-keys/index.js.map +1 -0
  361. package/contracts/clients/assets/index.d.ts +1050 -0
  362. package/contracts/clients/assets/index.js +80 -0
  363. package/contracts/clients/assets/index.js.map +1 -0
  364. package/contracts/clients/auth/index.d.ts +236 -0
  365. package/contracts/clients/auth/index.js +38 -0
  366. package/contracts/clients/auth/index.js.map +1 -0
  367. package/contracts/clients/cart/index.d.ts +229 -0
  368. package/contracts/clients/cart/index.js +63 -0
  369. package/contracts/clients/cart/index.js.map +1 -0
  370. package/contracts/clients/csv/index.d.ts +1800 -0
  371. package/contracts/clients/csv/index.js +96 -0
  372. package/contracts/clients/csv/index.js.map +1 -0
  373. package/contracts/clients/files/index.d.ts +552 -0
  374. package/contracts/clients/files/index.js +142 -0
  375. package/contracts/clients/files/index.js.map +1 -0
  376. package/contracts/clients/files-public/index.d.ts +552 -0
  377. package/contracts/clients/files-public/index.js +142 -0
  378. package/contracts/clients/files-public/index.js.map +1 -0
  379. package/contracts/clients/index.d.ts +15114 -0
  380. package/contracts/clients/index.js +58 -0
  381. package/contracts/clients/index.js.map +1 -0
  382. package/contracts/clients/individuals/index.d.ts +3199 -0
  383. package/contracts/clients/individuals/index.js +74 -0
  384. package/contracts/clients/individuals/index.js.map +1 -0
  385. package/contracts/clients/investor-accounts/index.d.ts +339 -0
  386. package/contracts/clients/investor-accounts/index.js +73 -0
  387. package/contracts/clients/investor-accounts/index.js.map +1 -0
  388. package/contracts/clients/issuer-payment-methods/index.d.ts +276 -0
  389. package/contracts/clients/issuer-payment-methods/index.js +24 -0
  390. package/contracts/clients/issuer-payment-methods/index.js.map +1 -0
  391. package/contracts/clients/issuers/index.d.ts +449 -0
  392. package/contracts/clients/issuers/index.js +75 -0
  393. package/contracts/clients/issuers/index.js.map +1 -0
  394. package/contracts/clients/kyc/index.d.ts +345 -0
  395. package/contracts/clients/kyc/index.js +49 -0
  396. package/contracts/clients/kyc/index.js.map +1 -0
  397. package/contracts/clients/legal-entities/index.d.ts +887 -0
  398. package/contracts/clients/legal-entities/index.js +74 -0
  399. package/contracts/clients/legal-entities/index.js.map +1 -0
  400. package/contracts/clients/offerings/index.d.ts +1068 -0
  401. package/contracts/clients/offerings/index.js +95 -0
  402. package/contracts/clients/offerings/index.js.map +1 -0
  403. package/contracts/clients/payment-methods/index.d.ts +456 -0
  404. package/contracts/clients/payment-methods/index.js +68 -0
  405. package/contracts/clients/payment-methods/index.js.map +1 -0
  406. package/contracts/clients/review/index.d.ts +85 -0
  407. package/contracts/clients/review/index.js +27 -0
  408. package/contracts/clients/review/index.js.map +1 -0
  409. package/contracts/clients/secure-requests/index.d.ts +100 -0
  410. package/contracts/clients/secure-requests/index.js +22 -0
  411. package/contracts/clients/secure-requests/index.js.map +1 -0
  412. package/contracts/clients/sites/index.d.ts +657 -0
  413. package/contracts/clients/sites/index.js +40 -0
  414. package/contracts/clients/sites/index.js.map +1 -0
  415. package/contracts/clients/trade-line-items/index.d.ts +216 -0
  416. package/contracts/clients/trade-line-items/index.js +47 -0
  417. package/contracts/clients/trade-line-items/index.js.map +1 -0
  418. package/contracts/clients/trades/index.d.ts +871 -0
  419. package/contracts/clients/trades/index.js +156 -0
  420. package/contracts/clients/trades/index.js.map +1 -0
  421. package/contracts/clients/transactions/index.d.ts +88 -0
  422. package/contracts/clients/transactions/index.js +25 -0
  423. package/contracts/clients/transactions/index.js.map +1 -0
  424. package/contracts/clients/webhooks/index.d.ts +506 -0
  425. package/contracts/clients/webhooks/index.js +118 -0
  426. package/contracts/clients/webhooks/index.js.map +1 -0
  427. package/package.json +27 -36
  428. package/common/helpers/index.ts +0 -59
  429. package/common/types/account-contact.types.ts +0 -98
  430. package/common/types/account-detail.types.ts +0 -27
  431. package/common/types/account-integration.types.ts +0 -143
  432. package/common/types/account-manager.types.ts +0 -124
  433. package/common/types/account.types.ts +0 -296
  434. package/common/types/activity.types.ts +0 -274
  435. package/common/types/address.types.ts +0 -41
  436. package/common/types/aic.types.ts +0 -246
  437. package/common/types/aml.types.ts +0 -18
  438. package/common/types/api-key-logs.types.ts +0 -66
  439. package/common/types/api-keys.types.ts +0 -69
  440. package/common/types/asset.types.ts +0 -338
  441. package/common/types/auth.types.ts +0 -370
  442. package/common/types/batch-jobs.types.ts +0 -151
  443. package/common/types/bonus-tier.types.ts +0 -147
  444. package/common/types/cart.types.ts +0 -21
  445. package/common/types/checklist-items.types.ts +0 -70
  446. package/common/types/checklist.types.ts +0 -97
  447. package/common/types/common.types.ts +0 -1520
  448. package/common/types/comply-advantage-api.types.ts +0 -316
  449. package/common/types/comply-advantage.types.ts +0 -25
  450. package/common/types/contact-us.types.ts +0 -107
  451. package/common/types/countries.types.ts +0 -375
  452. package/common/types/covered-person.types.ts +0 -274
  453. package/common/types/dashboard.types.ts +0 -799
  454. package/common/types/data-record.types.ts +0 -325
  455. package/common/types/data-room.types.ts +0 -242
  456. package/common/types/default-theme-config.types.ts +0 -87
  457. package/common/types/disbursement-adjustment.types.ts +0 -32
  458. package/common/types/disbursement-approval-user.types.ts +0 -100
  459. package/common/types/disbursement-review.types.ts +0 -110
  460. package/common/types/disbursement-transaction.types.ts +0 -72
  461. package/common/types/disbursements.types.ts +0 -426
  462. package/common/types/domain-filter.types.ts +0 -55
  463. package/common/types/email-theme.types.ts +0 -442
  464. package/common/types/entity.types.ts +0 -15
  465. package/common/types/error-responses.types.ts +0 -135
  466. package/common/types/escrow-account.types.ts +0 -104
  467. package/common/types/exchange-api-key.types.ts +0 -121
  468. package/common/types/exchange-import.types.ts +0 -36
  469. package/common/types/exchange-provider.types.ts +0 -329
  470. package/common/types/file.types.ts +0 -477
  471. package/common/types/health.types.ts +0 -29
  472. package/common/types/i-will-do-it-later.types.ts +0 -68
  473. package/common/types/individuals.types.ts +0 -541
  474. package/common/types/investor-account.types.ts +0 -1239
  475. package/common/types/investors-offering.types.ts +0 -65
  476. package/common/types/invite.types.ts +0 -133
  477. package/common/types/issuer-bank-account.types.ts +0 -107
  478. package/common/types/issuer-offering.types.ts +0 -395
  479. package/common/types/issuer-payment-method.types.ts +0 -382
  480. package/common/types/issuer.types.ts +0 -321
  481. package/common/types/job-item.types.ts +0 -119
  482. package/common/types/jobs.types.ts +0 -171
  483. package/common/types/kyb.types.ts +0 -53
  484. package/common/types/kyc.types.ts +0 -188
  485. package/common/types/legal-entity.types.ts +0 -185
  486. package/common/types/login-history.types.ts +0 -46
  487. package/common/types/mail-template.types.ts +0 -436
  488. package/common/types/north-cap-integration.types.ts +0 -190
  489. package/common/types/note.types.ts +0 -109
  490. package/common/types/notification.types.ts +0 -58
  491. package/common/types/notion-api.types.ts +0 -374
  492. package/common/types/notion-database.types.ts +0 -125
  493. package/common/types/notion-page.types.ts +0 -267
  494. package/common/types/offering-reports.types.ts +0 -153
  495. package/common/types/offering-submission.types.ts +0 -314
  496. package/common/types/offering.types.ts +0 -683
  497. package/common/types/page-revision.types.ts +0 -86
  498. package/common/types/page.types.ts +0 -436
  499. package/common/types/password.type.ts +0 -15
  500. package/common/types/payment-methods.types.ts +0 -298
  501. package/common/types/phone.type.ts +0 -27
  502. package/common/types/portfolio.types.ts +0 -50
  503. package/common/types/queue.types.ts +0 -112
  504. package/common/types/registered-reps.types.ts +0 -25
  505. package/common/types/rejection-reasons.types.ts +0 -56
  506. package/common/types/reminder-config.types.ts +0 -40
  507. package/common/types/review.types.ts +0 -133
  508. package/common/types/role.types.ts +0 -26
  509. package/common/types/secondary-customer.types.ts +0 -66
  510. package/common/types/secondary-issuer.types.ts +0 -50
  511. package/common/types/secondary-order.types.ts +0 -58
  512. package/common/types/secondary-security.types.ts +0 -60
  513. package/common/types/secondary-trade.entity.ts +0 -16
  514. package/common/types/secondary-trade.types.ts +0 -95
  515. package/common/types/secure-request.types.ts +0 -68
  516. package/common/types/signer.types.ts +0 -651
  517. package/common/types/site-link.types.ts +0 -166
  518. package/common/types/site-settings.types.ts +0 -726
  519. package/common/types/site.types.ts +0 -270
  520. package/common/types/sms.types.ts +0 -30
  521. package/common/types/state-machine.types.ts +0 -177
  522. package/common/types/states.types.ts +0 -163
  523. package/common/types/subdoc-preview.types.ts +0 -35
  524. package/common/types/task.types.ts +0 -258
  525. package/common/types/trade-adjustment.type.ts +0 -33
  526. package/common/types/trade-line-item.type.ts +0 -132
  527. package/common/types/trade.types.ts +0 -999
  528. package/common/types/transaction.types.ts +0 -209
  529. package/common/types/trusted-contact.types.ts +0 -122
  530. package/common/types/typography.types.ts +0 -75
  531. package/common/types/user-manual.types.ts +0 -290
  532. package/common/types/user-setting.types.ts +0 -133
  533. package/common/types/user.types.ts +0 -320
  534. package/common/types/webhook.types.ts +0 -588
  535. package/common/types/zip.type.ts +0 -36
  536. package/contracts/clients/accounts/index.ts +0 -61
  537. package/contracts/clients/aic/index.ts +0 -59
  538. package/contracts/clients/api-key-logs/index.ts +0 -53
  539. package/contracts/clients/api-keys/index.ts +0 -73
  540. package/contracts/clients/assets/index.ts +0 -102
  541. package/contracts/clients/auth/index.ts +0 -50
  542. package/contracts/clients/cart/index.ts +0 -80
  543. package/contracts/clients/files/index.ts +0 -166
  544. package/contracts/clients/files-public/index.ts +0 -166
  545. package/contracts/clients/index.ts +0 -54
  546. package/contracts/clients/individuals/index.ts +0 -93
  547. package/contracts/clients/investor-accounts/index.ts +0 -93
  548. package/contracts/clients/issuer-payment-methods/index.ts +0 -39
  549. package/contracts/clients/issuers/index.ts +0 -94
  550. package/contracts/clients/legal-entities/index.ts +0 -93
  551. package/contracts/clients/offerings/index.ts +0 -117
  552. package/contracts/clients/payment-methods/index.ts +0 -85
  553. package/contracts/clients/secure-requests/index.ts +0 -34
  554. package/contracts/clients/sites/index.ts +0 -56
  555. package/contracts/clients/trade-line-items/index.ts +0 -66
  556. package/contracts/clients/trades/index.ts +0 -186
  557. package/contracts/clients/transactions/index.ts +0 -37
  558. package/contracts/compliance/account-contacts/index.ts +0 -82
  559. package/contracts/compliance/account-managers/index.ts +0 -142
  560. package/contracts/compliance/accounts/index.ts +0 -187
  561. package/contracts/compliance/activities/index.ts +0 -55
  562. package/contracts/compliance/aic/index.ts +0 -60
  563. package/contracts/compliance/api-keys/index.ts +0 -91
  564. package/contracts/compliance/assets/index.ts +0 -122
  565. package/contracts/compliance/auth/index.ts +0 -134
  566. package/contracts/compliance/batch-jobs/index.ts +0 -62
  567. package/contracts/compliance/bonus-tiers/index.ts +0 -55
  568. package/contracts/compliance/checklist/index.ts +0 -87
  569. package/contracts/compliance/checklist-items/index.ts +0 -86
  570. package/contracts/compliance/covered-persons/index.ts +0 -97
  571. package/contracts/compliance/dashboard/index.ts +0 -111
  572. package/contracts/compliance/data-records/index.ts +0 -116
  573. package/contracts/compliance/data-rooms/index.ts +0 -113
  574. package/contracts/compliance/default-theme-configs/index.ts +0 -95
  575. package/contracts/compliance/disbursement/index.ts +0 -165
  576. package/contracts/compliance/disbursement-approval-users/index.ts +0 -84
  577. package/contracts/compliance/disbursement-transactions/index.ts +0 -37
  578. package/contracts/compliance/domain-filters/index.ts +0 -117
  579. package/contracts/compliance/email-themes/index.ts +0 -284
  580. package/contracts/compliance/escrow-accounts/index.ts +0 -85
  581. package/contracts/compliance/exchange-api-keys/index.ts +0 -129
  582. package/contracts/compliance/exchange-imports/index.ts +0 -137
  583. package/contracts/compliance/files/index.ts +0 -267
  584. package/contracts/compliance/files-public/index.ts +0 -188
  585. package/contracts/compliance/health/index.ts +0 -26
  586. package/contracts/compliance/index.ts +0 -147
  587. package/contracts/compliance/individuals/index.ts +0 -57
  588. package/contracts/compliance/investor-accounts/index.ts +0 -141
  589. package/contracts/compliance/invites/index.ts +0 -137
  590. package/contracts/compliance/issuer-bank-accounts/index.ts +0 -81
  591. package/contracts/compliance/issuer-payment-methods/index.ts +0 -81
  592. package/contracts/compliance/issuers/index.ts +0 -97
  593. package/contracts/compliance/job-items/index.ts +0 -58
  594. package/contracts/compliance/jobs/index.ts +0 -59
  595. package/contracts/compliance/kyb/index.ts +0 -54
  596. package/contracts/compliance/kyc/index.ts +0 -77
  597. package/contracts/compliance/legal-entities/index.ts +0 -57
  598. package/contracts/compliance/login-histories/index.ts +0 -37
  599. package/contracts/compliance/notes/index.ts +0 -69
  600. package/contracts/compliance/notion-databases/index.ts +0 -107
  601. package/contracts/compliance/notion-pages/index.ts +0 -105
  602. package/contracts/compliance/offering-reports/index.ts +0 -149
  603. package/contracts/compliance/offerings/index.ts +0 -233
  604. package/contracts/compliance/pages/index.ts +0 -178
  605. package/contracts/compliance/payment-methods/index.ts +0 -57
  606. package/contracts/compliance/rejection-reasons/index.ts +0 -32
  607. package/contracts/compliance/review/index.ts +0 -169
  608. package/contracts/compliance/roles/index.ts +0 -34
  609. package/contracts/compliance/secondary-customers/index.ts +0 -77
  610. package/contracts/compliance/secondary-orders/index.ts +0 -60
  611. package/contracts/compliance/secondary-trades/index.ts +0 -100
  612. package/contracts/compliance/secure-requests/index.ts +0 -54
  613. package/contracts/compliance/signer/index.ts +0 -369
  614. package/contracts/compliance/site-links/index.ts +0 -128
  615. package/contracts/compliance/site-settings/index.ts +0 -669
  616. package/contracts/compliance/sites/index.ts +0 -56
  617. package/contracts/compliance/state-machine/index.ts +0 -94
  618. package/contracts/compliance/tasks/index.ts +0 -91
  619. package/contracts/compliance/third-parties/index.ts +0 -52
  620. package/contracts/compliance/trade-line-items/index.ts +0 -59
  621. package/contracts/compliance/trades/index.ts +0 -230
  622. package/contracts/compliance/transactions/index.ts +0 -161
  623. package/contracts/compliance/user-manuals/index.ts +0 -271
  624. package/contracts/compliance/user-settings/index.ts +0 -189
  625. package/contracts/compliance/users/index.ts +0 -200
  626. package/contracts/compliance/webhooks/index.ts +0 -41
  627. package/contracts/compliance-apikey/accounts/index.ts +0 -58
  628. package/contracts/compliance-apikey/index.ts +0 -14
  629. package/contracts/index.ts +0 -6
  630. package/contracts/investors/account-contacts/index.ts +0 -58
  631. package/contracts/investors/aic/index.ts +0 -59
  632. package/contracts/investors/assets/index.ts +0 -61
  633. package/contracts/investors/auth/index.ts +0 -116
  634. package/contracts/investors/bonus-tiers/index.ts +0 -37
  635. package/contracts/investors/cart/index.ts +0 -75
  636. package/contracts/investors/contact-us/index.ts +0 -48
  637. package/contracts/investors/data-records/index.ts +0 -113
  638. package/contracts/investors/data-rooms/index.ts +0 -96
  639. package/contracts/investors/files/index.ts +0 -167
  640. package/contracts/investors/files-public/index.ts +0 -185
  641. package/contracts/investors/index.ts +0 -72
  642. package/contracts/investors/individuals/index.ts +0 -121
  643. package/contracts/investors/investor-accounts/index.ts +0 -110
  644. package/contracts/investors/issuer-payment-methods/index.ts +0 -36
  645. package/contracts/investors/issuers/index.ts +0 -30
  646. package/contracts/investors/legal-entities/index.ts +0 -93
  647. package/contracts/investors/notes/index.ts +0 -69
  648. package/contracts/investors/offerings/index.ts +0 -93
  649. package/contracts/investors/pages/index.ts +0 -88
  650. package/contracts/investors/payment-methods/index.ts +0 -149
  651. package/contracts/investors/portfolios/index.ts +0 -53
  652. package/contracts/investors/sites/index.ts +0 -96
  653. package/contracts/investors/tasks/index.ts +0 -111
  654. package/contracts/investors/trade-line-items/index.ts +0 -75
  655. package/contracts/investors/trades/index.ts +0 -114
  656. package/contracts/investors/transactions/index.ts +0 -37
  657. package/contracts/investors/trusted-contacts/index.ts +0 -93
  658. package/contracts/investors/user-manuals/index.ts +0 -62
  659. package/contracts/investors/user-settings/index.ts +0 -170
  660. package/contracts/investors/users/index.ts +0 -45
  661. package/contracts/investors/webhooks/index.ts +0 -30
  662. package/contracts/issuers/account-contacts/index.ts +0 -76
  663. package/contracts/issuers/account-integrations/index.ts +0 -97
  664. package/contracts/issuers/accounts/index.ts +0 -97
  665. package/contracts/issuers/activities/index.ts +0 -54
  666. package/contracts/issuers/aic/index.ts +0 -39
  667. package/contracts/issuers/api-key-logs/index.ts +0 -53
  668. package/contracts/issuers/api-keys/index.ts +0 -93
  669. package/contracts/issuers/assets/index.ts +0 -122
  670. package/contracts/issuers/auth/index.ts +0 -152
  671. package/contracts/issuers/bonus-tiers/index.ts +0 -55
  672. package/contracts/issuers/contact-us/index.ts +0 -48
  673. package/contracts/issuers/covered-persons/index.ts +0 -136
  674. package/contracts/issuers/dashboard/index.ts +0 -72
  675. package/contracts/issuers/data-records/index.ts +0 -257
  676. package/contracts/issuers/data-rooms/index.ts +0 -134
  677. package/contracts/issuers/disbursement-approval-users/index.ts +0 -82
  678. package/contracts/issuers/disbursement-transactions/index.ts +0 -53
  679. package/contracts/issuers/disbursements/index.ts +0 -189
  680. package/contracts/issuers/email-themes/index.ts +0 -242
  681. package/contracts/issuers/escrow-accounts/index.ts +0 -81
  682. package/contracts/issuers/exchange-api-keys/index.ts +0 -144
  683. package/contracts/issuers/files/index.ts +0 -166
  684. package/contracts/issuers/files-public/index.ts +0 -166
  685. package/contracts/issuers/health/index.ts +0 -24
  686. package/contracts/issuers/index.ts +0 -112
  687. package/contracts/issuers/investor-accounts/index.ts +0 -148
  688. package/contracts/issuers/invites/index.ts +0 -129
  689. package/contracts/issuers/issuer/index.ts +0 -94
  690. package/contracts/issuers/issuer-bank-accounts/index.ts +0 -81
  691. package/contracts/issuers/issuer-payment-methods/index.ts +0 -136
  692. package/contracts/issuers/kyc/index.ts +0 -38
  693. package/contracts/issuers/login-histories/index.ts +0 -51
  694. package/contracts/issuers/notes/index.ts +0 -69
  695. package/contracts/issuers/offerings/index.ts +0 -206
  696. package/contracts/issuers/pages/index.ts +0 -138
  697. package/contracts/issuers/payment-methods/index.ts +0 -61
  698. package/contracts/issuers/portfolios/index.ts +0 -36
  699. package/contracts/issuers/rejection-reasons/index.ts +0 -32
  700. package/contracts/issuers/review/index.ts +0 -63
  701. package/contracts/issuers/secondary-customers/index.ts +0 -55
  702. package/contracts/issuers/secondary-orders/index.ts +0 -57
  703. package/contracts/issuers/secondary-trades/index.ts +0 -57
  704. package/contracts/issuers/secure-requests/index.ts +0 -34
  705. package/contracts/issuers/site-links/index.ts +0 -116
  706. package/contracts/issuers/site-settings/index.ts +0 -585
  707. package/contracts/issuers/sites/index.ts +0 -32
  708. package/contracts/issuers/tasks/index.ts +0 -111
  709. package/contracts/issuers/trades/index.ts +0 -132
  710. package/contracts/issuers/transactions/index.ts +0 -158
  711. package/contracts/issuers/user-manuals/index.ts +0 -62
  712. package/contracts/issuers/user-settings/index.ts +0 -170
  713. package/contracts/issuers/users/index.ts +0 -126
  714. package/contracts/secondaries/accounts/index.ts +0 -58
  715. package/contracts/secondaries/index.ts +0 -23
  716. package/contracts/secondaries/secondary-customers/index.ts +0 -55
  717. package/contracts/secondaries/secondary-issuers/index.ts +0 -94
  718. package/contracts/secondaries/secondary-orders/index.ts +0 -56
  719. package/contracts/secondaries/secondary-securities/index.ts +0 -95
  720. package/contracts/secondaries/secondary-trades/index.ts +0 -56
  721. /package/common/types/{investorAccountIdSchema.type.ts → investorAccountIdSchema.type.d.ts} +0 -0
@@ -1,374 +0,0 @@
1
- import { z } from 'zod';
2
- import { extendZodWithOpenApi } from '@anatine/zod-openapi';
3
- import { NotionDatabaseZod } from './notion-database.types';
4
- import { LogContextZod } from './common.types';
5
-
6
- extendZodWithOpenApi(z);
7
-
8
- // Notion API Types - Based on official Notion API specification
9
- // https://developers.notion.com/reference/post-database-query
10
-
11
- export const NotionTextFilterZod = z.object({
12
- equals: z.string().optional(),
13
- does_not_equal: z.string().optional(),
14
- contains: z.string().optional(),
15
- does_not_contain: z.string().optional(),
16
- starts_with: z.string().optional(),
17
- ends_with: z.string().optional(),
18
- is_empty: z.boolean().optional(),
19
- is_not_empty: z.boolean().optional(),
20
- });
21
-
22
- export const NotionNumberFilterZod = z.object({
23
- equals: z.number().optional(),
24
- does_not_equal: z.number().optional(),
25
- greater_than: z.number().optional(),
26
- less_than: z.number().optional(),
27
- greater_than_or_equal_to: z.number().optional(),
28
- less_than_or_equal_to: z.number().optional(),
29
- is_empty: z.boolean().optional(),
30
- is_not_empty: z.boolean().optional(),
31
- });
32
-
33
- export const NotionSelectFilterZod = z.object({
34
- equals: z.string().optional(),
35
- does_not_equal: z.string().optional(),
36
- is_empty: z.boolean().optional(),
37
- is_not_empty: z.boolean().optional(),
38
- });
39
-
40
- export const NotionDateFilterZod = z.object({
41
- equals: z.string().optional(),
42
- before: z.string().optional(),
43
- after: z.string().optional(),
44
- on_or_before: z.string().optional(),
45
- on_or_after: z.string().optional(),
46
- is_empty: z.boolean().optional(),
47
- is_not_empty: z.boolean().optional(),
48
- past_week: z.object({}).optional(),
49
- past_month: z.object({}).optional(),
50
- past_year: z.object({}).optional(),
51
- next_week: z.object({}).optional(),
52
- next_month: z.object({}).optional(),
53
- next_year: z.object({}).optional(),
54
- });
55
-
56
- export const NotionCheckboxFilterZod = z.object({
57
- equals: z.boolean().optional(),
58
- does_not_equal: z.boolean().optional(),
59
- });
60
-
61
- export const NotionFilesFilterZod = z.object({
62
- is_empty: z.boolean().optional(),
63
- is_not_empty: z.boolean().optional(),
64
- });
65
-
66
- export const NotionRelationFilterZod = z.object({
67
- contains: z.string().optional(),
68
- does_not_contain: z.string().optional(),
69
- is_empty: z.boolean().optional(),
70
- is_not_empty: z.boolean().optional(),
71
- });
72
-
73
- export const NotionPeopleFilterZod = z.object({
74
- contains: z.string().optional(),
75
- does_not_contain: z.string().optional(),
76
- is_empty: z.boolean().optional(),
77
- is_not_empty: z.boolean().optional(),
78
- });
79
-
80
- export const NotionCreatedByUserFilterZod = z.object({
81
- contains: z.string().optional(),
82
- does_not_contain: z.string().optional(),
83
- is_empty: z.boolean().optional(),
84
- is_not_empty: z.boolean().optional(),
85
- });
86
-
87
- export const NotionLastEditedByUserFilterZod = z.object({
88
- contains: z.string().optional(),
89
- does_not_contain: z.string().optional(),
90
- is_empty: z.boolean().optional(),
91
- is_not_empty: z.boolean().optional(),
92
- });
93
-
94
- // Property Filter - must have property name and exactly one filter type
95
- export const NotionPropertyFilterZod = z
96
- .object({
97
- property: z.string(),
98
- })
99
- .and(
100
- z.union([
101
- z.object({ text: NotionTextFilterZod }),
102
- z.object({ number: NotionNumberFilterZod }),
103
- z.object({ select: NotionSelectFilterZod }),
104
- z.object({ date: NotionDateFilterZod }),
105
- z.object({ checkbox: NotionCheckboxFilterZod }),
106
- z.object({ url: NotionTextFilterZod }),
107
- z.object({ email: NotionTextFilterZod }),
108
- z.object({ phone_number: NotionTextFilterZod }),
109
- z.object({ files: NotionFilesFilterZod }),
110
- z.object({ relation: NotionRelationFilterZod }),
111
- z.object({ people: NotionPeopleFilterZod }),
112
- ]),
113
- );
114
-
115
- // Timestamp Filters
116
- export const NotionCreatedTimeFilterZod = z.object({
117
- created_time: NotionDateFilterZod,
118
- });
119
-
120
- export const NotionLastEditedTimeFilterZod = z.object({
121
- last_edited_time: NotionDateFilterZod,
122
- });
123
-
124
- export const NotionCreatedByFilterZod = z.object({
125
- created_by: NotionCreatedByUserFilterZod,
126
- });
127
-
128
- export const NotionLastEditedByFilterZod = z.object({
129
- last_edited_by: NotionLastEditedByUserFilterZod,
130
- });
131
-
132
- // Compound Filters
133
- export const NotionCompoundFilterZod = z.object({
134
- and: z.array(z.lazy(() => NotionFilterZod)).optional(),
135
- or: z.array(z.lazy(() => NotionFilterZod)).optional(),
136
- not: z.lazy(() => NotionFilterZod).optional(),
137
- });
138
-
139
- // Main Filter Union
140
- export const NotionFilterZod = z.union([
141
- NotionPropertyFilterZod,
142
- NotionCreatedTimeFilterZod,
143
- NotionLastEditedTimeFilterZod,
144
- NotionCreatedByFilterZod,
145
- NotionLastEditedByFilterZod,
146
- NotionCompoundFilterZod,
147
- ]);
148
-
149
- // Sort Types
150
- export const NotionPropertySortZod = z.object({
151
- property: z.string(),
152
- direction: z.enum(['ascending', 'descending']),
153
- });
154
-
155
- export const NotionTimestampSortZod = z.object({
156
- timestamp: z.enum(['created_time', 'last_edited_time']),
157
- direction: z.enum(['ascending', 'descending']),
158
- });
159
-
160
- export const NotionSortZod = z.union([
161
- NotionPropertySortZod,
162
- NotionTimestampSortZod,
163
- ]);
164
-
165
- // Database Query Options
166
- export const NotionDatabaseQueryOptionsZod = z.object({
167
- page_size: z.number().min(1).max(100).optional(),
168
- start_cursor: z.string().optional(),
169
- filter: NotionFilterZod.optional(),
170
- sorts: z.array(NotionSortZod).optional(),
171
- });
172
-
173
- // Response Types
174
- export const NotionPageObjectZod = z.object({
175
- object: z.literal('page'),
176
- id: z.string(),
177
- created_time: z.string(),
178
- last_edited_time: z.string(),
179
- created_by: z
180
- .object({
181
- object: z.literal('user'),
182
- id: z.string(),
183
- })
184
- .optional(),
185
- last_edited_by: z
186
- .object({
187
- object: z.literal('user'),
188
- id: z.string(),
189
- })
190
- .optional(),
191
- properties: z.lazy(() => NotionPagePropertiesZod),
192
- parent: z.object({
193
- type: z.literal('database_id'),
194
- database_id: z.string(),
195
- }),
196
- url: z.string(),
197
- public_url: z.string().nullable(),
198
- archived: z.boolean(),
199
- });
200
-
201
- export const NotionDatabaseQueryResponseZod = z.object({
202
- object: z.literal('list'),
203
- results: z.array(NotionPageObjectZod),
204
- next_cursor: z.string().nullable(),
205
- has_more: z.boolean(),
206
- type: z.literal('page_or_database'),
207
- page_or_database: z.record(z.any()),
208
- });
209
-
210
- export type NotionTextFilter = z.infer<typeof NotionTextFilterZod>;
211
- export type NotionNumberFilter = z.infer<typeof NotionNumberFilterZod>;
212
- export type NotionSelectFilter = z.infer<typeof NotionSelectFilterZod>;
213
- export type NotionDateFilter = z.infer<typeof NotionDateFilterZod>;
214
- export type NotionCheckboxFilter = z.infer<typeof NotionCheckboxFilterZod>;
215
- export type NotionFilesFilter = z.infer<typeof NotionFilesFilterZod>;
216
- export type NotionRelationFilter = z.infer<typeof NotionRelationFilterZod>;
217
- export type NotionPeopleFilter = z.infer<typeof NotionPeopleFilterZod>;
218
- export type NotionCreatedByUserFilter = z.infer<
219
- typeof NotionCreatedByUserFilterZod
220
- >;
221
- export type NotionLastEditedByUserFilter = z.infer<
222
- typeof NotionLastEditedByUserFilterZod
223
- >;
224
- export type NotionCreatedByFilter = z.infer<typeof NotionCreatedByFilterZod>;
225
- export type NotionLastEditedByFilter = z.infer<
226
- typeof NotionLastEditedByFilterZod
227
- >;
228
- export type NotionPropertyFilter = z.infer<typeof NotionPropertyFilterZod>;
229
- export type NotionCreatedTimeFilter = z.infer<
230
- typeof NotionCreatedTimeFilterZod
231
- >;
232
- export type NotionLastEditedTimeFilter = z.infer<
233
- typeof NotionLastEditedTimeFilterZod
234
- >;
235
- export type NotionCompoundFilter = z.infer<typeof NotionCompoundFilterZod>;
236
- export type NotionFilter = z.infer<typeof NotionFilterZod>;
237
- export type NotionPropertySort = z.infer<typeof NotionPropertySortZod>;
238
- export type NotionTimestampSort = z.infer<typeof NotionTimestampSortZod>;
239
- export type NotionSort = z.infer<typeof NotionSortZod>;
240
- export type NotionDatabaseQueryOptions = z.infer<
241
- typeof NotionDatabaseQueryOptionsZod
242
- >;
243
- export type NotionPageObject = z.infer<typeof NotionPageObjectZod>;
244
- export type NotionDatabaseQueryResponse = z.infer<
245
- typeof NotionDatabaseQueryResponseZod
246
- >;
247
-
248
- // Notion Page Property Types
249
- export const NotionRichTextItemZod = z.object({
250
- type: z.literal('text'),
251
- text: z.object({
252
- content: z.string(),
253
- link: z.object({ url: z.string() }).nullable(),
254
- }),
255
- annotations: z.object({
256
- bold: z.boolean(),
257
- italic: z.boolean(),
258
- strikethrough: z.boolean(),
259
- underline: z.boolean(),
260
- code: z.boolean(),
261
- color: z.string(),
262
- }),
263
- plain_text: z.string(),
264
- href: z.string().nullable(),
265
- });
266
-
267
- export const NotionTitlePropertyValueZod = z.object({
268
- id: z.string(),
269
- type: z.literal('title'),
270
- title: z.array(NotionRichTextItemZod),
271
- });
272
-
273
- export const NotionRichTextPropertyValueZod = z.object({
274
- id: z.string(),
275
- type: z.literal('rich_text'),
276
- rich_text: z.array(NotionRichTextItemZod),
277
- });
278
-
279
- export const NotionSelectPropertyValueZod = z.object({
280
- id: z.string(),
281
- type: z.literal('select'),
282
- select: z
283
- .object({
284
- id: z.string(),
285
- name: z.string(),
286
- color: z.string(),
287
- })
288
- .nullable(),
289
- });
290
-
291
- export const NotionNumberPropertyValueZod = z.object({
292
- id: z.string(),
293
- type: z.literal('number'),
294
- number: z.number().nullable(),
295
- });
296
-
297
- export const NotionCheckboxPropertyValueZod = z.object({
298
- id: z.string(),
299
- type: z.literal('checkbox'),
300
- checkbox: z.boolean(),
301
- });
302
-
303
- export const NotionDatePropertyValueZod = z.object({
304
- id: z.string(),
305
- type: z.literal('date'),
306
- date: z
307
- .object({
308
- start: z.string(),
309
- end: z.string().nullable(),
310
- time_zone: z.string().nullable(),
311
- })
312
- .nullable(),
313
- });
314
-
315
- export const NotionPropertyValueZod = z.union([
316
- NotionTitlePropertyValueZod,
317
- NotionRichTextPropertyValueZod,
318
- NotionSelectPropertyValueZod,
319
- NotionNumberPropertyValueZod,
320
- NotionCheckboxPropertyValueZod,
321
- NotionDatePropertyValueZod,
322
- z.object({ type: z.string() }).passthrough(),
323
- ]);
324
-
325
- export const NotionPagePropertiesZod = z.record(NotionPropertyValueZod);
326
-
327
- // Sync Log Type
328
- export const NotionSyncLogZod = z.object({
329
- success: z.boolean(),
330
- pagesCount: z.number().optional(),
331
- savedPages: z.number().optional(),
332
- timestamp: z.string(),
333
- error: z.string().optional(),
334
- rawApiResponses: z.array(z.any()).optional(),
335
- });
336
-
337
- // Log Context Type
338
- export const NotionLogContextZod = LogContextZod.extend({
339
- notionDatabaseId: z.string(),
340
- });
341
-
342
- // Page Processing Result Type
343
- export const NotionPageProcessingResultZod = z.object({
344
- notionDatabase: NotionDatabaseZod.nullable(),
345
- pagesCount: z.number(),
346
- savedPages: z.number(),
347
- });
348
-
349
- export type NotionRichTextItem = z.infer<typeof NotionRichTextItemZod>;
350
- export type NotionTitlePropertyValue = z.infer<
351
- typeof NotionTitlePropertyValueZod
352
- >;
353
- export type NotionRichTextPropertyValue = z.infer<
354
- typeof NotionRichTextPropertyValueZod
355
- >;
356
- export type NotionSelectPropertyValue = z.infer<
357
- typeof NotionSelectPropertyValueZod
358
- >;
359
- export type NotionNumberPropertyValue = z.infer<
360
- typeof NotionNumberPropertyValueZod
361
- >;
362
- export type NotionCheckboxPropertyValue = z.infer<
363
- typeof NotionCheckboxPropertyValueZod
364
- >;
365
- export type NotionDatePropertyValue = z.infer<
366
- typeof NotionDatePropertyValueZod
367
- >;
368
- export type NotionPropertyValue = z.infer<typeof NotionPropertyValueZod>;
369
- export type NotionPageProperties = z.infer<typeof NotionPagePropertiesZod>;
370
- export type NotionSyncLog = z.infer<typeof NotionSyncLogZod>;
371
- export type NotionLogContext = z.infer<typeof NotionLogContextZod>;
372
- export type NotionPageProcessingResult = z.infer<
373
- typeof NotionPageProcessingResultZod
374
- >;
@@ -1,125 +0,0 @@
1
- import { z } from 'zod';
2
- import { TypeID } from 'typeid-js';
3
- import { extendZodWithOpenApi } from '@anatine/zod-openapi';
4
- import { IBaseEntity } from './entity.types';
5
- import { IPaginationMeta } from './common.types';
6
-
7
- extendZodWithOpenApi(z);
8
-
9
- export const notionDatabaseIdSchema = z.string().refine(
10
- (value) => {
11
- try {
12
- const tid = TypeID.fromString(value);
13
- return tid.getType() === 'notion_database';
14
- } catch {
15
- return false;
16
- }
17
- },
18
- {
19
- message:
20
- 'Invalid notion_database ID format. Must be a valid TypeID with "notion_database" prefix. Example: notion_database_01j5y5ghx5fg68d663j1fvy2x7',
21
- },
22
- );
23
-
24
- export const NotionDatabaseZod = IBaseEntity.extend({
25
- name: z
26
- .string({ message: 'Name field is required.' })
27
- .min(2, { message: 'Name must have at least 2 characters.' })
28
- .max(50, { message: 'Name cannot exceed 50 characters.' })
29
- .openapi({ example: 'Database name' }),
30
- tid: z
31
- .string({ message: 'TID field is required.' })
32
- .min(2, { message: 'TID must have at least 2 characters.' })
33
- .max(50, { message: 'TID cannot exceed 50 characters.' })
34
- .openapi({ example: 'database_tid' }),
35
- sync: z
36
- .boolean({ message: 'Sync field is required.' })
37
- .openapi({ example: true }),
38
- display: z
39
- .boolean({ message: 'Display field is required.' })
40
- .openapi({ example: true }),
41
- syncLog: z.string().nullable().openapi({ example: null }),
42
- });
43
-
44
- export const PostNotionDatabaseSchema = z.object({
45
- name: z
46
- .string({ message: 'Name field is required.' })
47
- .min(2, { message: 'Name must have at least 2 characters.' })
48
- .max(50, { message: 'Name cannot exceed 50 characters.' })
49
- .openapi({ example: 'Database name' }),
50
- tid: z
51
- .string({ message: 'TID field is required.' })
52
- .min(2, { message: 'TID must have at least 2 characters.' })
53
- .max(50, { message: 'TID cannot exceed 50 characters.' })
54
- .openapi({ example: 'database_tid' }),
55
- sync: z
56
- .boolean({ message: 'Sync field must be a boolean.' })
57
- .optional()
58
- .openapi({ example: true }),
59
- display: z
60
- .boolean({ message: 'Display field must be a boolean.' })
61
- .optional()
62
- .openapi({ example: true }),
63
- });
64
-
65
- export const UpdateNotionDatabaseSchema = z.object({
66
- name: z.string().optional().openapi({ example: 'Database name' }),
67
- tid: z.string().optional().openapi({ example: 'database_tid' }),
68
- sync: z.boolean().optional().openapi({ example: true }),
69
- display: z.boolean().optional().openapi({ example: true }),
70
- });
71
-
72
- export const TriggerNotionDatabaseSync = z.object({}).openapi({
73
- description: 'Empty body - no additional data required for sync trigger',
74
- example: {},
75
- });
76
-
77
- export const NotionDatabaseFiltersZod = z.object({
78
- search: z
79
- .string({ message: 'Search field must be a string.' })
80
- .max(50, { message: 'Search cannot exceed 50 characters.' })
81
- .optional()
82
- .openapi({ example: 'search term' }),
83
- });
84
-
85
- export const IPaginatedNotionDatabases = z.object({
86
- items: z.array(NotionDatabaseZod),
87
- meta: IPaginationMeta,
88
- });
89
-
90
- const notionDatabaseInclude = z.enum(['notionPages']);
91
-
92
- /**
93
- * @description Query parameters for including related entities
94
- * @example in contract use as -> query: z.object({}).merge(NotionDatabaseIncludeQuery),
95
- */
96
- export const NotionDatabaseIncludeQuery = z.object({
97
- include: z
98
- .string()
99
- .optional()
100
- .transform((str) => (str ? str.split(',') : []))
101
- .refine(
102
- (includes) =>
103
- includes.every((include) =>
104
- notionDatabaseInclude.options.includes(include as any),
105
- ),
106
- {
107
- message: `Invalid include option provided. Valid options are: ${notionDatabaseInclude.options.join(',')}`,
108
- },
109
- )
110
- .openapi({
111
- example: `${notionDatabaseInclude.options.join(',')}`,
112
- }),
113
- });
114
-
115
- export type INotionDatabase = z.infer<typeof NotionDatabaseZod>;
116
- export type PostNotionDatabase = z.infer<typeof PostNotionDatabaseSchema>;
117
- export type UpdateNotionDatabase = z.infer<typeof UpdateNotionDatabaseSchema>;
118
- export type TriggerNotionDatabaseSync = z.infer<
119
- typeof TriggerNotionDatabaseSync
120
- >;
121
- export type IPaginatedNotionDatabase = z.infer<
122
- typeof IPaginatedNotionDatabases
123
- >;
124
- export interface NotionDatabaseIncludeQuery
125
- extends z.infer<typeof NotionDatabaseIncludeQuery> {}