@getcommunity/gc-validators 0.0.270 → 0.0.271-alpha.1

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 (334) hide show
  1. package/README.md +16 -38
  2. package/dist/base/index.cjs +106 -0
  3. package/dist/base/index.d.cts +5 -0
  4. package/dist/base/index.d.mts +5 -0
  5. package/dist/base/index.mjs +21 -0
  6. package/dist/component-BPHZTfVY.mjs +6 -0
  7. package/dist/component-DLjTD_qK.cjs +19 -0
  8. package/dist/components/blocks/index.cjs +207 -0
  9. package/dist/components/blocks/index.d.cts +1322 -0
  10. package/dist/components/blocks/index.d.mts +1322 -0
  11. package/dist/components/blocks/index.mjs +175 -0
  12. package/dist/components/brand/index.cjs +37 -0
  13. package/dist/components/brand/index.d.cts +315 -0
  14. package/dist/components/brand/index.d.mts +315 -0
  15. package/dist/components/brand/index.mjs +31 -0
  16. package/dist/components/forms/index.cjs +70 -0
  17. package/dist/components/forms/index.d.cts +333 -0
  18. package/dist/components/forms/index.d.mts +333 -0
  19. package/dist/components/forms/index.mjs +58 -0
  20. package/dist/components/shared/index.cjs +127 -0
  21. package/dist/components/shared/index.d.cts +917 -0
  22. package/dist/components/shared/index.d.mts +917 -0
  23. package/dist/components/shared/index.mjs +107 -0
  24. package/dist/components/slideshow/index.cjs +129 -0
  25. package/dist/components/slideshow/index.d.cts +742 -0
  26. package/dist/components/slideshow/index.d.mts +742 -0
  27. package/dist/components/slideshow/index.mjs +106 -0
  28. package/dist/components/utm/index.cjs +55 -0
  29. package/dist/components/utm/index.d.cts +32 -0
  30. package/dist/components/utm/index.d.mts +32 -0
  31. package/dist/components/utm/index.mjs +47 -0
  32. package/dist/constants/index.cjs +243 -0
  33. package/dist/constants/index.d.cts +197 -0
  34. package/dist/constants/index.d.mts +197 -0
  35. package/dist/constants/index.mjs +182 -0
  36. package/dist/constants-L2goO7Eg.mjs +85 -0
  37. package/dist/constants-PBZKggHL.cjs +102 -0
  38. package/dist/document-BAro2Mrj.cjs +18 -0
  39. package/dist/document-BAzLIprH.d.mts +100 -0
  40. package/dist/document-BFukanLe.mjs +54 -0
  41. package/dist/document-BK1ASowb.d.cts +17 -0
  42. package/dist/document-BMxLOdrT.d.cts +267 -0
  43. package/dist/document-BNoXPGwF.d.mts +27 -0
  44. package/dist/document-B_pJW777.d.mts +30 -0
  45. package/dist/document-Bd2AyLs8.d.mts +16 -0
  46. package/dist/document-BezYxNmb.d.cts +16 -0
  47. package/dist/document-Bj7SRTOn.d.cts +18 -0
  48. package/dist/document-Bo869pZx.d.mts +18 -0
  49. package/dist/document-Bpr9mbCs.d.mts +15 -0
  50. package/dist/document-Bqoi1MdT.mjs +11 -0
  51. package/dist/document-Bs8c1mok.d.cts +15 -0
  52. package/dist/document-C0c7azOe.d.mts +434 -0
  53. package/dist/document-CTTDXzOF.mjs +13 -0
  54. package/dist/document-CUl_Ys6-.mjs +23 -0
  55. package/dist/document-CWYzG60q.d.cts +19 -0
  56. package/dist/document-Ccszj8lR.cjs +20 -0
  57. package/dist/document-CjNHI7Eb.d.cts +27 -0
  58. package/dist/document-Cu_HUDC5.mjs +51 -0
  59. package/dist/document-D-KvyEb5.d.cts +238 -0
  60. package/dist/document-D2nLVGig.d.mts +238 -0
  61. package/dist/document-D4fJt3zX.d.cts +12223 -0
  62. package/dist/document-D5yDIDIx.d.mts +15 -0
  63. package/dist/document-D73dqRle.d.cts +19 -0
  64. package/dist/document-DA6YVZz-.d.cts +100 -0
  65. package/dist/document-DJ0YiVte.d.cts +30 -0
  66. package/dist/document-DMHIUE3J.d.mts +17 -0
  67. package/dist/document-DN3g0EFx.d.cts +434 -0
  68. package/dist/document-DYzRVV1C.d.mts +16 -0
  69. package/dist/document-D_ZMbzn6.d.cts +18 -0
  70. package/dist/document-DdRo9TdG.d.mts +12223 -0
  71. package/dist/document-DeoRGh7p.d.mts +19 -0
  72. package/dist/document-DsIPBTG8.cjs +30 -0
  73. package/dist/document-DsSaMVGb.cjs +106 -0
  74. package/dist/document-Gx2Vrg_w.d.mts +267 -0
  75. package/dist/document-IIJpsOIO.d.cts +16 -0
  76. package/dist/document-WHS8GHY5.d.mts +18 -0
  77. package/dist/document-dqrWptdY.d.cts +244 -0
  78. package/dist/document-hEBlSep8.d.cts +15 -0
  79. package/dist/document-rbMXLGxt.cjs +103 -0
  80. package/dist/document-si7GYS5g.d.mts +19 -0
  81. package/dist/document-vq-7rcU5.d.mts +244 -0
  82. package/dist/entities/audit-log/index.cjs +127 -0
  83. package/dist/entities/audit-log/index.d.cts +134 -0
  84. package/dist/entities/audit-log/index.d.mts +134 -0
  85. package/dist/entities/audit-log/index.mjs +115 -0
  86. package/dist/entities/blog-page/index.cjs +16 -0
  87. package/dist/entities/blog-page/index.d.cts +257 -0
  88. package/dist/entities/blog-page/index.d.mts +257 -0
  89. package/dist/entities/blog-page/index.mjs +13 -0
  90. package/dist/entities/blog-post/index.cjs +33 -0
  91. package/dist/entities/blog-post/index.d.cts +917 -0
  92. package/dist/entities/blog-post/index.d.mts +917 -0
  93. package/dist/entities/blog-post/index.mjs +21 -0
  94. package/dist/entities/careers-page/index.cjs +16 -0
  95. package/dist/entities/careers-page/index.d.cts +257 -0
  96. package/dist/entities/careers-page/index.d.mts +257 -0
  97. package/dist/entities/careers-page/index.mjs +13 -0
  98. package/dist/entities/category/index.cjs +63 -0
  99. package/dist/entities/category/index.d.cts +300 -0
  100. package/dist/entities/category/index.d.mts +300 -0
  101. package/dist/entities/category/index.mjs +52 -0
  102. package/dist/entities/client/index.cjs +96 -0
  103. package/dist/entities/client/index.d.cts +85 -0
  104. package/dist/entities/client/index.d.mts +85 -0
  105. package/dist/entities/client/index.mjs +83 -0
  106. package/dist/entities/client-content-pillar/index.cjs +70 -0
  107. package/dist/entities/client-content-pillar/index.d.cts +49 -0
  108. package/dist/entities/client-content-pillar/index.d.mts +49 -0
  109. package/dist/entities/client-content-pillar/index.mjs +59 -0
  110. package/dist/entities/client-media-platform/index.cjs +74 -0
  111. package/dist/entities/client-media-platform/index.d.cts +53 -0
  112. package/dist/entities/client-media-platform/index.d.mts +53 -0
  113. package/dist/entities/client-media-platform/index.mjs +63 -0
  114. package/dist/entities/client-project/index.cjs +205 -0
  115. package/dist/entities/client-project/index.d.cts +147 -0
  116. package/dist/entities/client-project/index.d.mts +147 -0
  117. package/dist/entities/client-project/index.mjs +188 -0
  118. package/dist/entities/client-report/index.cjs +82 -0
  119. package/dist/entities/client-report/index.d.cts +63 -0
  120. package/dist/entities/client-report/index.d.mts +63 -0
  121. package/dist/entities/client-report/index.mjs +71 -0
  122. package/dist/entities/client-styleguide/index.cjs +77 -0
  123. package/dist/entities/client-styleguide/index.d.cts +48 -0
  124. package/dist/entities/client-styleguide/index.d.mts +48 -0
  125. package/dist/entities/client-styleguide/index.mjs +66 -0
  126. package/dist/entities/client-user/index.cjs +78 -0
  127. package/dist/entities/client-user/index.d.cts +47 -0
  128. package/dist/entities/client-user/index.d.mts +47 -0
  129. package/dist/entities/client-user/index.mjs +64 -0
  130. package/dist/entities/comment/index.cjs +137 -0
  131. package/dist/entities/comment/index.d.cts +2 -0
  132. package/dist/entities/comment/index.d.mts +2 -0
  133. package/dist/entities/comment/index.mjs +116 -0
  134. package/dist/entities/content-pillar/index.cjs +59 -0
  135. package/dist/entities/content-pillar/index.d.cts +50 -0
  136. package/dist/entities/content-pillar/index.d.mts +50 -0
  137. package/dist/entities/content-pillar/index.mjs +48 -0
  138. package/dist/entities/faq-page/index.cjs +17 -0
  139. package/dist/entities/faq-page/index.d.cts +335 -0
  140. package/dist/entities/faq-page/index.d.mts +335 -0
  141. package/dist/entities/faq-page/index.mjs +14 -0
  142. package/dist/entities/formatter/index.cjs +258 -0
  143. package/dist/entities/formatter/index.d.cts +121 -0
  144. package/dist/entities/formatter/index.d.mts +121 -0
  145. package/dist/entities/formatter/index.mjs +233 -0
  146. package/dist/entities/gcflytour/index.cjs +79 -0
  147. package/dist/entities/gcflytour/index.d.cts +61 -0
  148. package/dist/entities/gcflytour/index.d.mts +61 -0
  149. package/dist/entities/gcflytour/index.mjs +68 -0
  150. package/dist/entities/gcflytour-snap/index.cjs +78 -0
  151. package/dist/entities/gcflytour-snap/index.d.cts +59 -0
  152. package/dist/entities/gcflytour-snap/index.d.mts +59 -0
  153. package/dist/entities/gcflytour-snap/index.mjs +67 -0
  154. package/dist/entities/landing-page/index.cjs +28 -0
  155. package/dist/entities/landing-page/index.d.cts +479 -0
  156. package/dist/entities/landing-page/index.d.mts +479 -0
  157. package/dist/entities/landing-page/index.mjs +25 -0
  158. package/dist/entities/lead/index.cjs +63 -0
  159. package/dist/entities/lead/index.d.cts +75 -0
  160. package/dist/entities/lead/index.d.mts +75 -0
  161. package/dist/entities/lead/index.mjs +57 -0
  162. package/dist/entities/media-content-type/index.cjs +100 -0
  163. package/dist/entities/media-content-type/index.d.cts +66 -0
  164. package/dist/entities/media-content-type/index.d.mts +66 -0
  165. package/dist/entities/media-content-type/index.mjs +89 -0
  166. package/dist/entities/media-creative-format/index.cjs +79 -0
  167. package/dist/entities/media-creative-format/index.d.cts +54 -0
  168. package/dist/entities/media-creative-format/index.d.mts +54 -0
  169. package/dist/entities/media-creative-format/index.mjs +68 -0
  170. package/dist/entities/media-medium/index.cjs +90 -0
  171. package/dist/entities/media-medium/index.d.cts +77 -0
  172. package/dist/entities/media-medium/index.d.mts +77 -0
  173. package/dist/entities/media-medium/index.mjs +79 -0
  174. package/dist/entities/media-platform/index.cjs +118 -0
  175. package/dist/entities/media-platform/index.d.cts +74 -0
  176. package/dist/entities/media-platform/index.d.mts +74 -0
  177. package/dist/entities/media-platform/index.mjs +107 -0
  178. package/dist/entities/monday-workspace/index.cjs +66 -0
  179. package/dist/entities/monday-workspace/index.d.cts +47 -0
  180. package/dist/entities/monday-workspace/index.d.mts +47 -0
  181. package/dist/entities/monday-workspace/index.mjs +55 -0
  182. package/dist/entities/newsletter-signup/index.cjs +67 -0
  183. package/dist/entities/newsletter-signup/index.d.cts +76 -0
  184. package/dist/entities/newsletter-signup/index.d.mts +76 -0
  185. package/dist/entities/newsletter-signup/index.mjs +60 -0
  186. package/dist/entities/policy-page/index.cjs +23 -0
  187. package/dist/entities/policy-page/index.d.cts +331 -0
  188. package/dist/entities/policy-page/index.d.mts +331 -0
  189. package/dist/entities/policy-page/index.mjs +20 -0
  190. package/dist/entities/product/index.cjs +28 -0
  191. package/dist/entities/product/index.d.cts +325 -0
  192. package/dist/entities/product/index.d.mts +325 -0
  193. package/dist/entities/product/index.mjs +23 -0
  194. package/dist/entities/product-highlight/index.cjs +28 -0
  195. package/dist/entities/product-highlight/index.d.cts +245 -0
  196. package/dist/entities/product-highlight/index.d.mts +245 -0
  197. package/dist/entities/product-highlight/index.mjs +23 -0
  198. package/dist/entities/resume/index.cjs +129 -0
  199. package/dist/entities/resume/index.d.cts +198 -0
  200. package/dist/entities/resume/index.d.mts +198 -0
  201. package/dist/entities/resume/index.mjs +119 -0
  202. package/dist/entities/sharpspring/index.cjs +19 -0
  203. package/dist/entities/sharpspring/index.d.cts +16 -0
  204. package/dist/entities/sharpspring/index.d.mts +16 -0
  205. package/dist/entities/sharpspring/index.mjs +16 -0
  206. package/dist/entities/tag/index.cjs +61 -0
  207. package/dist/entities/tag/index.d.cts +54 -0
  208. package/dist/entities/tag/index.d.mts +54 -0
  209. package/dist/entities/tag/index.mjs +50 -0
  210. package/dist/entities/team-member/index.cjs +29 -0
  211. package/dist/entities/team-member/index.d.cts +210 -0
  212. package/dist/entities/team-member/index.d.mts +210 -0
  213. package/dist/entities/team-member/index.mjs +17 -0
  214. package/dist/entities/team-page/index.cjs +16 -0
  215. package/dist/entities/team-page/index.d.cts +257 -0
  216. package/dist/entities/team-page/index.d.mts +257 -0
  217. package/dist/entities/team-page/index.mjs +13 -0
  218. package/dist/entities/teamwork/index.cjs +74 -0
  219. package/dist/entities/teamwork/index.d.cts +512 -0
  220. package/dist/entities/teamwork/index.d.mts +512 -0
  221. package/dist/entities/teamwork/index.mjs +68 -0
  222. package/dist/entities/trend/index.cjs +34 -0
  223. package/dist/entities/trend/index.d.cts +347 -0
  224. package/dist/entities/trend/index.d.mts +347 -0
  225. package/dist/entities/trend/index.mjs +28 -0
  226. package/dist/entities/up-auth/index.cjs +56 -0
  227. package/dist/entities/up-auth/index.d.cts +2 -0
  228. package/dist/entities/up-auth/index.d.mts +2 -0
  229. package/dist/entities/up-auth/index.mjs +44 -0
  230. package/dist/entities/up-permission/index.cjs +12 -0
  231. package/dist/entities/up-permission/index.d.cts +14 -0
  232. package/dist/entities/up-permission/index.d.mts +14 -0
  233. package/dist/entities/up-permission/index.mjs +9 -0
  234. package/dist/entities/up-role/index.cjs +28 -0
  235. package/dist/entities/up-role/index.d.cts +7 -0
  236. package/dist/entities/up-role/index.d.mts +7 -0
  237. package/dist/entities/up-role/index.mjs +23 -0
  238. package/dist/entities/up-user/index.cjs +64 -0
  239. package/dist/entities/up-user/index.d.cts +38 -0
  240. package/dist/entities/up-user/index.d.mts +38 -0
  241. package/dist/entities/up-user/index.mjs +54 -0
  242. package/dist/entities/upload/index.cjs +35 -0
  243. package/dist/entities/upload/index.d.cts +31 -0
  244. package/dist/entities/upload/index.d.mts +31 -0
  245. package/dist/entities/upload/index.mjs +29 -0
  246. package/dist/entities/url-redirect/index.cjs +67 -0
  247. package/dist/entities/url-redirect/index.d.cts +45 -0
  248. package/dist/entities/url-redirect/index.d.mts +45 -0
  249. package/dist/entities/url-redirect/index.mjs +54 -0
  250. package/dist/entities/user-account/index.cjs +48 -0
  251. package/dist/entities/user-account/index.d.cts +39 -0
  252. package/dist/entities/user-account/index.d.mts +39 -0
  253. package/dist/entities/user-account/index.mjs +39 -0
  254. package/dist/entities/utm-link-builder/index.cjs +84 -0
  255. package/dist/entities/utm-link-builder/index.d.cts +191 -0
  256. package/dist/entities/utm-link-builder/index.d.mts +191 -0
  257. package/dist/entities/utm-link-builder/index.mjs +76 -0
  258. package/dist/entities/utm-meta/index.cjs +19 -0
  259. package/dist/entities/utm-meta/index.d.cts +83 -0
  260. package/dist/entities/utm-meta/index.d.mts +83 -0
  261. package/dist/entities/utm-meta/index.mjs +16 -0
  262. package/dist/entities/utm-tracking-link/index.cjs +199 -0
  263. package/dist/entities/utm-tracking-link/index.d.cts +235 -0
  264. package/dist/entities/utm-tracking-link/index.d.mts +235 -0
  265. package/dist/entities/utm-tracking-link/index.mjs +184 -0
  266. package/dist/fields-BQHSYj70.d.cts +7 -0
  267. package/dist/fields-qx-5saY5.d.mts +7 -0
  268. package/dist/fonts-CGSHKgp0.cjs +125 -0
  269. package/dist/fonts-tMy55UFs.mjs +58 -0
  270. package/dist/index-BI8tN-QZ.d.mts +99 -0
  271. package/dist/index-BLE_fX1Q.d.cts +200 -0
  272. package/dist/index-Bht1Jd5l.d.mts +422 -0
  273. package/dist/index-DYPjS1qh.d.mts +200 -0
  274. package/dist/index-DpYYzY_9.d.cts +99 -0
  275. package/dist/index-ZBDWYTfn.d.cts +422 -0
  276. package/dist/json-BJ8GyrtC.d.cts +9 -0
  277. package/dist/json-BgewUW_1.cjs +19 -0
  278. package/dist/json-CTduX6Ak.mjs +12 -0
  279. package/dist/json-CqAaKeHA.d.mts +9 -0
  280. package/dist/media-upload-B6aQYeRM.cjs +59 -0
  281. package/dist/media-upload-DiRJksSU.mjs +40 -0
  282. package/dist/pagination-4pZafglS.cjs +23 -0
  283. package/dist/pagination-owwfYJS6.mjs +6 -0
  284. package/dist/{permissions.cjs → permissions/index.cjs} +6 -89
  285. package/dist/permissions/index.d.cts +2 -0
  286. package/dist/permissions/index.d.mts +2 -0
  287. package/dist/{permissions.mjs → permissions/index.mjs} +3 -86
  288. package/dist/query.schema-BOn5Kk_p.d.mts +41 -0
  289. package/dist/query.schema-CItKlb0x.d.cts +41 -0
  290. package/dist/query.schema-DHTf6rTw.cjs +95 -0
  291. package/dist/query.schema-YKoOuBnk.mjs +40 -0
  292. package/dist/regex-BnKGcdS4.mjs +55 -0
  293. package/dist/regex-Cl5goNwp.cjs +342 -0
  294. package/dist/relations-C04F46xL.mjs +41 -0
  295. package/dist/relations-CGu18hfT.cjs +90 -0
  296. package/dist/response-C-7nyNVD.d.mts +57 -0
  297. package/dist/response-c6SgLvi9.d.cts +57 -0
  298. package/dist/strapi-C0DtxJLD.mjs +9 -0
  299. package/dist/strapi-C7POOPEf.cjs +34 -0
  300. package/dist/strapi-COeswSwJ.mjs +49 -0
  301. package/dist/strapi-DmhV7ODq.cjs +72 -0
  302. package/dist/theme-Ba9vW4PA.cjs +230 -0
  303. package/dist/theme-BhQd4eMI.mjs +97 -0
  304. package/dist/{utilities.cjs → utilities/index.cjs} +9 -28
  305. package/dist/utilities/index.d.cts +24 -0
  306. package/dist/utilities/index.d.mts +24 -0
  307. package/dist/{utilities.mjs → utilities/index.mjs} +9 -25
  308. package/dist/validators-Bc9Is5Sr.cjs +222 -0
  309. package/dist/validators-P5E_3qzc.mjs +95 -0
  310. package/package.json +64 -40
  311. package/dist/constants.cjs +0 -461
  312. package/dist/constants.d.cts +0 -2
  313. package/dist/constants.d.mts +0 -2
  314. package/dist/constants.mjs +0 -353
  315. package/dist/index-CiWVYf_f.d.cts +0 -291
  316. package/dist/index-D5uEXy4J.d.mts +0 -4509
  317. package/dist/index-DOR_It7I.d.mts +0 -291
  318. package/dist/index-Df4iWapE.d.cts +0 -4509
  319. package/dist/index.cjs +0 -384
  320. package/dist/index.d.cts +0 -3
  321. package/dist/index.d.mts +0 -3
  322. package/dist/index.mjs +0 -6
  323. package/dist/permissions.d.cts +0 -2
  324. package/dist/permissions.d.mts +0 -2
  325. package/dist/schemas.cjs +0 -2326
  326. package/dist/schemas.d.cts +0 -2
  327. package/dist/schemas.d.mts +0 -2
  328. package/dist/schemas.mjs +0 -2068
  329. package/dist/types.cjs +0 -0
  330. package/dist/types.d.cts +0 -2
  331. package/dist/types.d.mts +0 -2
  332. package/dist/types.mjs +0 -1
  333. package/dist/utilities.d.cts +0 -2
  334. package/dist/utilities.d.mts +0 -2
