@authup/server-core 1.0.0-beta.58 → 1.0.0-beta.60

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 (730) hide show
  1. package/dist/adapters/database/domains/client/entity.d.ts.map +1 -1
  2. package/dist/adapters/database/domains/client/entity.mjs +58 -30
  3. package/dist/adapters/database/domains/client/entity.mjs.map +1 -1
  4. package/dist/adapters/database/domains/client-permission/entity.d.ts.map +1 -1
  5. package/dist/adapters/database/domains/client-permission/entity.mjs +48 -24
  6. package/dist/adapters/database/domains/client-permission/entity.mjs.map +1 -1
  7. package/dist/adapters/database/domains/client-role/entity.d.ts.map +1 -1
  8. package/dist/adapters/database/domains/client-role/entity.mjs +37 -17
  9. package/dist/adapters/database/domains/client-role/entity.mjs.map +1 -1
  10. package/dist/adapters/database/domains/client-scope/entity.d.ts.map +1 -1
  11. package/dist/adapters/database/domains/client-scope/entity.mjs +30 -14
  12. package/dist/adapters/database/domains/client-scope/entity.mjs.map +1 -1
  13. package/dist/adapters/database/domains/consent/entity.d.ts.map +1 -1
  14. package/dist/adapters/database/domains/consent/entity.mjs +34 -18
  15. package/dist/adapters/database/domains/consent/entity.mjs.map +1 -1
  16. package/dist/adapters/database/domains/event/entity.d.ts +1 -0
  17. package/dist/adapters/database/domains/event/entity.d.ts.map +1 -1
  18. package/dist/adapters/database/domains/event/entity.mjs +48 -23
  19. package/dist/adapters/database/domains/event/entity.mjs.map +1 -1
  20. package/dist/adapters/database/domains/identity-provider/entity.d.ts.map +1 -1
  21. package/dist/adapters/database/domains/identity-provider/entity.mjs +43 -23
  22. package/dist/adapters/database/domains/identity-provider/entity.mjs.map +1 -1
  23. package/dist/adapters/database/domains/identity-provider-account/entity.d.ts.map +1 -1
  24. package/dist/adapters/database/domains/identity-provider-account/entity.mjs +50 -22
  25. package/dist/adapters/database/domains/identity-provider-account/entity.mjs.map +1 -1
  26. package/dist/adapters/database/domains/identity-provider-attribute/entity.d.ts.map +1 -1
  27. package/dist/adapters/database/domains/identity-provider-attribute/entity.mjs +14 -6
  28. package/dist/adapters/database/domains/identity-provider-attribute/entity.mjs.map +1 -1
  29. package/dist/adapters/database/domains/identity-provider-attribute-mapping/entity.d.ts.map +1 -1
  30. package/dist/adapters/database/domains/identity-provider-attribute-mapping/entity.mjs +5 -1
  31. package/dist/adapters/database/domains/identity-provider-attribute-mapping/entity.mjs.map +1 -1
  32. package/dist/adapters/database/domains/identity-provider-permission-mapping/entity.d.ts.map +1 -1
  33. package/dist/adapters/database/domains/identity-provider-permission-mapping/entity.mjs +18 -6
  34. package/dist/adapters/database/domains/identity-provider-permission-mapping/entity.mjs.map +1 -1
  35. package/dist/adapters/database/domains/identity-provider-role-mapping/entity.d.ts.map +1 -1
  36. package/dist/adapters/database/domains/identity-provider-role-mapping/entity.mjs +34 -14
  37. package/dist/adapters/database/domains/identity-provider-role-mapping/entity.mjs.map +1 -1
  38. package/dist/adapters/database/domains/key/entity.d.ts.map +1 -1
  39. package/dist/adapters/database/domains/key/entity.mjs +35 -19
  40. package/dist/adapters/database/domains/key/entity.mjs.map +1 -1
  41. package/dist/adapters/database/domains/permission/entity.d.ts.map +1 -1
  42. package/dist/adapters/database/domains/permission/entity.mjs +35 -19
  43. package/dist/adapters/database/domains/permission/entity.mjs.map +1 -1
  44. package/dist/adapters/database/domains/permission-policy/entity.d.ts.map +1 -1
  45. package/dist/adapters/database/domains/permission-policy/entity.mjs +37 -17
  46. package/dist/adapters/database/domains/permission-policy/entity.mjs.map +1 -1
  47. package/dist/adapters/database/domains/policy/entity.d.ts.map +1 -1
  48. package/dist/adapters/database/domains/policy/entity.mjs +51 -27
  49. package/dist/adapters/database/domains/policy/entity.mjs.map +1 -1
  50. package/dist/adapters/database/domains/policy-attribute/entity.d.ts.map +1 -1
  51. package/dist/adapters/database/domains/policy-attribute/entity.mjs +14 -6
  52. package/dist/adapters/database/domains/policy-attribute/entity.mjs.map +1 -1
  53. package/dist/adapters/database/domains/realm/entity.d.ts.map +1 -1
  54. package/dist/adapters/database/domains/realm/entity.mjs +36 -20
  55. package/dist/adapters/database/domains/realm/entity.mjs.map +1 -1
  56. package/dist/adapters/database/domains/role/entity.d.ts.map +1 -1
  57. package/dist/adapters/database/domains/role/entity.mjs +44 -24
  58. package/dist/adapters/database/domains/role/entity.mjs.map +1 -1
  59. package/dist/adapters/database/domains/role-attribute/entity.d.ts.map +1 -1
  60. package/dist/adapters/database/domains/role-attribute/entity.mjs +30 -14
  61. package/dist/adapters/database/domains/role-attribute/entity.mjs.map +1 -1
  62. package/dist/adapters/database/domains/role-permission/entity.d.ts.map +1 -1
  63. package/dist/adapters/database/domains/role-permission/entity.mjs +45 -21
  64. package/dist/adapters/database/domains/role-permission/entity.mjs.map +1 -1
  65. package/dist/adapters/database/domains/scope/entity.d.ts.map +1 -1
  66. package/dist/adapters/database/domains/scope/entity.mjs +35 -19
  67. package/dist/adapters/database/domains/scope/entity.mjs.map +1 -1
  68. package/dist/adapters/database/domains/session/entity.d.ts.map +1 -1
  69. package/dist/adapters/database/domains/session/entity.mjs +63 -31
  70. package/dist/adapters/database/domains/session/entity.mjs.map +1 -1
  71. package/dist/adapters/database/domains/session-token/entity.d.ts +4 -1
  72. package/dist/adapters/database/domains/session-token/entity.d.ts.map +1 -1
  73. package/dist/adapters/database/domains/session-token/entity.mjs +40 -11
  74. package/dist/adapters/database/domains/session-token/entity.mjs.map +1 -1
  75. package/dist/adapters/database/domains/trust-anchor/entity.d.ts.map +1 -1
  76. package/dist/adapters/database/domains/trust-anchor/entity.mjs +25 -13
  77. package/dist/adapters/database/domains/trust-anchor/entity.mjs.map +1 -1
  78. package/dist/adapters/database/domains/user/entity.d.ts.map +1 -1
  79. package/dist/adapters/database/domains/user/entity.mjs +58 -34
  80. package/dist/adapters/database/domains/user/entity.mjs.map +1 -1
  81. package/dist/adapters/database/domains/user-attribute/entity.d.ts.map +1 -1
  82. package/dist/adapters/database/domains/user-attribute/entity.mjs +27 -11
  83. package/dist/adapters/database/domains/user-attribute/entity.mjs.map +1 -1
  84. package/dist/adapters/database/domains/user-authenticator/entity.d.ts.map +1 -1
  85. package/dist/adapters/database/domains/user-authenticator/entity.mjs +43 -23
  86. package/dist/adapters/database/domains/user-authenticator/entity.mjs.map +1 -1
  87. package/dist/adapters/database/domains/user-permission/entity.d.ts.map +1 -1
  88. package/dist/adapters/database/domains/user-permission/entity.mjs +45 -21
  89. package/dist/adapters/database/domains/user-permission/entity.mjs.map +1 -1
  90. package/dist/adapters/database/domains/user-role/entity.d.ts.map +1 -1
  91. package/dist/adapters/database/domains/user-role/entity.mjs +37 -17
  92. package/dist/adapters/database/domains/user-role/entity.mjs.map +1 -1
  93. package/dist/adapters/database/errors/driver.d.ts +9 -0
  94. package/dist/adapters/database/errors/driver.d.ts.map +1 -1
  95. package/dist/adapters/database/errors/driver.mjs +20 -1
  96. package/dist/adapters/database/errors/driver.mjs.map +1 -1
  97. package/dist/adapters/database/errors/index.mjs +2 -2
  98. package/dist/adapters/database/helpers/index.mjs +2 -2
  99. package/dist/adapters/database/helpers/is-supported.d.ts +7 -0
  100. package/dist/adapters/database/helpers/is-supported.d.ts.map +1 -1
  101. package/dist/adapters/database/helpers/is-supported.mjs +9 -1
  102. package/dist/adapters/database/helpers/is-supported.mjs.map +1 -1
  103. package/dist/adapters/database/index.mjs +3 -3
  104. package/dist/adapters/database/migrations/mysql/1785871780234-AlignSchemaWithEntityMetadata.d.ts +66 -0
  105. package/dist/adapters/database/migrations/mysql/1785871780234-AlignSchemaWithEntityMetadata.d.ts.map +1 -0
  106. package/dist/adapters/database/migrations/mysql/1785871780234-AlignSchemaWithEntityMetadata.mjs +181 -0
  107. package/dist/adapters/database/migrations/mysql/1785871780234-AlignSchemaWithEntityMetadata.mjs.map +1 -0
  108. package/dist/adapters/database/migrations/mysql/1786436332251-QueryIndexes.d.ts +44 -0
  109. package/dist/adapters/database/migrations/mysql/1786436332251-QueryIndexes.d.ts.map +1 -0
  110. package/dist/adapters/database/migrations/mysql/1786436332251-QueryIndexes.mjs +1294 -0
  111. package/dist/adapters/database/migrations/mysql/1786436332251-QueryIndexes.mjs.map +1 -0
  112. package/dist/adapters/database/migrations/postgres/1785871780234-AlignSchemaWithEntityMetadata.d.ts +43 -0
  113. package/dist/adapters/database/migrations/postgres/1785871780234-AlignSchemaWithEntityMetadata.d.ts.map +1 -0
  114. package/dist/adapters/database/migrations/postgres/1785871780234-AlignSchemaWithEntityMetadata.mjs +120 -0
  115. package/dist/adapters/database/migrations/postgres/1785871780234-AlignSchemaWithEntityMetadata.mjs.map +1 -0
  116. package/dist/adapters/database/migrations/postgres/1786436332251-QueryIndexes.d.ts +44 -0
  117. package/dist/adapters/database/migrations/postgres/1786436332251-QueryIndexes.d.ts.map +1 -0
  118. package/dist/adapters/database/migrations/postgres/1786436332251-QueryIndexes.mjs +987 -0
  119. package/dist/adapters/database/migrations/postgres/1786436332251-QueryIndexes.mjs.map +1 -0
  120. package/dist/adapters/http/controllers/entities/identity-provider/module.d.ts +14 -2
  121. package/dist/adapters/http/controllers/entities/identity-provider/module.d.ts.map +1 -1
  122. package/dist/adapters/http/controllers/entities/identity-provider/module.mjs +85 -19
  123. package/dist/adapters/http/controllers/entities/identity-provider/module.mjs.map +1 -1
  124. package/dist/adapters/http/controllers/entities/identity-provider/types.d.ts +4 -1
  125. package/dist/adapters/http/controllers/entities/identity-provider/types.d.ts.map +1 -1
  126. package/dist/adapters/http/controllers/entities/identity-provider-account/index.d.ts.map +1 -0
  127. package/dist/adapters/http/controllers/entities/identity-provider-account/index.mjs +5 -0
  128. package/dist/adapters/http/controllers/entities/identity-provider-account/module.d.ts +15 -0
  129. package/dist/adapters/http/controllers/entities/identity-provider-account/module.d.ts.map +1 -0
  130. package/dist/adapters/http/controllers/entities/identity-provider-account/module.mjs +94 -0
  131. package/dist/adapters/http/controllers/entities/identity-provider-account/module.mjs.map +1 -0
  132. package/dist/adapters/http/controllers/entities/index.d.ts +2 -0
  133. package/dist/adapters/http/controllers/entities/index.d.ts.map +1 -1
  134. package/dist/adapters/http/controllers/entities/index.mjs +5 -1
  135. package/dist/adapters/http/controllers/entities/session-token/index.d.ts +2 -0
  136. package/dist/adapters/http/controllers/entities/session-token/index.d.ts.map +1 -0
  137. package/dist/adapters/http/controllers/entities/session-token/index.mjs +5 -0
  138. package/dist/adapters/http/controllers/entities/session-token/module.d.ts +23 -0
  139. package/dist/adapters/http/controllers/entities/session-token/module.d.ts.map +1 -0
  140. package/dist/adapters/http/controllers/entities/session-token/module.mjs +112 -0
  141. package/dist/adapters/http/controllers/entities/session-token/module.mjs.map +1 -0
  142. package/dist/adapters/http/controllers/index.mjs +4 -1
  143. package/dist/adapters/http/controllers/workflows/account/index.d.ts +2 -0
  144. package/dist/adapters/http/controllers/workflows/account/index.d.ts.map +1 -0
  145. package/dist/adapters/http/controllers/workflows/account/index.mjs +5 -0
  146. package/dist/adapters/http/controllers/workflows/account/module.d.ts +24 -0
  147. package/dist/adapters/http/controllers/workflows/account/module.d.ts.map +1 -0
  148. package/dist/adapters/http/controllers/workflows/account/module.mjs +63 -0
  149. package/dist/adapters/http/controllers/workflows/account/module.mjs.map +1 -0
  150. package/dist/adapters/http/controllers/workflows/activate/module.mjs +1 -1
  151. package/dist/adapters/http/controllers/workflows/authenticator-challenge/module.d.ts.map +1 -1
  152. package/dist/adapters/http/controllers/workflows/authenticator-challenge/module.mjs +1 -0
  153. package/dist/adapters/http/controllers/workflows/authenticator-challenge/module.mjs.map +1 -1
  154. package/dist/adapters/http/controllers/workflows/authorize/module.mjs +2 -2
  155. package/dist/adapters/http/controllers/workflows/authorize/module.mjs.map +1 -1
  156. package/dist/adapters/http/controllers/workflows/index.d.ts +1 -0
  157. package/dist/adapters/http/controllers/workflows/index.d.ts.map +1 -1
  158. package/dist/adapters/http/controllers/workflows/index.mjs +3 -1
  159. package/dist/adapters/http/controllers/workflows/logout/module.mjs +2 -2
  160. package/dist/adapters/http/controllers/workflows/logout/module.mjs.map +1 -1
  161. package/dist/adapters/http/controllers/workflows/password-forgot/module.mjs +1 -1
  162. package/dist/adapters/http/controllers/workflows/password-reset/module.mjs +1 -1
  163. package/dist/adapters/http/controllers/workflows/register/module.mjs +1 -1
  164. package/dist/adapters/http/controllers/workflows/userinfo/module.d.ts.map +1 -1
  165. package/dist/adapters/http/controllers/workflows/userinfo/module.mjs +5 -1
  166. package/dist/adapters/http/controllers/workflows/userinfo/module.mjs.map +1 -1
  167. package/dist/adapters/http/index.mjs +5 -1
  168. package/dist/adapters/http/middleware/built-in/assets.d.ts +8 -1
  169. package/dist/adapters/http/middleware/built-in/assets.d.ts.map +1 -1
  170. package/dist/adapters/http/middleware/built-in/assets.mjs +48 -4
  171. package/dist/adapters/http/middleware/built-in/assets.mjs.map +1 -1
  172. package/dist/adapters/http/middleware/built-in/error.d.ts.map +1 -1
  173. package/dist/adapters/http/middleware/built-in/error.mjs +4 -3
  174. package/dist/adapters/http/middleware/built-in/error.mjs.map +1 -1
  175. package/dist/adapters/http/middleware/built-in/index.d.ts +2 -0
  176. package/dist/adapters/http/middleware/built-in/index.d.ts.map +1 -1
  177. package/dist/adapters/http/middleware/built-in/index.mjs +2 -1
  178. package/dist/adapters/http/middleware/built-in/theme.d.ts +15 -0
  179. package/dist/adapters/http/middleware/built-in/theme.d.ts.map +1 -0
  180. package/dist/adapters/http/middleware/built-in/theme.mjs +27 -0
  181. package/dist/adapters/http/middleware/built-in/theme.mjs.map +1 -0
  182. package/dist/adapters/http/middleware/built-in/types.d.ts +14 -0
  183. package/dist/adapters/http/middleware/built-in/types.d.ts.map +1 -0
  184. package/dist/adapters/http/middleware/built-in/ui-http-client.d.ts +1 -1
  185. package/dist/adapters/http/middleware/built-in/ui-http-client.mjs +1 -1
  186. package/dist/adapters/http/middleware/built-in/ui-http-client.mjs.map +1 -1
  187. package/dist/adapters/http/middleware/index.mjs +2 -1
  188. package/dist/adapters/http/request/event-context.d.ts.map +1 -1
  189. package/dist/adapters/http/request/event-context.mjs +2 -0
  190. package/dist/adapters/http/request/event-context.mjs.map +1 -1
  191. package/dist/adapters/http/ui/account-console/index.d.ts +4 -0
  192. package/dist/adapters/http/ui/account-console/index.d.ts.map +1 -0
  193. package/dist/adapters/http/ui/account-console/index.mjs +6 -0
  194. package/dist/adapters/http/ui/account-console/module.d.ts +28 -0
  195. package/dist/adapters/http/ui/account-console/module.d.ts.map +1 -0
  196. package/dist/adapters/http/ui/account-console/module.mjs +80 -0
  197. package/dist/adapters/http/ui/account-console/module.mjs.map +1 -0
  198. package/dist/adapters/http/ui/account-console/ref.d.ts +30 -0
  199. package/dist/adapters/http/ui/account-console/ref.d.ts.map +1 -0
  200. package/dist/adapters/http/ui/account-console/ref.mjs +50 -0
  201. package/dist/adapters/http/ui/account-console/ref.mjs.map +1 -0
  202. package/dist/adapters/http/ui/account-console/types.d.ts +11 -0
  203. package/dist/adapters/http/ui/account-console/types.d.ts.map +1 -0
  204. package/dist/adapters/http/ui/account-console/types.mjs +4 -0
  205. package/dist/adapters/http/ui/{internal-http-client.d.ts → auth-console/http-client.d.ts} +1 -1
  206. package/dist/adapters/http/ui/auth-console/http-client.d.ts.map +1 -0
  207. package/dist/adapters/http/ui/{internal-http-client.mjs → auth-console/http-client.mjs} +2 -2
  208. package/dist/adapters/http/ui/auth-console/http-client.mjs.map +1 -0
  209. package/dist/adapters/http/ui/auth-console/index.d.ts +6 -0
  210. package/dist/adapters/http/ui/auth-console/index.d.ts.map +1 -0
  211. package/dist/adapters/http/ui/auth-console/index.mjs +8 -0
  212. package/dist/adapters/http/ui/auth-console/module.d.ts +4 -0
  213. package/dist/adapters/http/ui/auth-console/module.d.ts.map +1 -0
  214. package/dist/adapters/http/ui/auth-console/module.mjs +73 -0
  215. package/dist/adapters/http/ui/auth-console/module.mjs.map +1 -0
  216. package/dist/adapters/http/ui/auth-console/resolve.d.ts +21 -0
  217. package/dist/adapters/http/ui/auth-console/resolve.d.ts.map +1 -0
  218. package/dist/adapters/http/ui/auth-console/resolve.mjs +53 -0
  219. package/dist/adapters/http/ui/auth-console/resolve.mjs.map +1 -0
  220. package/dist/adapters/http/ui/{serve.d.ts → auth-console/serve.d.ts} +1 -8
  221. package/dist/adapters/http/ui/auth-console/serve.d.ts.map +1 -0
  222. package/dist/adapters/http/ui/{serve.mjs → auth-console/serve.mjs} +5 -5
  223. package/dist/adapters/http/ui/auth-console/serve.mjs.map +1 -0
  224. package/dist/adapters/http/ui/auth-console/types.d.ts +26 -0
  225. package/dist/adapters/http/ui/auth-console/types.d.ts.map +1 -0
  226. package/dist/adapters/http/ui/auth-console/types.mjs +4 -0
  227. package/dist/adapters/http/ui/console-packages/index.d.ts +3 -0
  228. package/dist/adapters/http/ui/console-packages/index.d.ts.map +1 -0
  229. package/dist/adapters/http/ui/console-packages/index.mjs +5 -0
  230. package/dist/adapters/http/ui/console-packages/module.d.ts +33 -0
  231. package/dist/adapters/http/ui/console-packages/module.d.ts.map +1 -0
  232. package/dist/adapters/http/ui/console-packages/module.mjs +70 -0
  233. package/dist/adapters/http/ui/console-packages/module.mjs.map +1 -0
  234. package/dist/adapters/http/ui/console-packages/types.d.ts +12 -0
  235. package/dist/adapters/http/ui/console-packages/types.d.ts.map +1 -0
  236. package/dist/adapters/http/ui/console-packages/types.mjs +4 -0
  237. package/dist/adapters/http/ui/index.d.ts +5 -5
  238. package/dist/adapters/http/ui/index.d.ts.map +1 -1
  239. package/dist/adapters/http/ui/index.mjs +22 -5
  240. package/dist/adapters/http/ui/shared/html.d.ts +76 -0
  241. package/dist/adapters/http/ui/shared/html.d.ts.map +1 -0
  242. package/dist/adapters/http/ui/shared/html.mjs +103 -0
  243. package/dist/adapters/http/ui/shared/html.mjs.map +1 -0
  244. package/dist/adapters/http/ui/shared/index.d.ts +2 -0
  245. package/dist/adapters/http/ui/shared/index.d.ts.map +1 -0
  246. package/dist/adapters/http/ui/shared/index.mjs +5 -0
  247. package/dist/adapters/http/ui/theme/apply.d.ts +12 -0
  248. package/dist/adapters/http/ui/theme/apply.d.ts.map +1 -0
  249. package/dist/adapters/http/ui/theme/apply.mjs +29 -0
  250. package/dist/adapters/http/ui/theme/apply.mjs.map +1 -0
  251. package/dist/adapters/http/ui/theme/assets.d.ts +20 -0
  252. package/dist/adapters/http/ui/theme/assets.d.ts.map +1 -0
  253. package/dist/adapters/http/ui/theme/assets.mjs +86 -0
  254. package/dist/adapters/http/ui/theme/assets.mjs.map +1 -0
  255. package/dist/adapters/http/ui/theme/constants.d.ts +16 -0
  256. package/dist/adapters/http/ui/theme/constants.d.ts.map +1 -0
  257. package/dist/adapters/http/ui/theme/constants.mjs +20 -0
  258. package/dist/adapters/http/ui/theme/constants.mjs.map +1 -0
  259. package/dist/adapters/http/ui/theme/contract/constants.d.ts +120 -0
  260. package/dist/adapters/http/ui/theme/contract/constants.d.ts.map +1 -0
  261. package/dist/adapters/http/ui/theme/contract/constants.mjs +136 -0
  262. package/dist/adapters/http/ui/theme/contract/constants.mjs.map +1 -0
  263. package/dist/adapters/http/ui/theme/contract/head.d.ts +12 -0
  264. package/dist/adapters/http/ui/theme/contract/head.d.ts.map +1 -0
  265. package/dist/adapters/http/ui/theme/contract/head.mjs +61 -0
  266. package/dist/adapters/http/ui/theme/contract/head.mjs.map +1 -0
  267. package/dist/adapters/http/ui/theme/contract/index.d.ts +6 -0
  268. package/dist/adapters/http/ui/theme/contract/index.d.ts.map +1 -0
  269. package/dist/adapters/http/ui/theme/contract/index.mjs +8 -0
  270. package/dist/adapters/http/ui/theme/contract/manifest.d.ts +25 -0
  271. package/dist/adapters/http/ui/theme/contract/manifest.d.ts.map +1 -0
  272. package/dist/adapters/http/ui/theme/contract/manifest.mjs +77 -0
  273. package/dist/adapters/http/ui/theme/contract/manifest.mjs.map +1 -0
  274. package/dist/adapters/http/ui/theme/contract/types.d.ts +26 -0
  275. package/dist/adapters/http/ui/theme/contract/types.d.ts.map +1 -0
  276. package/dist/adapters/http/ui/theme/contract/types.mjs +4 -0
  277. package/dist/adapters/http/ui/theme/contract/utils.d.ts +11 -0
  278. package/dist/adapters/http/ui/theme/contract/utils.d.ts.map +1 -0
  279. package/dist/adapters/http/ui/theme/contract/utils.mjs +22 -0
  280. package/dist/adapters/http/ui/theme/contract/utils.mjs.map +1 -0
  281. package/dist/adapters/http/ui/theme/index.d.ts +7 -0
  282. package/dist/adapters/http/ui/theme/index.d.ts.map +1 -0
  283. package/dist/adapters/http/ui/theme/index.mjs +13 -0
  284. package/dist/adapters/http/ui/theme/module.d.ts +79 -0
  285. package/dist/adapters/http/ui/theme/module.d.ts.map +1 -0
  286. package/dist/adapters/http/ui/theme/module.mjs +206 -0
  287. package/dist/adapters/http/ui/theme/module.mjs.map +1 -0
  288. package/dist/adapters/http/ui/theme/types.d.ts +42 -0
  289. package/dist/adapters/http/ui/theme/types.d.ts.map +1 -0
  290. package/dist/adapters/http/ui/theme/types.mjs +4 -0
  291. package/dist/app/index.mjs +4 -2
  292. package/dist/app/modules/config/constants.d.ts +5 -0
  293. package/dist/app/modules/config/constants.d.ts.map +1 -1
  294. package/dist/app/modules/config/constants.mjs +5 -0
  295. package/dist/app/modules/config/constants.mjs.map +1 -1
  296. package/dist/app/modules/config/normalize.d.ts.map +1 -1
  297. package/dist/app/modules/config/normalize.mjs +8 -0
  298. package/dist/app/modules/config/normalize.mjs.map +1 -1
  299. package/dist/app/modules/config/origins.d.ts.map +1 -1
  300. package/dist/app/modules/config/origins.mjs +2 -0
  301. package/dist/app/modules/config/origins.mjs.map +1 -1
  302. package/dist/app/modules/config/read/env.d.ts.map +1 -1
  303. package/dist/app/modules/config/read/env.mjs +10 -0
  304. package/dist/app/modules/config/read/env.mjs.map +1 -1
  305. package/dist/app/modules/config/types.d.ts +63 -3
  306. package/dist/app/modules/config/types.d.ts.map +1 -1
  307. package/dist/app/modules/config/validator.d.ts.map +1 -1
  308. package/dist/app/modules/config/validator.mjs +5 -0
  309. package/dist/app/modules/config/validator.mjs.map +1 -1
  310. package/dist/app/modules/database/index.mjs +2 -1
  311. package/dist/app/modules/database/repositories/identity-provider-account/index.d.ts +2 -0
  312. package/dist/app/modules/database/repositories/identity-provider-account/index.d.ts.map +1 -0
  313. package/dist/app/modules/database/repositories/identity-provider-account/index.mjs +5 -0
  314. package/dist/app/modules/database/repositories/identity-provider-account/repository.d.ts +18 -0
  315. package/dist/app/modules/database/repositories/identity-provider-account/repository.d.ts.map +1 -0
  316. package/dist/app/modules/database/repositories/identity-provider-account/repository.mjs +69 -0
  317. package/dist/app/modules/database/repositories/identity-provider-account/repository.mjs.map +1 -0
  318. package/dist/app/modules/database/repositories/index.d.ts +1 -0
  319. package/dist/app/modules/database/repositories/index.d.ts.map +1 -1
  320. package/dist/app/modules/database/repositories/index.mjs +3 -1
  321. package/dist/app/modules/database/repositories/key/repository.d.ts +23 -0
  322. package/dist/app/modules/database/repositories/key/repository.d.ts.map +1 -1
  323. package/dist/app/modules/database/repositories/key/repository.mjs +39 -3
  324. package/dist/app/modules/database/repositories/key/repository.mjs.map +1 -1
  325. package/dist/app/modules/database/repositories/schema-validation.d.ts +14 -6
  326. package/dist/app/modules/database/repositories/schema-validation.d.ts.map +1 -1
  327. package/dist/app/modules/database/repositories/schema-validation.mjs +18 -6
  328. package/dist/app/modules/database/repositories/schema-validation.mjs.map +1 -1
  329. package/dist/app/modules/http/module.d.ts.map +1 -1
  330. package/dist/app/modules/http/module.mjs +7 -1
  331. package/dist/app/modules/http/module.mjs.map +1 -1
  332. package/dist/app/modules/http/modules/controller.d.ts +5 -2
  333. package/dist/app/modules/http/modules/controller.d.ts.map +1 -1
  334. package/dist/app/modules/http/modules/controller.mjs +57 -6
  335. package/dist/app/modules/http/modules/controller.mjs.map +1 -1
  336. package/dist/app/modules/http/modules/middleware.d.ts +9 -1
  337. package/dist/app/modules/http/modules/middleware.d.ts.map +1 -1
  338. package/dist/app/modules/http/modules/middleware.mjs +18 -3
  339. package/dist/app/modules/http/modules/middleware.mjs.map +1 -1
  340. package/dist/app/modules/identity/index.mjs +1 -2
  341. package/dist/app/modules/identity/module.d.ts.map +1 -1
  342. package/dist/app/modules/identity/module.mjs +2 -2
  343. package/dist/app/modules/identity/module.mjs.map +1 -1
  344. package/dist/app/modules/identity/repositories/index.mjs +1 -2
  345. package/dist/app/modules/identity/repositories/provider/index.d.ts +0 -1
  346. package/dist/app/modules/identity/repositories/provider/index.d.ts.map +1 -1
  347. package/dist/app/modules/identity/repositories/provider/index.mjs +1 -3
  348. package/dist/app/modules/index.mjs +4 -2
  349. package/dist/app/modules/logger/module.d.ts.map +1 -1
  350. package/dist/app/modules/logger/module.mjs +1 -0
  351. package/dist/app/modules/logger/module.mjs.map +1 -1
  352. package/dist/app/modules/oauth2/repositories/session-token/repository.d.ts +25 -1
  353. package/dist/app/modules/oauth2/repositories/session-token/repository.d.ts.map +1 -1
  354. package/dist/app/modules/oauth2/repositories/session-token/repository.mjs +70 -1
  355. package/dist/app/modules/oauth2/repositories/session-token/repository.mjs.map +1 -1
  356. package/dist/app/modules/provisioning/constants.d.ts +12 -0
  357. package/dist/app/modules/provisioning/constants.d.ts.map +1 -0
  358. package/dist/app/modules/provisioning/constants.mjs +16 -0
  359. package/dist/app/modules/provisioning/constants.mjs.map +1 -0
  360. package/dist/app/modules/provisioning/index.d.ts +2 -0
  361. package/dist/app/modules/provisioning/index.d.ts.map +1 -1
  362. package/dist/app/modules/provisioning/index.mjs +3 -1
  363. package/dist/app/modules/provisioning/lazy-wildcard.d.ts +15 -0
  364. package/dist/app/modules/provisioning/lazy-wildcard.d.ts.map +1 -0
  365. package/dist/app/modules/provisioning/lazy-wildcard.mjs +23 -0
  366. package/dist/app/modules/provisioning/lazy-wildcard.mjs.map +1 -0
  367. package/dist/app/modules/provisioning/module.d.ts.map +1 -1
  368. package/dist/app/modules/provisioning/module.mjs +24 -4
  369. package/dist/app/modules/provisioning/module.mjs.map +1 -1
  370. package/dist/app/modules/provisioning/sources/composite/module.d.ts +0 -19
  371. package/dist/app/modules/provisioning/sources/composite/module.d.ts.map +1 -1
  372. package/dist/app/modules/provisioning/sources/composite/module.mjs +7 -77
  373. package/dist/app/modules/provisioning/sources/composite/module.mjs.map +1 -1
  374. package/dist/app/modules/provisioning/sources/default/module.d.ts.map +1 -1
  375. package/dist/app/modules/provisioning/sources/default/module.mjs +1 -0
  376. package/dist/app/modules/provisioning/sources/default/module.mjs.map +1 -1
  377. package/dist/core/entities/client/index.d.ts +1 -1
  378. package/dist/core/entities/client/index.d.ts.map +1 -1
  379. package/dist/core/entities/client/index.mjs +2 -2
  380. package/dist/core/entities/client/schema.d.ts.map +1 -1
  381. package/dist/core/entities/client/schema.mjs +29 -10
  382. package/dist/core/entities/client/schema.mjs.map +1 -1
  383. package/dist/core/entities/client/service.mjs.map +1 -1
  384. package/dist/core/entities/client/system-clients.d.ts +95 -0
  385. package/dist/core/entities/client/system-clients.d.ts.map +1 -0
  386. package/dist/core/entities/client/system-clients.mjs +158 -0
  387. package/dist/core/entities/client/system-clients.mjs.map +1 -0
  388. package/dist/core/entities/client/types.d.ts +17 -4
  389. package/dist/core/entities/client/types.d.ts.map +1 -1
  390. package/dist/core/entities/client-permission/schema.d.ts.map +1 -1
  391. package/dist/core/entities/client-permission/schema.mjs +29 -6
  392. package/dist/core/entities/client-permission/schema.mjs.map +1 -1
  393. package/dist/core/entities/client-role/schema.d.ts.map +1 -1
  394. package/dist/core/entities/client-role/schema.mjs +27 -6
  395. package/dist/core/entities/client-role/schema.mjs.map +1 -1
  396. package/dist/core/entities/client-scope/schema.d.ts.map +1 -1
  397. package/dist/core/entities/client-scope/schema.mjs +19 -5
  398. package/dist/core/entities/client-scope/schema.mjs.map +1 -1
  399. package/dist/core/entities/consent/schema.d.ts.map +1 -1
  400. package/dist/core/entities/consent/schema.mjs +28 -6
  401. package/dist/core/entities/consent/schema.mjs.map +1 -1
  402. package/dist/core/entities/event/entity-event-handler.d.ts.map +1 -1
  403. package/dist/core/entities/event/entity-event-handler.mjs +2 -0
  404. package/dist/core/entities/event/entity-event-handler.mjs.map +1 -1
  405. package/dist/core/entities/event/sanitize.d.ts.map +1 -1
  406. package/dist/core/entities/event/sanitize.mjs +7 -4
  407. package/dist/core/entities/event/sanitize.mjs.map +1 -1
  408. package/dist/core/entities/event/schema.d.ts.map +1 -1
  409. package/dist/core/entities/event/schema.mjs +45 -16
  410. package/dist/core/entities/event/schema.mjs.map +1 -1
  411. package/dist/core/entities/event/service.d.ts.map +1 -1
  412. package/dist/core/entities/event/service.mjs +2 -0
  413. package/dist/core/entities/event/service.mjs.map +1 -1
  414. package/dist/core/entities/event/types.d.ts +2 -0
  415. package/dist/core/entities/event/types.d.ts.map +1 -1
  416. package/dist/core/entities/identity-provider/schema.d.ts.map +1 -1
  417. package/dist/core/entities/identity-provider/schema.mjs +29 -11
  418. package/dist/core/entities/identity-provider/schema.mjs.map +1 -1
  419. package/dist/core/entities/identity-provider-account/error.d.ts +7 -0
  420. package/dist/core/entities/identity-provider-account/error.d.ts.map +1 -0
  421. package/dist/core/entities/identity-provider-account/error.mjs +24 -0
  422. package/dist/core/entities/identity-provider-account/error.mjs.map +1 -0
  423. package/dist/core/entities/identity-provider-account/index.d.ts +5 -0
  424. package/dist/core/entities/identity-provider-account/index.d.ts.map +1 -0
  425. package/dist/core/entities/identity-provider-account/index.mjs +8 -0
  426. package/dist/core/entities/identity-provider-account/schema.d.ts +3 -0
  427. package/dist/core/entities/identity-provider-account/schema.d.ts.map +1 -0
  428. package/dist/core/entities/identity-provider-account/schema.mjs +52 -0
  429. package/dist/core/entities/identity-provider-account/schema.mjs.map +1 -0
  430. package/dist/core/entities/identity-provider-account/service.d.ts +24 -0
  431. package/dist/core/entities/identity-provider-account/service.d.ts.map +1 -0
  432. package/dist/core/entities/identity-provider-account/service.mjs +129 -0
  433. package/dist/core/entities/identity-provider-account/service.mjs.map +1 -0
  434. package/dist/core/entities/identity-provider-account/types.d.ts +69 -0
  435. package/dist/core/entities/identity-provider-account/types.d.ts.map +1 -0
  436. package/dist/core/entities/identity-provider-account/types.mjs +17 -0
  437. package/dist/core/entities/identity-provider-account/types.mjs.map +1 -0
  438. package/dist/core/entities/identity-provider-role-mapping/schema.d.ts.map +1 -1
  439. package/dist/core/entities/identity-provider-role-mapping/schema.mjs +27 -6
  440. package/dist/core/entities/identity-provider-role-mapping/schema.mjs.map +1 -1
  441. package/dist/core/entities/index.d.ts +2 -0
  442. package/dist/core/entities/index.d.ts.map +1 -1
  443. package/dist/core/entities/index.mjs +10 -2
  444. package/dist/core/entities/key/schema.d.ts.map +1 -1
  445. package/dist/core/entities/key/schema.mjs +39 -17
  446. package/dist/core/entities/key/schema.mjs.map +1 -1
  447. package/dist/core/entities/key/service.d.ts.map +1 -1
  448. package/dist/core/entities/key/service.mjs +1 -0
  449. package/dist/core/entities/key/service.mjs.map +1 -1
  450. package/dist/core/entities/permission/schema.d.ts.map +1 -1
  451. package/dist/core/entities/permission/schema.mjs +34 -13
  452. package/dist/core/entities/permission/schema.mjs.map +1 -1
  453. package/dist/core/entities/permission-policy/schema.d.ts.map +1 -1
  454. package/dist/core/entities/permission-policy/schema.mjs +27 -6
  455. package/dist/core/entities/permission-policy/schema.mjs.map +1 -1
  456. package/dist/core/entities/policy/schema.d.ts.map +1 -1
  457. package/dist/core/entities/policy/schema.mjs +31 -12
  458. package/dist/core/entities/policy/schema.mjs.map +1 -1
  459. package/dist/core/entities/realm/schema.d.ts.map +1 -1
  460. package/dist/core/entities/realm/schema.mjs +26 -12
  461. package/dist/core/entities/realm/schema.mjs.map +1 -1
  462. package/dist/core/entities/realm/service.d.ts +8 -6
  463. package/dist/core/entities/realm/service.d.ts.map +1 -1
  464. package/dist/core/entities/realm/service.mjs +5 -8
  465. package/dist/core/entities/realm/service.mjs.map +1 -1
  466. package/dist/core/entities/role/schema.d.ts.map +1 -1
  467. package/dist/core/entities/role/schema.mjs +36 -14
  468. package/dist/core/entities/role/schema.mjs.map +1 -1
  469. package/dist/core/entities/role-attribute/schema.d.ts.map +1 -1
  470. package/dist/core/entities/role-attribute/schema.mjs +28 -14
  471. package/dist/core/entities/role-attribute/schema.mjs.map +1 -1
  472. package/dist/core/entities/role-permission/schema.d.ts.map +1 -1
  473. package/dist/core/entities/role-permission/schema.mjs +29 -6
  474. package/dist/core/entities/role-permission/schema.mjs.map +1 -1
  475. package/dist/core/entities/scope/schema.d.ts.map +1 -1
  476. package/dist/core/entities/scope/schema.mjs +28 -12
  477. package/dist/core/entities/scope/schema.mjs.map +1 -1
  478. package/dist/core/entities/session/schema.d.ts.map +1 -1
  479. package/dist/core/entities/session/schema.mjs +41 -9
  480. package/dist/core/entities/session/schema.mjs.map +1 -1
  481. package/dist/core/entities/session-token/index.d.ts +4 -0
  482. package/dist/core/entities/session-token/index.d.ts.map +1 -0
  483. package/dist/core/entities/session-token/index.mjs +6 -0
  484. package/dist/core/entities/session-token/schema.d.ts +12 -0
  485. package/dist/core/entities/session-token/schema.d.ts.map +1 -0
  486. package/dist/core/entities/session-token/schema.mjs +66 -0
  487. package/dist/core/entities/session-token/schema.mjs.map +1 -0
  488. package/dist/core/entities/session-token/service.d.ts +70 -0
  489. package/dist/core/entities/session-token/service.d.ts.map +1 -0
  490. package/dist/core/entities/session-token/service.mjs +216 -0
  491. package/dist/core/entities/session-token/service.mjs.map +1 -0
  492. package/dist/core/entities/session-token/types.d.ts +37 -0
  493. package/dist/core/entities/session-token/types.d.ts.map +1 -0
  494. package/dist/core/entities/session-token/types.mjs +4 -0
  495. package/dist/core/entities/trust-anchor/schema.d.ts.map +1 -1
  496. package/dist/core/entities/trust-anchor/schema.mjs +27 -13
  497. package/dist/core/entities/trust-anchor/schema.mjs.map +1 -1
  498. package/dist/core/entities/trust-anchor/service.d.ts.map +1 -1
  499. package/dist/core/entities/trust-anchor/service.mjs +1 -0
  500. package/dist/core/entities/trust-anchor/service.mjs.map +1 -1
  501. package/dist/core/entities/user/schema.d.ts.map +1 -1
  502. package/dist/core/entities/user/schema.mjs +29 -12
  503. package/dist/core/entities/user/schema.mjs.map +1 -1
  504. package/dist/core/entities/user-attribute/schema.d.ts.map +1 -1
  505. package/dist/core/entities/user-attribute/schema.mjs +28 -14
  506. package/dist/core/entities/user-attribute/schema.mjs.map +1 -1
  507. package/dist/core/entities/user-authenticator/schema.d.ts.map +1 -1
  508. package/dist/core/entities/user-authenticator/schema.mjs +29 -12
  509. package/dist/core/entities/user-authenticator/schema.mjs.map +1 -1
  510. package/dist/core/entities/user-authenticator/service.d.ts +2 -1
  511. package/dist/core/entities/user-authenticator/service.d.ts.map +1 -1
  512. package/dist/core/entities/user-authenticator/service.mjs +5 -0
  513. package/dist/core/entities/user-authenticator/service.mjs.map +1 -1
  514. package/dist/core/entities/user-authenticator/types.d.ts +7 -1
  515. package/dist/core/entities/user-authenticator/types.d.ts.map +1 -1
  516. package/dist/core/entities/user-authenticator/types.mjs.map +1 -1
  517. package/dist/core/entities/user-permission/schema.d.ts.map +1 -1
  518. package/dist/core/entities/user-permission/schema.mjs +29 -6
  519. package/dist/core/entities/user-permission/schema.mjs.map +1 -1
  520. package/dist/core/entities/user-role/schema.d.ts.map +1 -1
  521. package/dist/core/entities/user-role/schema.mjs +27 -6
  522. package/dist/core/entities/user-role/schema.mjs.map +1 -1
  523. package/dist/core/identity/index.mjs +2 -1
  524. package/dist/core/identity/provider/account/error.d.ts +7 -0
  525. package/dist/core/identity/provider/account/error.d.ts.map +1 -0
  526. package/dist/core/identity/provider/account/error.mjs +24 -0
  527. package/dist/core/identity/provider/account/error.mjs.map +1 -0
  528. package/dist/core/identity/provider/account/index.d.ts +1 -0
  529. package/dist/core/identity/provider/account/index.d.ts.map +1 -1
  530. package/dist/core/identity/provider/account/index.mjs +2 -1
  531. package/dist/core/identity/provider/account/module.d.ts +2 -0
  532. package/dist/core/identity/provider/account/module.d.ts.map +1 -1
  533. package/dist/core/identity/provider/account/module.mjs +30 -0
  534. package/dist/core/identity/provider/account/module.mjs.map +1 -1
  535. package/dist/core/identity/provider/account/types.d.ts +12 -10
  536. package/dist/core/identity/provider/account/types.d.ts.map +1 -1
  537. package/dist/core/identity/provider/authentication/protocols/oauth2/module.d.ts +1 -0
  538. package/dist/core/identity/provider/authentication/protocols/oauth2/module.d.ts.map +1 -1
  539. package/dist/core/identity/provider/authentication/protocols/oauth2/module.mjs +5 -1
  540. package/dist/core/identity/provider/authentication/protocols/oauth2/module.mjs.map +1 -1
  541. package/dist/core/identity/provider/authentication/protocols/oauth2/types.d.ts +7 -0
  542. package/dist/core/identity/provider/authentication/protocols/oauth2/types.d.ts.map +1 -1
  543. package/dist/core/identity/provider/index.mjs +2 -1
  544. package/dist/core/index.mjs +15 -3
  545. package/dist/core/key/types.d.ts +2 -1
  546. package/dist/core/key/types.d.ts.map +1 -1
  547. package/dist/core/oauth2/authorization/code-request/verifier/module.d.ts.map +1 -1
  548. package/dist/core/oauth2/authorization/code-request/verifier/module.mjs +2 -2
  549. package/dist/core/oauth2/authorization/code-request/verifier/module.mjs.map +1 -1
  550. package/dist/core/oauth2/authorization/module.d.ts.map +1 -1
  551. package/dist/core/oauth2/authorization/module.mjs +2 -0
  552. package/dist/core/oauth2/authorization/module.mjs.map +1 -1
  553. package/dist/core/oauth2/authorization/state/types.d.ts +11 -0
  554. package/dist/core/oauth2/authorization/state/types.d.ts.map +1 -1
  555. package/dist/core/oauth2/end-session/service.d.ts.map +1 -1
  556. package/dist/core/oauth2/end-session/service.mjs +4 -4
  557. package/dist/core/oauth2/end-session/service.mjs.map +1 -1
  558. package/dist/core/oauth2/grant-types/authorize.d.ts.map +1 -1
  559. package/dist/core/oauth2/grant-types/authorize.mjs +1 -5
  560. package/dist/core/oauth2/grant-types/authorize.mjs.map +1 -1
  561. package/dist/core/oauth2/grant-types/password.mjs +2 -5
  562. package/dist/core/oauth2/grant-types/password.mjs.map +1 -1
  563. package/dist/core/oauth2/grant-types/refresh-token.d.ts.map +1 -1
  564. package/dist/core/oauth2/grant-types/refresh-token.mjs +37 -24
  565. package/dist/core/oauth2/grant-types/refresh-token.mjs.map +1 -1
  566. package/dist/core/oauth2/index.mjs +3 -1
  567. package/dist/core/oauth2/mfa-login/module.d.ts.map +1 -1
  568. package/dist/core/oauth2/mfa-login/module.mjs +4 -7
  569. package/dist/core/oauth2/mfa-login/module.mjs.map +1 -1
  570. package/dist/core/oauth2/session-token/error.d.ts +36 -0
  571. package/dist/core/oauth2/session-token/error.d.ts.map +1 -0
  572. package/dist/core/oauth2/session-token/error.mjs +49 -0
  573. package/dist/core/oauth2/session-token/error.mjs.map +1 -0
  574. package/dist/core/oauth2/session-token/index.d.ts +1 -0
  575. package/dist/core/oauth2/session-token/index.d.ts.map +1 -1
  576. package/dist/core/oauth2/session-token/index.mjs +2 -1
  577. package/dist/core/oauth2/session-token/types.d.ts +40 -0
  578. package/dist/core/oauth2/session-token/types.d.ts.map +1 -1
  579. package/dist/core/oauth2/token/issuer/access/module.d.ts.map +1 -1
  580. package/dist/core/oauth2/token/issuer/access/module.mjs +1 -0
  581. package/dist/core/oauth2/token/issuer/access/module.mjs.map +1 -1
  582. package/dist/core/oauth2/token/issuer/base.d.ts +1 -1
  583. package/dist/core/oauth2/token/issuer/base.d.ts.map +1 -1
  584. package/dist/core/oauth2/token/issuer/base.mjs.map +1 -1
  585. package/dist/core/oauth2/token/issuer/refresh/module.d.ts.map +1 -1
  586. package/dist/core/oauth2/token/issuer/refresh/module.mjs +1 -0
  587. package/dist/core/oauth2/token/issuer/refresh/module.mjs.map +1 -1
  588. package/dist/core/provisioning/constants.d.ts +8 -0
  589. package/dist/core/provisioning/constants.d.ts.map +1 -0
  590. package/dist/core/provisioning/constants.mjs +14 -0
  591. package/dist/core/provisioning/constants.mjs.map +1 -0
  592. package/dist/core/provisioning/entities/index.mjs +2 -1
  593. package/dist/core/provisioning/entities/realm/index.d.ts +1 -0
  594. package/dist/core/provisioning/entities/realm/index.d.ts.map +1 -1
  595. package/dist/core/provisioning/entities/realm/index.mjs +2 -1
  596. package/dist/core/provisioning/entities/realm/validator.d.ts +11 -0
  597. package/dist/core/provisioning/entities/realm/validator.d.ts.map +1 -1
  598. package/dist/core/provisioning/entities/realm/validator.mjs +14 -0
  599. package/dist/core/provisioning/entities/realm/validator.mjs.map +1 -1
  600. package/dist/core/provisioning/entities/realm/wildcard-validator.d.ts +19 -0
  601. package/dist/core/provisioning/entities/realm/wildcard-validator.d.ts.map +1 -0
  602. package/dist/core/provisioning/entities/realm/wildcard-validator.mjs +65 -0
  603. package/dist/core/provisioning/entities/realm/wildcard-validator.mjs.map +1 -0
  604. package/dist/core/provisioning/index.d.ts +3 -0
  605. package/dist/core/provisioning/index.d.ts.map +1 -1
  606. package/dist/core/provisioning/index.mjs +7 -1
  607. package/dist/core/provisioning/merge/index.d.ts +3 -0
  608. package/dist/core/provisioning/merge/index.d.ts.map +1 -0
  609. package/dist/core/provisioning/merge/index.mjs +5 -0
  610. package/dist/core/provisioning/merge/module.d.ts +18 -0
  611. package/dist/core/provisioning/merge/module.d.ts.map +1 -0
  612. package/dist/core/provisioning/merge/module.mjs +82 -0
  613. package/dist/core/provisioning/merge/module.mjs.map +1 -0
  614. package/dist/core/provisioning/merge/types.d.ts +34 -0
  615. package/dist/core/provisioning/merge/types.d.ts.map +1 -0
  616. package/dist/core/provisioning/merge/types.mjs +4 -0
  617. package/dist/core/provisioning/types.d.ts +10 -0
  618. package/dist/core/provisioning/types.d.ts.map +1 -1
  619. package/dist/core/provisioning/wildcard/index.d.ts +3 -0
  620. package/dist/core/provisioning/wildcard/index.d.ts.map +1 -0
  621. package/dist/core/provisioning/wildcard/index.mjs +5 -0
  622. package/dist/core/provisioning/wildcard/module.d.ts +53 -0
  623. package/dist/core/provisioning/wildcard/module.d.ts.map +1 -0
  624. package/dist/core/provisioning/wildcard/module.mjs +91 -0
  625. package/dist/core/provisioning/wildcard/module.mjs.map +1 -0
  626. package/dist/core/provisioning/wildcard/types.d.ts +19 -0
  627. package/dist/core/provisioning/wildcard/types.d.ts.map +1 -0
  628. package/dist/core/provisioning/wildcard/types.mjs +4 -0
  629. package/dist/core/query/index.mjs +2 -2
  630. package/dist/core/query/module.d.ts +19 -9
  631. package/dist/core/query/module.d.ts.map +1 -1
  632. package/dist/core/query/module.mjs +22 -10
  633. package/dist/core/query/module.mjs.map +1 -1
  634. package/dist/index.mjs +10 -4
  635. package/dist/path.d.ts +0 -2
  636. package/dist/path.d.ts.map +1 -1
  637. package/dist/path.mjs +1 -3
  638. package/dist/path.mjs.map +1 -1
  639. package/dist/swagger.json +885 -112
  640. package/dist/utils/error.d.ts +20 -3
  641. package/dist/utils/error.d.ts.map +1 -1
  642. package/dist/utils/error.mjs +102 -5
  643. package/dist/utils/error.mjs.map +1 -1
  644. package/dist/utils/index.mjs +2 -2
  645. package/package.json +25 -61
  646. package/dist/adapters/http/ui/base-path.d.ts +0 -9
  647. package/dist/adapters/http/ui/base-path.d.ts.map +0 -1
  648. package/dist/adapters/http/ui/base-path.mjs +0 -18
  649. package/dist/adapters/http/ui/base-path.mjs.map +0 -1
  650. package/dist/adapters/http/ui/internal-http-client.d.ts.map +0 -1
  651. package/dist/adapters/http/ui/internal-http-client.mjs.map +0 -1
  652. package/dist/adapters/http/ui/render.d.ts +0 -4
  653. package/dist/adapters/http/ui/render.d.ts.map +0 -1
  654. package/dist/adapters/http/ui/render.mjs +0 -63
  655. package/dist/adapters/http/ui/render.mjs.map +0 -1
  656. package/dist/adapters/http/ui/serve.d.ts.map +0 -1
  657. package/dist/adapters/http/ui/serve.mjs.map +0 -1
  658. package/dist/adapters/http/ui/types.d.ts +0 -20
  659. package/dist/adapters/http/ui/types.d.ts.map +0 -1
  660. package/dist/app/modules/identity/repositories/provider/account/index.d.ts.map +0 -1
  661. package/dist/app/modules/identity/repositories/provider/account/index.mjs +0 -5
  662. package/dist/app/modules/identity/repositories/provider/account/module.d.ts +0 -10
  663. package/dist/app/modules/identity/repositories/provider/account/module.d.ts.map +0 -1
  664. package/dist/app/modules/identity/repositories/provider/account/module.mjs +0 -28
  665. package/dist/app/modules/identity/repositories/provider/account/module.mjs.map +0 -1
  666. package/dist/core/entities/client/web-client.d.ts +0 -72
  667. package/dist/core/entities/client/web-client.d.ts.map +0 -1
  668. package/dist/core/entities/client/web-client.mjs +0 -123
  669. package/dist/core/entities/client/web-client.mjs.map +0 -1
  670. package/dist/ui/client/.vite/ssr-manifest.json +0 -54974
  671. package/dist/ui/client/assets/asap-latin-400-normal-Dc37g3Il.woff +0 -0
  672. package/dist/ui/client/assets/asap-latin-400-normal-DnZ1MOsG.woff2 +0 -0
  673. package/dist/ui/client/assets/asap-latin-700-normal-Dqcopq14.woff +0 -0
  674. package/dist/ui/client/assets/asap-latin-700-normal-l2Y8pi-F.woff2 +0 -0
  675. package/dist/ui/client/assets/asap-latin-ext-400-normal-C-fcRdtE.woff +0 -0
  676. package/dist/ui/client/assets/asap-latin-ext-400-normal-DwYtpHbV.woff2 +0 -0
  677. package/dist/ui/client/assets/asap-latin-ext-700-normal-D00OESsZ.woff +0 -0
  678. package/dist/ui/client/assets/asap-latin-ext-700-normal-y8bo5aW5.woff2 +0 -0
  679. package/dist/ui/client/assets/asap-vietnamese-400-normal-DGyJlJLT.woff2 +0 -0
  680. package/dist/ui/client/assets/asap-vietnamese-400-normal-lfLaoF2x.woff +0 -0
  681. package/dist/ui/client/assets/asap-vietnamese-700-normal-B-e19ug5.woff +0 -0
  682. package/dist/ui/client/assets/asap-vietnamese-700-normal-D-SxY94i.woff2 +0 -0
  683. package/dist/ui/client/assets/index-BTK3GPZZ.js +0 -106
  684. package/dist/ui/client/assets/index-Cx_pI7BS.css +0 -2
  685. package/dist/ui/client/assets/nunito-cyrillic-300-normal-BPQV259B.woff2 +0 -0
  686. package/dist/ui/client/assets/nunito-cyrillic-300-normal-g5qSsvc0.woff +0 -0
  687. package/dist/ui/client/assets/nunito-cyrillic-400-normal-D1j0u8EH.woff +0 -0
  688. package/dist/ui/client/assets/nunito-cyrillic-400-normal-xAOo5cBP.woff2 +0 -0
  689. package/dist/ui/client/assets/nunito-cyrillic-600-normal-BUjmtIuu.woff +0 -0
  690. package/dist/ui/client/assets/nunito-cyrillic-600-normal-DJGQ2h05.woff2 +0 -0
  691. package/dist/ui/client/assets/nunito-cyrillic-700-normal-DP36NgGt.woff2 +0 -0
  692. package/dist/ui/client/assets/nunito-cyrillic-700-normal-DfHRUDv-.woff +0 -0
  693. package/dist/ui/client/assets/nunito-cyrillic-ext-300-normal-BDHtqmCR.woff +0 -0
  694. package/dist/ui/client/assets/nunito-cyrillic-ext-300-normal-ChMQLIrm.woff2 +0 -0
  695. package/dist/ui/client/assets/nunito-cyrillic-ext-400-normal-CuPM9foi.woff2 +0 -0
  696. package/dist/ui/client/assets/nunito-cyrillic-ext-400-normal-xaE7D4Sw.woff +0 -0
  697. package/dist/ui/client/assets/nunito-cyrillic-ext-600-normal-CWPPjBOD.woff2 +0 -0
  698. package/dist/ui/client/assets/nunito-cyrillic-ext-600-normal-vnfu4DTE.woff +0 -0
  699. package/dist/ui/client/assets/nunito-cyrillic-ext-700-normal-BuR0mlCG.woff2 +0 -0
  700. package/dist/ui/client/assets/nunito-cyrillic-ext-700-normal-DfoqN4Gs.woff +0 -0
  701. package/dist/ui/client/assets/nunito-latin-300-normal-C3ZIKvzv.woff +0 -0
  702. package/dist/ui/client/assets/nunito-latin-300-normal-COoPE5VN.woff2 +0 -0
  703. package/dist/ui/client/assets/nunito-latin-400-normal-DKg4f3fz.woff +0 -0
  704. package/dist/ui/client/assets/nunito-latin-400-normal-r8SDr6Up.woff2 +0 -0
  705. package/dist/ui/client/assets/nunito-latin-600-normal-Br8yIETf.woff2 +0 -0
  706. package/dist/ui/client/assets/nunito-latin-600-normal-Cd0eNu1l.woff +0 -0
  707. package/dist/ui/client/assets/nunito-latin-700-normal-Dort48En.woff2 +0 -0
  708. package/dist/ui/client/assets/nunito-latin-700-normal-OcDqTBcA.woff +0 -0
  709. package/dist/ui/client/assets/nunito-latin-ext-300-normal-D1SyVuPt.woff2 +0 -0
  710. package/dist/ui/client/assets/nunito-latin-ext-300-normal-DfqbmdMl.woff +0 -0
  711. package/dist/ui/client/assets/nunito-latin-ext-400-normal-CjMJVfGn.woff +0 -0
  712. package/dist/ui/client/assets/nunito-latin-ext-400-normal-i-8OOpdj.woff2 +0 -0
  713. package/dist/ui/client/assets/nunito-latin-ext-600-normal-BKUpuB78.woff +0 -0
  714. package/dist/ui/client/assets/nunito-latin-ext-600-normal-Dd9Zuxh1.woff2 +0 -0
  715. package/dist/ui/client/assets/nunito-latin-ext-700-normal-BWeMsAzO.woff2 +0 -0
  716. package/dist/ui/client/assets/nunito-latin-ext-700-normal-D4woHhbd.woff +0 -0
  717. package/dist/ui/client/assets/nunito-vietnamese-300-normal-DATld5Vw.woff +0 -0
  718. package/dist/ui/client/assets/nunito-vietnamese-300-normal-mLneKULB.woff2 +0 -0
  719. package/dist/ui/client/assets/nunito-vietnamese-400-normal-BHkVbP3T.woff2 +0 -0
  720. package/dist/ui/client/assets/nunito-vietnamese-400-normal-DtOtW02z.woff +0 -0
  721. package/dist/ui/client/assets/nunito-vietnamese-600-normal-BY8O6Cug.woff2 +0 -0
  722. package/dist/ui/client/assets/nunito-vietnamese-600-normal-DO1RqFw5.woff +0 -0
  723. package/dist/ui/client/assets/nunito-vietnamese-700-normal-C9SQsXvj.woff +0 -0
  724. package/dist/ui/client/assets/nunito-vietnamese-700-normal-Ch8EUCfz.woff2 +0 -0
  725. package/dist/ui/client/index.html +0 -22
  726. package/dist/ui/server/assets/multipart-parser-BCMy8Xwv.js +0 -181
  727. package/dist/ui/server/assets/multipart-parser-BVY8pIV2.js +0 -176
  728. package/dist/ui/server/server.js +0 -155269
  729. /package/dist/{app/modules/identity/repositories/provider/account → adapters/http/controllers/entities/identity-provider-account}/index.d.ts +0 -0
  730. /package/dist/adapters/http/{ui → middleware/built-in}/types.mjs +0 -0
