alepha 0.19.1 → 0.19.3

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 (531) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +6 -9
  3. package/dist/api/audits/index.d.ts +378 -346
  4. package/dist/api/audits/index.d.ts.map +1 -1
  5. package/dist/api/files/index.d.ts +216 -184
  6. package/dist/api/files/index.d.ts.map +1 -1
  7. package/dist/api/jobs/index.d.ts +534 -502
  8. package/dist/api/jobs/index.d.ts.map +1 -1
  9. package/dist/api/jobs/index.js +13 -7
  10. package/dist/api/jobs/index.js.map +1 -1
  11. package/dist/api/keys/index.d.ts +202 -202
  12. package/dist/api/keys/index.d.ts.map +1 -1
  13. package/dist/api/notifications/index.d.ts +152 -152
  14. package/dist/api/notifications/index.d.ts.map +1 -1
  15. package/dist/api/organizations/index.browser.js +48 -0
  16. package/dist/api/organizations/index.browser.js.map +1 -0
  17. package/dist/api/organizations/index.d.ts +516 -0
  18. package/dist/api/organizations/index.d.ts.map +1 -0
  19. package/dist/api/organizations/index.js +202 -0
  20. package/dist/api/organizations/index.js.map +1 -0
  21. package/dist/api/parameters/index.d.ts +391 -358
  22. package/dist/api/parameters/index.d.ts.map +1 -1
  23. package/dist/api/parameters/index.js +5 -1
  24. package/dist/api/parameters/index.js.map +1 -1
  25. package/dist/api/users/index.browser.js +7 -5
  26. package/dist/api/users/index.browser.js.map +1 -1
  27. package/dist/api/users/index.d.ts +986 -931
  28. package/dist/api/users/index.d.ts.map +1 -1
  29. package/dist/api/users/index.js +160 -112
  30. package/dist/api/users/index.js.map +1 -1
  31. package/dist/api/verifications/index.d.ts +137 -137
  32. package/dist/api/verifications/index.d.ts.map +1 -1
  33. package/dist/api/verifications/index.js +2 -2
  34. package/dist/api/verifications/index.js.map +1 -1
  35. package/dist/batch/index.d.ts +6 -6
  36. package/dist/batch/index.d.ts.map +1 -1
  37. package/dist/billing/index.d.ts +1048 -0
  38. package/dist/billing/index.d.ts.map +1 -0
  39. package/dist/billing/index.js +713 -0
  40. package/dist/billing/index.js.map +1 -0
  41. package/dist/bin/index.js +0 -2
  42. package/dist/bin/index.js.map +1 -1
  43. package/dist/bucket/index.d.ts +10 -10
  44. package/dist/bucket/index.d.ts.map +1 -1
  45. package/dist/bucket/index.js +2 -2
  46. package/dist/bucket/index.js.map +1 -1
  47. package/dist/cache/core/index.d.ts +9 -9
  48. package/dist/cache/core/index.d.ts.map +1 -1
  49. package/dist/cache/core/index.js +2 -2
  50. package/dist/cache/core/index.js.map +1 -1
  51. package/dist/cache/core/index.workerd.js +2 -2
  52. package/dist/cache/core/index.workerd.js.map +1 -1
  53. package/dist/cache/redis/index.d.ts +6 -6
  54. package/dist/cache/redis/index.d.ts.map +1 -1
  55. package/dist/cache/redis/index.js +2 -2
  56. package/dist/cache/redis/index.js.map +1 -1
  57. package/dist/cli/config/index.d.ts +6 -18
  58. package/dist/cli/config/index.d.ts.map +1 -1
  59. package/dist/cli/config/index.js +5 -6
  60. package/dist/cli/config/index.js.map +1 -1
  61. package/dist/cli/core/index.d.ts +11811 -323
  62. package/dist/cli/core/index.d.ts.map +1 -1
  63. package/dist/cli/core/index.js +324 -98
  64. package/dist/cli/core/index.js.map +1 -1
  65. package/dist/cli/devtools/index.d.ts +50 -0
  66. package/dist/cli/devtools/index.d.ts.map +1 -0
  67. package/dist/cli/devtools/index.js +174 -0
  68. package/dist/cli/devtools/index.js.map +1 -0
  69. package/dist/cli/platform/index.d.ts +438 -542
  70. package/dist/cli/platform/index.d.ts.map +1 -1
  71. package/dist/cli/platform/index.js +46 -511
  72. package/dist/cli/platform/index.js.map +1 -1
  73. package/dist/cli/vendor/index.d.ts +201 -0
  74. package/dist/cli/vendor/index.d.ts.map +1 -0
  75. package/dist/cli/vendor/index.js +388 -0
  76. package/dist/cli/vendor/index.js.map +1 -0
  77. package/dist/command/index.d.ts +18 -18
  78. package/dist/command/index.d.ts.map +1 -1
  79. package/dist/command/index.js +2 -2
  80. package/dist/command/index.js.map +1 -1
  81. package/dist/core/index.browser.js +4 -4
  82. package/dist/core/index.browser.js.map +1 -1
  83. package/dist/core/index.d.ts +10 -10
  84. package/dist/core/index.d.ts.map +1 -1
  85. package/dist/core/index.js +8 -4
  86. package/dist/core/index.js.map +1 -1
  87. package/dist/core/index.native.js +8 -4
  88. package/dist/core/index.native.js.map +1 -1
  89. package/dist/core/index.workerd.js +8 -4
  90. package/dist/core/index.workerd.js.map +1 -1
  91. package/dist/crypto/index.d.ts +7 -7
  92. package/dist/crypto/index.d.ts.map +1 -1
  93. package/dist/datetime/index.d.ts +4 -4
  94. package/dist/datetime/index.d.ts.map +1 -1
  95. package/dist/email/brevo/index.d.ts +4 -4
  96. package/dist/email/brevo/index.d.ts.map +1 -1
  97. package/dist/email/core/index.d.ts +15 -11
  98. package/dist/email/core/index.d.ts.map +1 -1
  99. package/dist/email/core/index.js +12 -35
  100. package/dist/email/core/index.js.map +1 -1
  101. package/dist/email/smtp/index.d.ts +12 -12
  102. package/dist/email/smtp/index.d.ts.map +1 -1
  103. package/dist/email/smtp/index.js +7 -4
  104. package/dist/email/smtp/index.js.map +1 -1
  105. package/dist/fake/index.d.ts +4 -8
  106. package/dist/fake/index.d.ts.map +1 -1
  107. package/dist/fake/index.js +55 -889
  108. package/dist/fake/index.js.map +1 -1
  109. package/dist/lock/core/index.d.ts +13 -13
  110. package/dist/lock/core/index.d.ts.map +1 -1
  111. package/dist/lock/core/index.js +2 -2
  112. package/dist/lock/core/index.js.map +1 -1
  113. package/dist/lock/redis/index.d.ts +4 -4
  114. package/dist/lock/redis/index.d.ts.map +1 -1
  115. package/dist/logger/index.d.ts +16 -15
  116. package/dist/logger/index.d.ts.map +1 -1
  117. package/dist/logger/index.js +6 -3
  118. package/dist/logger/index.js.map +1 -1
  119. package/dist/mcp/index.d.ts +11 -11
  120. package/dist/mcp/index.d.ts.map +1 -1
  121. package/dist/mcp/index.js +2 -2
  122. package/dist/mcp/index.js.map +1 -1
  123. package/dist/orm/core/index.browser.js +11 -1
  124. package/dist/orm/core/index.browser.js.map +1 -1
  125. package/dist/orm/core/index.bun.js +78 -72
  126. package/dist/orm/core/index.bun.js.map +1 -1
  127. package/dist/orm/core/index.d.ts +103 -69
  128. package/dist/orm/core/index.d.ts.map +1 -1
  129. package/dist/orm/core/index.js +80 -70
  130. package/dist/orm/core/index.js.map +1 -1
  131. package/dist/orm/postgres/index.d.ts +19 -17
  132. package/dist/orm/postgres/index.d.ts.map +1 -1
  133. package/dist/queue/core/index.d.ts +14 -14
  134. package/dist/queue/core/index.d.ts.map +1 -1
  135. package/dist/queue/core/index.js +2 -2
  136. package/dist/queue/core/index.js.map +1 -1
  137. package/dist/queue/core/index.workerd.js +2 -2
  138. package/dist/queue/core/index.workerd.js.map +1 -1
  139. package/dist/queue/redis/index.d.ts +4 -4
  140. package/dist/queue/redis/index.d.ts.map +1 -1
  141. package/dist/queue/redis/index.js +2 -2
  142. package/dist/queue/redis/index.js.map +1 -1
  143. package/dist/react/auth/index.d.ts +9 -9
  144. package/dist/react/auth/index.d.ts.map +1 -1
  145. package/dist/react/core/index.d.ts +6 -6
  146. package/dist/react/core/index.d.ts.map +1 -1
  147. package/dist/react/core/index.js +5 -4
  148. package/dist/react/core/index.js.map +1 -1
  149. package/dist/react/form/index.d.ts +4 -4
  150. package/dist/react/form/index.d.ts.map +1 -1
  151. package/dist/react/head/index.d.ts +4 -4
  152. package/dist/react/head/index.d.ts.map +1 -1
  153. package/dist/react/i18n/index.d.ts +9 -9
  154. package/dist/react/i18n/index.d.ts.map +1 -1
  155. package/dist/react/intro/index.d.ts +2 -2
  156. package/dist/react/intro/index.d.ts.map +1 -1
  157. package/dist/react/intro/index.js +1 -1
  158. package/dist/react/intro/index.js.map +1 -1
  159. package/dist/react/router/index.browser.js +4 -5
  160. package/dist/react/router/index.browser.js.map +1 -1
  161. package/dist/react/router/index.d.ts +215 -215
  162. package/dist/react/router/index.d.ts.map +1 -1
  163. package/dist/react/router/index.js +6 -7
  164. package/dist/react/router/index.js.map +1 -1
  165. package/dist/react/testing/index.d.ts +2 -2
  166. package/dist/react/testing/index.d.ts.map +1 -1
  167. package/dist/react/testing/index.js +2 -4
  168. package/dist/react/testing/index.js.map +1 -1
  169. package/dist/redis/index.d.ts +19 -19
  170. package/dist/redis/index.d.ts.map +1 -1
  171. package/dist/retry/index.d.ts +4 -4
  172. package/dist/retry/index.d.ts.map +1 -1
  173. package/dist/scheduler/index.d.ts +13 -13
  174. package/dist/scheduler/index.d.ts.map +1 -1
  175. package/dist/scheduler/index.js +2 -2
  176. package/dist/scheduler/index.js.map +1 -1
  177. package/dist/scheduler/index.workerd.js +2 -2
  178. package/dist/scheduler/index.workerd.js.map +1 -1
  179. package/dist/security/index.browser.js +1 -1
  180. package/dist/security/index.browser.js.map +1 -1
  181. package/dist/security/index.d.ts +47 -47
  182. package/dist/security/index.d.ts.map +1 -1
  183. package/dist/security/index.js +9 -12
  184. package/dist/security/index.js.map +1 -1
  185. package/dist/server/auth/index.d.ts +170 -169
  186. package/dist/server/auth/index.d.ts.map +1 -1
  187. package/dist/server/auth/index.js +16 -2
  188. package/dist/server/auth/index.js.map +1 -1
  189. package/dist/server/cookies/index.d.ts +7 -7
  190. package/dist/server/cookies/index.d.ts.map +1 -1
  191. package/dist/server/core/index.d.ts +76 -76
  192. package/dist/server/core/index.d.ts.map +1 -1
  193. package/dist/server/core/index.js +23 -17
  194. package/dist/server/core/index.js.map +1 -1
  195. package/dist/server/cors/index.d.ts +13 -13
  196. package/dist/server/cors/index.d.ts.map +1 -1
  197. package/dist/server/cors/index.js +2 -2
  198. package/dist/server/cors/index.js.map +1 -1
  199. package/dist/server/etag/index.d.ts +9 -9
  200. package/dist/server/etag/index.d.ts.map +1 -1
  201. package/dist/server/health/index.d.ts +20 -20
  202. package/dist/server/health/index.d.ts.map +1 -1
  203. package/dist/server/links/index.browser.js +2 -2
  204. package/dist/server/links/index.browser.js.map +1 -1
  205. package/dist/server/links/index.d.ts +66 -66
  206. package/dist/server/links/index.d.ts.map +1 -1
  207. package/dist/server/links/index.js +4 -4
  208. package/dist/server/links/index.js.map +1 -1
  209. package/dist/server/metrics/index.d.ts +7 -7
  210. package/dist/server/metrics/index.d.ts.map +1 -1
  211. package/dist/server/proxy/index.d.ts +5 -5
  212. package/dist/server/proxy/index.d.ts.map +1 -1
  213. package/dist/server/rate-limit/index.d.ts +12 -12
  214. package/dist/server/rate-limit/index.d.ts.map +1 -1
  215. package/dist/server/rate-limit/index.js +2 -2
  216. package/dist/server/rate-limit/index.js.map +1 -1
  217. package/dist/server/static/index.d.ts +5 -5
  218. package/dist/server/static/index.d.ts.map +1 -1
  219. package/dist/server/swagger/index.d.ts +7 -7
  220. package/dist/server/swagger/index.d.ts.map +1 -1
  221. package/dist/server/swagger/index.js +2 -2
  222. package/dist/server/swagger/index.js.map +1 -1
  223. package/dist/sms/index.d.ts +11 -7
  224. package/dist/sms/index.d.ts.map +1 -1
  225. package/dist/sms/index.js +9 -15
  226. package/dist/sms/index.js.map +1 -1
  227. package/dist/system/index.d.ts +4 -4
  228. package/dist/system/index.d.ts.map +1 -1
  229. package/dist/topic/core/index.d.ts +6 -6
  230. package/dist/topic/core/index.d.ts.map +1 -1
  231. package/dist/topic/redis/index.d.ts +7 -7
  232. package/dist/topic/redis/index.d.ts.map +1 -1
  233. package/dist/topic/redis/index.js +2 -2
  234. package/dist/topic/redis/index.js.map +1 -1
  235. package/dist/websocket/index.d.ts +36 -36
  236. package/dist/websocket/index.d.ts.map +1 -1
  237. package/dist/websocket/index.js +2 -2
  238. package/dist/websocket/index.js.map +1 -1
  239. package/package.json +37 -15
  240. package/src/api/jobs/{services → __tests__}/JobService.spec.ts +1 -1
  241. package/src/api/jobs/providers/JobProvider.ts +13 -9
  242. package/src/api/keys/{services → __tests__}/ApiKeyService.spec.ts +1 -1
  243. package/src/api/organizations/__tests__/OrganizationService.spec.ts +193 -0
  244. package/src/api/organizations/controllers/AdminOrganizationController.ts +103 -0
  245. package/src/api/organizations/entities/organizations.ts +20 -0
  246. package/src/api/organizations/index.browser.ts +10 -0
  247. package/src/api/organizations/index.ts +31 -0
  248. package/src/api/organizations/schemas/createOrganizationSchema.ts +10 -0
  249. package/src/api/organizations/schemas/organizationQuerySchema.ts +10 -0
  250. package/src/api/organizations/schemas/organizationResourceSchema.ts +6 -0
  251. package/src/api/organizations/schemas/updateOrganizationSchema.ts +7 -0
  252. package/src/api/organizations/services/OrganizationService.ts +75 -0
  253. package/src/api/parameters/services/ParameterProvider.ts +6 -1
  254. package/src/api/users/{services → __tests__}/SessionService.spec.ts +67 -0
  255. package/src/api/users/{jobs → __tests__}/UserJobs.spec.ts +1 -1
  256. package/src/api/users/entities/users.ts +9 -3
  257. package/src/api/users/index.ts +23 -4
  258. package/src/api/users/primitives/$realm.ts +6 -4
  259. package/src/api/users/providers/RealmProvider.ts +1 -1
  260. package/src/api/users/services/RegistrationService.ts +1 -1
  261. package/src/api/users/services/SessionService.ts +92 -5
  262. package/src/api/users/services/UserService.ts +1 -1
  263. package/src/api/verifications/{jobs → __tests__}/VerificationJobs.spec.ts +4 -2
  264. package/src/api/verifications/parameters/VerificationParameters.ts +2 -2
  265. package/src/billing/__tests__/BillingService.spec.ts +136 -0
  266. package/src/billing/__tests__/PaymentMethodService.spec.ts +78 -0
  267. package/src/billing/controllers/AdminBillingController.ts +149 -0
  268. package/src/billing/controllers/BillingController.ts +108 -0
  269. package/src/billing/entities/paymentIntents.ts +34 -0
  270. package/src/billing/entities/paymentMethods.ts +24 -0
  271. package/src/billing/entities/refunds.ts +22 -0
  272. package/src/billing/errors/BillingError.ts +5 -0
  273. package/src/billing/index.ts +76 -0
  274. package/src/billing/providers/BillingProvider.ts +79 -0
  275. package/src/billing/providers/MemoryBillingProvider.ts +139 -0
  276. package/src/billing/schemas/intentSchemas.ts +60 -0
  277. package/src/billing/schemas/paymentMethodSchemas.ts +13 -0
  278. package/src/billing/schemas/refundSchemas.ts +6 -0
  279. package/src/billing/services/BillingService.ts +325 -0
  280. package/src/billing/services/PaymentMethodService.ts +82 -0
  281. package/src/bin/index.ts +0 -2
  282. package/src/bucket/providers/LocalFileStorageProvider.ts +2 -2
  283. package/src/cache/core/{primitives → __tests__}/$cache.middleware.spec.ts +1 -1
  284. package/src/cache/core/{providers → __tests__}/MemoryCacheProvider.spec.ts +1 -1
  285. package/src/cache/core/primitives/$cache.ts +2 -2
  286. package/src/cache/redis/providers/RedisCacheProvider.ts +2 -2
  287. package/src/cli/config/defineConfig.ts +17 -26
  288. package/src/cli/core/{services → __tests__}/ProjectScaffolder.spec.ts +1 -1
  289. package/src/cli/core/{commands/gen → __tests__}/changelog.spec.ts +1 -1
  290. package/src/cli/core/{commands → __tests__}/init.spec.ts +2 -8
  291. package/src/cli/core/atoms/devOptions.ts +0 -5
  292. package/src/cli/core/commands/build.ts +2 -2
  293. package/src/cli/core/commands/dev.ts +165 -30
  294. package/src/cli/core/commands/gen/changelog.ts +2 -2
  295. package/src/cli/core/commands/init.ts +2 -7
  296. package/src/cli/core/commands/verify.ts +0 -1
  297. package/src/cli/core/providers/AppEntryProvider.ts +2 -2
  298. package/src/cli/core/providers/ViteDevServerProvider.ts +99 -69
  299. package/src/cli/core/services/PackageManagerUtils.ts +8 -1
  300. package/src/cli/core/services/ProjectScaffolder.ts +23 -23
  301. package/src/cli/core/tasks/BuildClientTask.ts +8 -0
  302. package/src/cli/core/tasks/BuildServerTask.ts +17 -4
  303. package/src/cli/core/templates/agentMd.ts +14 -5
  304. package/src/cli/core/templates/alephaConfigTs.ts +0 -6
  305. package/src/cli/core/templates/webAdminDashboardTsx.ts +17 -0
  306. package/src/cli/core/templates/webAppRouterTs.ts +85 -2
  307. package/src/cli/devtools/atoms/devtoolsOptions.ts +26 -0
  308. package/src/cli/devtools/index.ts +214 -0
  309. package/src/cli/platform/{adapters → __tests__}/CloudflareAdapter.spec.ts +2 -2
  310. package/src/cli/platform/{providers → __tests__}/GitHubSecretStore.spec.ts +1 -1
  311. package/src/cli/platform/{services → __tests__}/NamingService.spec.ts +1 -1
  312. package/src/cli/platform/{providers → __tests__}/PlatformCacheProvider.spec.ts +1 -1
  313. package/src/cli/platform/{services → __tests__}/PlatformInspector.spec.ts +1 -1
  314. package/src/cli/platform/{services → __tests__}/PlatformOrchestrator.spec.ts +3 -3
  315. package/src/cli/platform/{services → __tests__}/SecretFilterService.spec.ts +1 -1
  316. package/src/cli/platform/{commands → __tests__}/SecretsCommand.spec.ts +1 -1
  317. package/src/cli/platform/{adapters → __tests__}/VercelAdapter.spec.ts +2 -2
  318. package/src/cli/platform/atoms/platformOptions.ts +2 -10
  319. package/src/cli/platform/commands/SecretsCommand.ts +2 -2
  320. package/src/cli/platform/commands/platform.ts +2 -11
  321. package/src/cli/platform/index.ts +55 -11
  322. package/src/cli/platform/services/PlatformInspector.ts +2 -2
  323. package/src/cli/platform/services/PlatformOrchestrator.ts +0 -9
  324. package/src/cli/vendor/__tests__/VendorService.spec.ts +407 -0
  325. package/src/cli/vendor/atoms/vendorOptions.ts +41 -0
  326. package/src/cli/vendor/commands/VendorCommand.ts +204 -0
  327. package/src/cli/vendor/index.ts +60 -0
  328. package/src/cli/vendor/services/VendorService.ts +338 -0
  329. package/src/command/{providers → __tests__}/CliProvider.spec.ts +1 -1
  330. package/src/command/{helpers → __tests__}/EnvUtils.spec.ts +1 -1
  331. package/src/command/providers/CliProvider.ts +2 -2
  332. package/src/core/Alepha.ts +10 -0
  333. package/src/core/{primitives → __tests__}/$atom.spec.ts +2 -2
  334. package/src/core/{primitives → __tests__}/$memoize.spec.ts +1 -1
  335. package/src/core/{primitives → __tests__}/$mode.spec.ts +1 -1
  336. package/src/core/{primitives → __tests__}/$pipeline.spec.ts +1 -1
  337. package/src/core/{primitives → __tests__}/$scope.spec.ts +2 -2
  338. package/src/core/{providers → __tests__}/KeylessJsonSchemaCodec.spec.ts +1 -1
  339. package/src/core/{providers → __tests__}/SchemaValidator.spec.ts +1 -1
  340. package/src/core/{helpers → __tests__}/jsonSchemaToTypeBox.spec.ts +1 -1
  341. package/src/core/index.shared.ts +1 -1
  342. package/src/core/primitives/{$use.ts → $state.ts} +4 -4
  343. package/src/crypto/{providers → __tests__}/BrowserCryptoProvider.browser.spec.ts +1 -1
  344. package/src/crypto/{providers → __tests__}/CryptoProvider.spec.ts +1 -1
  345. package/src/datetime/{primitives → __tests__}/$debounce.spec.ts +1 -1
  346. package/src/datetime/{primitives → __tests__}/$throttle.spec.ts +1 -1
  347. package/src/datetime/{primitives → __tests__}/$timeout.spec.ts +1 -1
  348. package/src/email/brevo/{providers → __tests__}/BrevoEmailProvider.spec.ts +1 -1
  349. package/src/email/core/{providers → __tests__}/LocalEmailProvider.spec.ts +39 -150
  350. package/src/email/core/providers/LocalEmailProvider.ts +13 -51
  351. package/src/email/smtp/providers/NodemailerEmailProvider.ts +2 -2
  352. package/src/lock/core/{primitives → __tests__}/$lock.middleware.spec.ts +1 -1
  353. package/src/lock/core/primitives/$lock.ts +2 -2
  354. package/src/logger/index.ts +16 -5
  355. package/src/mcp/transports/SseMcpTransport.ts +2 -2
  356. package/src/orm/__tests__/ModelBuilder-tests.ts +53 -0
  357. package/src/orm/__tests__/ModelBuilder.spec.ts +80 -0
  358. package/src/orm/__tests__/organization-tests.ts +200 -0
  359. package/src/orm/__tests__/organization.spec.ts +103 -0
  360. package/src/orm/core/{providers/drivers → __tests__}/BunSqliteProvider.bun.spec.ts +5 -2
  361. package/src/orm/core/constants/PG_SYMBOLS.ts +2 -0
  362. package/src/orm/core/index.shared.ts +1 -0
  363. package/src/orm/core/primitives/$entity.ts +31 -0
  364. package/src/orm/core/providers/DatabaseTypeProvider.ts +11 -0
  365. package/src/orm/core/providers/DrizzleKitProvider.ts +57 -106
  366. package/src/orm/core/providers/drivers/BunSqliteProvider.ts +2 -2
  367. package/src/orm/core/providers/drivers/NodeSqliteProvider.ts +3 -3
  368. package/src/orm/core/services/ModelBuilder.ts +11 -0
  369. package/src/orm/core/services/QueryManager.ts +16 -2
  370. package/src/orm/core/services/Repository.ts +70 -10
  371. package/src/orm/postgres/{providers → __tests__}/BunPostgresProvider.bun.spec.ts +1 -1
  372. package/src/queue/core/providers/WorkerProvider.ts +2 -2
  373. package/src/queue/redis/providers/RedisQueueProvider.ts +2 -2
  374. package/src/react/core/{hooks → __tests__}/useAction.browser.spec.tsx +1 -1
  375. package/src/react/core/hooks/useAction.ts +7 -6
  376. package/src/react/head/{providers → __tests__}/BrowserHeadProvider.browser.spec.ts +1 -1
  377. package/src/react/head/{helpers → __tests__}/SeoExpander.spec.ts +1 -1
  378. package/src/react/i18n/{providers → __tests__}/I18nProvider.spec.ts +1 -1
  379. package/src/react/i18n/{hooks → __tests__}/useI18n.browser.spec.tsx +1 -1
  380. package/src/react/intro/components/GettingStartedDevtoolsSlide.tsx +1 -1
  381. package/src/react/router/{providers → __tests__}/ReactBrowserProvider.browser.spec.ts +1 -1
  382. package/src/react/router/providers/ReactBrowserProvider.ts +2 -2
  383. package/src/react/router/providers/ReactPageProvider.ts +2 -2
  384. package/src/react/router/providers/ReactServerProvider.ts +3 -3
  385. package/src/redis/{providers → __tests__}/BunRedisProvider.bun.spec.ts +4 -4
  386. package/src/retry/{primitives → __tests__}/$retry.middleware.spec.ts +1 -1
  387. package/src/router/{TemplatedPathParser.spec.ts → __tests__/TemplatedPathParser.spec.ts} +1 -1
  388. package/src/scheduler/primitives/$scheduler.ts +2 -2
  389. package/src/security/{primitives → __tests__}/$secure-browser.spec.ts +1 -1
  390. package/src/security/{primitives → __tests__}/$secure.spec.ts +1 -1
  391. package/src/security/primitives/$issuer.ts +1 -1
  392. package/src/security/providers/JwtProvider.ts +6 -10
  393. package/src/security/providers/SecurityProvider.ts +6 -11
  394. package/src/security/schemas/userAccountInfoSchema.ts +3 -3
  395. package/src/server/auth/providers/ServerAuthProvider.ts +24 -2
  396. package/src/server/cookies/{services → __tests__}/CookieParser.spec.ts +1 -1
  397. package/src/server/core/{primitives → __tests__}/$circuit.spec.ts +1 -1
  398. package/src/server/core/{providers → __tests__}/NodeHttpServerProvider.spec.ts +1 -1
  399. package/src/server/core/{providers → __tests__}/ServerBodyParserProvider.spec.ts +31 -1
  400. package/src/server/core/{providers → __tests__}/ServerCompressProvider.spec.ts +1 -1
  401. package/src/server/core/{providers → __tests__}/ServerHelmetProvider.spec.ts +4 -1
  402. package/src/server/core/{providers → __tests__}/ServerMultipartProvider.spec.ts +1 -1
  403. package/src/server/core/{services → __tests__}/ServerRequestParser.spec.ts +1 -1
  404. package/src/server/core/primitives/$action.ts +2 -2
  405. package/src/server/core/primitives/$sse.ts +2 -2
  406. package/src/server/core/providers/ServerBodyParserProvider.ts +21 -12
  407. package/src/server/core/providers/ServerCompressProvider.ts +2 -2
  408. package/src/server/core/providers/ServerHelmetProvider.ts +2 -2
  409. package/src/server/core/providers/ServerMultipartProvider.ts +2 -2
  410. package/src/server/core/providers/ServerRouterProvider.ts +1 -5
  411. package/src/server/cors/{primitives → __tests__}/$cors.spec.ts +1 -1
  412. package/src/server/cors/providers/ServerCorsProvider.ts +2 -2
  413. package/src/server/links/{services → __tests__}/BatchCollector.spec.ts +1 -1
  414. package/src/server/links/providers/LinkProvider.ts +2 -2
  415. package/src/server/links/providers/RemotePrimitiveProvider.ts +2 -2
  416. package/src/server/links/providers/ServerLinksProvider.ts +2 -2
  417. package/src/server/rate-limit/{primitives → __tests__}/$rateLimit.spec.ts +1 -1
  418. package/src/server/rate-limit/providers/ServerRateLimitProvider.ts +2 -2
  419. package/src/server/swagger/providers/ServerSwaggerProvider.ts +2 -2
  420. package/src/sms/{providers → __tests__}/LocalSmsProvider.spec.ts +35 -29
  421. package/src/sms/providers/LocalSmsProvider.ts +13 -24
  422. package/src/system/{providers → __tests__}/MemoryFileSystemProvider.spec.ts +1 -1
  423. package/src/system/{providers → __tests__}/MemoryShellProvider.spec.ts +1 -1
  424. package/src/topic/redis/providers/RedisTopicProvider.ts +2 -2
  425. package/src/websocket/{services → __tests__}/RoomManager.spec.ts +1 -1
  426. package/src/websocket/providers/NodeWebSocketServerProvider.ts +2 -2
  427. package/src/cli/platform/adapters/DockerAdapter.spec.ts +0 -378
  428. package/src/cli/platform/adapters/DockerAdapter.ts +0 -417
  429. package/src/cli/platform/services/DockerComposeGenerator.spec.ts +0 -490
  430. package/src/cli/platform/services/DockerComposeGenerator.ts +0 -353
  431. package/src/cli/platform/services/DockerSshService.spec.ts +0 -47
  432. package/src/cli/platform/services/DockerSshService.ts +0 -61
  433. /package/src/api/audits/{primitives → __tests__}/$audit.spec.ts +0 -0
  434. /package/src/api/audits/{services → __tests__}/AuditService.spec.ts +0 -0
  435. /package/src/api/files/{controllers → __tests__}/AdminFileStatsController.spec.ts +0 -0
  436. /package/src/api/files/{controllers → __tests__}/FileController.spec.ts +0 -0
  437. /package/src/api/files/{jobs → __tests__}/FileJobs.spec.ts +0 -0
  438. /package/src/api/files/{services → __tests__}/FileService.spec.ts +0 -0
  439. /package/src/api/jobs/{primitives → __tests__}/$job-middleware.spec.ts +0 -0
  440. /package/src/api/parameters/{primitives → __tests__}/$parameter.spec.ts +0 -0
  441. /package/src/api/users/{primitives → __tests__}/$realm.spec.ts +0 -0
  442. /package/src/api/users/{controllers → __tests__}/AdminIdentityController.spec.ts +0 -0
  443. /package/src/api/users/{controllers → __tests__}/AdminSessionController.spec.ts +0 -0
  444. /package/src/api/users/{controllers → __tests__}/AdminUserController.spec.ts +0 -0
  445. /package/src/api/users/{services → __tests__}/CredentialService.spec.ts +0 -0
  446. /package/src/api/users/{providers → __tests__}/RealmProvider.spec.ts +0 -0
  447. /package/src/api/users/{services → __tests__}/RegistrationService.spec.ts +0 -0
  448. /package/src/batch/{primitives → __tests__}/$batch.spec.ts +0 -0
  449. /package/src/batch/{providers → __tests__}/BatchProvider.spec.ts +0 -0
  450. /package/src/bucket/{primitives → __tests__}/$bucket.spec.ts +0 -0
  451. /package/src/bucket/{providers → __tests__}/FileStorageProvider.spec.ts +0 -0
  452. /package/src/bucket/{providers → __tests__}/LocalFileStorageProvider.spec.ts +0 -0
  453. /package/src/bucket/{providers → __tests__}/MemoryFileStorageProvider.spec.ts +0 -0
  454. /package/src/cache/core/{primitives → __tests__}/$cache.spec.ts +0 -0
  455. /package/src/cache/redis/{providers → __tests__}/RedisCacheProvider.spec.ts +0 -0
  456. /package/src/command/{primitives → __tests__}/$command.spec.ts +0 -0
  457. /package/src/command/{helpers → __tests__}/Asker.spec.ts +0 -0
  458. /package/src/command/{helpers → __tests__}/Runner.spec.ts +0 -0
  459. /package/src/core/{primitives → __tests__}/$context.spec.ts +0 -0
  460. /package/src/core/{primitives → __tests__}/$env.spec.ts +0 -0
  461. /package/src/core/{primitives → __tests__}/$hook.spec.ts +0 -0
  462. /package/src/core/{primitives → __tests__}/$inject.spec.ts +0 -0
  463. /package/src/core/{primitives → __tests__}/$module.spec.ts +0 -0
  464. /package/src/core/{providers → __tests__}/CodecManager.spec.ts +0 -0
  465. /package/src/core/{providers → __tests__}/EventManager.spec.ts +0 -0
  466. /package/src/core/{providers → __tests__}/StateManager.spec.ts +0 -0
  467. /package/src/core/{providers → __tests__}/TypeProvider.spec.ts +0 -0
  468. /package/src/datetime/{primitives → __tests__}/$interval.spec.ts +0 -0
  469. /package/src/datetime/{providers → __tests__}/DateTimeProvider.spec.ts +0 -0
  470. /package/src/email/core/{primitives → __tests__}/$email.spec.ts +0 -0
  471. /package/src/fake/{providers → __tests__}/FakeProvider.spec.ts +0 -0
  472. /package/src/lock/core/{providers → __tests__}/MemoryLockProvider.spec.ts +0 -0
  473. /package/src/lock/redis/{providers → __tests__}/RedisLockProvider.spec.ts +0 -0
  474. /package/src/logger/{primitives → __tests__}/$logger.spec.ts +0 -0
  475. /package/src/logger/{services → __tests__}/Logger.spec.ts +0 -0
  476. /package/src/mcp/{primitives → __tests__}/$prompt.spec.ts +0 -0
  477. /package/src/mcp/{primitives → __tests__}/$resource.spec.ts +0 -0
  478. /package/src/mcp/{primitives → __tests__}/$tool.spec.ts +0 -0
  479. /package/src/mcp/{providers → __tests__}/McpServerProvider.spec.ts +0 -0
  480. /package/src/mcp/{helpers → __tests__}/jsonrpc.spec.ts +0 -0
  481. /package/src/orm/core/{helpers → __tests__}/parseQueryString.spec.ts +0 -0
  482. /package/src/queue/core/{primitives → __tests__}/$consumer.spec.ts +0 -0
  483. /package/src/queue/core/{providers → __tests__}/MemoryQueueProvider.spec.ts +0 -0
  484. /package/src/queue/core/{providers → __tests__}/WorkerProvider.spec.ts +0 -0
  485. /package/src/queue/redis/{providers → __tests__}/RedisQueueProvider.spec.ts +0 -0
  486. /package/src/react/form/{hooks → __tests__}/useForm.browser.spec.tsx +0 -0
  487. /package/src/react/head/{hooks → __tests__}/useHead.spec.tsx +0 -0
  488. /package/src/react/i18n/{components → __tests__}/Localize.spec.tsx +0 -0
  489. /package/src/react/router/{primitives → __tests__}/$page.browser.spec.tsx +0 -0
  490. /package/src/react/router/{primitives → __tests__}/$page.middleware.spec.tsx +0 -0
  491. /package/src/react/router/{primitives → __tests__}/$page.spec.tsx +0 -0
  492. /package/src/react/router/{providers → __tests__}/ReactPreloadProvider.spec.ts +0 -0
  493. /package/src/react/router/{providers → __tests__}/ReactServerProvider.spec.tsx +0 -0
  494. /package/src/react/router/{providers → __tests__}/ReactServerTemplateProvider.spec.ts +0 -0
  495. /package/src/retry/{primitives → __tests__}/$retry.spec.ts +0 -0
  496. /package/src/retry/{providers → __tests__}/RetryProvider.spec.ts +0 -0
  497. /package/src/router/{providers → __tests__}/RouterProvider.spec.ts +0 -0
  498. /package/src/security/{primitives → __tests__}/$issuer.spec.ts +0 -0
  499. /package/src/security/{primitives → __tests__}/$permission.spec.ts +0 -0
  500. /package/src/security/{primitives → __tests__}/$role.spec.ts +0 -0
  501. /package/src/security/{primitives → __tests__}/$serviceAccount.spec.ts +0 -0
  502. /package/src/security/{providers → __tests__}/SecurityProvider.spec.ts +0 -0
  503. /package/src/server/cookies/{providers → __tests__}/ServerCookiesProvider.spec.ts +0 -0
  504. /package/src/server/core/{primitives → __tests__}/$action.spec.ts +0 -0
  505. /package/src/server/core/{primitives → __tests__}/$middleware.spec.ts +0 -0
  506. /package/src/server/core/{primitives → __tests__}/$route.spec.ts +0 -0
  507. /package/src/server/core/{primitives → __tests__}/$sse.spec.ts +0 -0
  508. /package/src/server/core/{providers → __tests__}/BunHttpServerProvider.bun.spec.ts +0 -0
  509. /package/src/server/core/{services → __tests__}/HttpClient.spec.ts +0 -0
  510. /package/src/server/core/{providers → __tests__}/ServerLoggerProvider.spec.ts +0 -0
  511. /package/src/server/core/{services → __tests__}/UserAgentParser.spec.ts +0 -0
  512. /package/src/server/cors/{providers → __tests__}/ServerCorsProvider.spec.ts +0 -0
  513. /package/src/server/etag/{providers → __tests__}/ServerEtagProvider.spec.ts +0 -0
  514. /package/src/server/health/{providers → __tests__}/ServerHealthProvider.spec.ts +0 -0
  515. /package/src/server/links/{primitives → __tests__}/$remote.spec.ts +0 -0
  516. /package/src/server/links/{services → __tests__}/BatchEndpoint.spec.ts +0 -0
  517. /package/src/server/links/{providers → __tests__}/LinkProvider.spec.ts +0 -0
  518. /package/src/server/links/{providers → __tests__}/ServerLinksProvider.spec.ts +0 -0
  519. /package/src/server/metrics/{providers → __tests__}/ServerMetricsProvider.spec.ts +0 -0
  520. /package/src/server/proxy/{primitives → __tests__}/$proxy.spec.ts +0 -0
  521. /package/src/server/rate-limit/{providers → __tests__}/ServerRateLimitProvider.spec.ts +0 -0
  522. /package/src/server/static/{primitives → __tests__}/$serve.spec.ts +0 -0
  523. /package/src/server/swagger/{primitives → __tests__}/$swagger.spec.ts +0 -0
  524. /package/src/sms/{primitives → __tests__}/$sms.spec.ts +0 -0
  525. /package/src/sms/{providers → __tests__}/MemorySmsProvider.spec.ts +0 -0
  526. /package/src/system/{services → __tests__}/FileDetector.spec.ts +0 -0
  527. /package/src/system/{providers → __tests__}/NodeFileSystemProvider.spec.ts +0 -0
  528. /package/src/topic/core/{primitives → __tests__}/$subscriber.spec.ts +0 -0
  529. /package/src/topic/core/{providers → __tests__}/MemoryTopicProvider.spec.ts +0 -0
  530. /package/src/topic/redis/{providers → __tests__}/RedisTopicProvider.spec.ts +0 -0
  531. /package/src/websocket/{primitives → __tests__}/$channel.spec.ts +0 -0