package/dist/schemas.mjs DELETED
@@ -1,2068 +0,0 @@
1
- import { ClientProjectPhaseOptions, ClientProjectStatusOptions, CommentApprovalStatusOptions, ERROR_MESSAGE_COMMA_SEPPARATED_URLS, ERROR_MESSAGE_INVALID_URL, ERROR_MESSAGE_ONE_PROJECT_STATUS, ERROR_MESSAGE_REGEX_PHONE, ERROR_MESSAGE_REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_UTM_VALUE, ERROR_MESSAGE_ROBOT, ERROR_MESSAGE_URL_NO_QUERY_PARAMS, ERROR_MESSAGE_URL_PREFIX, ERROR_MESSAGE_UTM_URL, IsValidClientClassificationSelectOptions, LIMIT_LONG_STRING_MAX_LENGTH, LIMIT_MAX_DESTINATION, LIMIT_MAX_UTM_CAMPAIGN, LIMIT_MAX_UTM_CONTENT, LIMIT_MAX_UTM_CREATIVE_FORMAT, LIMIT_MAX_UTM_ID, LIMIT_MAX_UTM_MEDIUM, LIMIT_MAX_UTM_SOURCE, LIMIT_MONDAY_WORKSPACE_PAGINATION_MAX_SIZE, LIMIT_PAGINATION_MAX_SIZE, LIMIT_REDIRECT_PAGINATION_DEFAULT_SIZE, LIMIT_UTM_TRACKING_LINK_PAGINATION_MAX_SIZE, REGEX_NANP_PHONE, REGEX_URL_SLUG, REGEX_UTM_VALUE, ReportCommentReasonOptions } from "./constants.mjs";
2
- import { CLIENT_ENTITY_SCOPES } from "./permissions.mjs";
3
- import * as v from "valibot";
4
- //#region src/schemas/core-entities.schemas.ts
5
- const StrapiCollectionEntities = [
6
- "blog-posts",
7
- "categories",
8
- "client-content-pillars",
9
- "client-media-platforms",
10
- "client-projects",
11
- "client-reports",
12
- "client-styleguides",
13
- "client-users",
14
- "clients",
15
- "comment-reports",
16
- "comments",
17
- "content-pillars",
18
- "gc-fly-tour-snaps",
19
- "gc-fly-tours",
20
- "leads",
21
- "media-content-types",
22
- "media-creative-formats",
23
- "media-mediums",
24
- "media-platforms",
25
- "monday-workspaces",
26
- "newsletter-signups",
27
- "product-highlights",
28
- "products",
29
- "resumes",
30
- "tags",
31
- "team-members",
32
- "trends",
33
- "url-redirections",
34
- "user-accounts",
35
- "users",
36
- "utm-tracking-links"
37
- ];
38
- const ValidStrapiCollectionEntity = v.picklist(StrapiCollectionEntities);
39
- const StrapiSingleEntities = [
40
- "blog-page",
41
- "careers-page",
42
- "faq",
43
- "landing-page",
44
- "privacy-policy",
45
- "sms-policy",
46
- "team-page",
47
- "utm-meta"
48
- ];
49
- const ValidStrapiSingleEntity = v.picklist(StrapiSingleEntities);
50
- //#endregion
51
- //#region src/schemas/core-validators.schemas.ts
52
- /**
53
- * Basic number validator
54
- */
55
- const VNumberNullable = () => v.optional(v.nullable(v.number()));
56
- const VIntegerNullable = () => v.optional(v.nullable(v.pipe(v.number(), v.integer())));
57
- /**
58
- * Basic string validator with trim and min length
59
- */
60
- const VString = (minLength = 1) => v.pipe(v.string(), v.trim(), v.minLength(minLength));
61
- /**
62
- * String validator with trim, min length, and max length (Short)
63
- */
64
- const VStringShort = (minLength = 1) => v.pipe(v.string(), v.trim(), v.minLength(minLength), v.maxLength(255));
65
- /**
66
- * String validator with trim, min length, and max length (Long)
67
- */
68
- const VStringLong = (minLength = 1) => v.pipe(v.string(), v.trim(), v.minLength(minLength), v.maxLength(LIMIT_LONG_STRING_MAX_LENGTH));
69
- /**
70
- * String validator with trim, and max length
71
- */
72
- const VStringMax = (maxLength = 255) => v.pipe(v.string(), v.trim(), v.maxLength(maxLength));
73
- /**
74
- * String validator with trim, and max length
75
- */
76
- const VStringMaxRegex = (maxLength = 255, pattern, message) => v.pipe(v.string(), v.trim(), v.maxLength(maxLength), v.regex(pattern, message));
77
- /**
78
- * String validator with trim, min length, and max length
79
- */
80
- const VStringMinMax = (minLength = 1, maxLength = 255) => v.pipe(v.string(), v.trim(), v.minLength(minLength), v.maxLength(maxLength));
81
- /**
82
- * String validator with trim, min length, max length, and regex pattern
83
- */
84
- const VStringMinMaxRegex = (minLength = 1, maxLength = 255, pattern, message) => v.pipe(v.string(), v.trim(), v.minLength(minLength), v.maxLength(maxLength), v.regex(pattern, message));
85
- /**
86
- * Optional Nullable String validator (Long)
87
- */
88
- const VStringLongNullable = () => v.optional(v.nullable(v.pipe(v.string(), v.trim(), v.maxLength(LIMIT_LONG_STRING_MAX_LENGTH))));
89
- /**
90
- * Optional Nullable String validator
91
- * Commonly used for optional fields that might be null in the database or API
92
- */
93
- const VStringShortNullable = () => v.optional(v.nullable(v.pipe(v.string(), v.trim(), v.maxLength(255))));
94
- /**
95
- * URL Validator
96
- * Checks for http/https prefix and valid URL format
97
- */
98
- const VStringUrl = () => v.pipe(v.string(), v.trim(), v.startsWith("http", ERROR_MESSAGE_URL_PREFIX), v.url(ERROR_MESSAGE_INVALID_URL));
99
- /**
100
- * UTM URL Validator
101
- * Checks for valid URL format that does contain utm params
102
- */
103
- const VStringUrlUtm = () => v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
104
- return input.includes("utm_");
105
- }, ERROR_MESSAGE_UTM_URL));
106
- /**
107
- * URL no utm params Validator
108
- * Checks for valid URL format that does not contain utm params
109
- */
110
- const VStringUrlNoUtm = () => v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
111
- if (input === "") return false;
112
- return input.indexOf("?") === -1;
113
- }, ERROR_MESSAGE_URL_NO_QUERY_PARAMS));
114
- /**
115
- * Optional Nullable URL Validator
116
- */
117
- const VStringUrlNullable = () => v.optional(v.nullable(v.pipe(v.string(), v.trim(), v.startsWith("http", ERROR_MESSAGE_URL_PREFIX), v.url(ERROR_MESSAGE_INVALID_URL))));
118
- /**
119
- * Slug Validator
120
- */
121
- const VStringSlug = () => v.pipe(v.string(), v.trim(), v.minLength(1), v.maxLength(255), v.regex(REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG));
122
- /**
123
- * Email Validator
124
- */
125
- const VStringEmail = () => v.pipe(v.string(), v.trim(), v.minLength(5), v.maxLength(255), v.email());
126
- /**
127
- * Phone Validator (NANP)
128
- */
129
- const VStringPhone = () => v.pipe(v.string(), v.trim(), v.minLength(7), v.maxLength(24), v.regex(REGEX_NANP_PHONE, ERROR_MESSAGE_REGEX_PHONE));
130
- /**
131
- * Optional Nullable Phone Validator
132
- */
133
- const VStringPhoneNullable = () => v.optional(v.nullable(VStringPhone()));
134
- /**
135
- * Pagination Page Validator
136
- */
137
- const VPage = () => v.optional(v.pipe(v.number(), v.minValue(1)));
138
- /**
139
- * Pagination Size Validator
140
- */
141
- const VSize = (maxSize) => v.optional(v.pipe(v.number(), v.minValue(1), v.maxValue(maxSize)));
142
- //#endregion
143
- //#region src/schemas/core-relations.schemas.ts
144
- const SAssociateOneEntity = VStringMinMax(1, 255);
145
- const SAssociateManyEntities = v.pipe(v.array(SAssociateOneEntity), v.maxLength(100));
146
- const SQueryManyEntities = v.pipe(v.array(VStringMinMax(1, 255)));
147
- const SAssociateEntityRelationshipRequest = v.pipe(v.object({
148
- collection: ValidStrapiCollectionEntity,
149
- documentId: SAssociateOneEntity,
150
- relationKey: VStringShort(),
151
- connect: v.optional(SAssociateManyEntities),
152
- disconnect: v.optional(SAssociateManyEntities)
153
- }), v.check((input) => !!(input.connect || input.disconnect), "You must provide a relationship to update: connect or disconnect."));
154
- const SEntityPosition = v.optional(v.object({
155
- before: v.optional(SAssociateOneEntity),
156
- after: v.optional(SAssociateOneEntity),
157
- start: v.optional(v.boolean()),
158
- end: v.optional(v.boolean())
159
- }), { end: true });
160
- const SAssociateEntityPosition = v.object({
161
- documentId: SAssociateOneEntity,
162
- position: SEntityPosition,
163
- locale: v.optional(VStringShort())
164
- });
165
- const SAssociateEntityPositionDocumentRequest = v.pipe(v.object({
166
- collection: ValidStrapiCollectionEntity,
167
- documentId: SAssociateOneEntity,
168
- relationKey: VStringShort(),
169
- connect: v.optional(v.array(SAssociateEntityPosition)),
170
- disconnect: v.optional(SAssociateManyEntities)
171
- }), v.check((input) => !!(input.connect || input.disconnect), "You must provide a relationship to update: connect or disconnect."));
172
- const SSetEntityRelationshipRequest = v.pipe(v.object({
173
- collection: ValidStrapiCollectionEntity,
174
- documentId: SAssociateOneEntity,
175
- relationKey: VStringShort(),
176
- set: SAssociateManyEntities
177
- }));
178
- //#endregion
179
- //#region src/schemas/core-generic.schemas.ts
180
- const JsonSchema = v.lazy(() => v.union([
181
- v.string(),
182
- v.number(),
183
- v.boolean(),
184
- v.null(),
185
- v.record(v.string(), JsonSchema),
186
- v.array(JsonSchema)
187
- ]));
188
- const EntitySortKeys = [
189
- "id",
190
- "createdAt",
191
- "updatedAt"
192
- ];
193
- const QuerySortEntities = v.optional(v.pipe(v.array(v.picklist(EntitySortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(EntitySortKeys.length)));
194
- const QueryStrapiPaginated = v.object({
195
- page: VPage(),
196
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
197
- sort: QuerySortEntities
198
- });
199
- const QueryStrapiById = v.object({ id: v.number() });
200
- const QueryStrapiByDocumentId = v.object({ documentId: SAssociateOneEntity });
201
- const QueryStrapiBySlug = v.object({
202
- slug: VStringShort(),
203
- sort: QuerySortEntities
204
- });
205
- const QueryStrapiByEmail = v.object({
206
- email: VStringEmail(),
207
- sort: QuerySortEntities
208
- });
209
- const QueryStrapiByPhone = v.object({
210
- phone: VStringPhone(),
211
- sort: QuerySortEntities
212
- });
213
- const QueryStrapiByName = v.object({
214
- name: VStringShort(),
215
- sort: QuerySortEntities
216
- });
217
- //#endregion
218
- //#region src/schemas/audit-log.schemas.ts
219
- const AuditLogSortKeys = [
220
- "id",
221
- "method",
222
- "url",
223
- "path",
224
- "request_id",
225
- "ipaddress",
226
- "user_agent",
227
- "route_path",
228
- "route_handler",
229
- "actor_type",
230
- "actor_id",
231
- "actor_email",
232
- "entity_action",
233
- "entity_content_type",
234
- "entity_id",
235
- "entity_label",
236
- "createdAt",
237
- "updatedAt"
238
- ];
239
- const QuerySortAuditLogs = v.optional(v.pipe(v.array(v.picklist(AuditLogSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(AuditLogSortKeys.length)));
240
- const SAuditLogMethod = v.picklist([
241
- "GET",
242
- "POST",
243
- "PUT",
244
- "PATCH",
245
- "DELETE",
246
- "UNKNOWN"
247
- ]);
248
- const QueryStrapiSearchAuditLogs = v.object({
249
- page: VPage(),
250
- size: VSize(20),
251
- method: v.optional(SAuditLogMethod),
252
- url: v.optional(v.string()),
253
- path: v.optional(v.string()),
254
- request_id: v.optional(VStringMax()),
255
- ipaddress: v.optional(VStringMax(64)),
256
- user_agent: v.optional(VStringMax()),
257
- route_path: v.optional(VStringMax()),
258
- route_handler: v.optional(VStringMax()),
259
- actor_type: v.optional(VStringMax()),
260
- actor_id: v.optional(VStringMax()),
261
- actor_email: v.optional(VStringEmail()),
262
- entity_action: v.optional(VStringMax()),
263
- entity_content_type: v.optional(VStringMax()),
264
- entity_id: v.optional(VStringMax()),
265
- entity_label: v.optional(VStringMax()),
266
- sort: QuerySortAuditLogs
267
- });
268
- const SCreateAuditLogDocument = v.object({
269
- method: SAuditLogMethod,
270
- url: v.string(),
271
- path: v.string(),
272
- request_id: v.nullable(VStringMax()),
273
- ipaddress: v.nullable(VStringMax(64)),
274
- user_agent: v.nullable(VStringMax()),
275
- route_path: v.nullable(VStringMax()),
276
- route_handler: v.nullable(VStringMax()),
277
- actor_type: VStringMax(),
278
- actor_id: v.nullable(VStringMax()),
279
- actor_email: v.nullable(VStringEmail()),
280
- entity_action: VStringMax(),
281
- entity_content_type: VStringMax(),
282
- entity_id: v.nullable(VStringMax()),
283
- entity_label: v.nullable(VStringMax()),
284
- request_data: v.optional(v.nullable(JsonSchema)),
285
- before: v.optional(v.nullable(JsonSchema)),
286
- after: v.optional(v.nullable(JsonSchema))
287
- });
288
- const SUpdateAuditLogDocument = v.object({
289
- method: v.optional(SAuditLogMethod),
290
- url: v.optional(v.string()),
291
- path: v.optional(v.string()),
292
- request_id: v.optional(v.nullable(VStringMax())),
293
- ipaddress: v.optional(v.nullable(VStringMax(64))),
294
- user_agent: v.optional(v.nullable(VStringMax())),
295
- route_path: v.optional(v.nullable(VStringMax())),
296
- route_handler: v.optional(v.nullable(VStringMax())),
297
- actor_type: v.optional(VStringMax()),
298
- actor_id: v.optional(v.nullable(VStringMax())),
299
- actor_email: v.optional(v.nullable(VStringEmail())),
300
- entity_action: v.optional(VStringMax()),
301
- entity_content_type: v.optional(VStringMax()),
302
- entity_id: v.optional(v.nullable(VStringMax())),
303
- entity_label: v.optional(v.nullable(VStringMax())),
304
- request_data: v.optional(v.nullable(JsonSchema)),
305
- before: v.optional(v.nullable(JsonSchema)),
306
- after: v.optional(v.nullable(JsonSchema))
307
- });
308
- const SUpdateAuditLogDocumentRequest = v.object({
309
- documentId: SAssociateOneEntity,
310
- data: SUpdateAuditLogDocument
311
- });
312
- //#endregion
313
- //#region src/schemas/blog.schemas.ts
314
- const BlogPostSortKeys = [
315
- "id",
316
- "title",
317
- "slug",
318
- "is_live",
319
- "is_featured",
320
- "is_public",
321
- "published",
322
- "createdAt",
323
- "updatedAt"
324
- ];
325
- const QuerySortBlogPosts = v.optional(v.pipe(v.array(v.picklist(BlogPostSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(BlogPostSortKeys.length)));
326
- const QueryStrapiSearchBlogPosts = v.object({
327
- page: VPage(),
328
- size: VSize(20),
329
- search: v.optional(VStringShort(0)),
330
- category: v.optional(VStringShort(0)),
331
- tags: v.optional(v.array(VStringShort())),
332
- status: v.optional(v.picklist(["draft", "published"])),
333
- sort: QuerySortBlogPosts
334
- });
335
- const QueryStrapiSearchBlogPostsBySlug = v.object({
336
- slug: VStringShort(),
337
- status: v.optional(v.picklist(["draft", "published"]), "published"),
338
- sort: QuerySortBlogPosts
339
- });
340
- //#endregion
341
- //#region src/schemas/category.schemas.ts
342
- const CategorySortKeys = [
343
- "id",
344
- "label",
345
- "slug",
346
- "createdAt",
347
- "updatedAt"
348
- ];
349
- const QuerySortCategories = v.optional(v.pipe(v.array(v.picklist(CategorySortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(CategorySortKeys.length)));
350
- const QueryStrapiSearchCategories = v.object({
351
- page: VPage(),
352
- size: VSize(20),
353
- label: v.optional(VStringMax()),
354
- slug: v.optional(VStringMax()),
355
- sort: QuerySortCategories
356
- });
357
- const SCreateCategoryDocument = v.object({
358
- label: VStringMinMax(1, 255),
359
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)
360
- });
361
- const SUpdateCategoryDocument = v.object({
362
- label: v.optional(VStringMinMax(1, 255)),
363
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG))
364
- });
365
- const SUpdateCategoryDocumentRequest = v.object({
366
- documentId: SAssociateOneEntity,
367
- data: SUpdateCategoryDocument
368
- });
369
- //#endregion
370
- //#region src/schemas/client-content-pillar.schemas.ts
371
- const ClientContentPillarSortKeys = [
372
- "id",
373
- "is_active",
374
- "content_pillar.title",
375
- "content_pillar.slug",
376
- "createdAt",
377
- "updatedAt"
378
- ];
379
- const QuerySortClientContentPillars = v.optional(v.pipe(v.array(v.picklist(ClientContentPillarSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientContentPillarSortKeys.length)));
380
- const QueryStrapiSearchClientContentPillars = v.object({
381
- page: VPage(),
382
- size: VSize(100),
383
- is_active: v.optional(v.boolean()),
384
- client_id: v.optional(VStringMinMax(1, 255)),
385
- clients: v.optional(SQueryManyEntities),
386
- content_pillar_id: v.optional(VStringMinMax(1, 255)),
387
- content_pillars: v.optional(SQueryManyEntities),
388
- sort: QuerySortClientContentPillars
389
- });
390
- const SCreateClientContentPillarDocument = v.object({
391
- is_active: v.optional(v.boolean()),
392
- client: v.optional(SAssociateOneEntity),
393
- content_pillar: v.optional(SAssociateOneEntity)
394
- });
395
- const SUpdateClientContentPillarDocument = v.object({
396
- is_active: v.optional(v.boolean()),
397
- client: v.optional(SAssociateOneEntity),
398
- content_pillar: v.optional(SAssociateOneEntity)
399
- });
400
- const SUpdateClientContentPillarDocumentRequest = v.object({
401
- documentId: SAssociateOneEntity,
402
- data: SUpdateClientContentPillarDocument
403
- });
404
- //#endregion
405
- //#region src/schemas/client-media-platform.schemas.ts
406
- const ClientMediaPlatformSortKeys = [
407
- "id",
408
- "is_active",
409
- "is_organic_social",
410
- "is_paid_media",
411
- "createdAt",
412
- "updatedAt",
413
- "media_platform.title",
414
- "media_platform.slug",
415
- "media_platform.createdAt",
416
- "media_platform.updatedAt"
417
- ];
418
- const QuerySortClientMediaPlatforms = v.optional(v.pipe(v.array(v.picklist(ClientMediaPlatformSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientMediaPlatformSortKeys.length)));
419
- const QueryStrapiSearchClientMediaPlatforms = v.object({
420
- page: VPage(),
421
- size: VSize(100),
422
- url: v.optional(VStringMax(LIMIT_MAX_DESTINATION)),
423
- is_active: v.optional(v.boolean()),
424
- client_id: v.optional(VStringMinMax(1, 255)),
425
- clients: v.optional(SQueryManyEntities),
426
- media_platform_id: v.optional(VStringMinMax(1, 255)),
427
- media_platforms: v.optional(SQueryManyEntities),
428
- sort: QuerySortClientMediaPlatforms
429
- });
430
- const SCreateClientMediaPlatformDocument = v.object({
431
- url: v.nullable(VStringMax(LIMIT_MAX_DESTINATION)),
432
- is_active: v.boolean(),
433
- client: v.optional(SAssociateOneEntity),
434
- media_platform: v.optional(SAssociateOneEntity)
435
- });
436
- const SUpdateClientMediaPlatformDocument = v.object({
437
- url: v.optional(v.nullable(VStringMax(LIMIT_MAX_DESTINATION))),
438
- is_active: v.optional(v.boolean()),
439
- client: v.optional(SAssociateOneEntity),
440
- media_platform: v.optional(SAssociateOneEntity)
441
- });
442
- const SUpdateClientMediaPlatformDocumentRequest = v.object({
443
- documentId: SAssociateOneEntity,
444
- data: SUpdateClientMediaPlatformDocument
445
- });
446
- //#endregion
447
- //#region src/schemas/client-project.schemas.ts
448
- const ClientProjectSortKeys = [
449
- "id",
450
- "title",
451
- "slug",
452
- "is_active",
453
- "is_hidden",
454
- "project_phase",
455
- "project_url",
456
- "project_type",
457
- "project_pricing",
458
- "project_address",
459
- "phone_number",
460
- "num_of_models",
461
- "num_of_units_remain",
462
- "buyer_profile",
463
- "social_organic_start_date",
464
- "paid_media_start_date",
465
- "go_date",
466
- "createdAt",
467
- "updatedAt"
468
- ];
469
- const QuerySortClientProjects = v.optional(v.pipe(v.array(v.picklist(ClientProjectSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientProjectSortKeys.length)));
470
- const QueryStrapiSearchClientProjects = v.object({
471
- page: VPage(),
472
- size: VSize(100),
473
- client_id: v.optional(VStringShort()),
474
- title: v.optional(VStringMax()),
475
- slug: v.optional(VStringSlug()),
476
- is_active: v.optional(v.boolean()),
477
- is_hidden: v.optional(v.boolean()),
478
- project_status: v.optional(v.pipe(v.array(v.optional(v.picklist(ClientProjectStatusOptions), ClientProjectStatusOptions[0])), v.minLength(1), v.maxLength(1))),
479
- project_phase: v.optional(v.picklist(ClientProjectPhaseOptions)),
480
- project_url: v.optional(VStringUrl()),
481
- project_type: v.optional(VStringMax()),
482
- project_pricing: v.optional(VStringMax(255)),
483
- project_address: v.optional(VStringMax()),
484
- phone_number: v.optional(VStringPhone()),
485
- num_of_models: VIntegerNullable(),
486
- num_of_units_remain: VIntegerNullable(),
487
- buyer_profile: v.optional(VStringMax()),
488
- social_organic_start_date: v.optional(v.pipe(v.string(), v.isoDate())),
489
- paid_media_start_date: v.optional(v.pipe(v.string(), v.isoDate())),
490
- go_date: v.optional(v.pipe(v.string(), v.isoDate())),
491
- sort: QuerySortClientProjects
492
- });
493
- const SCreateClientProjectDocument = v.object({
494
- clients: v.pipe(v.array(VStringShort()), v.minLength(1)),
495
- title: VStringShort(),
496
- slug: VStringSlug(),
497
- is_active: v.boolean(),
498
- is_hidden: v.boolean(),
499
- project_status: v.pipe(v.array(v.optional(v.picklist(ClientProjectStatusOptions), ClientProjectStatusOptions[0])), v.minLength(1, ERROR_MESSAGE_ONE_PROJECT_STATUS), v.maxLength(1, ERROR_MESSAGE_ONE_PROJECT_STATUS)),
500
- project_phase: v.picklist(ClientProjectPhaseOptions),
501
- project_url: VStringUrlNullable(),
502
- project_type: v.optional(v.nullable(VStringMax())),
503
- project_pricing: v.optional(v.nullable(VStringMax())),
504
- project_address: v.optional(v.nullable(VStringMax())),
505
- phone_number: VStringPhoneNullable(),
506
- num_of_models: VIntegerNullable(),
507
- num_of_units_remain: VIntegerNullable(),
508
- buyer_profile: v.optional(v.nullable(VStringMax())),
509
- social_organic_start_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate()))),
510
- paid_media_start_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate()))),
511
- go_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate())))
512
- });
513
- const SUpdateClientProjectDocument = v.object({
514
- clients: v.optional(v.pipe(v.array(VStringShort()), v.minLength(1))),
515
- title: v.optional(VStringShort()),
516
- slug: v.optional(VStringSlug()),
517
- is_active: v.optional(v.boolean()),
518
- is_hidden: v.optional(v.boolean()),
519
- project_status: v.optional(v.pipe(v.array(v.optional(v.picklist(ClientProjectStatusOptions), ClientProjectStatusOptions[0])), v.minLength(1, ERROR_MESSAGE_ONE_PROJECT_STATUS), v.maxLength(1, ERROR_MESSAGE_ONE_PROJECT_STATUS))),
520
- project_phase: v.optional(v.picklist(ClientProjectPhaseOptions)),
521
- project_url: VStringUrlNullable(),
522
- project_type: v.optional(v.nullable(VStringMax())),
523
- project_pricing: v.optional(v.nullable(VStringMax())),
524
- project_address: v.optional(v.nullable(VStringMax())),
525
- phone_number: VStringPhoneNullable(),
526
- num_of_models: VIntegerNullable(),
527
- num_of_units_remain: VIntegerNullable(),
528
- buyer_profile: v.optional(v.nullable(VStringMax())),
529
- social_organic_start_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate()))),
530
- paid_media_start_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate()))),
531
- go_date: v.optional(v.nullable(v.pipe(v.string(), v.isoDate())))
532
- });
533
- const SUpdateClientProjectDocumentRequest = v.object({
534
- documentId: SAssociateOneEntity,
535
- data: SUpdateClientProjectDocument
536
- });
537
- const SAssociateClientToClientProjectDocument = v.object({
538
- client: SAssociateOneEntity,
539
- client_project: SAssociateOneEntity
540
- });
541
- //#endregion
542
- //#region src/schemas/client-report.schemas.ts
543
- const ClientReportSortKeys = [
544
- "id",
545
- "title",
546
- "is_active",
547
- "is_external",
548
- "is_hidden",
549
- "createdAt",
550
- "updatedAt"
551
- ];
552
- const QuerySortClientReports = v.optional(v.pipe(v.array(v.picklist(ClientReportSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientReportSortKeys.length)));
553
- const QueryStrapiSearchClientReports = v.object({
554
- page: VPage(),
555
- size: VSize(100),
556
- title: v.optional(VStringMax()),
557
- report_id: v.optional(VStringMax()),
558
- is_active: v.optional(v.boolean()),
559
- is_external: v.optional(v.boolean()),
560
- is_hidden: v.optional(v.boolean()),
561
- client_id: v.optional(VStringMinMax(1, 255)),
562
- clients: v.optional(SQueryManyEntities),
563
- sort: QuerySortClientReports
564
- });
565
- const SCreateClientReportDocument = v.object({
566
- title: VStringMinMax(1, 255),
567
- report_id: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
568
- is_active: v.optional(v.boolean(), true),
569
- is_external: v.optional(v.boolean(), false),
570
- is_hidden: v.optional(v.boolean(), false),
571
- scopes: v.optional(v.pipe(v.array(v.string("Please provide a valid list of scopes."))), ["user:*"]),
572
- clients: v.optional(SAssociateManyEntities)
573
- });
574
- const SUpdateClientReportDocument = v.object({
575
- title: v.optional(VStringMinMax(1, 255)),
576
- report_id: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
577
- is_active: v.optional(v.boolean()),
578
- is_external: v.optional(v.boolean()),
579
- is_hidden: v.optional(v.boolean()),
580
- scopes: v.optional(v.pipe(v.array(v.string("Please provide a valid list of scopes."))), ["user:*"]),
581
- clients: v.optional(SAssociateManyEntities)
582
- });
583
- const SUpdateClientReportDocumentRequest = v.object({
584
- documentId: SAssociateOneEntity,
585
- data: SUpdateClientReportDocument
586
- });
587
- //#endregion
588
- //#region src/schemas/client-styleguide.schemas.ts
589
- const ClientStyleguideSortKeys = [
590
- "id",
591
- "title",
592
- "createdAt",
593
- "updatedAt"
594
- ];
595
- const QuerySortClientStyleguides = v.optional(v.pipe(v.array(v.picklist(ClientStyleguideSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientStyleguideSortKeys.length)));
596
- const QueryStrapiSearchClientStyleguide = v.object({
597
- page: VPage(),
598
- size: VSize(100),
599
- title: v.optional(VStringMax()),
600
- is_active: v.optional(v.boolean()),
601
- client_id: v.optional(VStringMinMax(1, 255)),
602
- clients: v.optional(SQueryManyEntities),
603
- sort: QuerySortClientStyleguides
604
- });
605
- const SCreateClientStyleguideDocument = v.object({
606
- title: VStringMinMax(1, 255),
607
- is_active: v.optional(v.boolean(), true),
608
- client: v.optional(SAssociateOneEntity)
609
- });
610
- const SUpdateClientStyleguideDocument = v.object({
611
- title: v.optional(VStringMinMax(1, 255)),
612
- is_active: v.optional(v.boolean()),
613
- client: v.optional(SAssociateOneEntity)
614
- });
615
- const SUpdateClientStyleguideDocumentRequest = v.object({
616
- documentId: SAssociateOneEntity,
617
- data: SUpdateClientStyleguideDocument
618
- });
619
- //#endregion
620
- //#region src/schemas/client-user.schemas.ts
621
- const ClientUserSortKeys = [
622
- "id",
623
- "client.title",
624
- "client.teamwork_id",
625
- "client.teamwork_name",
626
- "client.is_active",
627
- "client.allow_create_utm_link",
628
- "client.is_paid_media",
629
- "client.is_organic_social",
630
- "user.username",
631
- "user.email",
632
- "user.confirmed",
633
- "user.blocked",
634
- "createdAt",
635
- "updatedAt"
636
- ];
637
- const QuerySortClientUsers = v.optional(v.pipe(v.array(v.picklist(ClientUserSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientUserSortKeys.length)));
638
- const SQueryListClientUserDocuments = v.object({
639
- documentId: SAssociateOneEntity,
640
- page: VPage(),
641
- size: VSize(100)
642
- });
643
- const SCreateClientUserDocument = v.object({
644
- client: v.optional(SAssociateOneEntity),
645
- user: v.optional(SAssociateOneEntity),
646
- scopes: v.pipe(v.array(v.pipe(v.string(), v.picklist(CLIENT_ENTITY_SCOPES)), "Please provide a valid list of scopes."), v.maxLength(CLIENT_ENTITY_SCOPES.length, "You cannot provide more scopes than there are available."))
647
- });
648
- const SUpdateClientUserDocument = v.object({ scopes: v.pipe(v.array(v.pipe(v.string(), v.picklist(CLIENT_ENTITY_SCOPES)), "Please provide a valid list of scopes."), v.maxLength(CLIENT_ENTITY_SCOPES.length, "You cannot provide more scopes than there are available.")) });
649
- const SUpdateClientUserDocumentRequest = v.object({
650
- documentId: SAssociateOneEntity,
651
- data: SUpdateClientUserDocument
652
- });
653
- const SVerifyClientUserDocument = v.object({
654
- client: SAssociateOneEntity,
655
- user: SAssociateOneEntity
656
- });
657
- //#endregion
658
- //#region src/schemas/client.schemas.ts
659
- const ClientSortKeys = [
660
- "id",
661
- "title",
662
- "teamwork_id",
663
- "teamwork_name",
664
- "utm_sheet_id",
665
- "is_active",
666
- "is_hidden",
667
- "is_featured",
668
- "allow_create_utm_link",
669
- "is_organic_social",
670
- "is_paid_media",
671
- "createdAt",
672
- "updatedAt"
673
- ];
674
- const QuerySortClients = v.optional(v.pipe(v.array(v.picklist(ClientSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ClientSortKeys.length)));
675
- const QueryStrapiSearchClients = v.object({
676
- page: VPage(),
677
- size: VSize(100),
678
- title: v.optional(VStringMax()),
679
- teamwork_id: v.optional(VStringMax()),
680
- teamwork_name: v.optional(VStringMax()),
681
- gainapp_id: v.optional(VStringMax()),
682
- utm_sheet_id: v.optional(VStringMax()),
683
- is_active: v.optional(v.boolean()),
684
- is_hidden: v.optional(v.boolean()),
685
- is_featured: v.optional(v.boolean()),
686
- allow_create_utm_link: v.optional(v.boolean()),
687
- is_paid_media: v.optional(v.boolean()),
688
- is_organic_social: v.optional(v.boolean()),
689
- classification: v.optional(v.pipe(v.array(v.picklist(IsValidClientClassificationSelectOptions)), v.maxLength(IsValidClientClassificationSelectOptions.length))),
690
- sort: QuerySortClients
691
- });
692
- const SCreateClientDocument = v.object({
693
- title: VStringMinMax(1, 255),
694
- teamwork_id: VStringMinMax(1, 255),
695
- teamwork_name: VStringMinMax(1, 255),
696
- gainapp_id: v.optional(v.nullable(VStringMinMax(1, 255))),
697
- utm_sheet_id: v.optional(VStringMinMax(1, 255)),
698
- is_active: v.boolean(),
699
- is_hidden: v.boolean(),
700
- is_featured: v.boolean(),
701
- allow_create_utm_link: v.boolean(),
702
- is_organic_social: v.boolean(),
703
- is_paid_media: v.boolean(),
704
- classification: v.optional(v.pipe(v.array(v.picklist(IsValidClientClassificationSelectOptions)), v.maxLength(IsValidClientClassificationSelectOptions.length)))
705
- });
706
- const SUpdateClientDocument = v.object({
707
- title: v.optional(VStringMinMax(1, 255)),
708
- teamwork_id: v.optional(VStringMinMax(1, 255)),
709
- teamwork_name: v.optional(VStringMinMax(1, 255)),
710
- gainapp_id: v.optional(v.nullable(VStringMinMax(1, 255))),
711
- utm_sheet_id: v.optional(VStringMinMax(1, 255)),
712
- is_active: v.optional(v.boolean()),
713
- is_hidden: v.optional(v.boolean()),
714
- is_featured: v.optional(v.boolean()),
715
- allow_create_utm_link: v.optional(v.boolean()),
716
- is_organic_social: v.optional(v.boolean()),
717
- is_paid_media: v.optional(v.boolean()),
718
- classification: v.optional(v.pipe(v.array(v.picklist(IsValidClientClassificationSelectOptions)), v.maxLength(IsValidClientClassificationSelectOptions.length)))
719
- });
720
- const SUpdateClientDocumentRequest = v.object({
721
- documentId: SAssociateOneEntity,
722
- data: SUpdateClientDocument
723
- });
724
- //#endregion
725
- //#region src/schemas/comment.schemas.ts
726
- const StrapiCommentSortKeys = [
727
- "id",
728
- "content",
729
- "blocked",
730
- "blockedThread",
731
- "approvalStatus",
732
- "createdAt",
733
- "updatedAt"
734
- ];
735
- const QuerySortStrapiComments = v.optional(v.pipe(v.array(v.picklist(StrapiCommentSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(StrapiCommentSortKeys.length)));
736
- const QueryFilterStrapiComments = v.object({
737
- approvalStatus: v.optional(v.object({ eq: v.picklist(CommentApprovalStatusOptions) })),
738
- authorName: v.optional(v.object({ containsi: v.pipe(v.string(), v.trim(), v.maxLength(255)) })),
739
- authorEmail: v.optional(v.object({ containsi: v.pipe(v.string(), v.trim(), v.maxLength(255)) })),
740
- blocked: v.optional(v.object({ eq: v.boolean() })),
741
- blockedThread: v.optional(v.object({ eq: v.boolean() })),
742
- content: v.optional(v.object({ containsi: v.pipe(v.string(), v.trim(), v.maxLength(255)) })),
743
- removed: v.optional(v.object({ eq: v.boolean() }))
744
- });
745
- const QueryStrapiCommentsInHeirarchy = v.object({
746
- relation: VStringMinMax(1, 255),
747
- sort: QuerySortStrapiComments,
748
- filters: v.optional(QueryFilterStrapiComments),
749
- nested_levels: v.optional(VPage())
750
- });
751
- const QueryStrapiCommentsFlat = v.object({
752
- relation: VStringMinMax(1, 255),
753
- filters: v.optional(QueryFilterStrapiComments),
754
- pagination: v.optional(v.object({
755
- page: VPage(),
756
- pageSize: v.optional(VSize(LIMIT_PAGINATION_MAX_SIZE))
757
- })),
758
- sort: QuerySortStrapiComments
759
- });
760
- const SCreateCommentDocument = v.object({
761
- relation: VStringMinMax(1, 255),
762
- content: VStringMinMax(1, LIMIT_LONG_STRING_MAX_LENGTH),
763
- author: v.object({
764
- id: v.number(),
765
- name: VStringMinMax(1, 255)
766
- }),
767
- threadOf: v.optional(v.number())
768
- });
769
- const SUpdateCommentDocument = v.object({
770
- relation: VStringMinMax(1, 255),
771
- id: v.number(),
772
- content: VStringMinMax(1, LIMIT_LONG_STRING_MAX_LENGTH),
773
- author: v.object({ id: v.number() })
774
- });
775
- const SDeleteCommentDocument = v.object({
776
- relation: VStringMinMax(1, 255),
777
- id: v.number(),
778
- author: v.object({ id: v.number() })
779
- });
780
- const SReportCommentDocument = v.object({
781
- relation: VStringMinMax(1, 255),
782
- commentId: v.number(),
783
- content: VStringMinMax(1, LIMIT_LONG_STRING_MAX_LENGTH),
784
- reason: v.picklist(ReportCommentReasonOptions, "You must select a valid reason for reporting this comment.")
785
- });
786
- //#endregion
787
- //#region src/schemas/content-pillar.schemas.ts
788
- const ContentPillarSortKeys = [
789
- "id",
790
- "title",
791
- "slug",
792
- "createdAt",
793
- "updatedAt"
794
- ];
795
- const QuerySortContentPillars = v.optional(v.pipe(v.array(v.picklist(ContentPillarSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(ContentPillarSortKeys.length)));
796
- const QueryStrapiSearchContentPillars = v.object({
797
- page: VPage(),
798
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
799
- title: v.optional(VStringMax()),
800
- slug: v.optional(VStringMax()),
801
- clients: v.optional(SQueryManyEntities),
802
- sort: QuerySortContentPillars
803
- });
804
- const SCreateContentPillarDocument = v.object({
805
- title: VStringMinMax(1, 255),
806
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
807
- description: v.optional(v.nullable(VStringMax(255))),
808
- clients: v.optional(SAssociateManyEntities)
809
- });
810
- const SUpdateContentPillarDocument = v.object({
811
- title: v.optional(VStringMinMax(1, 255)),
812
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
813
- description: v.optional(v.nullable(VStringMax(255))),
814
- clients: v.optional(SAssociateManyEntities)
815
- });
816
- const SUpdateContentPillarDocumentRequest = v.object({
817
- documentId: SAssociateOneEntity,
818
- data: SUpdateContentPillarDocument
819
- });
820
- //#endregion
821
- //#region src/schemas/formatter-prettier.schemas.ts
822
- /**
823
- * Prettier requires a numeric printWidth.
824
- * To get "inline unless structurally broken", use a very large default.
825
- */
826
- const INLINE_FIRST_PRINT_WIDTH = 80;
827
- const EndOfLineSchema = v.picklist([
828
- "lf",
829
- "crlf",
830
- "cr",
831
- "auto"
832
- ]);
833
- const ProseWrapSchema = v.picklist([
834
- "always",
835
- "never",
836
- "preserve"
837
- ]);
838
- const HtmlWhitespaceSensitivitySchema = v.picklist([
839
- "css",
840
- "strict",
841
- "ignore"
842
- ]);
843
- const XmlWhitespaceSensitivitySchema = v.picklist([
844
- "strict",
845
- "preserve",
846
- "ignore"
847
- ]);
848
- const XmlQuoteAttributesSchema = v.picklist([
849
- "preserve",
850
- "single",
851
- "double"
852
- ]);
853
- const EmbeddedLanguageFormattingSchema = v.picklist(["off", "auto"]);
854
- const JsonParserSchema = v.picklist([
855
- "json",
856
- "jsonc",
857
- "json5",
858
- "json-stringify"
859
- ]);
860
- const SharedConfigSchema = v.object({
861
- printWidth: v.number(),
862
- tabWidth: v.number(),
863
- useTabs: v.boolean(),
864
- endOfLine: EndOfLineSchema
865
- });
866
- const HtmlConfigSchema = v.object({
867
- ...SharedConfigSchema.entries,
868
- parser: v.literal("html"),
869
- bracketSameLine: v.boolean(),
870
- singleAttributePerLine: v.boolean(),
871
- htmlWhitespaceSensitivity: HtmlWhitespaceSensitivitySchema,
872
- proseWrap: ProseWrapSchema,
873
- embeddedLanguageFormatting: EmbeddedLanguageFormattingSchema
874
- });
875
- const XmlConfigSchema = v.object({
876
- ...SharedConfigSchema.entries,
877
- bracketSameLine: v.boolean(),
878
- singleAttributePerLine: v.boolean(),
879
- xmlWhitespaceSensitivity: XmlWhitespaceSensitivitySchema,
880
- xmlQuoteAttributes: XmlQuoteAttributesSchema,
881
- xmlSelfClosingSpace: v.boolean(),
882
- xmlSortAttributesByKey: v.boolean()
883
- });
884
- const JsonConfigSchema = v.object({
885
- ...SharedConfigSchema.entries,
886
- parser: JsonParserSchema
887
- });
888
- const HtmlOverridesSchema = v.partial(HtmlConfigSchema);
889
- const XmlOverridesSchema = v.partial(XmlConfigSchema);
890
- const JsonOverridesSchema = v.partial(JsonConfigSchema);
891
- const sharedDefaults = {
892
- printWidth: 80,
893
- tabWidth: 2,
894
- useTabs: false,
895
- endOfLine: "lf"
896
- };
897
- const htmlDefaults = {
898
- ...sharedDefaults,
899
- parser: "html",
900
- bracketSameLine: false,
901
- singleAttributePerLine: false,
902
- htmlWhitespaceSensitivity: "css",
903
- proseWrap: "preserve",
904
- embeddedLanguageFormatting: "auto"
905
- };
906
- const xmlDefaults = {
907
- ...sharedDefaults,
908
- bracketSameLine: false,
909
- singleAttributePerLine: false,
910
- xmlWhitespaceSensitivity: "strict",
911
- xmlQuoteAttributes: "double",
912
- xmlSelfClosingSpace: true,
913
- xmlSortAttributesByKey: true
914
- };
915
- const jsonDefaultsByParser = {
916
- json: {
917
- ...sharedDefaults,
918
- parser: "json"
919
- },
920
- jsonc: {
921
- ...sharedDefaults,
922
- parser: "jsonc"
923
- },
924
- json5: {
925
- ...sharedDefaults,
926
- parser: "json5"
927
- },
928
- "json-stringify": {
929
- ...sharedDefaults,
930
- parser: "json-stringify"
931
- }
932
- };
933
- function buildPrettierConfigHTML(overrides) {
934
- const safeOverrides = v.parse(HtmlOverridesSchema, overrides);
935
- return v.parse(HtmlConfigSchema, {
936
- ...htmlDefaults,
937
- ...safeOverrides,
938
- parser: "html"
939
- });
940
- }
941
- function buildPrettierConfigXML(overrides) {
942
- const safeOverrides = v.parse(XmlOverridesSchema, overrides);
943
- return v.parse(XmlConfigSchema, {
944
- ...xmlDefaults,
945
- ...safeOverrides
946
- });
947
- }
948
- function buildPrettierConfigJSON(fileType, overrides) {
949
- const safeOverrides = v.parse(JsonOverridesSchema, overrides);
950
- return v.parse(JsonConfigSchema, {
951
- ...jsonDefaultsByParser[fileType],
952
- ...safeOverrides,
953
- parser: fileType
954
- });
955
- }
956
- //#endregion
957
- //#region src/schemas/formatter.schemas.ts
958
- const FORMATTER_TEXT_MAX_LENGTH = 5e4;
959
- const formatterModeOptions = [
960
- {
961
- label: "HTML Formatter",
962
- value: "html"
963
- },
964
- {
965
- label: "XML Formatter",
966
- value: "xml"
967
- },
968
- {
969
- label: "JSON Formatter",
970
- value: "json"
971
- }
972
- ];
973
- const formatterModeValues = formatterModeOptions.map((option) => option.value);
974
- const SFormatterMode = v.picklist(formatterModeValues);
975
- const indentLevelOptions = [
976
- {
977
- label: "2 Spaces Indent",
978
- value: "TWO_SPACES",
979
- description: "prettifies input text with 2 spaces indent"
980
- },
981
- {
982
- label: "3 Spaces Indent",
983
- value: "THREE_SPACES",
984
- description: "prettifies input text with 3 spaces indent"
985
- },
986
- {
987
- label: "4 Spaces Indent",
988
- value: "FOUR_SPACES",
989
- description: "prettifies input text with 4 spaces indent"
990
- },
991
- {
992
- label: "Tab Delimited Indent",
993
- value: "TAB",
994
- description: "prettifies input text with tab delimited indent"
995
- },
996
- {
997
- label: "Compact Mode",
998
- value: "COMPACT",
999
- description: "removes all unnecessary whitespace, including newlines and tabs"
1000
- }
1001
- ];
1002
- const indentLevelValues = indentLevelOptions.map((option) => option.value);
1003
- const SIndentLevel = v.optional(v.picklist(indentLevelValues), "TWO_SPACES");
1004
- const SContentText = v.optional(v.pipe(v.string(), v.trim(), v.maxLength(FORMATTER_TEXT_MAX_LENGTH, `Text cannot exceed ${FORMATTER_TEXT_MAX_LENGTH.toLocaleString()} characters. Please upload a file instead if your content exceeds this limit.`)));
1005
- const HTMLMimeTypes = ["text/html", "application/xhtml+xml"];
1006
- const XMLMimeTypes = [
1007
- "text/xml",
1008
- "application/xml",
1009
- "application/rss+xml",
1010
- "application/atom+xml"
1011
- ];
1012
- const JSONMimeTypes = [
1013
- "text/json",
1014
- "application/json",
1015
- "application/ld+json",
1016
- "application/json5",
1017
- "application/x-ndjson",
1018
- "application/jsonlines"
1019
- ];
1020
- const TXTMimeTypes = ["text/plain", "application/octet-stream"];
1021
- const allowedMimeTypes = [
1022
- ...HTMLMimeTypes,
1023
- ...XMLMimeTypes,
1024
- ...JSONMimeTypes,
1025
- ...TXTMimeTypes
1026
- ];
1027
- const SContentFile = v.optional(v.pipe(v.file("Please upload a file."), v.maxSize(2 * 1024 * 1024, "File must be smaller than 2 MB."), v.mimeType(allowedMimeTypes, "Please upload a valid file: text, HTML, XML, or JSON.")));
1028
- const SFormatterForm = v.pipe(v.object({
1029
- formatter_mode: SFormatterMode,
1030
- chars_per_line: v.optional(v.number()),
1031
- indent_level: SIndentLevel,
1032
- text_content: SContentText,
1033
- files: SContentFile
1034
- }), v.check((input) => !!(input.text_content || input.files), "You must provide text content or a text file."));
1035
- const SFormatterRequest = v.pipe(v.object({
1036
- formatter_mode: SFormatterMode,
1037
- chars_per_line: v.optional(v.number()),
1038
- indent_level: SIndentLevel,
1039
- content: v.string(),
1040
- content_type: v.picklist(["text", "file"], "Please select a content type."),
1041
- prettier_parser: v.picklist([
1042
- "html",
1043
- "xml",
1044
- "json",
1045
- "jsonc",
1046
- "json5"
1047
- ], "Please select a prettier parser.")
1048
- }));
1049
- //#endregion
1050
- //#region src/schemas/gcflytour-snap.schemas.ts
1051
- const GCFlyTourSnapSortKeys = [
1052
- "id",
1053
- "title",
1054
- "slug",
1055
- "is_active",
1056
- "is_hidden",
1057
- "createdAt",
1058
- "updatedAt"
1059
- ];
1060
- const QuerySortGCFlyTourSnaps = v.optional(v.pipe(v.array(v.picklist(GCFlyTourSnapSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(GCFlyTourSnapSortKeys.length)));
1061
- const QueryStrapiSearchGCFlyTourSnaps = v.object({
1062
- page: VPage(),
1063
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1064
- title: v.optional(VStringMax()),
1065
- slug: v.optional(VStringMax()),
1066
- is_active: v.optional(v.boolean()),
1067
- is_hidden: v.optional(v.boolean()),
1068
- gcflytour: v.optional(VStringMinMax(1, 255)),
1069
- gcflytours: v.optional(SQueryManyEntities),
1070
- sort: QuerySortGCFlyTourSnaps
1071
- });
1072
- const SCreateGCFlyTourSnapDocument = v.object({
1073
- title: VStringMinMax(1, 255),
1074
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1075
- description: v.optional(v.nullable(VStringMax(255))),
1076
- is_active: v.boolean(),
1077
- is_hidden: v.boolean(),
1078
- gcflytour: v.optional(SAssociateOneEntity)
1079
- });
1080
- const SUpdateGCFlyTourSnapDocument = v.object({
1081
- title: v.optional(VStringMinMax(1, 255)),
1082
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1083
- description: v.optional(v.nullable(VStringMax(255))),
1084
- is_active: v.optional(v.boolean()),
1085
- is_hidden: v.optional(v.boolean()),
1086
- gcflytour: v.optional(SAssociateOneEntity)
1087
- });
1088
- const SUpdateGCFlyTourSnapDocumentRequest = v.object({
1089
- documentId: SAssociateOneEntity,
1090
- data: SUpdateGCFlyTourSnapDocument
1091
- });
1092
- //#endregion
1093
- //#region src/schemas/gcflytour.schemas.ts
1094
- const GCFlyTourSortKeys = [
1095
- "id",
1096
- "title",
1097
- "slug",
1098
- "is_active",
1099
- "is_hidden",
1100
- "createdAt",
1101
- "updatedAt"
1102
- ];
1103
- const QuerySortGCFlyTours = v.optional(v.pipe(v.array(v.picklist(GCFlyTourSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(GCFlyTourSortKeys.length)));
1104
- const QueryStrapiSearchGCFlyTours = v.object({
1105
- page: VPage(),
1106
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1107
- title: v.optional(VStringMax()),
1108
- slug: v.optional(VStringMax()),
1109
- is_active: v.optional(v.boolean()),
1110
- is_hidden: v.optional(v.boolean()),
1111
- clients: v.optional(SQueryManyEntities),
1112
- sort: QuerySortGCFlyTours
1113
- });
1114
- const SCreateGCFlyTourDocument = v.object({
1115
- title: VStringMinMax(1, 255),
1116
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1117
- description: v.optional(v.nullable(VStringMax(255))),
1118
- is_active: v.boolean(),
1119
- is_hidden: v.boolean(),
1120
- clients: v.optional(SAssociateManyEntities),
1121
- gcflytour_snaps: v.optional(SAssociateManyEntities)
1122
- });
1123
- const SUpdateGCFlyTourDocument = v.object({
1124
- title: v.optional(VStringMinMax(1, 255)),
1125
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1126
- description: v.optional(v.nullable(VStringMax(255))),
1127
- is_active: v.optional(v.boolean()),
1128
- is_hidden: v.optional(v.boolean()),
1129
- clients: v.optional(SAssociateManyEntities),
1130
- gcflytour_snaps: v.optional(SAssociateManyEntities)
1131
- });
1132
- const SUpdateGCFlyTourDocumentRequest = v.object({
1133
- documentId: SAssociateOneEntity,
1134
- data: SUpdateGCFlyTourDocument
1135
- });
1136
- //#endregion
1137
- //#region src/schemas/lead.schemas.ts
1138
- const SCreateLeadDocument = v.object({
1139
- first_name: VStringMinMax(1, 255),
1140
- last_name: VStringMinMax(1, 255),
1141
- email: VStringEmail(),
1142
- phone: VStringPhone(),
1143
- company: VStringMinMax(1, 255),
1144
- title: VStringMinMax(1, 255),
1145
- message: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1146
- product_interest: VStringMax(255),
1147
- email_consent: v.boolean(),
1148
- sms_consent: v.boolean(),
1149
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1150
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1151
- });
1152
- const SUpdateLeadDocument = v.object({
1153
- first_name: v.optional(VStringMinMax(1, 255)),
1154
- last_name: v.optional(VStringMinMax(1, 255)),
1155
- email: v.optional(VStringEmail()),
1156
- phone: v.optional(VStringPhone()),
1157
- company: v.optional(VStringMinMax(1, 255)),
1158
- title: v.optional(VStringMinMax(1, 255)),
1159
- message: v.optional(VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)),
1160
- product_interest: v.optional(v.nullable(VStringMax(255))),
1161
- email_consent: v.optional(v.boolean()),
1162
- sms_consent: v.optional(v.boolean()),
1163
- on_page: v.optional(VStringMax(LIMIT_MAX_DESTINATION)),
1164
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1165
- });
1166
- const SUpdateLeadRequest = v.object({
1167
- documentId: SAssociateOneEntity,
1168
- data: SUpdateLeadDocument
1169
- });
1170
- //#endregion
1171
- //#region src/schemas/media-content-type.schemas.ts
1172
- const MediaContentTypeSortKeys = [
1173
- "id",
1174
- "title",
1175
- "slug",
1176
- "is_active",
1177
- "is_organic_social",
1178
- "is_paid_media",
1179
- "createdAt",
1180
- "updatedAt",
1181
- "media_platforms.title",
1182
- "media_platforms.slug",
1183
- "media_platforms.utm_key",
1184
- "media_platforms.is_active",
1185
- "media_platforms.is_organic_social",
1186
- "media_platforms.is_paid_media",
1187
- "media_platforms.createdAt",
1188
- "media_platforms.updatedAt",
1189
- "media_creative_formats.title",
1190
- "media_creative_formats.slug",
1191
- "media_creative_formats.is_active",
1192
- "media_creative_formats.createdAt",
1193
- "media_creative_formats.updatedAt"
1194
- ];
1195
- const QuerySortMediaContentType = v.optional(v.pipe(v.array(v.picklist(MediaContentTypeSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(MediaContentTypeSortKeys.length)));
1196
- const QueryStrapiSearchMediaContentTypes = v.object({
1197
- page: VPage(),
1198
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1199
- title: v.optional(VStringMax()),
1200
- slug: v.optional(VStringMax()),
1201
- is_active: v.optional(v.boolean()),
1202
- is_organic_social: v.optional(v.boolean()),
1203
- is_paid_media: v.optional(v.boolean()),
1204
- media_platforms: v.optional(SQueryManyEntities),
1205
- media_creative_formats: v.optional(SQueryManyEntities),
1206
- sort: QuerySortMediaContentType
1207
- });
1208
- const SCreateMediaContentTypeDocument = v.object({
1209
- title: VStringMinMax(1, 255),
1210
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1211
- is_active: v.boolean(),
1212
- is_organic_social: v.boolean(),
1213
- is_paid_media: v.boolean(),
1214
- description: v.optional(v.nullable(VStringMax(255))),
1215
- media_platforms: v.optional(SAssociateManyEntities),
1216
- media_creative_formats: v.optional(SAssociateManyEntities)
1217
- });
1218
- const SUpdateMediaContentTypeDocument = v.object({
1219
- title: v.optional(VStringMinMax(1, 255)),
1220
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1221
- is_active: v.optional(v.boolean()),
1222
- is_organic_social: v.optional(v.boolean()),
1223
- is_paid_media: v.optional(v.boolean()),
1224
- description: v.optional(v.nullable(VStringMax(255))),
1225
- media_platforms: v.optional(SAssociateManyEntities),
1226
- media_creative_formats: v.optional(SAssociateManyEntities)
1227
- });
1228
- const SUpdateMediaContentTypeDocumentRequest = v.object({
1229
- documentId: SAssociateOneEntity,
1230
- data: SUpdateMediaContentTypeDocument
1231
- });
1232
- //#endregion
1233
- //#region src/schemas/media-creative-format.schemas.ts
1234
- const MediaCreativeFormatSortKeys = [
1235
- "id",
1236
- "title",
1237
- "slug",
1238
- "is_active",
1239
- "createdAt",
1240
- "updatedAt",
1241
- "media_content_types.title",
1242
- "media_content_types.slug",
1243
- "media_content_types.is_active",
1244
- "media_content_types.is_organic_social",
1245
- "media_content_types.is_paid_media",
1246
- "media_content_types.createdAt",
1247
- "media_content_types.updatedAt"
1248
- ];
1249
- const QuerySortMediaCreativeFormat = v.optional(v.pipe(v.array(v.picklist(MediaCreativeFormatSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(MediaCreativeFormatSortKeys.length)));
1250
- const QueryStrapiSearchMediaCreativeFormats = v.object({
1251
- page: VPage(),
1252
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1253
- title: v.optional(VStringMax()),
1254
- slug: v.optional(VStringMax()),
1255
- is_active: v.optional(v.boolean()),
1256
- media_content_types: v.optional(SQueryManyEntities),
1257
- sort: QuerySortMediaCreativeFormat
1258
- });
1259
- const SCreateMediaCreativeFormatDocument = v.object({
1260
- title: VStringMinMax(1, 255),
1261
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1262
- is_active: v.boolean(),
1263
- description: v.optional(v.nullable(VStringMax(255))),
1264
- media_content_types: v.optional(SAssociateManyEntities)
1265
- });
1266
- const SUpdateMediaCreativeFormatDocument = v.object({
1267
- title: v.optional(VStringMinMax(1, 255)),
1268
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1269
- is_active: v.optional(v.boolean()),
1270
- description: v.optional(v.nullable(VStringMax(255))),
1271
- media_content_types: v.optional(SAssociateManyEntities)
1272
- });
1273
- const SUpdateMediaCreativeFormatDocumentRequest = v.object({
1274
- documentId: SAssociateOneEntity,
1275
- data: SUpdateMediaCreativeFormatDocument
1276
- });
1277
- //#endregion
1278
- //#region src/schemas/media-medium.schemas.ts
1279
- const MediaMediumSortKeys = [
1280
- "id",
1281
- "title",
1282
- "slug",
1283
- "is_active",
1284
- "is_organic_social",
1285
- "is_paid_media",
1286
- "createdAt",
1287
- "updatedAt",
1288
- "media_platforms.title",
1289
- "media_platforms.slug",
1290
- "media_platforms.utm_key",
1291
- "media_platforms.is_active",
1292
- "media_platforms.is_organic_social",
1293
- "media_platforms.is_paid_media",
1294
- "media_platforms.createdAt",
1295
- "media_platforms.updatedAt"
1296
- ];
1297
- const QuerySortMediaMedium = v.optional(v.pipe(v.array(v.picklist(MediaMediumSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(MediaMediumSortKeys.length)));
1298
- const QueryStrapiSearchMediaMediums = v.object({
1299
- page: VPage(),
1300
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1301
- title: v.optional(VStringMax()),
1302
- slug: v.optional(VStringMax()),
1303
- is_active: v.optional(v.boolean()),
1304
- is_organic_social: v.optional(v.boolean()),
1305
- is_paid_media: v.optional(v.boolean()),
1306
- media_platforms: v.optional(SQueryManyEntities),
1307
- sort: QuerySortMediaMedium
1308
- });
1309
- const SCreateMediaMediumDocument = v.object({
1310
- title: VStringMinMax(1, 255),
1311
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1312
- is_active: v.boolean(),
1313
- is_organic_social: v.boolean(),
1314
- is_paid_media: v.boolean(),
1315
- description: v.optional(v.nullable(VStringMax(255))),
1316
- media_platforms: v.optional(SAssociateManyEntities)
1317
- });
1318
- const SUpdateMediaMediumDocument = v.object({
1319
- title: v.optional(VStringMinMax(1, 255)),
1320
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1321
- is_active: v.optional(v.boolean()),
1322
- is_organic_social: v.optional(v.boolean()),
1323
- is_paid_media: v.optional(v.boolean()),
1324
- description: v.optional(v.nullable(VStringMax(255))),
1325
- media_platforms: v.optional(SAssociateManyEntities)
1326
- });
1327
- const SUpdateMediaMediumDocumentRequest = v.object({
1328
- documentId: SAssociateOneEntity,
1329
- data: SUpdateMediaMediumDocument
1330
- });
1331
- //#endregion
1332
- //#region src/schemas/media-platform.schemas.ts
1333
- const MediaPlatformSortKeys = [
1334
- "id",
1335
- "title",
1336
- "slug",
1337
- "utm_key",
1338
- "is_active",
1339
- "is_organic_social",
1340
- "is_paid_media",
1341
- "createdAt",
1342
- "updatedAt",
1343
- "clients.title",
1344
- "clients.teamwork_id",
1345
- "clients.teamwork_name",
1346
- "clients.is_organic_social",
1347
- "clients.is_paid_media",
1348
- "clients.createdAt",
1349
- "clients.updatedAt",
1350
- "media_content_types.title",
1351
- "media_content_types.slug",
1352
- "media_content_types.is_active",
1353
- "media_content_types.is_organic_social",
1354
- "media_content_types.is_paid_media",
1355
- "media_content_types.createdAt",
1356
- "media_content_types.updatedAt",
1357
- "media_mediums.title",
1358
- "media_mediums.slug",
1359
- "media_mediums.is_active",
1360
- "media_mediums.is_organic_social",
1361
- "media_mediums.is_paid_media",
1362
- "media_mediums.createdAt",
1363
- "media_mediums.updatedAt"
1364
- ];
1365
- const QuerySortMediaPlatforms = v.optional(v.pipe(v.array(v.picklist(MediaPlatformSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(MediaPlatformSortKeys.length)));
1366
- const QueryStrapiSearchMediaPlatforms = v.object({
1367
- page: VPage(),
1368
- size: VSize(LIMIT_PAGINATION_MAX_SIZE),
1369
- title: v.optional(VStringMax()),
1370
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1371
- utm_key: v.optional(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1372
- is_active: v.optional(v.boolean()),
1373
- is_organic_social: v.optional(v.boolean()),
1374
- is_paid_media: v.optional(v.boolean()),
1375
- clients: v.optional(SQueryManyEntities),
1376
- media_content_types: v.optional(SQueryManyEntities),
1377
- media_mediums: v.optional(SQueryManyEntities),
1378
- sort: QuerySortMediaPlatforms
1379
- });
1380
- const SCreateMediaPlatformDocument = v.object({
1381
- title: VStringMinMax(1, 255),
1382
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1383
- utm_key: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG),
1384
- is_active: v.boolean(),
1385
- is_organic_social: v.boolean(),
1386
- is_paid_media: v.boolean(),
1387
- description: v.optional(v.nullable(VStringMax(255))),
1388
- clients: v.optional(SAssociateManyEntities),
1389
- media_content_types: v.optional(SAssociateManyEntities),
1390
- media_mediums: v.optional(SAssociateManyEntities)
1391
- });
1392
- const SUpdateMediaPlatformDocument = v.object({
1393
- title: v.optional(VStringMinMax(1, 255)),
1394
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1395
- utm_key: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)),
1396
- is_active: v.optional(v.boolean()),
1397
- is_organic_social: v.optional(v.boolean()),
1398
- is_paid_media: v.optional(v.boolean()),
1399
- description: v.optional(v.nullable(VStringMax(255))),
1400
- clients: v.optional(SAssociateManyEntities),
1401
- media_content_types: v.optional(SAssociateManyEntities),
1402
- media_mediums: v.optional(SAssociateManyEntities)
1403
- });
1404
- const SUpdateMediaPlatformDocumentRequest = v.object({
1405
- documentId: SAssociateOneEntity,
1406
- data: SUpdateMediaPlatformDocument
1407
- });
1408
- //#endregion
1409
- //#region src/schemas/monday-workspace.schemas.ts
1410
- const MondayWorkspaceSortKeys = [
1411
- "id",
1412
- "clients.title",
1413
- "clients.teamwork_name",
1414
- "title",
1415
- "workspace_id",
1416
- "createdAt",
1417
- "updatedAt"
1418
- ];
1419
- const QuerySortMondayWorkspaces = v.optional(v.pipe(v.array(v.picklist(MondayWorkspaceSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(MondayWorkspaceSortKeys.length)));
1420
- const QueryStrapiSearchMondayWorkspaces = v.object({
1421
- page: VPage(),
1422
- size: VSize(LIMIT_MONDAY_WORKSPACE_PAGINATION_MAX_SIZE),
1423
- title: v.optional(VStringMax()),
1424
- workspace_id: v.optional(VStringMax()),
1425
- clients: v.optional(SQueryManyEntities),
1426
- sort: QuerySortMondayWorkspaces
1427
- });
1428
- const SCreateMondayWorkspaceDocument = v.object({
1429
- title: VStringShort(),
1430
- workspace_id: VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
1431
- clients: v.optional(SAssociateManyEntities)
1432
- });
1433
- const SUpdateMondayWorkspaceDocument = v.object({
1434
- title: v.optional(VStringShort()),
1435
- workspace_id: v.optional(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1436
- clients: v.optional(SAssociateManyEntities)
1437
- });
1438
- const SUpdateMondayWorkspaceDocumentRequest = v.object({
1439
- documentId: SAssociateOneEntity,
1440
- data: SUpdateMondayWorkspaceDocument
1441
- });
1442
- //#endregion
1443
- //#region src/schemas/newsletter.schemas.ts
1444
- const SCreateNewsletterSignup = v.object({
1445
- first_name: VStringMinMax(1, 255),
1446
- last_name: VStringMinMax(1, 255),
1447
- email: VStringEmail(),
1448
- download_key: v.pipe(v.string(), v.trim(), v.maxLength(255)),
1449
- product_interest: v.pipe(v.string(ERROR_MESSAGE_ROBOT), v.trim(), v.maxLength(255)),
1450
- email_consent: v.boolean(),
1451
- sms_consent: v.boolean(),
1452
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1453
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1454
- middle_name: v.string()
1455
- });
1456
- const SCreateNewsletterSignupDocument = v.object({
1457
- first_name: VStringMinMax(1, 255),
1458
- last_name: VStringMinMax(1, 255),
1459
- email: VStringEmail(),
1460
- download_key: v.optional(v.nullable(VStringMax())),
1461
- product_interest: v.optional(v.nullable(VStringMax(255))),
1462
- email_consent: v.boolean(),
1463
- sms_consent: v.boolean(),
1464
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1465
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1466
- });
1467
- const SUpdateNewsletterSignupDocument = v.object({
1468
- first_name: v.optional(VStringMinMax(1, 255)),
1469
- last_name: v.optional(VStringMinMax(1, 255)),
1470
- email: v.optional(VStringEmail()),
1471
- download_key: v.optional(v.nullable(VStringMax())),
1472
- product_interest: v.optional(v.nullable(VStringMax(255))),
1473
- email_consent: v.optional(v.boolean()),
1474
- sms_consent: v.optional(v.boolean()),
1475
- on_page: v.optional(VStringMax(LIMIT_MAX_DESTINATION)),
1476
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1477
- });
1478
- const SUpdateNewsletterSignupRequest = v.object({
1479
- documentId: SAssociateOneEntity,
1480
- data: SUpdateNewsletterSignupDocument
1481
- });
1482
- //#endregion
1483
- //#region src/schemas/resume.schemas.ts
1484
- const checkIsValidUrlList = (input) => {
1485
- if (input === "") return true;
1486
- const urls = input.split(",");
1487
- if (urls.length > 0) {
1488
- const truthy = [];
1489
- for (let i = 0; i < urls.length; i++) {
1490
- const result = v.safeParse(v.pipe(v.string(), v.trim(), v.startsWith("http", ERROR_MESSAGE_URL_PREFIX), v.url(ERROR_MESSAGE_INVALID_URL)), urls[i]);
1491
- truthy.push(result.success);
1492
- }
1493
- return truthy.every((item) => item === true);
1494
- }
1495
- return false;
1496
- };
1497
- const SValidFileObject = v.object({
1498
- id: v.number(),
1499
- src: v.optional(v.string())
1500
- });
1501
- const SValidSocialProfiles = v.pipe(v.string(), v.trim(), v.maxLength(LIMIT_LONG_STRING_MAX_LENGTH), v.check(checkIsValidUrlList, ERROR_MESSAGE_COMMA_SEPPARATED_URLS));
1502
- const SCreateResume = v.object({
1503
- first_name: VStringMinMax(1, 255),
1504
- last_name: VStringMinMax(1, 255),
1505
- email: VStringEmail(),
1506
- phone: v.optional(VStringPhone()),
1507
- message: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1508
- social_profiles: v.optional(SValidSocialProfiles),
1509
- file: v.nullable(v.pipe(v.file("Please upload a PDF or Word document."), v.mimeType([
1510
- "application/pdf",
1511
- "application/msword",
1512
- "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
1513
- "application/rtf",
1514
- "text/plain",
1515
- "application/vnd.oasis.opendocument.text"
1516
- ], "Please upload a PDF or Word document."))),
1517
- email_consent: v.boolean(),
1518
- sms_consent: v.boolean(),
1519
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1520
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1521
- });
1522
- const SCreateResumeInfo = v.object({
1523
- first_name: VStringMinMax(1, 255),
1524
- last_name: VStringMinMax(1, 255),
1525
- email: VStringEmail(),
1526
- phone: v.optional(VStringPhone()),
1527
- message: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1528
- social_profiles: v.optional(SValidSocialProfiles),
1529
- file: SValidFileObject,
1530
- email_consent: v.boolean(),
1531
- sms_consent: v.boolean(),
1532
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1533
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1534
- });
1535
- const SCreateResumeInfoDocument = v.object({
1536
- first_name: VStringMinMax(1, 255),
1537
- last_name: VStringMinMax(1, 255),
1538
- email: VStringEmail(),
1539
- phone: VStringPhoneNullable(),
1540
- message: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1541
- social_profiles: v.optional(SValidSocialProfiles),
1542
- file: SValidFileObject,
1543
- email_consent: v.boolean(),
1544
- sms_consent: v.boolean(),
1545
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1546
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1547
- });
1548
- const SUpdateResumeInfo = v.object({
1549
- first_name: v.optional(VStringMinMax(1, 255)),
1550
- last_name: v.optional(VStringMinMax(1, 255)),
1551
- email: v.optional(VStringEmail()),
1552
- phone: VStringPhoneNullable(),
1553
- message: v.optional(VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)),
1554
- social_profiles: v.optional(v.nullable(v.optional(SValidSocialProfiles))),
1555
- file: v.optional(SValidFileObject),
1556
- email_consent: v.optional(v.boolean()),
1557
- sms_consent: v.optional(v.boolean()),
1558
- on_page: v.optional(VStringMax(LIMIT_MAX_DESTINATION)),
1559
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1560
- });
1561
- const SUpdateResumeInfoDocument = v.object({
1562
- first_name: v.optional(VStringMinMax(1, 255)),
1563
- last_name: v.optional(VStringMinMax(1, 255)),
1564
- email: v.optional(VStringEmail()),
1565
- phone: v.optional(VStringPhone()),
1566
- message: v.optional(VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)),
1567
- social_profiles: v.optional(v.optional(SValidSocialProfiles)),
1568
- file: v.optional(SValidFileObject),
1569
- email_consent: v.optional(v.boolean()),
1570
- sms_consent: v.optional(v.boolean()),
1571
- on_page: v.optional(VStringMax(LIMIT_MAX_DESTINATION)),
1572
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH)
1573
- });
1574
- const SUpdateResumeInfoRequest = v.object({
1575
- documentId: SAssociateOneEntity,
1576
- data: SUpdateResumeInfo
1577
- });
1578
- //#endregion
1579
- //#region src/schemas/sharpspring.schemas.ts
1580
- const SharpSpringSignUpToDownload = v.object({
1581
- first_name: VStringMinMax(1, 255),
1582
- last_name: VStringMinMax(1, 255),
1583
- email: VStringEmail(),
1584
- download_key: VStringMax(255),
1585
- email_consent: v.boolean(),
1586
- on_page: VStringMax(LIMIT_MAX_DESTINATION),
1587
- captcha: VStringMax(LIMIT_LONG_STRING_MAX_LENGTH),
1588
- middle_name: v.string()
1589
- });
1590
- //#endregion
1591
- //#region src/schemas/strapi-media-upload.schemas.ts
1592
- /**
1593
- * @documentation [Strapi Rest API Upload Files](https://docs.strapi.io/cms/api/rest/upload)
1594
- */
1595
- const SValidFileUpload10MB = v.pipe(v.file(), v.minSize(1), v.maxSize(10485760, `File size cannot exceed 10MB.`));
1596
- const SCreateStrapiMediaUploadDocument = v.object({
1597
- files: SValidFileUpload10MB,
1598
- ref: VStringMax(),
1599
- refId: VStringMinMax(1, 255),
1600
- field: VStringMax()
1601
- });
1602
- const SCreateMultipleStrapiMediaUploadDocument = v.object({
1603
- files: v.pipe(v.array(SValidFileUpload10MB), v.minLength(1)),
1604
- ref: VStringMax(),
1605
- refId: VStringMinMax(1, 255),
1606
- field: VStringMax()
1607
- });
1608
- const SUpdateStrapiMediaFileInfo = v.object({
1609
- name: VStringMinMax(1, 255),
1610
- alternativeText: v.optional(VStringMinMax(1, 255)),
1611
- caption: v.optional(VStringMinMax(1, 255))
1612
- });
1613
- //#endregion
1614
- //#region src/schemas/tag.schemas.ts
1615
- const TagSortKeys = [
1616
- "id",
1617
- "label",
1618
- "slug",
1619
- "createdAt",
1620
- "updatedAt"
1621
- ];
1622
- const QuerySortTags = v.optional(v.pipe(v.array(v.picklist(TagSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(TagSortKeys.length)));
1623
- const QueryStrapiSearchTags = v.object({
1624
- page: VPage(),
1625
- size: VSize(20),
1626
- label: v.optional(VStringMax()),
1627
- slug: v.optional(VStringMax()),
1628
- sort: QuerySortTags
1629
- });
1630
- const SCreateTagDocument = v.object({
1631
- label: VStringMinMax(1, 255),
1632
- slug: VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG)
1633
- });
1634
- const SUpdateTagDocument = v.object({
1635
- label: v.optional(VStringMinMax(1, 255)),
1636
- slug: v.optional(VStringMinMaxRegex(1, 255, REGEX_URL_SLUG, ERROR_MESSAGE_REGEX_URL_SLUG))
1637
- });
1638
- const SUpdateTagDocumentRequest = v.object({
1639
- documentId: SAssociateOneEntity,
1640
- data: SUpdateTagDocument
1641
- });
1642
- //#endregion
1643
- //#region src/schemas/team-member.schemas.ts
1644
- const TeamMemberSortKeys = [
1645
- "id",
1646
- "name",
1647
- "order",
1648
- "tier",
1649
- "group",
1650
- "is_employed",
1651
- "createdAt",
1652
- "updatedAt"
1653
- ];
1654
- const QuerySortTeamMembers = v.optional(v.pipe(v.array(v.picklist(TeamMemberSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(TeamMemberSortKeys.length)));
1655
- const QueryStrapiSearchTeamMembers = v.object({
1656
- page: VPage(),
1657
- size: VSize(20),
1658
- name: v.optional(VStringMax()),
1659
- slug: v.optional(VStringMax()),
1660
- order: VIntegerNullable(),
1661
- tier: v.optional(v.picklist([
1662
- "owner",
1663
- "manager",
1664
- "employee"
1665
- ])),
1666
- group: v.optional(v.picklist([
1667
- "account",
1668
- "media",
1669
- "creative"
1670
- ])),
1671
- is_employed: v.optional(v.boolean()),
1672
- sort: QuerySortTeamMembers
1673
- });
1674
- //#endregion
1675
- //#region src/schemas/teamwork.schemas.ts
1676
- const TeamworkProjectHealthSelectSortOptions = [{
1677
- label: "Name",
1678
- value: "name"
1679
- }, {
1680
- label: "Health",
1681
- value: "health"
1682
- }];
1683
- const TeamworkProjectHealthProjectStatusOptions = [
1684
- {
1685
- label: "Active",
1686
- value: "active",
1687
- description: "Projects that are currently active"
1688
- },
1689
- {
1690
- label: "Current",
1691
- value: "current",
1692
- description: "Projects that are currently ongoing"
1693
- },
1694
- {
1695
- label: "Late",
1696
- value: "late",
1697
- description: "Projects that are behind schedule"
1698
- },
1699
- {
1700
- label: "Upcoming",
1701
- value: "upcoming",
1702
- description: "Projects that are scheduled to start soon"
1703
- },
1704
- {
1705
- label: "Completed",
1706
- value: "completed",
1707
- description: "Projects that have been completed"
1708
- },
1709
- {
1710
- label: "Archived",
1711
- value: "archived",
1712
- description: "Projects that have been archived"
1713
- }
1714
- ];
1715
- const QuerySortTeamworkProjectHealth = v.optional(v.object({
1716
- key: v.picklist(TeamworkProjectHealthSelectSortOptions.map((option) => option.value)),
1717
- order: v.picklist(["ASC", "DESC"])
1718
- }));
1719
- const QueryStrapiSearchTeamworkProjectHealth = v.object({
1720
- page: VPage(),
1721
- size: VSize(100),
1722
- lastPeriodDays: VIntegerNullable(),
1723
- searchTerm: v.optional(VStringMax()),
1724
- excludeTagIds: v.optional(v.array(VStringMinMax(1, 255))),
1725
- includeArchivedProjects: v.optional(v.boolean()),
1726
- projectCategoryIds: v.optional(v.array(VStringMinMax(1, 255))),
1727
- projectCompanyIds: v.optional(v.array(VStringMinMax(1, 255))),
1728
- projectTagIds: v.optional(v.array(VStringMinMax(1, 255))),
1729
- projectHealths: v.optional(VStringMax()),
1730
- projectStatuses: v.optional(v.picklist(TeamworkProjectHealthProjectStatusOptions.map((option) => option.value)), TeamworkProjectHealthProjectStatusOptions[0].value),
1731
- sort: QuerySortTeamworkProjectHealth
1732
- });
1733
- //#endregion
1734
- //#region src/schemas/trend.schemas.ts
1735
- const SUpdateTrendsLikes = v.object({
1736
- documentId: SAssociateOneEntity,
1737
- likes: v.number()
1738
- });
1739
- //#endregion
1740
- //#region src/schemas/url-redirect.schemas.ts
1741
- const UrlRedirectSortKeys = [
1742
- "id",
1743
- "from",
1744
- "to",
1745
- "status_code",
1746
- "query_params",
1747
- "is_active",
1748
- "createdAt",
1749
- "updatedAt"
1750
- ];
1751
- const QuerySortUrlRedirects = v.optional(v.pipe(v.array(v.picklist(UrlRedirectSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(UrlRedirectSortKeys.length)));
1752
- const QueryStrapiPaginatedUrlRedirects = v.object({
1753
- page: v.fallback(v.optional(VPage(), 1), 1),
1754
- size: v.fallback(v.optional(v.pipe(v.number(), v.minValue(1), v.maxValue(20)), LIMIT_REDIRECT_PAGINATION_DEFAULT_SIZE), LIMIT_REDIRECT_PAGINATION_DEFAULT_SIZE),
1755
- sort: QuerySortUrlRedirects
1756
- });
1757
- const QueryStrapiUrlRedirectsByFrom = v.object({ from: v.string() });
1758
- //#endregion
1759
- //#region src/schemas/user-account.schemas.ts
1760
- const SReadUserAccountById = v.object({ id: v.number() });
1761
- const SReadUserAccountByDocumentId = v.object({ documentId: SAssociateOneEntity });
1762
- const SUpdateUserAccount = v.object({
1763
- documentId: SAssociateOneEntity,
1764
- first_name: VStringMinMax(1, 255),
1765
- last_name: VStringMinMax(1, 255),
1766
- preferred_name: v.nullable(VStringMinMax(1, 255))
1767
- });
1768
- const SUpdateUserAccountFirstName = v.object({
1769
- documentId: SAssociateOneEntity,
1770
- first_name: VStringMinMax(1, 255)
1771
- });
1772
- const SUpdateUserAccountLastName = v.object({
1773
- documentId: SAssociateOneEntity,
1774
- last_name: VStringMinMax(1, 255)
1775
- });
1776
- const SUpdateUserAccountPreferredName = v.object({
1777
- documentId: SAssociateOneEntity,
1778
- preferred_name: v.nullable(VStringMinMax(1, 255))
1779
- });
1780
- //#endregion
1781
- //#region src/schemas/user-auth.schemas.ts
1782
- const SUserToken = v.object({ token: v.string() });
1783
- const SLoginUser = v.object({
1784
- identifier: VStringEmail(),
1785
- password: VStringMinMax(8, 255)
1786
- });
1787
- const SRegisterUser = v.object({
1788
- username: VStringMinMaxRegex(3, 255, REGEX_UTM_VALUE, "username must be alphanumeric"),
1789
- email: VStringEmail(),
1790
- password: VStringMinMax(8, 255)
1791
- });
1792
- const SForgotUserPassword = v.object({ email: VStringEmail() });
1793
- const SRequestConfirmEmail = v.object({ email: VStringEmail() });
1794
- const SResetUserPassword = v.object({
1795
- password: VStringMinMax(8, 255),
1796
- passwordConfirmation: VStringMinMax(8, 255),
1797
- code: v.string()
1798
- });
1799
- const SChangePassword = v.pipe(v.object({
1800
- currentPassword: VStringMinMax(8, 255),
1801
- password: VStringMinMax(8, 255),
1802
- passwordConfirmation: VStringMinMax(8, 255)
1803
- }), v.forward(v.partialCheck([["password"], ["passwordConfirmation"]], (input) => input.password === input.passwordConfirmation, "Your new passwords do not match."), ["passwordConfirmation"]));
1804
- const SAuthRawAccessToken = v.object({
1805
- access_token: v.optional(v.string()),
1806
- expires_in: VIntegerNullable(),
1807
- scope: v.optional(v.string()),
1808
- token_type: v.optional(v.string()),
1809
- id_token: v.optional(v.string())
1810
- });
1811
- const SAuthConnectProviderRedirectSearch = v.object({
1812
- id_token: v.string(),
1813
- access_token: v.string(),
1814
- raw: v.optional(SAuthRawAccessToken)
1815
- });
1816
- const SAuthConnectProviderConfirmation = v.object({
1817
- provider: v.string(),
1818
- search: SAuthConnectProviderRedirectSearch
1819
- });
1820
- //#endregion
1821
- //#region src/schemas/user.schemas.ts
1822
- const UserSortKeys = [
1823
- "id",
1824
- "username",
1825
- "email",
1826
- "confirmed",
1827
- "blocked",
1828
- "createdAt",
1829
- "updatedAt"
1830
- ];
1831
- const QuerySortUsers = v.optional(v.pipe(v.array(v.picklist(UserSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(UserSortKeys.length)));
1832
- const QueryStrapiUsers = v.object({
1833
- page: VPage(),
1834
- size: VSize(10),
1835
- sort: QuerySortUsers
1836
- });
1837
- const QueryStrapiUsersByIdentifier = v.object({
1838
- identifier: VStringShort(0),
1839
- page: VPage(),
1840
- size: VSize(10)
1841
- });
1842
- const SCreateUserDocument = v.object({
1843
- username: VStringMinMaxRegex(3, 255, REGEX_UTM_VALUE, "username must be alphanumeric"),
1844
- email: VStringEmail(),
1845
- password: VStringMinMax(8, 255),
1846
- blocked: v.boolean(),
1847
- confirmed: v.boolean(),
1848
- role: v.number()
1849
- });
1850
- //#endregion
1851
- //#region src/schemas/utm-link-builder.schemas.ts
1852
- const SUtmLinkBuilderPartCampaignDateOptions = [
1853
- "annually",
1854
- "quarterly",
1855
- "monthly",
1856
- "on a specific date",
1857
- "no date"
1858
- ];
1859
- const SUtmLinkBuilderCampaign = v.object({
1860
- campaign_phase: VStringMinMax(1, 255),
1861
- campaign_product: v.optional(VStringMax()),
1862
- campaign_targeting: v.optional(v.pipe(v.array(VStringMaxRegex(255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)), v.maxLength(10))),
1863
- campaign_key: v.optional(VStringMaxRegex(255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1864
- campaign_date: v.object({
1865
- format: v.picklist(SUtmLinkBuilderPartCampaignDateOptions),
1866
- value: v.object({
1867
- year: v.number(),
1868
- quarter: VIntegerNullable(),
1869
- month: VIntegerNullable(),
1870
- day: VIntegerNullable()
1871
- })
1872
- })
1873
- });
1874
- const SUtmLinkBuilderCreativeFormat = v.object({
1875
- creative_format: v.optional(VStringMax(255)),
1876
- creative_format_variants: v.optional(v.array(VStringMax(255))),
1877
- creative_size: v.optional(v.object({
1878
- width: VIntegerNullable(),
1879
- height: VIntegerNullable(),
1880
- key: v.optional(VStringMax(255))
1881
- }))
1882
- });
1883
- const SUtmLinkBuilderTableForm = v.object({
1884
- creator: SAssociateOneEntity,
1885
- client: SAssociateOneEntity,
1886
- variants: v.pipe(v.array(v.object({
1887
- url_destinations: v.pipe(v.array(v.object({ url: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1888
- if (input === "") return false;
1889
- return input.indexOf("?") === -1;
1890
- }, ERROR_MESSAGE_URL_NO_QUERY_PARAMS)) })), v.minLength(1), v.maxLength(100)),
1891
- source: VStringMax(255),
1892
- mediums: v.pipe(v.array(VStringMax(255)), v.minLength(1), v.maxLength(10)),
1893
- campaign: SUtmLinkBuilderCampaign,
1894
- content: v.optional(VStringMax(255)),
1895
- creative_formats: v.optional(v.pipe(v.array(SUtmLinkBuilderCreativeFormat), v.maxLength(10))),
1896
- id: v.optional(VStringMinMax(1, 255))
1897
- })), v.minLength(1), v.maxLength(10)),
1898
- notes: v.optional(VStringMax())
1899
- });
1900
- const SUtmLinkBuilderSingleForm = v.object({
1901
- creator: SAssociateOneEntity,
1902
- client: SAssociateOneEntity,
1903
- url_destination: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1904
- if (input === "") return false;
1905
- return input.indexOf("?") === -1;
1906
- }, ERROR_MESSAGE_URL_NO_QUERY_PARAMS)),
1907
- source: VStringMax(255),
1908
- medium: VStringMax(255),
1909
- campaign: SUtmLinkBuilderCampaign,
1910
- content: v.optional(VStringMax(255)),
1911
- creative_format: v.optional(SUtmLinkBuilderCreativeFormat),
1912
- id: v.optional(VStringMinMax(1, 255)),
1913
- url: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1914
- return input.includes("utm_");
1915
- }, ERROR_MESSAGE_UTM_URL)),
1916
- notes: v.optional(VStringMax())
1917
- });
1918
- //#endregion
1919
- //#region src/schemas/utm-tracking-link.schemas.ts
1920
- const UtmTrackingLinkSortKeys = [
1921
- "id",
1922
- "creator",
1923
- "client",
1924
- "url_destination",
1925
- "utm_medium",
1926
- "utm_source",
1927
- "utm_campaign",
1928
- "utm_content",
1929
- "utm_creative_format",
1930
- "utm_id",
1931
- "campaign_phase",
1932
- "campaign_product",
1933
- "campaign_targeting",
1934
- "campaign_key",
1935
- "creative_format",
1936
- "creative_format_variants",
1937
- "url",
1938
- "is_active",
1939
- "createdAt",
1940
- "updatedAt"
1941
- ];
1942
- const QuerySortUtmTrackingLinks = v.optional(v.pipe(v.array(v.picklist(UtmTrackingLinkSortKeys.flatMap((k) => [`${k}:ASC`, `${k}:DESC`]))), v.maxLength(UtmTrackingLinkSortKeys.length)));
1943
- const QueryStrapiSearchUtmTrackingLinks = v.object({
1944
- page: VPage(),
1945
- size: VSize(LIMIT_UTM_TRACKING_LINK_PAGINATION_MAX_SIZE),
1946
- client_id: v.optional(VStringShort()),
1947
- creator_id: v.optional(VStringShort()),
1948
- clients: v.optional(SQueryManyEntities),
1949
- users: v.optional(SQueryManyEntities),
1950
- url_destination: v.optional(v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1951
- if (input === "") return false;
1952
- return input.indexOf("?") === -1;
1953
- }, ERROR_MESSAGE_URL_NO_QUERY_PARAMS))),
1954
- utm_medium: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_MEDIUM, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1955
- utm_source: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_SOURCE, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1956
- utm_campaign: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_CAMPAIGN, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1957
- utm_content: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_CONTENT, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1958
- utm_creative_format: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_CREATIVE_FORMAT, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1959
- utm_id: v.optional(VStringMinMaxRegex(1, LIMIT_MAX_UTM_ID, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
1960
- campaign_phase: v.optional(VStringShort(0)),
1961
- campaign_product: v.optional(VStringShort(0)),
1962
- campaign_targeting: v.optional(VStringShort(0)),
1963
- campaign_key: v.optional(VStringShort(0)),
1964
- creative_format: v.optional(VStringShort(0)),
1965
- creative_format_variants: v.optional(v.array(VStringShort())),
1966
- url: v.optional(v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1967
- return input.includes("utm_");
1968
- }, ERROR_MESSAGE_UTM_URL))),
1969
- is_active: v.optional(v.boolean()),
1970
- notes: v.optional(VStringShort(0)),
1971
- sort: QuerySortUtmTrackingLinks
1972
- });
1973
- const SCreateUtmTrackingLinkDocument = v.object({
1974
- creator: VStringShort(),
1975
- client: VStringShort(),
1976
- url_destination: VStringUrlNoUtm(),
1977
- utm_source: VStringMinMaxRegex(1, LIMIT_MAX_UTM_SOURCE, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
1978
- utm_medium: VStringMinMaxRegex(1, LIMIT_MAX_UTM_MEDIUM, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
1979
- utm_campaign: VStringMinMaxRegex(1, LIMIT_MAX_UTM_CAMPAIGN, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
1980
- utm_content: VStringShortNullable(),
1981
- utm_creative_format: VStringShortNullable(),
1982
- utm_id: VStringShortNullable(),
1983
- campaign_phase: VStringShort(),
1984
- campaign_product: VStringShortNullable(),
1985
- campaign_targeting: v.optional(v.nullable(v.pipe(v.array(VStringMax()), v.transform((value) => value.join(","))))),
1986
- campaign_key: v.optional(v.nullable(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE))),
1987
- creative_format: VStringShortNullable(),
1988
- creative_format_variants: v.optional(v.nullable(v.pipe(v.array(VStringMax()), v.transform((value) => value.join(","))))),
1989
- url: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
1990
- return input.includes("utm_");
1991
- }, ERROR_MESSAGE_UTM_URL)),
1992
- is_active: v.boolean(),
1993
- notes: VStringLongNullable()
1994
- });
1995
- const SCreateUtmTrackingLinkDocumentRequest = v.object({
1996
- creator: VStringShort(),
1997
- client: VStringShort(),
1998
- url_destination: VStringUrlNoUtm(),
1999
- utm_source: VStringMinMaxRegex(1, LIMIT_MAX_UTM_SOURCE, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2000
- utm_medium: VStringMinMaxRegex(1, LIMIT_MAX_UTM_MEDIUM, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2001
- utm_campaign: VStringMinMaxRegex(1, LIMIT_MAX_UTM_CAMPAIGN, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2002
- utm_content: v.optional(v.nullable(VStringMinMax(1, 255))),
2003
- utm_creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2004
- utm_id: v.optional(v.nullable(VStringMinMax(1, 255))),
2005
- campaign_phase: VStringShort(),
2006
- campaign_product: v.optional(v.nullable(VStringMinMax(1, 255))),
2007
- campaign_targeting: VStringShortNullable(),
2008
- campaign_key: v.optional(v.nullable(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE))),
2009
- creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2010
- creative_format_variants: VStringShortNullable(),
2011
- url: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
2012
- return input.includes("utm_");
2013
- }, ERROR_MESSAGE_UTM_URL)),
2014
- is_active: v.boolean(),
2015
- notes: v.optional(v.nullable(VStringMinMaxRegex(1, LIMIT_LONG_STRING_MAX_LENGTH, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)))
2016
- });
2017
- const SCreateUtmTrackingLinkParts = v.object({
2018
- url_destination: VStringUrlNoUtm(),
2019
- utm_source: VStringMinMaxRegex(1, LIMIT_MAX_UTM_SOURCE, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2020
- utm_medium: VStringMinMaxRegex(1, LIMIT_MAX_UTM_MEDIUM, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2021
- utm_campaign: VStringMinMaxRegex(1, LIMIT_MAX_UTM_CAMPAIGN, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2022
- utm_content: v.optional(v.nullable(VStringMinMax(1, 255))),
2023
- utm_creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2024
- utm_id: v.optional(v.nullable(VStringMinMax(1, 255))),
2025
- campaign_phase: VStringShort(),
2026
- campaign_product: v.optional(v.nullable(VStringMinMax(1, 255))),
2027
- campaign_targeting: v.optional(v.nullable(v.pipe(v.array(VStringShort()), v.transform((value) => value.join(","))))),
2028
- campaign_key: v.optional(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)),
2029
- creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2030
- creative_format_variants: v.optional(v.nullable(v.pipe(v.array(VStringShort()), v.transform((value) => value.join(","))))),
2031
- url: VStringUrlUtm(),
2032
- is_active: v.boolean(),
2033
- notes: v.optional(v.nullable(VStringMinMaxRegex(1, LIMIT_LONG_STRING_MAX_LENGTH, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)))
2034
- });
2035
- const SFormCreateMultipleUtmTrackingLinkDocuments = v.object({
2036
- creator: VStringShort(),
2037
- client: VStringShort(),
2038
- links: v.pipe(v.array(SCreateUtmTrackingLinkParts), v.minLength(1), v.maxLength(100))
2039
- });
2040
- const SReadUtmTrackingLinkDocumentByUrl = v.object({ url: v.pipe(v.string(), v.trim(), v.url(ERROR_MESSAGE_INVALID_URL), v.check((input) => {
2041
- return input.includes("utm_");
2042
- }, ERROR_MESSAGE_UTM_URL)) });
2043
- const SUpdateUtmTrackingLinkDocument = v.object({
2044
- creator: v.optional(VStringShort()),
2045
- client: v.optional(VStringShort()),
2046
- url_destination: VStringUrlNoUtm(),
2047
- utm_source: VStringMinMaxRegex(1, LIMIT_MAX_UTM_SOURCE, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2048
- utm_medium: VStringMinMaxRegex(1, LIMIT_MAX_UTM_MEDIUM, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2049
- utm_campaign: VStringMinMaxRegex(1, LIMIT_MAX_UTM_CAMPAIGN, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE),
2050
- utm_content: v.optional(v.nullable(VStringMinMax(1, 255))),
2051
- utm_creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2052
- utm_id: v.optional(v.nullable(VStringMinMax(1, 255))),
2053
- campaign_phase: VStringShort(),
2054
- campaign_product: v.optional(v.nullable(VStringMinMax(1, 255))),
2055
- campaign_targeting: v.optional(v.nullable(v.pipe(v.array(VStringShort()), v.transform((value) => value.join(","))))),
2056
- campaign_key: v.optional(v.nullable(VStringMinMaxRegex(1, 255, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE))),
2057
- creative_format: v.optional(v.nullable(VStringMinMax(1, 255))),
2058
- creative_format_variants: v.optional(v.nullable(v.pipe(v.array(SAssociateOneEntity), v.transform((value) => value.join(","))))),
2059
- url: VStringUrlUtm(),
2060
- is_active: v.boolean(),
2061
- notes: v.optional(v.nullable(VStringMinMaxRegex(1, LIMIT_LONG_STRING_MAX_LENGTH, REGEX_UTM_VALUE, ERROR_MESSAGE_REGEX_UTM_VALUE)))
2062
- });
2063
- const SUpdateUtmTrackingLinkDocumentRequest = v.object({
2064
- documentId: SAssociateOneEntity,
2065
- data: SUpdateUtmTrackingLinkDocument
2066
- });
2067
- //#endregion
2068
- export { AuditLogSortKeys, BlogPostSortKeys, CategorySortKeys, ClientContentPillarSortKeys, ClientMediaPlatformSortKeys, ClientProjectSortKeys, ClientReportSortKeys, ClientSortKeys, ClientStyleguideSortKeys, ClientUserSortKeys, ContentPillarSortKeys, EntitySortKeys, FORMATTER_TEXT_MAX_LENGTH, GCFlyTourSnapSortKeys, GCFlyTourSortKeys, HTMLMimeTypes, HtmlConfigSchema, INLINE_FIRST_PRINT_WIDTH, JSONMimeTypes, JsonConfigSchema, JsonSchema, MediaContentTypeSortKeys, MediaCreativeFormatSortKeys, MediaMediumSortKeys, MediaPlatformSortKeys, MondayWorkspaceSortKeys, QueryFilterStrapiComments, QuerySortAuditLogs, QuerySortBlogPosts, QuerySortCategories, QuerySortClientContentPillars, QuerySortClientMediaPlatforms, QuerySortClientProjects, QuerySortClientReports, QuerySortClientStyleguides, QuerySortClientUsers, QuerySortClients, QuerySortContentPillars, QuerySortEntities, QuerySortGCFlyTourSnaps, QuerySortGCFlyTours, QuerySortMediaContentType, QuerySortMediaCreativeFormat, QuerySortMediaMedium, QuerySortMediaPlatforms, QuerySortMondayWorkspaces, QuerySortStrapiComments, QuerySortTags, QuerySortTeamMembers, QuerySortTeamworkProjectHealth, QuerySortUrlRedirects, QuerySortUsers, QuerySortUtmTrackingLinks, QueryStrapiByDocumentId, QueryStrapiByEmail, QueryStrapiById, QueryStrapiByName, QueryStrapiByPhone, QueryStrapiBySlug, QueryStrapiCommentsFlat, QueryStrapiCommentsInHeirarchy, QueryStrapiPaginated, QueryStrapiPaginatedUrlRedirects, QueryStrapiSearchAuditLogs, QueryStrapiSearchBlogPosts, QueryStrapiSearchBlogPostsBySlug, QueryStrapiSearchCategories, QueryStrapiSearchClientContentPillars, QueryStrapiSearchClientMediaPlatforms, QueryStrapiSearchClientProjects, QueryStrapiSearchClientReports, QueryStrapiSearchClientStyleguide, QueryStrapiSearchClients, QueryStrapiSearchContentPillars, QueryStrapiSearchGCFlyTourSnaps, QueryStrapiSearchGCFlyTours, QueryStrapiSearchMediaContentTypes, QueryStrapiSearchMediaCreativeFormats, QueryStrapiSearchMediaMediums, QueryStrapiSearchMediaPlatforms, QueryStrapiSearchMondayWorkspaces, QueryStrapiSearchTags, QueryStrapiSearchTeamMembers, QueryStrapiSearchTeamworkProjectHealth, QueryStrapiSearchUtmTrackingLinks, QueryStrapiUrlRedirectsByFrom, QueryStrapiUsers, QueryStrapiUsersByIdentifier, SAssociateClientToClientProjectDocument, SAssociateEntityPosition, SAssociateEntityPositionDocumentRequest, SAssociateEntityRelationshipRequest, SAssociateManyEntities, SAssociateOneEntity, SAuditLogMethod, SAuthConnectProviderConfirmation, SAuthConnectProviderRedirectSearch, SAuthRawAccessToken, SChangePassword, SContentFile, SContentText, SCreateAuditLogDocument, SCreateCategoryDocument, SCreateClientContentPillarDocument, SCreateClientDocument, SCreateClientMediaPlatformDocument, SCreateClientProjectDocument, SCreateClientReportDocument, SCreateClientStyleguideDocument, SCreateClientUserDocument, SCreateCommentDocument, SCreateContentPillarDocument, SCreateGCFlyTourDocument, SCreateGCFlyTourSnapDocument, SCreateLeadDocument, SCreateMediaContentTypeDocument, SCreateMediaCreativeFormatDocument, SCreateMediaMediumDocument, SCreateMediaPlatformDocument, SCreateMondayWorkspaceDocument, SCreateMultipleStrapiMediaUploadDocument, SCreateNewsletterSignup, SCreateNewsletterSignupDocument, SCreateResume, SCreateResumeInfo, SCreateResumeInfoDocument, SCreateStrapiMediaUploadDocument, SCreateTagDocument, SCreateUserDocument, SCreateUtmTrackingLinkDocument, SCreateUtmTrackingLinkDocumentRequest, SCreateUtmTrackingLinkParts, SDeleteCommentDocument, SEntityPosition, SForgotUserPassword, SFormCreateMultipleUtmTrackingLinkDocuments, SFormatterForm, SFormatterMode, SFormatterRequest, SIndentLevel, SLoginUser, SQueryListClientUserDocuments, SQueryManyEntities, SReadUserAccountByDocumentId, SReadUserAccountById, SReadUtmTrackingLinkDocumentByUrl, SRegisterUser, SReportCommentDocument, SRequestConfirmEmail, SResetUserPassword, SSetEntityRelationshipRequest, SUpdateAuditLogDocument, SUpdateAuditLogDocumentRequest, SUpdateCategoryDocument, SUpdateCategoryDocumentRequest, SUpdateClientContentPillarDocument, SUpdateClientContentPillarDocumentRequest, SUpdateClientDocument, SUpdateClientDocumentRequest, SUpdateClientMediaPlatformDocument, SUpdateClientMediaPlatformDocumentRequest, SUpdateClientProjectDocument, SUpdateClientProjectDocumentRequest, SUpdateClientReportDocument, SUpdateClientReportDocumentRequest, SUpdateClientStyleguideDocument, SUpdateClientStyleguideDocumentRequest, SUpdateClientUserDocument, SUpdateClientUserDocumentRequest, SUpdateCommentDocument, SUpdateContentPillarDocument, SUpdateContentPillarDocumentRequest, SUpdateGCFlyTourDocument, SUpdateGCFlyTourDocumentRequest, SUpdateGCFlyTourSnapDocument, SUpdateGCFlyTourSnapDocumentRequest, SUpdateLeadDocument, SUpdateLeadRequest, SUpdateMediaContentTypeDocument, SUpdateMediaContentTypeDocumentRequest, SUpdateMediaCreativeFormatDocument, SUpdateMediaCreativeFormatDocumentRequest, SUpdateMediaMediumDocument, SUpdateMediaMediumDocumentRequest, SUpdateMediaPlatformDocument, SUpdateMediaPlatformDocumentRequest, SUpdateMondayWorkspaceDocument, SUpdateMondayWorkspaceDocumentRequest, SUpdateNewsletterSignupDocument, SUpdateNewsletterSignupRequest, SUpdateResumeInfo, SUpdateResumeInfoDocument, SUpdateResumeInfoRequest, SUpdateStrapiMediaFileInfo, SUpdateTagDocument, SUpdateTagDocumentRequest, SUpdateTrendsLikes, SUpdateUserAccount, SUpdateUserAccountFirstName, SUpdateUserAccountLastName, SUpdateUserAccountPreferredName, SUpdateUtmTrackingLinkDocument, SUpdateUtmTrackingLinkDocumentRequest, SUserToken, SUtmLinkBuilderCampaign, SUtmLinkBuilderCreativeFormat, SUtmLinkBuilderPartCampaignDateOptions, SUtmLinkBuilderSingleForm, SUtmLinkBuilderTableForm, SVerifyClientUserDocument, SharpSpringSignUpToDownload, StrapiCollectionEntities, StrapiCommentSortKeys, StrapiSingleEntities, TXTMimeTypes, TagSortKeys, TeamMemberSortKeys, TeamworkProjectHealthProjectStatusOptions, TeamworkProjectHealthSelectSortOptions, UrlRedirectSortKeys, UserSortKeys, UtmTrackingLinkSortKeys, VIntegerNullable, VNumberNullable, VPage, VSize, VString, VStringEmail, VStringLong, VStringLongNullable, VStringMax, VStringMaxRegex, VStringMinMax, VStringMinMaxRegex, VStringPhone, VStringPhoneNullable, VStringShort, VStringShortNullable, VStringSlug, VStringUrl, VStringUrlNoUtm, VStringUrlNullable, VStringUrlUtm, ValidStrapiCollectionEntity, ValidStrapiSingleEntity, XMLMimeTypes, XmlConfigSchema, allowedMimeTypes, buildPrettierConfigHTML, buildPrettierConfigJSON, buildPrettierConfigXML, checkIsValidUrlList, formatterModeOptions, formatterModeValues, indentLevelOptions, indentLevelValues };