@@ -5,12 +5,29 @@ import { AuthupError } from '@authup/errors';
5
5
  * 1. AuthupError instance → returned as-is
6
6
  * 2. EntityRelationLookupError → BAD_REQUEST AuthupError
7
7
  * 3. validup Issue error → BAD_REQUEST AuthupError carrying issues
8
- * 4. foreign @ebec/http HTTPError → AuthupError with the closest semantic code
9
- * 5. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT
10
- * 6. anything else INTERNAL_ERROR AuthupError
8
+ * 4. rapiq ParseError / CodecError BAD_REQUEST AuthupError (client wire query)
9
+ * 5. hapic ClientError → UPSTREAM_ERROR AuthupError (outbound call)
10
+ * 6. foreign @ebec/http HTTPError AuthupError with the closest semantic code
11
+ * 7. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT
12
+ * 8. anything else → INTERNAL_ERROR AuthupError
11
13
  *
12
14
  * The HTTP-status concern is handled separately by `httpStatusFromCode` in
13
15
  * the adapter — this function only assigns a semantic `code`.
14
16
  */
15
17
  export declare function sanitizeError(input: unknown): AuthupError;
18
+ /**
19
+ * Render an error for the LOG. It is the counterpart of `@authup/errors`'
20
+ * `serializeError`, which renders one for the response.
21
+ *
22
+ * The detail an outbound failure carries never survives `sanitizeError`
23
+ * (by design: upstream internals must not reach the caller), and
24
+ * `Error.cause` is non-enumerable, so a plain serialization drops it too.
25
+ * Both were therefore already gone by the time anything was written,
26
+ * which left a refused connection and an upstream `invalid_request`
27
+ * indistinguishable in the log.
28
+ *
29
+ * Everything not present is omitted, so an ordinary error still renders
30
+ * as its bare message.
31
+ */
32
+ export declare function describeError(input: unknown, headline?: string): string;
16
33
  //# sourceMappingURL=error.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/utils/error.ts"],"names":[],"mappings":"AAOA,OAAO,EACH,WAAW,EAId,MAAM,gBAAgB,CAAC;AAMxB;;;;;;;;;;;;GAYG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,WAAW,CAoEzD"}