@@ -1,26 +1,26 @@
1
- import * as alepha from "alepha";
1
+ import * as _$alepha from "alepha";
2
2
  import { Alepha, AlephaError, Page, PageQuery, Primitive, Static, StaticEncode, TNull, TObject, TOptional, TSchema, TUnion } from "alepha";
3
- import * as alepha_cache0 from "alepha/cache";
4
- import { CacheProvider } from "alepha/cache";
3
+ import { AuditService, CreateAudit } from "alepha/api/audits";
4
+ import * as _$alepha_bucket0 from "alepha/bucket";
5
5
  import { CryptoProvider, IssuerPrimitive, IssuerPrimitiveOptions, UserAccount } from "alepha/security";
6
- import * as alepha_server0 from "alepha/server";
7
- import * as alepha_orm0 from "alepha/orm";
6
+ import * as _$alepha_server0 from "alepha/server";
7
+ import * as _$alepha_orm0 from "alepha/orm";
8
8
  import { Page as Page$1, Repository } from "alepha/orm";
9
- import * as alepha_logger0 from "alepha/logger";
10
- import { AuditService, CreateAudit } from "alepha/api/audits";
11
- import * as alepha_server_links0 from "alepha/server/links";
12
- import * as alepha_api_notifications0 from "alepha/api/notifications";
9
+ import * as _$alepha_logger0 from "alepha/logger";
10
+ import * as _$alepha_server_links0 from "alepha/server/links";
11
+ import * as _$alepha_api_notifications0 from "alepha/api/notifications";
13
12
  import { OAuth2Profile, ServerAuthProvider, WithLinkFn, WithLoginFn } from "alepha/server/auth";
