@absolutejs/auth 0.65.0 → 0.65.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (264) hide show
  1. package/dist/index.js +7 -3
  2. package/dist/index.js.map +3 -3
  3. package/dist/server.js +7 -3
  4. package/dist/server.js.map +3 -3
  5. package/package.json +1 -1
  6. package/dist/abuse/captcha.d.ts +0 -11
  7. package/dist/abuse/config.d.ts +0 -29
  8. package/dist/actions.d.ts +0 -27
  9. package/dist/adaptive/config.d.ts +0 -34
  10. package/dist/adaptive/fingerprint.d.ts +0 -2
  11. package/dist/adaptive/inMemoryStores.d.ts +0 -3
  12. package/dist/adaptive/postgresStores.d.ts +0 -245
  13. package/dist/adaptive/types.d.ts +0 -62
  14. package/dist/agents/config.d.ts +0 -49
  15. package/dist/agents/context.d.ts +0 -46
  16. package/dist/agents/idJag.d.ts +0 -49
  17. package/dist/agents/inMemoryStores.d.ts +0 -4
  18. package/dist/agents/index.d.ts +0 -13
  19. package/dist/agents/oauthGuide.d.ts +0 -18
  20. package/dist/agents/oidcAdapter.d.ts +0 -20
  21. package/dist/agents/postgresStores.d.ts +0 -1176
  22. package/dist/agents/principal.d.ts +0 -4
  23. package/dist/agents/registration.d.ts +0 -162
  24. package/dist/agents/registrationClient.d.ts +0 -50
  25. package/dist/agents/routes.d.ts +0 -256
  26. package/dist/agents/types.d.ts +0 -129
  27. package/dist/apikeys/config.d.ts +0 -64
  28. package/dist/apikeys/inMemoryStores.d.ts +0 -4
  29. package/dist/apikeys/postgresStores.d.ts +0 -359
  30. package/dist/apikeys/routes.d.ts +0 -83
  31. package/dist/apikeys/types.d.ts +0 -53
  32. package/dist/audit/config.d.ts +0 -9
  33. package/dist/audit/export.d.ts +0 -2
  34. package/dist/audit/inMemoryAuditStore.d.ts +0 -2
  35. package/dist/audit/integrity.d.ts +0 -19
  36. package/dist/audit/postgresAuditStore.d.ts +0 -116
  37. package/dist/audit/siem.d.ts +0 -11
  38. package/dist/audit/types.d.ts +0 -21
  39. package/dist/audit/wrap.d.ts +0 -11
  40. package/dist/authContext.d.ts +0 -193
  41. package/dist/authorization/config.d.ts +0 -19
  42. package/dist/authorization/protectPermission.d.ts +0 -52
  43. package/dist/cli/import/auth0.d.ts +0 -2
  44. package/dist/cli/import/clerk.d.ts +0 -2
  45. package/dist/cli/import/index.d.ts +0 -10
  46. package/dist/cli/import/lucia.d.ts +0 -2
  47. package/dist/cli/import/nextauth.d.ts +0 -2
  48. package/dist/cli/import/supabase.d.ts +0 -2
  49. package/dist/cli/import/types.d.ts +0 -27
  50. package/dist/cli/migrate.d.ts +0 -2
  51. package/dist/client/components/react/SignIn.d.ts +0 -32
  52. package/dist/client/components/react/SignUp.d.ts +0 -29
  53. package/dist/client/components/react/UserButton.d.ts +0 -36
  54. package/dist/client/createAuthClient.d.ts +0 -285
  55. package/dist/client/index.d.ts +0 -4
  56. package/dist/client/passkeyHelpers.d.ts +0 -19
  57. package/dist/client/react.d.ts +0 -87
  58. package/dist/client/sessionExpiry.d.ts +0 -37
  59. package/dist/client/solid.d.ts +0 -86
  60. package/dist/client/svelte.d.ts +0 -86
  61. package/dist/client/vue.d.ts +0 -88
  62. package/dist/compliance/cipher.d.ts +0 -11
  63. package/dist/compliance/config.d.ts +0 -18
  64. package/dist/compliance/redaction.d.ts +0 -8
  65. package/dist/compliance/routes.d.ts +0 -89
  66. package/dist/constants.d.ts +0 -10
  67. package/dist/credentials/backgroundOps.d.ts +0 -45
  68. package/dist/credentials/config.d.ts +0 -94
  69. package/dist/credentials/emailValidation.d.ts +0 -9
  70. package/dist/credentials/emailVerification.d.ts +0 -83
  71. package/dist/credentials/import.d.ts +0 -49
  72. package/dist/credentials/inMemoryCredentialStore.d.ts +0 -2
  73. package/dist/credentials/legacyHashers.d.ts +0 -3
  74. package/dist/credentials/login.d.ts +0 -76
  75. package/dist/credentials/passwordPolicy.d.ts +0 -15
  76. package/dist/credentials/passwordReset.d.ts +0 -87
  77. package/dist/credentials/postgresCredentialStore.d.ts +0 -235
  78. package/dist/credentials/register.d.ts +0 -54
  79. package/dist/credentials/routes.d.ts +0 -201
  80. package/dist/credentials/types.d.ts +0 -26
  81. package/dist/crypto.d.ts +0 -32
  82. package/dist/csrf.d.ts +0 -10
  83. package/dist/errors.d.ts +0 -12
  84. package/dist/federation/tokenStore.d.ts +0 -29
  85. package/dist/fga/config.d.ts +0 -53
  86. package/dist/fga/inMemoryStores.d.ts +0 -3
  87. package/dist/fga/postgresStores.d.ts +0 -116
  88. package/dist/fga/redisCheckCache.d.ts +0 -11
  89. package/dist/fga/schema.d.ts +0 -2
  90. package/dist/fga/types.d.ts +0 -28
  91. package/dist/fingerprint-client/index.d.ts +0 -26
  92. package/dist/htmx/configuredRoutes.d.ts +0 -542
  93. package/dist/htmx/index.d.ts +0 -2
  94. package/dist/htmx/renderers.d.ts +0 -8
  95. package/dist/htmx/routes.d.ts +0 -514
  96. package/dist/htmx/types.d.ts +0 -129
  97. package/dist/index.d.ts +0 -3647
  98. package/dist/linkedProviders/inMemoryStores.d.ts +0 -9
  99. package/dist/linkedProviders/index.d.ts +0 -3
  100. package/dist/linkedProviders/neonStores.d.ts +0 -484
  101. package/dist/linkedProviders/oauthAccountResolver.d.ts +0 -28
  102. package/dist/linkedProviders/oauthResolver.d.ts +0 -9
  103. package/dist/linkedProviders/resolver.d.ts +0 -22
  104. package/dist/lockout/config.d.ts +0 -17
  105. package/dist/lockout/inMemoryLockoutStore.d.ts +0 -2
  106. package/dist/lockout/postgresLockoutStore.d.ts +0 -71
  107. package/dist/lockout/redisLockoutStore.d.ts +0 -3
  108. package/dist/lockout/types.d.ts +0 -12
  109. package/dist/manifest.d.ts +0 -18
  110. package/dist/manifest.json +0 -373
  111. package/dist/mfa/backupCodes.d.ts +0 -5
  112. package/dist/mfa/challenge.d.ts +0 -72
  113. package/dist/mfa/config.d.ts +0 -59
  114. package/dist/mfa/gate.d.ts +0 -2
  115. package/dist/mfa/inMemoryMfaStore.d.ts +0 -2
  116. package/dist/mfa/management.d.ts +0 -106
  117. package/dist/mfa/postgresMfaStore.d.ts +0 -266
  118. package/dist/mfa/recentAuth.d.ts +0 -2
  119. package/dist/mfa/rotation.d.ts +0 -17
  120. package/dist/mfa/routes.d.ts +0 -239
  121. package/dist/mfa/secret.d.ts +0 -2
  122. package/dist/mfa/sms.d.ts +0 -143
  123. package/dist/mfa/totp.d.ts +0 -91
  124. package/dist/mfa/types.d.ts +0 -58
  125. package/dist/migrations/generate.d.ts +0 -2
  126. package/dist/migrations/index.d.ts +0 -6
  127. package/dist/migrations/runner.d.ts +0 -22
  128. package/dist/migrations/types.d.ts +0 -14
  129. package/dist/oidc/clientAuth.d.ts +0 -19
  130. package/dist/oidc/clientIdMetadata.d.ts +0 -28
  131. package/dist/oidc/config.d.ts +0 -307
  132. package/dist/oidc/dpop.d.ts +0 -23
  133. package/dist/oidc/inMemoryStores.d.ts +0 -11
  134. package/dist/oidc/inMemoryVciStores.d.ts +0 -3
  135. package/dist/oidc/index.d.ts +0 -12
  136. package/dist/oidc/jar.d.ts +0 -14
  137. package/dist/oidc/keys.d.ts +0 -50
  138. package/dist/oidc/logout.d.ts +0 -38
  139. package/dist/oidc/mtls.d.ts +0 -11
  140. package/dist/oidc/operator.d.ts +0 -14
  141. package/dist/oidc/par.d.ts +0 -28
  142. package/dist/oidc/postgresStores.d.ts +0 -1217
  143. package/dist/oidc/registration.d.ts +0 -138
  144. package/dist/oidc/routes.d.ts +0 -569
  145. package/dist/oidc/types.d.ts +0 -157
  146. package/dist/oidc/userinfo.d.ts +0 -21
  147. package/dist/oidc/vci.d.ts +0 -159
  148. package/dist/oidc/vciRoutes.d.ts +0 -92
  149. package/dist/organizations/config.d.ts +0 -46
  150. package/dist/organizations/inMemoryOrganizationStore.d.ts +0 -2
  151. package/dist/organizations/operations.d.ts +0 -39
  152. package/dist/organizations/postgresOrganizationStore.d.ts +0 -340
  153. package/dist/organizations/routes.d.ts +0 -299
  154. package/dist/organizations/types.d.ts +0 -45
  155. package/dist/passwordless/config.d.ts +0 -43
  156. package/dist/passwordless/inMemoryPasswordlessTokenStore.d.ts +0 -2
  157. package/dist/passwordless/postgresPasswordlessTokenStore.d.ts +0 -56
  158. package/dist/passwordless/routes.d.ts +0 -163
  159. package/dist/passwordless/types.d.ts +0 -9
  160. package/dist/pluginIdentity.d.ts +0 -2
  161. package/dist/plugins/denyDisposableEmail.d.ts +0 -7
  162. package/dist/plugins/discordAlert.d.ts +0 -7
  163. package/dist/plugins/geoBlock.d.ts +0 -8
  164. package/dist/plugins/index.d.ts +0 -12
  165. package/dist/plugins/pagerdutyAlert.d.ts +0 -9
  166. package/dist/plugins/posthogIdentify.d.ts +0 -7
  167. package/dist/plugins/slackAlert.d.ts +0 -7
  168. package/dist/portal/config.d.ts +0 -34
  169. package/dist/portal/inMemorySetupSessionStore.d.ts +0 -2
  170. package/dist/portal/operations.d.ts +0 -10
  171. package/dist/portal/postgresSetupSessionStore.d.ts +0 -116
  172. package/dist/portal/routes.d.ts +0 -160
  173. package/dist/portal/types.d.ts +0 -16
  174. package/dist/providers/clients.d.ts +0 -1831
  175. package/dist/providers/index.d.ts +0 -2
  176. package/dist/providersFromEnv.d.ts +0 -19
  177. package/dist/redirect.d.ts +0 -2
  178. package/dist/roles/config.d.ts +0 -27
  179. package/dist/roles/inMemoryRoleStore.d.ts +0 -2
  180. package/dist/roles/operations.d.ts +0 -8
  181. package/dist/roles/postgresRoleStore.d.ts +0 -86
  182. package/dist/roles/resolver.d.ts +0 -17
  183. package/dist/roles/routes.d.ts +0 -106
  184. package/dist/roles/types.d.ts +0 -14
  185. package/dist/routes/authorize.d.ts +0 -102
  186. package/dist/routes/callback.d.ts +0 -64
  187. package/dist/routes/profile.d.ts +0 -73
  188. package/dist/routes/protectRoute.d.ts +0 -51
  189. package/dist/routes/refresh.d.ts +0 -74
  190. package/dist/routes/requireAuth.d.ts +0 -43
  191. package/dist/routes/revoke.d.ts +0 -73
  192. package/dist/routes/sessions.d.ts +0 -103
  193. package/dist/routes/signout.d.ts +0 -70
  194. package/dist/routes/stepUp.d.ts +0 -48
  195. package/dist/routes/userStatus.d.ts +0 -72
  196. package/dist/saml.d.ts +0 -1
  197. package/dist/scim/config.d.ts +0 -57
  198. package/dist/scim/extensions.d.ts +0 -30
  199. package/dist/scim/inMemoryScimTokenStore.d.ts +0 -2
  200. package/dist/scim/postgresScimTokenStore.d.ts +0 -86
  201. package/dist/scim/routes.d.ts +0 -366
  202. package/dist/scim/serialize.d.ts +0 -83
  203. package/dist/scim/types.d.ts +0 -54
  204. package/dist/server.d.ts +0 -34
  205. package/dist/session/access.d.ts +0 -33
  206. package/dist/session/anonymous.d.ts +0 -12
  207. package/dist/session/cleanup.d.ts +0 -45
  208. package/dist/session/cookieReader.d.ts +0 -10
  209. package/dist/session/impersonation.d.ts +0 -34
  210. package/dist/session/inMemoryStore.d.ts +0 -7
  211. package/dist/session/multiSession.d.ts +0 -27
  212. package/dist/session/neonStore.d.ts +0 -573
  213. package/dist/session/promote.d.ts +0 -23
  214. package/dist/session/redisStore.d.ts +0 -6
  215. package/dist/session/sessionsConfig.d.ts +0 -9
  216. package/dist/session/state.d.ts +0 -33
  217. package/dist/session/types.d.ts +0 -23
  218. package/dist/session/userSessions.d.ts +0 -19
  219. package/dist/sso/config.d.ts +0 -149
  220. package/dist/sso/discoveryRoute.d.ts +0 -63
  221. package/dist/sso/inMemorySamlServiceProviderStore.d.ts +0 -2
  222. package/dist/sso/inMemorySsoConnectionStore.d.ts +0 -2
  223. package/dist/sso/nodeSamlAdapter.d.ts +0 -8
  224. package/dist/sso/oidcRoutes.d.ts +0 -98
  225. package/dist/sso/postgresSamlServiceProviderStore.d.ts +0 -101
  226. package/dist/sso/postgresSsoConnectionStore.d.ts +0 -117
  227. package/dist/sso/samlIdpRoutes.d.ts +0 -139
  228. package/dist/sso/samlRoutes.d.ts +0 -179
  229. package/dist/sso/types.d.ts +0 -53
  230. package/dist/stores/postgres.d.ts +0 -5
  231. package/dist/stores/redis.d.ts +0 -5
  232. package/dist/telemetry/tracing.d.ts +0 -15
  233. package/dist/tenancy.d.ts +0 -9
  234. package/dist/typeGuards.d.ts +0 -6
  235. package/dist/typebox.d.ts +0 -4
  236. package/dist/types.d.ts +0 -431
  237. package/dist/utils.d.ts +0 -45
  238. package/dist/vault/config.d.ts +0 -20
  239. package/dist/vault/inMemoryVaultStore.d.ts +0 -2
  240. package/dist/vault/index.d.ts +0 -5
  241. package/dist/vault/postgresVaultStore.d.ts +0 -86
  242. package/dist/vault/types.d.ts +0 -14
  243. package/dist/vc/inMemoryVpStores.d.ts +0 -2
  244. package/dist/vc/openid4vp.d.ts +0 -82
  245. package/dist/vc/postgresVcStores.d.ts +0 -300
  246. package/dist/vc/sdJwt.d.ts +0 -37
  247. package/dist/vc/statusList.d.ts +0 -29
  248. package/dist/vc/statusListRoutes.d.ts +0 -63
  249. package/dist/vc/vpRoutes.d.ts +0 -120
  250. package/dist/verification/types.d.ts +0 -58
  251. package/dist/webauthn/adapter.d.ts +0 -59
  252. package/dist/webauthn/config.d.ts +0 -36
  253. package/dist/webauthn/inMemoryWebAuthnCredentialStore.d.ts +0 -2
  254. package/dist/webauthn/postgresWebAuthnCredentialStore.d.ts +0 -146
  255. package/dist/webauthn/routes.d.ts +0 -155
  256. package/dist/webauthn/simpleWebAuthnAdapter.d.ts +0 -3
  257. package/dist/webauthn/types.d.ts +0 -17
  258. package/dist/webauthn.d.ts +0 -1
  259. package/dist/webhooks/config.d.ts +0 -34
  260. package/dist/webhooks/dispatcher.d.ts +0 -3
  261. package/dist/webhooks/inMemoryStore.d.ts +0 -2
  262. package/dist/webhooks/postgresStore.d.ts +0 -116
  263. package/dist/webhooks/sign.d.ts +0 -11
  264. package/dist/webhooks/types.d.ts +0 -25