1
+ {"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/utils/error.ts"],"names":[],"mappings":"AAOA,OAAO,EACH,WAAW,EAKd,MAAM,gBAAgB,CAAC;AAQxB;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,WAAW,CAgGzD;AA0ED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CA8BvE"}
@@ -2,9 +2,11 @@ import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
4
  import { hasOwnProperty, isObject } from "@authup/kit";
5
- import { AuthupError, ErrorCode, codeFromHttpStatus, isAuthupError } from "@authup/errors";
5
+ import { AuthupError, ErrorCode, codeFromHttpStatus, isAuthupError, normalizeError } from "@authup/errors";
6
+ import { CodecError, ParseError } from "@rapiq/core";
6
7
  import { buildErrorMessageForAttributes, isValidupError, stringifyPath } from "validup";
7
8
  import { EntityRelationLookupError } from "typeorm-extension";
9
+ import { isClientError } from "hapic";
8
10
  import { isHTTPError } from "@ebec/http";
9
11
  //#region src/utils/error.ts
10
12
  /**
@@ -13,9 +15,11 @@ import { isHTTPError } from "@ebec/http";
13
15
  * 1. AuthupError instance → returned as-is
14
16
  * 2. EntityRelationLookupError → BAD_REQUEST AuthupError
15
17
  * 3. validup Issue error → BAD_REQUEST AuthupError carrying issues
16
- * 4. foreign @ebec/http HTTPError → AuthupError with the closest semantic code
17
- * 5. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT
18
- * 6. anything else INTERNAL_ERROR AuthupError
18
+ * 4. rapiq ParseError / CodecError BAD_REQUEST AuthupError (client wire query)
19
+ * 5. hapic ClientError → UPSTREAM_ERROR AuthupError (outbound call)
20
+ * 6. foreign @ebec/http HTTPError AuthupError with the closest semantic code
21
+ * 7. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT
22
+ * 8. anything else → INTERNAL_ERROR AuthupError
19
23
  *
20
24
  * The HTTP-status concern is handled separately by `httpStatusFromCode` in
21
25
  * the adapter — this function only assigns a semantic `code`.
@@ -36,6 +40,27 @@ import { isHTTPError } from "@ebec/http";
36
40
  error.issues.push(...input.issues);
37
41
  return error;
38
42
  }
43
+ if (input instanceof ParseError || input instanceof CodecError) return new AuthupError({
44
+ code: ErrorCode.BAD_REQUEST,
45
+ message: input.message,
46
+ stack: input.stack
47
+ });
48
+ /**
49
+ * An outbound call failed. This branch MUST precede the `isHTTPError`
50
+ * one below: a hapic `HttpResponseError` extends `BaseError` and carries
51
+ * the upstream `status`, so the duck guard matches it and would mirror
52
+ * that status onto our own response. An upstream 400 would then read as
53
+ * "your request was malformed" when the caller's request was fine.
54
+ *
55
+ * The message is deliberately dropped rather than forwarded: hapic
56
+ * embeds the outbound method and URL in it (`400 Bad Request (POST
57
+ * https://idp.example.com/token)`), which must not reach the caller.
58
+ * `describeError` is what carries the detail, into the log only.
59
+ */ if (isClientError(input)) return new AuthupError({
60
+ code: ErrorCode.UPSTREAM_ERROR,
61
+ message: "A request to an upstream service failed.",
62
+ stack: input.stack
63
+ });
39
64
  if (isHTTPError(input)) return new AuthupError({
40
65
  code: codeFromHttpStatus(input.status),
41
66
  message: input.message,
@@ -66,7 +91,79 @@ import { isHTTPError } from "@ebec/http";
66
91
  }
67
92
  return new AuthupError({ code: ErrorCode.INTERNAL_ERROR });
68
93
  }