13
+ import * as _$alepha_cache0 from "alepha/cache";
14
+ import { CacheProvider } from "alepha/cache";
14
15
  import { DateTime, DateTimeProvider } from "alepha/datetime";
16
+ import * as _$alepha_api_jobs0 from "alepha/api/jobs";
15
17
  import { FileSystemProvider } from "alepha/system";
16
- import * as alepha_bucket0 from "alepha/bucket";
17
- import * as alepha_api_jobs0 from "alepha/api/jobs";
18
18
  import { ParameterPrimitive } from "alepha/api/parameters";
19
19
  import { VerificationController } from "alepha/api/verifications";
20
- import * as typebox from "typebox";
21
- import * as drizzle_orm0 from "drizzle-orm";
20
+ import * as _$typebox from "typebox";
21
+ import * as _$drizzle_orm0 from "drizzle-orm";
22
22
  import { BuildExtraConfigColumns, SQL, SQLWrapper } from "drizzle-orm";
23
- import * as drizzle_orm_pg_core0 from "drizzle-orm/pg-core";
23
+ import * as _$drizzle_orm_pg_core0 from "drizzle-orm/pg-core";
24
24
  import { LockConfig, LockStrength, PgColumn, PgColumnBuilderBase, PgDatabase, PgInsertValue, PgSelectBase, PgSequenceOptions, PgTableExtraConfigValue, PgTableWithColumns, PgTransaction, UpdateDeleteAction } from "drizzle-orm/pg-core";
25
25
  import { PgTransactionConfig } from "drizzle-orm/pg-core/session";
26
26
  import { LibSQLDatabase } from "drizzle-orm/libsql";
@@ -40,32 +40,32 @@ import { FileController } from "alepha/api/files";
40
40
  * - `"required"`: Field is shown and required.
41
41
  */
42
42
  type FieldRequirement = "none" | "optional" | "required";
