@yielded/auth-persistence-drizzle 0.1.0-beta.25 → 0.1.0-beta.27
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.
- package/README.md +4 -2
- package/dist/D1.d.mts +495 -1151
- package/dist/D1.mjs +41 -19
- package/dist/D1.mjs.map +1 -1
- package/dist/Libsql.d.mts +385 -1996
- package/dist/Libsql.mjs +43 -47
- package/dist/Libsql.mjs.map +1 -1
- package/dist/Mysql2.d.mts +397 -1743
- package/dist/Mysql2.mjs +35 -41
- package/dist/Mysql2.mjs.map +1 -1
- package/dist/Pglite.d.mts +397 -1743
- package/dist/Pglite.mjs +42 -31
- package/dist/Pglite.mjs.map +1 -1
- package/dist/Postgres.d.mts +397 -1743
- package/dist/Postgres.mjs +42 -31
- package/dist/Postgres.mjs.map +1 -1
- package/dist/SqliteBun.d.mts +385 -1992
- package/dist/SqliteBun.mjs +43 -43
- package/dist/SqliteBun.mjs.map +1 -1
- package/dist/SqliteDo.d.mts +385 -1991
- package/dist/SqliteDo.mjs +42 -41
- package/dist/SqliteDo.mjs.map +1 -1
- package/dist/SqliteNode.d.mts +385 -1992
- package/dist/SqliteNode.mjs +43 -43
- package/dist/SqliteNode.mjs.map +1 -1
- package/dist/SqliteWasm.d.mts +385 -1992
- package/dist/SqliteWasm.mjs +43 -43
- package/dist/SqliteWasm.mjs.map +1 -1
- package/dist/drizzle/d1-identity.mjs +2 -2
- package/dist/drizzle/d1-identity.mjs.map +1 -1
- package/dist/drizzle/driver-types.d.mts +15 -0
- package/dist/drizzle/email-drivers.mjs +32 -0
- package/dist/drizzle/email-drivers.mjs.map +1 -0
- package/dist/drizzle/email-model.d.mts +9 -13
- package/dist/drizzle/email-target.d.mts +10 -11
- package/dist/drizzle/email-target.mjs +33 -70
- package/dist/drizzle/email-target.mjs.map +1 -1
- package/dist/drizzle/model.d.mts +1 -10
- package/dist/drizzle/model.mjs +1 -2
- package/dist/drizzle/model.mjs.map +1 -1
- package/dist/drizzle/mysql-identity.mjs +3 -6
- package/dist/drizzle/mysql-identity.mjs.map +1 -1
- package/dist/drizzle/native-clock.d.mts +9 -0
- package/dist/drizzle/native-clock.mjs +18 -0
- package/dist/drizzle/native-clock.mjs.map +1 -0
- package/dist/drizzle/native-database.d.mts +46 -0
- package/dist/drizzle/native-database.mjs +6 -5
- package/dist/drizzle/native-database.mjs.map +1 -1
- package/dist/drizzle/native-sql-table.mjs +13 -5
- package/dist/drizzle/native-sql-table.mjs.map +1 -1
- package/dist/drizzle/native-target.d.mts +6 -0
- package/dist/drizzle/native-target.mjs +44 -0
- package/dist/drizzle/native-target.mjs.map +1 -0
- package/dist/drizzle/oauth-connected-drivers.mjs +4 -56
- package/dist/drizzle/oauth-connected-drivers.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-model.d.mts +5 -22
- package/dist/drizzle/oauth-connected-model.mjs +1 -7
- package/dist/drizzle/oauth-connected-reference.d.mts +5 -7
- package/dist/drizzle/oauth-connected-reference.mjs +11 -3
- package/dist/drizzle/oauth-connected-reference.mjs.map +1 -1
- package/dist/drizzle/oauth-drivers.mjs +1 -2
- package/dist/drizzle/oauth-drivers.mjs.map +1 -1
- package/dist/drizzle/oauth-model.d.mts +11 -37
- package/dist/drizzle/oauth-model.mjs +3 -4
- package/dist/drizzle/oauth-model.mjs.map +1 -1
- package/dist/drizzle/oauth-proxy.d.mts +1 -1
- package/dist/drizzle/oauth-proxy.mjs +1 -1
- package/dist/drizzle/oauth-target.d.mts +9 -6
- package/dist/drizzle/oauth-target.mjs +47 -15
- package/dist/drizzle/oauth-target.mjs.map +1 -1
- package/dist/drizzle/passkey/target.d.mts +14 -0
- package/dist/drizzle/passkey/target.mjs +52 -0
- package/dist/drizzle/passkey/target.mjs.map +1 -0
- package/dist/drizzle/passkey/write-target.d.mts +11 -0
- package/dist/drizzle/passkey/write-target.mjs +28 -0
- package/dist/drizzle/passkey/write-target.mjs.map +1 -0
- package/dist/drizzle/passkey-drivers.mjs +2 -4
- package/dist/drizzle/passkey-drivers.mjs.map +1 -1
- package/dist/drizzle/passkey-model.d.mts +5 -26
- package/dist/drizzle/passkey-model.mjs +2 -8
- package/dist/drizzle/passkey-registration-ceremony-model.d.mts +3 -6
- package/dist/drizzle/passkey-write-drivers.mjs +2 -3
- package/dist/drizzle/passkey-write-drivers.mjs.map +1 -1
- package/dist/drizzle/passkey-write-model.d.mts +7 -9
- package/dist/drizzle/passkey-write-model.mjs +1 -3
- package/dist/drizzle/passkey-write-model.mjs.map +1 -1
- package/dist/drizzle/password-drivers.mjs +31 -0
- package/dist/drizzle/password-drivers.mjs.map +1 -0
- package/dist/drizzle/password-model.d.mts +7 -10
- package/dist/drizzle/password-target.d.mts +7 -8
- package/dist/drizzle/password-target.mjs +23 -68
- package/dist/drizzle/password-target.mjs.map +1 -1
- package/dist/drizzle/pg-identity.mjs +3 -6
- package/dist/drizzle/pg-identity.mjs.map +1 -1
- package/dist/drizzle/phone-drivers.mjs +24 -0
- package/dist/drizzle/phone-drivers.mjs.map +1 -0
- package/dist/drizzle/phone-model.d.mts +13 -104
- package/dist/drizzle/phone-model.mjs +5 -33
- package/dist/drizzle/phone-model.mjs.map +1 -1
- package/dist/drizzle/phone-target.mjs +22 -171
- package/dist/drizzle/phone-target.mjs.map +1 -1
- package/dist/drizzle/proof-drivers.mjs +24 -0
- package/dist/drizzle/proof-drivers.mjs.map +1 -0
- package/dist/drizzle/proof-model.d.mts +7 -15
- package/dist/drizzle/proof-target.d.mts +5 -5
- package/dist/drizzle/proof-target.mjs +14 -28
- package/dist/drizzle/proof-target.mjs.map +1 -1
- package/dist/drizzle/session-drivers.mjs +97 -0
- package/dist/drizzle/session-drivers.mjs.map +1 -0
- package/dist/drizzle/session-model.d.mts +11 -22
- package/dist/drizzle/sqlite-do-database.d.mts +3 -3
- package/dist/drizzle/sqlite-do-database.mjs +6 -1
- package/dist/drizzle/sqlite-do-database.mjs.map +1 -1
- package/dist/drizzle/sqlite-identity.mjs +3 -5
- package/dist/drizzle/sqlite-identity.mjs.map +1 -1
- package/dist/drizzle/step-up-model.d.mts +2 -5
- package/dist/drizzle/storage-validation.mjs +2 -1
- package/dist/drizzle/storage-validation.mjs.map +1 -1
- package/dist/drizzle/totp-model.d.mts +7 -74
- package/dist/drizzle/totp-model.mjs +1 -5
- package/dist/drizzle/totp-model.mjs.map +1 -1
- package/dist/drizzle/totp-target.mjs +39 -75
- package/dist/drizzle/totp-target.mjs.map +1 -1
- package/dist/drizzle/transaction-handle.mjs +13 -0
- package/dist/drizzle/transaction-handle.mjs.map +1 -0
- package/dist/drizzle/transaction-mysql.mjs +43 -12
- package/dist/drizzle/transaction-mysql.mjs.map +1 -1
- package/dist/index.d.mts +17 -22
- package/dist/index.mjs +10 -16
- package/dist/internal/drizzle-postgres.mjs +4 -6
- package/dist/internal/drizzle-postgres.mjs.map +1 -1
- package/dist/internal/drizzle-sqlite.mjs +4 -6
- package/dist/internal/drizzle-sqlite.mjs.map +1 -1
- package/package.json +1 -1
- package/src/D1.ts +77 -74
- package/src/Libsql.ts +65 -105
- package/src/Mysql2.ts +52 -87
- package/src/Pglite.ts +74 -81
- package/src/Postgres.ts +74 -81
- package/src/SqliteBun.ts +65 -113
- package/src/SqliteDo.ts +58 -106
- package/src/SqliteNode.ts +65 -113
- package/src/SqliteWasm.ts +65 -113
- package/src/drizzle/d1-identity.ts +2 -2
- package/src/drizzle/driver-types.ts +26 -0
- package/src/drizzle/email-drivers.ts +320 -0
- package/src/drizzle/email-model.ts +24 -78
- package/src/drizzle/email-target.ts +118 -211
- package/src/drizzle/model.ts +0 -2
- package/src/drizzle/mysql-identity.ts +4 -24
- package/src/drizzle/native-clock.ts +21 -0
- package/src/drizzle/native-database.ts +59 -18
- package/src/drizzle/native-sql-table.ts +104 -87
- package/src/drizzle/native-target.ts +120 -0
- package/src/drizzle/oauth-connected-drivers.ts +24 -233
- package/src/drizzle/oauth-connected-model.ts +3 -93
- package/src/drizzle/oauth-connected-reference.ts +16 -25
- package/src/drizzle/oauth-drivers.ts +58 -99
- package/src/drizzle/oauth-model.ts +27 -132
- package/src/drizzle/oauth-target.ts +250 -33
- package/src/drizzle/passkey/target.ts +205 -0
- package/src/drizzle/passkey/write-target.ts +91 -0
- package/src/drizzle/passkey-drivers.ts +35 -133
- package/src/drizzle/passkey-model.ts +3 -81
- package/src/drizzle/passkey-registration-ceremony-model.ts +5 -25
- package/src/drizzle/passkey-write-drivers.ts +32 -102
- package/src/drizzle/passkey-write-model.ts +10 -44
- package/src/drizzle/password-drivers.ts +286 -0
- package/src/drizzle/password-model.ts +10 -44
- package/src/drizzle/password-target.ts +85 -239
- package/src/drizzle/pg-identity.ts +4 -19
- package/src/drizzle/phone-drivers.ts +142 -0
- package/src/drizzle/phone-model.ts +22 -162
- package/src/drizzle/phone-target.ts +51 -493
- package/src/drizzle/proof-drivers.ts +123 -0
- package/src/drizzle/proof-model.ts +12 -123
- package/src/drizzle/proof-target.ts +38 -102
- package/src/drizzle/session-drivers.ts +696 -0
- package/src/drizzle/session-model.ts +54 -118
- package/src/drizzle/sqlite-do-database.ts +8 -0
- package/src/drizzle/sqlite-identity.ts +4 -22
- package/src/drizzle/step-up-model.ts +13 -37
- package/src/drizzle/storage-validation.ts +2 -1
- package/src/drizzle/totp-model.ts +20 -77
- package/src/drizzle/totp-target.ts +121 -261
- package/src/drizzle/transaction-handle.ts +41 -0
- package/src/drizzle/transaction-mysql.ts +91 -26
- package/src/index.ts +7 -122
- package/src/internal/drizzle-postgres.ts +4 -7
- package/src/internal/drizzle-sqlite.ts +4 -7
- package/dist/drizzle/crypto.mjs +0 -11
- package/dist/drizzle/crypto.mjs.map +0 -1
- package/dist/drizzle/d1-emails.d.mts +0 -62
- package/dist/drizzle/d1-emails.mjs +0 -626
- package/dist/drizzle/d1-emails.mjs.map +0 -1
- package/dist/drizzle/d1-generated-statement.mjs +0 -79
- package/dist/drizzle/d1-generated-statement.mjs.map +0 -1
- package/dist/drizzle/d1-oauth.d.mts +0 -331
- package/dist/drizzle/d1-oauth.mjs +0 -79
- package/dist/drizzle/d1-oauth.mjs.map +0 -1
- package/dist/drizzle/d1-passkey.d.mts +0 -37
- package/dist/drizzle/d1-passkey.mjs +0 -98
- package/dist/drizzle/d1-passkey.mjs.map +0 -1
- package/dist/drizzle/d1-password-prepared.d.mts +0 -25
- package/dist/drizzle/d1-password-prepared.mjs +0 -473
- package/dist/drizzle/d1-password-prepared.mjs.map +0 -1
- package/dist/drizzle/d1-passwords.d.mts +0 -70
- package/dist/drizzle/d1-passwords.mjs +0 -808
- package/dist/drizzle/d1-passwords.mjs.map +0 -1
- package/dist/drizzle/d1-phone.d.mts +0 -23
- package/dist/drizzle/d1-phone.mjs +0 -33
- package/dist/drizzle/d1-phone.mjs.map +0 -1
- package/dist/drizzle/d1-planning.d.mts +0 -11
- package/dist/drizzle/d1-planning.mjs +0 -43
- package/dist/drizzle/d1-planning.mjs.map +0 -1
- package/dist/drizzle/d1-proofs.d.mts +0 -80
- package/dist/drizzle/d1-proofs.mjs +0 -842
- package/dist/drizzle/d1-proofs.mjs.map +0 -1
- package/dist/drizzle/d1-sessions.d.mts +0 -68
- package/dist/drizzle/d1-sessions.mjs +0 -987
- package/dist/drizzle/d1-sessions.mjs.map +0 -1
- package/dist/drizzle/d1-totp.d.mts +0 -23
- package/dist/drizzle/d1-totp.mjs +0 -30
- package/dist/drizzle/d1-totp.mjs.map +0 -1
- package/dist/drizzle/email-registration.d.mts +0 -33
- package/dist/drizzle/email-registration.mjs +0 -281
- package/dist/drizzle/email-registration.mjs.map +0 -1
- package/dist/drizzle/email-sql.d.mts +0 -1
- package/dist/drizzle/email-sql.mjs +0 -9
- package/dist/drizzle/email-sql.mjs.map +0 -1
- package/dist/drizzle/mysql-emails.d.mts +0 -71
- package/dist/drizzle/mysql-emails.mjs +0 -43
- package/dist/drizzle/mysql-emails.mjs.map +0 -1
- package/dist/drizzle/mysql-password-prepared.d.mts +0 -30
- package/dist/drizzle/mysql-password-prepared.mjs +0 -21
- package/dist/drizzle/mysql-password-prepared.mjs.map +0 -1
- package/dist/drizzle/mysql-passwords.d.mts +0 -71
- package/dist/drizzle/mysql-passwords.mjs +0 -43
- package/dist/drizzle/mysql-passwords.mjs.map +0 -1
- package/dist/drizzle/mysql-proofs.d.mts +0 -75
- package/dist/drizzle/mysql-proofs.mjs +0 -28
- package/dist/drizzle/mysql-proofs.mjs.map +0 -1
- package/dist/drizzle/mysql-sessions.d.mts +0 -92
- package/dist/drizzle/mysql-sessions.mjs +0 -58
- package/dist/drizzle/mysql-sessions.mjs.map +0 -1
- package/dist/drizzle/oauth-connected-model.mjs.map +0 -1
- package/dist/drizzle/oauth-connected-target.d.mts +0 -6
- package/dist/drizzle/oauth-connected-target.mjs +0 -12
- package/dist/drizzle/oauth-connected-target.mjs.map +0 -1
- package/dist/drizzle/oauth-kernel.mjs +0 -11
- package/dist/drizzle/oauth-kernel.mjs.map +0 -1
- package/dist/drizzle/oauth-mysql.mjs +0 -8
- package/dist/drizzle/oauth-mysql.mjs.map +0 -1
- package/dist/drizzle/passkey-kernel.mjs +0 -8
- package/dist/drizzle/passkey-kernel.mjs.map +0 -1
- package/dist/drizzle/passkey-model.mjs.map +0 -1
- package/dist/drizzle/passkey-registration-ceremony-model.mjs +0 -2
- package/dist/drizzle/passkey-state.mjs +0 -7
- package/dist/drizzle/passkey-state.mjs.map +0 -1
- package/dist/drizzle/passkey-target.d.mts +0 -2
- package/dist/drizzle/passkey-target.mjs +0 -7
- package/dist/drizzle/passkey-target.mjs.map +0 -1
- package/dist/drizzle/passkey-write-target.d.mts +0 -5
- package/dist/drizzle/passkey-write-target.mjs +0 -7
- package/dist/drizzle/passkey-write-target.mjs.map +0 -1
- package/dist/drizzle/password-prepared-model.d.mts +0 -92
- package/dist/drizzle/password-prepared-model.mjs +0 -11
- package/dist/drizzle/password-prepared-model.mjs.map +0 -1
- package/dist/drizzle/password-prepared-sql.mjs +0 -395
- package/dist/drizzle/password-prepared-sql.mjs.map +0 -1
- package/dist/drizzle/password-prepared-state.mjs +0 -104
- package/dist/drizzle/password-prepared-state.mjs.map +0 -1
- package/dist/drizzle/password-prepared-target.d.mts +0 -13
- package/dist/drizzle/password-prepared-target.mjs +0 -62
- package/dist/drizzle/password-prepared-target.mjs.map +0 -1
- package/dist/drizzle/password-registration.d.mts +0 -7
- package/dist/drizzle/password-registration.mjs +0 -137
- package/dist/drizzle/password-registration.mjs.map +0 -1
- package/dist/drizzle/password-sql.d.mts +0 -1
- package/dist/drizzle/password-sql.mjs +0 -10
- package/dist/drizzle/password-sql.mjs.map +0 -1
- package/dist/drizzle/pg-emails.d.mts +0 -72
- package/dist/drizzle/pg-emails.mjs +0 -43
- package/dist/drizzle/pg-emails.mjs.map +0 -1
- package/dist/drizzle/pg-password-prepared.d.mts +0 -31
- package/dist/drizzle/pg-password-prepared.mjs +0 -21
- package/dist/drizzle/pg-password-prepared.mjs.map +0 -1
- package/dist/drizzle/pg-passwords.d.mts +0 -72
- package/dist/drizzle/pg-passwords.mjs +0 -43
- package/dist/drizzle/pg-passwords.mjs.map +0 -1
- package/dist/drizzle/pg-proofs.d.mts +0 -76
- package/dist/drizzle/pg-proofs.mjs +0 -27
- package/dist/drizzle/pg-proofs.mjs.map +0 -1
- package/dist/drizzle/pg-sessions.d.mts +0 -93
- package/dist/drizzle/pg-sessions.mjs +0 -58
- package/dist/drizzle/pg-sessions.mjs.map +0 -1
- package/dist/drizzle/phone-state.mjs +0 -14
- package/dist/drizzle/phone-state.mjs.map +0 -1
- package/dist/drizzle/phone-target.d.mts +0 -15
- package/dist/drizzle/proof-sql.d.mts +0 -1
- package/dist/drizzle/proof-sql.mjs +0 -8
- package/dist/drizzle/proof-sql.mjs.map +0 -1
- package/dist/drizzle/query-operations.mjs +0 -31
- package/dist/drizzle/query-operations.mjs.map +0 -1
- package/dist/drizzle/session-sql.d.mts +0 -1
- package/dist/drizzle/session-sql.mjs +0 -9
- package/dist/drizzle/session-sql.mjs.map +0 -1
- package/dist/drizzle/session-target.d.mts +0 -30
- package/dist/drizzle/session-target.mjs +0 -49
- package/dist/drizzle/session-target.mjs.map +0 -1
- package/dist/drizzle/sqlite-emails.mjs +0 -50
- package/dist/drizzle/sqlite-emails.mjs.map +0 -1
- package/dist/drizzle/sqlite-password-prepared.mjs +0 -26
- package/dist/drizzle/sqlite-password-prepared.mjs.map +0 -1
- package/dist/drizzle/sqlite-passwords.mjs +0 -54
- package/dist/drizzle/sqlite-passwords.mjs.map +0 -1
- package/dist/drizzle/sqlite-proofs.mjs +0 -34
- package/dist/drizzle/sqlite-proofs.mjs.map +0 -1
- package/dist/drizzle/sqlite-sessions.mjs +0 -79
- package/dist/drizzle/sqlite-sessions.mjs.map +0 -1
- package/dist/drizzle/standalone-guard.d.mts +0 -2
- package/dist/drizzle/standalone-guard.mjs +0 -21
- package/dist/drizzle/standalone-guard.mjs.map +0 -1
- package/dist/drizzle/totp-state.d.mts +0 -37
- package/dist/drizzle/totp-state.mjs +0 -287
- package/dist/drizzle/totp-state.mjs.map +0 -1
- package/dist/drizzle/totp-target.d.mts +0 -15
- package/dist/drizzle/transaction-execution.d.mts +0 -2
- package/dist/drizzle/transaction-execution.mjs +0 -11
- package/dist/drizzle/transaction-execution.mjs.map +0 -1
- package/dist/drizzle/transaction-owner.d.mts +0 -1
- package/dist/drizzle/transaction-owner.mjs +0 -8
- package/dist/drizzle/transaction-owner.mjs.map +0 -1
- package/src/drizzle/crypto.ts +0 -14
- package/src/drizzle/d1-emails.ts +0 -1945
- package/src/drizzle/d1-generated-statement.ts +0 -129
- package/src/drizzle/d1-oauth.ts +0 -360
- package/src/drizzle/d1-passkey.ts +0 -383
- package/src/drizzle/d1-password-prepared.ts +0 -1266
- package/src/drizzle/d1-passwords.ts +0 -2061
- package/src/drizzle/d1-phone.ts +0 -103
- package/src/drizzle/d1-planning.ts +0 -104
- package/src/drizzle/d1-proofs.ts +0 -2354
- package/src/drizzle/d1-sessions.ts +0 -2940
- package/src/drizzle/d1-totp.ts +0 -88
- package/src/drizzle/email-registration.ts +0 -850
- package/src/drizzle/email-sql.ts +0 -25
- package/src/drizzle/mysql-emails.ts +0 -343
- package/src/drizzle/mysql-password-prepared.ts +0 -198
- package/src/drizzle/mysql-passwords.ts +0 -343
- package/src/drizzle/mysql-proofs.ts +0 -196
- package/src/drizzle/mysql-sessions.ts +0 -780
- package/src/drizzle/oauth-connected-target.ts +0 -21
- package/src/drizzle/oauth-kernel.ts +0 -10
- package/src/drizzle/oauth-mysql.ts +0 -10
- package/src/drizzle/passkey-kernel.ts +0 -4
- package/src/drizzle/passkey-state.ts +0 -3
- package/src/drizzle/passkey-target.ts +0 -23
- package/src/drizzle/passkey-write-target.ts +0 -9
- package/src/drizzle/password-prepared-model.ts +0 -241
- package/src/drizzle/password-prepared-sql.ts +0 -1202
- package/src/drizzle/password-prepared-state.ts +0 -231
- package/src/drizzle/password-prepared-target.ts +0 -169
- package/src/drizzle/password-registration.ts +0 -369
- package/src/drizzle/password-sql.ts +0 -16
- package/src/drizzle/pg-emails.ts +0 -343
- package/src/drizzle/pg-password-prepared.ts +0 -199
- package/src/drizzle/pg-passwords.ts +0 -342
- package/src/drizzle/pg-proofs.ts +0 -206
- package/src/drizzle/pg-sessions.ts +0 -789
- package/src/drizzle/phone-state.ts +0 -21
- package/src/drizzle/proof-sql.ts +0 -10
- package/src/drizzle/query-operations.ts +0 -49
- package/src/drizzle/session-sql.ts +0 -15
- package/src/drizzle/session-target.ts +0 -337
- package/src/drizzle/sqlite-emails.ts +0 -393
- package/src/drizzle/sqlite-password-prepared.ts +0 -230
- package/src/drizzle/sqlite-passwords.ts +0 -497
- package/src/drizzle/sqlite-proofs.ts +0 -229
- package/src/drizzle/sqlite-sessions.ts +0 -1013
- package/src/drizzle/totp-state.ts +0 -525
- package/src/drizzle/transaction-execution.ts +0 -13
- package/src/drizzle/transaction-owner.ts +0 -11
package/dist/D1.d.mts
CHANGED
|
@@ -1,1192 +1,536 @@
|
|
|
1
|
+
import { EmailAddressMapping, EmailRegistrationMapping, EmailSignInMapping } from "./drizzle/email-model.mjs";
|
|
2
|
+
import { PasswordPersistenceMapping, PasswordRegistrationMapping } from "./drizzle/password-model.mjs";
|
|
3
|
+
import { ProofPersistenceMapping } from "./drizzle/proof-model.mjs";
|
|
1
4
|
import { D1ExternalIdentityMapping, D1GeneratedIdentityMapping, D1SubjectProvisioningMapping } from "./drizzle/model.mjs";
|
|
2
|
-
import {
|
|
5
|
+
import { AuthenticationAuthorityMapping, PendingAuthenticationMapping, SessionCleanupMapping, SignedSessionValidityMapping, StatefulSessionMapping } from "./drizzle/session-model.mjs";
|
|
6
|
+
import { D1PasskeyMapping, PasskeyCredentialMapping, PasskeyPersistenceMapping } from "./drizzle/passkey-model.mjs";
|
|
7
|
+
import { SessionStepUpMapping } from "./drizzle/step-up-model.mjs";
|
|
8
|
+
import { OAuthAccountsMapping, OAuthD1Mapping, OAuthRegistrationIntentMapping, OAuthRegistrationMapping, OAuthSignInMapping } from "./drizzle/oauth-model.mjs";
|
|
3
9
|
import { OAuthConnectedMapping, OAuthConnectedRevocationMapping } from "./drizzle/oauth-connected-model.mjs";
|
|
4
|
-
import {
|
|
10
|
+
import { PasskeyRegistrationCeremonyMapping } from "./drizzle/passkey-registration-ceremony-model.mjs";
|
|
11
|
+
import { NativeDatabase } from "./drizzle/native-database.mjs";
|
|
12
|
+
import { D1BatchStatements } from "./drizzle/D1BatchStatements.mjs";
|
|
13
|
+
import { OAuthCoordinatorError } from "./drizzle/oauth-target.mjs";
|
|
14
|
+
import { TotpMapping } from "./drizzle/totp-model.mjs";
|
|
15
|
+
import { PasskeyManagementMapping, PasskeyRegistrationMapping } from "./drizzle/passkey-write-model.mjs";
|
|
16
|
+
import { PasskeyCoordinatorError } from "./drizzle/passkey/target.mjs";
|
|
17
|
+
import { PhoneMapping } from "./drizzle/phone-model.mjs";
|
|
5
18
|
import "./index.mjs";
|
|
19
|
+
import { NativeDriverTransaction } from "./drizzle/driver-types.mjs";
|
|
20
|
+
import { SuppliedService } from "./drizzle/SuppliedService.mjs";
|
|
6
21
|
import { OAuthProxyPersistence } from "./internal/drizzle-sqlite-oauth-proxy.mjs";
|
|
7
22
|
import { Database } from "./drizzle/d1-database.mjs";
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { coordinateD1OAuthAccounts, coordinateD1OAuthRegistration, coordinateD1OAuthRegistrationIntents, coordinateD1OAuthSignIn, makeD1OAuthAccountsServices, makeD1OAuthRegistrationIntentServices, makeD1OAuthRegistrationServices, makeD1OAuthSignInServices } from "./drizzle/d1-oauth.mjs";
|
|
11
|
-
import { coordinateD1AuthenticationAuthority, coordinateD1PendingAuthentication, coordinateD1SessionStepUp, coordinateD1SignedSessionValidity, coordinateD1StatefulSessions, makeD1AuthenticationAuthorityServices, makeD1PendingAuthenticationServices, makeD1SessionStepUpServices, makeD1SignedSessionValidityServices, makeD1StatefulSessionServices } from "./drizzle/d1-sessions.mjs";
|
|
12
|
-
import { coordinateD1ProofPersistence, makeD1ProofPersistenceServices } from "./drizzle/d1-proofs.mjs";
|
|
13
|
-
import { coordinateD1PasswordPersistence, coordinateD1PasswordRegistration, makeD1PasswordPersistenceServices, makeD1PasswordRegistrationServices } from "./drizzle/d1-passwords.mjs";
|
|
14
|
-
import { coordinateD1EmailAddress, coordinateD1EmailRegistration, makeD1EmailAddressServices, makeD1EmailRegistrationServices, makeD1EmailSignInServices } from "./drizzle/d1-emails.mjs";
|
|
15
|
-
import { coordinateD1PasswordPreparedPersistence, makeD1PasswordPreparedPersistenceServices } from "./drizzle/d1-password-prepared.mjs";
|
|
16
|
-
import { coordinatePasskeyManagement, coordinatePasskeyPersistence, coordinatePasskeyRegistration, coordinatePasskeyRegistrationCeremony, makePasskeyCredentialServices, makePasskeyEnrollmentContextServices, makePasskeyManagementServices, makePasskeyPersistenceServices, makePasskeyRegistrationCeremonyServices, makePasskeyRegistrationServices } from "./drizzle/d1-passkey.mjs";
|
|
17
|
-
import { coordinatePhonePersistence, makePhonePersistenceServices } from "./drizzle/d1-phone.mjs";
|
|
18
|
-
import "./D1.mjs";
|
|
19
|
-
import { Effect, Layer } from "effect";
|
|
23
|
+
import { AnyRelations } from "drizzle-orm";
|
|
24
|
+
import { Layer } from "effect";
|
|
20
25
|
import { AnySQLiteTable } from "drizzle-orm/sqlite-core";
|
|
21
26
|
import { EffectSQLiteD1Database } from "drizzle-orm/effect-d1";
|
|
22
27
|
import { D1Client } from "@effect/sql-d1/D1Client";
|
|
23
28
|
//#region src/D1.d.ts
|
|
24
|
-
export declare const
|
|
29
|
+
export declare const coordinateProofPersistence: {
|
|
30
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
31
|
+
readonly $client: D1Client;
|
|
32
|
+
}, Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
33
|
+
readonly mapping: ProofPersistenceMapping<Proof, Subject, NativeId>;
|
|
34
|
+
readonly transaction?: never;
|
|
35
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Proofs").ProofUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Proofs").ProofPersistence>>;
|
|
36
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
37
|
+
readonly $client: D1Client;
|
|
38
|
+
}, Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
39
|
+
readonly mapping: ProofPersistenceMapping<Proof, Subject, NativeId>;
|
|
40
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
41
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Proofs").ProofUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Proofs").ProofPersistence>>;
|
|
42
|
+
}, makeProofPersistenceServices: <Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId>(mapping: ProofPersistenceMapping<Proof, Subject, NativeId>) => import("effect/Effect").Effect<{
|
|
43
|
+
readonly proofPersistence: import("@yielded/auth/Proofs").ProofPersistence["Service"];
|
|
44
|
+
}, import("@yielded/auth/Proofs").ProofUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
45
|
+
export declare const coordinatePasswordPersistence: {
|
|
46
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
47
|
+
readonly $client: D1Client;
|
|
48
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
49
|
+
readonly mapping: PasswordPersistenceMapping<S, I, C, AC, N>;
|
|
50
|
+
readonly transaction?: never;
|
|
51
|
+
} & {
|
|
52
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
53
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Password").PasswordPersistence>>;
|
|
54
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
55
|
+
readonly $client: D1Client;
|
|
56
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
57
|
+
readonly mapping: PasswordPersistenceMapping<S, I, C, AC, N>;
|
|
58
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
59
|
+
} & {
|
|
60
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
61
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Password").PasswordPersistence>>;
|
|
62
|
+
}, coordinatePasswordRegistration: {
|
|
63
|
+
<TargetId, Registration, Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
64
|
+
readonly $client: D1Client;
|
|
65
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
66
|
+
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
67
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
68
|
+
readonly transaction?: never;
|
|
69
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
70
|
+
<TargetId, Registration, Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
71
|
+
readonly $client: D1Client;
|
|
72
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
73
|
+
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
74
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
75
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
76
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
77
|
+
}, makePasswordPersistenceServices: <S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN>(mapping: PasswordPersistenceMapping<S, I, C, AC, N>, proofMapping?: ProofPersistenceMapping<Proof, PS, PN> | undefined) => import("effect/Effect").Effect<{
|
|
78
|
+
readonly passwordPersistence: import("@yielded/auth/Password").PasswordPersistence["Service"];
|
|
79
|
+
}, import("@yielded/auth/Password").PasswordUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makePasswordRegistrationServices: <Registration, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N>(mapping: PasswordRegistrationMapping<Registration, S, I, C, AC, N>) => import("effect/Effect").Effect<{
|
|
80
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>;
|
|
81
|
+
}, import("@yielded/auth/Password").PasswordUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
82
|
+
export declare const makeEmailSignInServices: <S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N>(mapping: EmailSignInMapping<S, I, C, AC, N>) => import("effect/Effect").Effect<{
|
|
83
|
+
readonly emailSignInTargets: import("@yielded/auth/Email").EmailSignInTargets["Service"];
|
|
84
|
+
}, import("@yielded/auth/Email").EmailUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailAddressServices: <S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN>(mapping: EmailAddressMapping<S, I, C, AC, N>, proofMapping?: ProofPersistenceMapping<Proof, PS, PN> | undefined) => import("effect/Effect").Effect<{
|
|
85
|
+
readonly emailAddressPersistence: import("@yielded/auth/Email").EmailAddressPersistence["Service"];
|
|
86
|
+
}, import("@yielded/auth/Email").EmailUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailRegistrationServices: <Registration, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N>(mapping: EmailRegistrationMapping<Registration, S, I, C, AC, N>, proofs: ProofPersistenceMapping<Proof, PS, PN>) => import("effect/Effect").Effect<{
|
|
87
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>;
|
|
88
|
+
}, import("@yielded/auth/Email").EmailUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateEmailAddress: {
|
|
89
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
90
|
+
readonly $client: D1Client;
|
|
91
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
92
|
+
readonly mapping: EmailAddressMapping<S, I, C, AC, N>;
|
|
93
|
+
readonly transaction?: never;
|
|
94
|
+
} & {
|
|
95
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
96
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Email").EmailAddressPersistence>>;
|
|
97
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
98
|
+
readonly $client: D1Client;
|
|
99
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
100
|
+
readonly mapping: EmailAddressMapping<S, I, C, AC, N>;
|
|
101
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
102
|
+
} & {
|
|
103
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
104
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Email").EmailAddressPersistence>>;
|
|
105
|
+
}, coordinateEmailRegistration: {
|
|
106
|
+
<TargetId, Registration, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
107
|
+
readonly $client: D1Client;
|
|
108
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
109
|
+
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
110
|
+
readonly proofMapping: ProofPersistenceMapping<Proof, PS, PN>;
|
|
111
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>>;
|
|
112
|
+
readonly transaction?: never;
|
|
113
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
114
|
+
<TargetId, Registration, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
115
|
+
readonly $client: D1Client;
|
|
116
|
+
}, S extends import("drizzle-orm").Table, I extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, AC extends import("drizzle-orm").Table, N, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
117
|
+
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
118
|
+
readonly proofMapping: ProofPersistenceMapping<Proof, PS, PN>;
|
|
119
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>>;
|
|
120
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
121
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
122
|
+
};
|
|
123
|
+
export declare const makeSubjectProvisioningServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: D1SubjectProvisioningMapping<Subject, Identifier, Request, NativeId>) => import("effect/Effect").Effect<{
|
|
25
124
|
readonly subjectProvisioner: {
|
|
26
|
-
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").
|
|
125
|
+
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => import("effect/Effect").Effect<import("@yielded/auth/Identity").SubjectProvisioned, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
27
126
|
};
|
|
28
127
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
29
|
-
export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTable, External extends AnySQLiteTable, NativeId>(mapping: D1ExternalIdentityMapping<Subject, External, NativeId>) => Effect.Effect<{
|
|
128
|
+
export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTable, External extends AnySQLiteTable, NativeId>(mapping: D1ExternalIdentityMapping<Subject, External, NativeId>) => import("effect/Effect").Effect<{
|
|
30
129
|
readonly externalIdentityMutation: {
|
|
31
|
-
readonly bind: (subjectId: import("@yielded/auth/Schema").SubjectId, identity: import("@yielded/auth/Identity").ExternalIdentity) => Effect.Effect<void, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
130
|
+
readonly bind: (subjectId: import("@yielded/auth/Schema").SubjectId, identity: import("@yielded/auth/Identity").ExternalIdentity) => import("effect/Effect").Effect<void, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
32
131
|
};
|
|
33
132
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
34
|
-
export declare const
|
|
35
|
-
export declare const makeIdentityServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, External extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: D1GeneratedIdentityMapping<Subject, Identifier, External, Request, NativeId>) => Effect.Effect<{
|
|
133
|
+
export declare const makeIdentityServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, External extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: D1GeneratedIdentityMapping<Subject, Identifier, External, Request, NativeId>) => import("effect/Effect").Effect<{
|
|
36
134
|
subjectProvisioner: {
|
|
37
|
-
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").
|
|
135
|
+
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => import("effect/Effect").Effect<import("@yielded/auth/Identity").SubjectProvisioned, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
38
136
|
};
|
|
39
137
|
externalIdentityMutation: {
|
|
40
|
-
readonly bind: (subjectId: import("@yielded/auth/Schema").SubjectId, identity: import("@yielded/auth/Identity").ExternalIdentity) => Effect.Effect<void, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
138
|
+
readonly bind: (subjectId: import("@yielded/auth/Schema").SubjectId, identity: import("@yielded/auth/Identity").ExternalIdentity) => import("effect/Effect").Effect<void, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
41
139
|
};
|
|
42
140
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
}>, F extends
|
|
52
|
-
|
|
53
|
-
}>,
|
|
54
|
-
|
|
55
|
-
}>, C extends
|
|
56
|
-
|
|
57
|
-
}>,
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
readonly
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
128
|
-
readonly metadata: {
|
|
129
|
-
readonly scopes: readonly string[];
|
|
130
|
-
readonly resources: readonly string[];
|
|
131
|
-
readonly accessExpiresAtMillis?: number;
|
|
132
|
-
readonly refreshExpiresAtMillis?: number;
|
|
133
|
-
readonly useUntilMillis: number;
|
|
134
|
-
readonly refreshUseUntilMillis?: number;
|
|
135
|
-
readonly obtainedAtMillis: number;
|
|
136
|
-
readonly profile?: {
|
|
137
|
-
readonly displayName?: string;
|
|
138
|
-
readonly handle?: string;
|
|
139
|
-
readonly avatarUrl?: string;
|
|
140
|
-
readonly profileUrl?: string;
|
|
141
|
-
readonly email?: string;
|
|
142
|
-
readonly emailVerified?: boolean;
|
|
143
|
-
readonly providerData?: {
|
|
144
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
145
|
-
};
|
|
146
|
-
};
|
|
147
|
-
};
|
|
148
|
-
};
|
|
149
|
-
readonly sealed: {
|
|
150
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
151
|
-
readonly keyId: string;
|
|
152
|
-
readonly nonce: string;
|
|
153
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
154
|
-
};
|
|
155
|
-
};
|
|
156
|
-
} | {
|
|
157
|
-
readonly _tag: "Busy";
|
|
158
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
159
|
-
readonly capture: (input: {
|
|
160
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
141
|
+
type D1Database = EffectSQLiteD1Database<AnyRelations> & {
|
|
142
|
+
readonly $client: D1Client;
|
|
143
|
+
};
|
|
144
|
+
type D1Table = AnySQLiteTable<{
|
|
145
|
+
dialect: "sqlite";
|
|
146
|
+
}>;
|
|
147
|
+
export declare const makeOAuthAccountsServices: <S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N>(mapping: OAuthAccountsMapping<S, O, C, AC, F, N> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
148
|
+
readonly oauthAccountsPersistence: import("@yielded/auth/OAuth").OAuthAccountsPersistence["Service"];
|
|
149
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthSignInServices: <S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N>(mapping: OAuthSignInMapping<S, O, C, AC, F, N> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
150
|
+
readonly oauthSignInPersistence: import("@yielded/auth/OAuth").OAuthSignInPersistence["Service"];
|
|
151
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationIntentServices: <O extends D1Table, I extends D1Table, N>(mapping: OAuthRegistrationIntentMapping<O, I, N> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
152
|
+
readonly oauthRegistrationIntents: import("@yielded/auth/OAuth").OAuthRegistrationIntents["Service"];
|
|
153
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationServices: <Registration, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, I extends D1Table, N>(mapping: OAuthRegistrationMapping<Registration, S, O, C, AC, I, N> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
154
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>;
|
|
155
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthRegistration: {
|
|
156
|
+
<Database extends D1Database, TargetId, Registration, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, I extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
157
|
+
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC, I, N> & OAuthD1Mapping;
|
|
158
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>>;
|
|
159
|
+
readonly transaction?: never;
|
|
160
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | D1BatchStatements>>;
|
|
161
|
+
<Database extends D1Database, TargetId, Registration, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, I extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
162
|
+
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC, I, N> & OAuthD1Mapping;
|
|
163
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>>;
|
|
164
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
165
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId | D1BatchStatements>>;
|
|
166
|
+
}, coordinateOAuthSignIn: {
|
|
167
|
+
<Database extends D1Database, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
168
|
+
readonly mapping: OAuthSignInMapping<S, O, C, AC, F, N> & OAuthD1Mapping;
|
|
169
|
+
readonly transaction?: never;
|
|
170
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/OAuth").OAuthSignInPersistence>>;
|
|
171
|
+
<Database extends D1Database, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
172
|
+
readonly mapping: OAuthSignInMapping<S, O, C, AC, F, N> & OAuthD1Mapping;
|
|
173
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
174
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/OAuth").OAuthSignInPersistence>>;
|
|
175
|
+
}, coordinateOAuthRegistrationIntents: {
|
|
176
|
+
<Database extends D1Database, O extends D1Table, I extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
177
|
+
readonly mapping: OAuthRegistrationIntentMapping<O, I, N> & OAuthD1Mapping;
|
|
178
|
+
readonly transaction?: never;
|
|
179
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/OAuth").OAuthRegistrationIntents>>;
|
|
180
|
+
<Database extends D1Database, O extends D1Table, I extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
181
|
+
readonly mapping: OAuthRegistrationIntentMapping<O, I, N> & OAuthD1Mapping;
|
|
182
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
183
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/OAuth").OAuthRegistrationIntents>>;
|
|
184
|
+
}, coordinateOAuthAccounts: {
|
|
185
|
+
<Database extends D1Database, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
186
|
+
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F, N> & OAuthD1Mapping;
|
|
187
|
+
readonly transaction?: never;
|
|
188
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/OAuth").OAuthAccountsPersistence>>;
|
|
189
|
+
<Database extends D1Database, S extends D1Table, O extends D1Table, C extends D1Table, AC extends D1Table, F extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
190
|
+
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F, N> & OAuthD1Mapping;
|
|
191
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
192
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/OAuth").OAuthAccountsPersistence>>;
|
|
193
|
+
}, makeOAuthConnectedServices: <S extends D1Table, AC extends D1Table, O extends D1Table, F extends D1Table, G extends D1Table, N, J extends D1Table = never>(mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
194
|
+
readonly oauthConnectedPersistence: import("@yielded/auth/OAuth").OAuthConnectedPersistence["Service"];
|
|
195
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthConnectedRevocationServices: <O extends D1Table, F extends D1Table, J extends D1Table, N>(mapping: OAuthConnectedRevocationMapping<O, F, J, N> & OAuthD1Mapping) => import("effect/Effect").Effect<{
|
|
196
|
+
readonly oauthConnectedRevocations: import("@yielded/auth/OAuth").OAuthConnectedRevocations["Service"];
|
|
197
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthConnected: {
|
|
198
|
+
<D extends D1Database, S extends D1Table, AC extends D1Table, O extends D1Table, F extends D1Table, G extends D1Table, N, J extends D1Table, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
199
|
+
readonly mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J> & OAuthD1Mapping;
|
|
200
|
+
readonly transaction?: never;
|
|
201
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/OAuth").OAuthConnectedPersistence>>;
|
|
202
|
+
<D extends D1Database, S extends D1Table, AC extends D1Table, O extends D1Table, F extends D1Table, G extends D1Table, N, J extends D1Table, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
203
|
+
readonly mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J> & OAuthD1Mapping;
|
|
204
|
+
readonly transaction: SuppliedService<TxId, NoInfer<D extends {
|
|
205
|
+
readonly transaction: (...args: any[]) => any;
|
|
206
|
+
} ? Parameters<Parameters<D["transaction"]>[0]>[0] : never>, TxShape>;
|
|
207
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/OAuth").OAuthConnectedPersistence>>;
|
|
208
|
+
}, coordinateOAuthConnectedRevocations: {
|
|
209
|
+
<D extends D1Database, O extends D1Table, F extends D1Table, J extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: import("effect/Effect").Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
210
|
+
readonly mapping: OAuthConnectedRevocationMapping<O, F, J, N> & OAuthD1Mapping;
|
|
211
|
+
readonly transaction?: never;
|
|
212
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/OAuth").OAuthConnectedRevocations>>;
|
|
213
|
+
<D extends D1Database, O extends D1Table, F extends D1Table, J extends D1Table, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: import("effect/Effect").Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
214
|
+
readonly mapping: OAuthConnectedRevocationMapping<O, F, J, N> & OAuthD1Mapping;
|
|
215
|
+
readonly transaction: SuppliedService<TxId, NoInfer<D extends {
|
|
216
|
+
readonly transaction: (...args: any[]) => any;
|
|
217
|
+
} ? Parameters<Parameters<D["transaction"]>[0]>[0] : never>, TxShape>;
|
|
218
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/OAuth").OAuthConnectedRevocations>>;
|
|
219
|
+
};
|
|
220
|
+
export declare const makePasskeyCredentialServices: <S extends D1Table, C extends D1Table, F extends D1Table, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyCredentialMapping<S, C, F, N> & D1PasskeyMapping, RSetup>) => import("effect/Effect").Effect<{
|
|
221
|
+
passkeyCredentials: {
|
|
222
|
+
readonly listForSubject: (input: {
|
|
223
|
+
readonly moduleId: string;
|
|
224
|
+
readonly rpId: string;
|
|
161
225
|
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
readonly
|
|
165
|
-
readonly
|
|
166
|
-
} | undefined, import("@yielded/auth/
|
|
226
|
+
}) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyEnrollmentSnapshot | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
227
|
+
readonly lookup: (input: {
|
|
228
|
+
readonly rpId: string;
|
|
229
|
+
readonly protocolCredentialId: import("@yielded/auth/Passkey").PasskeyProtocolCredentialId;
|
|
230
|
+
}) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyCredential | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
231
|
+
};
|
|
232
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | Exclude<RSetup, NativeDatabase>>, makePasskeyPersistenceServices: <S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N> & D1PasskeyMapping, RSetup>) => import("effect/Effect").Effect<{
|
|
233
|
+
passkeyPersistence: {
|
|
167
234
|
readonly issue: <A>(input: {
|
|
168
|
-
readonly
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
readonly
|
|
174
|
-
readonly
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
readonly scopes: readonly string[];
|
|
225
|
-
readonly resources: readonly string[];
|
|
226
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
227
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
228
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
229
|
-
readonly refreshAheadMillis: number;
|
|
230
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
231
|
-
readonly revocation: "cohort" | "unsupported";
|
|
232
|
-
};
|
|
233
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
234
|
-
readonly reconnect?: {
|
|
235
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
236
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
237
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
238
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
239
|
-
readonly identity: {
|
|
240
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
241
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
242
|
-
readonly subject: string;
|
|
243
|
-
};
|
|
244
|
-
readonly configuration: {
|
|
245
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
246
|
-
readonly protocol: "oauth" | "oidc";
|
|
247
|
-
readonly configurationGeneration: number;
|
|
248
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
249
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
250
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
251
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
252
|
-
readonly profile: {
|
|
253
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
254
|
-
readonly generation: number;
|
|
255
|
-
readonly issuance: "active" | "retired";
|
|
256
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
257
|
-
readonly clientRegistrationId: string;
|
|
258
|
-
readonly scopes: readonly string[];
|
|
259
|
-
readonly resources: readonly string[];
|
|
260
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
261
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
262
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
263
|
-
readonly refreshAheadMillis: number;
|
|
264
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
265
|
-
readonly revocation: "cohort" | "unsupported";
|
|
266
|
-
};
|
|
267
|
-
};
|
|
268
|
-
};
|
|
269
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
270
|
-
};
|
|
271
|
-
readonly sealed: {
|
|
272
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
273
|
-
readonly keyId: string;
|
|
274
|
-
readonly nonce: string;
|
|
275
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
276
|
-
};
|
|
277
|
-
readonly retentionUntilMillis: number;
|
|
278
|
-
};
|
|
279
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
280
|
-
readonly prepare: <A>(input: {
|
|
281
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
282
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
283
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
284
|
-
readonly _tag: "Rejected";
|
|
285
|
-
} | {
|
|
286
|
-
readonly _tag: "Issued";
|
|
287
|
-
readonly flow: {
|
|
288
|
-
readonly context: {
|
|
289
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
290
|
-
readonly protocol: "oauth" | "oidc";
|
|
291
|
-
readonly configurationGeneration: number;
|
|
292
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
293
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
294
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
295
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
296
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
297
|
-
readonly generation: number;
|
|
298
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
299
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
300
|
-
readonly access?: {
|
|
301
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
302
|
-
readonly generation: number;
|
|
303
|
-
readonly issuance: "active" | "retired";
|
|
304
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
305
|
-
readonly clientRegistrationId: string;
|
|
306
|
-
readonly scopes: readonly string[];
|
|
307
|
-
readonly resources: readonly string[];
|
|
308
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
309
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
310
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
311
|
-
readonly refreshAheadMillis: number;
|
|
312
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
313
|
-
readonly revocation: "cohort" | "unsupported";
|
|
314
|
-
};
|
|
315
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
316
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
317
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
318
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
319
|
-
readonly issuedAtMillis: number;
|
|
320
|
-
readonly expiresAtMillis: number;
|
|
321
|
-
readonly claimLifetimeMillis: number;
|
|
322
|
-
readonly namespace: "effect-auth/oauth-connected-context/v1";
|
|
323
|
-
readonly revision: {
|
|
324
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
325
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
326
|
-
readonly credentials: readonly {
|
|
327
|
-
readonly credentialId: string;
|
|
328
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
329
|
-
}[];
|
|
330
|
-
};
|
|
331
|
-
readonly profile: {
|
|
332
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
333
|
-
readonly generation: number;
|
|
334
|
-
readonly issuance: "active" | "retired";
|
|
335
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
336
|
-
readonly clientRegistrationId: string;
|
|
337
|
-
readonly scopes: readonly string[];
|
|
338
|
-
readonly resources: readonly string[];
|
|
339
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
340
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
341
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
342
|
-
readonly refreshAheadMillis: number;
|
|
343
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
344
|
-
readonly revocation: "cohort" | "unsupported";
|
|
345
|
-
};
|
|
346
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
347
|
-
readonly reconnect?: {
|
|
348
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
349
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
350
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
351
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
352
|
-
readonly identity: {
|
|
353
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
354
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
355
|
-
readonly subject: string;
|
|
356
|
-
};
|
|
357
|
-
readonly configuration: {
|
|
358
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
359
|
-
readonly protocol: "oauth" | "oidc";
|
|
360
|
-
readonly configurationGeneration: number;
|
|
361
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
362
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
363
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
364
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
365
|
-
readonly profile: {
|
|
366
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
367
|
-
readonly generation: number;
|
|
368
|
-
readonly issuance: "active" | "retired";
|
|
369
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
370
|
-
readonly clientRegistrationId: string;
|
|
371
|
-
readonly scopes: readonly string[];
|
|
372
|
-
readonly resources: readonly string[];
|
|
373
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
374
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
375
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
376
|
-
readonly refreshAheadMillis: number;
|
|
377
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
378
|
-
readonly revocation: "cohort" | "unsupported";
|
|
379
|
-
};
|
|
380
|
-
};
|
|
381
|
-
};
|
|
382
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
383
|
-
};
|
|
384
|
-
readonly sealed: {
|
|
385
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
386
|
-
readonly keyId: string;
|
|
387
|
-
readonly nonce: string;
|
|
388
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
389
|
-
};
|
|
390
|
-
readonly retentionUntilMillis: number;
|
|
391
|
-
};
|
|
392
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
393
|
-
readonly inspectPrepared: (input: import("@yielded/auth/OAuth").OAuthConnectedPreparedAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthConnectedPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
394
|
-
readonly preflight: (input: import("@yielded/auth/OAuth").OAuthConnectedAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthConnectedPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
395
|
-
readonly claim: <A>(input: {
|
|
396
|
-
readonly access: import("@yielded/auth/OAuth").OAuthConnectedAccess;
|
|
397
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
398
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
399
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
400
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
401
|
-
readonly _tag: "Rejected";
|
|
402
|
-
} | {
|
|
403
|
-
readonly _tag: "Claimed";
|
|
404
|
-
readonly claim: {
|
|
405
|
-
readonly flow: {
|
|
406
|
-
readonly context: {
|
|
407
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
408
|
-
readonly protocol: "oauth" | "oidc";
|
|
409
|
-
readonly configurationGeneration: number;
|
|
410
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
411
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
412
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
413
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
414
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
415
|
-
readonly generation: number;
|
|
416
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
417
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
418
|
-
readonly access?: {
|
|
419
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
420
|
-
readonly generation: number;
|
|
421
|
-
readonly issuance: "active" | "retired";
|
|
422
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
423
|
-
readonly clientRegistrationId: string;
|
|
424
|
-
readonly scopes: readonly string[];
|
|
425
|
-
readonly resources: readonly string[];
|
|
426
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
427
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
428
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
429
|
-
readonly refreshAheadMillis: number;
|
|
430
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
431
|
-
readonly revocation: "cohort" | "unsupported";
|
|
432
|
-
};
|
|
433
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
434
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
435
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
436
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
437
|
-
readonly issuedAtMillis: number;
|
|
438
|
-
readonly expiresAtMillis: number;
|
|
439
|
-
readonly claimLifetimeMillis: number;
|
|
440
|
-
readonly namespace: "effect-auth/oauth-connected-context/v1";
|
|
441
|
-
readonly revision: {
|
|
442
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
443
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
444
|
-
readonly credentials: readonly {
|
|
445
|
-
readonly credentialId: string;
|
|
446
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
447
|
-
}[];
|
|
448
|
-
};
|
|
449
|
-
readonly profile: {
|
|
450
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
451
|
-
readonly generation: number;
|
|
452
|
-
readonly issuance: "active" | "retired";
|
|
453
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
454
|
-
readonly clientRegistrationId: string;
|
|
455
|
-
readonly scopes: readonly string[];
|
|
456
|
-
readonly resources: readonly string[];
|
|
457
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
458
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
459
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
460
|
-
readonly refreshAheadMillis: number;
|
|
461
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
462
|
-
readonly revocation: "cohort" | "unsupported";
|
|
463
|
-
};
|
|
464
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
465
|
-
readonly reconnect?: {
|
|
466
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
467
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
468
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
469
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
470
|
-
readonly identity: {
|
|
471
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
472
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
473
|
-
readonly subject: string;
|
|
474
|
-
};
|
|
475
|
-
readonly configuration: {
|
|
476
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
477
|
-
readonly protocol: "oauth" | "oidc";
|
|
478
|
-
readonly configurationGeneration: number;
|
|
479
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
480
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
481
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
482
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
483
|
-
readonly profile: {
|
|
484
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
485
|
-
readonly generation: number;
|
|
486
|
-
readonly issuance: "active" | "retired";
|
|
487
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
488
|
-
readonly clientRegistrationId: string;
|
|
489
|
-
readonly scopes: readonly string[];
|
|
490
|
-
readonly resources: readonly string[];
|
|
491
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
492
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
493
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
494
|
-
readonly refreshAheadMillis: number;
|
|
495
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
496
|
-
readonly revocation: "cohort" | "unsupported";
|
|
497
|
-
};
|
|
498
|
-
};
|
|
499
|
-
};
|
|
500
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
501
|
-
};
|
|
502
|
-
readonly sealed: {
|
|
503
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
504
|
-
readonly keyId: string;
|
|
505
|
-
readonly nonce: string;
|
|
506
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
507
|
-
};
|
|
508
|
-
readonly retentionUntilMillis: number;
|
|
509
|
-
};
|
|
510
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
511
|
-
readonly claimedAtMillis: number;
|
|
512
|
-
readonly claimExpiresAtMillis: number;
|
|
513
|
-
readonly order: string;
|
|
514
|
-
};
|
|
515
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
516
|
-
readonly inspectGrant: (input: {
|
|
517
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedClaim;
|
|
518
|
-
readonly identity: {
|
|
519
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
520
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
521
|
-
readonly subject: string;
|
|
522
|
-
};
|
|
523
|
-
}) => Effect.Effect<{
|
|
524
|
-
readonly _tag: "Rejected";
|
|
525
|
-
} | {
|
|
526
|
-
readonly _tag: "Conflict";
|
|
527
|
-
} | {
|
|
528
|
-
readonly _tag: "Target";
|
|
529
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
530
|
-
} | {
|
|
531
|
-
readonly _tag: "Quarantine";
|
|
532
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
533
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
534
|
-
readonly settle: <A>(input: {
|
|
535
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedClaim;
|
|
536
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthConnectedOutcome;
|
|
537
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
538
|
-
readonly nowMillis: number;
|
|
539
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
540
|
-
readonly _tag: "Rejected";
|
|
541
|
-
} | {
|
|
542
|
-
readonly _tag: "Ambiguous";
|
|
543
|
-
} | {
|
|
544
|
-
readonly _tag: "Cancelled";
|
|
545
|
-
} | {
|
|
546
|
-
readonly _tag: "Conflict";
|
|
547
|
-
} | {
|
|
548
|
-
readonly _tag: "Connected";
|
|
549
|
-
readonly grant: {
|
|
550
|
-
readonly context: {
|
|
551
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
552
|
-
readonly exchangeOrder: string;
|
|
553
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
554
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
555
|
-
readonly identity: {
|
|
556
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
557
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
558
|
-
readonly subject: string;
|
|
559
|
-
};
|
|
560
|
-
readonly configuration: {
|
|
561
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
562
|
-
readonly protocol: "oauth" | "oidc";
|
|
563
|
-
readonly configurationGeneration: number;
|
|
564
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
565
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
566
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
567
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
568
|
-
readonly profile: {
|
|
569
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
570
|
-
readonly generation: number;
|
|
571
|
-
readonly issuance: "active" | "retired";
|
|
572
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
573
|
-
readonly clientRegistrationId: string;
|
|
574
|
-
readonly scopes: readonly string[];
|
|
575
|
-
readonly resources: readonly string[];
|
|
576
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
577
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
578
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
579
|
-
readonly refreshAheadMillis: number;
|
|
580
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
581
|
-
readonly revocation: "cohort" | "unsupported";
|
|
582
|
-
};
|
|
583
|
-
};
|
|
584
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
585
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
586
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
587
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
588
|
-
readonly metadata: {
|
|
589
|
-
readonly scopes: readonly string[];
|
|
590
|
-
readonly resources: readonly string[];
|
|
591
|
-
readonly accessExpiresAtMillis?: number;
|
|
592
|
-
readonly refreshExpiresAtMillis?: number;
|
|
593
|
-
readonly useUntilMillis: number;
|
|
594
|
-
readonly refreshUseUntilMillis?: number;
|
|
595
|
-
readonly obtainedAtMillis: number;
|
|
596
|
-
readonly profile?: {
|
|
597
|
-
readonly displayName?: string;
|
|
598
|
-
readonly handle?: string;
|
|
599
|
-
readonly avatarUrl?: string;
|
|
600
|
-
readonly profileUrl?: string;
|
|
601
|
-
readonly email?: string;
|
|
602
|
-
readonly emailVerified?: boolean;
|
|
603
|
-
readonly providerData?: {
|
|
604
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
605
|
-
};
|
|
606
|
-
};
|
|
607
|
-
};
|
|
608
|
-
};
|
|
609
|
-
readonly sealed: {
|
|
610
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
611
|
-
readonly keyId: string;
|
|
612
|
-
readonly nonce: string;
|
|
613
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
614
|
-
};
|
|
615
|
-
};
|
|
616
|
-
} | {
|
|
617
|
-
readonly _tag: "Busy";
|
|
618
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
235
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
236
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
237
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
238
|
+
readonly consume: <A>(input: {
|
|
239
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
240
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
241
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
242
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
243
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
244
|
+
readonly cleanup: <A>(input: {
|
|
245
|
+
readonly moduleId: string;
|
|
246
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
247
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
248
|
+
};
|
|
249
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, makePasskeyRegistrationCeremonyServices: <Flow extends D1Table, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow> & D1PasskeyMapping, RSetup>) => import("effect/Effect").Effect<{
|
|
250
|
+
passkeyPersistence: {
|
|
251
|
+
readonly issue: <A>(input: {
|
|
252
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
253
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
254
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
255
|
+
readonly consume: <A>(input: {
|
|
256
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
257
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
258
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
259
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
260
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
261
|
+
readonly cleanup: <A>(input: {
|
|
262
|
+
readonly moduleId: string;
|
|
263
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
264
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
265
|
+
};
|
|
266
|
+
capabilities: {
|
|
267
|
+
purposes: readonly ["registration"];
|
|
268
|
+
issue: "registration-authority";
|
|
269
|
+
assertionConsumption: false;
|
|
270
|
+
};
|
|
271
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePasskeyPersistence: {
|
|
272
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
273
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N> & D1PasskeyMapping, RSetup>;
|
|
274
|
+
readonly transaction?: never;
|
|
275
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
276
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
277
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N> & D1PasskeyMapping, RSetup>;
|
|
278
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
279
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
280
|
+
}, coordinatePasskeyRegistrationCeremony: {
|
|
281
|
+
<Database extends D1Database, Flow extends D1Table, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
282
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow> & D1PasskeyMapping, RSetup>;
|
|
283
|
+
readonly transaction?: never;
|
|
284
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
285
|
+
<Database extends D1Database, Flow extends D1Table, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
286
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow> & D1PasskeyMapping, RSetup>;
|
|
287
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
288
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
289
|
+
}, makePasskeyManagementServices: <S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N> & D1PasskeyMapping, RSetup>) => import("effect/Effect").Effect<{
|
|
290
|
+
passkeyManagementPersistence: {
|
|
619
291
|
readonly list: (input: {
|
|
620
|
-
readonly
|
|
621
|
-
readonly
|
|
292
|
+
readonly moduleId: string;
|
|
293
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
622
294
|
readonly cursor?: string;
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
627
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
628
|
-
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
629
|
-
readonly status: "Active" | "Disconnected" | "ReauthorizationRequired" | "Refreshing";
|
|
630
|
-
readonly scopes: readonly string[];
|
|
631
|
-
readonly accessExpiresAtMillis?: number;
|
|
632
|
-
readonly useUntilMillis: number;
|
|
633
|
-
readonly profile?: {
|
|
634
|
-
readonly displayName?: string;
|
|
635
|
-
readonly handle?: string;
|
|
636
|
-
readonly avatarUrl?: string;
|
|
637
|
-
readonly profileUrl?: string;
|
|
638
|
-
readonly email?: string;
|
|
639
|
-
readonly emailVerified?: boolean;
|
|
640
|
-
readonly providerData?: {
|
|
641
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
642
|
-
};
|
|
643
|
-
};
|
|
644
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
645
|
-
}[];
|
|
295
|
+
readonly limit: number;
|
|
296
|
+
}) => import("effect/Effect").Effect<{
|
|
297
|
+
readonly credentials: ReadonlyArray<import("@yielded/auth/Passkey").PasskeyCredentialSummary>;
|
|
646
298
|
readonly cursor?: string;
|
|
647
|
-
}, import("@yielded/auth/
|
|
648
|
-
readonly
|
|
649
|
-
readonly
|
|
650
|
-
readonly
|
|
651
|
-
readonly
|
|
652
|
-
readonly
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
readonly
|
|
299
|
+
}, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
300
|
+
readonly completeEnrollment: <A>(input: {
|
|
301
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
302
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
303
|
+
readonly verified: import("@yielded/auth/Passkey").PasskeyRegistrationVerified;
|
|
304
|
+
readonly management: import("@yielded/auth/Passkey").PasskeyManagementPolicy;
|
|
305
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
306
|
+
readonly _tag: "Enrolled";
|
|
307
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredentialSummary;
|
|
656
308
|
} | {
|
|
657
|
-
readonly _tag: "Conflict";
|
|
658
|
-
} | {
|
|
659
|
-
readonly _tag: "Target";
|
|
660
|
-
readonly grant: {
|
|
661
|
-
readonly context: {
|
|
662
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
663
|
-
readonly exchangeOrder: string;
|
|
664
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
665
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
666
|
-
readonly identity: {
|
|
667
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
668
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
669
|
-
readonly subject: string;
|
|
670
|
-
};
|
|
671
|
-
readonly configuration: {
|
|
672
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
673
|
-
readonly protocol: "oauth" | "oidc";
|
|
674
|
-
readonly configurationGeneration: number;
|
|
675
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
676
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
677
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
678
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
679
|
-
readonly profile: {
|
|
680
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
681
|
-
readonly generation: number;
|
|
682
|
-
readonly issuance: "active" | "retired";
|
|
683
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
684
|
-
readonly clientRegistrationId: string;
|
|
685
|
-
readonly scopes: readonly string[];
|
|
686
|
-
readonly resources: readonly string[];
|
|
687
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
688
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
689
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
690
|
-
readonly refreshAheadMillis: number;
|
|
691
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
692
|
-
readonly revocation: "cohort" | "unsupported";
|
|
693
|
-
};
|
|
694
|
-
};
|
|
695
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
696
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
697
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
698
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
699
|
-
readonly metadata: {
|
|
700
|
-
readonly scopes: readonly string[];
|
|
701
|
-
readonly resources: readonly string[];
|
|
702
|
-
readonly accessExpiresAtMillis?: number;
|
|
703
|
-
readonly refreshExpiresAtMillis?: number;
|
|
704
|
-
readonly useUntilMillis: number;
|
|
705
|
-
readonly refreshUseUntilMillis?: number;
|
|
706
|
-
readonly obtainedAtMillis: number;
|
|
707
|
-
readonly profile?: {
|
|
708
|
-
readonly displayName?: string;
|
|
709
|
-
readonly handle?: string;
|
|
710
|
-
readonly avatarUrl?: string;
|
|
711
|
-
readonly profileUrl?: string;
|
|
712
|
-
readonly email?: string;
|
|
713
|
-
readonly emailVerified?: boolean;
|
|
714
|
-
readonly providerData?: {
|
|
715
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
716
|
-
};
|
|
717
|
-
};
|
|
718
|
-
};
|
|
719
|
-
};
|
|
720
|
-
readonly sealed?: {
|
|
721
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
722
|
-
readonly keyId: string;
|
|
723
|
-
readonly nonce: string;
|
|
724
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
725
|
-
};
|
|
726
|
-
};
|
|
727
|
-
readonly revision: {
|
|
728
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
729
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
730
|
-
readonly credentials: readonly {
|
|
731
|
-
readonly credentialId: string;
|
|
732
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
733
|
-
}[];
|
|
734
|
-
};
|
|
735
|
-
} | {
|
|
736
|
-
readonly _tag: "Replay";
|
|
737
|
-
readonly result: {
|
|
738
|
-
readonly _tag: "Disconnected";
|
|
739
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
740
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
741
|
-
readonly affectedGrantCount: number;
|
|
742
|
-
readonly replayed: boolean;
|
|
743
|
-
};
|
|
744
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
745
|
-
readonly disconnect: <A>(input: {
|
|
746
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
747
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
748
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedDisconnectGrant;
|
|
749
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
750
|
-
readonly revocation?: import("@yielded/auth/OAuth").OAuthConnectedRevocationJob;
|
|
751
|
-
readonly retentionUntilMillis: number;
|
|
752
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
753
|
-
readonly _tag: "Rejected";
|
|
754
|
-
} | {
|
|
755
|
-
readonly _tag: "Conflict";
|
|
756
|
-
} | {
|
|
757
|
-
readonly _tag: "Disconnected";
|
|
758
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
759
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
760
|
-
readonly affectedGrantCount: number;
|
|
761
|
-
readonly replayed: boolean;
|
|
762
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
763
|
-
readonly inspectAccess: (input: {
|
|
764
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
765
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
766
|
-
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
767
|
-
}) => Effect.Effect<{
|
|
768
309
|
readonly _tag: "Rejected";
|
|
769
|
-
}
|
|
770
|
-
|
|
771
|
-
|
|
310
|
+
}, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
311
|
+
readonly inspectRemove: (input: {
|
|
312
|
+
readonly moduleId: string;
|
|
313
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
314
|
+
readonly credentialId: string;
|
|
315
|
+
}) => import("effect/Effect").Effect<{
|
|
772
316
|
readonly _tag: "Target";
|
|
773
|
-
readonly
|
|
774
|
-
readonly context: {
|
|
775
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
776
|
-
readonly exchangeOrder: string;
|
|
777
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
778
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
779
|
-
readonly identity: {
|
|
780
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
781
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
782
|
-
readonly subject: string;
|
|
783
|
-
};
|
|
784
|
-
readonly configuration: {
|
|
785
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
786
|
-
readonly protocol: "oauth" | "oidc";
|
|
787
|
-
readonly configurationGeneration: number;
|
|
788
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
789
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
790
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
791
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
792
|
-
readonly profile: {
|
|
793
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
794
|
-
readonly generation: number;
|
|
795
|
-
readonly issuance: "active" | "retired";
|
|
796
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
797
|
-
readonly clientRegistrationId: string;
|
|
798
|
-
readonly scopes: readonly string[];
|
|
799
|
-
readonly resources: readonly string[];
|
|
800
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
801
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
802
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
803
|
-
readonly refreshAheadMillis: number;
|
|
804
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
805
|
-
readonly revocation: "cohort" | "unsupported";
|
|
806
|
-
};
|
|
807
|
-
};
|
|
808
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
809
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
810
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
811
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
812
|
-
readonly metadata: {
|
|
813
|
-
readonly scopes: readonly string[];
|
|
814
|
-
readonly resources: readonly string[];
|
|
815
|
-
readonly accessExpiresAtMillis?: number;
|
|
816
|
-
readonly refreshExpiresAtMillis?: number;
|
|
817
|
-
readonly useUntilMillis: number;
|
|
818
|
-
readonly refreshUseUntilMillis?: number;
|
|
819
|
-
readonly obtainedAtMillis: number;
|
|
820
|
-
readonly profile?: {
|
|
821
|
-
readonly displayName?: string;
|
|
822
|
-
readonly handle?: string;
|
|
823
|
-
readonly avatarUrl?: string;
|
|
824
|
-
readonly profileUrl?: string;
|
|
825
|
-
readonly email?: string;
|
|
826
|
-
readonly emailVerified?: boolean;
|
|
827
|
-
readonly providerData?: {
|
|
828
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
829
|
-
};
|
|
830
|
-
};
|
|
831
|
-
};
|
|
832
|
-
};
|
|
833
|
-
readonly sealed: {
|
|
834
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
835
|
-
readonly keyId: string;
|
|
836
|
-
readonly nonce: string;
|
|
837
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
838
|
-
};
|
|
839
|
-
};
|
|
317
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
840
318
|
} | {
|
|
841
|
-
readonly _tag: "ReauthorizationRequired";
|
|
842
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
843
|
-
readonly claimRefresh: <A>(input: {
|
|
844
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
845
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
846
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
847
|
-
readonly nextTokenVersion: import("@yielded/auth/OAuth").OAuthConnectedRefreshClaim["nextTokenVersion"];
|
|
848
|
-
readonly lifetimeMillis: number;
|
|
849
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
850
319
|
readonly _tag: "Rejected";
|
|
851
|
-
}
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
readonly
|
|
855
|
-
|
|
856
|
-
readonly
|
|
857
|
-
readonly
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
};
|
|
869
|
-
readonly configuration: {
|
|
870
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
871
|
-
readonly protocol: "oauth" | "oidc";
|
|
872
|
-
readonly configurationGeneration: number;
|
|
873
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
874
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
875
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
876
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
877
|
-
readonly profile: {
|
|
878
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
879
|
-
readonly generation: number;
|
|
880
|
-
readonly issuance: "active" | "retired";
|
|
881
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
882
|
-
readonly clientRegistrationId: string;
|
|
883
|
-
readonly scopes: readonly string[];
|
|
884
|
-
readonly resources: readonly string[];
|
|
885
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
886
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
887
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
888
|
-
readonly refreshAheadMillis: number;
|
|
889
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
890
|
-
readonly revocation: "cohort" | "unsupported";
|
|
891
|
-
};
|
|
892
|
-
};
|
|
893
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
894
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
895
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
896
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
897
|
-
readonly metadata: {
|
|
898
|
-
readonly scopes: readonly string[];
|
|
899
|
-
readonly resources: readonly string[];
|
|
900
|
-
readonly accessExpiresAtMillis?: number;
|
|
901
|
-
readonly refreshExpiresAtMillis?: number;
|
|
902
|
-
readonly useUntilMillis: number;
|
|
903
|
-
readonly refreshUseUntilMillis?: number;
|
|
904
|
-
readonly obtainedAtMillis: number;
|
|
905
|
-
readonly profile?: {
|
|
906
|
-
readonly displayName?: string;
|
|
907
|
-
readonly handle?: string;
|
|
908
|
-
readonly avatarUrl?: string;
|
|
909
|
-
readonly profileUrl?: string;
|
|
910
|
-
readonly email?: string;
|
|
911
|
-
readonly emailVerified?: boolean;
|
|
912
|
-
readonly providerData?: {
|
|
913
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
914
|
-
};
|
|
915
|
-
};
|
|
916
|
-
};
|
|
917
|
-
};
|
|
918
|
-
readonly sealed: {
|
|
919
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
920
|
-
readonly keyId: string;
|
|
921
|
-
readonly nonce: string;
|
|
922
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
923
|
-
};
|
|
320
|
+
}, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
321
|
+
readonly remove: <A>(input: {
|
|
322
|
+
readonly moduleId: string;
|
|
323
|
+
readonly commandId: string;
|
|
324
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
325
|
+
readonly authorization: import("@yielded/auth/Passkey").PasskeyActionAuthorization;
|
|
326
|
+
readonly management: import("@yielded/auth/Passkey").PasskeyManagementPolicy;
|
|
327
|
+
readonly invalidation: import("@yielded/auth/Sessions").SessionInvalidationWindow;
|
|
328
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
329
|
+
readonly _tag: "Removed";
|
|
330
|
+
readonly result: {
|
|
331
|
+
readonly credentialId: string;
|
|
332
|
+
readonly invalidation: {
|
|
333
|
+
readonly trigger: "all-session-revocation" | "credential-change" | "factor-reset" | "identifier-change" | "password-reset" | "subject-delete" | "subject-disable";
|
|
334
|
+
readonly existingSessions: "cache-expiry" | "immediate" | "original-absolute-expiry";
|
|
335
|
+
readonly maximumExposureMillis: number;
|
|
336
|
+
readonly oldAuthenticationEvidence: "rejected";
|
|
924
337
|
};
|
|
925
|
-
readonly order: string;
|
|
926
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
927
|
-
readonly claimedAtMillis: number;
|
|
928
|
-
readonly claimExpiresAtMillis: number;
|
|
929
|
-
readonly nextTokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
930
338
|
};
|
|
931
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
932
|
-
readonly settleRefresh: <A>(input: {
|
|
933
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedRefreshClaim;
|
|
934
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
935
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthConnectedRefreshOutcome;
|
|
936
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
937
|
-
readonly _tag: "Rejected";
|
|
938
339
|
} | {
|
|
939
|
-
readonly _tag: "
|
|
340
|
+
readonly _tag: "Rejected" | "LastSignInMethod";
|
|
341
|
+
}, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
342
|
+
readonly rename: <A>(input: {
|
|
343
|
+
readonly moduleId: string;
|
|
344
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
345
|
+
readonly commandId: string;
|
|
346
|
+
readonly credentialId: string;
|
|
347
|
+
readonly name: string;
|
|
348
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
349
|
+
readonly _tag: "Renamed";
|
|
350
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredentialSummary;
|
|
940
351
|
} | {
|
|
941
|
-
readonly _tag: "Refreshed";
|
|
942
|
-
readonly grant: {
|
|
943
|
-
readonly context: {
|
|
944
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
945
|
-
readonly exchangeOrder: string;
|
|
946
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
947
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
948
|
-
readonly identity: {
|
|
949
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
950
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
951
|
-
readonly subject: string;
|
|
952
|
-
};
|
|
953
|
-
readonly configuration: {
|
|
954
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
955
|
-
readonly protocol: "oauth" | "oidc";
|
|
956
|
-
readonly configurationGeneration: number;
|
|
957
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
958
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
959
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
960
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
961
|
-
readonly profile: {
|
|
962
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
963
|
-
readonly generation: number;
|
|
964
|
-
readonly issuance: "active" | "retired";
|
|
965
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
966
|
-
readonly clientRegistrationId: string;
|
|
967
|
-
readonly scopes: readonly string[];
|
|
968
|
-
readonly resources: readonly string[];
|
|
969
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
970
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
971
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
972
|
-
readonly refreshAheadMillis: number;
|
|
973
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
974
|
-
readonly revocation: "cohort" | "unsupported";
|
|
975
|
-
};
|
|
976
|
-
};
|
|
977
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
978
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
979
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
980
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
981
|
-
readonly metadata: {
|
|
982
|
-
readonly scopes: readonly string[];
|
|
983
|
-
readonly resources: readonly string[];
|
|
984
|
-
readonly accessExpiresAtMillis?: number;
|
|
985
|
-
readonly refreshExpiresAtMillis?: number;
|
|
986
|
-
readonly useUntilMillis: number;
|
|
987
|
-
readonly refreshUseUntilMillis?: number;
|
|
988
|
-
readonly obtainedAtMillis: number;
|
|
989
|
-
readonly profile?: {
|
|
990
|
-
readonly displayName?: string;
|
|
991
|
-
readonly handle?: string;
|
|
992
|
-
readonly avatarUrl?: string;
|
|
993
|
-
readonly profileUrl?: string;
|
|
994
|
-
readonly email?: string;
|
|
995
|
-
readonly emailVerified?: boolean;
|
|
996
|
-
readonly providerData?: {
|
|
997
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
998
|
-
};
|
|
999
|
-
};
|
|
1000
|
-
};
|
|
1001
|
-
};
|
|
1002
|
-
readonly sealed: {
|
|
1003
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1004
|
-
readonly keyId: string;
|
|
1005
|
-
readonly nonce: string;
|
|
1006
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1007
|
-
};
|
|
1008
|
-
};
|
|
1009
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1010
|
-
readonly admitUse: <A>(input: {
|
|
1011
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
1012
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1013
|
-
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1014
|
-
readonly lifetimeMillis: number;
|
|
1015
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1016
352
|
readonly _tag: "Rejected";
|
|
1017
|
-
}
|
|
1018
|
-
readonly _tag: "Busy";
|
|
1019
|
-
} | {
|
|
1020
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1021
|
-
} | {
|
|
1022
|
-
readonly _tag: "Admitted";
|
|
1023
|
-
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1024
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1025
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1026
|
-
readonly admittedAtMillis: number;
|
|
1027
|
-
readonly expiresAtMillis: number;
|
|
1028
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1029
|
-
readonly cleanup: <A>(input: import("@yielded/auth/OAuth").OAuthCleanupInput, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1030
|
-
readonly terminalized: number;
|
|
1031
|
-
readonly removed: number;
|
|
1032
|
-
readonly hasMore: boolean;
|
|
1033
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
353
|
+
}, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
1034
354
|
};
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
}
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
}
|
|
1050
|
-
oauthConnectedRevocations: {
|
|
1051
|
-
readonly claim: <A>(input: {
|
|
1052
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1053
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1054
|
-
readonly lifetimeMillis: number;
|
|
1055
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1056
|
-
readonly _tag: "Claimed";
|
|
1057
|
-
readonly claim: {
|
|
1058
|
-
readonly job: {
|
|
1059
|
-
readonly context: {
|
|
1060
|
-
readonly namespace: "effect-auth/oauth-connected-revocation-context/v1";
|
|
1061
|
-
readonly jobId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1062
|
-
readonly token: {
|
|
1063
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1064
|
-
readonly exchangeOrder: string;
|
|
1065
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1066
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1067
|
-
readonly identity: {
|
|
1068
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1069
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1070
|
-
readonly subject: string;
|
|
1071
|
-
};
|
|
1072
|
-
readonly configuration: {
|
|
1073
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1074
|
-
readonly protocol: "oauth" | "oidc";
|
|
1075
|
-
readonly configurationGeneration: number;
|
|
1076
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1077
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1078
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1079
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1080
|
-
readonly profile: {
|
|
1081
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1082
|
-
readonly generation: number;
|
|
1083
|
-
readonly issuance: "active" | "retired";
|
|
1084
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1085
|
-
readonly clientRegistrationId: string;
|
|
1086
|
-
readonly scopes: readonly string[];
|
|
1087
|
-
readonly resources: readonly string[];
|
|
1088
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1089
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1090
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1091
|
-
readonly refreshAheadMillis: number;
|
|
1092
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1093
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1094
|
-
};
|
|
1095
|
-
};
|
|
1096
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1097
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1098
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1099
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1100
|
-
readonly metadata: {
|
|
1101
|
-
readonly scopes: readonly string[];
|
|
1102
|
-
readonly resources: readonly string[];
|
|
1103
|
-
readonly accessExpiresAtMillis?: number;
|
|
1104
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1105
|
-
readonly useUntilMillis: number;
|
|
1106
|
-
readonly refreshUseUntilMillis?: number;
|
|
1107
|
-
readonly obtainedAtMillis: number;
|
|
1108
|
-
readonly profile?: {
|
|
1109
|
-
readonly displayName?: string;
|
|
1110
|
-
readonly handle?: string;
|
|
1111
|
-
readonly avatarUrl?: string;
|
|
1112
|
-
readonly profileUrl?: string;
|
|
1113
|
-
readonly email?: string;
|
|
1114
|
-
readonly emailVerified?: boolean;
|
|
1115
|
-
readonly providerData?: {
|
|
1116
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1117
|
-
};
|
|
1118
|
-
};
|
|
1119
|
-
};
|
|
1120
|
-
};
|
|
1121
|
-
};
|
|
1122
|
-
readonly sealed: {
|
|
1123
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1124
|
-
readonly keyId: string;
|
|
1125
|
-
readonly nonce: string;
|
|
1126
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1127
|
-
};
|
|
1128
|
-
};
|
|
1129
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1130
|
-
readonly claimedAtMillis: number;
|
|
1131
|
-
readonly claimExpiresAtMillis: number;
|
|
1132
|
-
};
|
|
1133
|
-
} | {
|
|
1134
|
-
readonly _tag: "Empty";
|
|
1135
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1136
|
-
readonly settle: <A>(input: {
|
|
1137
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedRevocationClaim;
|
|
1138
|
-
readonly outcome: "Confirmed" | "Unknown";
|
|
1139
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1140
|
-
readonly settled: boolean;
|
|
1141
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
355
|
+
passkeyPersistence: {
|
|
356
|
+
readonly issue: <A>(input: {
|
|
357
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
358
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
359
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
360
|
+
readonly consume: <A>(input: {
|
|
361
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
362
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
363
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
364
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
365
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
366
|
+
readonly cleanup: <A>(input: {
|
|
367
|
+
readonly moduleId: string;
|
|
368
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
369
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
1142
370
|
};
|
|
1143
|
-
}, import("@yielded/auth/
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
}
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
}
|
|
1160
|
-
|
|
1161
|
-
}
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
}
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
}, body: Effect.Effect<A, E, R>)
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
}>,
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
}
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
readonly
|
|
1185
|
-
},
|
|
1186
|
-
|
|
1187
|
-
|
|
371
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, makePasskeyRegistrationServices: <S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, Value, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value> & D1PasskeyMapping, RSetup>) => import("effect/Effect").Effect<{
|
|
372
|
+
passkeyRegistrationAuthority: import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>;
|
|
373
|
+
passkeyPersistence: {
|
|
374
|
+
readonly issue: <A>(input: {
|
|
375
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
376
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
377
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => import("effect/Effect").Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
378
|
+
readonly consume: <A>(input: {
|
|
379
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
380
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
381
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
382
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
383
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
384
|
+
readonly cleanup: <A>(input: {
|
|
385
|
+
readonly moduleId: string;
|
|
386
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
387
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
388
|
+
};
|
|
389
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePasskeyManagement: {
|
|
390
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
391
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N> & D1PasskeyMapping, RSetup>;
|
|
392
|
+
readonly transaction?: never;
|
|
393
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/Passkey").PasskeyManagementPersistence | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
394
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
395
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N> & D1PasskeyMapping, RSetup>;
|
|
396
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
397
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/Passkey").PasskeyManagementPersistence | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
398
|
+
}, coordinatePasskeyRegistration: {
|
|
399
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, Value, A, E, R, AuthorityId, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
400
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value> & D1PasskeyMapping, RSetup>;
|
|
401
|
+
readonly authority: import("effect/Context").Key<AuthorityId, import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>>;
|
|
402
|
+
readonly transaction?: never;
|
|
403
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, AuthorityId | D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
404
|
+
<Database extends D1Database, S extends D1Table, C extends D1Table, F extends D1Table, Flow extends D1Table, N, Value, A, E, R, AuthorityId, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: import("effect/Effect").Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
405
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value> & D1PasskeyMapping, RSetup>;
|
|
406
|
+
readonly authority: import("effect/Context").Key<AuthorityId, import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>>;
|
|
407
|
+
readonly transaction: SuppliedService<TxId, never, TxShape>;
|
|
408
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, AuthorityId | TxId | D1BatchStatements | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
409
|
+
};
|
|
410
|
+
export declare const makePhonePersistenceServices: <Subject extends import("drizzle-orm").Table, Identifier extends import("drizzle-orm").Table, Credential extends import("drizzle-orm").Table, Proof extends import("drizzle-orm").Table, NativeId>(mapping: PhoneMapping<Subject, Identifier, Credential, Proof, NativeId>) => import("effect/Effect").Effect<{
|
|
411
|
+
readonly phonePersistence: import("@yielded/auth/PhoneOtp").PhonePersistence["Service"];
|
|
412
|
+
readonly phoneSignInTargets: import("@yielded/auth/PhoneOtp").PhoneSignInTargets["Service"];
|
|
413
|
+
}, import("@yielded/auth/PhoneOtp").PhoneConfigurationError | import("@yielded/auth/PhoneOtp").PhoneOtpUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePhonePersistence: {
|
|
414
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
415
|
+
readonly $client: D1Client;
|
|
416
|
+
}, Subject extends import("drizzle-orm").Table, Identifier extends import("drizzle-orm").Table, Credential extends import("drizzle-orm").Table, Proof extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
417
|
+
readonly mapping: PhoneMapping<Subject, Identifier, Credential, Proof, NativeId>;
|
|
418
|
+
readonly transaction?: never;
|
|
419
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/PhoneOtp").PhoneConfigurationError | import("@yielded/auth/PhoneOtp").PhoneOtpUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/PhoneOtp").PhonePersistence | import("@yielded/auth/PhoneOtp").PhoneSignInTargets>>;
|
|
420
|
+
<Database extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
421
|
+
readonly $client: D1Client;
|
|
422
|
+
}, Subject extends import("drizzle-orm").Table, Identifier extends import("drizzle-orm").Table, Credential extends import("drizzle-orm").Table, Proof extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<Database, DE, DR>, options: {
|
|
423
|
+
readonly mapping: PhoneMapping<Subject, Identifier, Credential, Proof, NativeId>;
|
|
424
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
425
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/PhoneOtp").PhoneConfigurationError | import("@yielded/auth/PhoneOtp").PhoneOtpUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/PhoneOtp").PhonePersistence | import("@yielded/auth/PhoneOtp").PhoneSignInTargets>>;
|
|
426
|
+
};
|
|
1188
427
|
/** Construct Drizzle from the driver's SQL-client Layer. */
|
|
1189
428
|
export declare const databaseLayer: Layer.Layer<Database, never, D1Client>;
|
|
429
|
+
export declare const coordinateAuthenticationAuthority: {
|
|
430
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
431
|
+
readonly $client: D1Client;
|
|
432
|
+
}, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
433
|
+
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, P, N>;
|
|
434
|
+
readonly transaction?: never;
|
|
435
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
436
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
437
|
+
readonly $client: D1Client;
|
|
438
|
+
}, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
439
|
+
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, P, N>;
|
|
440
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
441
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
442
|
+
}, coordinatePendingAuthentication: {
|
|
443
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
444
|
+
readonly $client: D1Client;
|
|
445
|
+
}, Id, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
446
|
+
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, N>;
|
|
447
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
448
|
+
readonly transaction?: never;
|
|
449
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
450
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
451
|
+
readonly $client: D1Client;
|
|
452
|
+
}, Id, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
453
|
+
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, N>;
|
|
454
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
455
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
456
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
457
|
+
}, coordinateSignedSessionValidity: {
|
|
458
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
459
|
+
readonly $client: D1Client;
|
|
460
|
+
}, Id, S extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
461
|
+
readonly mapping: SignedSessionValidityMapping<S, T, N, NS>;
|
|
462
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
463
|
+
readonly transaction?: never;
|
|
464
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
465
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
466
|
+
readonly $client: D1Client;
|
|
467
|
+
}, Id, S extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
468
|
+
readonly mapping: SignedSessionValidityMapping<S, T, N, NS>;
|
|
469
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
470
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
471
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
472
|
+
}, coordinateStatefulSessions: {
|
|
473
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
474
|
+
readonly $client: D1Client;
|
|
475
|
+
}, Id, RepositoryId, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
476
|
+
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, P, N, NS>;
|
|
477
|
+
readonly persistence: SuppliedService<Id, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
478
|
+
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
479
|
+
readonly transaction?: never;
|
|
480
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | RepositoryId>>;
|
|
481
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
482
|
+
readonly $client: D1Client;
|
|
483
|
+
}, Id, RepositoryId, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
484
|
+
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, P, N, NS>;
|
|
485
|
+
readonly persistence: SuppliedService<Id, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
486
|
+
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
487
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
488
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | RepositoryId | TxId>>;
|
|
489
|
+
}, makeAuthenticationAuthorityServices: <Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N>(mapping: AuthenticationAuthorityMapping<Claims, S, C, P, N>) => import("effect/Effect").Effect<{
|
|
490
|
+
readonly authenticationAuthority: import("@yielded/auth/Sessions").AuthenticationAuthority["Service"];
|
|
491
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makePendingAuthenticationServices: <Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N>(mapping: PendingAuthenticationMapping<Claims, S, C, P, N>) => import("effect/Effect").Effect<{
|
|
492
|
+
readonly pendingAuthentication: import("@yielded/auth/Sessions").PendingAuthentication<Claims>;
|
|
493
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeSignedSessionValidityServices: <S extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS>(mapping: SignedSessionValidityMapping<S, T, N, NS>) => import("effect/Effect").Effect<{
|
|
494
|
+
readonly signedSessionValidity: import("@yielded/auth/Sessions").SignedSessionValidity;
|
|
495
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeStatefulSessionServices: <Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, N, NS>(mapping: StatefulSessionMapping<Claims, S, C, Session, P, N, NS>) => import("effect/Effect").Effect<{
|
|
496
|
+
readonly statefulSessionPersistence: import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>;
|
|
497
|
+
readonly sessionRepository: import("@yielded/auth/Sessions").SessionRepository;
|
|
498
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeSessionStepUpServices: <Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, Id>(mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, P, Session, T, N, NS>, target: import("effect/Context").Service<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>) => import("effect/Effect").Effect<{
|
|
499
|
+
sessionStepUpPersistence: import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>;
|
|
500
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateSessionStepUp: {
|
|
501
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
502
|
+
readonly $client: D1Client;
|
|
503
|
+
}, Id, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
504
|
+
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, P, Session, T, N, NS>;
|
|
505
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
506
|
+
readonly transaction?: never;
|
|
507
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
508
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
509
|
+
readonly $client: D1Client;
|
|
510
|
+
}, Id, Claims, S extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, P extends import("drizzle-orm").Table, Session extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR, TxId, TxShape>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
511
|
+
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, P, Session, T, N, NS>;
|
|
512
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
513
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
514
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
515
|
+
}, makeSessionCleanupServices: <P extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS>(mapping: SessionCleanupMapping<P, T, N, NS>) => import("effect/Effect").Effect<{
|
|
516
|
+
readonly sessionCleanup: import("@yielded/auth/Sessions").SessionCleanup;
|
|
517
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
518
|
+
export declare const makeTotpPersistenceServices: <S extends import("drizzle-orm").Table, F extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, N, P extends import("drizzle-orm").Table = import("drizzle-orm").Table<import("drizzle-orm").TableConfig<import("drizzle-orm").Columns>>, RS = never>(source: import("@yielded/auth-persistence/Adapter").TotpMappingSource<TotpMapping<S, F, C, N, P>, RS>) => import("effect/Effect").Effect<{
|
|
519
|
+
readonly totpPersistence: import("@yielded/auth/Totp").TotpPersistence["Service"];
|
|
520
|
+
}, import("@yielded/auth-persistence/Adapter").PersistenceMappingError | import("@yielded/auth/Totp").TotpConfigurationError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RS, NativeDatabase>>, coordinateTotpPersistence: {
|
|
521
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
522
|
+
readonly $client: D1Client;
|
|
523
|
+
}, S extends import("drizzle-orm").Table, F extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, N, P extends import("drizzle-orm").Table, A, E, R, DE, DR, RS = never>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
524
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").TotpMappingSource<TotpMapping<S, F, C, N, P>, RS>;
|
|
525
|
+
readonly transaction?: never;
|
|
526
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth-persistence/Adapter").PersistenceMappingError | import("@yielded/auth/Totp").TotpConfigurationError | import("@yielded/auth/Totp").TotpUnavailable, DR | RS | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, D1BatchStatements | import("@yielded/auth/Totp").TotpPersistence>>;
|
|
527
|
+
<DB extends EffectSQLiteD1Database<import("drizzle-orm").TablesRelationalConfig> & {
|
|
528
|
+
readonly $client: D1Client;
|
|
529
|
+
}, S extends import("drizzle-orm").Table, F extends import("drizzle-orm").Table, C extends import("drizzle-orm").Table, N, P extends import("drizzle-orm").Table, A, E, R, DE, DR, TxId, TxShape, RS = never>(acquire: import("effect/Effect").Effect<DB, DE, DR>, options: {
|
|
530
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").TotpMappingSource<TotpMapping<S, F, C, N, P>, RS>;
|
|
531
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
532
|
+
}, body: import("effect/Effect").Effect<A, E, R>): import("effect/Effect").Effect<A, DE | E | import("@yielded/auth-persistence/Adapter").PersistenceMappingError | import("@yielded/auth/Totp").TotpConfigurationError | import("@yielded/auth/Totp").TotpUnavailable, DR | RS | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | D1BatchStatements | import("@yielded/auth/Totp").TotpPersistence>>;
|
|
533
|
+
};
|
|
1190
534
|
//#endregion
|
|
1191
|
-
export { D1BatchStatements, Database, OAuthProxyPersistence
|
|
535
|
+
export { D1BatchStatements, Database, OAuthProxyPersistence };
|
|
1192
536
|
//# sourceMappingURL=D1.d.mts.map
|