94
+ const DESCRIBE_BODY_MAX_LENGTH = 1024;
95
+ const DESCRIBE_CAUSE_MAX_DEPTH = 5;
96
+ const DESCRIBE_CAUSE_KEYS = [
97
+ "code",
98
+ "errno",
99
+ "syscall",
100
+ "address",
101
+ "port"
102
+ ];
103
+ function describeBody(input) {
104
+ let value;
105
+ if (typeof input === "string") value = input;
106
+ else try {
107
+ value = JSON.stringify(input) ?? String(input);
108
+ } catch {
109
+ value = Object.prototype.toString.call(input);
110
+ }
111
+ if (value.length === 0) return;
112
+ if (value.length > DESCRIBE_BODY_MAX_LENGTH) return `${value.substring(0, DESCRIBE_BODY_MAX_LENGTH)}… (truncated)`;
113
+ return value;
114
+ }
115
+ function describeCauseLink(input) {
116
+ const error = input;
117
+ const parts = [`${typeof error.name === "string" ? error.name : "Error"}: ${error.message}`];
118
+ const details = [];
119
+ for (const key of DESCRIBE_CAUSE_KEYS) {
120
+ const value = input[key];
121
+ if (typeof value === "string" || typeof value === "number") details.push(`${key}=${value}`);
122
+ }
123
+ if (details.length > 0) parts.push(`(${details.join(" ")})`);
124
+ return parts.join(" ");
125
+ }
126
+ function describeCauseChain(input) {
127
+ const links = [];
128
+ const seen = /* @__PURE__ */ new Set();
129
+ let current = isObject(input) ? input.cause : void 0;
130
+ while (isObject(current) && !seen.has(current) && links.length < DESCRIBE_CAUSE_MAX_DEPTH) {
131
+ seen.add(current);
132
+ links.push(describeCauseLink(current));
133
+ current = current.cause;
134
+ }
135
+ if (links.length === 0) return;
136
+ return links.join(" <- ");
137
+ }
138
+ /**
139
+ * Render an error for the LOG. It is the counterpart of `@authup/errors`'
140
+ * `serializeError`, which renders one for the response.
141
+ *
142
+ * The detail an outbound failure carries never survives `sanitizeError`
143
+ * (by design: upstream internals must not reach the caller), and
144
+ * `Error.cause` is non-enumerable, so a plain serialization drops it too.
145
+ * Both were therefore already gone by the time anything was written,
146
+ * which left a refused connection and an upstream `invalid_request`
147
+ * indistinguishable in the log.
148
+ *
149
+ * Everything not present is omitted, so an ordinary error still renders
150
+ * as its bare message.
151
+ */ function describeError(input, headline) {
152
+ const error = normalizeError(input);
153
+ const lines = [];
154
+ if (headline) lines.push(headline);
155
+ lines.push(error.message);
156
+ if (isClientError(error) && error.response) {
157
+ lines.push(` upstream status: ${error.response.status}`);
158
+ const body = describeBody(error.response.data);
159
+ if (body) lines.push(` upstream body: ${body}`);
160
+ }
161
+ const causes = describeCauseChain(error);
162
+ if (causes) lines.push(` cause: ${causes}`);
163
+ if (error.stack) lines.push(` stack: ${error.stack}`);
164
+ return lines.join("\n");
165
+ }
69
166
  //#endregion