43
- declare const realmAuthSettingsAtom: alepha.Atom<alepha.TObject<{
44
- displayName: alepha.TOptional<alepha.TString>;
45
- description: alepha.TOptional<alepha.TString>;
46
- logoUrl: alepha.TOptional<alepha.TString>;
47
- registrationAllowed: alepha.TBoolean;
48
- email: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
49
- username: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
50
- usernameRegExp: alepha.TString;
51
- phoneNumber: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
52
- verifyEmailRequired: alepha.TBoolean;
53
- verifyPhoneRequired: alepha.TBoolean;
54
- firstNameLastName: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
55
- resetPasswordAllowed: alepha.TBoolean;
56
- adminEmails: alepha.TArray<alepha.TString>;
57
- adminUsernames: alepha.TArray<alepha.TString>;
58
- passwordPolicy: alepha.TObject<{
59
- minLength: alepha.TInteger;
60
- requireUppercase: alepha.TBoolean;
61
- requireLowercase: alepha.TBoolean;
62
- requireNumbers: alepha.TBoolean;
63
- requireSpecialCharacters: alepha.TBoolean;
43
+ declare const realmAuthSettingsAtom: _$alepha.Atom<_$alepha.TObject<{
44
+ displayName: _$alepha.TOptional<_$alepha.TString>;
45
+ description: _$alepha.TOptional<_$alepha.TString>;
46
+ logoUrl: _$alepha.TOptional<_$alepha.TString>;
47
+ registrationAllowed: _$alepha.TBoolean;
48
+ email: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
49
+ username: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
50
+ usernameRegExp: _$alepha.TString;
51
+ phoneNumber: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
52
+ verifyEmailRequired: _$alepha.TBoolean;
53
+ verifyPhoneRequired: _$alepha.TBoolean;
54
+ firstNameLastName: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
55
+ resetPasswordAllowed: _$alepha.TBoolean;
56
+ adminEmails: _$alepha.TArray<_$alepha.TString>;
57
+ adminUsernames: _$alepha.TArray<_$alepha.TString>;
58
+ passwordPolicy: _$alepha.TObject<{
59
+ minLength: _$alepha.TInteger;
60
+ requireUppercase: _$alepha.TBoolean;
61
+ requireLowercase: _$alepha.TBoolean;
62
+ requireNumbers: _$alepha.TBoolean;
63
+ requireSpecialCharacters: _$alepha.TBoolean;
64
64
  }>;
65
- loginRateLimit: alepha.TObject<{
66
- ipMaxAttempts: alepha.TInteger;
67
- accountMaxAttempts: alepha.TInteger;
68
- windowMs: alepha.TInteger;
65
+ loginRateLimit: _$alepha.TObject<{
66
+ ipMaxAttempts: _$alepha.TInteger;
67
+ accountMaxAttempts: _$alepha.TInteger;
68
+ windowMs: _$alepha.TInteger;
69
69
  }>;
70
70
  }>, "alepha.api.users.realmAuthSettings">;
71
71
  type RealmAuthSettings = Static<typeof realmAuthSettingsAtom.schema>;
@@ -150,6 +150,36 @@ interface EntityPrimitiveOptions<T extends TObject, Keys = keyof Static<T>> {
150
150
  * Partial index condition. Only rows matching this SQL expression are indexed.
151
151
  */
152
152
  where?: SQL;
153
+ } | {
154
+ /**
155
+ * SQL expressions for expression-based indexes.
156
+ *
157
+ * Can include column references and SQL functions like `LOWER()`, `UPPER()`, etc.
158
+ * Columns and expressions can be mixed together.
159
+ *
160
+ * @example
161
+ * ```ts
162
+ * // Case-insensitive unique username per realm
163
+ * indexes: [{
164
+ * expressions: (self) => [self.realm, sql`LOWER(${self.username})`],
165
+ * unique: true,
166
+ * name: "users_realm_username_lower_idx",
167
+ * }]
168
+ * ```
169
+ */
170
+ expressions: (self: Record<Keys & string, any>) => (SQL | any)[];
171
+ /**
172
+ * Whether this should be a unique index (enforces uniqueness constraint).
173
+ */
174
+ unique?: boolean;
175
+ /**
176
+ * Custom name for the index. If not provided, generates name automatically.
177
+ */
178
+ name: string;
179
+ /**
180
+ * Partial index condition. Only rows matching this SQL expression are indexed.
181
+ */
182
+ where?: SQL;
153
183
  })[];
154
184
  /**
155
185
  * Foreign key constraints to maintain referential integrity.
@@ -260,6 +290,7 @@ declare const PG_IDENTITY: unique symbol;
260
290
  declare const PG_ENUM: unique symbol;
261
291
  declare const PG_REF: unique symbol;
262
292
  declare const PG_GENERATED: unique symbol;
293
+ declare const PG_ORGANIZATION: unique symbol;
263
294
  /**
264
295
  * @deprecated Use `PG_IDENTITY` instead.
265
296
  */
@@ -275,6 +306,7 @@ type PgSymbols = {
275
306
  [PG_REF]: PgRefOptions;
276
307
  [PG_ENUM]: PgEnumOptions;
277
308
  [PG_GENERATED]: PgGeneratedOptions;
309
+ [PG_ORGANIZATION]: {};
278
310
  /**
279
311
  * @deprecated Use `PG_IDENTITY` instead.
280
312
  */
@@ -1091,7 +1123,7 @@ declare abstract class ModelBuilder {
1091
1123
  protected buildTableConfig<TConfig, TSelf>(entity: EntityPrimitive, builders: TableConfigBuilders<TConfig>, tableResolver?: (entityName: string) => any, customConfigHandler?: (config: any, self: TSelf) => TConfig[]): ((self: TSelf) => TConfig[]) | undefined;
1092
1124
  }
1093
1125
  //#endregion
1094
- //#region ../../../../node_modules/@electric-sql/pglite/dist/pglite-SIPwY9Cm.d.ts
1126
+ //#region ../../../../node_modules/@electric-sql/pglite/dist/pglite-BZlQ7pL-.d.ts
1095
1127
  type MessageName = 'parseComplete' | 'bindComplete' | 'closeComplete' | 'noData' | 'portalSuspended' | 'replicationStart' | 'emptyQuery' | 'copyDone' | 'copyData' | 'rowDescription' | 'parameterDescription' | 'parameterStatus' | 'backendKeyData' | 'notification' | 'readyForQuery' | 'commandComplete' | 'dataRow' | 'copyInResponse' | 'copyOutResponse' | 'authenticationOk' | 'authenticationMD5Password' | 'authenticationCleartextPassword' | 'authenticationSASL' | 'authenticationSASLContinue' | 'authenticationSASLFinal' | 'error' | 'notice';
1096
1128
  type BackendMessage = {
1097
1129
  name: MessageName;
@@ -1163,6 +1195,7 @@ interface PostgresMod extends Omit<EmscriptenModule, 'preInit' | 'preRun' | 'pos
1163
1195
  thisProgram: string;
1164
1196
  stdin: (() => number | null) | null;
1165
1197
  FS: FS;
1198
+ wasmMemory: WebAssembly.Memory;
1166
1199
  PROXYFS: Emscripten.FileSystemType;
1167
1200
  WASM_PREFIX: string;
1168
1201
  pg_extensions: Record<string, Promise<Blob | null>>;
@@ -1286,7 +1319,8 @@ interface PGliteOptions<TExtensions extends Extensions = Extensions> {
1286
1319
  extensions?: TExtensions;
1287
1320
  loadDataDir?: Blob | File;
1288
1321
  initialMemory?: number;
1289
- wasmModule?: WebAssembly.Module;
1322
+ pgliteWasmModule?: WebAssembly.Module;
1323
+ initdbWasmModule?: WebAssembly.Module;
1290
1324
  fsBundle?: Blob | File;
1291
1325
  parsers?: ParserOptions;
1292
1326
  serializers?: SerializerOptions;
@@ -5955,7 +5989,7 @@ declare const upPgSnapshot: (snapshot: Record<string, unknown>) => {
5955
5989
  //#endregion
5956
5990
  //#region ../../src/orm/core/providers/DrizzleKitProvider.d.ts
5957
5991
  declare class DrizzleKitProvider {
5958
- protected readonly log: alepha_logger0.Logger;
5992
+ protected readonly log: _$alepha_logger0.Logger;
5959
5993
  protected readonly dateTime: DateTimeProvider;
5960
5994
  protected readonly alepha: Alepha;
5961
5995
  /**
@@ -6017,18 +6051,16 @@ declare class DrizzleKitProvider {
6017
6051
  */
6018
6052
  protected pushPostgres(kit: typeof api_d_exports, models: Record<string, unknown>, provider: DatabaseProvider): Promise<void>;
6019
6053
  /**
6020
- * Run the statements returned by Drizzle Kit's pushSchema, with safety filters and logging.
6054
+ * Execute a list of SQL statements against the provider.
6021
6055
  */
6022
- protected runPushResult(result: {
6023
- statementsToExecute: string[];
6024
- warnings: string[];
6025
- hasDataLoss: boolean;
6026
- }, provider: DatabaseProvider): Promise<void>;
6056
+ protected executeStatements(statements: string[], provider: DatabaseProvider): Promise<void>;
6027
6057
  /**
6028
- * Execute migration statements as a fallback when push sync is not available.
6029
- * Used for drivers that don't support Drizzle Kit introspection (e.g. PgLite).
6058
+ * Execute SQL statements, ignoring "already exists" errors.
6059
+ *
6060
+ * Used by the fallback migration path where push may have partially
6061
+ * applied changes before erroring, leaving some objects already created.
6030
6062
  */
6031
- protected executeFallbackStatements(statements: string[], provider: DatabaseProvider): Promise<void>;
6063
+ protected executeStatementsLenient(statements: string[], provider: DatabaseProvider): Promise<void>;
6032
6064
  protected createSchemaIfNotExists(provider: DatabaseProvider, schemaName: string): Promise<void>;
6033
6065
  /**
6034
6066
  * Wrap a Drizzle PgDatabase instance for compatibility with Drizzle Kit.
@@ -6038,15 +6070,6 @@ declare class DrizzleKitProvider {
6038
6070
  * extends Array directly — no .rows property.
6039
6071
  */
6040
6072
  protected wrapDbForDrizzleKit(db: any): any;
6041
- /**
6042
- * Suppress Drizzle Kit's spinner output during a callback.
6043
- *
6044
- * Drizzle Kit uses hanji's renderWithTask with a setInterval-based spinner.
6045
- * If the wrapped task throws, the interval is never cleared and leaks
6046
- * spinner frames to stdout. We keep the filter active until the next
6047
- * tick after the promise settles to catch any straggling writes.
6048
- */
6049
- protected muteSpinner<T>(fn: () => Promise<T>): Promise<T>;
6050
6073
  /**
6051
6074
  * Try to load the official Drizzle Kit API.
6052
6075
  */
@@ -6058,7 +6081,7 @@ type SQLLike = SQLWrapper | string;
6058
6081
  declare abstract class DatabaseProvider {
6059
6082
  protected readonly alepha: Alepha;
6060
6083
  protected readonly dateTime: DateTimeProvider;
6061
- protected readonly log: alepha_logger0.Logger;
6084
+ protected readonly log: _$alepha_logger0.Logger;
6062
6085
  protected abstract readonly builder: ModelBuilder;
6063
6086
  protected readonly kit: DrizzleKitProvider;
6064
6087
  abstract readonly db: PgDatabase<any>;
@@ -6216,7 +6239,7 @@ declare class QueryManager {
6216
6239
  createPagination<T>(entities: T[], limit?: number, offset?: number, sort?: Array<{
6217
6240
  column: string;
6218
6241
  direction: "asc" | "desc";
6219
- }>): alepha.Page<T>;
6242
+ }>): _$alepha.Page<T>;
6220
6243
  }
6221
6244
  interface PgJoin {
6222
6245
  table: string;
@@ -6250,7 +6273,7 @@ declare class PgRelationManager {
6250
6273
  declare abstract class Repository$1<T extends TObject> {
6251
6274
  readonly entity: EntityPrimitive<T>;
6252
6275
  readonly provider: DatabaseProvider;
6253
- protected readonly log: alepha_logger0.Logger;
6276
+ protected readonly log: _$alepha_logger0.Logger;
6254
6277
  protected readonly relationManager: PgRelationManager;
6255
6278
  protected readonly queryManager: QueryManager;
6256
6279
  protected readonly dateTimeProvider: DateTimeProvider;
@@ -6328,15 +6351,15 @@ declare abstract class Repository$1<T extends TObject> {
6328
6351
  /**
6329
6352
  * Start a SELECT query on the table.
6330
6353
  */
6331
- protected rawSelect(opts?: StatementOptions): drizzle_orm_pg_core0.PgSelectBase<string, Record<string, PgColumn<drizzle_orm0.ColumnBaseConfig<drizzle_orm0.ColumnDataType, string>, {}, {}>>, "single", Record<string, "not-null">, false, never, {
6354
+ protected rawSelect(opts?: StatementOptions): _$drizzle_orm_pg_core0.PgSelectBase<string, Record<string, PgColumn<_$drizzle_orm0.ColumnBaseConfig<_$drizzle_orm0.ColumnDataType, string>, {}, {}>>, "single", Record<string, "not-null">, false, never, {
6332
6355
  [x: string]: unknown;
6333
6356
  }[], {
6334
- [x: string]: PgColumn<drizzle_orm0.ColumnBaseConfig<drizzle_orm0.ColumnDataType, string>, {}, {}>;
6357
+ [x: string]: PgColumn<_$drizzle_orm0.ColumnBaseConfig<_$drizzle_orm0.ColumnDataType, string>, {}, {}>;
6335
6358
  }>;
6336
6359
  /**
6337
6360
  * Start a SELECT DISTINCT query on the table.
6338
6361
  */
6339
- protected rawSelectDistinct(opts?: StatementOptions, columns?: (keyof Static<T>)[]): drizzle_orm_pg_core0.PgSelectBase<string, Record<string, any>, "partial", Record<string, "not-null">, false, never, {
6362
+ protected rawSelectDistinct(opts?: StatementOptions, columns?: (keyof Static<T>)[]): _$drizzle_orm_pg_core0.PgSelectBase<string, Record<string, any>, "partial", Record<string, "not-null">, false, never, {
6340
6363
  [x: string]: any;
6341
6364
  }[], {
6342
6365
  [x: string]: any;
@@ -6344,15 +6367,15 @@ declare abstract class Repository$1<T extends TObject> {
6344
6367
  /**
6345
6368
  * Start an INSERT query on the table.
6346
6369
  */
6347
- protected rawInsert(opts?: StatementOptions): drizzle_orm_pg_core0.PgInsertBuilder<PgTableWithColumns<SchemaToTableConfig<T>>, any, false>;
6370
+ protected rawInsert(opts?: StatementOptions): _$drizzle_orm_pg_core0.PgInsertBuilder<PgTableWithColumns<SchemaToTableConfig<T>>, any, false>;
6348
6371
  /**
6349
6372
  * Start an UPDATE query on the table.
6350
6373
  */
6351
- protected rawUpdate(opts?: StatementOptions): drizzle_orm_pg_core0.PgUpdateBuilder<PgTableWithColumns<SchemaToTableConfig<T>>, any>;
6374
+ protected rawUpdate(opts?: StatementOptions): _$drizzle_orm_pg_core0.PgUpdateBuilder<PgTableWithColumns<SchemaToTableConfig<T>>, any>;
6352
6375
  /**
6353
6376
  * Start a DELETE query on the table.
6354
6377
  */
6355
- protected rawDelete(opts?: StatementOptions): drizzle_orm_pg_core0.PgDeleteBase<PgTableWithColumns<SchemaToTableConfig<T>>, any, undefined, undefined, false, never>;
6378
+ protected rawDelete(opts?: StatementOptions): _$drizzle_orm_pg_core0.PgDeleteBase<PgTableWithColumns<SchemaToTableConfig<T>>, any, undefined, undefined, false, never>;
6356
6379
  /**
6357
6380
  * Create a Drizzle `select` query based on a JSON query object.
6358
6381
  *
@@ -6541,6 +6564,9 @@ declare abstract class Repository$1<T extends TObject> {
6541
6564
  force?: boolean;
6542
6565
  }): PgQueryWhereOrSQL<T>;
6543
6566
  protected deletedAt(): PgAttrField | undefined;
6567
+ protected withOrganization(where: PgQueryWhereOrSQL<T>): PgQueryWhereOrSQL<T>;
6568
+ protected stampOrganization(data: any): void;
6569
+ protected organizationField(): PgAttrField | undefined;
6544
6570
  /**
6545
6571
  * Convert something to valid Pg Insert Value.
6546
6572
  */
@@ -6581,7 +6607,7 @@ declare abstract class Repository$1<T extends TObject> {
6581
6607
  */
6582
6608
  protected getPrimaryKey(schema: TObject): {
6583
6609
  key: string;
6584
- col: PgColumn<drizzle_orm0.ColumnBaseConfig<drizzle_orm0.ColumnDataType, string>, {}, {}>;
6610
+ col: PgColumn<_$drizzle_orm0.ColumnBaseConfig<_$drizzle_orm0.ColumnDataType, string>, {}, {}>;
6585
6611
  type: TSchema;
6586
6612
  };
6587
6613
  }
@@ -6650,8 +6676,8 @@ type WithSQL<T> = { [P in keyof T]?: T[P] | SQL };
6650
6676
  * - `d1://BINDING_NAME` — Cloudflare D1
6651
6677
  * - `hyperdrive://BINDING_NAME` — Cloudflare Hyperdrive
6652
6678
  */
6653
- declare const databaseEnvSchema: alepha.TObject<{
6654
- DATABASE_URL: alepha.TOptional<alepha.TString>;
6679
+ declare const databaseEnvSchema: _$alepha.TObject<{
6680
+ DATABASE_URL: _$alepha.TOptional<_$alepha.TString>;
6655
6681
  /**
6656
6682
  * Enable or disable push-based schema synchronization (drizzle-kit push).
6657
6683
  *
@@ -6659,7 +6685,7 @@ declare const databaseEnvSchema: alepha.TObject<{
6659
6685
  * Set to `false` in development to skip automatic schema sync
6660
6686
  * (e.g. when managing migrations manually).
6661
6687
  */
6662
- DATABASE_SYNC: alepha.TOptional<alepha.TBoolean>;
6688
+ DATABASE_SYNC: _$alepha.TOptional<_$alepha.TBoolean>;
6663
6689
  }>;
6664
6690
  declare module "alepha" {
6665
6691
  interface Env extends Partial<Static<typeof databaseEnvSchema>> {}
@@ -6685,37 +6711,37 @@ declare class UserAudits {
6685
6711
  userEmail?: string | undefined;
6686
6712
  resourceType?: string | undefined;
6687
6713
  resourceId?: string | undefined;
6688
- metadata?: typebox.StaticRecord<[], "Decode", {}, {
6689
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6690
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6691
- type: alepha.TString;
6692
- action: alepha.TString;
6693
- severity: PgAttr<alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6694
- userId: alepha.TOptional<alepha.TString>;
6695
- userRealm: alepha.TOptional<alepha.TString>;
6696
- userEmail: alepha.TOptional<alepha.TString>;
6697
- resourceType: alepha.TOptional<alepha.TString>;
6698
- resourceId: alepha.TOptional<alepha.TString>;
6699
- description: alepha.TOptional<alepha.TString>;
6700
- metadata: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
6701
- ipAddress: alepha.TOptional<alepha.TString>;
6702
- userAgent: alepha.TOptional<alepha.TString>;
6703
- sessionId: alepha.TOptional<alepha.TString>;
6704
- requestId: alepha.TOptional<alepha.TString>;
6705
- success: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
6706
- errorMessage: alepha.TOptional<alepha.TString>;
6707
- }, string, alepha.TAny> | undefined;
6714
+ metadata?: _$typebox.StaticRecord<[], "Decode", {}, {
6715
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6716
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6717
+ type: _$alepha.TString;
6718
+ action: _$alepha.TString;
6719
+ severity: PgAttr<_$alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6720
+ userId: _$alepha.TOptional<_$alepha.TString>;
6721
+ userRealm: _$alepha.TOptional<_$alepha.TString>;
6722
+ userEmail: _$alepha.TOptional<_$alepha.TString>;
6723
+ resourceType: _$alepha.TOptional<_$alepha.TString>;
6724
+ resourceId: _$alepha.TOptional<_$alepha.TString>;
6725
+ description: _$alepha.TOptional<_$alepha.TString>;
6726
+ metadata: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
6727
+ ipAddress: _$alepha.TOptional<_$alepha.TString>;
6728
+ userAgent: _$alepha.TOptional<_$alepha.TString>;
6729
+ sessionId: _$alepha.TOptional<_$alepha.TString>;
6730
+ requestId: _$alepha.TOptional<_$alepha.TString>;
6731
+ success: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
6732
+ errorMessage: _$alepha.TOptional<_$alepha.TString>;
6733
+ }, string, _$alepha.TAny> | undefined;
6708
6734
  ipAddress?: string | undefined;
6709
6735
  userAgent?: string | undefined;
6710
6736
  sessionId?: string | undefined;
6711
6737
  requestId?: string | undefined;
6712
6738
  errorMessage?: string | undefined;
6713
6739
  type: string;
6740
+ id: string;
6741
+ createdAt: string;
6714
6742
  action: string;
6715
6743
  severity: "info" | "warning" | "critical";
6716
6744
  success: boolean;
6717
- id: string;
6718
- createdAt: string;
6719
6745
  }>;
6720
6746
  /**
6721
6747
  * Record an authentication-related audit event.
@@ -6727,37 +6753,37 @@ declare class UserAudits {
6727
6753
  userEmail?: string | undefined;
6728
6754
  resourceType?: string | undefined;
6729
6755
  resourceId?: string | undefined;
6730
- metadata?: typebox.StaticRecord<[], "Decode", {}, {
6731
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6732
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6733
- type: alepha.TString;
6734
- action: alepha.TString;
6735
- severity: PgAttr<alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6736
- userId: alepha.TOptional<alepha.TString>;
6737
- userRealm: alepha.TOptional<alepha.TString>;
6738
- userEmail: alepha.TOptional<alepha.TString>;
6739
- resourceType: alepha.TOptional<alepha.TString>;
6740
- resourceId: alepha.TOptional<alepha.TString>;
6741
- description: alepha.TOptional<alepha.TString>;
6742
- metadata: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
6743
- ipAddress: alepha.TOptional<alepha.TString>;
6744
- userAgent: alepha.TOptional<alepha.TString>;
6745
- sessionId: alepha.TOptional<alepha.TString>;
6746
- requestId: alepha.TOptional<alepha.TString>;
6747
- success: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
6748
- errorMessage: alepha.TOptional<alepha.TString>;
6749
- }, string, alepha.TAny> | undefined;
6756
+ metadata?: _$typebox.StaticRecord<[], "Decode", {}, {
6757
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6758
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6759
+ type: _$alepha.TString;
6760
+ action: _$alepha.TString;
6761
+ severity: PgAttr<_$alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6762
+ userId: _$alepha.TOptional<_$alepha.TString>;
6763
+ userRealm: _$alepha.TOptional<_$alepha.TString>;
6764
+ userEmail: _$alepha.TOptional<_$alepha.TString>;
6765
+ resourceType: _$alepha.TOptional<_$alepha.TString>;
6766
+ resourceId: _$alepha.TOptional<_$alepha.TString>;
6767
+ description: _$alepha.TOptional<_$alepha.TString>;
6768
+ metadata: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
6769
+ ipAddress: _$alepha.TOptional<_$alepha.TString>;
6770
+ userAgent: _$alepha.TOptional<_$alepha.TString>;
6771
+ sessionId: _$alepha.TOptional<_$alepha.TString>;
6772
+ requestId: _$alepha.TOptional<_$alepha.TString>;
6773
+ success: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
6774
+ errorMessage: _$alepha.TOptional<_$alepha.TString>;
6775
+ }, string, _$alepha.TAny> | undefined;
6750
6776
  ipAddress?: string | undefined;
6751
6777
  userAgent?: string | undefined;
6752
6778
  sessionId?: string | undefined;
6753
6779
  requestId?: string | undefined;
6754
6780
  errorMessage?: string | undefined;
6755
6781
  type: string;
6782
+ id: string;
6783
+ createdAt: string;
6756
6784
  action: string;
6757
6785
  severity: "info" | "warning" | "critical";
6758
6786
  success: boolean;
6759
- id: string;
6760
- createdAt: string;
6761
6787
  }>;
6762
6788
  /**
6763
6789
  * Record a generic audit event.
@@ -6769,37 +6795,37 @@ declare class UserAudits {
6769
6795
  userEmail?: string | undefined;
6770
6796
  resourceType?: string | undefined;
6771
6797
  resourceId?: string | undefined;
6772
- metadata?: typebox.StaticRecord<[], "Decode", {}, {
6773
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6774
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6775
- type: alepha.TString;
6776
- action: alepha.TString;
6777
- severity: PgAttr<alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6778
- userId: alepha.TOptional<alepha.TString>;
6779
- userRealm: alepha.TOptional<alepha.TString>;
6780
- userEmail: alepha.TOptional<alepha.TString>;
6781
- resourceType: alepha.TOptional<alepha.TString>;
6782
- resourceId: alepha.TOptional<alepha.TString>;
6783
- description: alepha.TOptional<alepha.TString>;
6784
- metadata: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
6785
- ipAddress: alepha.TOptional<alepha.TString>;
6786
- userAgent: alepha.TOptional<alepha.TString>;
6787
- sessionId: alepha.TOptional<alepha.TString>;
6788
- requestId: alepha.TOptional<alepha.TString>;
6789
- success: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
6790
- errorMessage: alepha.TOptional<alepha.TString>;
6791
- }, string, alepha.TAny> | undefined;
6798
+ metadata?: _$typebox.StaticRecord<[], "Decode", {}, {
6799
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
6800
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
6801
+ type: _$alepha.TString;
6802
+ action: _$alepha.TString;
6803
+ severity: PgAttr<_$alepha.TUnsafe<"info" | "warning" | "critical">, typeof PG_DEFAULT>;
6804
+ userId: _$alepha.TOptional<_$alepha.TString>;
6805
+ userRealm: _$alepha.TOptional<_$alepha.TString>;
6806
+ userEmail: _$alepha.TOptional<_$alepha.TString>;
6807
+ resourceType: _$alepha.TOptional<_$alepha.TString>;
6808
+ resourceId: _$alepha.TOptional<_$alepha.TString>;
6809
+ description: _$alepha.TOptional<_$alepha.TString>;
6810
+ metadata: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
6811
+ ipAddress: _$alepha.TOptional<_$alepha.TString>;
6812
+ userAgent: _$alepha.TOptional<_$alepha.TString>;
6813
+ sessionId: _$alepha.TOptional<_$alepha.TString>;
6814
+ requestId: _$alepha.TOptional<_$alepha.TString>;
6815
+ success: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
6816
+ errorMessage: _$alepha.TOptional<_$alepha.TString>;
6817
+ }, string, _$alepha.TAny> | undefined;
6792
6818
  ipAddress?: string | undefined;
6793
6819
  userAgent?: string | undefined;
6794
6820
  sessionId?: string | undefined;
6795
6821
  requestId?: string | undefined;
6796
6822
  errorMessage?: string | undefined;
6797
6823
  type: string;
6824
+ id: string;
6825
+ createdAt: string;
6798
6826
  action: string;
6799
6827
  severity: "info" | "warning" | "critical";
6800
6828
  success: boolean;
6801
- id: string;
6802
- createdAt: string;
6803
6829
  }>;
6804
6830
  }
6805
6831
  //#endregion
@@ -6816,58 +6842,59 @@ declare class UserBuckets {
6816
6842
  /**
6817
6843
  * Bucket for user avatar storage.
6818
6844
  */
6819
- readonly avatars: alepha_bucket0.BucketPrimitive;
6845
+ readonly avatars: _$alepha_bucket0.BucketPrimitive;
6820
6846
  }
6821
6847
  //#endregion
6822
6848
  //#region ../../src/api/users/entities/identities.d.ts
6823
- declare const identities: alepha_orm0.EntityPrimitive<alepha.TObject<{
6824
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
6825
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
6826
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6827
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6828
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
6829
- password: alepha.TOptional<alepha.TString>;
6830
- provider: alepha.TString;
6831
- providerUserId: alepha.TOptional<alepha.TString>;
6832
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
6849
+ declare const identities: _$alepha_orm0.EntityPrimitive<_$alepha.TObject<{
6850
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
6851
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
6852
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6853
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6854
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
6855
+ password: _$alepha.TOptional<_$alepha.TString>;
6856
+ provider: _$alepha.TString;
6857
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
6858
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
6833
6859
  }>>;
6834
6860
  type IdentityEntity = Static<typeof identities.schema>;
6835
6861
  //#endregion
6836
6862
  //#region ../../src/api/users/entities/sessions.d.ts
6837
- declare const sessions: alepha_orm0.EntityPrimitive<alepha.TObject<{
6838
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
6839
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
6840
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6841
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6842
- refreshToken: alepha.TString;
6843
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
6844
- expiresAt: alepha.TString;
6845
- ip: alepha.TOptional<alepha.TString>;
6846
- userAgent: alepha.TOptional<alepha.TObject<{
6847
- os: alepha.TString;
6848
- browser: alepha.TString;
6849
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
6863
+ declare const sessions: _$alepha_orm0.EntityPrimitive<_$alepha.TObject<{
6864
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
6865
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
6866
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6867
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6868
+ refreshToken: _$alepha.TString;
6869
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
6870
+ expiresAt: _$alepha.TString;
6871
+ ip: _$alepha.TOptional<_$alepha.TString>;
6872
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
6873
+ os: _$alepha.TString;
6874
+ browser: _$alepha.TString;
6875
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
6850
6876
  }>>;
6851
6877
  }>>;
6852
6878
  type SessionEntity = Static<typeof sessions.schema>;
6853
6879
  //#endregion
6854
6880
  //#region ../../src/api/users/entities/users.d.ts
6855
6881
  declare const DEFAULT_USER_REALM_NAME = "default";
6856
- declare const users: alepha_orm0.EntityPrimitive<alepha.TObject<{
6857
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
6858
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
6859
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6860
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6861
- realm: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_DEFAULT>;
6862
- username: alepha.TOptional<alepha.TString>;
6863
- email: alepha.TOptional<alepha.TString>;
6864
- phoneNumber: alepha.TOptional<alepha.TString>;
6865
- roles: alepha_orm0.PgAttr<alepha.TArray<alepha.TString>, typeof alepha_orm0.PG_DEFAULT>;
6866
- firstName: alepha.TOptional<alepha.TString>;
6867
- lastName: alepha.TOptional<alepha.TString>;
6868
- picture: alepha.TOptional<alepha.TString>;
6869
- enabled: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
6870
- emailVerified: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
6882
+ declare const users: _$alepha_orm0.EntityPrimitive<_$alepha.TObject<{
6883
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
6884
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
6885
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6886
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
6887
+ realm: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_DEFAULT>;
6888
+ username: _$alepha.TOptional<_$alepha.TString>;
6889
+ email: _$alepha.TOptional<_$alepha.TString>;
6890
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
6891
+ roles: _$alepha_orm0.PgAttr<_$alepha.TArray<_$alepha.TString>, typeof _$alepha_orm0.PG_DEFAULT>;
6892
+ firstName: _$alepha.TOptional<_$alepha.TString>;
6893
+ lastName: _$alepha.TOptional<_$alepha.TString>;
6894
+ picture: _$alepha.TOptional<_$alepha.TString>;
6895
+ enabled: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
6896
+ emailVerified: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
6897
+ organizationId: _$alepha_orm0.PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof _$alepha_orm0.PG_ORGANIZATION>;
6871
6898
  }>>;
6872
6899
  type UserEntity = Static<typeof users.schema>;
6873
6900
  //#endregion
@@ -6889,11 +6916,13 @@ type RealmPrimitive = IssuerPrimitive & WithLinkFn & WithLoginFn;
6889
6916
  declare const $realm: (options?: RealmOptions) => RealmPrimitive;
6890
6917
  interface RealmFeatures {
6891
6918
  /**
6892
- * Enable session purge functionality for cleaning up expired sessions.
6919
+ * Will enable Job module.
6920
+ *
6921
+ * - Enable session purge functionality for cleaning up expired sessions.
6893
6922
  *
6894
6923
  * @default false
6895
6924
  */
6896
- sessionPurge?: boolean;
6925
+ jobs?: boolean;
6897
6926
  /**
6898
6927
  * Enable notification system for password reset, verification emails, etc.
6899
6928
  *
@@ -6988,47 +7017,48 @@ interface Realm {
6988
7017
  }
6989
7018
  declare class RealmProvider {
6990
7019
  protected readonly alepha: Alepha;
6991
- protected readonly defaultIdentities: Repository<alepha.TObject<{
6992
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
6993
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
6994
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6995
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
6996
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
6997
- password: alepha.TOptional<alepha.TString>;
6998
- provider: alepha.TString;
6999
- providerUserId: alepha.TOptional<alepha.TString>;
7000
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
7020
+ protected readonly defaultIdentities: Repository<_$alepha.TObject<{
7021
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7022
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7023
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7024
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7025
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
7026
+ password: _$alepha.TOptional<_$alepha.TString>;
7027
+ provider: _$alepha.TString;
7028
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
7029
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
7001
7030
  }>>;
7002
- protected readonly defaultSessions: Repository<alepha.TObject<{
7003
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
7004
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
7005
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7006
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7007
- refreshToken: alepha.TString;
7008
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
7009
- expiresAt: alepha.TString;
7010
- ip: alepha.TOptional<alepha.TString>;
7011
- userAgent: alepha.TOptional<alepha.TObject<{
7012
- os: alepha.TString;
7013
- browser: alepha.TString;
7014
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7031
+ protected readonly defaultSessions: Repository<_$alepha.TObject<{
7032
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7033
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7034
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7035
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7036
+ refreshToken: _$alepha.TString;
7037
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
7038
+ expiresAt: _$alepha.TString;
7039
+ ip: _$alepha.TOptional<_$alepha.TString>;
7040
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
7041
+ os: _$alepha.TString;
7042
+ browser: _$alepha.TString;
7043
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7015
7044
  }>>;
7016
7045
  }>>;
7017
- protected readonly defaultUsers: Repository<alepha.TObject<{
7018
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
7019
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
7020
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7021
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7022
- realm: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_DEFAULT>;
7023
- username: alepha.TOptional<alepha.TString>;
7024
- email: alepha.TOptional<alepha.TString>;
7025
- phoneNumber: alepha.TOptional<alepha.TString>;
7026
- roles: alepha_orm0.PgAttr<alepha.TArray<alepha.TString>, typeof alepha_orm0.PG_DEFAULT>;
7027
- firstName: alepha.TOptional<alepha.TString>;
7028
- lastName: alepha.TOptional<alepha.TString>;
7029
- picture: alepha.TOptional<alepha.TString>;
7030
- enabled: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
7031
- emailVerified: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
7046
+ protected readonly defaultUsers: Repository<_$alepha.TObject<{
7047
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7048
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7049
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7050
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7051
+ realm: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_DEFAULT>;
7052
+ username: _$alepha.TOptional<_$alepha.TString>;
7053
+ email: _$alepha.TOptional<_$alepha.TString>;
7054
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7055
+ roles: _$alepha_orm0.PgAttr<_$alepha.TArray<_$alepha.TString>, typeof _$alepha_orm0.PG_DEFAULT>;
7056
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7057
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7058
+ picture: _$alepha.TOptional<_$alepha.TString>;
7059
+ enabled: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
7060
+ emailVerified: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
7061
+ organizationId: _$alepha_orm0.PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof _$alepha_orm0.PG_ORGANIZATION>;
7032
7062
  }>>;
7033
7063
  protected realms: Map<string, Realm>;
7034
7064
  register(realmName: string, realmOptions?: RealmOptions): Realm;
@@ -7042,31 +7072,31 @@ declare class RealmProvider {
7042
7072
  }
7043
7073
  //#endregion
7044
7074
  //#region ../../src/api/users/schemas/identityQuerySchema.d.ts
7045
- declare const identityQuerySchema: alepha.TObject<{
7046
- page: alepha.TOptional<alepha.TInteger>;
7047
- size: alepha.TOptional<alepha.TInteger>;
7048
- sort: alepha.TOptional<alepha.TString>;
7049
- userId: alepha.TOptional<alepha.TString>;
7050
- provider: alepha.TOptional<alepha.TString>;
7075
+ declare const identityQuerySchema: _$alepha.TObject<{
7076
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7077
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7078
+ sort: _$alepha.TOptional<_$alepha.TString>;
7079
+ userId: _$alepha.TOptional<_$alepha.TString>;
7080
+ provider: _$alepha.TOptional<_$alepha.TString>;
7051
7081
  }>;
7052
7082
  type IdentityQuery = Static<typeof identityQuerySchema>;
7053
7083
  //#endregion
7054
7084
  //#region ../../src/api/users/services/IdentityService.d.ts
7055
7085
  declare class IdentityService {
7056
7086
  protected readonly alepha: Alepha;
7057
- protected readonly log: alepha_logger0.Logger;
7087
+ protected readonly log: _$alepha_logger0.Logger;
7058
7088
  protected readonly realmProvider: RealmProvider;
7059
7089
  protected userAudits(realmName?: string): UserAudits | undefined;
7060
- identities(userRealmName?: string): alepha_orm0.Repository<alepha.TObject<{
7061
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
7062
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
7063
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7064
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7065
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
7066
- password: alepha.TOptional<alepha.TString>;
7067
- provider: alepha.TString;
7068
- providerUserId: alepha.TOptional<alepha.TString>;
7069
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
7090
+ identities(userRealmName?: string): _$alepha_orm0.Repository<_$alepha.TObject<{
7091
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7092
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7093
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7094
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7095
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
7096
+ password: _$alepha.TOptional<_$alepha.TString>;
7097
+ provider: _$alepha.TString;
7098
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
7099
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
7070
7100
  }>>;
7071
7101
  /**
7072
7102
  * Find identities with pagination and filtering.
@@ -7090,91 +7120,91 @@ declare class AdminIdentityController {
7090
7120
  /**
7091
7121
  * Find identities with pagination and filtering.
7092
7122
  */
7093
- readonly findIdentities: alepha_server0.ActionPrimitiveFn<{
7094
- query: alepha.TObject<{
7095
- page: alepha.TOptional<alepha.TInteger>;
7096
- size: alepha.TOptional<alepha.TInteger>;
7097
- sort: alepha.TOptional<alepha.TString>;
7098
- userId: alepha.TOptional<alepha.TString>;
7099
- provider: alepha.TOptional<alepha.TString>;
7100
- userRealmName: alepha.TOptional<alepha.TString>;
7101
- }>;
7102
- response: alepha.TPage<alepha.TObject<{
7103
- userId: PgAttr<alepha.TString, typeof PG_REF>;
7104
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7105
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7106
- provider: alepha.TString;
7107
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7108
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7109
- providerUserId: alepha.TOptional<alepha.TString>;
7110
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
7123
+ readonly findIdentities: _$alepha_server0.ActionPrimitiveFn<{
7124
+ query: _$alepha.TObject<{
7125
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7126
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7127
+ sort: _$alepha.TOptional<_$alepha.TString>;
7128
+ userId: _$alepha.TOptional<_$alepha.TString>;
7129
+ provider: _$alepha.TOptional<_$alepha.TString>;
7130
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7131
+ }>;
7132
+ response: _$alepha.TPage<_$alepha.TObject<{
7133
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7134
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7135
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7136
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7137
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
7138
+ provider: _$alepha.TString;
7139
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
7140
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
7111
7141
  }>>;
7112
7142
  }>;
7113
7143
  /**
7114
7144
  * Get an identity by ID.
7115
7145
  */
7116
- readonly getIdentity: alepha_server0.ActionPrimitiveFn<{
7117
- params: alepha.TObject<{
7118
- id: alepha.TString;
7146
+ readonly getIdentity: _$alepha_server0.ActionPrimitiveFn<{
7147
+ params: _$alepha.TObject<{
7148
+ id: _$alepha.TString;
7119
7149
  }>;
7120
- query: alepha.TObject<{
7121
- userRealmName: alepha.TOptional<alepha.TString>;
7150
+ query: _$alepha.TObject<{
7151
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7122
7152
  }>;
7123
- response: alepha.TObject<{
7124
- userId: PgAttr<alepha.TString, typeof PG_REF>;
7125
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7126
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7127
- provider: alepha.TString;
7128
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7129
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7130
- providerUserId: alepha.TOptional<alepha.TString>;
7131
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
7153
+ response: _$alepha.TObject<{
7154
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7155
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7156
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7157
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7158
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
7159
+ provider: _$alepha.TString;
7160
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
7161
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
7132
7162
  }>;
7133
7163
  }>;
7134
7164
  /**
7135
7165
  * Delete an identity.
7136
7166
  */
7137
- readonly deleteIdentity: alepha_server0.ActionPrimitiveFn<{
7138
- params: alepha.TObject<{
7139
- id: alepha.TString;
7167
+ readonly deleteIdentity: _$alepha_server0.ActionPrimitiveFn<{
7168
+ params: _$alepha.TObject<{
7169
+ id: _$alepha.TString;
7140
7170
  }>;
7141
- query: alepha.TObject<{
7142
- userRealmName: alepha.TOptional<alepha.TString>;
7171
+ query: _$alepha.TObject<{
7172
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7143
7173
  }>;
7144
- response: alepha.TObject<{
7145
- ok: alepha.TBoolean;
7146
- id: alepha.TOptional<alepha.TUnion<[alepha.TString, alepha.TInteger]>>;
7147
- count: alepha.TOptional<alepha.TNumber>;
7174
+ response: _$alepha.TObject<{
7175
+ ok: _$alepha.TBoolean;
7176
+ id: _$alepha.TOptional<_$alepha.TUnion<[_$alepha.TString, _$alepha.TInteger]>>;
7177
+ count: _$alepha.TOptional<_$alepha.TNumber>;
7148
7178
  }>;
7149
7179
  }>;
7150
7180
  }
7151
7181
  //#endregion
7152
7182
  //#region ../../src/api/users/schemas/sessionQuerySchema.d.ts
7153
- declare const sessionQuerySchema: alepha.TObject<{
7154
- page: alepha.TOptional<alepha.TInteger>;
7155
- size: alepha.TOptional<alepha.TInteger>;
7156
- sort: alepha.TOptional<alepha.TString>;
7157
- userId: alepha.TOptional<alepha.TString>;
7183
+ declare const sessionQuerySchema: _$alepha.TObject<{
7184
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7185
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7186
+ sort: _$alepha.TOptional<_$alepha.TString>;
7187
+ userId: _$alepha.TOptional<_$alepha.TString>;
7158
7188
  }>;
7159
7189
  type SessionQuery = Static<typeof sessionQuerySchema>;
7160
7190
  //#endregion
7161
7191
  //#region ../../src/api/users/services/SessionCrudService.d.ts
7162
7192
  declare class SessionCrudService {
7163
- protected readonly log: alepha_logger0.Logger;
7193
+ protected readonly log: _$alepha_logger0.Logger;
7164
7194
  protected readonly realmProvider: RealmProvider;
7165
- sessions(userRealmName?: string): alepha_orm0.Repository<alepha.TObject<{
7166
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
7167
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
7168
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7169
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7170
- refreshToken: alepha.TString;
7171
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
7172
- expiresAt: alepha.TString;
7173
- ip: alepha.TOptional<alepha.TString>;
7174
- userAgent: alepha.TOptional<alepha.TObject<{
7175
- os: alepha.TString;
7176
- browser: alepha.TString;
7177
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7195
+ sessions(userRealmName?: string): _$alepha_orm0.Repository<_$alepha.TObject<{
7196
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7197
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7198
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7199
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7200
+ refreshToken: _$alepha.TString;
7201
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
7202
+ expiresAt: _$alepha.TString;
7203
+ ip: _$alepha.TOptional<_$alepha.TString>;
7204
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
7205
+ os: _$alepha.TString;
7206
+ browser: _$alepha.TString;
7207
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7178
7208
  }>>;
7179
7209
  }>>;
7180
7210
  /**
@@ -7199,170 +7229,173 @@ declare class AdminSessionController {
7199
7229
  /**
7200
7230
  * Find sessions with pagination and filtering.
7201
7231
  */
7202
- readonly findSessions: alepha_server0.ActionPrimitiveFn<{
7203
- query: alepha.TObject<{
7204
- page: alepha.TOptional<alepha.TInteger>;
7205
- size: alepha.TOptional<alepha.TInteger>;
7206
- sort: alepha.TOptional<alepha.TString>;
7207
- userId: alepha.TOptional<alepha.TString>;
7208
- userRealmName: alepha.TOptional<alepha.TString>;
7209
- }>;
7210
- response: alepha.TPage<alepha.TObject<{
7211
- id: alepha.TString;
7212
- version: alepha.TNumber;
7213
- createdAt: alepha.TString;
7214
- updatedAt: alepha.TString;
7215
- refreshToken: alepha.TString;
7216
- userId: alepha.TString;
7217
- expiresAt: alepha.TString;
7218
- ip: alepha.TOptional<alepha.TString>;
7219
- userAgent: alepha.TOptional<alepha.TObject<{
7220
- os: alepha.TString;
7221
- browser: alepha.TString;
7222
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7232
+ readonly findSessions: _$alepha_server0.ActionPrimitiveFn<{
7233
+ query: _$alepha.TObject<{
7234
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7235
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7236
+ sort: _$alepha.TOptional<_$alepha.TString>;
7237
+ userId: _$alepha.TOptional<_$alepha.TString>;
7238
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7239
+ }>;
7240
+ response: _$alepha.TPage<_$alepha.TObject<{
7241
+ id: _$alepha.TString;
7242
+ version: _$alepha.TNumber;
7243
+ createdAt: _$alepha.TString;
7244
+ updatedAt: _$alepha.TString;
7245
+ refreshToken: _$alepha.TString;
7246
+ userId: _$alepha.TString;
7247
+ expiresAt: _$alepha.TString;
7248
+ ip: _$alepha.TOptional<_$alepha.TString>;
7249
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
7250
+ os: _$alepha.TString;
7251
+ browser: _$alepha.TString;
7252
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7223
7253
  }>>;
7224
7254
  }>>;
7225
7255
  }>;
7226
7256
  /**
7227
7257
  * Get a session by ID.
7228
7258
  */
7229
- readonly getSession: alepha_server0.ActionPrimitiveFn<{
7230
- params: alepha.TObject<{
7231
- id: alepha.TString;
7232
- }>;
7233
- query: alepha.TObject<{
7234
- userRealmName: alepha.TOptional<alepha.TString>;
7235
- }>;
7236
- response: alepha.TObject<{
7237
- id: alepha.TString;
7238
- version: alepha.TNumber;
7239
- createdAt: alepha.TString;
7240
- updatedAt: alepha.TString;
7241
- refreshToken: alepha.TString;
7242
- userId: alepha.TString;
7243
- expiresAt: alepha.TString;
7244
- ip: alepha.TOptional<alepha.TString>;
7245
- userAgent: alepha.TOptional<alepha.TObject<{
7246
- os: alepha.TString;
7247
- browser: alepha.TString;
7248
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7259
+ readonly getSession: _$alepha_server0.ActionPrimitiveFn<{
7260
+ params: _$alepha.TObject<{
7261
+ id: _$alepha.TString;
7262
+ }>;
7263
+ query: _$alepha.TObject<{
7264
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7265
+ }>;
7266
+ response: _$alepha.TObject<{
7267
+ id: _$alepha.TString;
7268
+ version: _$alepha.TNumber;
7269
+ createdAt: _$alepha.TString;
7270
+ updatedAt: _$alepha.TString;
7271
+ refreshToken: _$alepha.TString;
7272
+ userId: _$alepha.TString;
7273
+ expiresAt: _$alepha.TString;
7274
+ ip: _$alepha.TOptional<_$alepha.TString>;
7275
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
7276
+ os: _$alepha.TString;
7277
+ browser: _$alepha.TString;
7278
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7249
7279
  }>>;
7250
7280
  }>;
7251
7281
  }>;
7252
7282
  /**
7253
7283
  * Delete a session.
7254
7284
  */
7255
- readonly deleteSession: alepha_server0.ActionPrimitiveFn<{
7256
- params: alepha.TObject<{
7257
- id: alepha.TString;
7285
+ readonly deleteSession: _$alepha_server0.ActionPrimitiveFn<{
7286
+ params: _$alepha.TObject<{
7287
+ id: _$alepha.TString;
7258
7288
  }>;
7259
- query: alepha.TObject<{
7260
- userRealmName: alepha.TOptional<alepha.TString>;
7289
+ query: _$alepha.TObject<{
7290
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7261
7291
  }>;
7262
- response: alepha.TObject<{
7263
- ok: alepha.TBoolean;
7264
- id: alepha.TOptional<alepha.TUnion<[alepha.TString, alepha.TInteger]>>;
7265
- count: alepha.TOptional<alepha.TNumber>;
7292
+ response: _$alepha.TObject<{
7293
+ ok: _$alepha.TBoolean;
7294
+ id: _$alepha.TOptional<_$alepha.TUnion<[_$alepha.TString, _$alepha.TInteger]>>;
7295
+ count: _$alepha.TOptional<_$alepha.TNumber>;
7266
7296
  }>;
7267
7297
  }>;
7268
7298
  }
7269
7299
  //#endregion
7270
7300
  //#region ../../src/api/users/notifications/UserNotifications.d.ts
7271
7301
  declare class UserNotifications {
7272
- readonly passwordReset: alepha_api_notifications0.NotificationPrimitive<alepha.TObject<{
7273
- email: alepha.TString;
7274
- code: alepha.TString;
7275
- expiresInMinutes: alepha.TNumber;
7302
+ readonly passwordReset: _$alepha_api_notifications0.NotificationPrimitive<_$alepha.TObject<{
7303
+ email: _$alepha.TString;
7304
+ code: _$alepha.TString;
7305
+ expiresInMinutes: _$alepha.TNumber;
7276
7306
  }>>;
7277
- readonly emailVerification: alepha_api_notifications0.NotificationPrimitive<alepha.TObject<{
7278
- email: alepha.TString;
7279
- code: alepha.TString;
7280
- expiresInMinutes: alepha.TNumber;
7307
+ readonly emailVerification: _$alepha_api_notifications0.NotificationPrimitive<_$alepha.TObject<{
7308
+ email: _$alepha.TString;
7309
+ code: _$alepha.TString;
7310
+ expiresInMinutes: _$alepha.TNumber;
7281
7311
  }>>;
7282
- readonly phoneVerification: alepha_api_notifications0.NotificationPrimitive<alepha.TObject<{
7283
- phoneNumber: alepha.TString;
7284
- code: alepha.TString;
7285
- expiresInMinutes: alepha.TNumber;
7312
+ readonly phoneVerification: _$alepha_api_notifications0.NotificationPrimitive<_$alepha.TObject<{
7313
+ phoneNumber: _$alepha.TString;
7314
+ code: _$alepha.TString;
7315
+ expiresInMinutes: _$alepha.TNumber;
7286
7316
  }>>;
7287
- readonly passwordResetLink: alepha_api_notifications0.NotificationPrimitive<alepha.TObject<{
7288
- email: alepha.TString;
7289
- resetUrl: alepha.TString;
7290
- expiresInMinutes: alepha.TNumber;
7317
+ readonly passwordResetLink: _$alepha_api_notifications0.NotificationPrimitive<_$alepha.TObject<{
7318
+ email: _$alepha.TString;
7319
+ resetUrl: _$alepha.TString;
7320
+ expiresInMinutes: _$alepha.TNumber;
7291
7321
  }>>;
7292
- readonly emailVerificationLink: alepha_api_notifications0.NotificationPrimitive<alepha.TObject<{
7293
- email: alepha.TString;
7294
- verifyUrl: alepha.TString;
7295
- expiresInMinutes: alepha.TNumber;
7322
+ readonly emailVerificationLink: _$alepha_api_notifications0.NotificationPrimitive<_$alepha.TObject<{
7323
+ email: _$alepha.TString;
7324
+ verifyUrl: _$alepha.TString;
7325
+ expiresInMinutes: _$alepha.TNumber;
7296
7326
  }>>;
7297
7327
  }
7298
7328
  //#endregion
7299
7329
  //#region ../../src/api/users/schemas/createUserSchema.d.ts
7300
- declare const createUserSchema: alepha.TObject<{
7301
- email: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7302
- username: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7303
- phoneNumber: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7304
- id: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
7305
- createdAt: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
7306
- version: alepha.TOptional<PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
7307
- updatedAt: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
7308
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7309
- firstName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7310
- lastName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7311
- picture: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7312
- enabled: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7313
- emailVerified: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7330
+ declare const createUserSchema: _$alepha.TObject<{
7331
+ enabled: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7332
+ email: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7333
+ phoneNumber: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7334
+ id: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
7335
+ version: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
7336
+ createdAt: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
7337
+ updatedAt: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
7338
+ username: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7339
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7340
+ firstName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7341
+ lastName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7342
+ picture: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7343
+ emailVerified: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7344
+ organizationId: _$alepha.TOptional<PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>>;
7314
7345
  }>;
7315
7346
  type CreateUser = Static<typeof createUserSchema>;
7316
7347
  //#endregion
7317
7348
  //#region ../../src/api/users/schemas/updateUserSchema.d.ts
7318
- declare const updateUserSchema: alepha.TObject<{
7319
- email: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7320
- phoneNumber: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7321
- realm: alepha.TOptional<PgAttr<alepha.TString, typeof PG_DEFAULT>>;
7322
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7323
- firstName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7324
- lastName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7325
- picture: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7326
- enabled: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7349
+ declare const updateUserSchema: _$alepha.TObject<{
7350
+ enabled: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7351
+ email: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7352
+ phoneNumber: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7353
+ realm: _$alepha.TOptional<PgAttr<_$alepha.TString, typeof PG_DEFAULT>>;
7354
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7355
+ firstName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7356
+ lastName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7357
+ picture: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7358
+ organizationId: _$alepha.TOptional<PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>>;
7327
7359
  }>;
7328
7360
  type UpdateUser = Static<typeof updateUserSchema>;
7329
7361
  //#endregion
7330
7362
  //#region ../../src/api/users/schemas/userQuerySchema.d.ts
7331
- declare const userQuerySchema: alepha.TObject<{
7332
- page: alepha.TOptional<alepha.TInteger>;
7333
- size: alepha.TOptional<alepha.TInteger>;
7334
- sort: alepha.TOptional<alepha.TString>;
7335
- email: alepha.TOptional<alepha.TString>;
7336
- enabled: alepha.TOptional<alepha.TBoolean>;
7337
- emailVerified: alepha.TOptional<alepha.TBoolean>;
7338
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7339
- query: alepha.TOptional<alepha.TString>;
7363
+ declare const userQuerySchema: _$alepha.TObject<{
7364
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7365
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7366
+ sort: _$alepha.TOptional<_$alepha.TString>;
7367
+ email: _$alepha.TOptional<_$alepha.TString>;
7368
+ enabled: _$alepha.TOptional<_$alepha.TBoolean>;
7369
+ emailVerified: _$alepha.TOptional<_$alepha.TBoolean>;
7370
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7371
+ query: _$alepha.TOptional<_$alepha.TString>;
7340
7372
  }>;
7341
7373
  type UserQuery = Static<typeof userQuerySchema>;
7342
7374
  //#endregion
7343
7375
  //#region ../../src/api/users/services/UserService.d.ts
7344
7376
  declare class UserService {
7345
7377
  protected readonly alepha: Alepha;
7346
- protected readonly log: alepha_logger0.Logger;
7347
- protected readonly verificationController: alepha_server_links0.HttpVirtualClient<VerificationController>;
7378
+ protected readonly log: _$alepha_logger0.Logger;
7379
+ protected readonly verificationController: _$alepha_server_links0.HttpVirtualClient<VerificationController>;
7348
7380
  protected readonly realmProvider: RealmProvider;
7349
7381
  protected userAudits(realmName?: string): UserAudits | undefined;
7350
7382
  protected userNotifications(realmName?: string): UserNotifications | undefined;
7351
- users(userRealmName?: string): alepha_orm0.Repository<alepha.TObject<{
7352
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
7353
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
7354
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7355
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
7356
- realm: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_DEFAULT>;
7357
- username: alepha.TOptional<alepha.TString>;
7358
- email: alepha.TOptional<alepha.TString>;
7359
- phoneNumber: alepha.TOptional<alepha.TString>;
7360
- roles: alepha_orm0.PgAttr<alepha.TArray<alepha.TString>, typeof alepha_orm0.PG_DEFAULT>;
7361
- firstName: alepha.TOptional<alepha.TString>;
7362
- lastName: alepha.TOptional<alepha.TString>;
7363
- picture: alepha.TOptional<alepha.TString>;
7364
- enabled: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
7365
- emailVerified: alepha_orm0.PgAttr<alepha.TBoolean, typeof alepha_orm0.PG_DEFAULT>;
7383
+ users(userRealmName?: string): _$alepha_orm0.Repository<_$alepha.TObject<{
7384
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
7385
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
7386
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7387
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
7388
+ realm: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_DEFAULT>;
7389
+ username: _$alepha.TOptional<_$alepha.TString>;
7390
+ email: _$alepha.TOptional<_$alepha.TString>;
7391
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7392
+ roles: _$alepha_orm0.PgAttr<_$alepha.TArray<_$alepha.TString>, typeof _$alepha_orm0.PG_DEFAULT>;
7393
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7394
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7395
+ picture: _$alepha.TOptional<_$alepha.TString>;
7396
+ enabled: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
7397
+ emailVerified: _$alepha_orm0.PgAttr<_$alepha.TBoolean, typeof _$alepha_orm0.PG_DEFAULT>;
7398
+ organizationId: _$alepha_orm0.PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof _$alepha_orm0.PG_ORGANIZATION>;
7366
7399
  }>>;
7367
7400
  /**
7368
7401
  * Request email verification for a user.
@@ -7411,152 +7444,158 @@ declare class AdminUserController {
7411
7444
  /**
7412
7445
  * Find users with pagination and filtering.
7413
7446
  */
7414
- readonly findUsers: alepha_server0.ActionPrimitiveFn<{
7415
- query: alepha.TObject<{
7416
- page: alepha.TOptional<alepha.TInteger>;
7417
- size: alepha.TOptional<alepha.TInteger>;
7418
- sort: alepha.TOptional<alepha.TString>;
7419
- email: alepha.TOptional<alepha.TString>;
7420
- enabled: alepha.TOptional<alepha.TBoolean>;
7421
- emailVerified: alepha.TOptional<alepha.TBoolean>;
7422
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7423
- query: alepha.TOptional<alepha.TString>;
7424
- userRealmName: alepha.TOptional<alepha.TString>;
7425
- }>;
7426
- response: alepha.TPage<alepha.TObject<{
7427
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7428
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7429
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7430
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7431
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7432
- username: alepha.TOptional<alepha.TString>;
7433
- email: alepha.TOptional<alepha.TString>;
7434
- phoneNumber: alepha.TOptional<alepha.TString>;
7435
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7436
- firstName: alepha.TOptional<alepha.TString>;
7437
- lastName: alepha.TOptional<alepha.TString>;
7438
- picture: alepha.TOptional<alepha.TString>;
7439
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7440
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7447
+ readonly findUsers: _$alepha_server0.ActionPrimitiveFn<{
7448
+ query: _$alepha.TObject<{
7449
+ page: _$alepha.TOptional<_$alepha.TInteger>;
7450
+ size: _$alepha.TOptional<_$alepha.TInteger>;
7451
+ sort: _$alepha.TOptional<_$alepha.TString>;
7452
+ email: _$alepha.TOptional<_$alepha.TString>;
7453
+ enabled: _$alepha.TOptional<_$alepha.TBoolean>;
7454
+ emailVerified: _$alepha.TOptional<_$alepha.TBoolean>;
7455
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7456
+ query: _$alepha.TOptional<_$alepha.TString>;
7457
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7458
+ }>;
7459
+ response: _$alepha.TPage<_$alepha.TObject<{
7460
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7461
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7462
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7463
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7464
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7465
+ username: _$alepha.TOptional<_$alepha.TString>;
7466
+ email: _$alepha.TOptional<_$alepha.TString>;
7467
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7468
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7469
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7470
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7471
+ picture: _$alepha.TOptional<_$alepha.TString>;
7472
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7473
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7474
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7441
7475
  }>>;
7442
7476
  }>;
7443
7477
  /**
7444
7478
  * Get a user by ID.
7445
7479
  */
7446
- readonly getUser: alepha_server0.ActionPrimitiveFn<{
7447
- params: alepha.TObject<{
7448
- id: alepha.TString;
7449
- }>;
7450
- query: alepha.TObject<{
7451
- userRealmName: alepha.TOptional<alepha.TString>;
7452
- }>;
7453
- response: alepha.TObject<{
7454
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7455
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7456
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7457
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7458
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7459
- username: alepha.TOptional<alepha.TString>;
7460
- email: alepha.TOptional<alepha.TString>;
7461
- phoneNumber: alepha.TOptional<alepha.TString>;
7462
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7463
- firstName: alepha.TOptional<alepha.TString>;
7464
- lastName: alepha.TOptional<alepha.TString>;
7465
- picture: alepha.TOptional<alepha.TString>;
7466
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7467
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7480
+ readonly getUser: _$alepha_server0.ActionPrimitiveFn<{
7481
+ params: _$alepha.TObject<{
7482
+ id: _$alepha.TString;
7483
+ }>;
7484
+ query: _$alepha.TObject<{
7485
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7486
+ }>;
7487
+ response: _$alepha.TObject<{
7488
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7489
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7490
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7491
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7492
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7493
+ username: _$alepha.TOptional<_$alepha.TString>;
7494
+ email: _$alepha.TOptional<_$alepha.TString>;
7495
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7496
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7497
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7498
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7499
+ picture: _$alepha.TOptional<_$alepha.TString>;
7500
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7501
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7502
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7468
7503
  }>;
7469
7504
  }>;
7470
7505
  /**
7471
7506
  * Create a new user.
7472
7507
  */
7473
- readonly createUser: alepha_server0.ActionPrimitiveFn<{
7474
- query: alepha.TObject<{
7475
- userRealmName: alepha.TOptional<alepha.TString>;
7476
- }>;
7477
- body: alepha.TObject<{
7478
- email: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7479
- username: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7480
- phoneNumber: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7481
- id: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
7482
- createdAt: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
7483
- version: alepha.TOptional<PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
7484
- updatedAt: alepha.TOptional<PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
7485
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7486
- firstName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7487
- lastName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7488
- picture: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7489
- enabled: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7490
- emailVerified: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7491
- }>;
7492
- response: alepha.TObject<{
7493
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7494
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7495
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7496
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7497
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7498
- username: alepha.TOptional<alepha.TString>;
7499
- email: alepha.TOptional<alepha.TString>;
7500
- phoneNumber: alepha.TOptional<alepha.TString>;
7501
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7502
- firstName: alepha.TOptional<alepha.TString>;
7503
- lastName: alepha.TOptional<alepha.TString>;
7504
- picture: alepha.TOptional<alepha.TString>;
7505
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7506
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7508
+ readonly createUser: _$alepha_server0.ActionPrimitiveFn<{
7509
+ query: _$alepha.TObject<{
7510
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7511
+ }>;
7512
+ body: _$alepha.TObject<{
7513
+ enabled: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7514
+ email: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7515
+ phoneNumber: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7516
+ id: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>>;
7517
+ version: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>>;
7518
+ createdAt: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>>;
7519
+ updatedAt: _$alepha.TOptional<PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>>;
7520
+ username: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7521
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7522
+ firstName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7523
+ lastName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7524
+ picture: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7525
+ emailVerified: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7526
+ organizationId: _$alepha.TOptional<PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>>;
7527
+ }>;
7528
+ response: _$alepha.TObject<{
7529
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7530
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7531
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7532
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7533
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7534
+ username: _$alepha.TOptional<_$alepha.TString>;
7535
+ email: _$alepha.TOptional<_$alepha.TString>;
7536
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7537
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7538
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7539
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7540
+ picture: _$alepha.TOptional<_$alepha.TString>;
7541
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7542
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7543
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7507
7544
  }>;
7508
7545
  }>;
7509
7546
  /**
7510
7547
  * Update a user.
7511
7548
  */
7512
- readonly updateUser: alepha_server0.ActionPrimitiveFn<{
7513
- params: alepha.TObject<{
7514
- id: alepha.TString;
7515
- }>;
7516
- query: alepha.TObject<{
7517
- userRealmName: alepha.TOptional<alepha.TString>;
7518
- }>;
7519
- body: alepha.TObject<{
7520
- email: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7521
- phoneNumber: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7522
- realm: alepha.TOptional<PgAttr<alepha.TString, typeof PG_DEFAULT>>;
7523
- roles: alepha.TOptional<alepha.TArray<alepha.TString>>;
7524
- firstName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7525
- lastName: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7526
- picture: alepha.TOptional<alepha.TOptional<alepha.TString>>;
7527
- enabled: alepha.TOptional<PgAttr<alepha.TBoolean, typeof PG_DEFAULT>>;
7528
- }>;
7529
- response: alepha.TObject<{
7530
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7531
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7532
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7533
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7534
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7535
- username: alepha.TOptional<alepha.TString>;
7536
- email: alepha.TOptional<alepha.TString>;
7537
- phoneNumber: alepha.TOptional<alepha.TString>;
7538
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7539
- firstName: alepha.TOptional<alepha.TString>;
7540
- lastName: alepha.TOptional<alepha.TString>;
7541
- picture: alepha.TOptional<alepha.TString>;
7542
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7543
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7549
+ readonly updateUser: _$alepha_server0.ActionPrimitiveFn<{
7550
+ params: _$alepha.TObject<{
7551
+ id: _$alepha.TString;
7552
+ }>;
7553
+ query: _$alepha.TObject<{
7554
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7555
+ }>;
7556
+ body: _$alepha.TObject<{
7557
+ enabled: _$alepha.TOptional<PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>>;
7558
+ email: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7559
+ phoneNumber: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7560
+ realm: _$alepha.TOptional<PgAttr<_$alepha.TString, typeof PG_DEFAULT>>;
7561
+ roles: _$alepha.TOptional<_$alepha.TArray<_$alepha.TString>>;
7562
+ firstName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7563
+ lastName: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7564
+ picture: _$alepha.TOptional<_$alepha.TOptional<_$alepha.TString>>;
7565
+ organizationId: _$alepha.TOptional<PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>>;
7566
+ }>;
7567
+ response: _$alepha.TObject<{
7568
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7569
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7570
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7571
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7572
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7573
+ username: _$alepha.TOptional<_$alepha.TString>;
7574
+ email: _$alepha.TOptional<_$alepha.TString>;
7575
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7576
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7577
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7578
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7579
+ picture: _$alepha.TOptional<_$alepha.TString>;
7580
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7581
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7582
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7544
7583
  }>;
7545
7584
  }>;
7546
7585
  /**
7547
7586
  * Delete a user.
7548
7587
  */
7549
- readonly deleteUser: alepha_server0.ActionPrimitiveFn<{
7550
- params: alepha.TObject<{
7551
- id: alepha.TString;
7588
+ readonly deleteUser: _$alepha_server0.ActionPrimitiveFn<{
7589
+ params: _$alepha.TObject<{
7590
+ id: _$alepha.TString;
7552
7591
  }>;
7553
- query: alepha.TObject<{
7554
- userRealmName: alepha.TOptional<alepha.TString>;
7592
+ query: _$alepha.TObject<{
7593
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7555
7594
  }>;
7556
- response: alepha.TObject<{
7557
- ok: alepha.TBoolean;
7558
- id: alepha.TOptional<alepha.TUnion<[alepha.TString, alepha.TInteger]>>;
7559
- count: alepha.TOptional<alepha.TNumber>;
7595
+ response: _$alepha.TObject<{
7596
+ ok: _$alepha.TBoolean;
7597
+ id: _$alepha.TOptional<_$alepha.TUnion<[_$alepha.TString, _$alepha.TInteger]>>;
7598
+ count: _$alepha.TOptional<_$alepha.TNumber>;
7560
7599
  }>;
7561
7600
  }>;
7562
7601
  }
@@ -7575,55 +7614,55 @@ declare class RealmController {
7575
7614
  * Get realm configuration settings.
7576
7615
  * This endpoint is not exposed in the API documentation.
7577
7616
  */
7578
- readonly getRealmConfig: alepha_server0.ActionPrimitiveFn<{
7579
- query: alepha.TObject<{
7580
- realmName: alepha.TOptional<alepha.TString>;
7581
- }>;
7582
- response: alepha.TObject<{
7583
- settings: alepha.TObject<{
7584
- displayName: alepha.TOptional<alepha.TString>;
7585
- description: alepha.TOptional<alepha.TString>;
7586
- logoUrl: alepha.TOptional<alepha.TString>;
7587
- registrationAllowed: alepha.TBoolean;
7588
- email: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
7589
- username: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
7590
- usernameRegExp: alepha.TString;
7591
- phoneNumber: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
7592
- verifyEmailRequired: alepha.TBoolean;
7593
- verifyPhoneRequired: alepha.TBoolean;
7594
- firstNameLastName: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
7595
- resetPasswordAllowed: alepha.TBoolean;
7596
- adminEmails: alepha.TArray<alepha.TString>;
7597
- adminUsernames: alepha.TArray<alepha.TString>;
7598
- passwordPolicy: alepha.TObject<{
7599
- minLength: alepha.TInteger;
7600
- requireUppercase: alepha.TBoolean;
7601
- requireLowercase: alepha.TBoolean;
7602
- requireNumbers: alepha.TBoolean;
7603
- requireSpecialCharacters: alepha.TBoolean;
7617
+ readonly getRealmConfig: _$alepha_server0.ActionPrimitiveFn<{
7618
+ query: _$alepha.TObject<{
7619
+ realmName: _$alepha.TOptional<_$alepha.TString>;
7620
+ }>;
7621
+ response: _$alepha.TObject<{
7622
+ settings: _$alepha.TObject<{
7623
+ displayName: _$alepha.TOptional<_$alepha.TString>;
7624
+ description: _$alepha.TOptional<_$alepha.TString>;
7625
+ logoUrl: _$alepha.TOptional<_$alepha.TString>;
7626
+ registrationAllowed: _$alepha.TBoolean;
7627
+ email: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
7628
+ username: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
7629
+ usernameRegExp: _$alepha.TString;
7630
+ phoneNumber: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
7631
+ verifyEmailRequired: _$alepha.TBoolean;
7632
+ verifyPhoneRequired: _$alepha.TBoolean;
7633
+ firstNameLastName: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
7634
+ resetPasswordAllowed: _$alepha.TBoolean;
7635
+ adminEmails: _$alepha.TArray<_$alepha.TString>;
7636
+ adminUsernames: _$alepha.TArray<_$alepha.TString>;
7637
+ passwordPolicy: _$alepha.TObject<{
7638
+ minLength: _$alepha.TInteger;
7639
+ requireUppercase: _$alepha.TBoolean;
7640
+ requireLowercase: _$alepha.TBoolean;
7641
+ requireNumbers: _$alepha.TBoolean;
7642
+ requireSpecialCharacters: _$alepha.TBoolean;
7604
7643
  }>;
7605
- loginRateLimit: alepha.TObject<{
7606
- ipMaxAttempts: alepha.TInteger;
7607
- accountMaxAttempts: alepha.TInteger;
7608
- windowMs: alepha.TInteger;
7644
+ loginRateLimit: _$alepha.TObject<{
7645
+ ipMaxAttempts: _$alepha.TInteger;
7646
+ accountMaxAttempts: _$alepha.TInteger;
7647
+ windowMs: _$alepha.TInteger;
7609
7648
  }>;
7610
7649
  }>;
7611
- realmName: alepha.TString;
7612
- authenticationMethods: alepha.TArray<alepha.TObject<{
7613
- name: alepha.TString;
7614
- type: alepha.TUnsafe<"OAUTH2" | "OIDC" | "CREDENTIALS">;
7650
+ realmName: _$alepha.TString;
7651
+ authenticationMethods: _$alepha.TArray<_$alepha.TObject<{
7652
+ name: _$alepha.TString;
7653
+ type: _$alepha.TUnsafe<"OAUTH2" | "OIDC" | "CREDENTIALS">;
7615
7654
  }>>;
7616
7655
  }>;
7617
7656
  }>;
7618
- readonly checkUsernameAvailability: alepha_server0.ActionPrimitiveFn<{
7619
- query: alepha.TObject<{
7620
- realmName: alepha.TOptional<alepha.TString>;
7657
+ readonly checkUsernameAvailability: _$alepha_server0.ActionPrimitiveFn<{
7658
+ query: _$alepha.TObject<{
7659
+ realmName: _$alepha.TOptional<_$alepha.TString>;
7621
7660
  }>;
7622
- body: alepha.TObject<{
7623
- username: alepha.TString;
7661
+ body: _$alepha.TObject<{
7662
+ username: _$alepha.TString;
7624
7663
  }>;
7625
- response: alepha.TObject<{
7626
- available: alepha.TBoolean;
7664
+ response: _$alepha.TObject<{
7665
+ available: _$alepha.TBoolean;
7627
7666
  }>;
7628
7667
  }>;
7629
7668
  }
@@ -7635,10 +7674,10 @@ declare class RealmController {
7635
7674
  * Requires the intent ID from Phase 1, the verification code,
7636
7675
  * and the new password.
7637
7676
  */
7638
- declare const completePasswordResetRequestSchema: alepha.TObject<{
7639
- intentId: alepha.TString;
7640
- code: alepha.TString;
7641
- newPassword: alepha.TString;
7677
+ declare const completePasswordResetRequestSchema: _$alepha.TObject<{
7678
+ intentId: _$alepha.TString;
7679
+ code: _$alepha.TString;
7680
+ newPassword: _$alepha.TString;
7642
7681
  }>;
7643
7682
  type CompletePasswordResetRequest = Static<typeof completePasswordResetRequestSchema>;
7644
7683
  //#endregion
@@ -7649,9 +7688,9 @@ type CompletePasswordResetRequest = Static<typeof completePasswordResetRequestSc
7649
7688
  * Contains the intent ID needed for Phase 2 completion,
7650
7689
  * along with expiration time.
7651
7690
  */
7652
- declare const passwordResetIntentResponseSchema: alepha.TObject<{
7653
- intentId: alepha.TString;
7654
- expiresAt: alepha.TString;
7691
+ declare const passwordResetIntentResponseSchema: _$alepha.TObject<{
7692
+ intentId: _$alepha.TString;
7693
+ expiresAt: _$alepha.TString;
7655
7694
  }>;
7656
7695
  type PasswordResetIntentResponse = Static<typeof passwordResetIntentResponseSchema>;
7657
7696
  //#endregion
@@ -7668,55 +7707,56 @@ interface PasswordResetIntent {
7668
7707
  }
7669
7708
  declare class CredentialService {
7670
7709
  protected readonly alepha: Alepha;
7671
- protected readonly log: alepha_logger0.Logger;
7710
+ protected readonly log: _$alepha_logger0.Logger;
7672
7711
  protected readonly cryptoProvider: CryptoProvider;
7673
7712
  protected readonly dateTimeProvider: DateTimeProvider;
7674
- protected readonly verificationController: alepha_server_links0.HttpVirtualClient<VerificationController>;
7713
+ protected readonly verificationController: _$alepha_server_links0.HttpVirtualClient<VerificationController>;
7675
7714
  protected readonly realmProvider: RealmProvider;
7676
7715
  protected userAudits(realmName?: string): UserAudits | undefined;
7677
7716
  protected userNotifications(realmName?: string): UserNotifications | undefined;
7678
- protected readonly intentCache: alepha_cache0.CacheMiddlewareFn<PasswordResetIntent>;
7679
- users(userRealmName?: string): Repository$1<alepha.TObject<{
7680
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7681
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7682
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7683
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7684
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7685
- username: alepha.TOptional<alepha.TString>;
7686
- email: alepha.TOptional<alepha.TString>;
7687
- phoneNumber: alepha.TOptional<alepha.TString>;
7688
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7689
- firstName: alepha.TOptional<alepha.TString>;
7690
- lastName: alepha.TOptional<alepha.TString>;
7691
- picture: alepha.TOptional<alepha.TString>;
7692
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7693
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7717
+ protected readonly intentCache: _$alepha_cache0.CacheMiddlewareFn<PasswordResetIntent>;
7718
+ users(userRealmName?: string): Repository$1<_$alepha.TObject<{
7719
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7720
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7721
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7722
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7723
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7724
+ username: _$alepha.TOptional<_$alepha.TString>;
7725
+ email: _$alepha.TOptional<_$alepha.TString>;
7726
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7727
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7728
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7729
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7730
+ picture: _$alepha.TOptional<_$alepha.TString>;
7731
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7732
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7733
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7694
7734
  }>>;
7695
- sessions(userRealmName?: string): Repository$1<alepha.TObject<{
7696
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7697
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7698
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7699
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7700
- refreshToken: alepha.TString;
7701
- userId: PgAttr<alepha.TString, typeof PG_REF>;
7702
- expiresAt: alepha.TString;
7703
- ip: alepha.TOptional<alepha.TString>;
7704
- userAgent: alepha.TOptional<alepha.TObject<{
7705
- os: alepha.TString;
7706
- browser: alepha.TString;
7707
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7735
+ sessions(userRealmName?: string): Repository$1<_$alepha.TObject<{
7736
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7737
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7738
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7739
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7740
+ refreshToken: _$alepha.TString;
7741
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
7742
+ expiresAt: _$alepha.TString;
7743
+ ip: _$alepha.TOptional<_$alepha.TString>;
7744
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
7745
+ os: _$alepha.TString;
7746
+ browser: _$alepha.TString;
7747
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
7708
7748
  }>>;
7709
7749
  }>>;
7710
- identities(userRealmName?: string): Repository$1<alepha.TObject<{
7711
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7712
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7713
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7714
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7715
- userId: PgAttr<alepha.TString, typeof PG_REF>;
7716
- password: alepha.TOptional<alepha.TString>;
7717
- provider: alepha.TString;
7718
- providerUserId: alepha.TOptional<alepha.TString>;
7719
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
7750
+ identities(userRealmName?: string): Repository$1<_$alepha.TObject<{
7751
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7752
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7753
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7754
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7755
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
7756
+ password: _$alepha.TOptional<_$alepha.TString>;
7757
+ provider: _$alepha.TString;
7758
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
7759
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
7720
7760
  }>>;
7721
7761
  /**
7722
7762
  * Phase 1: Create a password reset intent.
@@ -7753,11 +7793,11 @@ declare class CredentialService {
7753
7793
  }
7754
7794
  //#endregion
7755
7795
  //#region ../../src/api/users/schemas/completeRegistrationRequestSchema.d.ts
7756
- declare const completeRegistrationRequestSchema: alepha.TObject<{
7757
- intentId: alepha.TString;
7758
- emailCode: alepha.TOptional<alepha.TString>;
7759
- phoneCode: alepha.TOptional<alepha.TString>;
7760
- captchaToken: alepha.TOptional<alepha.TString>;
7796
+ declare const completeRegistrationRequestSchema: _$alepha.TObject<{
7797
+ intentId: _$alepha.TString;
7798
+ emailCode: _$alepha.TOptional<_$alepha.TString>;
7799
+ phoneCode: _$alepha.TOptional<_$alepha.TString>;
7800
+ captchaToken: _$alepha.TOptional<_$alepha.TString>;
7761
7801
  }>;
7762
7802
  type CompleteRegistrationRequest = Static<typeof completeRegistrationRequestSchema>;
7763
7803
  //#endregion
@@ -7766,24 +7806,24 @@ type CompleteRegistrationRequest = Static<typeof completeRegistrationRequestSche
7766
7806
  * Schema for user registration request body.
7767
7807
  * Password is always required, other fields depend on realm settings.
7768
7808
  */
7769
- declare const registerRequestSchema: alepha.TObject<{
7770
- password: alepha.TString;
7771
- username: alepha.TOptional<alepha.TString>;
7772
- email: alepha.TOptional<alepha.TString>;
7773
- phoneNumber: alepha.TOptional<alepha.TString>;
7774
- firstName: alepha.TOptional<alepha.TString>;
7775
- lastName: alepha.TOptional<alepha.TString>;
7776
- picture: alepha.TOptional<alepha.TString>;
7809
+ declare const registerRequestSchema: _$alepha.TObject<{
7810
+ password: _$alepha.TString;
7811
+ username: _$alepha.TOptional<_$alepha.TString>;
7812
+ email: _$alepha.TOptional<_$alepha.TString>;
7813
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7814
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7815
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7816
+ picture: _$alepha.TOptional<_$alepha.TString>;
7777
7817
  }>;
7778
7818
  type RegisterRequest = Static<typeof registerRequestSchema>;
7779
7819
  //#endregion
7780
7820
  //#region ../../src/api/users/schemas/registrationIntentResponseSchema.d.ts
7781
- declare const registrationIntentResponseSchema: alepha.TObject<{
7782
- intentId: alepha.TString;
7783
- expectCaptcha: alepha.TBoolean;
7784
- expectEmailVerification: alepha.TBoolean;
7785
- expectPhoneVerification: alepha.TBoolean;
7786
- expiresAt: alepha.TString;
7821
+ declare const registrationIntentResponseSchema: _$alepha.TObject<{
7822
+ intentId: _$alepha.TString;
7823
+ expectCaptcha: _$alepha.TBoolean;
7824
+ expectEmailVerification: _$alepha.TBoolean;
7825
+ expectPhoneVerification: _$alepha.TBoolean;
7826
+ expiresAt: _$alepha.TString;
7787
7827
  }>;
7788
7828
  type RegistrationIntentResponse = Static<typeof registrationIntentResponseSchema>;
7789
7829
  //#endregion
@@ -7811,12 +7851,12 @@ interface RegistrationIntent {
7811
7851
  }
7812
7852
  declare class RegistrationService {
7813
7853
  protected readonly alepha: Alepha;
7814
- protected readonly log: alepha_logger0.Logger;
7854
+ protected readonly log: _$alepha_logger0.Logger;
7815
7855
  protected readonly dateTimeProvider: DateTimeProvider;
7816
7856
  protected readonly cryptoProvider: CryptoProvider;
7817
- protected readonly verificationController: alepha_server_links0.HttpVirtualClient<VerificationController>;
7857
+ protected readonly verificationController: _$alepha_server_links0.HttpVirtualClient<VerificationController>;
7818
7858
  protected readonly realmProvider: RealmProvider;
7819
- protected readonly intentCache: alepha_cache0.CacheMiddlewareFn<RegistrationIntent>;
7859
+ protected readonly intentCache: _$alepha_cache0.CacheMiddlewareFn<RegistrationIntent>;
7820
7860
  protected userAudits(realmName?: string): UserAudits | undefined;
7821
7861
  protected userNotifications(realmName?: string): UserNotifications;
7822
7862
  /**
@@ -7866,131 +7906,132 @@ declare class UserController {
7866
7906
  * Phase 1: Create a registration intent.
7867
7907
  * Validates data, creates verification sessions, and stores intent in cache.
7868
7908
  */
7869
- readonly createRegistrationIntent: alepha_server0.ActionPrimitiveFn<{
7870
- body: alepha.TObject<{
7871
- password: alepha.TString;
7872
- username: alepha.TOptional<alepha.TString>;
7873
- email: alepha.TOptional<alepha.TString>;
7874
- phoneNumber: alepha.TOptional<alepha.TString>;
7875
- firstName: alepha.TOptional<alepha.TString>;
7876
- lastName: alepha.TOptional<alepha.TString>;
7877
- picture: alepha.TOptional<alepha.TString>;
7878
- }>;
7879
- query: alepha.TObject<{
7880
- userRealmName: alepha.TOptional<alepha.TString>;
7881
- }>;
7882
- response: alepha.TObject<{
7883
- intentId: alepha.TString;
7884
- expectCaptcha: alepha.TBoolean;
7885
- expectEmailVerification: alepha.TBoolean;
7886
- expectPhoneVerification: alepha.TBoolean;
7887
- expiresAt: alepha.TString;
7909
+ readonly createRegistrationIntent: _$alepha_server0.ActionPrimitiveFn<{
7910
+ body: _$alepha.TObject<{
7911
+ password: _$alepha.TString;
7912
+ username: _$alepha.TOptional<_$alepha.TString>;
7913
+ email: _$alepha.TOptional<_$alepha.TString>;
7914
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7915
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7916
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7917
+ picture: _$alepha.TOptional<_$alepha.TString>;
7918
+ }>;
7919
+ query: _$alepha.TObject<{
7920
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7921
+ }>;
7922
+ response: _$alepha.TObject<{
7923
+ intentId: _$alepha.TString;
7924
+ expectCaptcha: _$alepha.TBoolean;
7925
+ expectEmailVerification: _$alepha.TBoolean;
7926
+ expectPhoneVerification: _$alepha.TBoolean;
7927
+ expiresAt: _$alepha.TString;
7888
7928
  }>;
7889
7929
  }>;
7890
7930
  /**
7891
7931
  * Phase 2: Complete registration using an intent.
7892
7932
  * Validates verification codes and creates the user.
7893
7933
  */
7894
- readonly createUserFromIntent: alepha_server0.ActionPrimitiveFn<{
7895
- body: alepha.TObject<{
7896
- intentId: alepha.TString;
7897
- emailCode: alepha.TOptional<alepha.TString>;
7898
- phoneCode: alepha.TOptional<alepha.TString>;
7899
- captchaToken: alepha.TOptional<alepha.TString>;
7900
- }>;
7901
- response: alepha.TObject<{
7902
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7903
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7904
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7905
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7906
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
7907
- username: alepha.TOptional<alepha.TString>;
7908
- email: alepha.TOptional<alepha.TString>;
7909
- phoneNumber: alepha.TOptional<alepha.TString>;
7910
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
7911
- firstName: alepha.TOptional<alepha.TString>;
7912
- lastName: alepha.TOptional<alepha.TString>;
7913
- picture: alepha.TOptional<alepha.TString>;
7914
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7915
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
7934
+ readonly createUserFromIntent: _$alepha_server0.ActionPrimitiveFn<{
7935
+ body: _$alepha.TObject<{
7936
+ intentId: _$alepha.TString;
7937
+ emailCode: _$alepha.TOptional<_$alepha.TString>;
7938
+ phoneCode: _$alepha.TOptional<_$alepha.TString>;
7939
+ captchaToken: _$alepha.TOptional<_$alepha.TString>;
7940
+ }>;
7941
+ response: _$alepha.TObject<{
7942
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
7943
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
7944
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
7945
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
7946
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
7947
+ username: _$alepha.TOptional<_$alepha.TString>;
7948
+ email: _$alepha.TOptional<_$alepha.TString>;
7949
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
7950
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
7951
+ firstName: _$alepha.TOptional<_$alepha.TString>;
7952
+ lastName: _$alepha.TOptional<_$alepha.TString>;
7953
+ picture: _$alepha.TOptional<_$alepha.TString>;
7954
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7955
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
7956
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
7916
7957
  }>;
7917
7958
  }>;
7918
7959
  /**
7919
7960
  * Phase 1: Create a password reset intent.
7920
7961
  * Validates email, sends verification code, and stores intent in cache.
7921
7962
  */
7922
- readonly createPasswordResetIntent: alepha_server0.ActionPrimitiveFn<{
7923
- query: alepha.TObject<{
7924
- userRealmName: alepha.TOptional<alepha.TString>;
7963
+ readonly createPasswordResetIntent: _$alepha_server0.ActionPrimitiveFn<{
7964
+ query: _$alepha.TObject<{
7965
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7925
7966
  }>;
7926
- body: alepha.TObject<{
7927
- email: alepha.TString;
7967
+ body: _$alepha.TObject<{
7968
+ email: _$alepha.TString;
7928
7969
  }>;
7929
- response: alepha.TObject<{
7930
- intentId: alepha.TString;
7931
- expiresAt: alepha.TString;
7970
+ response: _$alepha.TObject<{
7971
+ intentId: _$alepha.TString;
7972
+ expiresAt: _$alepha.TString;
7932
7973
  }>;
7933
7974
  }>;
7934
7975
  /**
7935
7976
  * Phase 2: Complete password reset using an intent.
7936
7977
  * Validates verification code, updates password, and invalidates sessions.
7937
7978
  */
7938
- readonly completePasswordReset: alepha_server0.ActionPrimitiveFn<{
7939
- body: alepha.TObject<{
7940
- intentId: alepha.TString;
7941
- code: alepha.TString;
7942
- newPassword: alepha.TString;
7979
+ readonly completePasswordReset: _$alepha_server0.ActionPrimitiveFn<{
7980
+ body: _$alepha.TObject<{
7981
+ intentId: _$alepha.TString;
7982
+ code: _$alepha.TString;
7983
+ newPassword: _$alepha.TString;
7943
7984
  }>;
7944
- response: alepha.TObject<{
7945
- ok: alepha.TBoolean;
7946
- id: alepha.TOptional<alepha.TUnion<[alepha.TString, alepha.TInteger]>>;
7947
- count: alepha.TOptional<alepha.TNumber>;
7985
+ response: _$alepha.TObject<{
7986
+ ok: _$alepha.TBoolean;
7987
+ id: _$alepha.TOptional<_$alepha.TUnion<[_$alepha.TString, _$alepha.TInteger]>>;
7988
+ count: _$alepha.TOptional<_$alepha.TNumber>;
7948
7989
  }>;
7949
7990
  }>;
7950
7991
  /**
7951
7992
  * @deprecated Use createPasswordResetIntent instead
7952
7993
  */
7953
- requestPasswordReset: alepha_server0.ActionPrimitiveFn<{
7954
- query: alepha.TObject<{
7955
- userRealmName: alepha.TOptional<alepha.TString>;
7994
+ requestPasswordReset: _$alepha_server0.ActionPrimitiveFn<{
7995
+ query: _$alepha.TObject<{
7996
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7956
7997
  }>;
7957
- body: alepha.TObject<{
7958
- email: alepha.TString;
7998
+ body: _$alepha.TObject<{
7999
+ email: _$alepha.TString;
7959
8000
  }>;
7960
- response: alepha.TObject<{
7961
- success: alepha.TBoolean;
7962
- message: alepha.TString;
8001
+ response: _$alepha.TObject<{
8002
+ success: _$alepha.TBoolean;
8003
+ message: _$alepha.TString;
7963
8004
  }>;
7964
8005
  }>;
7965
8006
  /**
7966
8007
  * @deprecated Use completePasswordReset instead
7967
8008
  */
7968
- validateResetToken: alepha_server0.ActionPrimitiveFn<{
7969
- query: alepha.TObject<{
7970
- email: alepha.TString;
7971
- token: alepha.TString;
7972
- userRealmName: alepha.TOptional<alepha.TString>;
8009
+ validateResetToken: _$alepha_server0.ActionPrimitiveFn<{
8010
+ query: _$alepha.TObject<{
8011
+ email: _$alepha.TString;
8012
+ token: _$alepha.TString;
8013
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7973
8014
  }>;
7974
- response: alepha.TObject<{
7975
- valid: alepha.TBoolean;
7976
- email: alepha.TOptional<alepha.TString>;
8015
+ response: _$alepha.TObject<{
8016
+ valid: _$alepha.TBoolean;
8017
+ email: _$alepha.TOptional<_$alepha.TString>;
7977
8018
  }>;
7978
8019
  }>;
7979
8020
  /**
7980
8021
  * @deprecated Use completePasswordReset instead
7981
8022
  */
7982
- resetPassword: alepha_server0.ActionPrimitiveFn<{
7983
- query: alepha.TObject<{
7984
- userRealmName: alepha.TOptional<alepha.TString>;
8023
+ resetPassword: _$alepha_server0.ActionPrimitiveFn<{
8024
+ query: _$alepha.TObject<{
8025
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
7985
8026
  }>;
7986
- body: alepha.TObject<{
7987
- email: alepha.TString;
7988
- token: alepha.TString;
7989
- newPassword: alepha.TString;
8027
+ body: _$alepha.TObject<{
8028
+ email: _$alepha.TString;
8029
+ token: _$alepha.TString;
8030
+ newPassword: _$alepha.TString;
7990
8031
  }>;
7991
- response: alepha.TObject<{
7992
- success: alepha.TBoolean;
7993
- message: alepha.TString;
8032
+ response: _$alepha.TObject<{
8033
+ success: _$alepha.TBoolean;
8034
+ message: _$alepha.TString;
7994
8035
  }>;
7995
8036
  }>;
7996
8037
  /**
@@ -7999,47 +8040,47 @@ declare class UserController {
7999
8040
  * @param method - The verification method: "code" (default) sends a 6-digit code, "link" sends a clickable verification link.
8000
8041
  * @param verifyUrl - Required when method is "link". The base URL for the verification link. Token and email will be appended as query params.
8001
8042
  */
8002
- requestEmailVerification: alepha_server0.ActionPrimitiveFn<{
8003
- query: alepha.TObject<{
8004
- userRealmName: alepha.TOptional<alepha.TString>;
8005
- method: alepha.TOptional<alepha.TUnsafe<"link" | "code">>;
8006
- verifyUrl: alepha.TOptional<alepha.TString>;
8043
+ requestEmailVerification: _$alepha_server0.ActionPrimitiveFn<{
8044
+ query: _$alepha.TObject<{
8045
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
8046
+ method: _$alepha.TOptional<_$alepha.TUnsafe<"link" | "code">>;
8047
+ verifyUrl: _$alepha.TOptional<_$alepha.TString>;
8007
8048
  }>;
8008
- body: alepha.TObject<{
8009
- email: alepha.TString;
8049
+ body: _$alepha.TObject<{
8050
+ email: _$alepha.TString;
8010
8051
  }>;
8011
- response: alepha.TObject<{
8012
- success: alepha.TBoolean;
8013
- message: alepha.TString;
8052
+ response: _$alepha.TObject<{
8053
+ success: _$alepha.TBoolean;
8054
+ message: _$alepha.TString;
8014
8055
  }>;
8015
8056
  }>;
8016
8057
  /**
8017
8058
  * Verify email with a valid token.
8018
8059
  * Updates the user's emailVerified status.
8019
8060
  */
8020
- verifyEmail: alepha_server0.ActionPrimitiveFn<{
8021
- query: alepha.TObject<{
8022
- userRealmName: alepha.TOptional<alepha.TString>;
8061
+ verifyEmail: _$alepha_server0.ActionPrimitiveFn<{
8062
+ query: _$alepha.TObject<{
8063
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
8023
8064
  }>;
8024
- body: alepha.TObject<{
8025
- email: alepha.TString;
8026
- token: alepha.TString;
8065
+ body: _$alepha.TObject<{
8066
+ email: _$alepha.TString;
8067
+ token: _$alepha.TString;
8027
8068
  }>;
8028
- response: alepha.TObject<{
8029
- success: alepha.TBoolean;
8030
- message: alepha.TString;
8069
+ response: _$alepha.TObject<{
8070
+ success: _$alepha.TBoolean;
8071
+ message: _$alepha.TString;
8031
8072
  }>;
8032
8073
  }>;
8033
8074
  /**
8034
8075
  * Check if an email is verified.
8035
8076
  */
8036
- checkEmailVerification: alepha_server0.ActionPrimitiveFn<{
8037
- query: alepha.TObject<{
8038
- email: alepha.TString;
8039
- userRealmName: alepha.TOptional<alepha.TString>;
8077
+ checkEmailVerification: _$alepha_server0.ActionPrimitiveFn<{
8078
+ query: _$alepha.TObject<{
8079
+ email: _$alepha.TString;
8080
+ userRealmName: _$alepha.TOptional<_$alepha.TString>;
8040
8081
  }>;
8041
- response: alepha.TObject<{
8042
- verified: alepha.TBoolean;
8082
+ response: _$alepha.TObject<{
8083
+ verified: _$alepha.TBoolean;
8043
8084
  }>;
8044
8085
  }>;
8045
8086
  }
@@ -8056,21 +8097,21 @@ declare class UserController {
8056
8097
  * It is lazy-loaded when the `sessionPurge` feature is enabled in the realm.
8057
8098
  */
8058
8099
  declare class UserJobs {
8059
- protected readonly log: alepha_logger0.Logger;
8100
+ protected readonly log: _$alepha_logger0.Logger;
8060
8101
  protected readonly dateTimeProvider: DateTimeProvider;
8061
- protected readonly sessionRepository: alepha_orm0.Repository<alepha.TObject<{
8062
- id: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_PRIMARY_KEY>, typeof alepha_orm0.PG_DEFAULT>;
8063
- version: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TInteger, typeof alepha_orm0.PG_VERSION>, typeof alepha_orm0.PG_DEFAULT>;
8064
- createdAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_CREATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
8065
- updatedAt: alepha_orm0.PgAttr<alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_UPDATED_AT>, typeof alepha_orm0.PG_DEFAULT>;
8066
- refreshToken: alepha.TString;
8067
- userId: alepha_orm0.PgAttr<alepha.TString, typeof alepha_orm0.PG_REF>;
8068
- expiresAt: alepha.TString;
8069
- ip: alepha.TOptional<alepha.TString>;
8070
- userAgent: alepha.TOptional<alepha.TObject<{
8071
- os: alepha.TString;
8072
- browser: alepha.TString;
8073
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8102
+ protected readonly sessionRepository: _$alepha_orm0.Repository<_$alepha.TObject<{
8103
+ id: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_PRIMARY_KEY>, typeof _$alepha_orm0.PG_DEFAULT>;
8104
+ version: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TInteger, typeof _$alepha_orm0.PG_VERSION>, typeof _$alepha_orm0.PG_DEFAULT>;
8105
+ createdAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_CREATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
8106
+ updatedAt: _$alepha_orm0.PgAttr<_$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_UPDATED_AT>, typeof _$alepha_orm0.PG_DEFAULT>;
8107
+ refreshToken: _$alepha.TString;
8108
+ userId: _$alepha_orm0.PgAttr<_$alepha.TString, typeof _$alepha_orm0.PG_REF>;
8109
+ expiresAt: _$alepha.TString;
8110
+ ip: _$alepha.TOptional<_$alepha.TString>;
8111
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
8112
+ os: _$alepha.TString;
8113
+ browser: _$alepha.TString;
8114
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8074
8115
  }>>;
8075
8116
  }>>;
8076
8117
  /**
@@ -8079,124 +8120,125 @@ declare class UserJobs {
8079
8120
  * This job runs daily at 3:00 AM and removes all sessions
8080
8121
  * where the `expiresAt` timestamp has passed.
8081
8122
  */
8082
- readonly purgeExpiredSessions: alepha_api_jobs0.JobPrimitive<alepha.TSchema>;
8123
+ readonly purgeExpiredSessions: _$alepha_api_jobs0.JobPrimitive<_$alepha.TSchema>;
8083
8124
  }
8084
8125
  //#endregion
8085
8126
  //#region ../../src/api/users/schemas/identityResourceSchema.d.ts
8086
- declare const identityResourceSchema: alepha.TObject<{
8087
- userId: PgAttr<alepha.TString, typeof PG_REF>;
8088
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8089
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8090
- provider: alepha.TString;
8091
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8092
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8093
- providerUserId: alepha.TOptional<alepha.TString>;
8094
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
8127
+ declare const identityResourceSchema: _$alepha.TObject<{
8128
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8129
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8130
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8131
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8132
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
8133
+ provider: _$alepha.TString;
8134
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
8135
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
8095
8136
  }>;
8096
8137
  type IdentityResource = Static<typeof identityResourceSchema>;
8097
8138
  //#endregion
8098
8139
  //#region ../../src/api/users/schemas/loginSchema.d.ts
8099
- declare const loginSchema: alepha.TObject<{
8100
- username: alepha.TString;
8101
- password: alepha.TString;
8140
+ declare const loginSchema: _$alepha.TObject<{
8141
+ username: _$alepha.TString;
8142
+ password: _$alepha.TString;
8102
8143
  }>;
8103
8144
  type LoginInput = Static<typeof loginSchema>;
8104
8145
  //#endregion
8105
8146
  //#region ../../src/api/users/schemas/realmConfigSchema.d.ts
8106
- declare const realmConfigSchema: alepha.TObject<{
8107
- settings: alepha.TObject<{
8108
- displayName: alepha.TOptional<alepha.TString>;
8109
- description: alepha.TOptional<alepha.TString>;
8110
- logoUrl: alepha.TOptional<alepha.TString>;
8111
- registrationAllowed: alepha.TBoolean;
8112
- email: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
8113
- username: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
8114
- usernameRegExp: alepha.TString;
8115
- phoneNumber: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
8116
- verifyEmailRequired: alepha.TBoolean;
8117
- verifyPhoneRequired: alepha.TBoolean;
8118
- firstNameLastName: alepha.TUnion<[typebox.TLiteral<"none">, typebox.TLiteral<"optional">, typebox.TLiteral<"required">]>;
8119
- resetPasswordAllowed: alepha.TBoolean;
8120
- adminEmails: alepha.TArray<alepha.TString>;
8121
- adminUsernames: alepha.TArray<alepha.TString>;
8122
- passwordPolicy: alepha.TObject<{
8123
- minLength: alepha.TInteger;
8124
- requireUppercase: alepha.TBoolean;
8125
- requireLowercase: alepha.TBoolean;
8126
- requireNumbers: alepha.TBoolean;
8127
- requireSpecialCharacters: alepha.TBoolean;
8128
- }>;
8129
- loginRateLimit: alepha.TObject<{
8130
- ipMaxAttempts: alepha.TInteger;
8131
- accountMaxAttempts: alepha.TInteger;
8132
- windowMs: alepha.TInteger;
8147
+ declare const realmConfigSchema: _$alepha.TObject<{
8148
+ settings: _$alepha.TObject<{
8149
+ displayName: _$alepha.TOptional<_$alepha.TString>;
8150
+ description: _$alepha.TOptional<_$alepha.TString>;
8151
+ logoUrl: _$alepha.TOptional<_$alepha.TString>;
8152
+ registrationAllowed: _$alepha.TBoolean;
8153
+ email: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
8154
+ username: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
8155
+ usernameRegExp: _$alepha.TString;
8156
+ phoneNumber: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
8157
+ verifyEmailRequired: _$alepha.TBoolean;
8158
+ verifyPhoneRequired: _$alepha.TBoolean;
8159
+ firstNameLastName: _$alepha.TUnion<[_$typebox.TLiteral<"none">, _$typebox.TLiteral<"optional">, _$typebox.TLiteral<"required">]>;
8160
+ resetPasswordAllowed: _$alepha.TBoolean;
8161
+ adminEmails: _$alepha.TArray<_$alepha.TString>;
8162
+ adminUsernames: _$alepha.TArray<_$alepha.TString>;
8163
+ passwordPolicy: _$alepha.TObject<{
8164
+ minLength: _$alepha.TInteger;
8165
+ requireUppercase: _$alepha.TBoolean;
8166
+ requireLowercase: _$alepha.TBoolean;
8167
+ requireNumbers: _$alepha.TBoolean;
8168
+ requireSpecialCharacters: _$alepha.TBoolean;
8169
+ }>;
8170
+ loginRateLimit: _$alepha.TObject<{
8171
+ ipMaxAttempts: _$alepha.TInteger;
8172
+ accountMaxAttempts: _$alepha.TInteger;
8173
+ windowMs: _$alepha.TInteger;
8133
8174
  }>;
8134
8175
  }>;
8135
- realmName: alepha.TString;
8136
- authenticationMethods: alepha.TArray<alepha.TObject<{
8137
- name: alepha.TString;
8138
- type: alepha.TUnsafe<"OAUTH2" | "OIDC" | "CREDENTIALS">;
8176
+ realmName: _$alepha.TString;
8177
+ authenticationMethods: _$alepha.TArray<_$alepha.TObject<{
8178
+ name: _$alepha.TString;
8179
+ type: _$alepha.TUnsafe<"OAUTH2" | "OIDC" | "CREDENTIALS">;
8139
8180
  }>>;
8140
8181
  }>;
8141
8182
  type RealmConfig = Static<typeof realmConfigSchema>;
8142
8183
  //#endregion
8143
8184
  //#region ../../src/api/users/schemas/registerSchema.d.ts
8144
- declare const registerSchema: alepha.TObject<{
8145
- username: alepha.TString;
8146
- email: alepha.TString;
8147
- password: alepha.TString;
8148
- confirmPassword: alepha.TString;
8149
- firstName: alepha.TOptional<alepha.TString>;
8150
- lastName: alepha.TOptional<alepha.TString>;
8185
+ declare const registerSchema: _$alepha.TObject<{
8186
+ username: _$alepha.TString;
8187
+ email: _$alepha.TString;
8188
+ password: _$alepha.TString;
8189
+ confirmPassword: _$alepha.TString;
8190
+ firstName: _$alepha.TOptional<_$alepha.TString>;
8191
+ lastName: _$alepha.TOptional<_$alepha.TString>;
8151
8192
  }>;
8152
8193
  type RegisterInput = Static<typeof registerSchema>;
8153
8194
  //#endregion
8154
8195
  //#region ../../src/api/users/schemas/resetPasswordSchema.d.ts
8155
- declare const resetPasswordRequestSchema: alepha.TObject<{
8156
- email: alepha.TString;
8196
+ declare const resetPasswordRequestSchema: _$alepha.TObject<{
8197
+ email: _$alepha.TString;
8157
8198
  }>;
8158
- declare const resetPasswordSchema: alepha.TObject<{
8159
- token: alepha.TString;
8160
- password: alepha.TString;
8161
- confirmPassword: alepha.TString;
8199
+ declare const resetPasswordSchema: _$alepha.TObject<{
8200
+ token: _$alepha.TString;
8201
+ password: _$alepha.TString;
8202
+ confirmPassword: _$alepha.TString;
8162
8203
  }>;
8163
8204
  type ResetPasswordRequest = Static<typeof resetPasswordRequestSchema>;
8164
8205
  type ResetPasswordInput = Static<typeof resetPasswordSchema>;
8165
8206
  //#endregion
8166
8207
  //#region ../../src/api/users/schemas/sessionResourceSchema.d.ts
8167
- declare const sessionResourceSchema: alepha.TObject<{
8168
- id: alepha.TString;
8169
- version: alepha.TNumber;
8170
- createdAt: alepha.TString;
8171
- updatedAt: alepha.TString;
8172
- refreshToken: alepha.TString;
8173
- userId: alepha.TString;
8174
- expiresAt: alepha.TString;
8175
- ip: alepha.TOptional<alepha.TString>;
8176
- userAgent: alepha.TOptional<alepha.TObject<{
8177
- os: alepha.TString;
8178
- browser: alepha.TString;
8179
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8208
+ declare const sessionResourceSchema: _$alepha.TObject<{
8209
+ id: _$alepha.TString;
8210
+ version: _$alepha.TNumber;
8211
+ createdAt: _$alepha.TString;
8212
+ updatedAt: _$alepha.TString;
8213
+ refreshToken: _$alepha.TString;
8214
+ userId: _$alepha.TString;
8215
+ expiresAt: _$alepha.TString;
8216
+ ip: _$alepha.TOptional<_$alepha.TString>;
8217
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
8218
+ os: _$alepha.TString;
8219
+ browser: _$alepha.TString;
8220
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8180
8221
  }>>;
8181
8222
  }>;
8182
8223
  type SessionResource = Static<typeof sessionResourceSchema>;
8183
8224
  //#endregion
8184
8225
  //#region ../../src/api/users/schemas/userResourceSchema.d.ts
8185
- declare const userResourceSchema: alepha.TObject<{
8186
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8187
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8188
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8189
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8190
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
8191
- username: alepha.TOptional<alepha.TString>;
8192
- email: alepha.TOptional<alepha.TString>;
8193
- phoneNumber: alepha.TOptional<alepha.TString>;
8194
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
8195
- firstName: alepha.TOptional<alepha.TString>;
8196
- lastName: alepha.TOptional<alepha.TString>;
8197
- picture: alepha.TOptional<alepha.TString>;
8198
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8199
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8226
+ declare const userResourceSchema: _$alepha.TObject<{
8227
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8228
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8229
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8230
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8231
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
8232
+ username: _$alepha.TOptional<_$alepha.TString>;
8233
+ email: _$alepha.TOptional<_$alepha.TString>;
8234
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
8235
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
8236
+ firstName: _$alepha.TOptional<_$alepha.TString>;
8237
+ lastName: _$alepha.TOptional<_$alepha.TString>;
8238
+ picture: _$alepha.TOptional<_$alepha.TString>;
8239
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8240
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8241
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
8200
8242
  }>;
8201
8243
  type UserResource = Static<typeof userResourceSchema>;
8202
8244
  //#endregion
@@ -8206,52 +8248,53 @@ declare class SessionService {
8206
8248
  protected readonly fsp: FileSystemProvider;
8207
8249
  protected readonly dateTimeProvider: DateTimeProvider;
8208
8250
  protected readonly cryptoProvider: CryptoProvider;
8209
- protected readonly log: alepha_logger0.Logger;
8251
+ protected readonly log: _$alepha_logger0.Logger;
8210
8252
  protected readonly realmProvider: RealmProvider;
8211
- protected readonly fileController: alepha_server_links0.HttpVirtualClient<FileController>;
8253
+ protected readonly fileController: _$alepha_server_links0.HttpVirtualClient<FileController>;
8212
8254
  protected readonly cacheProvider: CacheProvider;
8213
8255
  protected userAudits(realmName?: string): UserAudits | undefined;
8214
- users(userRealmName?: string): Repository$1<alepha.TObject<{
8215
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8216
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8217
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8218
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8219
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
8220
- username: alepha.TOptional<alepha.TString>;
8221
- email: alepha.TOptional<alepha.TString>;
8222
- phoneNumber: alepha.TOptional<alepha.TString>;
8223
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
8224
- firstName: alepha.TOptional<alepha.TString>;
8225
- lastName: alepha.TOptional<alepha.TString>;
8226
- picture: alepha.TOptional<alepha.TString>;
8227
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8228
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8256
+ users(userRealmName?: string): Repository$1<_$alepha.TObject<{
8257
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8258
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8259
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8260
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8261
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
8262
+ username: _$alepha.TOptional<_$alepha.TString>;
8263
+ email: _$alepha.TOptional<_$alepha.TString>;
8264
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
8265
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
8266
+ firstName: _$alepha.TOptional<_$alepha.TString>;
8267
+ lastName: _$alepha.TOptional<_$alepha.TString>;
8268
+ picture: _$alepha.TOptional<_$alepha.TString>;
8269
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8270
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8271
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
8229
8272
  }>>;
8230
- sessions(userRealmName?: string): Repository$1<alepha.TObject<{
8231
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8232
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8233
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8234
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8235
- refreshToken: alepha.TString;
8236
- userId: PgAttr<alepha.TString, typeof PG_REF>;
8237
- expiresAt: alepha.TString;
8238
- ip: alepha.TOptional<alepha.TString>;
8239
- userAgent: alepha.TOptional<alepha.TObject<{
8240
- os: alepha.TString;
8241
- browser: alepha.TString;
8242
- device: alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8273
+ sessions(userRealmName?: string): Repository$1<_$alepha.TObject<{
8274
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8275
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8276
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8277
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8278
+ refreshToken: _$alepha.TString;
8279
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
8280
+ expiresAt: _$alepha.TString;
8281
+ ip: _$alepha.TOptional<_$alepha.TString>;
8282
+ userAgent: _$alepha.TOptional<_$alepha.TObject<{
8283
+ os: _$alepha.TString;
8284
+ browser: _$alepha.TString;
8285
+ device: _$alepha.TUnsafe<"MOBILE" | "DESKTOP" | "TABLET">;
8243
8286
  }>>;
8244
8287
  }>>;
8245
- identities(userRealmName?: string): Repository$1<alepha.TObject<{
8246
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8247
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8248
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8249
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8250
- userId: PgAttr<alepha.TString, typeof PG_REF>;
8251
- password: alepha.TOptional<alepha.TString>;
8252
- provider: alepha.TString;
8253
- providerUserId: alepha.TOptional<alepha.TString>;
8254
- providerData: alepha.TOptional<alepha.TRecord<string, alepha.TAny>>;
8288
+ identities(userRealmName?: string): Repository$1<_$alepha.TObject<{
8289
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8290
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8291
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8292
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8293
+ userId: PgAttr<_$alepha.TString, typeof PG_REF>;
8294
+ password: _$alepha.TOptional<_$alepha.TString>;
8295
+ provider: _$alepha.TString;
8296
+ providerUserId: _$alepha.TOptional<_$alepha.TString>;
8297
+ providerData: _$alepha.TOptional<_$alepha.TRecord<string, _$alepha.TAny>>;
8255
8298
  }>>;
8256
8299
  /**
8257
8300
  * Check if user should be auto-promoted to admin based on adminEmails/adminUsernames settings.
@@ -8263,6 +8306,15 @@ declare class SessionService {
8263
8306
  username?: string | null;
8264
8307
  roles: string[];
8265
8308
  }, userRealmName?: string): Promise<boolean>;
8309
+ /**
8310
+ * Generate a unique username from an OAuth profile.
8311
+ *
8312
+ * 1. Extract candidate from email prefix
8313
+ * 2. Sanitize against realm's usernameRegExp (strip invalid chars, truncate)
8314
+ * 3. Check case-insensitive uniqueness, append suffix (2, 3, ...) if taken
8315
+ * 4. Fall back to "user" + random 6-char alphanumeric if all else fails
8316
+ */
8317
+ protected generateUniqueUsername(profile: OAuth2Profile, realmSettings: any, users: any): Promise<string>;
8266
8318
  /**
8267
8319
  * Random delay to prevent timing attacks (50-200ms)
8268
8320
  * Uses cryptographically secure random number generation
@@ -8290,36 +8342,38 @@ declare class SessionService {
8290
8342
  sessionId: string;
8291
8343
  }>;
8292
8344
  refreshSession(refreshToken: string, userRealmName?: string): Promise<{
8293
- user: PgStatic<alepha.TObject<{
8294
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8295
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8296
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8297
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8298
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
8299
- username: alepha.TOptional<alepha.TString>;
8300
- email: alepha.TOptional<alepha.TString>;
8301
- phoneNumber: alepha.TOptional<alepha.TString>;
8302
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
8303
- firstName: alepha.TOptional<alepha.TString>;
8304
- lastName: alepha.TOptional<alepha.TString>;
8305
- picture: alepha.TOptional<alepha.TString>;
8306
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8307
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8308
- }>, PgRelationMap<alepha.TObject<{
8309
- id: PgAttr<PgAttr<alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8310
- version: PgAttr<PgAttr<alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8311
- createdAt: PgAttr<PgAttr<alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8312
- updatedAt: PgAttr<PgAttr<alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8313
- realm: PgAttr<alepha.TString, typeof PG_DEFAULT>;
8314
- username: alepha.TOptional<alepha.TString>;
8315
- email: alepha.TOptional<alepha.TString>;
8316
- phoneNumber: alepha.TOptional<alepha.TString>;
8317
- roles: PgAttr<alepha.TArray<alepha.TString>, typeof PG_DEFAULT>;
8318
- firstName: alepha.TOptional<alepha.TString>;
8319
- lastName: alepha.TOptional<alepha.TString>;
8320
- picture: alepha.TOptional<alepha.TString>;
8321
- enabled: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8322
- emailVerified: PgAttr<alepha.TBoolean, typeof PG_DEFAULT>;
8345
+ user: PgStatic<_$alepha.TObject<{
8346
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8347
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8348
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8349
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8350
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
8351
+ username: _$alepha.TOptional<_$alepha.TString>;
8352
+ email: _$alepha.TOptional<_$alepha.TString>;
8353
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
8354
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
8355
+ firstName: _$alepha.TOptional<_$alepha.TString>;
8356
+ lastName: _$alepha.TOptional<_$alepha.TString>;
8357
+ picture: _$alepha.TOptional<_$alepha.TString>;
8358
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8359
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8360
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
8361
+ }>, PgRelationMap<_$alepha.TObject<{
8362
+ id: PgAttr<PgAttr<_$alepha.TString, typeof PG_PRIMARY_KEY>, typeof PG_DEFAULT>;
8363
+ version: PgAttr<PgAttr<_$alepha.TInteger, typeof PG_VERSION>, typeof PG_DEFAULT>;
8364
+ createdAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_CREATED_AT>, typeof PG_DEFAULT>;
8365
+ updatedAt: PgAttr<PgAttr<_$alepha.TString, typeof PG_UPDATED_AT>, typeof PG_DEFAULT>;
8366
+ realm: PgAttr<_$alepha.TString, typeof PG_DEFAULT>;
8367
+ username: _$alepha.TOptional<_$alepha.TString>;
8368
+ email: _$alepha.TOptional<_$alepha.TString>;
8369
+ phoneNumber: _$alepha.TOptional<_$alepha.TString>;
8370
+ roles: PgAttr<_$alepha.TArray<_$alepha.TString>, typeof PG_DEFAULT>;
8371
+ firstName: _$alepha.TOptional<_$alepha.TString>;
8372
+ lastName: _$alepha.TOptional<_$alepha.TString>;
8373
+ picture: _$alepha.TOptional<_$alepha.TString>;
8374
+ enabled: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8375
+ emailVerified: PgAttr<_$alepha.TBoolean, typeof PG_DEFAULT>;
8376
+ organizationId: PgAttr<_$alepha.TOptional<_$alepha.TString>, typeof PG_ORGANIZATION>;
8323
8377
  }>>>;
8324
8378
  expiresIn: number;
8325
8379
  sessionId: string;
@@ -8327,18 +8381,19 @@ declare class SessionService {
8327
8381
  deleteSession(refreshToken: string, userRealmName?: string): Promise<void>;
8328
8382
  link(provider: string, profile: OAuth2Profile, userRealmName?: string): Promise<{
8329
8383
  email?: string | undefined;
8330
- username?: string | undefined;
8331
8384
  phoneNumber?: string | undefined;
8385
+ username?: string | undefined;
8332
8386
  firstName?: string | undefined;
8333
8387
  lastName?: string | undefined;
8334
8388
  picture?: string | undefined;
8389
+ organizationId?: string | undefined;
8390
+ enabled: boolean;
8335
8391
  id: string;
8336
- createdAt: string;
8337
8392
  version: number;
8393
+ createdAt: string;
8338
8394
  updatedAt: string;
8339
8395
  realm: string;
8340
8396
  roles: string[];
8341
- enabled: boolean;
8342
8397
  emailVerified: boolean;
8343
8398
  } | {
8344
8399
  sub: string;
@@ -8388,7 +8443,7 @@ declare class SessionService {
8388
8443
  *
8389
8444
  * @module alepha.api.users
8390
8445
  */
8391
- declare const AlephaApiUsers: alepha.Service<alepha.Module>;
8446
+ declare const AlephaApiUsers: _$alepha.Service<_$alepha.Module>;
8392
8447
  //#endregion
8393
8448
  export { $realm, AdminIdentityController, AdminSessionController, AdminUserController, AlephaApiUsers, CompletePasswordResetRequest, CompleteRegistrationRequest, CreateUser, CredentialService, DEFAULT_USER_REALM_NAME, FieldRequirement, IdentityEntity, IdentityQuery, IdentityResource, IdentityService, LoginInput, PasswordResetIntentResponse, Realm, RealmAuthSettings, RealmConfig, RealmController, RealmFeatures, RealmOptions, RealmPrimitive, RealmProvider, RealmRepositories, RegisterInput, RegistrationIntentResponse, RegistrationService, ResetPasswordInput, ResetPasswordRequest, SessionCrudService, SessionEntity, SessionQuery, SessionResource, SessionService, UpdateUser, UserAudits, UserBuckets, UserController, UserEntity, UserJobs, UserNotifications, UserQuery, UserResource, UserService, completePasswordResetRequestSchema, completeRegistrationRequestSchema, createUserSchema, identities, identityQuerySchema, identityResourceSchema, loginSchema, passwordResetIntentResponseSchema, realmAuthSettingsAtom, realmConfigSchema, registerSchema, registrationIntentResponseSchema, resetPasswordRequestSchema, resetPasswordSchema, sessionQuerySchema, sessionResourceSchema, sessions, updateUserSchema, userQuerySchema, userResourceSchema, users };
8394
8449
  //# sourceMappingURL=index.d.ts.map