@yielded/auth-persistence 0.1.0-beta.10

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 (182) hide show
  1. package/README.md +27 -0
  2. package/dist/Adapter.d.mts +30 -0
  3. package/dist/Adapter.mjs +25 -0
  4. package/dist/index.d.mts +7 -0
  5. package/dist/index.mjs +7 -0
  6. package/dist/internal/PasswordPreparedPostconditions.d.mts +22 -0
  7. package/dist/internal/PasswordPreparedPostconditions.mjs +12 -0
  8. package/dist/internal/PasswordPreparedPostconditions.mjs.map +1 -0
  9. package/dist/internal/configuration.d.mts +174 -0
  10. package/dist/internal/configuration.mjs +7 -0
  11. package/dist/internal/configuration.mjs.map +1 -0
  12. package/dist/internal/email-kernel.d.mts +275 -0
  13. package/dist/internal/email-kernel.mjs +487 -0
  14. package/dist/internal/email-kernel.mjs.map +1 -0
  15. package/dist/internal/mapping-error.d.mts +10 -0
  16. package/dist/internal/mapping-error.mjs +30 -0
  17. package/dist/internal/mapping-error.mjs.map +1 -0
  18. package/dist/internal/models/common.d.mts +12 -0
  19. package/dist/internal/models/email-model.d.mts +353 -0
  20. package/dist/internal/models/email-model.mjs +21 -0
  21. package/dist/internal/models/email-model.mjs.map +1 -0
  22. package/dist/internal/models/passkey-model.d.mts +266 -0
  23. package/dist/internal/models/passkey-model.mjs +34 -0
  24. package/dist/internal/models/passkey-model.mjs.map +1 -0
  25. package/dist/internal/models/passkey-registration-ceremony-model.d.mts +49 -0
  26. package/dist/internal/models/passkey-registration-ceremony-model.mjs +18 -0
  27. package/dist/internal/models/passkey-registration-ceremony-model.mjs.map +1 -0
  28. package/dist/internal/models/passkey-write-model.d.mts +189 -0
  29. package/dist/internal/models/passkey-write-model.mjs +13 -0
  30. package/dist/internal/models/passkey-write-model.mjs.map +1 -0
  31. package/dist/internal/models/password-model.d.mts +328 -0
  32. package/dist/internal/models/password-model.mjs +23 -0
  33. package/dist/internal/models/password-model.mjs.map +1 -0
  34. package/dist/internal/models/proof-model.d.mts +285 -0
  35. package/dist/internal/models/proof-model.mjs +17 -0
  36. package/dist/internal/models/proof-model.mjs.map +1 -0
  37. package/dist/internal/models/session-model.d.mts +199 -0
  38. package/dist/internal/models/session-model.mjs +20 -0
  39. package/dist/internal/models/session-model.mjs.map +1 -0
  40. package/dist/internal/models/step-up-model.d.mts +66 -0
  41. package/dist/internal/models/step-up-model.mjs +9 -0
  42. package/dist/internal/models/step-up-model.mjs.map +1 -0
  43. package/dist/internal/oauth-app.d.mts +11 -0
  44. package/dist/internal/oauth-app.mjs +57 -0
  45. package/dist/internal/oauth-app.mjs.map +1 -0
  46. package/dist/internal/oauth-server.d.mts +10 -0
  47. package/dist/internal/oauth-server.mjs +66 -0
  48. package/dist/internal/oauth-server.mjs.map +1 -0
  49. package/dist/internal/passkey/admission.d.mts +6 -0
  50. package/dist/internal/passkey/admission.mjs +216 -0
  51. package/dist/internal/passkey/admission.mjs.map +1 -0
  52. package/dist/internal/passkey/credentials.d.mts +14 -0
  53. package/dist/internal/passkey/credentials.mjs +249 -0
  54. package/dist/internal/passkey/credentials.mjs.map +1 -0
  55. package/dist/internal/passkey/enrollment.mjs +138 -0
  56. package/dist/internal/passkey/enrollment.mjs.map +1 -0
  57. package/dist/internal/passkey/flow.d.mts +21 -0
  58. package/dist/internal/passkey/flow.mjs +452 -0
  59. package/dist/internal/passkey/flow.mjs.map +1 -0
  60. package/dist/internal/passkey/management.mjs +231 -0
  61. package/dist/internal/passkey/management.mjs.map +1 -0
  62. package/dist/internal/passkey/registration-ceremony.d.mts +9 -0
  63. package/dist/internal/passkey/registration-ceremony.mjs +129 -0
  64. package/dist/internal/passkey/registration-ceremony.mjs.map +1 -0
  65. package/dist/internal/passkey/registration-custody.d.mts +2 -0
  66. package/dist/internal/passkey/registration-custody.mjs +52 -0
  67. package/dist/internal/passkey/registration-custody.mjs.map +1 -0
  68. package/dist/internal/passkey/registration-write.mjs +211 -0
  69. package/dist/internal/passkey/registration-write.mjs.map +1 -0
  70. package/dist/internal/passkey/state.d.mts +10 -0
  71. package/dist/internal/passkey/state.mjs +234 -0
  72. package/dist/internal/passkey/state.mjs.map +1 -0
  73. package/dist/internal/passkey/target.d.mts +19 -0
  74. package/dist/internal/passkey/target.mjs +190 -0
  75. package/dist/internal/passkey/target.mjs.map +1 -0
  76. package/dist/internal/passkey/write-state.d.mts +17 -0
  77. package/dist/internal/passkey/write-state.mjs +345 -0
  78. package/dist/internal/passkey/write-state.mjs.map +1 -0
  79. package/dist/internal/passkey/write-target.mjs +192 -0
  80. package/dist/internal/passkey/write-target.mjs.map +1 -0
  81. package/dist/internal/passkey-kernel.d.mts +5592 -0
  82. package/dist/internal/passkey-kernel.mjs +49 -0
  83. package/dist/internal/passkey-kernel.mjs.map +1 -0
  84. package/dist/internal/passkeys.d.mts +7 -0
  85. package/dist/internal/passkeys.mjs +368 -0
  86. package/dist/internal/passkeys.mjs.map +1 -0
  87. package/dist/internal/password-kernel.d.mts +290 -0
  88. package/dist/internal/password-kernel.mjs +704 -0
  89. package/dist/internal/password-kernel.mjs.map +1 -0
  90. package/dist/internal/persistence.d.mts +25 -0
  91. package/dist/internal/persistence.mjs +291 -0
  92. package/dist/internal/persistence.mjs.map +1 -0
  93. package/dist/internal/phone-kernel.d.mts +162 -0
  94. package/dist/internal/phone-kernel.mjs +434 -0
  95. package/dist/internal/phone-kernel.mjs.map +1 -0
  96. package/dist/internal/proof-kernel.d.mts +93 -0
  97. package/dist/internal/proof-kernel.mjs +619 -0
  98. package/dist/internal/proof-kernel.mjs.map +1 -0
  99. package/dist/internal/query-operations.d.mts +61 -0
  100. package/dist/internal/registration-contract.d.mts +16 -0
  101. package/dist/internal/registration.mjs +66 -0
  102. package/dist/internal/registration.mjs.map +1 -0
  103. package/dist/internal/session-kernel.d.mts +48 -0
  104. package/dist/internal/session-kernel.mjs +737 -0
  105. package/dist/internal/session-kernel.mjs.map +1 -0
  106. package/dist/internal/sql-persistence.d.mts +10 -0
  107. package/dist/internal/sql-persistence.mjs +37 -0
  108. package/dist/internal/sql-persistence.mjs.map +1 -0
  109. package/dist/internal/sql-query.mjs +207 -0
  110. package/dist/internal/sql-query.mjs.map +1 -0
  111. package/dist/internal/sql-table.d.mts +36 -0
  112. package/dist/internal/sql-table.mjs +81 -0
  113. package/dist/internal/sql-table.mjs.map +1 -0
  114. package/dist/internal/standalone.d.mts +9 -0
  115. package/dist/internal/standalone.mjs +13 -0
  116. package/dist/internal/standalone.mjs.map +1 -0
  117. package/dist/internal/step-up-state.d.mts +49 -0
  118. package/dist/internal/step-up-state.mjs +32 -0
  119. package/dist/internal/step-up-state.mjs.map +1 -0
  120. package/dist/internal/storage-mapping.mjs +686 -0
  121. package/dist/internal/storage-mapping.mjs.map +1 -0
  122. package/dist/internal/storage-tables.d.mts +913 -0
  123. package/dist/internal/storage-tables.mjs +387 -0
  124. package/dist/internal/storage-tables.mjs.map +1 -0
  125. package/dist/internal/storage-validation.mjs +58 -0
  126. package/dist/internal/storage-validation.mjs.map +1 -0
  127. package/dist/internal/transaction-execution-kernel.d.mts +38 -0
  128. package/dist/internal/transaction-execution-kernel.mjs +116 -0
  129. package/dist/internal/transaction-execution-kernel.mjs.map +1 -0
  130. package/dist/internal/transaction-kernel.d.mts +77 -0
  131. package/dist/internal/transaction-kernel.mjs +260 -0
  132. package/dist/internal/transaction-kernel.mjs.map +1 -0
  133. package/package.json +1 -0
  134. package/src/Adapter.ts +291 -0
  135. package/src/index.ts +6 -0
  136. package/src/internal/PasswordPreparedPostconditions.ts +30 -0
  137. package/src/internal/configuration.ts +282 -0
  138. package/src/internal/email-kernel.ts +1535 -0
  139. package/src/internal/mapping-error.ts +36 -0
  140. package/src/internal/models/common.ts +11 -0
  141. package/src/internal/models/email-model.ts +559 -0
  142. package/src/internal/models/passkey-model.ts +390 -0
  143. package/src/internal/models/passkey-registration-ceremony-model.ts +72 -0
  144. package/src/internal/models/passkey-write-model.ts +297 -0
  145. package/src/internal/models/password-model.ts +513 -0
  146. package/src/internal/models/proof-model.ts +424 -0
  147. package/src/internal/models/session-model.ts +375 -0
  148. package/src/internal/models/step-up-model.ts +135 -0
  149. package/src/internal/oauth-app.ts +82 -0
  150. package/src/internal/oauth-server.ts +89 -0
  151. package/src/internal/passkey/admission.ts +361 -0
  152. package/src/internal/passkey/credentials.ts +511 -0
  153. package/src/internal/passkey/enrollment.ts +326 -0
  154. package/src/internal/passkey/flow.ts +1062 -0
  155. package/src/internal/passkey/management.ts +421 -0
  156. package/src/internal/passkey/registration-ceremony.ts +283 -0
  157. package/src/internal/passkey/registration-custody.ts +91 -0
  158. package/src/internal/passkey/registration-write.ts +426 -0
  159. package/src/internal/passkey/state.ts +353 -0
  160. package/src/internal/passkey/target.ts +586 -0
  161. package/src/internal/passkey/write-state.ts +681 -0
  162. package/src/internal/passkey/write-target.ts +452 -0
  163. package/src/internal/passkey-kernel.ts +104 -0
  164. package/src/internal/passkeys.ts +606 -0
  165. package/src/internal/password-kernel.ts +2124 -0
  166. package/src/internal/persistence.ts +588 -0
  167. package/src/internal/phone-kernel.ts +846 -0
  168. package/src/internal/proof-kernel.ts +1954 -0
  169. package/src/internal/query-operations.ts +81 -0
  170. package/src/internal/registration-contract.ts +22 -0
  171. package/src/internal/registration.ts +161 -0
  172. package/src/internal/session-kernel.ts +2217 -0
  173. package/src/internal/sql-persistence.ts +45 -0
  174. package/src/internal/sql-query.ts +298 -0
  175. package/src/internal/sql-table.ts +104 -0
  176. package/src/internal/standalone.ts +30 -0
  177. package/src/internal/step-up-state.ts +139 -0
  178. package/src/internal/storage-mapping.ts +708 -0
  179. package/src/internal/storage-tables.ts +408 -0
  180. package/src/internal/storage-validation.ts +117 -0
  181. package/src/internal/transaction-execution-kernel.ts +313 -0
  182. package/src/internal/transaction-kernel.ts +593 -0