70
- export { sanitizeError };
167
+ export { describeError, sanitizeError };
71
168
 
72
169
  //# sourceMappingURL=error.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"error.mjs","names":["AuthupError","ErrorCode","codeFromHttpStatus","isAuthupError","isHTTPError","EntityRelationLookupError","buildErrorMessageForAttributes","isValidupError","stringifyPath","hasOwnProperty","isObject","sanitizeError","input","code","ENTITY_RELATION_INVALID","message","stack","paths","issues","map","issue","path","error","BAD_REQUEST","push","status","undefined","ENTITY_CONFLICT","STORAGE_INSUFFICIENT","INTERNAL_ERROR"],"sources":["../../src/utils/error.ts"],"sourcesContent":["/*\n * Copyright (c) 2024.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\nimport { \n AuthupError, \n ErrorCode, \n codeFromHttpStatus, \n isAuthupError, \n} from '@authup/errors';\nimport { isHTTPError } from '@ebec/http';\nimport { EntityRelationLookupError } from 'typeorm-extension';\nimport { buildErrorMessageForAttributes, isValidupError, stringifyPath } from 'validup';\nimport { hasOwnProperty, isObject } from '@authup/kit';\n\n/**\n * Normalize an unknown error to an AuthupError. Recognised shapes:\n *\n * 1. AuthupError instance → returned as-is\n * 2. EntityRelationLookupError → BAD_REQUEST AuthupError\n * 3. validup Issue error → BAD_REQUEST AuthupError carrying issues\n * 4. foreign @ebec/http HTTPError → AuthupError with the closest semantic code\n * 5. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT\n * 6. anything else → INTERNAL_ERROR AuthupError\n *\n * The HTTP-status concern is handled separately by `httpStatusFromCode` in\n * the adapter — this function only assigns a semantic `code`.\n */\nexport function sanitizeError(input: unknown): AuthupError {\n if (isAuthupError(input)) {\n return input;\n }\n\n if (input instanceof EntityRelationLookupError) {\n return new AuthupError({\n code: ErrorCode.ENTITY_RELATION_INVALID,\n message: input.message,\n stack: input.stack,\n });\n }\n\n if (isValidupError(input)) {\n const paths = input.issues.map((issue) => stringifyPath(issue.path));\n const error = new AuthupError({\n code: ErrorCode.BAD_REQUEST,\n stack: input.stack,\n message: input.message || buildErrorMessageForAttributes(paths),\n });\n\n error.issues.push(...input.issues);\n return error;\n }\n\n if (isHTTPError(input)) {\n return new AuthupError({\n code: codeFromHttpStatus(input.status),\n message: input.message,\n stack: input.stack,\n });\n }\n\n if (isObject(input)) {\n const code = hasOwnProperty(input, 'code') &&\n typeof input.code === 'string' ?\n input.code :\n undefined;\n\n /**\n * @see https://dev.mysql.com/doc/mysql-errors/8.0/en/server-error-reference.html\n */\n switch (code) {\n case '23505':\n case 'ER_DUP_ENTRY':\n case 'SQLITE_CONSTRAINT_UNIQUE': {\n return new AuthupError({\n code: ErrorCode.ENTITY_CONFLICT,\n message: 'An entry with some unique attributes already exists.',\n stack: input.stack as string | undefined,\n });\n }\n case 'ER_DISK_FULL':\n return new AuthupError({\n code: ErrorCode.STORAGE_INSUFFICIENT,\n message: 'No database operation possible, due to the lack of free disk space.',\n stack: input.stack as string | undefined,\n });\n }\n\n return new AuthupError({\n code: ErrorCode.INTERNAL_ERROR,\n message: input.message as string | undefined,\n stack: input.stack as string | undefined,\n });\n }\n\n return new AuthupError({ code: ErrorCode.INTERNAL_ERROR });\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;GA+BA,SAAgBW,cAAcC,OAAc;CACxC,IAAIT,cAAcS,KAAAA,GACd,OAAOA;CAGX,IAAIA,iBAAiBP,2BACjB,OAAO,IAAIL,YAAY;EACnBa,MAAMZ,UAAUa;EAChBC,SAASH,MAAMG;EACfC,OAAOJ,MAAMI;CACjB,CAAA;CAGJ,IAAIT,eAAeK,KAAAA,GAAQ;EACvB,MAAMK,QAAQL,MAAMM,OAAOC,KAAKC,UAAUZ,cAAcY,MAAMC,IAAI,CAAA;EAClE,MAAMC,QAAQ,IAAItB,YAAY;GAC1Ba,MAAMZ,UAAUsB;GAChBP,OAAOJ,MAAMI;GACbD,SAASH,MAAMG,WAAWT,+BAA+BW,KAAAA;EAC7D,CAAA;EAEAK,MAAMJ,OAAOM,KAAI,GAAIZ,MAAMM,MAAM;EACjC,OAAOI;CACX;CAEA,IAAIlB,YAAYQ,KAAAA,GACZ,OAAO,IAAIZ,YAAY;EACnBa,MAAMX,mBAAmBU,MAAMa,MAAM;EACrCV,SAASH,MAAMG;EACfC,OAAOJ,MAAMI;CACjB,CAAA;CAGJ,IAAIN,SAASE,KAAAA,GAAQ;;;KASjB,QARaH,eAAeG,OAAO,MAAA,KACnC,OAAOA,MAAMC,SAAS,WAClBD,MAAMC,OACNa,KAAAA,GAKJ;GACI,KAAK;GACL,KAAK;GACL,KAAK,4BACD,OAAO,IAAI1B,YAAY;IACnBa,MAAMZ,UAAU0B;IAChBZ,SAAS;IACTC,OAAOJ,MAAMI;GACjB,CAAA;GAEJ,KAAK,gBACD,OAAO,IAAIhB,YAAY;IACnBa,MAAMZ,UAAU2B;IAChBb,SAAS;IACTC,OAAOJ,MAAMI;GACjB,CAAA;EACR;EAEA,OAAO,IAAIhB,YAAY;GACnBa,MAAMZ,UAAU4B;GAChBd,SAASH,MAAMG;GACfC,OAAOJ,MAAMI;EACjB,CAAA;CACJ;CAEA,OAAO,IAAIhB,YAAY,EAAEa,MAAMZ,UAAU4B,eAAe,CAAA;AAC5D"}