package/dist/index.d.ts DELETED
@@ -1,3647 +0,0 @@
1
- import { Elysia } from 'elysia';
2
- import type { AuthConfig } from './types';
3
- export declare const auth: <UserType>(configuration: AuthConfig<UserType>) => Promise<Elysia<"", {
4
- decorator: {};
5
- store: {
6
- session: import("./types").SessionRecord<UserType>;
7
- unregisteredSession: import("./types").UnregisteredSessionRecord;
8
- };
9
- derive: ({
10
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
11
- readonly code: "Bad Request";
12
- readonly message: "Cookies are missing";
13
- } | {
14
- readonly code: "Unauthorized";
15
- readonly message: "User is not authenticated";
16
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
17
- } & {
18
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
19
- readonly code: "Unauthorized";
20
- readonly message: "Recent authentication required";
21
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
22
- } & {
23
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
24
- code: "Forbidden" | "Unauthorized";
25
- message: "Agent is not authenticated" | "Insufficient agent scopes";
26
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
27
- }) | ({
28
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
29
- readonly code: "Bad Request";
30
- readonly message: "Cookies are missing";
31
- } | {
32
- readonly code: "Unauthorized";
33
- readonly message: "User is not authenticated";
34
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
35
- } & {
36
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
37
- readonly code: "Unauthorized";
38
- readonly message: "Recent authentication required";
39
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
40
- } & {
41
- readonly protectPermission: <AuthReturn, AuthFailReturn_3>(check: import(".").PermissionCheck, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
42
- readonly code: "Bad Request";
43
- readonly message: "Cookies are missing";
44
- } | {
45
- readonly code: "Forbidden";
46
- readonly message: "Insufficient permissions";
47
- } | {
48
- readonly code: "Unauthorized";
49
- readonly message: "User is not authenticated";
50
- }) => AuthFailReturn_3) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | import("elysia").ElysiaCustomStatusResponse<"Forbidden", "Insufficient permissions", 403> | AuthReturn | NonNullable<AuthFailReturn_3>>;
51
- } & {
52
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
53
- code: "Forbidden" | "Unauthorized";
54
- message: "Agent is not authenticated" | "Insufficient agent scopes";
55
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
56
- });
57
- resolve: {};
58
- }, {
59
- typebox: {};
60
- error: {};
61
- } & {
62
- typebox: {};
63
- error: {};
64
- }, {
65
- schema: {};
66
- standaloneSchema: {};
67
- macro: {};
68
- macroFn: {};
69
- parser: {};
70
- response: {};
71
- } & (({
72
- schema: {};
73
- standaloneSchema: {};
74
- macro: {};
75
- macroFn: {};
76
- parser: {};
77
- response: {};
78
- } & ({
79
- schema: import("elysia").UnwrapRoute<{
80
- cookie: import("@sinclair/typebox").TObject<{
81
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
82
- }>;
83
- }, {}, "">;
84
- standaloneSchema: {};
85
- macro: {};
86
- macroFn: {};
87
- parser: {};
88
- response: import("elysia").ExtractErrorFromHandle<{
89
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
90
- readonly code: "Bad Request";
91
- readonly message: "Cookies are missing";
92
- } | {
93
- readonly code: "Unauthorized";
94
- readonly message: "User is not authenticated";
95
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
96
- }>;
97
- } & ({
98
- schema: import("elysia").UnwrapRoute<{
99
- cookie: import("@sinclair/typebox").TObject<{
100
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
101
- }>;
102
- }, {}, "">;
103
- standaloneSchema: {};
104
- macro: {};
105
- macroFn: {};
106
- parser: {};
107
- response: import("elysia").ExtractErrorFromHandle<{
108
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
109
- readonly code: "Unauthorized";
110
- readonly message: "Recent authentication required";
111
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
112
- }>;
113
- } & ({
114
- schema: {};
115
- standaloneSchema: {};
116
- macro: {};
117
- macroFn: {};
118
- parser: {};
119
- response: {};
120
- } | {
121
- schema: import("elysia").UnwrapRoute<{
122
- cookie: import("@sinclair/typebox").TObject<{
123
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
124
- }>;
125
- }, {}, "">;
126
- standaloneSchema: {};
127
- macro: {};
128
- macroFn: {};
129
- parser: {};
130
- response: import("elysia").ExtractErrorFromHandle<{
131
- readonly protectPermission: <AuthReturn, AuthFailReturn_3>(check: import(".").PermissionCheck, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
132
- readonly code: "Bad Request";
133
- readonly message: "Cookies are missing";
134
- } | {
135
- readonly code: "Forbidden";
136
- readonly message: "Insufficient permissions";
137
- } | {
138
- readonly code: "Unauthorized";
139
- readonly message: "User is not authenticated";
140
- }) => AuthFailReturn_3) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | import("elysia").ElysiaCustomStatusResponse<"Forbidden", "Insufficient permissions", 403> | AuthReturn | NonNullable<AuthFailReturn_3>>;
141
- }>;
142
- })))) & {
143
- schema: {};
144
- standaloneSchema: {};
145
- macro: {};
146
- macroFn: {};
147
- parser: {};
148
- response: import("elysia").ExtractErrorFromHandle<{
149
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
150
- code: "Forbidden" | "Unauthorized";
151
- message: "Agent is not authenticated" | "Insufficient agent scopes";
152
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
153
- }>;
154
- }), {}, {
155
- derive: {};
156
- resolve: {};
157
- schema: {};
158
- standaloneSchema: {};
159
- response: {};
160
- }, {
161
- derive: {};
162
- resolve: {};
163
- schema: {};
164
- standaloneSchema: {};
165
- response: {};
166
- } & {
167
- derive: {};
168
- resolve: {};
169
- schema: {};
170
- standaloneSchema: {};
171
- response: {};
172
- }>>;
173
- export declare const createAuthApplications: <UserType>(configuration: AuthConfig<UserType>) => Promise<{
174
- authContext: Elysia<"", {
175
- decorator: {};
176
- store: {
177
- session: import("./types").SessionRecord<UserType>;
178
- unregisteredSession: import("./types").UnregisteredSessionRecord;
179
- };
180
- derive: ({
181
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
182
- readonly code: "Bad Request";
183
- readonly message: "Cookies are missing";
184
- } | {
185
- readonly code: "Unauthorized";
186
- readonly message: "User is not authenticated";
187
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
188
- } & {
189
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
190
- readonly code: "Unauthorized";
191
- readonly message: "Recent authentication required";
192
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
193
- } & {
194
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
195
- code: "Forbidden" | "Unauthorized";
196
- message: "Agent is not authenticated" | "Insufficient agent scopes";
197
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
198
- }) | ({
199
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
200
- readonly code: "Bad Request";
201
- readonly message: "Cookies are missing";
202
- } | {
203
- readonly code: "Unauthorized";
204
- readonly message: "User is not authenticated";
205
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
206
- } & {
207
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
208
- readonly code: "Unauthorized";
209
- readonly message: "Recent authentication required";
210
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
211
- } & {
212
- readonly protectPermission: <AuthReturn, AuthFailReturn_3>(check: import(".").PermissionCheck, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
213
- readonly code: "Bad Request";
214
- readonly message: "Cookies are missing";
215
- } | {
216
- readonly code: "Forbidden";
217
- readonly message: "Insufficient permissions";
218
- } | {
219
- readonly code: "Unauthorized";
220
- readonly message: "User is not authenticated";
221
- }) => AuthFailReturn_3) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | import("elysia").ElysiaCustomStatusResponse<"Forbidden", "Insufficient permissions", 403> | AuthReturn | NonNullable<AuthFailReturn_3>>;
222
- } & {
223
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
224
- code: "Forbidden" | "Unauthorized";
225
- message: "Agent is not authenticated" | "Insufficient agent scopes";
226
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
227
- });
228
- resolve: {};
229
- }, {
230
- typebox: {};
231
- error: {};
232
- } & {
233
- typebox: {};
234
- error: {};
235
- }, ({
236
- schema: {};
237
- standaloneSchema: {};
238
- macro: {};
239
- macroFn: {};
240
- parser: {};
241
- response: {};
242
- } & ({
243
- schema: import("elysia").UnwrapRoute<{
244
- cookie: import("@sinclair/typebox").TObject<{
245
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
246
- }>;
247
- }, {}, "">;
248
- standaloneSchema: {};
249
- macro: {};
250
- macroFn: {};
251
- parser: {};
252
- response: import("elysia").ExtractErrorFromHandle<{
253
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
254
- readonly code: "Bad Request";
255
- readonly message: "Cookies are missing";
256
- } | {
257
- readonly code: "Unauthorized";
258
- readonly message: "User is not authenticated";
259
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
260
- }>;
261
- } & ({
262
- schema: import("elysia").UnwrapRoute<{
263
- cookie: import("@sinclair/typebox").TObject<{
264
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
265
- }>;
266
- }, {}, "">;
267
- standaloneSchema: {};
268
- macro: {};
269
- macroFn: {};
270
- parser: {};
271
- response: import("elysia").ExtractErrorFromHandle<{
272
- readonly requireRecentAuth: <AuthReturn, AuthFailReturn_1>(maxAgeMs: number, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
273
- readonly code: "Unauthorized";
274
- readonly message: "Recent authentication required";
275
- }) => AuthFailReturn_1) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "Recent authentication required", 401> | AuthReturn | NonNullable<AuthFailReturn_1>>;
276
- }>;
277
- } & ({
278
- schema: {};
279
- standaloneSchema: {};
280
- macro: {};
281
- macroFn: {};
282
- parser: {};
283
- response: {};
284
- } | {
285
- schema: import("elysia").UnwrapRoute<{
286
- cookie: import("@sinclair/typebox").TObject<{
287
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
288
- }>;
289
- }, {}, "">;
290
- standaloneSchema: {};
291
- macro: {};
292
- macroFn: {};
293
- parser: {};
294
- response: import("elysia").ExtractErrorFromHandle<{
295
- readonly protectPermission: <AuthReturn, AuthFailReturn_3>(check: import(".").PermissionCheck, handleAuth: (user: UserType) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
296
- readonly code: "Bad Request";
297
- readonly message: "Cookies are missing";
298
- } | {
299
- readonly code: "Forbidden";
300
- readonly message: "Insufficient permissions";
301
- } | {
302
- readonly code: "Unauthorized";
303
- readonly message: "User is not authenticated";
304
- }) => AuthFailReturn_3) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | import("elysia").ElysiaCustomStatusResponse<"Forbidden", "Insufficient permissions", 403> | AuthReturn | NonNullable<AuthFailReturn_3>>;
305
- }>;
306
- })))) & {
307
- schema: {};
308
- standaloneSchema: {};
309
- macro: {};
310
- macroFn: {};
311
- parser: {};
312
- response: import("elysia").ExtractErrorFromHandle<{
313
- readonly protectAgent: <AuthReturn, AuthFailReturn_2>(requiredScopes: string[], handleAuth: (principal: import(".").AgentPrincipal) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: (error: {
314
- code: "Forbidden" | "Unauthorized";
315
- message: "Agent is not authenticated" | "Insufficient agent scopes";
316
- }) => AuthFailReturn_2 | Promise<AuthFailReturn_2>) => Promise<Response | AuthReturn | NonNullable<Awaited<AuthFailReturn_2>>>;
317
- }>;
318
- }, {}, {
319
- derive: {};
320
- resolve: {};
321
- schema: {};
322
- standaloneSchema: {};
323
- response: {};
324
- }, ({
325
- derive: {};
326
- resolve: {};
327
- schema: {};
328
- standaloneSchema: {};
329
- response: {};
330
- } & {
331
- derive: {};
332
- resolve: {};
333
- schema: {};
334
- standaloneSchema: {};
335
- response: {};
336
- }) | ({
337
- derive: {};
338
- resolve: {};
339
- schema: {};
340
- standaloneSchema: {};
341
- response: {};
342
- } & {
343
- derive: {};
344
- resolve: {};
345
- schema: {};
346
- standaloneSchema: {};
347
- response: {};
348
- } & {
349
- derive: {};
350
- resolve: {};
351
- schema: {};
352
- standaloneSchema: {};
353
- response: {};
354
- })>;
355
- coreRoutes: Elysia<"", {
356
- decorator: {};
357
- store: {
358
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<NoInfer<UserType>>;
359
- unregisteredSession: import("./types").UnregisteredSessionRecord;
360
- };
361
- derive: {
362
- readonly cleanupSessions: () => Promise<void>;
363
- };
364
- resolve: {};
365
- }, {
366
- typebox: {};
367
- error: {};
368
- } & {
369
- typebox: {};
370
- error: {};
371
- }, {
372
- schema: {};
373
- standaloneSchema: {};
374
- macro: {};
375
- macroFn: {};
376
- parser: {};
377
- response: {};
378
- } & {
379
- schema: {};
380
- standaloneSchema: {};
381
- macro: {};
382
- macroFn: {};
383
- parser: {};
384
- response: import("elysia").ExtractErrorFromHandle<{
385
- readonly cleanupSessions: () => Promise<void>;
386
- }>;
387
- } & {
388
- schema: {};
389
- standaloneSchema: {};
390
- macro: {};
391
- macroFn: {};
392
- parser: {};
393
- response: {};
394
- }, (({
395
- [x: string]: {
396
- delete: {
397
- body: unknown;
398
- params: {};
399
- query: unknown;
400
- headers: unknown;
401
- response: {
402
- 400: "Cookies are missing";
403
- 401: "No user session id found";
404
- 200: Response;
405
- 422: {
406
- type: "validation";
407
- on: string;
408
- summary?: string;
409
- message?: string;
410
- found?: unknown;
411
- property?: string;
412
- expected?: string;
413
- };
414
- 500: "Sign out operation failed";
415
- };
416
- };
417
- };
418
- } & {
419
- [x: string]: {
420
- post: {
421
- body: unknown;
422
- params: {};
423
- query: unknown;
424
- headers: unknown;
425
- response: {
426
- 400: "Cookies are missing" | "Session has no access token to revoke";
427
- 401: "Provider is required" | "Client provider not found" | "Client variant is required" | "Client variant not found" | "No auth provider found" | "No user session found";
428
- 501: "Provider does not support revocation";
429
- 200: Response;
430
- 422: {
431
- type: "validation";
432
- on: string;
433
- summary?: string;
434
- message?: string;
435
- found?: unknown;
436
- property?: string;
437
- expected?: string;
438
- };
439
- 500: "Failed to revoke token";
440
- };
441
- };
442
- };
443
- } & ({
444
- [x: string]: {
445
- get: {
446
- body: unknown;
447
- params: {};
448
- query: unknown;
449
- headers: unknown;
450
- response: {
451
- 400: "Cookies are missing";
452
- 200: {
453
- impersonator: import("./types").Impersonator | undefined;
454
- user: NonNullable<UserType> | null;
455
- };
456
- 422: {
457
- type: "validation";
458
- on: string;
459
- summary?: string;
460
- message?: string;
461
- found?: unknown;
462
- property?: string;
463
- expected?: string;
464
- };
465
- 500: `Error: ${string} - ${string}` | `Unknown Error: ${string}`;
466
- };
467
- };
468
- };
469
- } & ({
470
- [x: string]: {
471
- post: {
472
- body: unknown;
473
- params: {};
474
- query: unknown;
475
- headers: unknown;
476
- response: {
477
- 400: "Cookies are missing" | "No refresh token found";
478
- 401: "Provider is required" | "Client provider not found" | "Client variant is required" | "Client variant not found" | "No auth provider found" | "No user session found";
479
- 501: "Provider is not refreshable";
480
- 200: Response;
481
- 422: {
482
- type: "validation";
483
- on: string;
484
- summary?: string;
485
- message?: string;
486
- found?: unknown;
487
- property?: string;
488
- expected?: string;
489
- };
490
- 500: "Failed to refresh token";
491
- };
492
- };
493
- };
494
- } & ({
495
- [x: string]: {
496
- ":provider": {
497
- get: {
498
- body: unknown;
499
- params: {
500
- provider: string;
501
- };
502
- query: {
503
- client?: string | undefined;
504
- intent?: "login" | "link_identity" | "link_connector" | undefined;
505
- };
506
- headers: unknown;
507
- response: {
508
- 400: "Cookies are missing" | "Provider is required";
509
- 401: "Provider is required" | "Client provider not found" | "Client variant is required" | "Client variant not found";
510
- 200: Response;
511
- 422: {
512
- type: "validation";
513
- on: string;
514
- summary?: string;
515
- message?: string;
516
- found?: unknown;
517
- property?: string;
518
- expected?: string;
519
- };
520
- 500: "Failed to create authorization URL";
521
- };
522
- };
523
- };
524
- };
525
- } | {
526
- [x: string]: {
527
- ":provider": {
528
- [x: string]: {
529
- get: {
530
- body: unknown;
531
- params: {
532
- provider: string;
533
- };
534
- query: {
535
- client?: string | undefined;
536
- intent?: "login" | "link_identity" | "link_connector" | undefined;
537
- };
538
- headers: unknown;
539
- response: {
540
- 400: "Cookies are missing" | "Provider is required";
541
- 401: "Provider is required" | "Client provider not found" | "Client variant is required" | "Client variant not found";
542
- 200: Response;
543
- 422: {
544
- type: "validation";
545
- on: string;
546
- summary?: string;
547
- message?: string;
548
- found?: unknown;
549
- property?: string;
550
- expected?: string;
551
- };
552
- 500: "Failed to create authorization URL";
553
- };
554
- };
555
- };
556
- };
557
- };
558
- })))) & {
559
- [x: string]: {
560
- get: {
561
- body: unknown;
562
- params: {};
563
- query: unknown;
564
- headers: unknown;
565
- response: {
566
- [x: number]: {};
567
- };
568
- };
569
- };
570
- }) & {
571
- [x: string]: {
572
- get: {
573
- body: unknown;
574
- params: {};
575
- query: unknown;
576
- headers: unknown;
577
- response: {
578
- 400: "Cookies are missing" | "Session has no access token to fetch a profile";
579
- 401: "Provider is required" | "Client provider not found" | "Client variant is required" | "Client variant not found" | "No auth provider found" | "No user session found";
580
- 501: "Provider does not expose a profile endpoint";
581
- 200: Response;
582
- 422: {
583
- type: "validation";
584
- on: string;
585
- summary?: string;
586
- message?: string;
587
- found?: unknown;
588
- property?: string;
589
- expected?: string;
590
- };
591
- 500: `${string} - ${string}` | `Failed to validate authorization code: Unknown status: ${string}`;
592
- };
593
- };
594
- };
595
- }, {
596
- derive: {};
597
- resolve: {};
598
- schema: {};
599
- standaloneSchema: {};
600
- response: {};
601
- }, {
602
- derive: {};
603
- resolve: {};
604
- schema: {};
605
- standaloneSchema: {};
606
- response: {};
607
- } & {
608
- derive: {};
609
- resolve: {};
610
- schema: {};
611
- standaloneSchema: {};
612
- response: {};
613
- } & {
614
- derive: {};
615
- resolve: {};
616
- schema: {};
617
- standaloneSchema: {};
618
- response: {};
619
- }>;
620
- featureRoutes: Elysia<"", {
621
- decorator: {};
622
- store: {} | {
623
- session: import("./types").SessionRecord<import(".").AuthHtmxUser>;
624
- unregisteredSession: import("./types").UnregisteredSessionRecord;
625
- } | {
626
- session: import("./types").SessionRecord<UserType>;
627
- unregisteredSession: import("./types").UnregisteredSessionRecord;
628
- } | {
629
- session: import("./types").SessionRecord<UserType>;
630
- unregisteredSession: import("./types").UnregisteredSessionRecord;
631
- } | {
632
- session: import("./types").SessionRecord<UserType>;
633
- unregisteredSession: import("./types").UnregisteredSessionRecord;
634
- } | {
635
- session: import("./types").SessionRecord<UserType>;
636
- unregisteredSession: import("./types").UnregisteredSessionRecord;
637
- } | {
638
- session: import("./types").SessionRecord<UserType>;
639
- unregisteredSession: import("./types").UnregisteredSessionRecord;
640
- } | {
641
- session: import("./types").SessionRecord<UserType>;
642
- unregisteredSession: import("./types").UnregisteredSessionRecord;
643
- } | {
644
- session: import("./types").SessionRecord<UserType>;
645
- unregisteredSession: import("./types").UnregisteredSessionRecord;
646
- } | {
647
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
648
- unregisteredSession: import("./types").UnregisteredSessionRecord;
649
- } | {
650
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
651
- unregisteredSession: import("./types").UnregisteredSessionRecord;
652
- } | {
653
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
654
- unregisteredSession: import("./types").UnregisteredSessionRecord;
655
- } | {
656
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
657
- unregisteredSession: import("./types").UnregisteredSessionRecord;
658
- } | {
659
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
660
- unregisteredSession: import("./types").UnregisteredSessionRecord;
661
- } | {
662
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
663
- unregisteredSession: import("./types").UnregisteredSessionRecord;
664
- } | {
665
- session: import("./types").SessionRecord<UserType> & import("./types").SessionRecord<import(".").AuthHtmxUser>;
666
- unregisteredSession: import("./types").UnregisteredSessionRecord;
667
- };
668
- derive: {} | {
669
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: import(".").AuthHtmxUser) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
670
- readonly code: "Bad Request";
671
- readonly message: "Cookies are missing";
672
- } | {
673
- readonly code: "Unauthorized";
674
- readonly message: "User is not authenticated";
675
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
676
- };
677
- resolve: {};
678
- }, {
679
- typebox: {};
680
- error: {};
681
- } & {
682
- typebox: {};
683
- error: {};
684
- }, (({
685
- schema: {};
686
- standaloneSchema: {};
687
- macro: {};
688
- macroFn: {};
689
- parser: {};
690
- response: {};
691
- } & {
692
- schema: {};
693
- standaloneSchema: {};
694
- macro: {};
695
- macroFn: {};
696
- parser: {};
697
- response: {};
698
- }) | ({
699
- schema: {};
700
- standaloneSchema: {};
701
- macro: {};
702
- macroFn: {};
703
- parser: {};
704
- response: {};
705
- } & {
706
- schema: {};
707
- standaloneSchema: {};
708
- macro: {};
709
- macroFn: {};
710
- parser: {};
711
- response: {};
712
- } & {
713
- schema: import("elysia").UnwrapRoute<{
714
- cookie: import("@sinclair/typebox").TObject<{
715
- user_session_id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TTemplateLiteralSyntax<"${string}-${string}-${string}-${string}-${string}">>;
716
- }>;
717
- }, {}, "">;
718
- standaloneSchema: {};
719
- macro: {};
720
- macroFn: {};
721
- parser: {};
722
- response: import("elysia").ExtractErrorFromHandle<{
723
- readonly protectRoute: <AuthReturn, AuthFailReturn = never>(handleAuth: (user: import(".").AuthHtmxUser) => AuthReturn | Promise<AuthReturn>, handleAuthFail?: ((error: {
724
- readonly code: "Bad Request";
725
- readonly message: "Cookies are missing";
726
- } | {
727
- readonly code: "Unauthorized";
728
- readonly message: "User is not authenticated";
729
- }) => AuthFailReturn) | undefined) => Promise<import("elysia").ElysiaCustomStatusResponse<"Bad Request", "Cookies are missing", 400> | import("elysia").ElysiaCustomStatusResponse<"Unauthorized", "User is not authenticated", 401> | AuthReturn | NonNullable<AuthFailReturn>>;
730
- }>;
731
- })) & {
732
- schema: {};
733
- standaloneSchema: {};
734
- macro: {};
735
- macroFn: {};
736
- parser: {};
737
- response: {};
738
- }, (((((((((((((((({} | ({
739
- [x: string]: {
740
- post: {
741
- body: {
742
- email: string;
743
- password: string;
744
- };
745
- params: {};
746
- query: unknown;
747
- headers: unknown;
748
- response: {
749
- [x: number]: {};
750
- };
751
- };
752
- };
753
- } & {
754
- [x: string]: {
755
- post: {
756
- body: {
757
- token: string;
758
- };
759
- params: {};
760
- query: unknown;
761
- headers: unknown;
762
- response: {
763
- 400: "Invalid or expired verification token";
764
- 200: {
765
- readonly status: "email_verified";
766
- };
767
- 422: {
768
- type: "validation";
769
- on: string;
770
- summary?: string;
771
- message?: string;
772
- found?: unknown;
773
- property?: string;
774
- expected?: string;
775
- };
776
- };
777
- };
778
- };
779
- } & {
780
- [x: string]: {
781
- request: {
782
- post: {
783
- body: {
784
- email: string;
785
- };
786
- params: {};
787
- query: unknown;
788
- headers: unknown;
789
- response: {
790
- 200: {
791
- readonly status: "verification_requested";
792
- };
793
- 422: {
794
- type: "validation";
795
- on: string;
796
- summary?: string;
797
- message?: string;
798
- found?: unknown;
799
- property?: string;
800
- expected?: string;
801
- };
802
- };
803
- };
804
- };
805
- };
806
- } & {
807
- [x: string]: {
808
- post: {
809
- body: {
810
- email: string;
811
- password: string;
812
- };
813
- params: {};
814
- query: unknown;
815
- headers: unknown;
816
- response: {
817
- 401: "Invalid email or password";
818
- 403: "Request origin is not allowed" | {
819
- readonly status: "email_not_verified";
820
- };
821
- 200: {
822
- readonly status: "mfa_required";
823
- } | {
824
- readonly passwordCompromised: boolean;
825
- readonly status: "authenticated";
826
- };
827
- 422: {
828
- type: "validation";
829
- on: string;
830
- summary?: string;
831
- message?: string;
832
- found?: unknown;
833
- property?: string;
834
- expected?: string;
835
- };
836
- 429: {
837
- readonly retryAfterMs: number | undefined;
838
- readonly status: "account_locked";
839
- };
840
- };
841
- };
842
- };
843
- } & {
844
- [x: string]: {
845
- request: {
846
- post: {
847
- body: {
848
- email: string;
849
- };
850
- params: {};
851
- query: unknown;
852
- headers: unknown;
853
- response: {
854
- 200: {
855
- readonly status: "reset_requested";
856
- };
857
- 422: {
858
- type: "validation";
859
- on: string;
860
- summary?: string;
861
- message?: string;
862
- found?: unknown;
863
- property?: string;
864
- expected?: string;
865
- };
866
- };
867
- };
868
- };
869
- };
870
- } & {
871
- [x: string]: {
872
- post: {
873
- body: {
874
- token: string;
875
- password: string;
876
- };
877
- params: {};
878
- query: unknown;
879
- headers: unknown;
880
- response: {
881
- 400: "Invalid or expired reset token" | {
882
- readonly message: "Password does not meet the policy";
883
- readonly violations: import(".").PasswordPolicyViolation[];
884
- };
885
- 200: {
886
- readonly status: "password_reset";
887
- };
888
- 422: {
889
- type: "validation";
890
- on: string;
891
- summary?: string;
892
- message?: string;
893
- found?: unknown;
894
- property?: string;
895
- expected?: string;
896
- };
897
- };
898
- };
899
- };
900
- })) & ({} | ({
901
- [x: string]: {
902
- get: {
903
- body: unknown;
904
- params: {};
905
- query: unknown;
906
- headers: unknown;
907
- response: {
908
- 401: "Authentication required";
909
- 200: {
910
- backupCodesRemaining: number;
911
- enabled: boolean;
912
- smsBackup: {
913
- enabled: boolean;
914
- phone: string | null;
915
- };
916
- totp: {
917
- enabled: boolean;
918
- };
919
- };
920
- 422: {
921
- type: "validation";
922
- on: string;
923
- summary?: string;
924
- message?: string;
925
- found?: unknown;
926
- property?: string;
927
- expected?: string;
928
- };
929
- };
930
- };
931
- };
932
- } & {
933
- [x: string]: {
934
- delete: {
935
- body: unknown;
936
- params: {};
937
- query: unknown;
938
- headers: unknown;
939
- response: {
940
- 401: "Recent authentication required" | "Authentication required";
941
- 200: {
942
- readonly status: "disabled";
943
- };
944
- 422: {
945
- type: "validation";
946
- on: string;
947
- summary?: string;
948
- message?: string;
949
- found?: unknown;
950
- property?: string;
951
- expected?: string;
952
- };
953
- };
954
- };
955
- };
956
- } & {
957
- [x: string]: {
958
- post: {
959
- body: unknown;
960
- params: {};
961
- query: unknown;
962
- headers: unknown;
963
- response: {
964
- 401: "Recent authentication required" | "Authentication required";
965
- 200: {
966
- readonly secret: string;
967
- readonly uri: string;
968
- };
969
- 422: {
970
- type: "validation";
971
- on: string;
972
- summary?: string;
973
- message?: string;
974
- found?: unknown;
975
- property?: string;
976
- expected?: string;
977
- };
978
- };
979
- };
980
- };
981
- } & {
982
- [x: string]: {
983
- post: {
984
- body: {
985
- code: string;
986
- };
987
- params: {};
988
- query: unknown;
989
- headers: unknown;
990
- response: {
991
- 400: "No TOTP enrollment in progress" | "Invalid TOTP code";
992
- 401: "Recent authentication required" | "Authentication required";
993
- 200: {
994
- readonly backupCodes: string[];
995
- };
996
- 422: {
997
- type: "validation";
998
- on: string;
999
- summary?: string;
1000
- message?: string;
1001
- found?: unknown;
1002
- property?: string;
1003
- expected?: string;
1004
- };
1005
- };
1006
- };
1007
- };
1008
- } & {
1009
- [x: string]: {
1010
- post: {
1011
- body: {
1012
- phone: string;
1013
- };
1014
- params: {};
1015
- query: unknown;
1016
- headers: unknown;
1017
- response: {
1018
- 400: string;
1019
- 401: "Recent authentication required" | "Authentication required";
1020
- 501: "SMS MFA is not configured";
1021
- 200: {
1022
- readonly phone: string;
1023
- };
1024
- 422: {
1025
- type: "validation";
1026
- on: string;
1027
- summary?: string;
1028
- message?: string;
1029
- found?: unknown;
1030
- property?: string;
1031
- expected?: string;
1032
- };
1033
- 429: string;
1034
- 503: string;
1035
- };
1036
- };
1037
- };
1038
- } & {
1039
- [x: string]: {
1040
- post: {
1041
- body: {
1042
- code: string;
1043
- };
1044
- params: {};
1045
- query: unknown;
1046
- headers: unknown;
1047
- response: {
1048
- 400: string;
1049
- 401: "Recent authentication required" | "Authentication required";
1050
- 200: {
1051
- readonly status: "enrolled";
1052
- };
1053
- 422: {
1054
- type: "validation";
1055
- on: string;
1056
- summary?: string;
1057
- message?: string;
1058
- found?: unknown;
1059
- property?: string;
1060
- expected?: string;
1061
- };
1062
- 429: string;
1063
- 503: string;
1064
- };
1065
- };
1066
- };
1067
- } & {
1068
- [x: string]: {
1069
- post: {
1070
- body: {
1071
- code?: string | undefined;
1072
- action?: "verify" | "send" | undefined;
1073
- factor?: "sms" | undefined;
1074
- };
1075
- params: {};
1076
- query: unknown;
1077
- headers: unknown;
1078
- response: {
1079
- 400: string;
1080
- 401: "SMS code expired" | "Too many attempts" | "SMS challenge is no longer active" | "No MFA challenge in progress" | "Invalid MFA code";
1081
- 200: {
1082
- readonly status: "sent";
1083
- } | {
1084
- readonly status: "authenticated";
1085
- };
1086
- 422: {
1087
- type: "validation";
1088
- on: string;
1089
- summary?: string;
1090
- message?: string;
1091
- found?: unknown;
1092
- property?: string;
1093
- expected?: string;
1094
- };
1095
- 429: string;
1096
- 503: string;
1097
- };
1098
- };
1099
- };
1100
- }))) & {}) & ({} | ({
1101
- [x: string]: {
1102
- get: {
1103
- body: unknown;
1104
- params: {};
1105
- query: unknown;
1106
- headers: unknown;
1107
- response: {
1108
- 401: "Authentication required";
1109
- 501: "Session management requires an authSessionStore";
1110
- 200: {
1111
- readonly sessions: {
1112
- authenticatedAt?: number;
1113
- current: boolean;
1114
- expiresAt: number;
1115
- id: import("./types").UserSessionId;
1116
- }[];
1117
- };
1118
- 422: {
1119
- type: "validation";
1120
- on: string;
1121
- summary?: string;
1122
- message?: string;
1123
- found?: unknown;
1124
- property?: string;
1125
- expected?: string;
1126
- };
1127
- };
1128
- };
1129
- };
1130
- } & {
1131
- [x: string]: {
1132
- ":id": {
1133
- delete: {
1134
- body: unknown;
1135
- params: {
1136
- id: string;
1137
- };
1138
- query: unknown;
1139
- headers: unknown;
1140
- response: {
1141
- 400: "Invalid session id";
1142
- 401: "Authentication required";
1143
- 501: "Session management requires an authSessionStore";
1144
- 404: "Session not found";
1145
- 200: {
1146
- readonly revoked: `${string}-${string}-${string}-${string}-${string}`;
1147
- };
1148
- 422: {
1149
- type: "validation";
1150
- on: string;
1151
- summary?: string;
1152
- message?: string;
1153
- found?: unknown;
1154
- property?: string;
1155
- expected?: string;
1156
- };
1157
- };
1158
- };
1159
- };
1160
- };
1161
- }))) & ({} | ({
1162
- [x: string]: {
1163
- get: {
1164
- body: unknown;
1165
- params: {
1166
- organizationId: string;
1167
- };
1168
- query: unknown;
1169
- headers: unknown;
1170
- response: {
1171
- 404: "No OIDC connection is configured for this organization";
1172
- 200: Response;
1173
- 422: {
1174
- type: "validation";
1175
- on: string;
1176
- summary?: string;
1177
- message?: string;
1178
- found?: unknown;
1179
- property?: string;
1180
- expected?: string;
1181
- };
1182
- };
1183
- };
1184
- };
1185
- } & {
1186
- [x: string]: {
1187
- get: {
1188
- body: unknown;
1189
- params: {
1190
- organizationId: string;
1191
- };
1192
- query: {
1193
- code?: string | undefined;
1194
- state?: string | undefined;
1195
- };
1196
- headers: unknown;
1197
- response: {
1198
- 400: "SSO session cookies are missing" | "Invalid SSO callback request" | "SSO organization mismatch" | "OIDC token response is missing an id_token";
1199
- 404: "No OIDC connection is configured for this organization";
1200
- 200: Response;
1201
- 422: {
1202
- type: "validation";
1203
- on: string;
1204
- summary?: string;
1205
- message?: string;
1206
- found?: unknown;
1207
- property?: string;
1208
- expected?: string;
1209
- };
1210
- 500: "OIDC sign-in failed";
1211
- };
1212
- };
1213
- };
1214
- }))) & ({} | ({
1215
- [x: string]: {
1216
- get: {
1217
- body: unknown;
1218
- params: {
1219
- organizationId: string;
1220
- };
1221
- query: unknown;
1222
- headers: unknown;
1223
- response: {
1224
- 404: "No SAML connection is configured for this organization";
1225
- 200: Response;
1226
- 422: {
1227
- type: "validation";
1228
- on: string;
1229
- summary?: string;
1230
- message?: string;
1231
- found?: unknown;
1232
- property?: string;
1233
- expected?: string;
1234
- };
1235
- };
1236
- };
1237
- };
1238
- } & {
1239
- [x: string]: {
1240
- post: {
1241
- body: {
1242
- RelayState?: string | undefined;
1243
- SAMLResponse: string;
1244
- };
1245
- params: {
1246
- organizationId: string;
1247
- };
1248
- query: unknown;
1249
- headers: unknown;
1250
- response: {
1251
- 404: "No SAML connection is configured for this organization";
1252
- 200: Response;
1253
- 422: {
1254
- type: "validation";
1255
- on: string;
1256
- summary?: string;
1257
- message?: string;
1258
- found?: unknown;
1259
- property?: string;
1260
- expected?: string;
1261
- };
1262
- 500: "SAML sign-in failed";
1263
- };
1264
- };
1265
- };
1266
- } & {
1267
- [x: string]: {
1268
- get: {
1269
- body: unknown;
1270
- params: {
1271
- organizationId: string;
1272
- };
1273
- query: unknown;
1274
- headers: unknown;
1275
- response: {
1276
- 404: "No SAML connection is configured for this organization";
1277
- 200: Response;
1278
- 422: {
1279
- type: "validation";
1280
- on: string;
1281
- summary?: string;
1282
- message?: string;
1283
- found?: unknown;
1284
- property?: string;
1285
- expected?: string;
1286
- };
1287
- };
1288
- };
1289
- };
1290
- } & {
1291
- [x: string]: {
1292
- get: {
1293
- body: unknown;
1294
- params: {
1295
- organizationId: string;
1296
- };
1297
- query: unknown;
1298
- headers: unknown;
1299
- response: {
1300
- 200: Response;
1301
- 422: {
1302
- type: "validation";
1303
- on: string;
1304
- summary?: string;
1305
- message?: string;
1306
- found?: unknown;
1307
- property?: string;
1308
- expected?: string;
1309
- };
1310
- };
1311
- };
1312
- };
1313
- } & {
1314
- [x: string]: {
1315
- get: {
1316
- body: unknown;
1317
- params: {
1318
- organizationId: string;
1319
- };
1320
- query: {
1321
- RelayState?: string | undefined;
1322
- SAMLResponse?: string | undefined;
1323
- SAMLRequest?: string | undefined;
1324
- SigAlg?: string | undefined;
1325
- Signature?: string | undefined;
1326
- };
1327
- headers: unknown;
1328
- response: {
1329
- 400: "Missing SAMLRequest or SAMLResponse" | "Invalid SAML LogoutRequest";
1330
- 501: "SAML Single Logout is not configured";
1331
- 404: "No SAML connection is configured for this organization";
1332
- 200: Response;
1333
- 422: {
1334
- type: "validation";
1335
- on: string;
1336
- summary?: string;
1337
- message?: string;
1338
- found?: unknown;
1339
- property?: string;
1340
- expected?: string;
1341
- };
1342
- 500: "SAML logout failed";
1343
- };
1344
- };
1345
- };
1346
- }))) & ({} | {
1347
- [x: string]: {
1348
- get: {
1349
- body: unknown;
1350
- params: {};
1351
- query: {
1352
- email?: string | undefined;
1353
- };
1354
- headers: unknown;
1355
- response: {
1356
- 400: "An \"email\" query parameter is required" | "A valid email address is required";
1357
- 404: "No SSO organization is configured for this email domain" | "No SSO connection is configured for this organization";
1358
- 200: Response;
1359
- 422: {
1360
- type: "validation";
1361
- on: string;
1362
- summary?: string;
1363
- message?: string;
1364
- found?: unknown;
1365
- property?: string;
1366
- expected?: string;
1367
- };
1368
- };
1369
- };
1370
- };
1371
- })) & ({} | ({
1372
- [x: string]: {
1373
- get: {
1374
- body: unknown;
1375
- params: {};
1376
- query: unknown;
1377
- headers: unknown;
1378
- response: {
1379
- 200: Response;
1380
- };
1381
- };
1382
- };
1383
- } & {
1384
- [x: string]: {
1385
- post: {
1386
- body: unknown;
1387
- params: {};
1388
- query: unknown;
1389
- headers: unknown;
1390
- response: {
1391
- 200: Response;
1392
- };
1393
- };
1394
- };
1395
- } & {
1396
- [x: string]: {
1397
- get: {
1398
- body: unknown;
1399
- params: {};
1400
- query: {
1401
- filter?: string | undefined;
1402
- };
1403
- headers: unknown;
1404
- response: {
1405
- 200: Response;
1406
- 422: {
1407
- type: "validation";
1408
- on: string;
1409
- summary?: string;
1410
- message?: string;
1411
- found?: unknown;
1412
- property?: string;
1413
- expected?: string;
1414
- };
1415
- };
1416
- };
1417
- };
1418
- } & {
1419
- [x: string]: {
1420
- get: {
1421
- body: unknown;
1422
- params: {
1423
- id: string;
1424
- };
1425
- query: unknown;
1426
- headers: unknown;
1427
- response: {
1428
- 200: Response;
1429
- 422: {
1430
- type: "validation";
1431
- on: string;
1432
- summary?: string;
1433
- message?: string;
1434
- found?: unknown;
1435
- property?: string;
1436
- expected?: string;
1437
- };
1438
- };
1439
- };
1440
- };
1441
- } & {
1442
- [x: string]: {
1443
- put: {
1444
- body: unknown;
1445
- params: {
1446
- id: string;
1447
- };
1448
- query: unknown;
1449
- headers: unknown;
1450
- response: {
1451
- 200: Response;
1452
- 422: {
1453
- type: "validation";
1454
- on: string;
1455
- summary?: string;
1456
- message?: string;
1457
- found?: unknown;
1458
- property?: string;
1459
- expected?: string;
1460
- };
1461
- };
1462
- };
1463
- };
1464
- } & {
1465
- [x: string]: {
1466
- patch: {
1467
- body: unknown;
1468
- params: {
1469
- id: string;
1470
- };
1471
- query: unknown;
1472
- headers: unknown;
1473
- response: {
1474
- 200: Response;
1475
- 422: {
1476
- type: "validation";
1477
- on: string;
1478
- summary?: string;
1479
- message?: string;
1480
- found?: unknown;
1481
- property?: string;
1482
- expected?: string;
1483
- };
1484
- };
1485
- };
1486
- };
1487
- } & {
1488
- [x: string]: {
1489
- delete: {
1490
- body: unknown;
1491
- params: {
1492
- id: string;
1493
- };
1494
- query: unknown;
1495
- headers: unknown;
1496
- response: {
1497
- 200: Response;
1498
- 422: {
1499
- type: "validation";
1500
- on: string;
1501
- summary?: string;
1502
- message?: string;
1503
- found?: unknown;
1504
- property?: string;
1505
- expected?: string;
1506
- };
1507
- };
1508
- };
1509
- };
1510
- } & {
1511
- [x: string]: {
1512
- post: {
1513
- body: unknown;
1514
- params: {};
1515
- query: unknown;
1516
- headers: unknown;
1517
- response: {
1518
- 200: Response;
1519
- };
1520
- };
1521
- };
1522
- } & {
1523
- [x: string]: {
1524
- get: {
1525
- body: unknown;
1526
- params: {};
1527
- query: {
1528
- filter?: string | undefined;
1529
- };
1530
- headers: unknown;
1531
- response: {
1532
- 200: Response;
1533
- 422: {
1534
- type: "validation";
1535
- on: string;
1536
- summary?: string;
1537
- message?: string;
1538
- found?: unknown;
1539
- property?: string;
1540
- expected?: string;
1541
- };
1542
- };
1543
- };
1544
- };
1545
- } & {
1546
- [x: string]: {
1547
- get: {
1548
- body: unknown;
1549
- params: {
1550
- id: string;
1551
- };
1552
- query: unknown;
1553
- headers: unknown;
1554
- response: {
1555
- 200: Response;
1556
- 422: {
1557
- type: "validation";
1558
- on: string;
1559
- summary?: string;
1560
- message?: string;
1561
- found?: unknown;
1562
- property?: string;
1563
- expected?: string;
1564
- };
1565
- };
1566
- };
1567
- };
1568
- } & {
1569
- [x: string]: {
1570
- put: {
1571
- body: unknown;
1572
- params: {
1573
- id: string;
1574
- };
1575
- query: unknown;
1576
- headers: unknown;
1577
- response: {
1578
- 200: Response;
1579
- 422: {
1580
- type: "validation";
1581
- on: string;
1582
- summary?: string;
1583
- message?: string;
1584
- found?: unknown;
1585
- property?: string;
1586
- expected?: string;
1587
- };
1588
- };
1589
- };
1590
- };
1591
- } & {
1592
- [x: string]: {
1593
- patch: {
1594
- body: unknown;
1595
- params: {
1596
- id: string;
1597
- };
1598
- query: unknown;
1599
- headers: unknown;
1600
- response: {
1601
- 200: Response;
1602
- 422: {
1603
- type: "validation";
1604
- on: string;
1605
- summary?: string;
1606
- message?: string;
1607
- found?: unknown;
1608
- property?: string;
1609
- expected?: string;
1610
- };
1611
- };
1612
- };
1613
- };
1614
- } & {
1615
- [x: string]: {
1616
- delete: {
1617
- body: unknown;
1618
- params: {
1619
- id: string;
1620
- };
1621
- query: unknown;
1622
- headers: unknown;
1623
- response: {
1624
- 200: Response;
1625
- 422: {
1626
- type: "validation";
1627
- on: string;
1628
- summary?: string;
1629
- message?: string;
1630
- found?: unknown;
1631
- property?: string;
1632
- expected?: string;
1633
- };
1634
- };
1635
- };
1636
- };
1637
- } & {
1638
- [x: string]: {
1639
- get: {
1640
- body: unknown;
1641
- params: {};
1642
- query: unknown;
1643
- headers: unknown;
1644
- response: {
1645
- 200: Response;
1646
- };
1647
- };
1648
- };
1649
- } & {
1650
- [x: string]: {
1651
- get: {
1652
- body: unknown;
1653
- params: {
1654
- id: string;
1655
- };
1656
- query: unknown;
1657
- headers: unknown;
1658
- response: {
1659
- 200: Response;
1660
- 422: {
1661
- type: "validation";
1662
- on: string;
1663
- summary?: string;
1664
- message?: string;
1665
- found?: unknown;
1666
- property?: string;
1667
- expected?: string;
1668
- };
1669
- };
1670
- };
1671
- };
1672
- } & {
1673
- [x: string]: {
1674
- get: {
1675
- body: unknown;
1676
- params: {};
1677
- query: unknown;
1678
- headers: unknown;
1679
- response: {
1680
- 200: Response;
1681
- };
1682
- };
1683
- };
1684
- } & {
1685
- [x: string]: {
1686
- get: {
1687
- body: unknown;
1688
- params: {
1689
- id: string;
1690
- };
1691
- query: unknown;
1692
- headers: unknown;
1693
- response: {
1694
- 200: Response;
1695
- 422: {
1696
- type: "validation";
1697
- on: string;
1698
- summary?: string;
1699
- message?: string;
1700
- found?: unknown;
1701
- property?: string;
1702
- expected?: string;
1703
- };
1704
- };
1705
- };
1706
- };
1707
- }))) & ({} | {
1708
- [x: string]: {
1709
- post: {
1710
- body: {
1711
- client_id?: string | undefined;
1712
- scope?: string | undefined;
1713
- grant_type?: string | undefined;
1714
- client_secret?: string | undefined;
1715
- };
1716
- params: {};
1717
- query: unknown;
1718
- headers: unknown;
1719
- response: {
1720
- 200: Response;
1721
- 422: {
1722
- type: "validation";
1723
- on: string;
1724
- summary?: string;
1725
- message?: string;
1726
- found?: unknown;
1727
- property?: string;
1728
- expected?: string;
1729
- };
1730
- };
1731
- };
1732
- };
1733
- })) & ({} | ({
1734
- [x: string]: {
1735
- get: {
1736
- body: unknown;
1737
- params: {};
1738
- query: {
1739
- client_id?: string | undefined;
1740
- scope?: string | undefined;
1741
- nonce?: string | undefined;
1742
- claims?: string | undefined;
1743
- resource?: string | undefined;
1744
- request?: string | undefined;
1745
- redirect_uri?: string | undefined;
1746
- acr_values?: string | undefined;
1747
- code_challenge?: string | undefined;
1748
- code_challenge_method?: string | undefined;
1749
- id_token_hint?: string | undefined;
1750
- max_age?: string | undefined;
1751
- prompt?: string | undefined;
1752
- request_uri?: string | undefined;
1753
- response_mode?: string | undefined;
1754
- response_type?: string | undefined;
1755
- state?: string | undefined;
1756
- };
1757
- headers: unknown;
1758
- response: {
1759
- 200: Response;
1760
- 422: {
1761
- type: "validation";
1762
- on: string;
1763
- summary?: string;
1764
- message?: string;
1765
- found?: unknown;
1766
- property?: string;
1767
- expected?: string;
1768
- };
1769
- };
1770
- };
1771
- };
1772
- } & {
1773
- [x: string]: {
1774
- post: {
1775
- body: {
1776
- code?: string | undefined;
1777
- client_id?: string | undefined;
1778
- scope?: string | undefined;
1779
- audience?: string | undefined;
1780
- resource?: string | undefined;
1781
- refresh_token?: string | undefined;
1782
- device_code?: string | undefined;
1783
- auth_req_id?: string | undefined;
1784
- grant_type?: string | undefined;
1785
- claim_token?: string | undefined;
1786
- assertion?: string | undefined;
1787
- client_secret?: string | undefined;
1788
- redirect_uri?: string | undefined;
1789
- client_assertion?: string | undefined;
1790
- client_assertion_type?: string | undefined;
1791
- code_verifier?: string | undefined;
1792
- 'pre-authorized_code'?: string | undefined;
1793
- subject_token?: string | undefined;
1794
- subject_token_type?: string | undefined;
1795
- };
1796
- params: {};
1797
- query: unknown;
1798
- headers: unknown;
1799
- response: {
1800
- 200: Response;
1801
- 422: {
1802
- type: "validation";
1803
- on: string;
1804
- summary?: string;
1805
- message?: string;
1806
- found?: unknown;
1807
- property?: string;
1808
- expected?: string;
1809
- };
1810
- };
1811
- };
1812
- };
1813
- } & {
1814
- [x: string]: {
1815
- post: {
1816
- body: {
1817
- client_id?: string | undefined;
1818
- scope?: string | undefined;
1819
- nonce?: string | undefined;
1820
- audience?: string | undefined;
1821
- claims?: string | undefined;
1822
- resource?: string | undefined;
1823
- client_secret?: string | undefined;
1824
- redirect_uri?: string | undefined;
1825
- acr_values?: string | undefined;
1826
- code_challenge?: string | undefined;
1827
- code_challenge_method?: string | undefined;
1828
- response_type?: string | undefined;
1829
- state?: string | undefined;
1830
- client_assertion?: string | undefined;
1831
- client_assertion_type?: string | undefined;
1832
- };
1833
- params: {};
1834
- query: unknown;
1835
- headers: {
1836
- authorization?: string | undefined;
1837
- };
1838
- response: {
1839
- 200: Response;
1840
- 422: {
1841
- type: "validation";
1842
- on: string;
1843
- summary?: string;
1844
- message?: string;
1845
- found?: unknown;
1846
- property?: string;
1847
- expected?: string;
1848
- };
1849
- };
1850
- };
1851
- };
1852
- } & {
1853
- [x: string]: {
1854
- post: {
1855
- body: {
1856
- client_id?: string | undefined;
1857
- client_secret?: string | undefined;
1858
- token_type_hint?: string | undefined;
1859
- token: string;
1860
- };
1861
- params: {};
1862
- query: unknown;
1863
- headers: {
1864
- authorization?: string | undefined;
1865
- };
1866
- response: {
1867
- 200: Response;
1868
- 422: {
1869
- type: "validation";
1870
- on: string;
1871
- summary?: string;
1872
- message?: string;
1873
- found?: unknown;
1874
- property?: string;
1875
- expected?: string;
1876
- };
1877
- };
1878
- };
1879
- };
1880
- } & {
1881
- [x: string]: {
1882
- post: {
1883
- body: {
1884
- client_id?: string | undefined;
1885
- client_secret?: string | undefined;
1886
- token_type_hint?: string | undefined;
1887
- token: string;
1888
- };
1889
- params: {};
1890
- query: unknown;
1891
- headers: {
1892
- authorization?: string | undefined;
1893
- };
1894
- response: {
1895
- 200: Response;
1896
- 422: {
1897
- type: "validation";
1898
- on: string;
1899
- summary?: string;
1900
- message?: string;
1901
- found?: unknown;
1902
- property?: string;
1903
- expected?: string;
1904
- };
1905
- };
1906
- };
1907
- };
1908
- } & {
1909
- [x: string]: {
1910
- post: {
1911
- body: {
1912
- client_id?: string | undefined;
1913
- scope?: string | undefined;
1914
- client_secret?: string | undefined;
1915
- login_hint?: string | undefined;
1916
- binding_message?: string | undefined;
1917
- };
1918
- params: {};
1919
- query: unknown;
1920
- headers: {
1921
- authorization?: string | undefined;
1922
- };
1923
- response: {
1924
- 200: Response;
1925
- 422: {
1926
- type: "validation";
1927
- on: string;
1928
- summary?: string;
1929
- message?: string;
1930
- found?: unknown;
1931
- property?: string;
1932
- expected?: string;
1933
- };
1934
- };
1935
- };
1936
- };
1937
- } & {
1938
- [x: string]: {
1939
- post: {
1940
- body: {
1941
- client_id?: string | undefined;
1942
- scope?: string | undefined;
1943
- client_secret?: string | undefined;
1944
- };
1945
- params: {};
1946
- query: unknown;
1947
- headers: {
1948
- authorization?: string | undefined;
1949
- };
1950
- response: {
1951
- 200: Response;
1952
- 422: {
1953
- type: "validation";
1954
- on: string;
1955
- summary?: string;
1956
- message?: string;
1957
- found?: unknown;
1958
- property?: string;
1959
- expected?: string;
1960
- };
1961
- };
1962
- };
1963
- };
1964
- } & {
1965
- [x: string]: {
1966
- post: {
1967
- body: {
1968
- action?: "deny" | "approve" | undefined;
1969
- user_code: string;
1970
- };
1971
- params: {};
1972
- query: unknown;
1973
- headers: unknown;
1974
- response: {
1975
- 200: Response;
1976
- 422: {
1977
- type: "validation";
1978
- on: string;
1979
- summary?: string;
1980
- message?: string;
1981
- found?: unknown;
1982
- property?: string;
1983
- expected?: string;
1984
- };
1985
- };
1986
- };
1987
- };
1988
- } & {
1989
- [x: string]: {
1990
- get: {
1991
- body: unknown;
1992
- params: {};
1993
- query: {
1994
- client_id?: string | undefined;
1995
- id_token_hint?: string | undefined;
1996
- state?: string | undefined;
1997
- post_logout_redirect_uri?: string | undefined;
1998
- };
1999
- headers: unknown;
2000
- response: {
2001
- 200: Response;
2002
- 422: {
2003
- type: "validation";
2004
- on: string;
2005
- summary?: string;
2006
- message?: string;
2007
- found?: unknown;
2008
- property?: string;
2009
- expected?: string;
2010
- };
2011
- };
2012
- };
2013
- };
2014
- } & {
2015
- [x: string]: {
2016
- post: {
2017
- body: {
2018
- client_id?: string | undefined;
2019
- id_token_hint?: string | undefined;
2020
- state?: string | undefined;
2021
- post_logout_redirect_uri?: string | undefined;
2022
- };
2023
- params: {};
2024
- query: unknown;
2025
- headers: unknown;
2026
- response: {
2027
- 200: Response;
2028
- 422: {
2029
- type: "validation";
2030
- on: string;
2031
- summary?: string;
2032
- message?: string;
2033
- found?: unknown;
2034
- property?: string;
2035
- expected?: string;
2036
- };
2037
- };
2038
- };
2039
- };
2040
- } & {
2041
- [x: string]: {
2042
- post: {
2043
- body: {
2044
- jwks?: any;
2045
- scope?: string | undefined;
2046
- backchannel_logout_uri?: string | undefined;
2047
- client_name?: string | undefined;
2048
- grant_types?: string[] | undefined;
2049
- jwks_uri?: string | undefined;
2050
- post_logout_redirect_uris?: string[] | undefined;
2051
- redirect_uris?: string[] | undefined;
2052
- };
2053
- params: {};
2054
- query: unknown;
2055
- headers: {
2056
- authorization?: string | undefined;
2057
- };
2058
- response: {
2059
- 200: Response;
2060
- 422: {
2061
- type: "validation";
2062
- on: string;
2063
- summary?: string;
2064
- message?: string;
2065
- found?: unknown;
2066
- property?: string;
2067
- expected?: string;
2068
- };
2069
- };
2070
- };
2071
- };
2072
- } & {
2073
- [x: string]: {
2074
- ":clientId": {
2075
- get: {
2076
- body: unknown;
2077
- params: {
2078
- clientId: string;
2079
- };
2080
- query: unknown;
2081
- headers: {
2082
- authorization?: string | undefined;
2083
- };
2084
- response: {
2085
- 200: Response;
2086
- 422: {
2087
- type: "validation";
2088
- on: string;
2089
- summary?: string;
2090
- message?: string;
2091
- found?: unknown;
2092
- property?: string;
2093
- expected?: string;
2094
- };
2095
- };
2096
- };
2097
- };
2098
- };
2099
- } & {
2100
- [x: string]: {
2101
- ":clientId": {
2102
- put: {
2103
- body: {
2104
- jwks?: any;
2105
- scope?: string | undefined;
2106
- backchannel_logout_uri?: string | undefined;
2107
- client_name?: string | undefined;
2108
- grant_types?: string[] | undefined;
2109
- jwks_uri?: string | undefined;
2110
- post_logout_redirect_uris?: string[] | undefined;
2111
- redirect_uris?: string[] | undefined;
2112
- };
2113
- params: {
2114
- clientId: string;
2115
- };
2116
- query: unknown;
2117
- headers: {
2118
- authorization?: string | undefined;
2119
- };
2120
- response: {
2121
- 200: Response;
2122
- 422: {
2123
- type: "validation";
2124
- on: string;
2125
- summary?: string;
2126
- message?: string;
2127
- found?: unknown;
2128
- property?: string;
2129
- expected?: string;
2130
- };
2131
- };
2132
- };
2133
- };
2134
- };
2135
- } & {
2136
- [x: string]: {
2137
- ":clientId": {
2138
- delete: {
2139
- body: unknown;
2140
- params: {
2141
- clientId: string;
2142
- };
2143
- query: unknown;
2144
- headers: {
2145
- authorization?: string | undefined;
2146
- };
2147
- response: {
2148
- 200: Response;
2149
- 422: {
2150
- type: "validation";
2151
- on: string;
2152
- summary?: string;
2153
- message?: string;
2154
- found?: unknown;
2155
- property?: string;
2156
- expected?: string;
2157
- };
2158
- };
2159
- };
2160
- };
2161
- };
2162
- } & {
2163
- [x: string]: {
2164
- get: {
2165
- body: unknown;
2166
- params: {};
2167
- query: unknown;
2168
- headers: {
2169
- authorization?: string | undefined;
2170
- };
2171
- response: {
2172
- 200: Response;
2173
- 422: {
2174
- type: "validation";
2175
- on: string;
2176
- summary?: string;
2177
- message?: string;
2178
- found?: unknown;
2179
- property?: string;
2180
- expected?: string;
2181
- };
2182
- };
2183
- };
2184
- };
2185
- } & {
2186
- [x: string]: {
2187
- post: {
2188
- body: {
2189
- access_token?: string | undefined;
2190
- };
2191
- params: {};
2192
- query: unknown;
2193
- headers: {
2194
- authorization?: string | undefined;
2195
- };
2196
- response: {
2197
- 200: Response;
2198
- 422: {
2199
- type: "validation";
2200
- on: string;
2201
- summary?: string;
2202
- message?: string;
2203
- found?: unknown;
2204
- property?: string;
2205
- expected?: string;
2206
- };
2207
- };
2208
- };
2209
- };
2210
- } & {
2211
- [x: string]: {
2212
- get: {
2213
- body: unknown;
2214
- params: {};
2215
- query: unknown;
2216
- headers: unknown;
2217
- response: {
2218
- 200: {
2219
- keys: {
2220
- alg: string;
2221
- crv: string | undefined;
2222
- kid: string;
2223
- kty: string | undefined;
2224
- use: string;
2225
- x: string | undefined;
2226
- y: string | undefined;
2227
- }[];
2228
- };
2229
- };
2230
- };
2231
- };
2232
- } & {
2233
- ".well-known": {
2234
- "openid-configuration": {
2235
- get: {
2236
- body: unknown;
2237
- params: {};
2238
- query: unknown;
2239
- headers: unknown;
2240
- response: {
2241
- 200: Record<string, unknown>;
2242
- };
2243
- };
2244
- };
2245
- };
2246
- } & {
2247
- ".well-known": {
2248
- "oauth-authorization-server": {
2249
- get: {
2250
- body: unknown;
2251
- params: {};
2252
- query: unknown;
2253
- headers: unknown;
2254
- response: {
2255
- 200: Record<string, unknown>;
2256
- };
2257
- };
2258
- };
2259
- };
2260
- }))) & ({} | ({
2261
- [x: string]: {
2262
- get: {
2263
- body: unknown;
2264
- params: {};
2265
- query: unknown;
2266
- headers: unknown;
2267
- response: {
2268
- 401: "Authentication required";
2269
- 200: {
2270
- readonly organizations: {
2271
- membership: import(".").OrganizationMembership;
2272
- organization: import(".").Organization | undefined;
2273
- }[];
2274
- };
2275
- 422: {
2276
- type: "validation";
2277
- on: string;
2278
- summary?: string;
2279
- message?: string;
2280
- found?: unknown;
2281
- property?: string;
2282
- expected?: string;
2283
- };
2284
- };
2285
- };
2286
- };
2287
- } & {
2288
- [x: string]: {
2289
- post: {
2290
- body: {
2291
- metadata?: {} | undefined;
2292
- name: string;
2293
- };
2294
- params: {};
2295
- query: unknown;
2296
- headers: unknown;
2297
- response: {
2298
- 401: "Authentication required";
2299
- 403: "Cannot create organizations";
2300
- 200: {
2301
- readonly organization: import(".").Organization;
2302
- };
2303
- 422: {
2304
- type: "validation";
2305
- on: string;
2306
- summary?: string;
2307
- message?: string;
2308
- found?: unknown;
2309
- property?: string;
2310
- expected?: string;
2311
- };
2312
- };
2313
- };
2314
- };
2315
- } & {
2316
- [x: string]: {
2317
- ":organizationId": {
2318
- invitations: {
2319
- post: {
2320
- body: {
2321
- roles?: string[] | undefined;
2322
- email: string;
2323
- };
2324
- params: {
2325
- organizationId: string;
2326
- };
2327
- query: unknown;
2328
- headers: unknown;
2329
- response: {
2330
- 401: "Authentication required";
2331
- 403: "Cannot manage members";
2332
- 200: {
2333
- readonly invitationId: string;
2334
- readonly token: string;
2335
- };
2336
- 422: {
2337
- type: "validation";
2338
- on: string;
2339
- summary?: string;
2340
- message?: string;
2341
- found?: unknown;
2342
- property?: string;
2343
- expected?: string;
2344
- };
2345
- };
2346
- };
2347
- };
2348
- };
2349
- };
2350
- } & {
2351
- [x: string]: {
2352
- ":organizationId": {
2353
- invitations: {
2354
- get: {
2355
- body: unknown;
2356
- params: {
2357
- organizationId: string;
2358
- };
2359
- query: unknown;
2360
- headers: unknown;
2361
- response: {
2362
- 401: "Authentication required";
2363
- 403: "Cannot manage members";
2364
- 200: {
2365
- readonly invitations: {
2366
- email: string;
2367
- expiresAt: number;
2368
- invitationId: string;
2369
- roles: string[];
2370
- state: import(".").InvitationState;
2371
- }[];
2372
- };
2373
- 422: {
2374
- type: "validation";
2375
- on: string;
2376
- summary?: string;
2377
- message?: string;
2378
- found?: unknown;
2379
- property?: string;
2380
- expected?: string;
2381
- };
2382
- };
2383
- };
2384
- };
2385
- };
2386
- };
2387
- } & {
2388
- [x: string]: {
2389
- ":organizationId": {
2390
- invitations: {
2391
- ":invitationId": {
2392
- delete: {
2393
- body: unknown;
2394
- params: {
2395
- organizationId: string;
2396
- invitationId: string;
2397
- };
2398
- query: unknown;
2399
- headers: unknown;
2400
- response: {
2401
- 401: "Authentication required";
2402
- 403: "Cannot manage members";
2403
- 404: "Invitation not found";
2404
- 200: {
2405
- readonly revoked: string;
2406
- };
2407
- 422: {
2408
- type: "validation";
2409
- on: string;
2410
- summary?: string;
2411
- message?: string;
2412
- found?: unknown;
2413
- property?: string;
2414
- expected?: string;
2415
- };
2416
- };
2417
- };
2418
- };
2419
- };
2420
- };
2421
- };
2422
- } & {
2423
- [x: string]: {
2424
- invitations: {
2425
- accept: {
2426
- post: {
2427
- body: {
2428
- token: string;
2429
- };
2430
- params: {};
2431
- query: unknown;
2432
- headers: unknown;
2433
- response: {
2434
- 400: "Invalid or expired invitation";
2435
- 401: "Authentication required";
2436
- 200: {
2437
- readonly organizationId: string;
2438
- readonly roles: string[];
2439
- };
2440
- 422: {
2441
- type: "validation";
2442
- on: string;
2443
- summary?: string;
2444
- message?: string;
2445
- found?: unknown;
2446
- property?: string;
2447
- expected?: string;
2448
- };
2449
- };
2450
- };
2451
- };
2452
- };
2453
- };
2454
- } & {
2455
- [x: string]: {
2456
- ":organizationId": {
2457
- members: {
2458
- get: {
2459
- body: unknown;
2460
- params: {
2461
- organizationId: string;
2462
- };
2463
- query: unknown;
2464
- headers: unknown;
2465
- response: {
2466
- 401: "Authentication required";
2467
- 403: "Not a member";
2468
- 200: {
2469
- readonly members: import(".").OrganizationMembership[];
2470
- };
2471
- 422: {
2472
- type: "validation";
2473
- on: string;
2474
- summary?: string;
2475
- message?: string;
2476
- found?: unknown;
2477
- property?: string;
2478
- expected?: string;
2479
- };
2480
- };
2481
- };
2482
- };
2483
- };
2484
- };
2485
- } & {
2486
- [x: string]: {
2487
- ":organizationId": {
2488
- members: {
2489
- ":userId": {
2490
- delete: {
2491
- body: unknown;
2492
- params: {
2493
- userId: string;
2494
- organizationId: string;
2495
- };
2496
- query: unknown;
2497
- headers: unknown;
2498
- response: {
2499
- 401: "Authentication required";
2500
- 403: "Cannot manage members";
2501
- 200: {
2502
- readonly removed: string;
2503
- };
2504
- 422: {
2505
- type: "validation";
2506
- on: string;
2507
- summary?: string;
2508
- message?: string;
2509
- found?: unknown;
2510
- property?: string;
2511
- expected?: string;
2512
- };
2513
- };
2514
- };
2515
- };
2516
- };
2517
- };
2518
- };
2519
- }))) & ({} | ({
2520
- [x: string]: {
2521
- ":organizationId": {
2522
- get: {
2523
- body: unknown;
2524
- params: {
2525
- organizationId: string;
2526
- };
2527
- query: unknown;
2528
- headers: unknown;
2529
- response: {
2530
- 401: "Authentication required";
2531
- 403: "Cannot manage roles";
2532
- 200: {
2533
- readonly roles: readonly import(".").Role[];
2534
- };
2535
- 422: {
2536
- type: "validation";
2537
- on: string;
2538
- summary?: string;
2539
- message?: string;
2540
- found?: unknown;
2541
- property?: string;
2542
- expected?: string;
2543
- };
2544
- };
2545
- };
2546
- };
2547
- };
2548
- } & {
2549
- [x: string]: {
2550
- ":organizationId": {
2551
- members: {
2552
- ":userId": {
2553
- put: {
2554
- body: {
2555
- roles: string[];
2556
- };
2557
- params: {
2558
- userId: string;
2559
- organizationId: string;
2560
- };
2561
- query: unknown;
2562
- headers: unknown;
2563
- response: {
2564
- 401: "Authentication required";
2565
- 403: "Cannot manage roles";
2566
- 404: "Membership not found";
2567
- 200: {
2568
- readonly roles: string[];
2569
- };
2570
- 422: {
2571
- type: "validation";
2572
- on: string;
2573
- summary?: string;
2574
- message?: string;
2575
- found?: unknown;
2576
- property?: string;
2577
- expected?: string;
2578
- };
2579
- };
2580
- };
2581
- };
2582
- };
2583
- };
2584
- };
2585
- }))) & ({} | ({
2586
- [x: string]: {
2587
- session: {
2588
- get: {
2589
- body: unknown;
2590
- params: {};
2591
- query: unknown;
2592
- headers: unknown;
2593
- response: {
2594
- 401: "Invalid or expired setup link";
2595
- 200: {
2596
- readonly capabilities: import(".").SetupCapability[];
2597
- readonly configured: {
2598
- readonly oidc: boolean;
2599
- readonly saml: boolean;
2600
- };
2601
- readonly expiresAt: number;
2602
- readonly oidc: {
2603
- redirectUri: string;
2604
- } | undefined;
2605
- readonly organizationId: string;
2606
- readonly saml: {
2607
- acsUrl: string;
2608
- entityId: string;
2609
- metadataUrl: string;
2610
- } | undefined;
2611
- readonly scim: {
2612
- baseUrl: string;
2613
- } | undefined;
2614
- };
2615
- };
2616
- };
2617
- };
2618
- };
2619
- } & {
2620
- [x: string]: {
2621
- connection: {
2622
- saml: {
2623
- put: {
2624
- body: {
2625
- idpSloUrl?: string | undefined;
2626
- idpEntityId: string;
2627
- idpSsoUrl: string;
2628
- idpX509Cert: string;
2629
- };
2630
- params: {};
2631
- query: unknown;
2632
- headers: unknown;
2633
- response: {
2634
- 401: "Invalid or expired setup link";
2635
- 403: "This setup link cannot configure SAML";
2636
- 501: "SSO is not configured";
2637
- 200: {
2638
- readonly configured: true;
2639
- readonly type: "saml";
2640
- };
2641
- 422: {
2642
- type: "validation";
2643
- on: string;
2644
- summary?: string;
2645
- message?: string;
2646
- found?: unknown;
2647
- property?: string;
2648
- expected?: string;
2649
- };
2650
- };
2651
- };
2652
- };
2653
- };
2654
- };
2655
- } & {
2656
- [x: string]: {
2657
- connection: {
2658
- oidc: {
2659
- put: {
2660
- body: {
2661
- scopes?: string[] | undefined;
2662
- redirectUri?: string | undefined;
2663
- issuer: string;
2664
- clientId: string;
2665
- clientSecret: string;
2666
- };
2667
- params: {};
2668
- query: unknown;
2669
- headers: unknown;
2670
- response: {
2671
- 401: "Invalid or expired setup link";
2672
- 403: "This setup link cannot configure OIDC";
2673
- 501: "SSO is not configured";
2674
- 200: {
2675
- readonly configured: true;
2676
- readonly type: "oidc";
2677
- };
2678
- 422: {
2679
- type: "validation";
2680
- on: string;
2681
- summary?: string;
2682
- message?: string;
2683
- found?: unknown;
2684
- property?: string;
2685
- expected?: string;
2686
- };
2687
- };
2688
- };
2689
- };
2690
- };
2691
- };
2692
- } & {
2693
- [x: string]: {
2694
- scim: {
2695
- token: {
2696
- post: {
2697
- body: unknown;
2698
- params: {};
2699
- query: unknown;
2700
- headers: unknown;
2701
- response: {
2702
- 401: "Invalid or expired setup link";
2703
- 403: "This setup link cannot configure SCIM";
2704
- 501: "SCIM is not configured";
2705
- 200: {
2706
- readonly baseUrl: `${string}/${string}`;
2707
- readonly token: string;
2708
- readonly tokenId: string;
2709
- };
2710
- };
2711
- };
2712
- };
2713
- };
2714
- };
2715
- }))) & ({} | ({
2716
- [x: string]: {
2717
- register: {
2718
- options: {
2719
- post: {
2720
- body: unknown;
2721
- params: {};
2722
- query: unknown;
2723
- headers: unknown;
2724
- response: {
2725
- 401: "Authentication required";
2726
- 200: {
2727
- [x: string]: unknown;
2728
- };
2729
- 422: {
2730
- type: "validation";
2731
- on: string;
2732
- summary?: string;
2733
- message?: string;
2734
- found?: unknown;
2735
- property?: string;
2736
- expected?: string;
2737
- };
2738
- };
2739
- };
2740
- };
2741
- };
2742
- };
2743
- } & {
2744
- [x: string]: {
2745
- register: {
2746
- verify: {
2747
- post: {
2748
- body: {};
2749
- params: {};
2750
- query: unknown;
2751
- headers: unknown;
2752
- response: {
2753
- 400: "No registration challenge in progress" | "WebAuthn registration failed";
2754
- 401: "Authentication required";
2755
- 200: {
2756
- readonly credentialId: string;
2757
- readonly verified: true;
2758
- };
2759
- 422: {
2760
- type: "validation";
2761
- on: string;
2762
- summary?: string;
2763
- message?: string;
2764
- found?: unknown;
2765
- property?: string;
2766
- expected?: string;
2767
- };
2768
- };
2769
- };
2770
- };
2771
- };
2772
- };
2773
- } & {
2774
- [x: string]: {
2775
- authenticate: {
2776
- options: {
2777
- post: {
2778
- body: unknown;
2779
- params: {};
2780
- query: unknown;
2781
- headers: unknown;
2782
- response: {
2783
- 200: {
2784
- [x: string]: unknown;
2785
- };
2786
- 422: {
2787
- type: "validation";
2788
- on: string;
2789
- summary?: string;
2790
- message?: string;
2791
- found?: unknown;
2792
- property?: string;
2793
- expected?: string;
2794
- };
2795
- };
2796
- };
2797
- };
2798
- };
2799
- };
2800
- } & {
2801
- [x: string]: {
2802
- authenticate: {
2803
- verify: {
2804
- post: {
2805
- body: {
2806
- id: string;
2807
- };
2808
- params: {};
2809
- query: unknown;
2810
- headers: unknown;
2811
- response: {
2812
- 400: "No authentication challenge in progress";
2813
- 401: "Unknown credential" | "WebAuthn authentication failed";
2814
- 200: {
2815
- readonly status: "authenticated";
2816
- };
2817
- 422: {
2818
- type: "validation";
2819
- on: string;
2820
- summary?: string;
2821
- message?: string;
2822
- found?: unknown;
2823
- property?: string;
2824
- expected?: string;
2825
- };
2826
- };
2827
- };
2828
- };
2829
- };
2830
- };
2831
- }))) & ({} | ({
2832
- [x: string]: {
2833
- export: {
2834
- get: {
2835
- body: unknown;
2836
- params: {};
2837
- query: unknown;
2838
- headers: unknown;
2839
- response: {
2840
- 401: "Authentication required";
2841
- 200: {
2842
- [x: string]: unknown;
2843
- };
2844
- 422: {
2845
- type: "validation";
2846
- on: string;
2847
- summary?: string;
2848
- message?: string;
2849
- found?: unknown;
2850
- property?: string;
2851
- expected?: string;
2852
- };
2853
- };
2854
- };
2855
- };
2856
- };
2857
- } & {
2858
- [x: string]: {
2859
- delete: {
2860
- body: unknown;
2861
- params: {};
2862
- query: unknown;
2863
- headers: unknown;
2864
- response: {
2865
- 401: "Authentication required";
2866
- 200: {
2867
- readonly deleted: true;
2868
- };
2869
- 422: {
2870
- type: "validation";
2871
- on: string;
2872
- summary?: string;
2873
- message?: string;
2874
- found?: unknown;
2875
- property?: string;
2876
- expected?: string;
2877
- };
2878
- };
2879
- };
2880
- };
2881
- }))) & ({} | ({
2882
- htmx: {
2883
- login: {
2884
- get: {
2885
- body: unknown;
2886
- params: {};
2887
- query: unknown;
2888
- headers: unknown;
2889
- response: {
2890
- 200: Response;
2891
- 422: {
2892
- type: "validation";
2893
- on: string;
2894
- summary?: string;
2895
- message?: string;
2896
- found?: unknown;
2897
- property?: string;
2898
- expected?: string;
2899
- };
2900
- };
2901
- };
2902
- };
2903
- };
2904
- } & {
2905
- htmx: {
2906
- link: {
2907
- get: {
2908
- body: unknown;
2909
- params: {};
2910
- query: unknown;
2911
- headers: unknown;
2912
- response: {
2913
- 200: Response;
2914
- 422: {
2915
- type: "validation";
2916
- on: string;
2917
- summary?: string;
2918
- message?: string;
2919
- found?: unknown;
2920
- property?: string;
2921
- expected?: string;
2922
- };
2923
- };
2924
- };
2925
- };
2926
- };
2927
- } & {
2928
- htmx: {
2929
- "connector-links": {
2930
- get: {
2931
- body: unknown;
2932
- params: {};
2933
- query: unknown;
2934
- headers: unknown;
2935
- response: {
2936
- 200: Response;
2937
- 422: {
2938
- type: "validation";
2939
- on: string;
2940
- summary?: string;
2941
- message?: string;
2942
- found?: unknown;
2943
- property?: string;
2944
- expected?: string;
2945
- };
2946
- };
2947
- };
2948
- };
2949
- };
2950
- } & {
2951
- htmx: {
2952
- "auth-menu": {
2953
- get: {
2954
- body: unknown;
2955
- params: {};
2956
- query: unknown;
2957
- headers: unknown;
2958
- response: {
2959
- 400: "Cookies are missing";
2960
- 401: "User is not authenticated";
2961
- 200: Response;
2962
- 422: {
2963
- type: "validation";
2964
- on: string;
2965
- summary?: string;
2966
- message?: string;
2967
- found?: unknown;
2968
- property?: string;
2969
- expected?: string;
2970
- };
2971
- };
2972
- };
2973
- };
2974
- };
2975
- } & {
2976
- htmx: {
2977
- me: {
2978
- get: {
2979
- body: unknown;
2980
- params: {};
2981
- query: unknown;
2982
- headers: unknown;
2983
- response: {
2984
- 400: "Cookies are missing";
2985
- 401: "User is not authenticated";
2986
- 200: Response;
2987
- 422: {
2988
- type: "validation";
2989
- on: string;
2990
- summary?: string;
2991
- message?: string;
2992
- found?: unknown;
2993
- property?: string;
2994
- expected?: string;
2995
- };
2996
- };
2997
- };
2998
- };
2999
- };
3000
- } & {
3001
- htmx: {
3002
- account: {
3003
- get: {
3004
- body: unknown;
3005
- params: {};
3006
- query: unknown;
3007
- headers: unknown;
3008
- response: {
3009
- 400: "Cookies are missing";
3010
- 401: "User is not authenticated";
3011
- 200: Response;
3012
- 422: {
3013
- type: "validation";
3014
- on: string;
3015
- summary?: string;
3016
- message?: string;
3017
- found?: unknown;
3018
- property?: string;
3019
- expected?: string;
3020
- };
3021
- };
3022
- };
3023
- };
3024
- };
3025
- } & {
3026
- htmx: {
3027
- identities: {
3028
- get: {
3029
- body: unknown;
3030
- params: {};
3031
- query: unknown;
3032
- headers: unknown;
3033
- response: {
3034
- 400: "Cookies are missing";
3035
- 401: "User is not authenticated";
3036
- 200: Response;
3037
- 422: {
3038
- type: "validation";
3039
- on: string;
3040
- summary?: string;
3041
- message?: string;
3042
- found?: unknown;
3043
- property?: string;
3044
- expected?: string;
3045
- };
3046
- };
3047
- };
3048
- };
3049
- };
3050
- } & {
3051
- htmx: {
3052
- identities: {
3053
- ":id": {
3054
- primary: {
3055
- post: {
3056
- body: unknown;
3057
- params: {
3058
- id: string;
3059
- } & {};
3060
- query: unknown;
3061
- headers: unknown;
3062
- response: {
3063
- 400: "Cookies are missing";
3064
- 401: "User is not authenticated";
3065
- 200: Response;
3066
- 422: {
3067
- type: "validation";
3068
- on: string;
3069
- summary?: string;
3070
- message?: string;
3071
- found?: unknown;
3072
- property?: string;
3073
- expected?: string;
3074
- };
3075
- };
3076
- };
3077
- };
3078
- };
3079
- };
3080
- };
3081
- } & {
3082
- htmx: {
3083
- identities: {
3084
- ":id": {
3085
- delete: {
3086
- body: unknown;
3087
- params: {
3088
- id: string;
3089
- } & {};
3090
- query: unknown;
3091
- headers: unknown;
3092
- response: {
3093
- 400: "Cookies are missing";
3094
- 401: "User is not authenticated";
3095
- 200: Response;
3096
- 422: {
3097
- type: "validation";
3098
- on: string;
3099
- summary?: string;
3100
- message?: string;
3101
- found?: unknown;
3102
- property?: string;
3103
- expected?: string;
3104
- };
3105
- };
3106
- };
3107
- };
3108
- };
3109
- };
3110
- } & {
3111
- htmx: {
3112
- merge: {
3113
- ":id": {
3114
- post: {
3115
- body: unknown;
3116
- params: {
3117
- id: string;
3118
- } & {};
3119
- query: unknown;
3120
- headers: unknown;
3121
- response: {
3122
- 400: "Cookies are missing";
3123
- 401: "User is not authenticated";
3124
- 200: Response;
3125
- 422: {
3126
- type: "validation";
3127
- on: string;
3128
- summary?: string;
3129
- message?: string;
3130
- found?: unknown;
3131
- property?: string;
3132
- expected?: string;
3133
- };
3134
- };
3135
- };
3136
- };
3137
- };
3138
- };
3139
- } & {
3140
- htmx: {
3141
- merge: {
3142
- ":id": {
3143
- delete: {
3144
- body: unknown;
3145
- params: {
3146
- id: string;
3147
- } & {};
3148
- query: unknown;
3149
- headers: unknown;
3150
- response: {
3151
- 400: "Cookies are missing";
3152
- 401: "User is not authenticated";
3153
- 200: Response;
3154
- 422: {
3155
- type: "validation";
3156
- on: string;
3157
- summary?: string;
3158
- message?: string;
3159
- found?: unknown;
3160
- property?: string;
3161
- expected?: string;
3162
- };
3163
- };
3164
- };
3165
- };
3166
- };
3167
- };
3168
- } & {
3169
- htmx: {
3170
- "connector-list": {
3171
- get: {
3172
- body: unknown;
3173
- params: {};
3174
- query: unknown;
3175
- headers: unknown;
3176
- response: {
3177
- 400: "Cookies are missing";
3178
- 401: "User is not authenticated";
3179
- 200: Response;
3180
- 422: {
3181
- type: "validation";
3182
- on: string;
3183
- summary?: string;
3184
- message?: string;
3185
- found?: unknown;
3186
- property?: string;
3187
- expected?: string;
3188
- };
3189
- };
3190
- };
3191
- };
3192
- };
3193
- } & {
3194
- htmx: {
3195
- connectors: {
3196
- grants: {
3197
- ":id": {
3198
- delete: {
3199
- body: unknown;
3200
- params: {
3201
- id: string;
3202
- } & {};
3203
- query: unknown;
3204
- headers: unknown;
3205
- response: {
3206
- 400: "Cookies are missing";
3207
- 401: "User is not authenticated";
3208
- 200: Response;
3209
- 422: {
3210
- type: "validation";
3211
- on: string;
3212
- summary?: string;
3213
- message?: string;
3214
- found?: unknown;
3215
- property?: string;
3216
- expected?: string;
3217
- };
3218
- };
3219
- };
3220
- };
3221
- };
3222
- };
3223
- };
3224
- } & {
3225
- htmx: {
3226
- connectors: {
3227
- bindings: {
3228
- ":id": {
3229
- delete: {
3230
- body: unknown;
3231
- params: {
3232
- id: string;
3233
- } & {};
3234
- query: unknown;
3235
- headers: unknown;
3236
- response: {
3237
- 400: "Cookies are missing";
3238
- 401: "User is not authenticated";
3239
- 200: Response;
3240
- 422: {
3241
- type: "validation";
3242
- on: string;
3243
- summary?: string;
3244
- message?: string;
3245
- found?: unknown;
3246
- property?: string;
3247
- expected?: string;
3248
- };
3249
- };
3250
- };
3251
- };
3252
- };
3253
- };
3254
- };
3255
- } & {
3256
- htmx: {
3257
- "login-redirect": {
3258
- get: {
3259
- body: unknown;
3260
- params: {};
3261
- query: unknown;
3262
- headers: unknown;
3263
- response: {
3264
- 200: Response;
3265
- 422: {
3266
- type: "validation";
3267
- on: string;
3268
- summary?: string;
3269
- message?: string;
3270
- found?: unknown;
3271
- property?: string;
3272
- expected?: string;
3273
- };
3274
- };
3275
- };
3276
- };
3277
- };
3278
- } & {
3279
- htmx: {
3280
- "delete-account": {
3281
- post: {
3282
- body: unknown;
3283
- params: {};
3284
- query: unknown;
3285
- headers: unknown;
3286
- response: {
3287
- 400: "Cookies are missing";
3288
- 401: "User is not authenticated";
3289
- 200: Response;
3290
- 422: {
3291
- type: "validation";
3292
- on: string;
3293
- summary?: string;
3294
- message?: string;
3295
- found?: unknown;
3296
- property?: string;
3297
- expected?: string;
3298
- };
3299
- };
3300
- };
3301
- };
3302
- };
3303
- } & {
3304
- htmx: {
3305
- signout: {
3306
- get: {
3307
- body: unknown;
3308
- params: {};
3309
- query: unknown;
3310
- headers: unknown;
3311
- response: {
3312
- 200: Response;
3313
- 422: {
3314
- type: "validation";
3315
- on: string;
3316
- summary?: string;
3317
- message?: string;
3318
- found?: unknown;
3319
- property?: string;
3320
- expected?: string;
3321
- };
3322
- };
3323
- };
3324
- };
3325
- };
3326
- }))) & ({} | ({
3327
- [x: string]: {
3328
- get: {
3329
- body: unknown;
3330
- params: {};
3331
- query: unknown;
3332
- headers: unknown;
3333
- response: {
3334
- 200: {
3335
- resource: string;
3336
- scopes_supported: string[];
3337
- resource_name?: string | undefined;
3338
- resource_logo_uri?: string | undefined;
3339
- authorization_servers: string[];
3340
- bearer_methods_supported: string[];
3341
- };
3342
- };
3343
- };
3344
- };
3345
- } & {
3346
- [x: string]: {
3347
- get: {
3348
- body: unknown;
3349
- params: {};
3350
- query: unknown;
3351
- headers: unknown;
3352
- response: {
3353
- 200: Response;
3354
- };
3355
- };
3356
- };
3357
- } & {
3358
- [x: string]: {
3359
- get: {
3360
- body: unknown;
3361
- params: {};
3362
- query: unknown;
3363
- headers: unknown;
3364
- response: {
3365
- 200: Response;
3366
- };
3367
- };
3368
- };
3369
- } & {
3370
- [x: string]: {
3371
- post: {
3372
- body: unknown;
3373
- params: {};
3374
- query: unknown;
3375
- headers: unknown;
3376
- response: {
3377
- 200: Response;
3378
- };
3379
- };
3380
- };
3381
- } & {
3382
- [x: string]: {
3383
- post: {
3384
- body: unknown;
3385
- params: {};
3386
- query: unknown;
3387
- headers: unknown;
3388
- response: {
3389
- 200: Response;
3390
- };
3391
- };
3392
- };
3393
- } & {
3394
- [x: string]: {
3395
- post: {
3396
- body: unknown;
3397
- params: {};
3398
- query: unknown;
3399
- headers: unknown;
3400
- response: {
3401
- 200: Response;
3402
- };
3403
- };
3404
- };
3405
- })), {
3406
- derive: {};
3407
- resolve: {};
3408
- schema: {};
3409
- standaloneSchema: {};
3410
- response: {};
3411
- }, {
3412
- derive: {};
3413
- resolve: {};
3414
- schema: {};
3415
- standaloneSchema: {};
3416
- response: {};
3417
- } & {
3418
- derive: {};
3419
- resolve: {};
3420
- schema: {};
3421
- standaloneSchema: {};
3422
- response: {};
3423
- } & {
3424
- derive: {};
3425
- resolve: {};
3426
- schema: {};
3427
- standaloneSchema: {};
3428
- response: {};
3429
- }>;
3430
- }>;
3431
- export * from './actions';
3432
- export type AuthApplications<UserType> = Awaited<ReturnType<typeof createAuthApplications<UserType>>>;
3433
- export { createAuthContext } from './authContext';
3434
- export type { AuthInstance } from './authContext';
3435
- export * from './types';
3436
- export * from './typebox';
3437
- export * from './vault/config';
3438
- export * from './vault/types';
3439
- export { createInMemoryVaultStore } from './vault/inMemoryVaultStore';
3440
- export { createNeonVaultStore, createPostgresVaultStore, vaultEntriesTable } from './vault/postgresVaultStore';
3441
- export { createFederatedTokenStore, getOrRefreshFederatedTokens } from './federation/tokenStore';
3442
- export type { FederatedTokenRefresher, FederatedTokenSet, FederatedTokenStore } from './federation/tokenStore';
3443
- export { decodeSessionUserRecord, type AuthSessionStore, type SessionUserDecoder } from './session/types';
3444
- export { isAuthIntent, isUserSessionId, isValidUser } from './typeGuards';
3445
- export { readSessionCookie } from './session/cookieReader';
3446
- export { AuthIdentityConflictError } from './errors';
3447
- export { sessionStore } from './session/state';
3448
- export { createInMemoryAuthSessionStore } from './session/inMemoryStore';
3449
- export { createNeonAuthSessionStore } from './session/neonStore';
3450
- export { providersFromEnv, type ProviderSelection } from './providersFromEnv';
3451
- export { createRedisAuthSessionStore, type RedisSessionClient } from './session/redisStore';
3452
- export { createLinkedProviderCredentialResolver } from './linkedProviders/resolver';
3453
- export { createOAuthLinkedProviderCredentialResolver } from './linkedProviders/oauthResolver';
3454
- export { createOAuthAccountLinkedProviderCredentialResolver, type OAuthLinkedProviderAccount, type OAuthLinkedProviderAccountStore } from './linkedProviders/oauthAccountResolver';
3455
- export { createNeonLinkedProviderStores, createNeonOAuthLinkedProviderCredentialResolver } from './linkedProviders/neonStores';
3456
- export { createInMemoryLinkedProviderStores } from './linkedProviders/inMemoryStores';
3457
- export { protectRoutePlugin } from './routes/protectRoute';
3458
- export { requireAuthPlugin } from './routes/requireAuth';
3459
- export { sessionRoutes } from './routes/sessions';
3460
- export { stepUpPlugin } from './routes/stepUp';
3461
- export * from './session/sessionsConfig';
3462
- export { endImpersonation, isImpersonating, startImpersonation } from './session/impersonation';
3463
- export { createAnonymousSession, isAnonymousSession } from './session/anonymous';
3464
- export { addToSessionRing, listRingSessions, readSessionRing, removeFromSessionRing, switchActiveSession } from './session/multiSession';
3465
- export { listUserSessions, refreshUserSessions, revokeUserSessions } from './session/userSessions';
3466
- export type { UserSession } from './session/userSessions';
3467
- export { sessionCleanup } from './session/cleanup';
3468
- export { createAuthHtmxRoutes } from './htmx/routes';
3469
- export { resolveAuthHtmxRenderers } from './htmx/renderers';
3470
- export type { AuthHtmxConfig, AuthHtmxConnectorTarget, AuthHtmxProviderData, AuthHtmxProviderInfo, AuthHtmxRenderOverrides, AuthHtmxRenderersConfig, AuthHtmxUser, AuthIdentityPayload, LinkedProviderPayload } from './htmx/types';
3471
- export * from './utils';
3472
- export * from './redirect';
3473
- export * from './csrf';
3474
- export { buildClientProviders, resolveClientProviderEntry, resolveProviderClientConfiguration } from './providers/clients';
3475
- export type { OAuth2TokenResponse, OAuth2Client, OAuth2ClientForConfig, CustomProviderCredentials, ProviderConfig, ProviderOption, PKCEProvider, OIDCProvider, RefreshableProvider, RevocableProvider, ScopeRequiredProvider, ProvidersMap, ProviderConfiguration, CredentialsFor } from 'citra';
3476
- export { providers, providerOptions, createCustomOAuth2Client, defineProvider, refreshableProviderOptions, revocableProviderOptions, oidcProviderOptions, pkceProviderOptions, scopeRequiredProviderOptions, decodeJWT, extractPropFromIdentity, isValidProviderOption, isRefreshableOAuth2Client, isRefreshableProviderOption, isOIDCProviderOption, isPKCEProviderOption, isRevocableProviderOption, isRevocableOAuth2Client } from 'citra';
3477
- export * from './crypto';
3478
- export * from './tenancy';
3479
- export * from './credentials/config';
3480
- export * from './credentials/passwordPolicy';
3481
- export * from './credentials/backgroundOps';
3482
- export * from './credentials/emailValidation';
3483
- export { importUser, importUsers, rehashCredentialPassword } from './credentials/import';
3484
- export type { ImportUserResult, ImportUsersOptions, ImportableUser } from './credentials/import';
3485
- export { isLegacyHash, verifyAuth0Pbkdf2, verifyCognitoSha256 } from './credentials/legacyHashers';
3486
- export * from './credentials/types';
3487
- export { credentialRoutes } from './credentials/routes';
3488
- export { credentialsEmailVerification } from './credentials/emailVerification';
3489
- export { credentialsLogin } from './credentials/login';
3490
- export { credentialsPasswordReset } from './credentials/passwordReset';
3491
- export { credentialsRegister } from './credentials/register';
3492
- export { createInMemoryCredentialStore } from './credentials/inMemoryCredentialStore';
3493
- export { createNeonCredentialStore, createPostgresCredentialStore, credentialResetTokensTable, credentialsTable, credentialVerificationTokensTable } from './credentials/postgresCredentialStore';
3494
- export { createNeonDatabase } from './stores/postgres';
3495
- export type { AnyPgDatabase } from './stores/postgres';
3496
- export * from './mfa/config';
3497
- export * from './mfa/types';
3498
- export * from './verification/types';
3499
- export { consumeBackupCode, generateBackupCodes } from './mfa/backupCodes';
3500
- export { createMfaGate } from './mfa/gate';
3501
- export { mfaChallenge } from './mfa/challenge';
3502
- export { mfaRoutes } from './mfa/routes';
3503
- export { mfaManagementRoutes, type MfaStatus } from './mfa/management';
3504
- export { rotateMfaEncryptionKey } from './mfa/rotation';
3505
- export type { MfaKeyRotationResult } from './mfa/rotation';
3506
- export { mfaTotpRoutes } from './mfa/totp';
3507
- export { isE164Phone, maskPhone, mfaSmsRoutes } from './mfa/sms';
3508
- export { decryptTotpSecret, encryptTotpSecret } from './mfa/secret';
3509
- export { createInMemoryMfaStore } from './mfa/inMemoryMfaStore';
3510
- export { createNeonMfaStore, createPostgresMfaStore, mfaEnrollmentsTable } from './mfa/postgresMfaStore';
3511
- export * from './audit/config';
3512
- export * from './audit/types';
3513
- export { createTamperEvidentSink, hashAuditEvent, verifyAuditChain } from './audit/integrity';
3514
- export type { AuditChainResult, AuditIntegrity } from './audit/integrity';
3515
- export { createSiemLogStream } from './audit/siem';
3516
- export type { SiemEndpoint, SiemFormat } from './audit/siem';
3517
- export * from './abuse/captcha';
3518
- export * from './abuse/config';
3519
- export * from './authorization/config';
3520
- export { protectPermissionPlugin } from './authorization/protectPermission';
3521
- export * from './compliance/config';
3522
- export { complianceRoutes } from './compliance/routes';
3523
- export { createAuditRedactor } from './compliance/redaction';
3524
- export { createSecretCipher } from './compliance/cipher';
3525
- export type { SecretCipher } from './compliance/cipher';
3526
- export * from './lockout/config';
3527
- export * from './lockout/types';
3528
- export { createInMemoryLockoutStore } from './lockout/inMemoryLockoutStore';
3529
- export { createNeonLockoutStore, createPostgresLockoutStore, lockoutsTable } from './lockout/postgresLockoutStore';
3530
- export { createRedisLockoutStore } from './lockout/redisLockoutStore';
3531
- export type { RedisLike } from './stores/redis';
3532
- export { exportAuditCsv } from './audit/export';
3533
- export { createInMemoryAuditSink } from './audit/inMemoryAuditStore';
3534
- export { auditEventsTable, createNeonAuditSink, createPostgresAuditSink } from './audit/postgresAuditStore';
3535
- export * from './sso/types';
3536
- export * from './sso/config';
3537
- export * from './scim/types';
3538
- export * from './scim/config';
3539
- export * from './scim/extensions';
3540
- export { scimRoutes } from './scim/routes';
3541
- export * from './vc/sdJwt';
3542
- export { buildIssuerMetadata, createCredentialOffer, DEFAULT_VCI_ROUTE, exchangePreAuthorizedCode, issueCredential, PRE_AUTHORIZED_CODE_GRANT } from './oidc/vci';
3543
- export type { CredentialConfiguration, CredentialIssueInput, CredentialIssueResult, CredentialNonceRecord, CredentialNonceStore, CredentialOffer, CredentialOfferStore, PreAuthExchangeResult, VciConfig } from './oidc/vci';
3544
- export { createInMemoryCredentialNonceStore, createInMemoryCredentialOfferStore } from './oidc/inMemoryVciStores';
3545
- export { vciRoutes } from './oidc/vciRoutes';
3546
- export * from './vc/statusList';
3547
- export { statusListRoutes, DEFAULT_STATUS_ROUTE } from './vc/statusListRoutes';
3548
- export { buildHolderKeyBindingJwt, createPresentationRequest, parsePresentationToken, verifyPresentationResponse } from './vc/openid4vp';
3549
- export type { CreatePresentationRequestInput, PresentationRequest, PresentationRequestStore, PresentationResponseInput, PresentationVerifyError, PresentationVerifyResult, VerifiedPresentation, Vp4Config } from './vc/openid4vp';
3550
- export { createInMemoryPresentationRequestStore } from './vc/inMemoryVpStores';
3551
- export { vpRoutes, DEFAULT_VP_ROUTE } from './vc/vpRoutes';
3552
- export { createNeonCredentialNonceStore, createNeonCredentialOfferStore, createNeonPresentationRequestStore, createPostgresCredentialNonceStore, createPostgresCredentialOfferStore, createPostgresPresentationRequestStore, vcCredentialNoncesTable, vcCredentialOffersTable, vcPresentationRequestsTable } from './vc/postgresVcStores';
3553
- export { createInMemoryScimTokenStore } from './scim/inMemoryScimTokenStore';
3554
- export { createNeonScimTokenStore, createPostgresScimTokenStore, scimTokensTable } from './scim/postgresScimTokenStore';
3555
- export * from './apikeys/config';
3556
- export * from './apikeys/types';
3557
- export { apiKeysRoutes } from './apikeys/routes';
3558
- export * from './agents/config';
3559
- export * from './agents/types';
3560
- export * from './agents/registration';
3561
- export * from './agents/registrationClient';
3562
- export * from './agents/idJag';
3563
- export * from './agents/oauthGuide';
3564
- export { agentAuthPlugin, agentAuthChallenge } from './agents/routes';
3565
- export { resolveAgentPrincipal, agentHasScopes } from './agents/principal';
3566
- export { createOidcAgentCredentialVerifier } from './agents/oidcAdapter';
3567
- export { createInMemoryAgentDelegationStore, createInMemoryAgentIdentityRegistrationStore, createInMemoryAgentRegistrationStore } from './agents/inMemoryStores';
3568
- export { agentDelegationsTable, agentDelegationsBunSqlTable, agentIdentityRegistrationsTable, agentIdentityRegistrationsBunSqlTable, agentRegistrationsTable, agentRegistrationsBunSqlTable, createBunSqlDrizzleAgentDelegationStore, createBunSqlDrizzleAgentIdentityRegistrationStore, createBunSqlDrizzleAgentRegistrationStore, createNeonAgentDelegationStore, createNeonAgentIdentityRegistrationStore, createNeonAgentRegistrationStore, createDrizzleAgentDelegationStore, createPostgresAgentDelegationStore, createPostgresAgentIdentityRegistrationStore, createPostgresAgentRegistrationStore } from './agents/postgresStores';
3569
- export { createInMemoryAccessTokenStore, createInMemoryApiClientStore, createInMemoryApiKeyStore } from './apikeys/inMemoryStores';
3570
- export { accessTokensTable, apiClientsTable, apiKeysTable, createNeonAccessTokenStore, createNeonApiClientStore, createNeonApiKeyStore, createPostgresAccessTokenStore, createPostgresApiClientStore, createPostgresApiKeyStore } from './apikeys/postgresStores';
3571
- export * from './oidc/config';
3572
- export * from './oidc/clientIdMetadata';
3573
- export * from './oidc/types';
3574
- export { oidcProviderRoutes } from './oidc/routes';
3575
- export { generateSigningKey, jwkThumbprint, signJwt, signingVerificationKeys, toPublicJwk, verifyJwt, verifyJwtWithKeys } from './oidc/keys';
3576
- export type { SigningKey, SigningKeyIdentity } from './oidc/keys';
3577
- export { extractDpopNonceClaim, mintDpopNonce, verifyDpopNonce, verifyDpopProof } from './oidc/dpop';
3578
- export type { DpopResult } from './oidc/dpop';
3579
- export { CLIENT_ASSERTION_TYPE, verifyClientAssertion, verifyJwtSignedByClient } from './oidc/clientAuth';
3580
- export { parseSignedRequestObject } from './oidc/jar';
3581
- export type { JarParseResult } from './oidc/jar';
3582
- export { computeCertThumbprint, extractRfc9440ClientCert, resolveClientCert, verifyCertificateBoundToken } from './oidc/mtls';
3583
- export { createInMemoryAuthorizationCodeStore, createInMemoryBackchannelAuthStore, createInMemoryClientAssertionJtiStore, createInMemoryClientRegistrationTokenStore, createInMemoryDeviceAuthorizationStore, createInMemoryInitialAccessTokenStore, createInMemoryLogoutDeliveryStore, createInMemoryOAuthClientStore, createInMemoryOidcRefreshTokenStore, createInMemoryPushedAuthorizationRequestStore } from './oidc/inMemoryStores';
3584
- export { consumePushedRequest, pushAuthorizationRequest, DEFAULT_PAR_TTL_MS, REQUEST_URI_PREFIX } from './oidc/par';
3585
- export { fetchUserInfo, readUserInfoBearer, userInfoChallengeHeader } from './oidc/userinfo';
3586
- export type { UserInfoResult } from './oidc/userinfo';
3587
- export { fanOutBackchannelLogout, mintLogoutToken, resolvePostLogoutRedirect, verifyIdTokenHint } from './oidc/logout';
3588
- export { createNeonAuthorizationCodeStore, createNeonBackchannelAuthStore, createNeonClientAssertionJtiStore, createNeonClientRegistrationTokenStore, createNeonDeviceAuthorizationStore, createNeonInitialAccessTokenStore, createNeonLogoutDeliveryStore, createNeonOAuthClientStore, createNeonOidcRefreshTokenStore, createNeonPushedAuthorizationRequestStore, createPostgresAuthorizationCodeStore, createPostgresBackchannelAuthStore, createPostgresClientAssertionJtiStore, createPostgresClientRegistrationTokenStore, createPostgresDeviceAuthorizationStore, createPostgresInitialAccessTokenStore, createPostgresLogoutDeliveryStore, createPostgresOAuthClientStore, createPostgresOidcRefreshTokenStore, createPostgresPushedAuthorizationRequestStore, oauthClientAssertionJtisTable, oauthClientRegistrationTokensTable, oauthClientsTable, oauthCodesTable, oauthBackchannelAuthRequestsTable, oauthDeviceAuthorizationsTable, oauthInitialAccessTokensTable, oauthLogoutDeliveriesTable, oauthPushedAuthorizationRequestsTable, oauthRefreshTokensTable } from './oidc/postgresStores';
3589
- export { deleteRegisteredClient, getRegisteredClient, registerClient, updateRegisteredClient, type ClientRegistrationDecision, type ClientRegistrationMetadata, type OnClientRegistration, type RegisterClientResult } from './oidc/registration';
3590
- export * from './adaptive/config';
3591
- export * from './adaptive/fingerprint';
3592
- export * from './adaptive/types';
3593
- export { createInMemoryKnownDeviceStore, createInMemoryLoginHistoryStore } from './adaptive/inMemoryStores';
3594
- export { createNeonKnownDeviceStore, createNeonLoginHistoryStore, createPostgresKnownDeviceStore, createPostgresLoginHistoryStore, knownDevicesTable, loginHistoryTable } from './adaptive/postgresStores';
3595
- export * from './fga/config';
3596
- export * from './fga/schema';
3597
- export * from './fga/types';
3598
- export { createInMemoryWarrantStore, warrantKey } from './fga/inMemoryStores';
3599
- export { createRedisFgaCache, type RedisFgaCacheClient } from './fga/redisCheckCache';
3600
- export { initTracing, withSpan, type TracingConfig } from './telemetry/tracing';
3601
- export { blockMigrations, runMigrations, type BlockMigrations, type BlockName, type Migration } from './migrations';
3602
- export type { MigrationClient, MigrationQueryResult, MigrationRunResult, RunMigrationsOptions } from './migrations/runner';
3603
- export { createNeonWarrantStore, createPostgresWarrantStore, warrantsTable } from './fga/postgresStores';
3604
- export { ssoDiscoveryRoute } from './sso/discoveryRoute';
3605
- export { oidcSsoRoutes } from './sso/oidcRoutes';
3606
- export { samlIdpRoutes } from './sso/samlIdpRoutes';
3607
- export { samlSsoRoutes } from './sso/samlRoutes';
3608
- export { createInMemorySamlServiceProviderStore } from './sso/inMemorySamlServiceProviderStore';
3609
- export { createInMemorySsoConnectionStore } from './sso/inMemorySsoConnectionStore';
3610
- export { createNeonSamlServiceProviderStore, createPostgresSamlServiceProviderStore, samlServiceProvidersTable } from './sso/postgresSamlServiceProviderStore';
3611
- export { createNeonSsoConnectionStore, createPostgresSsoConnectionStore, ssoConnectionsTable } from './sso/postgresSsoConnectionStore';
3612
- export * from './webauthn/adapter';
3613
- export * from './webauthn/config';
3614
- export * from './webauthn/types';
3615
- export { webauthnRoutes } from './webauthn/routes';
3616
- export { createInMemoryWebAuthnCredentialStore } from './webauthn/inMemoryWebAuthnCredentialStore';
3617
- export { createNeonWebAuthnCredentialStore, createPostgresWebAuthnCredentialStore, webauthnCredentialsTable } from './webauthn/postgresWebAuthnCredentialStore';
3618
- export * from './organizations/config';
3619
- export * from './organizations/types';
3620
- export { acceptInvitation, createOrganization, inviteToOrganization, listUserOrganizations } from './organizations/operations';
3621
- export { organizationRoutes } from './organizations/routes';
3622
- export { createInMemoryOrganizationStore } from './organizations/inMemoryOrganizationStore';
3623
- export { createNeonOrganizationStore, createPostgresOrganizationStore, organizationInvitationsTable, organizationMembershipsTable, organizationsTable } from './organizations/postgresOrganizationStore';
3624
- export * from './roles/config';
3625
- export * from './roles/types';
3626
- export { createMembershipPermissionResolver, resolvePermissions } from './roles/resolver';
3627
- export { setMemberRoles } from './roles/operations';
3628
- export { roleRoutes } from './roles/routes';
3629
- export { createInMemoryRoleStore } from './roles/inMemoryRoleStore';
3630
- export { createNeonRoleStore, createPostgresRoleStore, rolesTable } from './roles/postgresRoleStore';
3631
- export * from './passwordless/config';
3632
- export * from './passwordless/types';
3633
- export { passwordlessRoutes } from './passwordless/routes';
3634
- export { createInMemoryPasswordlessTokenStore } from './passwordless/inMemoryPasswordlessTokenStore';
3635
- export { createNeonPasswordlessTokenStore, createPostgresPasswordlessTokenStore, passwordlessTokensTable } from './passwordless/postgresPasswordlessTokenStore';
3636
- export * from './webhooks/config';
3637
- export * from './webhooks/types';
3638
- export { createWebhookDispatcher } from './webhooks/dispatcher';
3639
- export { createInMemoryWebhookDeliveryStore } from './webhooks/inMemoryStore';
3640
- export { createNeonWebhookDeliveryStore, createPostgresWebhookDeliveryStore, webhookDeliveriesTable } from './webhooks/postgresStore';
3641
- export { signWebhook, verifyWebhookSignature } from './webhooks/sign';
3642
- export * from './portal/config';
3643
- export * from './portal/types';
3644
- export { createSetupSession, resolveSetupSession } from './portal/operations';
3645
- export { portalRoutes } from './portal/routes';
3646
- export { createInMemorySetupSessionStore } from './portal/inMemorySetupSessionStore';
3647
- export { createNeonSetupSessionStore, createPostgresSetupSessionStore, setupSessionsTable } from './portal/postgresSetupSessionStore';