@@ -0,0 +1,913 @@
1
+ import { Schema } from "effect";
2
+ //#region src/internal/storage-tables.d.ts
3
+ export declare const StorageColumn: Schema.Struct<{
4
+ readonly name: Schema.NonEmptyString;
5
+ readonly type: Schema.Literals<readonly ["text", "integer", "boolean"]>;
6
+ readonly nullable: Schema.optionalKey<Schema.Boolean>;
7
+ }>;
8
+ export declare const StorageTable: Schema.Struct<{
9
+ readonly name: Schema.NonEmptyString;
10
+ readonly schema: Schema.optionalKey<Schema.NonEmptyString>;
11
+ readonly columns: Schema.$Record<Schema.String, Schema.Struct<{
12
+ readonly name: Schema.NonEmptyString;
13
+ readonly type: Schema.Literals<readonly ["text", "integer", "boolean"]>;
14
+ readonly nullable: Schema.optionalKey<Schema.Boolean>;
15
+ }>>;
16
+ readonly unique: Schema.$Array<Schema.$Array<Schema.String>>;
17
+ }>;
18
+ export type StorageTable = typeof StorageTable.Type;
19
+ /** Logical roles are independent of table names and migration ownership. */
20
+ export declare const storageTables: {
21
+ readonly subjects: {
22
+ columns: {
23
+ id: {
24
+ type: "text";
25
+ };
26
+ active: {
27
+ type: "boolean";
28
+ };
29
+ securityRevision: {
30
+ type: "text";
31
+ };
32
+ };
33
+ unique: readonly (readonly ("active" | "id" | "securityRevision")[])[];
34
+ };
35
+ readonly identifiers: {
36
+ columns: {
37
+ namespace: {
38
+ type: "text";
39
+ };
40
+ value: {
41
+ type: "text";
42
+ };
43
+ subjectId: {
44
+ type: "text";
45
+ };
46
+ revision: {
47
+ type: "text";
48
+ };
49
+ verifiedAt: {
50
+ type: "integer";
51
+ nullable: boolean;
52
+ };
53
+ active: {
54
+ type: "boolean";
55
+ };
56
+ };
57
+ unique: readonly (readonly ("active" | "namespace" | "revision" | "subjectId" | "value" | "verifiedAt")[])[];
58
+ };
59
+ readonly credentials: {
60
+ columns: {
61
+ credentialId: {
62
+ type: "text";
63
+ };
64
+ subjectId: {
65
+ type: "text";
66
+ };
67
+ revision: {
68
+ type: "text";
69
+ };
70
+ active: {
71
+ type: "boolean";
72
+ };
73
+ };
74
+ unique: readonly (readonly ("active" | "credentialId" | "revision" | "subjectId")[])[];
75
+ };
76
+ readonly passwords: {
77
+ columns: {
78
+ moduleId: {
79
+ type: "text";
80
+ };
81
+ subjectId: {
82
+ type: "text";
83
+ };
84
+ credentialId: {
85
+ type: "text";
86
+ };
87
+ credentialRevision: {
88
+ type: "text";
89
+ };
90
+ verifierVersion: {
91
+ type: "text";
92
+ };
93
+ verifier: {
94
+ type: "text";
95
+ };
96
+ normalization: {
97
+ type: "text";
98
+ };
99
+ };
100
+ unique: readonly (readonly ("credentialId" | "credentialRevision" | "moduleId" | "normalization" | "subjectId" | "verifier" | "verifierVersion")[])[];
101
+ };
102
+ readonly passwordAttempts: {
103
+ columns: {
104
+ moduleId: {
105
+ type: "text";
106
+ };
107
+ action: {
108
+ type: "text";
109
+ };
110
+ attemptId: {
111
+ type: "text";
112
+ };
113
+ identifierNamespace: {
114
+ type: "text";
115
+ };
116
+ identifierValue: {
117
+ type: "text";
118
+ };
119
+ subjectId: {
120
+ type: "text";
121
+ nullable: boolean;
122
+ };
123
+ credentialId: {
124
+ type: "text";
125
+ nullable: boolean;
126
+ };
127
+ securityRevision: {
128
+ type: "text";
129
+ nullable: boolean;
130
+ };
131
+ credentialRevision: {
132
+ type: "text";
133
+ nullable: boolean;
134
+ };
135
+ verifierVersion: {
136
+ type: "text";
137
+ nullable: boolean;
138
+ };
139
+ identifierBindingRevision: {
140
+ type: "text";
141
+ nullable: boolean;
142
+ };
143
+ admittedAt: {
144
+ type: "integer";
145
+ };
146
+ deadline: {
147
+ type: "integer";
148
+ };
149
+ retentionUntil: {
150
+ type: "integer";
151
+ };
152
+ state: {
153
+ type: "text";
154
+ };
155
+ };
156
+ unique: readonly (readonly ("action" | "admittedAt" | "attemptId" | "credentialId" | "credentialRevision" | "deadline" | "identifierBindingRevision" | "identifierNamespace" | "identifierValue" | "moduleId" | "retentionUntil" | "securityRevision" | "state" | "subjectId" | "verifierVersion")[])[];
157
+ };
158
+ readonly passwordScopes: {
159
+ columns: {
160
+ moduleId: {
161
+ type: "text";
162
+ };
163
+ action: {
164
+ type: "text";
165
+ };
166
+ scopeKind: {
167
+ type: "text";
168
+ };
169
+ scopeKey: {
170
+ type: "text";
171
+ };
172
+ };
173
+ unique: readonly (readonly ("action" | "moduleId" | "scopeKey" | "scopeKind")[])[];
174
+ };
175
+ readonly passwordCharges: {
176
+ columns: {
177
+ moduleId: {
178
+ type: "text";
179
+ };
180
+ action: {
181
+ type: "text";
182
+ };
183
+ scopeKind: {
184
+ type: "text";
185
+ };
186
+ scopeKey: {
187
+ type: "text";
188
+ };
189
+ attemptId: {
190
+ type: "text";
191
+ };
192
+ occurredAt: {
193
+ type: "integer";
194
+ };
195
+ retentionUntil: {
196
+ type: "integer";
197
+ };
198
+ };
199
+ unique: readonly (readonly ("action" | "attemptId" | "moduleId" | "occurredAt" | "retentionUntil" | "scopeKey" | "scopeKind")[])[];
200
+ };
201
+ readonly passwordCommands: {
202
+ columns: {
203
+ moduleId: {
204
+ type: "text";
205
+ };
206
+ commandId: {
207
+ type: "text";
208
+ };
209
+ action: {
210
+ type: "text";
211
+ };
212
+ bindingDigest: {
213
+ type: "text";
214
+ };
215
+ decision: {
216
+ type: "text";
217
+ };
218
+ retentionUntil: {
219
+ type: "integer";
220
+ };
221
+ };
222
+ unique: readonly (readonly ("action" | "bindingDigest" | "commandId" | "decision" | "moduleId" | "retentionUntil")[])[];
223
+ };
224
+ readonly passwordRegistrations: {
225
+ columns: {
226
+ moduleId: {
227
+ type: "text";
228
+ };
229
+ requestId: {
230
+ type: "text";
231
+ };
232
+ };
233
+ unique: readonly (readonly ("moduleId" | "requestId")[])[];
234
+ };
235
+ readonly emailCredentials: {
236
+ columns: {
237
+ moduleId: {
238
+ type: "text";
239
+ };
240
+ subjectId: {
241
+ type: "text";
242
+ };
243
+ credentialId: {
244
+ type: "text";
245
+ };
246
+ identifierNamespace: {
247
+ type: "text";
248
+ };
249
+ identifierValue: {
250
+ type: "text";
251
+ };
252
+ credentialRevision: {
253
+ type: "text";
254
+ };
255
+ active: {
256
+ type: "boolean";
257
+ };
258
+ };
259
+ unique: readonly (readonly ("active" | "credentialId" | "credentialRevision" | "identifierNamespace" | "identifierValue" | "moduleId" | "subjectId")[])[];
260
+ };
261
+ readonly emailCommands: {
262
+ columns: {
263
+ moduleId: {
264
+ type: "text";
265
+ };
266
+ commandId: {
267
+ type: "text";
268
+ };
269
+ action: {
270
+ type: "text";
271
+ };
272
+ bindingDigest: {
273
+ type: "text";
274
+ };
275
+ retentionUntil: {
276
+ type: "integer";
277
+ };
278
+ };
279
+ unique: readonly (readonly ("action" | "bindingDigest" | "commandId" | "moduleId" | "retentionUntil")[])[];
280
+ };
281
+ readonly phoneState: {
282
+ columns: {
283
+ scope: {
284
+ type: "text";
285
+ };
286
+ state: {
287
+ type: "text";
288
+ };
289
+ version: {
290
+ type: "text";
291
+ };
292
+ };
293
+ unique: readonly (readonly ("scope" | "state" | "version")[])[];
294
+ };
295
+ readonly passkeyCredentials: {
296
+ columns: {
297
+ credentialId: {
298
+ type: "text";
299
+ };
300
+ subjectId: {
301
+ type: "text";
302
+ };
303
+ rpId: {
304
+ type: "text";
305
+ };
306
+ protocolCredentialId: {
307
+ type: "text";
308
+ };
309
+ credentialKey: {
310
+ type: "text";
311
+ };
312
+ handleKey: {
313
+ type: "text";
314
+ };
315
+ userHandle: {
316
+ type: "text";
317
+ };
318
+ publicKey: {
319
+ type: "text";
320
+ };
321
+ algorithm: {
322
+ type: "integer";
323
+ };
324
+ profile: {
325
+ type: "text";
326
+ };
327
+ credentialRevision: {
328
+ type: "text";
329
+ };
330
+ active: {
331
+ type: "boolean";
332
+ };
333
+ primarySignIn: {
334
+ type: "boolean";
335
+ };
336
+ enrollmentUserVerified: {
337
+ type: "boolean";
338
+ };
339
+ backupEligible: {
340
+ type: "boolean";
341
+ };
342
+ backupState: {
343
+ type: "boolean";
344
+ };
345
+ counter: {
346
+ type: "integer";
347
+ };
348
+ maximumCounter: {
349
+ type: "integer";
350
+ };
351
+ name: {
352
+ type: "text";
353
+ };
354
+ createdAt: {
355
+ type: "integer";
356
+ };
357
+ lastUsedAt: {
358
+ type: "integer";
359
+ nullable: boolean;
360
+ };
361
+ };
362
+ unique: readonly (readonly ("active" | "algorithm" | "backupEligible" | "backupState" | "counter" | "createdAt" | "credentialId" | "credentialKey" | "credentialRevision" | "enrollmentUserVerified" | "handleKey" | "lastUsedAt" | "maximumCounter" | "name" | "primarySignIn" | "profile" | "protocolCredentialId" | "publicKey" | "rpId" | "subjectId" | "userHandle")[])[];
363
+ };
364
+ readonly passkeyOwnership: {
365
+ columns: {
366
+ credentialKey: {
367
+ type: "text";
368
+ };
369
+ rpId: {
370
+ type: "text";
371
+ };
372
+ protocolCredentialId: {
373
+ type: "text";
374
+ };
375
+ subjectId: {
376
+ type: "text";
377
+ nullable: boolean;
378
+ };
379
+ credentialId: {
380
+ type: "text";
381
+ nullable: boolean;
382
+ };
383
+ state: {
384
+ type: "text";
385
+ };
386
+ version: {
387
+ type: "text";
388
+ };
389
+ reservationId: {
390
+ type: "text";
391
+ nullable: boolean;
392
+ };
393
+ };
394
+ unique: readonly (readonly ("credentialId" | "credentialKey" | "protocolCredentialId" | "reservationId" | "rpId" | "state" | "subjectId" | "version")[])[];
395
+ };
396
+ readonly passkeyHandles: {
397
+ columns: {
398
+ handleKey: {
399
+ type: "text";
400
+ };
401
+ rpId: {
402
+ type: "text";
403
+ };
404
+ userHandle: {
405
+ type: "text";
406
+ };
407
+ subjectId: {
408
+ type: "text";
409
+ nullable: boolean;
410
+ };
411
+ state: {
412
+ type: "text";
413
+ };
414
+ version: {
415
+ type: "text";
416
+ };
417
+ reservationId: {
418
+ type: "text";
419
+ nullable: boolean;
420
+ };
421
+ };
422
+ unique: readonly (readonly ("handleKey" | "reservationId" | "rpId" | "state" | "subjectId" | "userHandle" | "version")[])[];
423
+ };
424
+ readonly passkeyModules: {
425
+ columns: {
426
+ moduleId: {
427
+ type: "text";
428
+ };
429
+ active: {
430
+ type: "boolean";
431
+ };
432
+ policyRevision: {
433
+ type: "text";
434
+ };
435
+ policy: {
436
+ type: "text";
437
+ };
438
+ };
439
+ unique: readonly (readonly ("active" | "moduleId" | "policy" | "policyRevision")[])[];
440
+ };
441
+ readonly passkeyFlows: {
442
+ columns: {
443
+ moduleId: {
444
+ type: "text";
445
+ };
446
+ flowId: {
447
+ type: "text";
448
+ };
449
+ commandId: {
450
+ type: "text";
451
+ };
452
+ purpose: {
453
+ type: "text";
454
+ };
455
+ state: {
456
+ type: "text";
457
+ };
458
+ version: {
459
+ type: "text";
460
+ };
461
+ generation: {
462
+ type: "integer";
463
+ };
464
+ snapshot: {
465
+ type: "text";
466
+ };
467
+ policySnapshot: {
468
+ type: "text";
469
+ };
470
+ requestBindingVerifier: {
471
+ type: "text";
472
+ };
473
+ requestBindingExpiresAt: {
474
+ type: "integer";
475
+ };
476
+ issuedAt: {
477
+ type: "integer";
478
+ };
479
+ expiresAt: {
480
+ type: "integer";
481
+ };
482
+ retentionUntil: {
483
+ type: "integer";
484
+ };
485
+ claimId: {
486
+ type: "text";
487
+ nullable: boolean;
488
+ };
489
+ claimedAt: {
490
+ type: "integer";
491
+ nullable: boolean;
492
+ };
493
+ claimExpiresAt: {
494
+ type: "integer";
495
+ nullable: boolean;
496
+ };
497
+ credentialSnapshot: {
498
+ type: "text";
499
+ nullable: boolean;
500
+ };
501
+ subjectScope: {
502
+ type: "text";
503
+ nullable: boolean;
504
+ };
505
+ targetScope: {
506
+ type: "text";
507
+ nullable: boolean;
508
+ };
509
+ };
510
+ unique: readonly (readonly ("claimExpiresAt" | "claimId" | "claimedAt" | "commandId" | "credentialSnapshot" | "expiresAt" | "flowId" | "generation" | "issuedAt" | "moduleId" | "policySnapshot" | "purpose" | "requestBindingExpiresAt" | "requestBindingVerifier" | "retentionUntil" | "snapshot" | "state" | "subjectScope" | "targetScope" | "version")[])[];
511
+ };
512
+ readonly passkeyAdmissions: {
513
+ columns: {
514
+ authorityScope: {
515
+ type: "text";
516
+ };
517
+ moduleId: {
518
+ type: "text";
519
+ };
520
+ version: {
521
+ type: "text";
522
+ };
523
+ ownerMarker: {
524
+ type: "text";
525
+ };
526
+ admittedAt: {
527
+ type: "integer";
528
+ nullable: boolean;
529
+ };
530
+ };
531
+ unique: readonly (readonly ("admittedAt" | "authorityScope" | "moduleId" | "ownerMarker" | "version")[])[];
532
+ };
533
+ readonly passkeyCharges: {
534
+ columns: {
535
+ moduleId: {
536
+ type: "text";
537
+ };
538
+ flowId: {
539
+ type: "text";
540
+ };
541
+ purpose: {
542
+ type: "text";
543
+ };
544
+ kind: {
545
+ type: "text";
546
+ };
547
+ scope: {
548
+ type: "text";
549
+ };
550
+ originalWindowMillis: {
551
+ type: "integer";
552
+ };
553
+ admittedAt: {
554
+ type: "integer";
555
+ nullable: boolean;
556
+ };
557
+ retainUntil: {
558
+ type: "integer";
559
+ nullable: boolean;
560
+ };
561
+ version: {
562
+ type: "text";
563
+ };
564
+ ownerMarker: {
565
+ type: "text";
566
+ };
567
+ };
568
+ unique: readonly (readonly ("admittedAt" | "flowId" | "kind" | "moduleId" | "originalWindowMillis" | "ownerMarker" | "purpose" | "retainUntil" | "scope" | "version")[])[];
569
+ };
570
+ readonly passkeyCommands: {
571
+ columns: {
572
+ moduleId: {
573
+ type: "text";
574
+ };
575
+ commandId: {
576
+ type: "text";
577
+ };
578
+ subjectId: {
579
+ type: "text";
580
+ };
581
+ credentialId: {
582
+ type: "text";
583
+ };
584
+ intent: {
585
+ type: "text";
586
+ };
587
+ decision: {
588
+ type: "text";
589
+ };
590
+ retentionUntil: {
591
+ type: "integer";
592
+ };
593
+ version: {
594
+ type: "text";
595
+ };
596
+ };
597
+ unique: readonly (readonly ("commandId" | "credentialId" | "decision" | "intent" | "moduleId" | "retentionUntil" | "subjectId" | "version")[])[];
598
+ };
599
+ readonly proofRequests: {
600
+ columns: {
601
+ moduleId: {
602
+ type: "text";
603
+ };
604
+ requestId: {
605
+ type: "text";
606
+ };
607
+ fingerprint: {
608
+ type: "text";
609
+ };
610
+ proofId: {
611
+ type: "text";
612
+ };
613
+ purpose: {
614
+ type: "text";
615
+ };
616
+ keyId: {
617
+ type: "text";
618
+ };
619
+ createdAt: {
620
+ type: "integer";
621
+ };
622
+ retentionUntil: {
623
+ type: "integer";
624
+ };
625
+ receipt: {
626
+ type: "text";
627
+ };
628
+ };
629
+ unique: readonly (readonly ("createdAt" | "fingerprint" | "keyId" | "moduleId" | "proofId" | "purpose" | "receipt" | "requestId" | "retentionUntil")[])[];
630
+ };
631
+ readonly proofSeries: {
632
+ columns: {
633
+ moduleId: {
634
+ type: "text";
635
+ };
636
+ purpose: {
637
+ type: "text";
638
+ };
639
+ scopeKey: {
640
+ type: "text";
641
+ };
642
+ activeProofId: {
643
+ type: "text";
644
+ nullable: boolean;
645
+ };
646
+ lastIssueAt: {
647
+ type: "integer";
648
+ nullable: boolean;
649
+ };
650
+ version: {
651
+ type: "text";
652
+ };
653
+ };
654
+ unique: readonly (readonly ("activeProofId" | "lastIssueAt" | "moduleId" | "purpose" | "scopeKey" | "version")[])[];
655
+ };
656
+ readonly proofGenerations: {
657
+ columns: {
658
+ moduleId: {
659
+ type: "text";
660
+ };
661
+ purpose: {
662
+ type: "text";
663
+ };
664
+ proofId: {
665
+ type: "text";
666
+ };
667
+ requestId: {
668
+ type: "text";
669
+ };
670
+ seriesKey: {
671
+ type: "text";
672
+ };
673
+ deliveryId: {
674
+ type: "text";
675
+ };
676
+ binding: {
677
+ type: "text";
678
+ };
679
+ verifierKeyId: {
680
+ type: "text";
681
+ };
682
+ verifierDigest: {
683
+ type: "text";
684
+ };
685
+ issuedAt: {
686
+ type: "integer";
687
+ };
688
+ expiresAt: {
689
+ type: "integer";
690
+ };
691
+ version: {
692
+ type: "text";
693
+ };
694
+ state: {
695
+ type: "text";
696
+ };
697
+ sendCount: {
698
+ type: "integer";
699
+ };
700
+ deliveryState: {
701
+ type: "text";
702
+ };
703
+ claimVersion: {
704
+ type: "text";
705
+ nullable: boolean;
706
+ };
707
+ claimDeadline: {
708
+ type: "integer";
709
+ nullable: boolean;
710
+ };
711
+ retryAt: {
712
+ type: "integer";
713
+ nullable: boolean;
714
+ };
715
+ deliveryRetryMillis: {
716
+ type: "integer";
717
+ };
718
+ retentionUntil: {
719
+ type: "integer";
720
+ };
721
+ fingerprint: {
722
+ type: "text";
723
+ };
724
+ };
725
+ unique: readonly (readonly ("binding" | "claimDeadline" | "claimVersion" | "deliveryId" | "deliveryRetryMillis" | "deliveryState" | "expiresAt" | "fingerprint" | "issuedAt" | "moduleId" | "proofId" | "purpose" | "requestId" | "retentionUntil" | "retryAt" | "sendCount" | "seriesKey" | "state" | "verifierDigest" | "verifierKeyId" | "version")[])[];
726
+ };
727
+ readonly proofContinuations: {
728
+ columns: {
729
+ moduleId: {
730
+ type: "text";
731
+ };
732
+ purpose: {
733
+ type: "text";
734
+ };
735
+ continuationId: {
736
+ type: "text";
737
+ };
738
+ digest: {
739
+ type: "text";
740
+ };
741
+ proofId: {
742
+ type: "text";
743
+ };
744
+ seriesKey: {
745
+ type: "text";
746
+ };
747
+ binding: {
748
+ type: "text";
749
+ };
750
+ expiresAt: {
751
+ type: "integer";
752
+ };
753
+ consumed: {
754
+ type: "boolean";
755
+ };
756
+ version: {
757
+ type: "text";
758
+ };
759
+ retentionUntil: {
760
+ type: "integer";
761
+ };
762
+ };
763
+ unique: readonly (readonly ("binding" | "consumed" | "continuationId" | "digest" | "expiresAt" | "moduleId" | "proofId" | "purpose" | "retentionUntil" | "seriesKey" | "version")[])[];
764
+ };
765
+ readonly proofScopes: {
766
+ columns: {
767
+ moduleId: {
768
+ type: "text";
769
+ };
770
+ purpose: {
771
+ type: "text";
772
+ };
773
+ action: {
774
+ type: "text";
775
+ };
776
+ scopeKind: {
777
+ type: "text";
778
+ };
779
+ scopeKey: {
780
+ type: "text";
781
+ };
782
+ };
783
+ unique: readonly (readonly ("action" | "moduleId" | "purpose" | "scopeKey" | "scopeKind")[])[];
784
+ };
785
+ readonly proofAbuse: {
786
+ columns: {
787
+ moduleId: {
788
+ type: "text";
789
+ };
790
+ purpose: {
791
+ type: "text";
792
+ };
793
+ action: {
794
+ type: "text";
795
+ };
796
+ scopeKind: {
797
+ type: "text";
798
+ };
799
+ scopeKey: {
800
+ type: "text";
801
+ };
802
+ commandId: {
803
+ type: "text";
804
+ };
805
+ occurredAt: {
806
+ type: "integer";
807
+ };
808
+ retentionUntil: {
809
+ type: "integer";
810
+ };
811
+ };
812
+ unique: readonly (readonly ("action" | "commandId" | "moduleId" | "occurredAt" | "purpose" | "retentionUntil" | "scopeKey" | "scopeKind")[])[];
813
+ };
814
+ readonly proofFailures: {
815
+ columns: {
816
+ moduleId: {
817
+ type: "text";
818
+ };
819
+ purpose: {
820
+ type: "text";
821
+ };
822
+ seriesKey: {
823
+ type: "text";
824
+ };
825
+ commandId: {
826
+ type: "text";
827
+ };
828
+ occurredAt: {
829
+ type: "integer";
830
+ };
831
+ retentionUntil: {
832
+ type: "integer";
833
+ };
834
+ };
835
+ unique: readonly (readonly ("commandId" | "moduleId" | "occurredAt" | "purpose" | "retentionUntil" | "seriesKey")[])[];
836
+ };
837
+ readonly proofCommands: {
838
+ columns: {
839
+ moduleId: {
840
+ type: "text";
841
+ };
842
+ commandId: {
843
+ type: "text";
844
+ };
845
+ kind: {
846
+ type: "text";
847
+ };
848
+ decision: {
849
+ type: "text";
850
+ };
851
+ retentionUntil: {
852
+ type: "integer";
853
+ };
854
+ };
855
+ unique: readonly (readonly ("commandId" | "decision" | "kind" | "moduleId" | "retentionUntil")[])[];
856
+ };
857
+ readonly sessions: {
858
+ columns: {
859
+ sessionId: {
860
+ type: "text";
861
+ };
862
+ subjectId: {
863
+ type: "text";
864
+ };
865
+ digest: {
866
+ type: "text";
867
+ };
868
+ version: {
869
+ type: "text";
870
+ };
871
+ securityRevision: {
872
+ type: "text";
873
+ };
874
+ issuedAt: {
875
+ type: "integer";
876
+ };
877
+ expiresAt: {
878
+ type: "integer";
879
+ };
880
+ absoluteExpiresAt: {
881
+ type: "integer";
882
+ };
883
+ record: {
884
+ type: "text";
885
+ };
886
+ };
887
+ unique: readonly (readonly ("absoluteExpiresAt" | "digest" | "expiresAt" | "issuedAt" | "record" | "securityRevision" | "sessionId" | "subjectId" | "version")[])[];
888
+ };
889
+ readonly sessionFlows: {
890
+ columns: {
891
+ flowId: {
892
+ type: "text";
893
+ };
894
+ subjectId: {
895
+ type: "text";
896
+ };
897
+ state: {
898
+ type: "text";
899
+ };
900
+ pendingDigest: {
901
+ type: "text";
902
+ nullable: boolean;
903
+ };
904
+ dedupUntil: {
905
+ type: "integer";
906
+ };
907
+ };
908
+ unique: readonly (readonly ("dedupUntil" | "flowId" | "pendingDigest" | "state" | "subjectId")[])[];
909
+ };
910
+ };
911
+ export type StorageRole = keyof typeof storageTables;
912
+ //#endregion
913
+ //# sourceMappingURL=storage-tables.d.mts.map