1
+ {"version":3,"file":"error.mjs","names":["AuthupError","ErrorCode","codeFromHttpStatus","isAuthupError","normalizeError","isHTTPError","isClientError","CodecError","ParseError","EntityRelationLookupError","buildErrorMessageForAttributes","isValidupError","stringifyPath","hasOwnProperty","isObject","sanitizeError","input","code","ENTITY_RELATION_INVALID","message","stack","paths","issues","map","issue","path","error","BAD_REQUEST","push","UPSTREAM_ERROR","status","undefined","ENTITY_CONFLICT","STORAGE_INSUFFICIENT","INTERNAL_ERROR","DESCRIBE_BODY_MAX_LENGTH","DESCRIBE_CAUSE_MAX_DEPTH","DESCRIBE_CAUSE_KEYS","describeBody","value","JSON","stringify","String","Object","prototype","toString","call","length","substring","describeCauseLink","name","parts","details","key","join","describeCauseChain","links","seen","Set","current","cause","has","add","describeError","headline","lines","response","body","data","causes"],"sources":["../../src/utils/error.ts"],"sourcesContent":["/*\n * Copyright (c) 2024.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\nimport {\n AuthupError,\n ErrorCode,\n codeFromHttpStatus,\n isAuthupError,\n normalizeError,\n} from '@authup/errors';\nimport { isHTTPError } from '@ebec/http';\nimport { isClientError } from 'hapic';\nimport { CodecError, ParseError } from '@rapiq/core';\nimport { EntityRelationLookupError } from 'typeorm-extension';\nimport { buildErrorMessageForAttributes, isValidupError, stringifyPath } from 'validup';\nimport { hasOwnProperty, isObject } from '@authup/kit';\n\n/**\n * Normalize an unknown error to an AuthupError. Recognised shapes:\n *\n * 1. AuthupError instance → returned as-is\n * 2. EntityRelationLookupError → BAD_REQUEST AuthupError\n * 3. validup Issue error → BAD_REQUEST AuthupError carrying issues\n * 4. rapiq ParseError / CodecError → BAD_REQUEST AuthupError (client wire query)\n * 5. hapic ClientError → UPSTREAM_ERROR AuthupError (outbound call)\n * 6. foreign @ebec/http HTTPError → AuthupError with the closest semantic code\n * 7. driver error w/ a recognised code → ENTITY_CONFLICT or STORAGE_INSUFFICIENT\n * 8. anything else → INTERNAL_ERROR AuthupError\n *\n * The HTTP-status concern is handled separately by `httpStatusFromCode` in\n * the adapter — this function only assigns a semantic `code`.\n */\nexport function sanitizeError(input: unknown): AuthupError {\n if (isAuthupError(input)) {\n return input;\n }\n\n if (input instanceof EntityRelationLookupError) {\n return new AuthupError({\n code: ErrorCode.ENTITY_RELATION_INVALID,\n message: input.message,\n stack: input.stack,\n });\n }\n\n if (isValidupError(input)) {\n const paths = input.issues.map((issue) => stringifyPath(issue.path));\n const error = new AuthupError({\n code: ErrorCode.BAD_REQUEST,\n stack: input.stack,\n message: input.message || buildErrorMessageForAttributes(paths),\n });\n\n error.issues.push(...input.issues);\n return error;\n }\n\n if (input instanceof ParseError || input instanceof CodecError) {\n return new AuthupError({\n code: ErrorCode.BAD_REQUEST,\n message: input.message,\n stack: input.stack,\n });\n }\n\n /**\n * An outbound call failed. This branch MUST precede the `isHTTPError`\n * one below: a hapic `HttpResponseError` extends `BaseError` and carries\n * the upstream `status`, so the duck guard matches it and would mirror\n * that status onto our own response. An upstream 400 would then read as\n * \"your request was malformed\" when the caller's request was fine.\n *\n * The message is deliberately dropped rather than forwarded: hapic\n * embeds the outbound method and URL in it (`400 Bad Request (POST\n * https://idp.example.com/token)`), which must not reach the caller.\n * `describeError` is what carries the detail, into the log only.\n */\n if (isClientError(input)) {\n return new AuthupError({\n code: ErrorCode.UPSTREAM_ERROR,\n message: 'A request to an upstream service failed.',\n stack: input.stack,\n });\n }\n\n if (isHTTPError(input)) {\n return new AuthupError({\n code: codeFromHttpStatus(input.status),\n message: input.message,\n stack: input.stack,\n });\n }\n\n if (isObject(input)) {\n const code = hasOwnProperty(input, 'code') &&\n typeof input.code === 'string' ?\n input.code :\n undefined;\n\n /**\n * @see https://dev.mysql.com/doc/mysql-errors/8.0/en/server-error-reference.html\n */\n switch (code) {\n case '23505':\n case 'ER_DUP_ENTRY':\n case 'SQLITE_CONSTRAINT_UNIQUE': {\n return new AuthupError({\n code: ErrorCode.ENTITY_CONFLICT,\n message: 'An entry with some unique attributes already exists.',\n stack: input.stack as string | undefined,\n });\n }\n case 'ER_DISK_FULL':\n return new AuthupError({\n code: ErrorCode.STORAGE_INSUFFICIENT,\n message: 'No database operation possible, due to the lack of free disk space.',\n stack: input.stack as string | undefined,\n });\n }\n\n return new AuthupError({\n code: ErrorCode.INTERNAL_ERROR,\n message: input.message as string | undefined,\n stack: input.stack as string | undefined,\n });\n }\n\n return new AuthupError({ code: ErrorCode.INTERNAL_ERROR });\n}\n\nconst DESCRIBE_BODY_MAX_LENGTH = 1024;\nconst DESCRIBE_CAUSE_MAX_DEPTH = 5;\n\n// Fields node attaches to a syscall error. Without them a transport failure\n// reads as a bare \"connect ECONNREFUSED\" with no way back to the reason.\nconst DESCRIBE_CAUSE_KEYS = ['code', 'errno', 'syscall', 'address', 'port'] as const;\n\nfunction describeBody(input: unknown): string | undefined {\n let value: string;\n\n if (typeof input === 'string') {\n value = input;\n } else {\n try {\n value = JSON.stringify(input) ?? String(input);\n } catch {\n // A body that cannot be serialized (circular, a stream) is\n // still worth naming by shape.\n value = Object.prototype.toString.call(input);\n }\n }\n\n if (value.length === 0) {\n return undefined;\n }\n\n if (value.length > DESCRIBE_BODY_MAX_LENGTH) {\n return `${value.substring(0, DESCRIBE_BODY_MAX_LENGTH)}… (truncated)`;\n }\n\n return value;\n}\n\nfunction describeCauseLink(input: object): string {\n const error = input as Error;\n const name = typeof error.name === 'string' ? error.name : 'Error';\n const parts: string[] = [`${name}: ${error.message}`];\n\n const details: string[] = [];\n for (const key of DESCRIBE_CAUSE_KEYS) {\n const value = (input as Record<string, unknown>)[key];\n if (typeof value === 'string' || typeof value === 'number') {\n details.push(`${key}=${value}`);\n }\n }\n\n if (details.length > 0) {\n parts.push(`(${details.join(' ')})`);\n }\n\n return parts.join(' ');\n}\n\nfunction describeCauseChain(input: unknown): string | undefined {\n const links: string[] = [];\n const seen = new Set<unknown>();\n\n let current: unknown = isObject(input) ? (input as { cause?: unknown }).cause : undefined;\n\n while (isObject(current) && !seen.has(current) && links.length < DESCRIBE_CAUSE_MAX_DEPTH) {\n seen.add(current);\n links.push(describeCauseLink(current));\n current = (current as { cause?: unknown }).cause;\n }\n\n if (links.length === 0) {\n return undefined;\n }\n\n return links.join(' <- ');\n}\n\n/**\n * Render an error for the LOG. It is the counterpart of `@authup/errors`'\n * `serializeError`, which renders one for the response.\n *\n * The detail an outbound failure carries never survives `sanitizeError`\n * (by design: upstream internals must not reach the caller), and\n * `Error.cause` is non-enumerable, so a plain serialization drops it too.\n * Both were therefore already gone by the time anything was written,\n * which left a refused connection and an upstream `invalid_request`\n * indistinguishable in the log.\n *\n * Everything not present is omitted, so an ordinary error still renders\n * as its bare message.\n */\nexport function describeError(input: unknown, headline?: string): string {\n const error = normalizeError(input);\n\n const lines: string[] = [];\n if (headline) {\n lines.push(headline);\n }\n lines.push(error.message);\n\n // hapic attaches the decoded body to the response through a getter, so\n // it is non-enumerable and only reachable by an explicit read.\n if (isClientError(error) && error.response) {\n lines.push(` upstream status: ${error.response.status}`);\n\n const body = describeBody(error.response.data);\n if (body) {\n lines.push(` upstream body: ${body}`);\n }\n }\n\n const causes = describeCauseChain(error);\n if (causes) {\n lines.push(` cause: ${causes}`);\n }\n\n if (error.stack) {\n lines.push(` stack: ${error.stack}`);\n }\n\n return lines.join('\\n');\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;GAoCA,SAAgBe,cAAcC,OAAc;CACxC,IAAIb,cAAca,KAAAA,GACd,OAAOA;CAGX,IAAIA,iBAAiBP,2BACjB,OAAO,IAAIT,YAAY;EACnBiB,MAAMhB,UAAUiB;EAChBC,SAASH,MAAMG;EACfC,OAAOJ,MAAMI;CACjB,CAAA;CAGJ,IAAIT,eAAeK,KAAAA,GAAQ;EACvB,MAAMK,QAAQL,MAAMM,OAAOC,KAAKC,UAAUZ,cAAcY,MAAMC,IAAI,CAAA;EAClE,MAAMC,QAAQ,IAAI1B,YAAY;GAC1BiB,MAAMhB,UAAU0B;GAChBP,OAAOJ,MAAMI;GACbD,SAASH,MAAMG,WAAWT,+BAA+BW,KAAAA;EAC7D,CAAA;EAEAK,MAAMJ,OAAOM,KAAI,GAAIZ,MAAMM,MAAM;EACjC,OAAOI;CACX;CAEA,IAAIV,iBAAiBR,cAAcQ,iBAAiBT,YAChD,OAAO,IAAIP,YAAY;EACnBiB,MAAMhB,UAAU0B;EAChBR,SAASH,MAAMG;EACfC,OAAOJ,MAAMI;CACjB,CAAA;;;;;;;;;;;;IAeJ,IAAId,cAAcU,KAAAA,GACd,OAAO,IAAIhB,YAAY;EACnBiB,MAAMhB,UAAU4B;EAChBV,SAAS;EACTC,OAAOJ,MAAMI;CACjB,CAAA;CAGJ,IAAIf,YAAYW,KAAAA,GACZ,OAAO,IAAIhB,YAAY;EACnBiB,MAAMf,mBAAmBc,MAAMc,MAAM;EACrCX,SAASH,MAAMG;EACfC,OAAOJ,MAAMI;CACjB,CAAA;CAGJ,IAAIN,SAASE,KAAAA,GAAQ;;;KASjB,QARaH,eAAeG,OAAO,MAAA,KACnC,OAAOA,MAAMC,SAAS,WAClBD,MAAMC,OACNc,KAAAA,GAKJ;GACI,KAAK;GACL,KAAK;GACL,KAAK,4BACD,OAAO,IAAI/B,YAAY;IACnBiB,MAAMhB,UAAU+B;IAChBb,SAAS;IACTC,OAAOJ,MAAMI;GACjB,CAAA;GAEJ,KAAK,gBACD,OAAO,IAAIpB,YAAY;IACnBiB,MAAMhB,UAAUgC;IAChBd,SAAS;IACTC,OAAOJ,MAAMI;GACjB,CAAA;EACR;EAEA,OAAO,IAAIpB,YAAY;GACnBiB,MAAMhB,UAAUiC;GAChBf,SAASH,MAAMG;GACfC,OAAOJ,MAAMI;EACjB,CAAA;CACJ;CAEA,OAAO,IAAIpB,YAAY,EAAEiB,MAAMhB,UAAUiC,eAAe,CAAA;AAC5D;AAEA,MAAMC,2BAA2B;AACjC,MAAMC,2BAA2B;AAIjC,MAAMC,sBAAsB;CAAC;CAAQ;CAAS;CAAW;CAAW;AAAO;AAE3E,SAASC,aAAatB,OAAc;CAChC,IAAIuB;CAEJ,IAAI,OAAOvB,UAAU,UACjBuB,QAAQvB;MAER,IAAI;EACAuB,QAAQC,KAAKC,UAAUzB,KAAAA,KAAU0B,OAAO1B,KAAAA;CAC5C,QAAQ;EAGJuB,QAAQI,OAAOC,UAAUC,SAASC,KAAK9B,KAAAA;CAC3C;CAGJ,IAAIuB,MAAMQ,WAAW,GACjB;CAGJ,IAAIR,MAAMQ,SAASZ,0BACf,OAAO,GAAGI,MAAMS,UAAU,GAAGb,wBAAAA,EAA0B;CAG3D,OAAOI;AACX;AAEA,SAASU,kBAAkBjC,OAAa;CACpC,MAAMU,QAAQV;CAEd,MAAMmC,QAAkB,CAAC,GADZ,OAAOzB,MAAMwB,SAAS,WAAWxB,MAAMwB,OAAO,QAC1B,IAAIxB,MAAMP,SAAU;CAErD,MAAMiC,UAAoB,CAAA;CAC1B,KAAK,MAAMC,OAAOhB,qBAAqB;EACnC,MAAME,QAAQ,MAAmCc;EACjD,IAAI,OAAOd,UAAU,YAAY,OAAOA,UAAU,UAC9Ca,QAAQxB,KAAK,GAAGyB,IAAI,GAAGd,OAAO;CAEtC;CAEA,IAAIa,QAAQL,SAAS,GACjBI,MAAMvB,KAAK,IAAIwB,QAAQE,KAAK,GAAA,EAAK,EAAE;CAGvC,OAAOH,MAAMG,KAAK,GAAA;AACtB;AAEA,SAASC,mBAAmBvC,OAAc;CACtC,MAAMwC,QAAkB,CAAA;CACxB,MAAMC,uBAAO,IAAIC,IAAAA;CAEjB,IAAIC,UAAmB7C,SAASE,KAAAA,IAAS,MAA+B4C,QAAQ7B,KAAAA;CAEhF,OAAOjB,SAAS6C,OAAAA,KAAY,CAACF,KAAKI,IAAIF,OAAAA,KAAYH,MAAMT,SAASX,0BAA0B;EACvFqB,KAAKK,IAAIH,OAAAA;EACTH,MAAM5B,KAAKqB,kBAAkBU,OAAAA,CAAAA;EAC7BA,UAAU,QAAiCC;CAC/C;CAEA,IAAIJ,MAAMT,WAAW,GACjB;CAGJ,OAAOS,MAAMF,KAAK,MAAA;AACtB;;;;;;;;;;;;;;GAgBA,SAAgBS,cAAc/C,OAAgBgD,UAAiB;CAC3D,MAAMtC,QAAQtB,eAAeY,KAAAA;CAE7B,MAAMiD,QAAkB,CAAA;CACxB,IAAID,UACAC,MAAMrC,KAAKoC,QAAAA;CAEfC,MAAMrC,KAAKF,MAAMP,OAAO;CAIxB,IAAIb,cAAcoB,KAAAA,KAAUA,MAAMwC,UAAU;EACxCD,MAAMrC,KAAK,sBAAsBF,MAAMwC,SAASpC,QAAQ;EAExD,MAAMqC,OAAO7B,aAAaZ,MAAMwC,SAASE,IAAI;EAC7C,IAAID,MACAF,MAAMrC,KAAK,sBAAsBuC,MAAM;CAE/C;CAEA,MAAME,SAASd,mBAAmB7B,KAAAA;CAClC,IAAI2C,QACAJ,MAAMrC,KAAK,sBAAsByC,QAAQ;CAG7C,IAAI3C,MAAMN,OACN6C,MAAMrC,KAAK,sBAAsBF,MAAMN,OAAO;CAGlD,OAAO6C,MAAMX,KAAK,IAAA;AACtB"}
@@ -1,7 +1,7 @@
1
1
  import "node:path";
2
2
  import "node:url";
3
3
  import.meta.url;
4
- import { sanitizeError } from "./error.mjs";
4
+ import { describeError, sanitizeError } from "./error.mjs";
5
5
  import { isSelfToken } from "./self-id.mjs";
6
6
  import { resolveURL } from "./url.mjs";
7
- export { isSelfToken, resolveURL, sanitizeError };
7
+ export { describeError, isSelfToken, resolveURL, sanitizeError };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@authup/server-core",
3
3
  "type": "module",
4
- "version": "1.0.0-beta.58",
4
+ "version": "1.0.0-beta.60",
5
5
  "description": "This is a standalone application.",
6
6
  "license": "AGPL-3.0-only",
7
7
  "main": "dist/index.mjs",
@@ -15,18 +15,17 @@
15
15
  "cli-dev": "npm run build:server && npm run cli",
16
16
  "cli-dev-src": "nodemon --watch src --exec \"npm run build:server && node dist/cli/index.mjs\"",
17
17
  "cli-dev-dist": "nodemon --watch dist --exec \"node dist/cli/index.mjs\"",
18
- "build:ui:client": "vite build --config ui/vite.config.ts --ssrManifest .vite/ssr-manifest.json --outDir ../dist/ui/client ui",
19
- "build:ui:server": "vite build --config ui/vite.config.ts --ssr src/server.ts --outDir ../dist/ui/server ui",
20
- "build:ui": "npm run build:ui:server && npm run build:ui:client",
21
18
  "build:server:types": "tsc --emitDeclarationOnly -p tsconfig.build.json",
22
19
  "build:server:js": "tsdown",
23
20
  "build:server": "npm run build:server:js && npm run build:server:types && npm run build:swagger",
24
21
  "build:swagger": "trapi generate",
25
- "build": "rimraf ./dist && npm run build:server && npm run build:ui",
22
+ "build": "rimraf ./dist && npm run build:server",
26
23
  "test": "cross-env NODE_ENV=test vitest run --config test/vitest.config.ts",
27
24
  "test:mysql": "cross-env DB_TYPE=mysql DB_HOST=127.0.0.1 DB_USERNAME=root DB_PASSWORD=start123 DB_DATABASE=app vitest run --config test/vitest.config.ts",
28
25
  "test:psql": "cross-env DB_TYPE=postgres DB_HOST=127.0.0.1 DB_USERNAME=postgres DB_PASSWORD=start123 DB_DATABASE=app vitest run --config test/vitest.config.ts",
29
26
  "test:coverage": "cross-env NODE_ENV=test vitest run --config test/vitest.config.ts --coverage",
27
+ "test:schema-drift": "node scripts/assert-schema-drift.mjs",
28
+ "test:migration-latest": "node scripts/verify-latest-migration.mjs",
30
29
  "check:types": "tsc -p tsconfig.test.json"
31
30
  },
32
31
  "engines": {
@@ -68,22 +67,24 @@
68
67
  },
69
68
  "homepage": "https://github.com/authup/authup#readme",
70
69
  "dependencies": {
71
- "@authup/access": "^1.0.0-beta.58",
72
- "@authup/core-http-kit": "^1.0.0-beta.58",
73
- "@authup/core-kit": "^1.0.0-beta.58",
74
- "@authup/errors": "^1.0.0-beta.58",
75
- "@authup/i18n": "^1.0.0-beta.58",
76
- "@authup/kit": "^1.0.0-beta.58",
77
- "@authup/server-kit": "^1.0.0-beta.58",
78
- "@authup/specs": "^1.0.0-beta.58",
70
+ "@authup/access": "^1.0.0-beta.60",
71
+ "@authup/client-account-console": "^1.0.0-beta.60",
72
+ "@authup/client-auth-console": "^1.0.0-beta.60",
73
+ "@authup/core-http-kit": "^1.0.0-beta.60",
74
+ "@authup/core-kit": "^1.0.0-beta.60",
75
+ "@authup/errors": "^1.0.0-beta.60",
76
+ "@authup/i18n": "^1.0.0-beta.60",
77
+ "@authup/kit": "^1.0.0-beta.60",
78
+ "@authup/server-kit": "^1.0.0-beta.60",
79
+ "@authup/specs": "^1.0.0-beta.60",
79
80
  "@ebec/http": "^4.2.0",
80
81
  "@hapic/oauth2": "^4.0.1",
81
82
  "@peculiar/x509": "^2.0.0",
82
- "@rapiq/adapter-memory": "^2.0.0-beta.13",
83
- "@rapiq/adapter-sql": "^2.0.0-beta.13",
84
- "@rapiq/adapter-typeorm": "^2.0.0-beta.13",
85
- "@rapiq/codec-url": "^2.0.0-beta.13",
86
- "@rapiq/core": "^2.0.0-beta.13",
83
+ "@rapiq/adapter-memory": "^2.1.0",
84
+ "@rapiq/adapter-sql": "^2.1.0",
85
+ "@rapiq/adapter-typeorm": "^2.1.0",
86
+ "@rapiq/codec-url": "^2.1.0",
87
+ "@rapiq/core": "^2.1.0",
87
88
  "@routup/assets": "^5.0.0",
88
89
  "@routup/basic": "^3.0.0",
89
90
  "@routup/cors": "^2.0.0",
@@ -108,7 +109,7 @@
108
109
  "locter": "^4.0.0",
109
110
  "mysql2": "^3.23.2",
110
111
  "node-cron": "^4.6.0",
111
- "nodemailer": "^9.0.3",
112
+ "nodemailer": "^9.0.4",
112
113
  "orkos": "^1.1.1",
113
114
  "otpauth": "^9.5.1",
114
115
  "pg": "^8.22.0",
@@ -119,64 +120,27 @@
119
120
  "smob": "^1.6.1",
120
121
  "tsyringe": "^4.10.0",
121
122
  "typeorm": "1.1.0",
122
- "typeorm-extension": "^4.0.0-beta.1",
123
+ "typeorm-extension": "^4.0.0-beta.3",
123
124
  "uncrypto": "^0.1.3",
124
125
  "validup": "^1.0.0",
125
126
  "zod": "^4.4.3"
126
127
  },
127
128
  "devDependencies": {
128
- "@authup/client-web-kit": "^1.0.0-beta.58",
129
- "@authup/client-web-kit-theme": "^1.0.0-beta.58",
130
- "@authup/client-web-theme": "^1.0.0-beta.58",
131
- "@authup/server-test-kit": "^1.0.0-beta.58",
129
+ "@authup/server-test-kit": "^1.0.0-beta.60",
132
130
  "@faker-js/faker": "^10.5.0",
133
- "@fontsource/asap": "^5.3.0",
134
- "@fontsource/nunito": "^5.3.0",
135
- "@iconify-json/fa6-brands": "^1.2.0",
136
- "@iconify-json/fa6-solid": "^1.2.0",
137
- "@iconify/vue": "^5.0.0",
138
- "@ilingo/validup": "^1.1.0",
139
- "@ilingo/validup-vue": "^1.1.0",
140
- "@ilingo/vue": "^6.1.0",
141
- "@nuxt/icon": "^2.4.1",
142
- "@tailwindcss/vite": "^4.3.3",
143
131
  "@trapi/cli": "^2.0.4",
144
132
  "@types/ldapjs": "^3.0.6",
145
133
  "@types/nodemailer": "^8.0.0",
146
134
  "@types/qrcode": "^1.5.6",
147
135
  "@types/supertest": "^7.2.1",
148
- "@validup/vue": "^1.0.0",
149
- "@vitejs/plugin-vue": "^6.0.8",
150
- "@vuecs/button": "^1.4.0",
151
- "@vuecs/core": "^3.5.0",
152
- "@vuecs/countdown": "^2.1.0",
153
- "@vuecs/design": "^1.1.0",
154
- "@vuecs/elements": "^1.5.0",
155
- "@vuecs/forms": "^5.4.0",
156
- "@vuecs/icon": "^1.1.0",
157
- "@vuecs/icons-font-awesome": "^1.3.0",
158
- "@vuecs/link": "^2.1.0",
159
- "@vuecs/list": "^1.2.0",
160
- "@vuecs/locale": "^1.1.0",
161
- "@vuecs/navigation": "^4.4.0",
162
- "@vuecs/overlays": "^1.3.0",
163
- "@vuecs/pagination": "^2.2.0",
164
- "@vuecs/placeholder": "^1.1.0",
165
- "@vuecs/table": "^1.6.0",
166
- "@vuecs/theme-tailwind": "^6.4.0",
167
- "@vuecs/timeago": "^2.2.0",
168
136
  "jest-serial-runner": "^1.2.1",
169
137
  "nodemon": "^3.1.14",
170
- "pinia": "^3.0.0",
171
138
  "supertest": "^7.2.2",
172
- "tailwindcss": "^4.3.1",
173
- "testcontainers": "^12.0.4",
139
+ "testcontainers": "^12.1.0",
174
140
  "ts-node": "^10.8.2",
175
- "unplugin-swc": "^1.5.9",
141
+ "unplugin-swc": "^1.5.10",
176
142
  "vite": "^8.1.3",
177
- "vitest": "^4.0.14",
178
- "vue": "^3.5.40",
179
- "vue-router": "^5.0.7"
143
+ "vitest": "^4.0.14"
180
144
  },
181
145
  "publishConfig": {
182
146
  "access": "public"
@@ -1,9 +0,0 @@
1
- /**
2
- * Rewrite root-absolute /public/ asset references (script/link/preload tags
3
- * emitted with the fixed vite base) so they carry the path prefix under which
4
- * authup is publicly served (e.g. /auth/public/...). The reverse proxy is
5
- * expected to strip the prefix before the request reaches authup, so the
6
- * assets middleware keeps serving at /public.
7
- */
8
- export declare function rebasePublicAssetURLs(html: string, basePath: string): string;
9
- //# sourceMappingURL=base-path.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base-path.d.ts","sourceRoot":"","sources":["../../../../src/adapters/http/ui/base-path.ts"],"names":[],"mappings":"AAOA;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAI,MAAM,CAM7E"}
@@ -1,18 +0,0 @@
1
- import "node:path";
2
- import "node:url";
3
- import.meta.url;
4
- //#region src/adapters/http/ui/base-path.ts
5
- /**
6
- * Rewrite root-absolute /public/ asset references (script/link/preload tags
7
- * emitted with the fixed vite base) so they carry the path prefix under which
8
- * authup is publicly served (e.g. /auth/public/...). The reverse proxy is
9
- * expected to strip the prefix before the request reaches authup, so the
10
- * assets middleware keeps serving at /public.
11
- */ function rebasePublicAssetURLs(html, basePath) {
12
- if (!basePath) return html;
13
- return html.replace(/(src|href)="\/public\//g, `$1="${basePath}/public/`);
14
- }
15
- //#endregion
16
- export { rebasePublicAssetURLs };
17
-
18
- //# sourceMappingURL=base-path.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base-path.mjs","names":["rebasePublicAssetURLs","html","basePath","replace"],"sources":["../../../../src/adapters/http/ui/base-path.ts"],"sourcesContent":["/*\n * Copyright (c) 2026.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\n/**\n * Rewrite root-absolute /public/ asset references (script/link/preload tags\n * emitted with the fixed vite base) so they carry the path prefix under which\n * authup is publicly served (e.g. /auth/public/...). The reverse proxy is\n * expected to strip the prefix before the request reaches authup, so the\n * assets middleware keeps serving at /public.\n */\nexport function rebasePublicAssetURLs(html: string, basePath: string) : string {\n if (!basePath) {\n return html;\n }\n\n return html.replace(/(src|href)=\"\\/public\\//g, `$1=\"${basePath}/public/`);\n}\n"],"mappings":";;;;;;;;;;GAcA,SAAgBA,sBAAsBC,MAAcC,UAAgB;CAChE,IAAI,CAACA,UACD,OAAOD;CAGX,OAAOA,KAAKE,QAAQ,2BAA2B,OAAOD,SAAS,SAAS;AAC5E"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"internal-http-client.d.ts","sourceRoot":"","sources":["../../../../src/adapters/http/ui/internal-http-client.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAErD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,YAAY,CAAC;AAE9D;;;;GAIG;AACH,wBAAgB,iCAAiC,CAC7C,SAAS,EAAE,MAAM,EACjB,WAAW,EAAE,MAAM,GACnB,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAmC1B;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CAAC,GAAG,EAAE,2BAA2B,GAAI,OAAO,CAOrF"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"internal-http-client.mjs","names":["Client","FetchTransport","fetch","createPublicToInternalURLRewriter","publicURL","internalURL","publicParsed","URL","internalParsed","hostname","basePath","pathname","replace","url","parsed","origin","startsWith","substring","length","search","href","createInternalUIHttpClient","ctx","rewriteURL","baseURL","transport","input","init"],"sources":["../../../../src/adapters/http/ui/internal-http-client.ts"],"sourcesContent":["/*\n * Copyright (c) 2026.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\nimport { Client } from '@authup/core-http-kit';\nimport type { IClient } from '@authup/core-http-kit';\nimport { FetchTransport, fetch } from 'hapic';\nimport type { InternalUIHttpClientContext } from './types.ts';\n\n/**\n * Build a rewriter that maps URLs under the public base URL\n * (scheme://host[/prefix]) onto the server's own listen address. URLs\n * outside the public origin/prefix pass through untouched.\n */\nexport function createPublicToInternalURLRewriter(\n publicURL: string,\n internalURL: string,\n) : (url: string) => string {\n const publicParsed = new URL(publicURL);\n const internalParsed = new URL(internalURL);\n // a wildcard listen address (0.0.0.0 / [::]) is not reliably dialable —\n // loop back explicitly\n if (internalParsed.hostname === '0.0.0.0' || internalParsed.hostname === '[::]') {\n internalParsed.hostname = '127.0.0.1';\n }\n const basePath = publicParsed.pathname.replace(/\\/+$/, '');\n\n return (url: string) => {\n let parsed : URL;\n try {\n parsed = new URL(url);\n } catch {\n return url;\n }\n\n if (parsed.origin !== publicParsed.origin) {\n return url;\n }\n\n let { pathname } = parsed;\n if (basePath) {\n if (pathname === basePath) {\n pathname = '/';\n } else if (pathname.startsWith(`${basePath}/`)) {\n pathname = pathname.substring(basePath.length);\n } else {\n return url;\n }\n }\n\n return new URL(pathname + parsed.search, internalParsed.origin).href;\n };\n}\n\n/**\n * HTTP client for the SSR'd UI pages: the render's API calls target the\n * server itself, so they are dispatched against its own listen address —\n * no reverse-proxy round-trip, no TLS (a self-signed publicUrl certificate\n * would otherwise fail Node's fetch), no dependency on the public hostname\n * resolving from inside the deployment.\n *\n * The rewrite happens at the TRANSPORT layer only: `baseURL` must stay the\n * public URL because the rendered HTML derives user-facing URLs from it\n * (e.g. the identity-provider authorize hrefs via `getAuthorizeUri`), and\n * hydration does not patch attribute mismatches.\n */\nexport function createInternalUIHttpClient(ctx: InternalUIHttpClientContext) : IClient {\n const rewriteURL = createPublicToInternalURLRewriter(ctx.publicURL, ctx.internalURL);\n\n return new Client({\n baseURL: ctx.publicURL,\n transport: new FetchTransport({ fetch: (input, init) => fetch(rewriteURL(input), init) }),\n });\n}\n"],"mappings":";;;;;;;;;;GAiBA,SAAgBG,kCACZC,WACAC,aAAmB;CAEnB,MAAMC,eAAe,IAAIC,IAAIH,SAAAA;CAC7B,MAAMI,iBAAiB,IAAID,IAAIF,WAAAA;CAG/B,IAAIG,eAAeC,aAAa,aAAaD,eAAeC,aAAa,QACrED,eAAeC,WAAW;CAE9B,MAAMC,WAAWJ,aAAaK,SAASC,QAAQ,QAAQ,EAAA;CAEvD,QAAQC,QAAAA;EACJ,IAAIC;EACJ,IAAI;GACAA,SAAS,IAAIP,IAAIM,GAAAA;EACrB,QAAQ;GACJ,OAAOA;EACX;EAEA,IAAIC,OAAOC,WAAWT,aAAaS,QAC/B,OAAOF;EAGX,IAAI,EAAEF,aAAaG;EACnB,IAAIJ,UACA,IAAIC,aAAaD,UACbC,WAAW;OACR,IAAIA,SAASK,WAAW,GAAGN,SAAS,EAAE,GACzCC,WAAWA,SAASM,UAAUP,SAASQ,MAAM;OAE7C,OAAOL;EAIf,OAAO,IAAIN,IAAII,WAAWG,OAAOK,QAAQX,eAAeO,MAAM,CAAA,CAAEK;CACpE;AACJ;;;;;;;;;;;;GAcA,SAAgBC,2BAA2BC,KAAgC;CACvE,MAAMC,aAAapB,kCAAkCmB,IAAIlB,WAAWkB,IAAIjB,WAAW;CAEnF,OAAO,IAAIL,OAAO;EACdwB,SAASF,IAAIlB;EACbqB,WAAW,IAAIxB,eAAe,EAAEC,QAAQwB,OAAOC,SAASzB,MAAMqB,WAAWG,KAAAA,GAAQC,IAAAA,EAAM,CAAA;CAC3F,CAAA;AACJ"}
@@ -1,4 +0,0 @@
1
- import type { IAppEvent } from 'routup';
2
- import type { UIRenderContext } from './types.ts';
3
- export declare function renderUIPage(event: IAppEvent, ctx: UIRenderContext): Promise<string>;
4
- //# sourceMappingURL=render.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../../../../src/adapters/http/ui/render.ts"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AAQxC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAYlD,wBAAsB,YAAY,CAAC,KAAK,EAAE,SAAS,EAAE,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC,MAAM,CAAC,CAqF1F"}
@@ -1,63 +0,0 @@
1
- import "node:path";
2
- import "node:url";
3
- import.meta.url;
4
- import { LOCALE_COOKIE } from "../request/helpers/locale.mjs";
5
- import { rebasePublicAssetURLs } from "./base-path.mjs";
6
- import { UI_DIST_PATH, UI_SOURCE_PATH } from "../../../path.mjs";
7
- import { VITE_SERVER_STORE_KEY } from "../middleware/built-in/assets.mjs";
8
- import { UI_HTTP_CLIENT_FACTORY_STORE_KEY } from "../middleware/built-in/ui-http-client.mjs";
9
- import "../middleware/index.mjs";
10
- import { getURLBasePath } from "@authup/kit";
11
- import path from "node:path";
12
- import { useRequestCookie } from "@routup/basic/cookie";
13
- import { CodeTransformation, isCodeTransformation } from "typeorm-extension";
14
- import { read } from "locter";
15
- import fs from "node:fs";
16
- //#region src/adapters/http/ui/render.ts
17
- const COLOR_MODE_COOKIE = "vc-color-mode";
18
- let cachedHtml;
19
- let cachedManifest;
20
- let cachedRender;
21
- async function renderUIPage(event, ctx) {
22
- const isJIT = isCodeTransformation(CodeTransformation.JUST_IN_TIME);
23
- const colorMode = useRequestCookie(event, COLOR_MODE_COOKIE);
24
- ctx.payload.config.colorMode = colorMode;
25
- const locale = useRequestCookie(event, LOCALE_COOKIE);
26
- ctx.payload.config.locale = locale;
27
- let html;
28
- let manifest;
29
- let render;
30
- if (isJIT) {
31
- const vite = event.store[VITE_SERVER_STORE_KEY];
32
- html = await fs.promises.readFile(path.join(UI_SOURCE_PATH, "index.html"), "utf-8");
33
- html = await vite.transformIndexHtml("/", html);
34
- manifest = {};
35
- render = (await vite.ssrLoadModule("/src/server.ts")).render;
36
- } else {
37
- html = cachedHtml ??= await fs.promises.readFile(path.join(UI_DIST_PATH, "client", "index.html"), "utf-8");
38
- manifest = cachedManifest ??= JSON.parse(await fs.promises.readFile(path.join(UI_DIST_PATH, "client", ".vite", "ssr-manifest.json"), "utf-8"));
39
- render = cachedRender ??= (await read(path.join(UI_DIST_PATH, "server", "server.js"))).render;
40
- }
41
- const httpClientFactory = event.store[UI_HTTP_CLIENT_FACTORY_STORE_KEY];
42
- const [appHtml, preloadLinks] = await render({
43
- url: ctx.url,
44
- manifest,
45
- payload: ctx.payload,
46
- httpClient: httpClientFactory ? httpClientFactory() : void 0
47
- });
48
- let body = html.replace("<!--preload-links-->", preloadLinks).replace("<!--app-html-->", appHtml);
49
- let htmlAttrs = "lang=\"en\"";
50
- if (locale && /^[a-zA-Z]{2,3}(-[a-zA-Z0-9]+)*$/.test(locale)) htmlAttrs = `lang="${locale}"`;
51
- if (colorMode === "dark" || colorMode === "light") htmlAttrs += ` class="${colorMode}"`;
52
- body = body.replace(/<html\b[^>]*>/i, `<html ${htmlAttrs}>`);
53
- body = rebasePublicAssetURLs(body, getURLBasePath(ctx.payload.config.baseURL));
54
- event.response.headers.set("content-type", "text/html; charset=utf-8");
55
- event.response.headers.set("content-security-policy", "frame-ancestors 'none'");
56
- event.response.headers.set("x-frame-options", "DENY");
57
- event.response.headers.set("referrer-policy", "no-referrer");
58
- return body;
59
- }
60
- //#endregion
61
- export { renderUIPage };
62
-
63
- //# sourceMappingURL=render.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"render.mjs","names":["getURLBasePath","useRequestCookie","read","fs","path","CodeTransformation","isCodeTransformation","UI_DIST_PATH","UI_SOURCE_PATH","UI_HTTP_CLIENT_FACTORY_STORE_KEY","VITE_SERVER_STORE_KEY","LOCALE_COOKIE","rebasePublicAssetURLs","COLOR_MODE_COOKIE","cachedHtml","cachedManifest","cachedRender","renderUIPage","event","ctx","isJIT","JUST_IN_TIME","colorMode","payload","config","locale","html","manifest","render","vite","store","promises","readFile","join","transformIndexHtml","ssrLoadModule","JSON","parse","httpClientFactory","appHtml","preloadLinks","url","httpClient","undefined","body","replace","htmlAttrs","test","baseURL","response","headers","set"],"sources":["../../../../src/adapters/http/ui/render.ts"],"sourcesContent":["/*\n * Copyright (c) 2026.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\nimport { getURLBasePath } from '@authup/kit';\nimport { useRequestCookie } from '@routup/basic/cookie';\nimport { read } from 'locter';\nimport fs from 'node:fs';\nimport path from 'node:path';\nimport type { IAppEvent } from 'routup';\nimport type { ViteDevServer } from 'vite';\nimport { CodeTransformation, isCodeTransformation } from 'typeorm-extension';\nimport type { IClient } from '@authup/core-http-kit';\nimport { UI_DIST_PATH, UI_SOURCE_PATH } from '../../../path.ts';\nimport { UI_HTTP_CLIENT_FACTORY_STORE_KEY, VITE_SERVER_STORE_KEY } from '../middleware/index.ts';\nimport { LOCALE_COOKIE } from '../request/helpers/locale.ts';\nimport { rebasePublicAssetURLs } from './base-path.ts';\nimport type { UIRenderContext } from './types.ts';\n\nconst COLOR_MODE_COOKIE = 'vc-color-mode';\n\n// Process-lifetime caches for the immutable production SSR assets. The dist\n// template, manifest and server bundle don't change after boot, so read them\n// once instead of per request (the auth/login routes are hot paths). The JIT\n// (dev) path deliberately re-reads so HMR keeps working.\nlet cachedHtml: string | undefined;\nlet cachedManifest: Record<string, any> | undefined;\nlet cachedRender: CallableFunction | undefined;\n\nexport async function renderUIPage(event: IAppEvent, ctx: UIRenderContext): Promise<string> {\n const isJIT = isCodeTransformation(CodeTransformation.JUST_IN_TIME);\n\n // Mirror @vuecs/nuxt's SSR plugins: resolve the cookies server-side so\n // the HTML shell already carries the `.dark`/`.light` class and lang\n // attribute (no flash) and the client app hydrates from the same values.\n const colorMode = useRequestCookie(event, COLOR_MODE_COOKIE);\n ctx.payload.config.colorMode = colorMode;\n\n const locale = useRequestCookie(event, LOCALE_COOKIE);\n ctx.payload.config.locale = locale;\n\n let html : string;\n let manifest : Record<string, any>;\n let render : CallableFunction;\n\n if (isJIT) {\n const vite = event.store[VITE_SERVER_STORE_KEY] as ViteDevServer;\n\n html = await fs.promises.readFile(\n path.join(UI_SOURCE_PATH, 'index.html'),\n 'utf-8',\n );\n html = await vite.transformIndexHtml('/', html);\n manifest = {};\n render = (await vite.ssrLoadModule('/src/server.ts')).render;\n } else {\n html = (cachedHtml ??= await fs.promises.readFile(\n path.join(UI_DIST_PATH, 'client', 'index.html'),\n 'utf-8',\n ));\n manifest = (cachedManifest ??= JSON.parse(await fs.promises.readFile(\n path.join(UI_DIST_PATH, 'client', '.vite', 'ssr-manifest.json'),\n 'utf-8',\n )));\n render = (cachedRender ??= (await read(\n path.join(UI_DIST_PATH, 'server', 'server.js'),\n )).render);\n }\n\n const httpClientFactory = event.store[UI_HTTP_CLIENT_FACTORY_STORE_KEY] as (() => IClient) | undefined;\n\n const [appHtml, preloadLinks] = await render({\n url: ctx.url,\n manifest,\n payload: ctx.payload,\n httpClient: httpClientFactory ? httpClientFactory() : undefined,\n });\n\n let body = html\n .replace('<!--preload-links-->', preloadLinks)\n .replace('<!--app-html-->', appHtml);\n\n let htmlAttrs = 'lang=\"en\"';\n if (locale && /^[a-zA-Z]{2,3}(-[a-zA-Z0-9]+)*$/.test(locale)) {\n htmlAttrs = `lang=\"${locale}\"`;\n }\n if (colorMode === 'dark' || colorMode === 'light') {\n htmlAttrs += ` class=\"${colorMode}\"`;\n }\n // Match the opening <html> tag by pattern rather than an exact literal,\n // so a reformatted tag / dev-mode transformIndexHtml rewrite still gets\n // the lang + color-mode attributes (no silent FOUC).\n body = body.replace(/<html\\b[^>]*>/i, `<html ${htmlAttrs}>`);\n\n // When authup is publicly served under a sub-path (publicUrl carries a\n // pathname, e.g. https://example.com/auth), the fixed /public/ vite base\n // would bypass the proxy mapping — rebase asset URLs onto the prefix.\n body = rebasePublicAssetURLs(body, getURLBasePath(ctx.payload.config.baseURL));\n\n event.response.headers.set('content-type', 'text/html; charset=utf-8');\n\n // Clickjacking guard: the SSR auth pages (login, consent, realm-mismatch,\n // logout) mutate state behind explicit clicks and hydrate the logged-in\n // session from first-party cookies. Framing them would make click-gating\n // defeatable via overlay attacks, so deny embedding entirely. (Iframe-based\n // silent renew is therefore unsupported — auth state is JS-readable anyway.)\n event.response.headers.set('content-security-policy', \"frame-ancestors 'none'\");\n event.response.headers.set('x-frame-options', 'DENY');\n\n // The auth pages' URLs routinely carry sensitive query params\n // (id_token_hint, code, redirect, state) — never leak them via Referer.\n event.response.headers.set('referrer-policy', 'no-referrer');\n\n return body;\n}\n\n"],"mappings":";;;;;;;;;;;;;;;;AAsBA,MAAMa,oBAAoB;AAM1B,IAAIC;AACJ,IAAIC;AACJ,IAAIC;AAEJ,eAAsBC,aAAaC,OAAkBC,KAAoB;CACrE,MAAMC,QAAQd,qBAAqBD,mBAAmBgB,YAAY;CAKlE,MAAMC,YAAYrB,iBAAiBiB,OAAOL,iBAAAA;CAC1CM,IAAII,QAAQC,OAAOF,YAAYA;CAE/B,MAAMG,SAASxB,iBAAiBiB,OAAOP,aAAAA;CACvCQ,IAAII,QAAQC,OAAOC,SAASA;CAE5B,IAAIC;CACJ,IAAIC;CACJ,IAAIC;CAEJ,IAAIR,OAAO;EACP,MAAMS,OAAOX,MAAMY,MAAMpB;EAEzBgB,OAAO,MAAMvB,GAAG4B,SAASC,SACrB5B,KAAK6B,KAAKzB,gBAAgB,YAAA,GAC1B,OAAA;EAEJkB,OAAO,MAAMG,KAAKK,mBAAmB,KAAKR,IAAAA;EAC1CC,WAAW,CAAC;EACZC,UAAU,MAAMC,KAAKM,cAAc,gBAAA,EAAA,CAAmBP;CAC1D,OAAO;EACHF,OAAQZ,eAAe,MAAMX,GAAG4B,SAASC,SACrC5B,KAAK6B,KAAK1B,cAAc,UAAU,YAAA,GAClC,OAAA;EAEJoB,WAAYZ,mBAAmBqB,KAAKC,MAAM,MAAMlC,GAAG4B,SAASC,SACxD5B,KAAK6B,KAAK1B,cAAc,UAAU,SAAS,mBAAA,GAC3C,OAAA,CAAA;EAEJqB,SAAUZ,kBAAkB,MAAMd,KAC9BE,KAAK6B,KAAK1B,cAAc,UAAU,WAAA,CAAA,EAAA,CACnCqB;CACP;CAEA,MAAMU,oBAAoBpB,MAAMY,MAAMrB;CAEtC,MAAM,CAAC8B,SAASC,gBAAgB,MAAMZ,OAAO;EACzCa,KAAKtB,IAAIsB;EACTd;EACAJ,SAASJ,IAAII;EACbmB,YAAYJ,oBAAoBA,kBAAAA,IAAsBK,KAAAA;CAC1D,CAAA;CAEA,IAAIC,OAAOlB,KACNmB,QAAQ,wBAAwBL,YAAAA,CAAAA,CAChCK,QAAQ,mBAAmBN,OAAAA;CAEhC,IAAIO,YAAY;CAChB,IAAIrB,UAAU,kCAAkCsB,KAAKtB,MAAAA,GACjDqB,YAAY,SAASrB,OAAO;CAEhC,IAAIH,cAAc,UAAUA,cAAc,SACtCwB,aAAa,WAAWxB,UAAU;CAKtCsB,OAAOA,KAAKC,QAAQ,kBAAkB,SAASC,UAAU,EAAE;CAK3DF,OAAOhC,sBAAsBgC,MAAM5C,eAAemB,IAAII,QAAQC,OAAOwB,OAAO,CAAA;CAE5E9B,MAAM+B,SAASC,QAAQC,IAAI,gBAAgB,0BAAA;CAO3CjC,MAAM+B,SAASC,QAAQC,IAAI,2BAA2B,wBAAA;CACtDjC,MAAM+B,SAASC,QAAQC,IAAI,mBAAmB,MAAA;CAI9CjC,MAAM+B,SAASC,QAAQC,IAAI,mBAAmB,aAAA;CAE9C,OAAOP;AACX"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"serve.d.ts","sourceRoot":"","sources":["../../../../src/adapters/http/ui/serve.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAEpE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AAIxC,MAAM,MAAM,wBAAwB,GAAG;IACnC,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,sBAAsB,CAAC;IAIjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC7B,KAAK,EAAE,SAAS,EAChB,OAAO,EAAE,wBAAwB,GAClC,OAAO,CAAC,MAAM,CAAC,CAwBjB"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"serve.mjs","names":["useRequestQuery","sanitizeRelativeRedirect","renderUIPage","serveWorkflowPage","event","options","query","data","features","redirect","realmAware","realmId","realm_id","undefined","tokenAware","token","url","payload","config","baseURL"],"sources":["../../../../src/adapters/http/ui/serve.ts"],"sourcesContent":["/*\n * Copyright (c) 2026.\n * Author Peter Placzek (tada5hi)\n * For the full copyright and license information,\n * view the LICENSE file that was distributed with this source code.\n */\n\nimport type { StatusResponseFeatures } from '@authup/core-http-kit';\nimport { useRequestQuery } from '@routup/basic/query';\nimport type { IAppEvent } from 'routup';\nimport { sanitizeRelativeRedirect } from '../request/index.ts';\nimport { renderUIPage } from './render.ts';\n\nexport type ServeWorkflowPageOptions = {\n url: string,\n baseURL: string,\n features: StatusResponseFeatures,\n // Whether the page consumes the `realmId` (legacy `realm_id`) / `token`\n // query params (e.g. prefill from an email deep link). Off by default so\n // a page never reflects a param it doesn't use.\n realmAware?: boolean,\n tokenAware?: boolean,\n};\n\n/**\n * Single SSR payload-assembly path for the auth workflow GET routes:\n * whitelists query params, applies the open-redirect guard, and renders.\n * Keeps the four workflow controllers as thin POST adapters.\n */\nexport function serveWorkflowPage(\n event: IAppEvent,\n options: ServeWorkflowPageOptions,\n): Promise<string> {\n const query = useRequestQuery(event);\n\n const data: Record<string, any> = {\n features: options.features,\n redirect: sanitizeRelativeRedirect(query.redirect),\n };\n\n if (options.realmAware) {\n const realmId = typeof query.realmId === 'string' ? query.realmId : query.realm_id;\n data.realmId = typeof realmId === 'string' ? realmId : undefined;\n }\n\n if (options.tokenAware) {\n data.token = typeof query.token === 'string' ? query.token : undefined;\n }\n\n return renderUIPage(event, {\n url: options.url,\n payload: {\n config: { baseURL: options.baseURL },\n data,\n },\n });\n}\n"],"mappings":";;;;;;;;;;;;GA6BA,SAAgBG,kBACZC,OACAC,SAAiC;CAEjC,MAAMC,QAAQN,gBAAgBI,KAAAA;CAE9B,MAAMG,OAA4B;EAC9BC,UAAUH,QAAQG;EAClBC,UAAUR,yBAAyBK,MAAMG,QAAQ;CACrD;CAEA,IAAIJ,QAAQK,YAAY;EACpB,MAAMC,UAAU,OAAOL,MAAMK,YAAY,WAAWL,MAAMK,UAAUL,MAAMM;EAC1EL,KAAKI,UAAU,OAAOA,YAAY,WAAWA,UAAUE,KAAAA;CAC3D;CAEA,IAAIR,QAAQS,YACRP,KAAKQ,QAAQ,OAAOT,MAAMS,UAAU,WAAWT,MAAMS,QAAQF,KAAAA;CAGjE,OAAOX,aAAaE,OAAO;EACvBY,KAAKX,QAAQW;EACbC,SAAS;GACLC,QAAQ,EAAEC,SAASd,QAAQc,QAAQ;GACnCZ;EACJ;CACJ,CAAA;AACJ"}
@@ -1,20 +0,0 @@
1
- export type UIRenderContext = {
2
- url: string;
3
- payload: {
4
- config: Record<string, any>;
5
- data: Record<string, any>;
6
- };
7
- };
8
- export type InternalUIHttpClientContext = {
9
- /**
10
- * The public base URL (config `publicUrl`) — stays the client's
11
- * `baseURL` so URLs rendered into the HTML remain user-facing.
12
- */
13
- publicURL: string;
14
- /**
15
- * The server's own listen address (e.g. http://localhost:3010/) —
16
- * where the transport actually dispatches requests.
17
- */
18
- internalURL: string;
19
- };
20
- //# sourceMappingURL=types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/adapters/http/ui/types.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,eAAe,GAAG;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE;QACL,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;QAC5B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;KAC7B,CAAC;CACL,CAAC;AAEF,MAAM,MAAM,2BAA2B,GAAG;IACtC;;;OAGG;IACH,SAAS,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,WAAW,EAAE,MAAM,CAAC;CACvB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../src/app/modules/identity/repositories/provider/account/index.ts"],"names":[],"mappings":"AAOA,cAAc,aAAa,CAAC"}
@@ -1,5 +0,0 @@
1
- import "node:path";
2
- import "node:url";
3
- import.meta.url;
4
- import { IdentityProviderAccountRepository } from "./module.mjs";
5
- export { IdentityProviderAccountRepository };
@@ -1,10 +0,0 @@
1
- import type { IdentityProviderAccount } from '@authup/core-kit';
2
- import type { DataSource, DeepPartial } from 'typeorm';
3
- import type { IIdentityProviderAccountRepository, IdentityProviderIdentity } from '../../../../../../core/index.ts';
4
- export declare class IdentityProviderAccountRepository implements IIdentityProviderAccountRepository {
5
- protected dataSource: DataSource;
6
- constructor(dataSource: DataSource);
7
- findOneByProviderIdentity(identity: IdentityProviderIdentity): Promise<IdentityProviderAccount | null>;
8
- save(entity: DeepPartial<IdentityProviderAccount>): Promise<IdentityProviderAccount>;
9
- }
10
- //# sourceMappingURL=module.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../../../../../src/app/modules/identity/repositories/provider/account/module.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,KAAK,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AACvD,OAAO,KAAK,EAAE,kCAAkC,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAGpH,qBAAa,iCAAkC,YAAW,kCAAkC;IACxF,SAAS,CAAC,UAAU,EAAG,UAAU,CAAC;gBAEtB,UAAU,EAAE,UAAU;IAI5B,yBAAyB,CAAC,QAAQ,EAAE,wBAAwB,GAAG,OAAO,CAAC,uBAAuB,GAAG,IAAI,CAAC;IAYtG,IAAI,CAAC,MAAM,EAAE,WAAW,CAAC,uBAAuB,CAAC,GAAG,OAAO,CAAC,uBAAuB,CAAC;CAK7F"}