@yielded/auth-persistence-drizzle 0.1.0-beta.24 → 0.1.0-beta.26
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 +90 -25
- 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 -1265
- package/src/drizzle/d1-passwords.ts +0 -2060
- 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 -1201
- 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/SqliteDo.d.mts
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import { DrizzleTableModel } from "./drizzle/table-model.mjs";
|
|
2
1
|
import { EmailAddressMapping, EmailRegistrationMapping, EmailSignInMapping } from "./drizzle/email-model.mjs";
|
|
3
|
-
import { PasswordRegistrationMapping } from "./drizzle/password-model.mjs";
|
|
4
|
-
import { ExternalIdentityTables, IdentityTables, SubjectProvisioningTables } from "./drizzle/model.mjs";
|
|
2
|
+
import { PasswordPersistenceMapping, PasswordRegistrationMapping } from "./drizzle/password-model.mjs";
|
|
5
3
|
import { ProofPersistenceMapping } from "./drizzle/proof-model.mjs";
|
|
6
|
-
import {
|
|
7
|
-
import { AuthenticationAuthorityMapping, PendingAuthenticationMapping, SignedSessionValidityMapping, StatefulSessionMapping } from "./drizzle/session-model.mjs";
|
|
8
|
-
import { PasskeyCredentialMapping,
|
|
4
|
+
import { ExternalIdentityTables, IdentityTables, SubjectProvisioningTables } from "./drizzle/model.mjs";
|
|
5
|
+
import { AuthenticationAuthorityMapping, PendingAuthenticationMapping, SessionCleanupMapping, SignedSessionValidityMapping, StatefulSessionMapping } from "./drizzle/session-model.mjs";
|
|
6
|
+
import { PasskeyCredentialMapping, PasskeyPersistenceMapping } from "./drizzle/passkey-model.mjs";
|
|
9
7
|
import { SessionStepUpMapping } from "./drizzle/step-up-model.mjs";
|
|
10
8
|
import { OAuthAccountsMapping, OAuthRegistrationIntentMapping, OAuthRegistrationMapping, OAuthSignInMapping } from "./drizzle/oauth-model.mjs";
|
|
11
9
|
import { OAuthConnectedMapping, OAuthConnectedRevocationMapping } from "./drizzle/oauth-connected-model.mjs";
|
|
12
10
|
import { PasskeyRegistrationCeremonyMapping } from "./drizzle/passkey-registration-ceremony-model.mjs";
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
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";
|
|
16
15
|
import { PasskeyManagementMapping, PasskeyRegistrationMapping } from "./drizzle/passkey-write-model.mjs";
|
|
17
|
-
import {
|
|
16
|
+
import { PasskeyCoordinatorError } from "./drizzle/passkey/target.mjs";
|
|
17
|
+
import { PhoneMapping } from "./drizzle/phone-model.mjs";
|
|
18
18
|
import "./index.mjs";
|
|
19
|
-
import { OAuthProxyPersistence } from "./internal/drizzle-sqlite-oauth-proxy.mjs";
|
|
20
|
-
import { SuppliedService } from "./drizzle/SuppliedService.mjs";
|
|
21
|
-
import { TotpCoordinatorError } from "./drizzle/totp-target.mjs";
|
|
22
|
-
import { PhoneCoordinatorError } from "./drizzle/phone-target.mjs";
|
|
23
19
|
import { DatabaseValue, Transaction, makeDatabase } from "./drizzle/sqlite-do-database.mjs";
|
|
24
|
-
import {
|
|
20
|
+
import { NativeDriverTransaction } from "./drizzle/driver-types.mjs";
|
|
21
|
+
import { SuppliedService } from "./drizzle/SuppliedService.mjs";
|
|
22
|
+
import { OAuthProxyPersistence } from "./internal/drizzle-sqlite-oauth-proxy.mjs";
|
|
23
|
+
import "./D1.mjs";
|
|
24
|
+
import { PersistenceConfigurationError } from "@yielded/auth-persistence/Adapter";
|
|
25
25
|
import { Context, Effect, Layer } from "effect";
|
|
26
26
|
import { AnySQLiteTable } from "drizzle-orm/sqlite-core";
|
|
27
27
|
import { SqliteClient } from "@effect/sql-sqlite-do/SqliteClient";
|
|
@@ -31,251 +31,83 @@ declare const Database_base: Context.ServiceClass<Database, "effect-auth/persist
|
|
|
31
31
|
export declare class Database extends Database_base {}
|
|
32
32
|
/** Construct Drizzle with asynchronous transactions owned by Effect SQL. */
|
|
33
33
|
export declare const databaseLayer: Layer.Layer<Database, PersistenceConfigurationError, SqliteClient>;
|
|
34
|
-
export declare const
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
34
|
+
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>) => Effect.Effect<{
|
|
35
|
+
readonly emailSignInTargets: import("@yielded/auth/Email").EmailSignInTargets["Service"];
|
|
36
|
+
}, 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) => Effect.Effect<{
|
|
37
|
+
readonly emailAddressPersistence: import("@yielded/auth/Email").EmailAddressPersistence["Service"];
|
|
38
|
+
}, 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>) => Effect.Effect<{
|
|
39
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>;
|
|
40
|
+
}, import("@yielded/auth/Email").EmailUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateEmailAddress: {
|
|
41
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
42
|
+
readonly mapping: EmailAddressMapping<S, I, C, AC, N>;
|
|
38
43
|
readonly transaction?: never;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
readonly
|
|
44
|
-
|
|
44
|
+
} & {
|
|
45
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
46
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
47
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
48
|
+
readonly mapping: EmailAddressMapping<S, I, C, AC, N>;
|
|
49
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
50
|
+
} & {
|
|
51
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
52
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
45
53
|
}, coordinateEmailRegistration: {
|
|
46
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
47
|
-
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC,
|
|
48
|
-
readonly proofMapping:
|
|
49
|
-
readonly target: SuppliedService<TargetId, EmailRegistrationAuthority<Registration>>;
|
|
54
|
+
<TargetId, Registration, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
55
|
+
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
56
|
+
readonly proofMapping: ProofPersistenceMapping<Proof, PS, PN>;
|
|
57
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>>;
|
|
50
58
|
readonly transaction?: never;
|
|
51
|
-
}, body: Effect.Effect<
|
|
52
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
53
|
-
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC,
|
|
54
|
-
readonly proofMapping:
|
|
55
|
-
readonly target: SuppliedService<TargetId, EmailRegistrationAuthority<Registration>>;
|
|
56
|
-
readonly transaction: SuppliedService<TxId, NoInfer<
|
|
57
|
-
}, body: Effect.Effect<
|
|
58
|
-
}
|
|
59
|
-
emailAddressPersistence: {
|
|
60
|
-
readonly target: (input: {
|
|
61
|
-
readonly moduleId: string;
|
|
62
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
63
|
-
readonly target: import("@yielded/auth/Identity").LoginIdentifier;
|
|
64
|
-
readonly sourceCredentialId?: string;
|
|
65
|
-
}) => Effect.Effect<import("@yielded/auth/Email").EmailAddressTarget, import("@yielded/auth/Email").EmailUnavailable>;
|
|
66
|
-
readonly checkCompletion: (input: import("@yielded/auth/Proofs").ProofCompletionInput) => Effect.Effect<boolean, import("@yielded/auth/Email").EmailUnavailable>;
|
|
67
|
-
readonly verifyWithProof: <A>(input: import("@yielded/auth/Email").EmailAddressMutation, prepare: import("@yielded/auth/Email").PrepareEmailCommit<import("@yielded/auth/Email").EmailAddressDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
68
|
-
readonly changeWithProof: <A>(input: import("@yielded/auth/Email").EmailAddressMutation, prepare: import("@yielded/auth/Email").PrepareEmailCommit<import("@yielded/auth/Email").EmailAddressDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
69
|
-
readonly cleanup: <A>(input: {
|
|
70
|
-
readonly moduleId: string;
|
|
71
|
-
readonly limit: number;
|
|
72
|
-
}, prepare: import("@yielded/auth/Email").PrepareEmailCommit<{
|
|
73
|
-
readonly removed: number;
|
|
74
|
-
readonly hasMore: boolean;
|
|
75
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
76
|
-
};
|
|
77
|
-
}, import("@yielded/auth/Email").EmailUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailRegistrationServices: <Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId>(mapping: EmailRegistrationMapping<Registration, S, I, C, AC, Rq, NativeId>, proofMapping: import("@yielded/auth-persistence/Adapter").ProofPersistenceMapping<DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, DrizzleTableModel<any>, any, import("drizzle-orm").SQL<unknown>>) => Effect.Effect<{
|
|
78
|
-
registrationAuthority: EmailRegistrationAuthority<Registration>;
|
|
79
|
-
}, import("@yielded/auth/Email").EmailUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailSignInServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, NativeId>(mapping: EmailSignInMapping<S, I, C, NativeId>) => Effect.Effect<{
|
|
80
|
-
emailSignInTargets: {
|
|
81
|
-
readonly lookup: (input: {
|
|
82
|
-
readonly moduleId: string;
|
|
83
|
-
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
84
|
-
}) => Effect.Effect<import("effect/Option").Option<import("@yielded/auth/Email").EmailCredentialSnapshot>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
85
|
-
};
|
|
86
|
-
}, import("@yielded/auth/Email").EmailUnavailable, Database>;
|
|
59
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
60
|
+
<TargetId, Registration, Proof extends import("drizzle-orm").Table, PS extends import("drizzle-orm").Table, PN, Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
61
|
+
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
62
|
+
readonly proofMapping: ProofPersistenceMapping<Proof, PS, PN>;
|
|
63
|
+
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").EmailRegistrationAuthority<Registration>>;
|
|
64
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
65
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Email").EmailUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
66
|
+
};
|
|
87
67
|
export declare const coordinatePasswordPersistence: {
|
|
88
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends
|
|
89
|
-
readonly mapping:
|
|
90
|
-
readonly proofMapping?: PM;
|
|
68
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
69
|
+
readonly mapping: PasswordPersistenceMapping<S, I, C, AC, N>;
|
|
91
70
|
readonly transaction?: never;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
readonly
|
|
97
|
-
|
|
71
|
+
} & {
|
|
72
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
73
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
74
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
75
|
+
readonly mapping: PasswordPersistenceMapping<S, I, C, AC, N>;
|
|
76
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
77
|
+
} & {
|
|
78
|
+
readonly proofMapping?: ProofPersistenceMapping<Proof, PS, PN>;
|
|
79
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
98
80
|
}, coordinatePasswordRegistration: {
|
|
99
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
100
|
-
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC,
|
|
81
|
+
<TargetId, Registration, Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
82
|
+
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
101
83
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
102
84
|
readonly transaction?: never;
|
|
103
|
-
}, body: Effect.Effect<
|
|
104
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
105
|
-
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC,
|
|
85
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
86
|
+
<TargetId, Registration, Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
87
|
+
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, N>;
|
|
106
88
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
107
|
-
readonly transaction: SuppliedService<TxId, NoInfer<
|
|
108
|
-
}, body: Effect.Effect<
|
|
109
|
-
}, makePasswordPersistenceServices: <S extends
|
|
110
|
-
passwordPersistence:
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
readonly subjectId?: import("@yielded/auth/Schema").SubjectId;
|
|
115
|
-
}) => Effect.Effect<import("effect/Option").Option<import("@yielded/auth/Password").PasswordCredentialSnapshot>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
116
|
-
readonly rehashIfCurrent: (input: {
|
|
117
|
-
readonly credential: import("@yielded/auth/Password").PasswordCredentialSnapshot;
|
|
118
|
-
readonly nextVerifier: import("effect/Redacted").Redacted<import("@yielded/auth/Password").EncodedPasswordHash>;
|
|
119
|
-
}) => Effect.Effect<void, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
120
|
-
readonly readForSubject: (input: {
|
|
121
|
-
readonly moduleId: string;
|
|
122
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
123
|
-
}) => Effect.Effect<import("effect/Option").Option<import("@yielded/auth/Password").PasswordCredentialSnapshot>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
124
|
-
readonly recoveryTarget: (input: {
|
|
125
|
-
readonly moduleId: string;
|
|
126
|
-
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
127
|
-
}) => Effect.Effect<import("effect/Option").Option<import("@yielded/auth/Password").PasswordCredentialSnapshot>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
128
|
-
readonly addIfAbsent: <A>(input: import("@yielded/auth/Password").PasswordMutationInput, prepare: import("@yielded/auth/Password").PreparePasswordCommit<import("@yielded/auth/Password").PasswordMutationDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
129
|
-
readonly replaceIfCurrent: <A>(input: import("@yielded/auth/Password").PasswordMutationInput, prepare: import("@yielded/auth/Password").PreparePasswordCommit<import("@yielded/auth/Password").PasswordMutationDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
130
|
-
readonly checkReset: (input: import("@yielded/auth/Proofs").ProofCompletionInput) => Effect.Effect<boolean, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
131
|
-
readonly resetWithProof: <A>(input: import("@yielded/auth/Password").PasswordMutationInput & {
|
|
132
|
-
readonly completion: import("@yielded/auth/Proofs").ProofCompletionPlan;
|
|
133
|
-
}, prepare: import("@yielded/auth/Password").PreparePasswordCommit<import("@yielded/auth/Password").PasswordMutationDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
134
|
-
};
|
|
135
|
-
}, import("@yielded/auth/Password").PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makePasswordRegistrationServices: <Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId>(mapping: PasswordRegistrationMapping<Registration, S, I, C, AC, Rq, NativeId>) => Effect.Effect<{
|
|
136
|
-
registrationAuthority: import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>;
|
|
137
|
-
}, import("@yielded/auth/Password").PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
89
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
90
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Password").PasswordUnavailable, DR | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
91
|
+
}, 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) => Effect.Effect<{
|
|
92
|
+
readonly passwordPersistence: import("@yielded/auth/Password").PasswordPersistence["Service"];
|
|
93
|
+
}, 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>) => Effect.Effect<{
|
|
94
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>;
|
|
95
|
+
}, import("@yielded/auth/Password").PasswordUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
138
96
|
export declare const coordinateProofPersistence: {
|
|
139
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
140
|
-
readonly mapping:
|
|
141
|
-
readonly transaction?: never;
|
|
142
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Proofs").ProofUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Proofs").ProofPersistence>>;
|
|
143
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Rq extends AnySQLiteTable, S extends AnySQLiteTable, G extends AnySQLiteTable, Cn extends AnySQLiteTable, Rs extends AnySQLiteTable, Aev extends AnySQLiteTable, F extends AnySQLiteTable, C extends AnySQLiteTable, Sub extends AnySQLiteTable, I extends AnySQLiteTable, Cr extends AnySQLiteTable, NativeId, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
144
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").ProofPersistenceMapping<DrizzleTableModel<Rq>, DrizzleTableModel<S>, DrizzleTableModel<G>, DrizzleTableModel<Cn>, DrizzleTableModel<Rs>, DrizzleTableModel<Aev>, DrizzleTableModel<F>, DrizzleTableModel<C>, DrizzleTableModel<Sub>, DrizzleTableModel<I>, DrizzleTableModel<Cr>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
145
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
146
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Proofs").ProofUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Proofs").ProofPersistence>>;
|
|
147
|
-
}, makeProofPersistenceServices: <Rq extends AnySQLiteTable, S extends AnySQLiteTable, G extends AnySQLiteTable, Cn extends AnySQLiteTable, Rs extends AnySQLiteTable, A extends AnySQLiteTable, F extends AnySQLiteTable, C extends AnySQLiteTable, Sub extends AnySQLiteTable, I extends AnySQLiteTable, Cr extends AnySQLiteTable, NativeId>(mapping: import("@yielded/auth-persistence/Adapter").ProofPersistenceMapping<DrizzleTableModel<Rq>, DrizzleTableModel<S>, DrizzleTableModel<G>, DrizzleTableModel<Cn>, DrizzleTableModel<Rs>, DrizzleTableModel<A>, DrizzleTableModel<F>, DrizzleTableModel<C>, DrizzleTableModel<Sub>, DrizzleTableModel<I>, DrizzleTableModel<Cr>, NativeId, import("drizzle-orm").SQL<unknown>>) => Effect.Effect<{
|
|
148
|
-
proofPersistence: {
|
|
149
|
-
readonly issue: <A_1>(input: {
|
|
150
|
-
readonly record: import("@yielded/auth/Proofs").ProofRecord;
|
|
151
|
-
readonly policy: import("@yielded/auth/Proofs").ProofPolicy;
|
|
152
|
-
readonly eligible: boolean;
|
|
153
|
-
readonly supersedes?: import("@yielded/auth/Proofs").ProofId;
|
|
154
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<import("@yielded/auth/Proofs").ProofIssueDecision, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofRequestConflict | import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
155
|
-
readonly attempt: <A_1>(input: {
|
|
156
|
-
readonly moduleId: string;
|
|
157
|
-
readonly purpose: import("@yielded/auth/Proofs").ProofPurpose;
|
|
158
|
-
readonly proofId: import("@yielded/auth/Proofs").ProofId;
|
|
159
|
-
readonly binding: import("@yielded/auth/Proofs").ProofBinding;
|
|
160
|
-
readonly candidate?: import("@yielded/auth/Proofs").ProofDigest;
|
|
161
|
-
readonly continuationId: import("@yielded/auth/Proofs").ProofContinuationId;
|
|
162
|
-
readonly continuationDigest: import("@yielded/auth/Schema").TokenDigest;
|
|
163
|
-
readonly nowMillis: number;
|
|
164
|
-
readonly policy: import("@yielded/auth/Proofs").ProofPolicy;
|
|
165
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<import("@yielded/auth/Proofs").ProofAttemptDecision, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
166
|
-
readonly complete: <A_1>(input: import("@yielded/auth/Proofs").ProofCompletionInput, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<import("@yielded/auth/Proofs").ProofCompletionDecision, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
167
|
-
readonly claimDelivery: <A_1>(input: {
|
|
168
|
-
readonly moduleId: string;
|
|
169
|
-
readonly proofId: import("@yielded/auth/Proofs").ProofId;
|
|
170
|
-
readonly version: import("@yielded/auth/Proofs").ProofVersion;
|
|
171
|
-
readonly deliveryId: import("@yielded/auth/Proofs").ProofDeliveryId;
|
|
172
|
-
readonly nowMillis: number;
|
|
173
|
-
readonly policy: import("@yielded/auth/Proofs").ProofPolicy;
|
|
174
|
-
readonly allowAmbiguousRetry: boolean;
|
|
175
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<import("@yielded/auth/Proofs").ProofDeliveryClaim, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
176
|
-
readonly settleDelivery: <A_1>(input: {
|
|
177
|
-
readonly moduleId: string;
|
|
178
|
-
readonly proofId: import("@yielded/auth/Proofs").ProofId;
|
|
179
|
-
readonly version: import("@yielded/auth/Proofs").ProofVersion;
|
|
180
|
-
readonly deliveryId: import("@yielded/auth/Proofs").ProofDeliveryId;
|
|
181
|
-
readonly claimVersion: import("@yielded/auth/Proofs").ProofVersion;
|
|
182
|
-
readonly outcome: import("@yielded/auth/Proofs").ProofDeliveryOutcome;
|
|
183
|
-
readonly nowMillis: number;
|
|
184
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<void, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
185
|
-
readonly cancel: <A_1>(input: {
|
|
186
|
-
readonly moduleId: string;
|
|
187
|
-
readonly purpose: import("@yielded/auth/Proofs").ProofPurpose;
|
|
188
|
-
readonly binding: import("@yielded/auth/Proofs").ProofBinding;
|
|
189
|
-
readonly nowMillis: number;
|
|
190
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<void, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
191
|
-
readonly cleanup: <A_1>(input: {
|
|
192
|
-
readonly moduleId: string;
|
|
193
|
-
readonly nowMillis: number;
|
|
194
|
-
readonly limit: number;
|
|
195
|
-
}, prepare: import("@yielded/auth/Proofs").PrepareProofCommit<import("@yielded/auth/Proofs").ProofCleanupResult, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Proofs").ProofUnavailable>;
|
|
196
|
-
};
|
|
197
|
-
}, import("@yielded/auth/Proofs").ProofUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
198
|
-
export declare const coordinateAuthenticationAuthority: {
|
|
199
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
200
|
-
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, F, P, NativeId>;
|
|
201
|
-
readonly transaction?: never;
|
|
202
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
203
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
204
|
-
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, F, P, NativeId>;
|
|
205
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
206
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
207
|
-
}, coordinatePendingAuthentication: {
|
|
208
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, P extends AnySQLiteTable, F extends AnySQLiteTable, NativeId, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
209
|
-
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, F, NativeId>;
|
|
210
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
211
|
-
readonly transaction?: never;
|
|
212
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
213
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, P extends AnySQLiteTable, F extends AnySQLiteTable, NativeId, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
214
|
-
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, F, NativeId>;
|
|
215
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
216
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
217
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
218
|
-
}, coordinateSignedSessionValidity: {
|
|
219
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
220
|
-
readonly mapping: SignedSessionValidityMapping<S, T, NativeId, NativeSessionId>;
|
|
221
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
222
|
-
readonly transaction?: never;
|
|
223
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
224
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
225
|
-
readonly mapping: SignedSessionValidityMapping<S, T, NativeId, NativeSessionId>;
|
|
226
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
227
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
228
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
229
|
-
}, coordinateStatefulSessions: {
|
|
230
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, PersistenceId, RepositoryId, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, Session extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, NativeSessionId, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
231
|
-
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, F, P, NativeId, NativeSessionId>;
|
|
232
|
-
readonly persistence: SuppliedService<PersistenceId, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
233
|
-
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
234
|
-
readonly transaction?: never;
|
|
235
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, PersistenceId | RepositoryId>>;
|
|
236
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, PersistenceId, RepositoryId, Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, Session extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, NativeSessionId, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
237
|
-
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, F, P, NativeId, NativeSessionId>;
|
|
238
|
-
readonly persistence: SuppliedService<PersistenceId, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
239
|
-
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
240
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
241
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, PersistenceId | RepositoryId | TxId>>;
|
|
242
|
-
}, makeAuthenticationAuthorityServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId>(mapping: AuthenticationAuthorityMapping<Claims, S, C, F, P, NativeId>) => Effect.Effect<{
|
|
243
|
-
authenticationAuthority: {
|
|
244
|
-
readonly capture: (subjectId: import("@yielded/auth/Schema").SubjectId, credentialIds: ReadonlyArray<string>) => Effect.Effect<import("@yielded/auth/Sessions").AuthenticationCapture, import("@yielded/auth/Sessions").StaleAuthentication | import("@yielded/auth/Sessions").SessionUnavailable>;
|
|
245
|
-
readonly requirements: (evidence: import("@yielded/auth/Sessions").AuthenticationEvidence) => Effect.Effect<import("@yielded/auth/Sessions").AuthenticationRequirement, import("@yielded/auth/Sessions").StaleAuthentication | import("@yielded/auth/Sessions").SessionUnavailable>;
|
|
246
|
-
readonly approve: <A>(input: {
|
|
247
|
-
readonly evidence: import("@yielded/auth/Sessions").AuthenticationEvidence;
|
|
248
|
-
readonly now: import("effect/DateTime").Utc;
|
|
249
|
-
readonly expiresAt: import("effect/DateTime").Utc;
|
|
250
|
-
readonly absoluteExpiresAt: import("effect/DateTime").Utc;
|
|
251
|
-
readonly pending?: import("@yielded/auth/Sessions").PendingConsumption;
|
|
252
|
-
}, prepare: import("@yielded/auth/Sessions").PrepareSessionCommit<void, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Sessions").StaleAuthentication | import("@yielded/auth/Sessions").PendingAuthenticationInvalid | import("@yielded/auth/Sessions").SessionUnavailable>;
|
|
253
|
-
};
|
|
254
|
-
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makePendingAuthenticationServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, P extends AnySQLiteTable, F extends AnySQLiteTable, NativeId>(mapping: PendingAuthenticationMapping<Claims, S, C, P, F, NativeId>) => Effect.Effect<{
|
|
255
|
-
pendingAuthentication: import("@yielded/auth/Sessions").PendingAuthentication<Claims>;
|
|
256
|
-
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeSessionStepUpServices: <Claims, Id, S extends AnySQLiteTable, C extends AnySQLiteTable, I extends AnySQLiteTable, Session extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId>(mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, I, Session, T, NativeId, NativeSessionId>, target: Context.Service<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>) => Effect.Effect<{
|
|
257
|
-
sessionStepUpPersistence: import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>;
|
|
258
|
-
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateSessionStepUp: {
|
|
259
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Claims, Id, S extends AnySQLiteTable, C extends AnySQLiteTable, I extends AnySQLiteTable, Session extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
260
|
-
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, I, Session, T, NativeId, NativeSessionId>;
|
|
261
|
-
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
97
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR>(acquire: Effect.Effect<Database, DE, DR>, options: {
|
|
98
|
+
readonly mapping: ProofPersistenceMapping<Proof, Subject, NativeId>;
|
|
262
99
|
readonly transaction?: never;
|
|
263
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A,
|
|
264
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
265
|
-
readonly mapping:
|
|
266
|
-
readonly
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeStatefulSessionServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, Session extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, NativeSessionId>(mapping: StatefulSessionMapping<Claims, S, C, Session, F, P, NativeId, NativeSessionId>) => Effect.Effect<{
|
|
272
|
-
readonly statefulSessionPersistence: import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>;
|
|
273
|
-
readonly sessionRepository: import("@yielded/auth/Sessions").SessionRepository;
|
|
274
|
-
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
275
|
-
export declare const commitMode: "interactive";
|
|
100
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
101
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId, A, E, R, DE, DR, TxId, TxShape>(acquire: Effect.Effect<Database, DE, DR>, options: {
|
|
102
|
+
readonly mapping: ProofPersistenceMapping<Proof, Subject, NativeId>;
|
|
103
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
104
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
105
|
+
}, makeProofPersistenceServices: <Proof extends import("drizzle-orm").Table, Subject extends import("drizzle-orm").Table, NativeId>(mapping: ProofPersistenceMapping<Proof, Subject, NativeId>) => Effect.Effect<{
|
|
106
|
+
readonly proofPersistence: import("@yielded/auth/Proofs").ProofPersistence["Service"];
|
|
107
|
+
}, import("@yielded/auth/Proofs").ProofUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
276
108
|
export declare const makeIdentityServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, External extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: IdentityTables<Subject, Identifier, External, Request, NativeId>) => Effect.Effect<{
|
|
277
109
|
subjectProvisioner: {
|
|
278
|
-
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").
|
|
110
|
+
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").SubjectProvisioned, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
279
111
|
};
|
|
280
112
|
externalIdentityMutation: {
|
|
281
113
|
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>;
|
|
@@ -283,7 +115,7 @@ export declare const makeIdentityServices: <Subject extends AnySQLiteTable, Iden
|
|
|
283
115
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
284
116
|
export declare const makeSubjectProvisioningServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: SubjectProvisioningTables<Subject, Identifier, Request, NativeId>) => Effect.Effect<{
|
|
285
117
|
readonly subjectProvisioner: {
|
|
286
|
-
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").
|
|
118
|
+
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").SubjectProvisioned, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
287
119
|
};
|
|
288
120
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
289
121
|
export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTable, External extends AnySQLiteTable, NativeId>(mapping: ExternalIdentityTables<Subject, External, NativeId>) => Effect.Effect<{
|
|
@@ -291,22 +123,6 @@ export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTab
|
|
|
291
123
|
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>;
|
|
292
124
|
};
|
|
293
125
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
294
|
-
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, T extends AnySQLiteTable, B extends AnySQLiteTable, NativeId, PS extends AnySQLiteTable = AnySQLiteTable, PC extends AnySQLiteTable = AnySQLiteTable, PM extends AnySQLiteTable = AnySQLiteTable, PSub extends AnySQLiteTable = AnySQLiteTable, PI extends AnySQLiteTable = AnySQLiteTable, PCr extends AnySQLiteTable = AnySQLiteTable, PNativeId = unknown>(mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, M, T, B, NativeId>, proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined) => Effect.Effect<{
|
|
295
|
-
passwordPreparedPersistence: import("@yielded/auth/Password").PasswordPreparedPersistence;
|
|
296
|
-
}, import("@yielded/auth/Password").PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
297
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, T extends AnySQLiteTable, B extends AnySQLiteTable, NativeId, PS extends AnySQLiteTable, PC extends AnySQLiteTable, PM extends AnySQLiteTable, PSub extends AnySQLiteTable, PI extends AnySQLiteTable, PCr extends AnySQLiteTable, PNativeId, Out, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
298
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, M, T, B, NativeId>;
|
|
299
|
-
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
300
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
301
|
-
readonly transaction?: never;
|
|
302
|
-
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
303
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, T extends AnySQLiteTable, B extends AnySQLiteTable, NativeId, PS extends AnySQLiteTable, PC extends AnySQLiteTable, PM extends AnySQLiteTable, PSub extends AnySQLiteTable, PI extends AnySQLiteTable, PCr extends AnySQLiteTable, PNativeId, Out, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
304
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, M, T, B, NativeId>;
|
|
305
|
-
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
306
|
-
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
307
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
308
|
-
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
309
|
-
};
|
|
310
126
|
export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
311
127
|
dialect: "sqlite";
|
|
312
128
|
}>, O extends AnySQLiteTable<{
|
|
@@ -317,260 +133,8 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
317
133
|
dialect: "sqlite";
|
|
318
134
|
}>, F extends AnySQLiteTable<{
|
|
319
135
|
dialect: "sqlite";
|
|
320
|
-
}>,
|
|
321
|
-
|
|
322
|
-
}>, U extends AnySQLiteTable<{
|
|
323
|
-
dialect: "sqlite";
|
|
324
|
-
}>, N>(mapping: OAuthAccountsMapping<S, O, C, AC, F, TA, U, N>) => Effect.Effect<{
|
|
325
|
-
oauthAccountsPersistence: {
|
|
326
|
-
readonly capture: (input: {
|
|
327
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
328
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
329
|
-
}) => Effect.Effect<import("@yielded/auth/OAuth").OAuthAccountRevision | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
330
|
-
readonly issue: <A>(input: {
|
|
331
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthLinkPendingFlow;
|
|
332
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthActionAuthorization;
|
|
333
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
334
|
-
readonly _tag: "Rejected";
|
|
335
|
-
} | {
|
|
336
|
-
readonly _tag: "Issued";
|
|
337
|
-
readonly flow: {
|
|
338
|
-
readonly context: {
|
|
339
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
340
|
-
readonly protocol: "oauth" | "oidc";
|
|
341
|
-
readonly configurationGeneration: number;
|
|
342
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
343
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
344
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
345
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
346
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
347
|
-
readonly generation: number;
|
|
348
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
349
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
350
|
-
readonly access?: {
|
|
351
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
352
|
-
readonly generation: number;
|
|
353
|
-
readonly issuance: "active" | "retired";
|
|
354
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
355
|
-
readonly clientRegistrationId: string;
|
|
356
|
-
readonly scopes: readonly string[];
|
|
357
|
-
readonly resources: readonly string[];
|
|
358
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
359
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
360
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
361
|
-
readonly refreshAheadMillis: number;
|
|
362
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
363
|
-
readonly revocation: "cohort" | "unsupported";
|
|
364
|
-
};
|
|
365
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
366
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
367
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
368
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
369
|
-
readonly issuedAtMillis: number;
|
|
370
|
-
readonly expiresAtMillis: number;
|
|
371
|
-
readonly claimLifetimeMillis: number;
|
|
372
|
-
readonly namespace: "effect-auth/oauth-link-context/v1";
|
|
373
|
-
readonly revision: {
|
|
374
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
375
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
376
|
-
readonly credentials: readonly {
|
|
377
|
-
readonly credentialId: string;
|
|
378
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
379
|
-
}[];
|
|
380
|
-
};
|
|
381
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
382
|
-
};
|
|
383
|
-
readonly sealed: {
|
|
384
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
385
|
-
readonly keyId: string;
|
|
386
|
-
readonly nonce: string;
|
|
387
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
388
|
-
};
|
|
389
|
-
readonly retentionUntilMillis: number;
|
|
390
|
-
};
|
|
391
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
392
|
-
readonly preflight: (input: import("@yielded/auth/OAuth").OAuthLinkAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthLinkPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
393
|
-
readonly claim: <A>(input: {
|
|
394
|
-
readonly access: import("@yielded/auth/OAuth").OAuthLinkAccess;
|
|
395
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthLinkPendingFlow;
|
|
396
|
-
readonly claimId: import("@yielded/auth/OAuth").OAuthLinkClaim["claimId"];
|
|
397
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthActionAuthorization;
|
|
398
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
399
|
-
readonly _tag: "Rejected";
|
|
400
|
-
} | {
|
|
401
|
-
readonly _tag: "Claimed";
|
|
402
|
-
readonly claim: {
|
|
403
|
-
readonly flow: {
|
|
404
|
-
readonly context: {
|
|
405
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
406
|
-
readonly protocol: "oauth" | "oidc";
|
|
407
|
-
readonly configurationGeneration: number;
|
|
408
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
409
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
410
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
411
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
412
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
413
|
-
readonly generation: number;
|
|
414
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
415
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
416
|
-
readonly access?: {
|
|
417
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
418
|
-
readonly generation: number;
|
|
419
|
-
readonly issuance: "active" | "retired";
|
|
420
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
421
|
-
readonly clientRegistrationId: string;
|
|
422
|
-
readonly scopes: readonly string[];
|
|
423
|
-
readonly resources: readonly string[];
|
|
424
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
425
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
426
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
427
|
-
readonly refreshAheadMillis: number;
|
|
428
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
429
|
-
readonly revocation: "cohort" | "unsupported";
|
|
430
|
-
};
|
|
431
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
432
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
433
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
434
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
435
|
-
readonly issuedAtMillis: number;
|
|
436
|
-
readonly expiresAtMillis: number;
|
|
437
|
-
readonly claimLifetimeMillis: number;
|
|
438
|
-
readonly namespace: "effect-auth/oauth-link-context/v1";
|
|
439
|
-
readonly revision: {
|
|
440
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
441
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
442
|
-
readonly credentials: readonly {
|
|
443
|
-
readonly credentialId: string;
|
|
444
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
445
|
-
}[];
|
|
446
|
-
};
|
|
447
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
448
|
-
};
|
|
449
|
-
readonly sealed: {
|
|
450
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
451
|
-
readonly keyId: string;
|
|
452
|
-
readonly nonce: string;
|
|
453
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
454
|
-
};
|
|
455
|
-
readonly retentionUntilMillis: number;
|
|
456
|
-
};
|
|
457
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
458
|
-
readonly claimedAtMillis: number;
|
|
459
|
-
readonly claimExpiresAtMillis: number;
|
|
460
|
-
};
|
|
461
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
462
|
-
readonly settle: <A>(input: {
|
|
463
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthLinkClaim;
|
|
464
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthLinkOutcome;
|
|
465
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthActionAuthorization;
|
|
466
|
-
readonly invalidation: import("@yielded/auth/Sessions").SessionInvalidationWindow;
|
|
467
|
-
readonly nowMillis: number;
|
|
468
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
469
|
-
readonly _tag: "Rejected";
|
|
470
|
-
} | {
|
|
471
|
-
readonly _tag: "Ambiguous";
|
|
472
|
-
} | {
|
|
473
|
-
readonly _tag: "Cancelled";
|
|
474
|
-
} | {
|
|
475
|
-
readonly _tag: "Linked";
|
|
476
|
-
readonly credential: {
|
|
477
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
478
|
-
readonly identity: {
|
|
479
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
480
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
481
|
-
readonly subject: string;
|
|
482
|
-
};
|
|
483
|
-
readonly credentialId: string;
|
|
484
|
-
readonly credentialRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
485
|
-
readonly revision: {
|
|
486
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
487
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
488
|
-
readonly credentials: readonly {
|
|
489
|
-
readonly credentialId: string;
|
|
490
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
491
|
-
}[];
|
|
492
|
-
};
|
|
493
|
-
};
|
|
494
|
-
readonly changed: boolean;
|
|
495
|
-
} | {
|
|
496
|
-
readonly _tag: "Conflict";
|
|
497
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
498
|
-
readonly inspectUnlink: (input: {
|
|
499
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
500
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
501
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
502
|
-
readonly credentialId: string;
|
|
503
|
-
}) => Effect.Effect<{
|
|
504
|
-
readonly _tag: "Rejected";
|
|
505
|
-
} | {
|
|
506
|
-
readonly _tag: "Conflict";
|
|
507
|
-
} | {
|
|
508
|
-
readonly _tag: "Target";
|
|
509
|
-
readonly credential: {
|
|
510
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
511
|
-
readonly identity: {
|
|
512
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
513
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
514
|
-
readonly subject: string;
|
|
515
|
-
};
|
|
516
|
-
readonly credentialId: string;
|
|
517
|
-
readonly credentialRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
518
|
-
readonly revision: {
|
|
519
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
520
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
521
|
-
readonly credentials: readonly {
|
|
522
|
-
readonly credentialId: string;
|
|
523
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
524
|
-
}[];
|
|
525
|
-
};
|
|
526
|
-
};
|
|
527
|
-
} | {
|
|
528
|
-
readonly _tag: "Replay";
|
|
529
|
-
readonly result: {
|
|
530
|
-
readonly _tag: "Unlinked";
|
|
531
|
-
readonly credentialId: string;
|
|
532
|
-
readonly invalidation: {
|
|
533
|
-
readonly trigger: "all-session-revocation" | "credential-change" | "factor-reset" | "identifier-change" | "password-reset" | "subject-delete" | "subject-disable";
|
|
534
|
-
readonly existingSessions: "immediate" | "original-absolute-expiry";
|
|
535
|
-
readonly maximumExposureMillis: number;
|
|
536
|
-
readonly oldAuthenticationEvidence: "rejected";
|
|
537
|
-
};
|
|
538
|
-
};
|
|
539
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
540
|
-
readonly unlink: <A>(input: {
|
|
541
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
542
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
543
|
-
readonly credential: import("@yielded/auth/OAuth").OAuthCredentialSnapshot;
|
|
544
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthActionAuthorization;
|
|
545
|
-
readonly invalidation: import("@yielded/auth/Sessions").SessionInvalidationWindow;
|
|
546
|
-
readonly nowMillis: number;
|
|
547
|
-
readonly retentionUntilMillis: number;
|
|
548
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
549
|
-
readonly _tag: "Rejected";
|
|
550
|
-
} | {
|
|
551
|
-
readonly _tag: "Conflict";
|
|
552
|
-
} | {
|
|
553
|
-
readonly _tag: "Unlinked";
|
|
554
|
-
readonly result: {
|
|
555
|
-
readonly _tag: "Unlinked";
|
|
556
|
-
readonly credentialId: string;
|
|
557
|
-
readonly invalidation: {
|
|
558
|
-
readonly trigger: "all-session-revocation" | "credential-change" | "factor-reset" | "identifier-change" | "password-reset" | "subject-delete" | "subject-disable";
|
|
559
|
-
readonly existingSessions: "immediate" | "original-absolute-expiry";
|
|
560
|
-
readonly maximumExposureMillis: number;
|
|
561
|
-
readonly oldAuthenticationEvidence: "rejected";
|
|
562
|
-
};
|
|
563
|
-
};
|
|
564
|
-
readonly replayed: boolean;
|
|
565
|
-
} | {
|
|
566
|
-
readonly _tag: "LastSignInMethod";
|
|
567
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
568
|
-
readonly cleanup: <A>(input: import("@yielded/auth/OAuth").OAuthCleanupInput, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
569
|
-
readonly terminalized: number;
|
|
570
|
-
readonly removed: number;
|
|
571
|
-
readonly hasMore: boolean;
|
|
572
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
573
|
-
};
|
|
136
|
+
}>, N>(mapping: OAuthAccountsMapping<S, O, C, AC, F, N>) => Effect.Effect<{
|
|
137
|
+
readonly oauthAccountsPersistence: import("@yielded/auth/OAuth").OAuthAccountsPersistence["Service"];
|
|
574
138
|
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthSignInServices: <S extends AnySQLiteTable<{
|
|
575
139
|
dialect: "sqlite";
|
|
576
140
|
}>, O extends AnySQLiteTable<{
|
|
@@ -582,60 +146,13 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
582
146
|
}>, F extends AnySQLiteTable<{
|
|
583
147
|
dialect: "sqlite";
|
|
584
148
|
}>, N>(mapping: OAuthSignInMapping<S, O, C, AC, F, N>) => Effect.Effect<{
|
|
585
|
-
oauthSignInPersistence:
|
|
586
|
-
|
|
587
|
-
readonly claim: <A>(input: {
|
|
588
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
589
|
-
readonly generation: number;
|
|
590
|
-
readonly flowId: import("@yielded/auth/Operations").RequestBindingFlowId;
|
|
591
|
-
readonly provider: import("@yielded/auth/OAuth").OAuthProviderKey;
|
|
592
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
593
|
-
readonly stateDigest: import("@yielded/auth/Schema").TokenDigest;
|
|
594
|
-
readonly requestBindingVerifier: import("@yielded/auth/Schema").TokenDigest;
|
|
595
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
596
|
-
readonly responseIssuer?: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
597
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
598
|
-
readonly nowMillis: number;
|
|
599
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<import("@yielded/auth/OAuth").OAuthClaimDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
600
|
-
readonly settle: <A>(input: {
|
|
601
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthClaim;
|
|
602
|
-
readonly outcome: {
|
|
603
|
-
readonly _tag: "Verified";
|
|
604
|
-
readonly identity: import("@yielded/auth/OAuth").OAuthVerifiedExternalIdentity;
|
|
605
|
-
} | {
|
|
606
|
-
readonly _tag: "Cancelled" | "Rejected" | "Ambiguous";
|
|
607
|
-
};
|
|
608
|
-
readonly nowMillis: number;
|
|
609
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<import("@yielded/auth/OAuth").OAuthSettlementDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
610
|
-
readonly cleanup: <A>(input: import("@yielded/auth/OAuth").OAuthCleanupInput, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
611
|
-
readonly terminalized: number;
|
|
612
|
-
readonly removed: number;
|
|
613
|
-
readonly hasMore: boolean;
|
|
614
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
615
|
-
};
|
|
616
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationIntentServices: <S extends AnySQLiteTable<{
|
|
617
|
-
dialect: "sqlite";
|
|
618
|
-
}>, O extends AnySQLiteTable<{
|
|
619
|
-
dialect: "sqlite";
|
|
620
|
-
}>, C extends AnySQLiteTable<{
|
|
621
|
-
dialect: "sqlite";
|
|
622
|
-
}>, AC extends AnySQLiteTable<{
|
|
623
|
-
dialect: "sqlite";
|
|
624
|
-
}>, F extends AnySQLiteTable<{
|
|
625
|
-
dialect: "sqlite";
|
|
626
|
-
}>, TA extends AnySQLiteTable<{
|
|
149
|
+
readonly oauthSignInPersistence: import("@yielded/auth/OAuth").OAuthSignInPersistence["Service"];
|
|
150
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationIntentServices: <O extends AnySQLiteTable<{
|
|
627
151
|
dialect: "sqlite";
|
|
628
152
|
}>, I extends AnySQLiteTable<{
|
|
629
153
|
dialect: "sqlite";
|
|
630
|
-
}>, N>(mapping: OAuthRegistrationIntentMapping<
|
|
631
|
-
oauthRegistrationIntents:
|
|
632
|
-
readonly settle: <A>(input: {
|
|
633
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthClaim;
|
|
634
|
-
readonly identity: import("@yielded/auth/OAuth").OAuthVerifiedExternalIdentity;
|
|
635
|
-
readonly intent?: import("@yielded/auth/OAuth").OAuthRegistrationIntent;
|
|
636
|
-
readonly nowMillis: number;
|
|
637
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<import("@yielded/auth/OAuth").OAuthRegistrationSettlement, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
638
|
-
};
|
|
154
|
+
}>, N>(mapping: OAuthRegistrationIntentMapping<O, I, N>) => Effect.Effect<{
|
|
155
|
+
readonly oauthRegistrationIntents: import("@yielded/auth/OAuth").OAuthRegistrationIntents["Service"];
|
|
639
156
|
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationServices: <Registration, S extends AnySQLiteTable<{
|
|
640
157
|
dialect: "sqlite";
|
|
641
158
|
}>, O extends AnySQLiteTable<{
|
|
@@ -644,14 +161,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
644
161
|
dialect: "sqlite";
|
|
645
162
|
}>, AC extends AnySQLiteTable<{
|
|
646
163
|
dialect: "sqlite";
|
|
647
|
-
}>, TA extends AnySQLiteTable<{
|
|
648
|
-
dialect: "sqlite";
|
|
649
164
|
}>, I extends AnySQLiteTable<{
|
|
650
165
|
dialect: "sqlite";
|
|
651
|
-
}>,
|
|
652
|
-
|
|
653
|
-
}>, N>(mapping: OAuthRegistrationMapping<Registration, S, O, C, AC, TA, I, R, N>) => Effect.Effect<{
|
|
654
|
-
registrationAuthority: import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>;
|
|
166
|
+
}>, N>(mapping: OAuthRegistrationMapping<Registration, S, O, C, AC, I, N>) => Effect.Effect<{
|
|
167
|
+
readonly registrationAuthority: import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>;
|
|
655
168
|
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthRegistration: {
|
|
656
169
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable<{
|
|
657
170
|
dialect: "sqlite";
|
|
@@ -661,17 +174,13 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
661
174
|
dialect: "sqlite";
|
|
662
175
|
}>, AC extends AnySQLiteTable<{
|
|
663
176
|
dialect: "sqlite";
|
|
664
|
-
}>, TA extends AnySQLiteTable<{
|
|
665
|
-
dialect: "sqlite";
|
|
666
177
|
}>, I extends AnySQLiteTable<{
|
|
667
178
|
dialect: "sqlite";
|
|
668
|
-
}>, Rq extends AnySQLiteTable<{
|
|
669
|
-
dialect: "sqlite";
|
|
670
179
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
671
|
-
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC,
|
|
180
|
+
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC, I, N>;
|
|
672
181
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>>;
|
|
673
182
|
readonly transaction?: never;
|
|
674
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
183
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
675
184
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable<{
|
|
676
185
|
dialect: "sqlite";
|
|
677
186
|
}>, O extends AnySQLiteTable<{
|
|
@@ -680,19 +189,15 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
680
189
|
dialect: "sqlite";
|
|
681
190
|
}>, AC extends AnySQLiteTable<{
|
|
682
191
|
dialect: "sqlite";
|
|
683
|
-
}>, TA extends AnySQLiteTable<{
|
|
684
|
-
dialect: "sqlite";
|
|
685
192
|
}>, I extends AnySQLiteTable<{
|
|
686
193
|
dialect: "sqlite";
|
|
687
|
-
}>, Rq extends AnySQLiteTable<{
|
|
688
|
-
dialect: "sqlite";
|
|
689
194
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
690
|
-
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC,
|
|
195
|
+
readonly mapping: OAuthRegistrationMapping<NoInfer<Registration>, S, O, C, AC, I, N>;
|
|
691
196
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").OAuthRegistrationAuthority<Registration>>;
|
|
692
197
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
693
198
|
readonly transaction: (...args: any[]) => any;
|
|
694
199
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
695
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
200
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
696
201
|
}, coordinateOAuthSignIn: {
|
|
697
202
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
698
203
|
dialect: "sqlite";
|
|
@@ -707,7 +212,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
707
212
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
708
213
|
readonly mapping: OAuthSignInMapping<S, O, C, AC, F, N>;
|
|
709
214
|
readonly transaction?: never;
|
|
710
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
215
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/OAuth").OAuthSignInPersistence>>;
|
|
711
216
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
712
217
|
dialect: "sqlite";
|
|
713
218
|
}>, O extends AnySQLiteTable<{
|
|
@@ -723,46 +228,26 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
723
228
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
724
229
|
readonly transaction: (...args: any[]) => any;
|
|
725
230
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
726
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
231
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/OAuth").OAuthSignInPersistence>>;
|
|
727
232
|
}, coordinateOAuthRegistrationIntents: {
|
|
728
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
729
|
-
dialect: "sqlite";
|
|
730
|
-
}>, O extends AnySQLiteTable<{
|
|
731
|
-
dialect: "sqlite";
|
|
732
|
-
}>, C extends AnySQLiteTable<{
|
|
733
|
-
dialect: "sqlite";
|
|
734
|
-
}>, AC extends AnySQLiteTable<{
|
|
735
|
-
dialect: "sqlite";
|
|
736
|
-
}>, F extends AnySQLiteTable<{
|
|
737
|
-
dialect: "sqlite";
|
|
738
|
-
}>, TA extends AnySQLiteTable<{
|
|
233
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, O extends AnySQLiteTable<{
|
|
739
234
|
dialect: "sqlite";
|
|
740
235
|
}>, I extends AnySQLiteTable<{
|
|
741
236
|
dialect: "sqlite";
|
|
742
237
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
743
|
-
readonly mapping: OAuthRegistrationIntentMapping<
|
|
238
|
+
readonly mapping: OAuthRegistrationIntentMapping<O, I, N>;
|
|
744
239
|
readonly transaction?: never;
|
|
745
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
746
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
747
|
-
dialect: "sqlite";
|
|
748
|
-
}>, O extends AnySQLiteTable<{
|
|
749
|
-
dialect: "sqlite";
|
|
750
|
-
}>, C extends AnySQLiteTable<{
|
|
751
|
-
dialect: "sqlite";
|
|
752
|
-
}>, AC extends AnySQLiteTable<{
|
|
753
|
-
dialect: "sqlite";
|
|
754
|
-
}>, F extends AnySQLiteTable<{
|
|
755
|
-
dialect: "sqlite";
|
|
756
|
-
}>, TA extends AnySQLiteTable<{
|
|
240
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/OAuth").OAuthRegistrationIntents>>;
|
|
241
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, O extends AnySQLiteTable<{
|
|
757
242
|
dialect: "sqlite";
|
|
758
243
|
}>, I extends AnySQLiteTable<{
|
|
759
244
|
dialect: "sqlite";
|
|
760
245
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
761
|
-
readonly mapping: OAuthRegistrationIntentMapping<
|
|
246
|
+
readonly mapping: OAuthRegistrationIntentMapping<O, I, N>;
|
|
762
247
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
763
248
|
readonly transaction: (...args: any[]) => any;
|
|
764
249
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
765
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
250
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/OAuth").OAuthRegistrationIntents>>;
|
|
766
251
|
}, coordinateOAuthAccounts: {
|
|
767
252
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
768
253
|
dialect: "sqlite";
|
|
@@ -774,14 +259,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
774
259
|
dialect: "sqlite";
|
|
775
260
|
}>, F extends AnySQLiteTable<{
|
|
776
261
|
dialect: "sqlite";
|
|
777
|
-
}>, TA extends AnySQLiteTable<{
|
|
778
|
-
dialect: "sqlite";
|
|
779
|
-
}>, U extends AnySQLiteTable<{
|
|
780
|
-
dialect: "sqlite";
|
|
781
262
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
782
|
-
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F,
|
|
263
|
+
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F, N>;
|
|
783
264
|
readonly transaction?: never;
|
|
784
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
265
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/OAuth").OAuthAccountsPersistence>>;
|
|
785
266
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
786
267
|
dialect: "sqlite";
|
|
787
268
|
}>, O extends AnySQLiteTable<{
|
|
@@ -792,1210 +273,92 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
792
273
|
dialect: "sqlite";
|
|
793
274
|
}>, F extends AnySQLiteTable<{
|
|
794
275
|
dialect: "sqlite";
|
|
795
|
-
}>, TA extends AnySQLiteTable<{
|
|
796
|
-
dialect: "sqlite";
|
|
797
|
-
}>, U extends AnySQLiteTable<{
|
|
798
|
-
dialect: "sqlite";
|
|
799
276
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
800
|
-
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F,
|
|
277
|
+
readonly mapping: OAuthAccountsMapping<S, O, C, AC, F, N>;
|
|
801
278
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
802
279
|
readonly transaction: (...args: any[]) => any;
|
|
803
280
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
804
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
281
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/OAuth").OAuthAccountsPersistence>>;
|
|
805
282
|
}, makeOAuthConnectedServices: <S extends AnySQLiteTable<{
|
|
806
283
|
dialect: "sqlite";
|
|
807
284
|
}>, AC extends AnySQLiteTable<{
|
|
808
285
|
dialect: "sqlite";
|
|
809
|
-
}>, T extends AnySQLiteTable<{
|
|
810
|
-
dialect: "sqlite";
|
|
811
286
|
}>, O extends AnySQLiteTable<{
|
|
812
287
|
dialect: "sqlite";
|
|
813
288
|
}>, F extends AnySQLiteTable<{
|
|
814
289
|
dialect: "sqlite";
|
|
815
290
|
}>, G extends AnySQLiteTable<{
|
|
816
291
|
dialect: "sqlite";
|
|
817
|
-
}>, C extends AnySQLiteTable<{
|
|
818
|
-
dialect: "sqlite";
|
|
819
|
-
}>, H extends AnySQLiteTable<{
|
|
820
|
-
dialect: "sqlite";
|
|
821
|
-
}>, UA extends AnySQLiteTable<{
|
|
822
|
-
dialect: "sqlite";
|
|
823
|
-
}>, DC extends AnySQLiteTable<{
|
|
824
|
-
dialect: "sqlite";
|
|
825
292
|
}>, N, J extends AnySQLiteTable<{
|
|
826
293
|
dialect: "sqlite";
|
|
827
|
-
}> = never>(mapping: OAuthConnectedMapping<S, AC,
|
|
828
|
-
oauthConnectedPersistence:
|
|
829
|
-
|
|
830
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthClaim;
|
|
831
|
-
readonly configuration: import("@yielded/auth/OAuth").OAuthConnectedConfiguration;
|
|
832
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<import("@yielded/auth/OAuth").OAuthSignInAccessClaim, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
833
|
-
readonly inspectSignIn: (input: {
|
|
834
|
-
readonly reservation: import("@yielded/auth/OAuth").OAuthSignInAccessClaim;
|
|
835
|
-
readonly credential: import("@yielded/auth/OAuth").OAuthCredentialSnapshot;
|
|
836
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
837
|
-
}) => Effect.Effect<import("@yielded/auth/OAuth").OAuthSignInAccessInspection, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
838
|
-
readonly settleSignIn: <A>(input: {
|
|
839
|
-
readonly reservation: import("@yielded/auth/OAuth").OAuthSignInAccessClaim;
|
|
840
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
841
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
842
|
-
readonly _tag: "Rejected";
|
|
843
|
-
} | {
|
|
844
|
-
readonly _tag: "Ambiguous";
|
|
845
|
-
} | {
|
|
846
|
-
readonly _tag: "Cancelled";
|
|
847
|
-
} | {
|
|
848
|
-
readonly _tag: "Conflict";
|
|
849
|
-
} | {
|
|
850
|
-
readonly _tag: "Connected";
|
|
851
|
-
readonly grant: {
|
|
852
|
-
readonly context: {
|
|
853
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
854
|
-
readonly exchangeOrder: string;
|
|
855
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
856
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
857
|
-
readonly identity: {
|
|
858
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
859
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
860
|
-
readonly subject: string;
|
|
861
|
-
};
|
|
862
|
-
readonly configuration: {
|
|
863
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
864
|
-
readonly protocol: "oauth" | "oidc";
|
|
865
|
-
readonly configurationGeneration: number;
|
|
866
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
867
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
868
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
869
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
870
|
-
readonly profile: {
|
|
871
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
872
|
-
readonly generation: number;
|
|
873
|
-
readonly issuance: "active" | "retired";
|
|
874
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
875
|
-
readonly clientRegistrationId: string;
|
|
876
|
-
readonly scopes: readonly string[];
|
|
877
|
-
readonly resources: readonly string[];
|
|
878
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
879
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
880
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
881
|
-
readonly refreshAheadMillis: number;
|
|
882
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
883
|
-
readonly revocation: "cohort" | "unsupported";
|
|
884
|
-
};
|
|
885
|
-
};
|
|
886
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
887
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
888
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
889
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
890
|
-
readonly metadata: {
|
|
891
|
-
readonly scopes: readonly string[];
|
|
892
|
-
readonly resources: readonly string[];
|
|
893
|
-
readonly accessExpiresAtMillis?: number;
|
|
894
|
-
readonly refreshExpiresAtMillis?: number;
|
|
895
|
-
readonly useUntilMillis: number;
|
|
896
|
-
readonly refreshUseUntilMillis?: number;
|
|
897
|
-
readonly obtainedAtMillis: number;
|
|
898
|
-
readonly profile?: {
|
|
899
|
-
readonly displayName?: string;
|
|
900
|
-
readonly handle?: string;
|
|
901
|
-
readonly avatarUrl?: string;
|
|
902
|
-
readonly profileUrl?: string;
|
|
903
|
-
readonly email?: string;
|
|
904
|
-
readonly emailVerified?: boolean;
|
|
905
|
-
readonly providerData?: {
|
|
906
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
907
|
-
};
|
|
908
|
-
};
|
|
909
|
-
};
|
|
910
|
-
};
|
|
911
|
-
readonly sealed: {
|
|
912
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
913
|
-
readonly keyId: string;
|
|
914
|
-
readonly nonce: string;
|
|
915
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
916
|
-
};
|
|
917
|
-
};
|
|
918
|
-
} | {
|
|
919
|
-
readonly _tag: "Busy";
|
|
920
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
921
|
-
readonly capture: (input: {
|
|
922
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
923
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
924
|
-
readonly grantId?: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
925
|
-
}) => Effect.Effect<{
|
|
926
|
-
readonly revision: import("@yielded/auth/OAuth").OAuthAccountRevision;
|
|
927
|
-
readonly target?: import("@yielded/auth/OAuth").OAuthConnectedTarget;
|
|
928
|
-
} | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
929
|
-
readonly issue: <A>(input: {
|
|
930
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
931
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
932
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
933
|
-
readonly _tag: "Rejected";
|
|
934
|
-
} | {
|
|
935
|
-
readonly _tag: "Issued";
|
|
936
|
-
readonly flow: {
|
|
937
|
-
readonly context: {
|
|
938
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
939
|
-
readonly protocol: "oauth" | "oidc";
|
|
940
|
-
readonly configurationGeneration: number;
|
|
941
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
942
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
943
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
944
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
945
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
946
|
-
readonly generation: number;
|
|
947
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
948
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
949
|
-
readonly access?: {
|
|
950
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
951
|
-
readonly generation: number;
|
|
952
|
-
readonly issuance: "active" | "retired";
|
|
953
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
954
|
-
readonly clientRegistrationId: string;
|
|
955
|
-
readonly scopes: readonly string[];
|
|
956
|
-
readonly resources: readonly string[];
|
|
957
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
958
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
959
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
960
|
-
readonly refreshAheadMillis: number;
|
|
961
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
962
|
-
readonly revocation: "cohort" | "unsupported";
|
|
963
|
-
};
|
|
964
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
965
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
966
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
967
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
968
|
-
readonly issuedAtMillis: number;
|
|
969
|
-
readonly expiresAtMillis: number;
|
|
970
|
-
readonly claimLifetimeMillis: number;
|
|
971
|
-
readonly namespace: "effect-auth/oauth-connected-context/v1";
|
|
972
|
-
readonly revision: {
|
|
973
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
974
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
975
|
-
readonly credentials: readonly {
|
|
976
|
-
readonly credentialId: string;
|
|
977
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
978
|
-
}[];
|
|
979
|
-
};
|
|
980
|
-
readonly profile: {
|
|
981
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
982
|
-
readonly generation: number;
|
|
983
|
-
readonly issuance: "active" | "retired";
|
|
984
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
985
|
-
readonly clientRegistrationId: string;
|
|
986
|
-
readonly scopes: readonly string[];
|
|
987
|
-
readonly resources: readonly string[];
|
|
988
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
989
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
990
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
991
|
-
readonly refreshAheadMillis: number;
|
|
992
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
993
|
-
readonly revocation: "cohort" | "unsupported";
|
|
994
|
-
};
|
|
995
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
996
|
-
readonly reconnect?: {
|
|
997
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
998
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
999
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1000
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1001
|
-
readonly identity: {
|
|
1002
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1003
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1004
|
-
readonly subject: string;
|
|
1005
|
-
};
|
|
1006
|
-
readonly configuration: {
|
|
1007
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1008
|
-
readonly protocol: "oauth" | "oidc";
|
|
1009
|
-
readonly configurationGeneration: number;
|
|
1010
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1011
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1012
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1013
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1014
|
-
readonly profile: {
|
|
1015
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1016
|
-
readonly generation: number;
|
|
1017
|
-
readonly issuance: "active" | "retired";
|
|
1018
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1019
|
-
readonly clientRegistrationId: string;
|
|
1020
|
-
readonly scopes: readonly string[];
|
|
1021
|
-
readonly resources: readonly string[];
|
|
1022
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1023
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1024
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1025
|
-
readonly refreshAheadMillis: number;
|
|
1026
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1027
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1028
|
-
};
|
|
1029
|
-
};
|
|
1030
|
-
};
|
|
1031
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
1032
|
-
};
|
|
1033
|
-
readonly sealed: {
|
|
1034
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
1035
|
-
readonly keyId: string;
|
|
1036
|
-
readonly nonce: string;
|
|
1037
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1038
|
-
};
|
|
1039
|
-
readonly retentionUntilMillis: number;
|
|
1040
|
-
};
|
|
1041
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1042
|
-
readonly prepare: <A>(input: {
|
|
1043
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
1044
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1045
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1046
|
-
readonly _tag: "Rejected";
|
|
1047
|
-
} | {
|
|
1048
|
-
readonly _tag: "Issued";
|
|
1049
|
-
readonly flow: {
|
|
1050
|
-
readonly context: {
|
|
1051
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1052
|
-
readonly protocol: "oauth" | "oidc";
|
|
1053
|
-
readonly configurationGeneration: number;
|
|
1054
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1055
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1056
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1057
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1058
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1059
|
-
readonly generation: number;
|
|
1060
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
1061
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
1062
|
-
readonly access?: {
|
|
1063
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1064
|
-
readonly generation: number;
|
|
1065
|
-
readonly issuance: "active" | "retired";
|
|
1066
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1067
|
-
readonly clientRegistrationId: string;
|
|
1068
|
-
readonly scopes: readonly string[];
|
|
1069
|
-
readonly resources: readonly string[];
|
|
1070
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1071
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1072
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1073
|
-
readonly refreshAheadMillis: number;
|
|
1074
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1075
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1076
|
-
};
|
|
1077
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
1078
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
1079
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
1080
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
1081
|
-
readonly issuedAtMillis: number;
|
|
1082
|
-
readonly expiresAtMillis: number;
|
|
1083
|
-
readonly claimLifetimeMillis: number;
|
|
1084
|
-
readonly namespace: "effect-auth/oauth-connected-context/v1";
|
|
1085
|
-
readonly revision: {
|
|
1086
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1087
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1088
|
-
readonly credentials: readonly {
|
|
1089
|
-
readonly credentialId: string;
|
|
1090
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1091
|
-
}[];
|
|
1092
|
-
};
|
|
1093
|
-
readonly profile: {
|
|
1094
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1095
|
-
readonly generation: number;
|
|
1096
|
-
readonly issuance: "active" | "retired";
|
|
1097
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1098
|
-
readonly clientRegistrationId: string;
|
|
1099
|
-
readonly scopes: readonly string[];
|
|
1100
|
-
readonly resources: readonly string[];
|
|
1101
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1102
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1103
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1104
|
-
readonly refreshAheadMillis: number;
|
|
1105
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1106
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1107
|
-
};
|
|
1108
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1109
|
-
readonly reconnect?: {
|
|
1110
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1111
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1112
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1113
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1114
|
-
readonly identity: {
|
|
1115
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1116
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1117
|
-
readonly subject: string;
|
|
1118
|
-
};
|
|
1119
|
-
readonly configuration: {
|
|
1120
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1121
|
-
readonly protocol: "oauth" | "oidc";
|
|
1122
|
-
readonly configurationGeneration: number;
|
|
1123
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1124
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1125
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1126
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1127
|
-
readonly profile: {
|
|
1128
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1129
|
-
readonly generation: number;
|
|
1130
|
-
readonly issuance: "active" | "retired";
|
|
1131
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1132
|
-
readonly clientRegistrationId: string;
|
|
1133
|
-
readonly scopes: readonly string[];
|
|
1134
|
-
readonly resources: readonly string[];
|
|
1135
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1136
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1137
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1138
|
-
readonly refreshAheadMillis: number;
|
|
1139
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1140
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1141
|
-
};
|
|
1142
|
-
};
|
|
1143
|
-
};
|
|
1144
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
1145
|
-
};
|
|
1146
|
-
readonly sealed: {
|
|
1147
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
1148
|
-
readonly keyId: string;
|
|
1149
|
-
readonly nonce: string;
|
|
1150
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1151
|
-
};
|
|
1152
|
-
readonly retentionUntilMillis: number;
|
|
1153
|
-
};
|
|
1154
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1155
|
-
readonly inspectPrepared: (input: import("@yielded/auth/OAuth").OAuthConnectedPreparedAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthConnectedPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1156
|
-
readonly preflight: (input: import("@yielded/auth/OAuth").OAuthConnectedAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthConnectedPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1157
|
-
readonly claim: <A>(input: {
|
|
1158
|
-
readonly access: import("@yielded/auth/OAuth").OAuthConnectedAccess;
|
|
1159
|
-
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
1160
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1161
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
1162
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1163
|
-
readonly _tag: "Rejected";
|
|
1164
|
-
} | {
|
|
1165
|
-
readonly _tag: "Claimed";
|
|
1166
|
-
readonly claim: {
|
|
1167
|
-
readonly flow: {
|
|
1168
|
-
readonly context: {
|
|
1169
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1170
|
-
readonly protocol: "oauth" | "oidc";
|
|
1171
|
-
readonly configurationGeneration: number;
|
|
1172
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1173
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1174
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1175
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1176
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1177
|
-
readonly generation: number;
|
|
1178
|
-
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
1179
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
1180
|
-
readonly access?: {
|
|
1181
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1182
|
-
readonly generation: number;
|
|
1183
|
-
readonly issuance: "active" | "retired";
|
|
1184
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1185
|
-
readonly clientRegistrationId: string;
|
|
1186
|
-
readonly scopes: readonly string[];
|
|
1187
|
-
readonly resources: readonly string[];
|
|
1188
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1189
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1190
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1191
|
-
readonly refreshAheadMillis: number;
|
|
1192
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1193
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1194
|
-
};
|
|
1195
|
-
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
1196
|
-
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
1197
|
-
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
1198
|
-
readonly requestBindingExpiresAtMillis: number;
|
|
1199
|
-
readonly issuedAtMillis: number;
|
|
1200
|
-
readonly expiresAtMillis: number;
|
|
1201
|
-
readonly claimLifetimeMillis: number;
|
|
1202
|
-
readonly namespace: "effect-auth/oauth-connected-context/v1";
|
|
1203
|
-
readonly revision: {
|
|
1204
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1205
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1206
|
-
readonly credentials: readonly {
|
|
1207
|
-
readonly credentialId: string;
|
|
1208
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1209
|
-
}[];
|
|
1210
|
-
};
|
|
1211
|
-
readonly profile: {
|
|
1212
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1213
|
-
readonly generation: number;
|
|
1214
|
-
readonly issuance: "active" | "retired";
|
|
1215
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1216
|
-
readonly clientRegistrationId: string;
|
|
1217
|
-
readonly scopes: readonly string[];
|
|
1218
|
-
readonly resources: readonly string[];
|
|
1219
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1220
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1221
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1222
|
-
readonly refreshAheadMillis: number;
|
|
1223
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1224
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1225
|
-
};
|
|
1226
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1227
|
-
readonly reconnect?: {
|
|
1228
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1229
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1230
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1231
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1232
|
-
readonly identity: {
|
|
1233
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1234
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1235
|
-
readonly subject: string;
|
|
1236
|
-
};
|
|
1237
|
-
readonly configuration: {
|
|
1238
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1239
|
-
readonly protocol: "oauth" | "oidc";
|
|
1240
|
-
readonly configurationGeneration: number;
|
|
1241
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1242
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1243
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1244
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1245
|
-
readonly profile: {
|
|
1246
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1247
|
-
readonly generation: number;
|
|
1248
|
-
readonly issuance: "active" | "retired";
|
|
1249
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1250
|
-
readonly clientRegistrationId: string;
|
|
1251
|
-
readonly scopes: readonly string[];
|
|
1252
|
-
readonly resources: readonly string[];
|
|
1253
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1254
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1255
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1256
|
-
readonly refreshAheadMillis: number;
|
|
1257
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1258
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1259
|
-
};
|
|
1260
|
-
};
|
|
1261
|
-
};
|
|
1262
|
-
readonly maximumEvidenceAgeMillis: number;
|
|
1263
|
-
};
|
|
1264
|
-
readonly sealed: {
|
|
1265
|
-
readonly format: "oauth-xchacha20poly1305-v1";
|
|
1266
|
-
readonly keyId: string;
|
|
1267
|
-
readonly nonce: string;
|
|
1268
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1269
|
-
};
|
|
1270
|
-
readonly retentionUntilMillis: number;
|
|
1271
|
-
};
|
|
1272
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1273
|
-
readonly claimedAtMillis: number;
|
|
1274
|
-
readonly claimExpiresAtMillis: number;
|
|
1275
|
-
readonly order: string;
|
|
1276
|
-
};
|
|
1277
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1278
|
-
readonly inspectGrant: (input: {
|
|
1279
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedClaim;
|
|
1280
|
-
readonly identity: {
|
|
1281
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1282
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1283
|
-
readonly subject: string;
|
|
1284
|
-
};
|
|
1285
|
-
}) => Effect.Effect<{
|
|
1286
|
-
readonly _tag: "Rejected";
|
|
1287
|
-
} | {
|
|
1288
|
-
readonly _tag: "Conflict";
|
|
1289
|
-
} | {
|
|
1290
|
-
readonly _tag: "Target";
|
|
1291
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1292
|
-
} | {
|
|
1293
|
-
readonly _tag: "Quarantine";
|
|
1294
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1295
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1296
|
-
readonly settle: <A>(input: {
|
|
1297
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedClaim;
|
|
1298
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthConnectedOutcome;
|
|
1299
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
1300
|
-
readonly nowMillis: number;
|
|
1301
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1302
|
-
readonly _tag: "Rejected";
|
|
1303
|
-
} | {
|
|
1304
|
-
readonly _tag: "Ambiguous";
|
|
1305
|
-
} | {
|
|
1306
|
-
readonly _tag: "Cancelled";
|
|
1307
|
-
} | {
|
|
1308
|
-
readonly _tag: "Conflict";
|
|
1309
|
-
} | {
|
|
1310
|
-
readonly _tag: "Connected";
|
|
1311
|
-
readonly grant: {
|
|
1312
|
-
readonly context: {
|
|
1313
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1314
|
-
readonly exchangeOrder: string;
|
|
1315
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1316
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1317
|
-
readonly identity: {
|
|
1318
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1319
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1320
|
-
readonly subject: string;
|
|
1321
|
-
};
|
|
1322
|
-
readonly configuration: {
|
|
1323
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1324
|
-
readonly protocol: "oauth" | "oidc";
|
|
1325
|
-
readonly configurationGeneration: number;
|
|
1326
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1327
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1328
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1329
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1330
|
-
readonly profile: {
|
|
1331
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1332
|
-
readonly generation: number;
|
|
1333
|
-
readonly issuance: "active" | "retired";
|
|
1334
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1335
|
-
readonly clientRegistrationId: string;
|
|
1336
|
-
readonly scopes: readonly string[];
|
|
1337
|
-
readonly resources: readonly string[];
|
|
1338
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1339
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1340
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1341
|
-
readonly refreshAheadMillis: number;
|
|
1342
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1343
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1344
|
-
};
|
|
1345
|
-
};
|
|
1346
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1347
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1348
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1349
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1350
|
-
readonly metadata: {
|
|
1351
|
-
readonly scopes: readonly string[];
|
|
1352
|
-
readonly resources: readonly string[];
|
|
1353
|
-
readonly accessExpiresAtMillis?: number;
|
|
1354
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1355
|
-
readonly useUntilMillis: number;
|
|
1356
|
-
readonly refreshUseUntilMillis?: number;
|
|
1357
|
-
readonly obtainedAtMillis: number;
|
|
1358
|
-
readonly profile?: {
|
|
1359
|
-
readonly displayName?: string;
|
|
1360
|
-
readonly handle?: string;
|
|
1361
|
-
readonly avatarUrl?: string;
|
|
1362
|
-
readonly profileUrl?: string;
|
|
1363
|
-
readonly email?: string;
|
|
1364
|
-
readonly emailVerified?: boolean;
|
|
1365
|
-
readonly providerData?: {
|
|
1366
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1367
|
-
};
|
|
1368
|
-
};
|
|
1369
|
-
};
|
|
1370
|
-
};
|
|
1371
|
-
readonly sealed: {
|
|
1372
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1373
|
-
readonly keyId: string;
|
|
1374
|
-
readonly nonce: string;
|
|
1375
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1376
|
-
};
|
|
1377
|
-
};
|
|
1378
|
-
} | {
|
|
1379
|
-
readonly _tag: "Busy";
|
|
1380
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1381
|
-
readonly list: (input: {
|
|
1382
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1383
|
-
readonly limit: number;
|
|
1384
|
-
readonly cursor?: string;
|
|
1385
|
-
}) => Effect.Effect<{
|
|
1386
|
-
readonly items: readonly {
|
|
1387
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1388
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1389
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1390
|
-
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1391
|
-
readonly status: "Active" | "Disconnected" | "ReauthorizationRequired" | "Refreshing";
|
|
1392
|
-
readonly scopes: readonly string[];
|
|
1393
|
-
readonly accessExpiresAtMillis?: number;
|
|
1394
|
-
readonly useUntilMillis: number;
|
|
1395
|
-
readonly profile?: {
|
|
1396
|
-
readonly displayName?: string;
|
|
1397
|
-
readonly handle?: string;
|
|
1398
|
-
readonly avatarUrl?: string;
|
|
1399
|
-
readonly profileUrl?: string;
|
|
1400
|
-
readonly email?: string;
|
|
1401
|
-
readonly emailVerified?: boolean;
|
|
1402
|
-
readonly providerData?: {
|
|
1403
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1404
|
-
};
|
|
1405
|
-
};
|
|
1406
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
1407
|
-
}[];
|
|
1408
|
-
readonly cursor?: string;
|
|
1409
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1410
|
-
readonly inspectDisconnect: (input: {
|
|
1411
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1412
|
-
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
1413
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1414
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
1415
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1416
|
-
}) => Effect.Effect<{
|
|
1417
|
-
readonly _tag: "Rejected";
|
|
1418
|
-
} | {
|
|
1419
|
-
readonly _tag: "Conflict";
|
|
1420
|
-
} | {
|
|
1421
|
-
readonly _tag: "Target";
|
|
1422
|
-
readonly grant: {
|
|
1423
|
-
readonly context: {
|
|
1424
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1425
|
-
readonly exchangeOrder: string;
|
|
1426
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1427
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1428
|
-
readonly identity: {
|
|
1429
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1430
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1431
|
-
readonly subject: string;
|
|
1432
|
-
};
|
|
1433
|
-
readonly configuration: {
|
|
1434
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1435
|
-
readonly protocol: "oauth" | "oidc";
|
|
1436
|
-
readonly configurationGeneration: number;
|
|
1437
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1438
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1439
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1440
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1441
|
-
readonly profile: {
|
|
1442
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1443
|
-
readonly generation: number;
|
|
1444
|
-
readonly issuance: "active" | "retired";
|
|
1445
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1446
|
-
readonly clientRegistrationId: string;
|
|
1447
|
-
readonly scopes: readonly string[];
|
|
1448
|
-
readonly resources: readonly string[];
|
|
1449
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1450
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1451
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1452
|
-
readonly refreshAheadMillis: number;
|
|
1453
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1454
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1455
|
-
};
|
|
1456
|
-
};
|
|
1457
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1458
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1459
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1460
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1461
|
-
readonly metadata: {
|
|
1462
|
-
readonly scopes: readonly string[];
|
|
1463
|
-
readonly resources: readonly string[];
|
|
1464
|
-
readonly accessExpiresAtMillis?: number;
|
|
1465
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1466
|
-
readonly useUntilMillis: number;
|
|
1467
|
-
readonly refreshUseUntilMillis?: number;
|
|
1468
|
-
readonly obtainedAtMillis: number;
|
|
1469
|
-
readonly profile?: {
|
|
1470
|
-
readonly displayName?: string;
|
|
1471
|
-
readonly handle?: string;
|
|
1472
|
-
readonly avatarUrl?: string;
|
|
1473
|
-
readonly profileUrl?: string;
|
|
1474
|
-
readonly email?: string;
|
|
1475
|
-
readonly emailVerified?: boolean;
|
|
1476
|
-
readonly providerData?: {
|
|
1477
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1478
|
-
};
|
|
1479
|
-
};
|
|
1480
|
-
};
|
|
1481
|
-
};
|
|
1482
|
-
readonly sealed?: {
|
|
1483
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1484
|
-
readonly keyId: string;
|
|
1485
|
-
readonly nonce: string;
|
|
1486
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1487
|
-
};
|
|
1488
|
-
};
|
|
1489
|
-
readonly revision: {
|
|
1490
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1491
|
-
readonly securityRevision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1492
|
-
readonly credentials: readonly {
|
|
1493
|
-
readonly credentialId: string;
|
|
1494
|
-
readonly revision: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1495
|
-
}[];
|
|
1496
|
-
};
|
|
1497
|
-
} | {
|
|
1498
|
-
readonly _tag: "Replay";
|
|
1499
|
-
readonly result: {
|
|
1500
|
-
readonly _tag: "Disconnected";
|
|
1501
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1502
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
1503
|
-
readonly affectedGrantCount: number;
|
|
1504
|
-
readonly replayed: boolean;
|
|
1505
|
-
};
|
|
1506
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1507
|
-
readonly disconnect: <A>(input: {
|
|
1508
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1509
|
-
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
1510
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedDisconnectGrant;
|
|
1511
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
1512
|
-
readonly revocation?: import("@yielded/auth/OAuth").OAuthConnectedRevocationJob;
|
|
1513
|
-
readonly retentionUntilMillis: number;
|
|
1514
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1515
|
-
readonly _tag: "Rejected";
|
|
1516
|
-
} | {
|
|
1517
|
-
readonly _tag: "Conflict";
|
|
1518
|
-
} | {
|
|
1519
|
-
readonly _tag: "Disconnected";
|
|
1520
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1521
|
-
readonly remoteRevocation: "Confirmed" | "Pending" | "Unknown" | "Unsupported";
|
|
1522
|
-
readonly affectedGrantCount: number;
|
|
1523
|
-
readonly replayed: boolean;
|
|
1524
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1525
|
-
readonly inspectAccess: (input: {
|
|
1526
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1527
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1528
|
-
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1529
|
-
}) => Effect.Effect<{
|
|
1530
|
-
readonly _tag: "Rejected";
|
|
1531
|
-
} | {
|
|
1532
|
-
readonly _tag: "Busy";
|
|
1533
|
-
} | {
|
|
1534
|
-
readonly _tag: "Target";
|
|
1535
|
-
readonly grant: {
|
|
1536
|
-
readonly context: {
|
|
1537
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1538
|
-
readonly exchangeOrder: string;
|
|
1539
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1540
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1541
|
-
readonly identity: {
|
|
1542
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1543
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1544
|
-
readonly subject: string;
|
|
1545
|
-
};
|
|
1546
|
-
readonly configuration: {
|
|
1547
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1548
|
-
readonly protocol: "oauth" | "oidc";
|
|
1549
|
-
readonly configurationGeneration: number;
|
|
1550
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1551
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1552
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1553
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1554
|
-
readonly profile: {
|
|
1555
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1556
|
-
readonly generation: number;
|
|
1557
|
-
readonly issuance: "active" | "retired";
|
|
1558
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1559
|
-
readonly clientRegistrationId: string;
|
|
1560
|
-
readonly scopes: readonly string[];
|
|
1561
|
-
readonly resources: readonly string[];
|
|
1562
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1563
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1564
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1565
|
-
readonly refreshAheadMillis: number;
|
|
1566
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1567
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1568
|
-
};
|
|
1569
|
-
};
|
|
1570
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1571
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1572
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1573
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1574
|
-
readonly metadata: {
|
|
1575
|
-
readonly scopes: readonly string[];
|
|
1576
|
-
readonly resources: readonly string[];
|
|
1577
|
-
readonly accessExpiresAtMillis?: number;
|
|
1578
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1579
|
-
readonly useUntilMillis: number;
|
|
1580
|
-
readonly refreshUseUntilMillis?: number;
|
|
1581
|
-
readonly obtainedAtMillis: number;
|
|
1582
|
-
readonly profile?: {
|
|
1583
|
-
readonly displayName?: string;
|
|
1584
|
-
readonly handle?: string;
|
|
1585
|
-
readonly avatarUrl?: string;
|
|
1586
|
-
readonly profileUrl?: string;
|
|
1587
|
-
readonly email?: string;
|
|
1588
|
-
readonly emailVerified?: boolean;
|
|
1589
|
-
readonly providerData?: {
|
|
1590
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1591
|
-
};
|
|
1592
|
-
};
|
|
1593
|
-
};
|
|
1594
|
-
};
|
|
1595
|
-
readonly sealed: {
|
|
1596
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1597
|
-
readonly keyId: string;
|
|
1598
|
-
readonly nonce: string;
|
|
1599
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1600
|
-
};
|
|
1601
|
-
};
|
|
1602
|
-
} | {
|
|
1603
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1604
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1605
|
-
readonly claimRefresh: <A>(input: {
|
|
1606
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
1607
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1608
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1609
|
-
readonly nextTokenVersion: import("@yielded/auth/OAuth").OAuthConnectedRefreshClaim["nextTokenVersion"];
|
|
1610
|
-
readonly lifetimeMillis: number;
|
|
1611
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1612
|
-
readonly _tag: "Rejected";
|
|
1613
|
-
} | {
|
|
1614
|
-
readonly _tag: "Busy";
|
|
1615
|
-
} | {
|
|
1616
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1617
|
-
} | {
|
|
1618
|
-
readonly _tag: "Claimed";
|
|
1619
|
-
readonly claim: {
|
|
1620
|
-
readonly grant: {
|
|
1621
|
-
readonly context: {
|
|
1622
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1623
|
-
readonly exchangeOrder: string;
|
|
1624
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1625
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1626
|
-
readonly identity: {
|
|
1627
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1628
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1629
|
-
readonly subject: string;
|
|
1630
|
-
};
|
|
1631
|
-
readonly configuration: {
|
|
1632
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1633
|
-
readonly protocol: "oauth" | "oidc";
|
|
1634
|
-
readonly configurationGeneration: number;
|
|
1635
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1636
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1637
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1638
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1639
|
-
readonly profile: {
|
|
1640
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1641
|
-
readonly generation: number;
|
|
1642
|
-
readonly issuance: "active" | "retired";
|
|
1643
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1644
|
-
readonly clientRegistrationId: string;
|
|
1645
|
-
readonly scopes: readonly string[];
|
|
1646
|
-
readonly resources: readonly string[];
|
|
1647
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1648
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1649
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1650
|
-
readonly refreshAheadMillis: number;
|
|
1651
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1652
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1653
|
-
};
|
|
1654
|
-
};
|
|
1655
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1656
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1657
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1658
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1659
|
-
readonly metadata: {
|
|
1660
|
-
readonly scopes: readonly string[];
|
|
1661
|
-
readonly resources: readonly string[];
|
|
1662
|
-
readonly accessExpiresAtMillis?: number;
|
|
1663
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1664
|
-
readonly useUntilMillis: number;
|
|
1665
|
-
readonly refreshUseUntilMillis?: number;
|
|
1666
|
-
readonly obtainedAtMillis: number;
|
|
1667
|
-
readonly profile?: {
|
|
1668
|
-
readonly displayName?: string;
|
|
1669
|
-
readonly handle?: string;
|
|
1670
|
-
readonly avatarUrl?: string;
|
|
1671
|
-
readonly profileUrl?: string;
|
|
1672
|
-
readonly email?: string;
|
|
1673
|
-
readonly emailVerified?: boolean;
|
|
1674
|
-
readonly providerData?: {
|
|
1675
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1676
|
-
};
|
|
1677
|
-
};
|
|
1678
|
-
};
|
|
1679
|
-
};
|
|
1680
|
-
readonly sealed: {
|
|
1681
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1682
|
-
readonly keyId: string;
|
|
1683
|
-
readonly nonce: string;
|
|
1684
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1685
|
-
};
|
|
1686
|
-
};
|
|
1687
|
-
readonly order: string;
|
|
1688
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1689
|
-
readonly claimedAtMillis: number;
|
|
1690
|
-
readonly claimExpiresAtMillis: number;
|
|
1691
|
-
readonly nextTokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1692
|
-
};
|
|
1693
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1694
|
-
readonly settleRefresh: <A>(input: {
|
|
1695
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedRefreshClaim;
|
|
1696
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1697
|
-
readonly outcome: import("@yielded/auth/OAuth").OAuthConnectedRefreshOutcome;
|
|
1698
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1699
|
-
readonly _tag: "Rejected";
|
|
1700
|
-
} | {
|
|
1701
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1702
|
-
} | {
|
|
1703
|
-
readonly _tag: "Refreshed";
|
|
1704
|
-
readonly grant: {
|
|
1705
|
-
readonly context: {
|
|
1706
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1707
|
-
readonly exchangeOrder: string;
|
|
1708
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1709
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1710
|
-
readonly identity: {
|
|
1711
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1712
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1713
|
-
readonly subject: string;
|
|
1714
|
-
};
|
|
1715
|
-
readonly configuration: {
|
|
1716
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1717
|
-
readonly protocol: "oauth" | "oidc";
|
|
1718
|
-
readonly configurationGeneration: number;
|
|
1719
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1720
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1721
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1722
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1723
|
-
readonly profile: {
|
|
1724
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1725
|
-
readonly generation: number;
|
|
1726
|
-
readonly issuance: "active" | "retired";
|
|
1727
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1728
|
-
readonly clientRegistrationId: string;
|
|
1729
|
-
readonly scopes: readonly string[];
|
|
1730
|
-
readonly resources: readonly string[];
|
|
1731
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1732
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1733
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1734
|
-
readonly refreshAheadMillis: number;
|
|
1735
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1736
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1737
|
-
};
|
|
1738
|
-
};
|
|
1739
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1740
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1741
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1742
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1743
|
-
readonly metadata: {
|
|
1744
|
-
readonly scopes: readonly string[];
|
|
1745
|
-
readonly resources: readonly string[];
|
|
1746
|
-
readonly accessExpiresAtMillis?: number;
|
|
1747
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1748
|
-
readonly useUntilMillis: number;
|
|
1749
|
-
readonly refreshUseUntilMillis?: number;
|
|
1750
|
-
readonly obtainedAtMillis: number;
|
|
1751
|
-
readonly profile?: {
|
|
1752
|
-
readonly displayName?: string;
|
|
1753
|
-
readonly handle?: string;
|
|
1754
|
-
readonly avatarUrl?: string;
|
|
1755
|
-
readonly profileUrl?: string;
|
|
1756
|
-
readonly email?: string;
|
|
1757
|
-
readonly emailVerified?: boolean;
|
|
1758
|
-
readonly providerData?: {
|
|
1759
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1760
|
-
};
|
|
1761
|
-
};
|
|
1762
|
-
};
|
|
1763
|
-
};
|
|
1764
|
-
readonly sealed: {
|
|
1765
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1766
|
-
readonly keyId: string;
|
|
1767
|
-
readonly nonce: string;
|
|
1768
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1769
|
-
};
|
|
1770
|
-
};
|
|
1771
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1772
|
-
readonly admitUse: <A>(input: {
|
|
1773
|
-
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
1774
|
-
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedUseAuthorization;
|
|
1775
|
-
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1776
|
-
readonly lifetimeMillis: number;
|
|
1777
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1778
|
-
readonly _tag: "Rejected";
|
|
1779
|
-
} | {
|
|
1780
|
-
readonly _tag: "Busy";
|
|
1781
|
-
} | {
|
|
1782
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1783
|
-
} | {
|
|
1784
|
-
readonly _tag: "Admitted";
|
|
1785
|
-
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1786
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1787
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1788
|
-
readonly admittedAtMillis: number;
|
|
1789
|
-
readonly expiresAtMillis: number;
|
|
1790
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1791
|
-
readonly cleanup: <A>(input: import("@yielded/auth/OAuth").OAuthCleanupInput, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1792
|
-
readonly terminalized: number;
|
|
1793
|
-
readonly removed: number;
|
|
1794
|
-
readonly hasMore: boolean;
|
|
1795
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1796
|
-
};
|
|
1797
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthConnectedRevocationServices: <T extends AnySQLiteTable<{
|
|
1798
|
-
dialect: "sqlite";
|
|
1799
|
-
}>, O extends AnySQLiteTable<{
|
|
294
|
+
}> = never>(mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J>) => Effect.Effect<{
|
|
295
|
+
readonly oauthConnectedPersistence: import("@yielded/auth/OAuth").OAuthConnectedPersistence["Service"];
|
|
296
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthConnectedRevocationServices: <O extends AnySQLiteTable<{
|
|
1800
297
|
dialect: "sqlite";
|
|
1801
298
|
}>, F extends AnySQLiteTable<{
|
|
1802
299
|
dialect: "sqlite";
|
|
1803
|
-
}>, G extends AnySQLiteTable<{
|
|
1804
|
-
dialect: "sqlite";
|
|
1805
|
-
}>, C extends AnySQLiteTable<{
|
|
1806
|
-
dialect: "sqlite";
|
|
1807
|
-
}>, H extends AnySQLiteTable<{
|
|
1808
|
-
dialect: "sqlite";
|
|
1809
300
|
}>, J extends AnySQLiteTable<{
|
|
1810
301
|
dialect: "sqlite";
|
|
1811
|
-
}>, N>(mapping: OAuthConnectedRevocationMapping<
|
|
1812
|
-
oauthConnectedRevocations:
|
|
1813
|
-
|
|
1814
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1815
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1816
|
-
readonly lifetimeMillis: number;
|
|
1817
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1818
|
-
readonly _tag: "Claimed";
|
|
1819
|
-
readonly claim: {
|
|
1820
|
-
readonly job: {
|
|
1821
|
-
readonly context: {
|
|
1822
|
-
readonly namespace: "effect-auth/oauth-connected-revocation-context/v1";
|
|
1823
|
-
readonly jobId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1824
|
-
readonly token: {
|
|
1825
|
-
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1826
|
-
readonly exchangeOrder: string;
|
|
1827
|
-
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1828
|
-
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1829
|
-
readonly identity: {
|
|
1830
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1831
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1832
|
-
readonly subject: string;
|
|
1833
|
-
};
|
|
1834
|
-
readonly configuration: {
|
|
1835
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1836
|
-
readonly protocol: "oauth" | "oidc";
|
|
1837
|
-
readonly configurationGeneration: number;
|
|
1838
|
-
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
1839
|
-
readonly responseIssuerMode: "required" | "unsupported";
|
|
1840
|
-
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
1841
|
-
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
1842
|
-
readonly profile: {
|
|
1843
|
-
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1844
|
-
readonly generation: number;
|
|
1845
|
-
readonly issuance: "active" | "retired";
|
|
1846
|
-
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1847
|
-
readonly clientRegistrationId: string;
|
|
1848
|
-
readonly scopes: readonly string[];
|
|
1849
|
-
readonly resources: readonly string[];
|
|
1850
|
-
readonly retention: "access-and-refresh" | "access-only";
|
|
1851
|
-
readonly maximumAccessLifetimeMillis: number;
|
|
1852
|
-
readonly maximumRefreshLifetimeMillis?: number;
|
|
1853
|
-
readonly refreshAheadMillis: number;
|
|
1854
|
-
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1855
|
-
readonly revocation: "cohort" | "unsupported";
|
|
1856
|
-
};
|
|
1857
|
-
};
|
|
1858
|
-
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
1859
|
-
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1860
|
-
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1861
|
-
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1862
|
-
readonly metadata: {
|
|
1863
|
-
readonly scopes: readonly string[];
|
|
1864
|
-
readonly resources: readonly string[];
|
|
1865
|
-
readonly accessExpiresAtMillis?: number;
|
|
1866
|
-
readonly refreshExpiresAtMillis?: number;
|
|
1867
|
-
readonly useUntilMillis: number;
|
|
1868
|
-
readonly refreshUseUntilMillis?: number;
|
|
1869
|
-
readonly obtainedAtMillis: number;
|
|
1870
|
-
readonly profile?: {
|
|
1871
|
-
readonly displayName?: string;
|
|
1872
|
-
readonly handle?: string;
|
|
1873
|
-
readonly avatarUrl?: string;
|
|
1874
|
-
readonly profileUrl?: string;
|
|
1875
|
-
readonly email?: string;
|
|
1876
|
-
readonly emailVerified?: boolean;
|
|
1877
|
-
readonly providerData?: {
|
|
1878
|
-
readonly [x: string]: import("effect/Schema").Json;
|
|
1879
|
-
};
|
|
1880
|
-
};
|
|
1881
|
-
};
|
|
1882
|
-
};
|
|
1883
|
-
};
|
|
1884
|
-
readonly sealed: {
|
|
1885
|
-
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
1886
|
-
readonly keyId: string;
|
|
1887
|
-
readonly nonce: string;
|
|
1888
|
-
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1889
|
-
};
|
|
1890
|
-
};
|
|
1891
|
-
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1892
|
-
readonly claimedAtMillis: number;
|
|
1893
|
-
readonly claimExpiresAtMillis: number;
|
|
1894
|
-
};
|
|
1895
|
-
} | {
|
|
1896
|
-
readonly _tag: "Empty";
|
|
1897
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1898
|
-
readonly settle: <A>(input: {
|
|
1899
|
-
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedRevocationClaim;
|
|
1900
|
-
readonly outcome: "Confirmed" | "Unknown";
|
|
1901
|
-
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1902
|
-
readonly settled: boolean;
|
|
1903
|
-
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1904
|
-
};
|
|
1905
|
-
}, import("@yielded/auth/OAuth").OAuthUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthConnected: {
|
|
302
|
+
}>, N>(mapping: OAuthConnectedRevocationMapping<O, F, J, N>) => Effect.Effect<{
|
|
303
|
+
readonly oauthConnectedRevocations: import("@yielded/auth/OAuth").OAuthConnectedRevocations["Service"];
|
|
304
|
+
}, import("@yielded/auth/OAuth").OAuthUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthConnected: {
|
|
1906
305
|
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
1907
306
|
dialect: "sqlite";
|
|
1908
307
|
}>, AC extends AnySQLiteTable<{
|
|
1909
308
|
dialect: "sqlite";
|
|
1910
|
-
}>, T extends AnySQLiteTable<{
|
|
1911
|
-
dialect: "sqlite";
|
|
1912
309
|
}>, O extends AnySQLiteTable<{
|
|
1913
310
|
dialect: "sqlite";
|
|
1914
311
|
}>, F extends AnySQLiteTable<{
|
|
1915
312
|
dialect: "sqlite";
|
|
1916
313
|
}>, G extends AnySQLiteTable<{
|
|
1917
314
|
dialect: "sqlite";
|
|
1918
|
-
}>, C extends AnySQLiteTable<{
|
|
1919
|
-
dialect: "sqlite";
|
|
1920
|
-
}>, H extends AnySQLiteTable<{
|
|
1921
|
-
dialect: "sqlite";
|
|
1922
|
-
}>, UA extends AnySQLiteTable<{
|
|
1923
|
-
dialect: "sqlite";
|
|
1924
|
-
}>, DC extends AnySQLiteTable<{
|
|
1925
|
-
dialect: "sqlite";
|
|
1926
315
|
}>, N, J extends AnySQLiteTable<{
|
|
1927
316
|
dialect: "sqlite";
|
|
1928
317
|
}>, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
1929
|
-
readonly mapping: OAuthConnectedMapping<S, AC,
|
|
318
|
+
readonly mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J>;
|
|
1930
319
|
readonly transaction?: never;
|
|
1931
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
320
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/OAuth").OAuthConnectedPersistence>>;
|
|
1932
321
|
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
1933
322
|
dialect: "sqlite";
|
|
1934
323
|
}>, AC extends AnySQLiteTable<{
|
|
1935
324
|
dialect: "sqlite";
|
|
1936
|
-
}>, T extends AnySQLiteTable<{
|
|
1937
|
-
dialect: "sqlite";
|
|
1938
325
|
}>, O extends AnySQLiteTable<{
|
|
1939
326
|
dialect: "sqlite";
|
|
1940
327
|
}>, F extends AnySQLiteTable<{
|
|
1941
328
|
dialect: "sqlite";
|
|
1942
329
|
}>, G extends AnySQLiteTable<{
|
|
1943
330
|
dialect: "sqlite";
|
|
1944
|
-
}>, C extends AnySQLiteTable<{
|
|
1945
|
-
dialect: "sqlite";
|
|
1946
|
-
}>, H extends AnySQLiteTable<{
|
|
1947
|
-
dialect: "sqlite";
|
|
1948
|
-
}>, UA extends AnySQLiteTable<{
|
|
1949
|
-
dialect: "sqlite";
|
|
1950
|
-
}>, DC extends AnySQLiteTable<{
|
|
1951
|
-
dialect: "sqlite";
|
|
1952
331
|
}>, N, J extends AnySQLiteTable<{
|
|
1953
332
|
dialect: "sqlite";
|
|
1954
333
|
}>, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
1955
|
-
readonly mapping: OAuthConnectedMapping<S, AC,
|
|
334
|
+
readonly mapping: OAuthConnectedMapping<S, AC, O, F, G, N, J>;
|
|
1956
335
|
readonly transaction: SuppliedService<TxId, NoInfer<D extends {
|
|
1957
336
|
readonly transaction: (...args: any[]) => any;
|
|
1958
337
|
} ? Parameters<Parameters<D["transaction"]>[0]>[0] : never>, TxShape>;
|
|
1959
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
338
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/OAuth").OAuthConnectedPersistence>>;
|
|
1960
339
|
}, coordinateOAuthConnectedRevocations: {
|
|
1961
|
-
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
1962
|
-
dialect: "sqlite";
|
|
1963
|
-
}>, O extends AnySQLiteTable<{
|
|
340
|
+
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, O extends AnySQLiteTable<{
|
|
1964
341
|
dialect: "sqlite";
|
|
1965
342
|
}>, F extends AnySQLiteTable<{
|
|
1966
343
|
dialect: "sqlite";
|
|
1967
|
-
}>, G extends AnySQLiteTable<{
|
|
1968
|
-
dialect: "sqlite";
|
|
1969
|
-
}>, C extends AnySQLiteTable<{
|
|
1970
|
-
dialect: "sqlite";
|
|
1971
|
-
}>, H extends AnySQLiteTable<{
|
|
1972
|
-
dialect: "sqlite";
|
|
1973
344
|
}>, J extends AnySQLiteTable<{
|
|
1974
345
|
dialect: "sqlite";
|
|
1975
346
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
1976
|
-
readonly mapping: OAuthConnectedRevocationMapping<
|
|
347
|
+
readonly mapping: OAuthConnectedRevocationMapping<O, F, J, N>;
|
|
1977
348
|
readonly transaction?: never;
|
|
1978
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
1979
|
-
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
1980
|
-
dialect: "sqlite";
|
|
1981
|
-
}>, O extends AnySQLiteTable<{
|
|
349
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/OAuth").OAuthConnectedRevocations>>;
|
|
350
|
+
<D extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, O extends AnySQLiteTable<{
|
|
1982
351
|
dialect: "sqlite";
|
|
1983
352
|
}>, F extends AnySQLiteTable<{
|
|
1984
353
|
dialect: "sqlite";
|
|
1985
|
-
}>, G extends AnySQLiteTable<{
|
|
1986
|
-
dialect: "sqlite";
|
|
1987
|
-
}>, C extends AnySQLiteTable<{
|
|
1988
|
-
dialect: "sqlite";
|
|
1989
|
-
}>, H extends AnySQLiteTable<{
|
|
1990
|
-
dialect: "sqlite";
|
|
1991
354
|
}>, J extends AnySQLiteTable<{
|
|
1992
355
|
dialect: "sqlite";
|
|
1993
356
|
}>, N, A, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
1994
|
-
readonly mapping: OAuthConnectedRevocationMapping<
|
|
357
|
+
readonly mapping: OAuthConnectedRevocationMapping<O, F, J, N>;
|
|
1995
358
|
readonly transaction: SuppliedService<TxId, NoInfer<D extends {
|
|
1996
359
|
readonly transaction: (...args: any[]) => any;
|
|
1997
360
|
} ? Parameters<Parameters<D["transaction"]>[0]>[0] : never>, TxShape>;
|
|
1998
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
361
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/OAuth").OAuthConnectedRevocations>>;
|
|
1999
362
|
};
|
|
2000
363
|
export declare const makePasskeyCredentialServices: <S extends AnySQLiteTable<{
|
|
2001
364
|
dialect: "sqlite";
|
|
@@ -2003,225 +366,252 @@ export declare const makePasskeyCredentialServices: <S extends AnySQLiteTable<{
|
|
|
2003
366
|
dialect: "sqlite";
|
|
2004
367
|
}>, F extends AnySQLiteTable<{
|
|
2005
368
|
dialect: "sqlite";
|
|
2006
|
-
}>,
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
}
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
}
|
|
2017
|
-
|
|
2018
|
-
}
|
|
2019
|
-
dialect: "sqlite";
|
|
2020
|
-
}>, M extends AnySQLiteTable<{
|
|
2021
|
-
dialect: "sqlite";
|
|
2022
|
-
}>, Flow extends AnySQLiteTable<{
|
|
2023
|
-
dialect: "sqlite";
|
|
2024
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2025
|
-
dialect: "sqlite";
|
|
2026
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2027
|
-
dialect: "sqlite";
|
|
2028
|
-
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, O, H, N>, M, Flow, Admission, Charge, N>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyPersistenceServices, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, makePasskeyEnrollmentContextServices: <S extends AnySQLiteTable<{
|
|
369
|
+
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyCredentialMapping<S, C, F, N>, RSetup>) => Effect.Effect<{
|
|
370
|
+
passkeyCredentials: {
|
|
371
|
+
readonly listForSubject: (input: {
|
|
372
|
+
readonly moduleId: string;
|
|
373
|
+
readonly rpId: string;
|
|
374
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
375
|
+
}) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyEnrollmentSnapshot | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
376
|
+
readonly lookup: (input: {
|
|
377
|
+
readonly rpId: string;
|
|
378
|
+
readonly protocolCredentialId: import("@yielded/auth/Passkey").PasskeyProtocolCredentialId;
|
|
379
|
+
}) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyCredential | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
380
|
+
};
|
|
381
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | Exclude<RSetup, NativeDatabase>>, makePasskeyPersistenceServices: <S extends AnySQLiteTable<{
|
|
2029
382
|
dialect: "sqlite";
|
|
2030
383
|
}>, C extends AnySQLiteTable<{
|
|
2031
384
|
dialect: "sqlite";
|
|
2032
385
|
}>, F extends AnySQLiteTable<{
|
|
2033
386
|
dialect: "sqlite";
|
|
2034
|
-
}>, O extends AnySQLiteTable<{
|
|
2035
|
-
dialect: "sqlite";
|
|
2036
|
-
}>, H extends AnySQLiteTable<{
|
|
2037
|
-
dialect: "sqlite";
|
|
2038
|
-
}>, M extends AnySQLiteTable<{
|
|
2039
|
-
dialect: "sqlite";
|
|
2040
|
-
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyEnrollmentContextMapping<PasskeyCredentialMapping<S, C, F, O, H, N>, M, N>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyEnrollmentContextServices, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, import("effect/Crypto").Crypto | Database | Exclude<RSetup, NativeDatabase>>, makePasskeyRegistrationCeremonyServices: <M extends AnySQLiteTable<{
|
|
2041
|
-
dialect: "sqlite";
|
|
2042
387
|
}>, Flow extends AnySQLiteTable<{
|
|
2043
388
|
dialect: "sqlite";
|
|
2044
|
-
}>,
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
}
|
|
2049
|
-
|
|
2050
|
-
|
|
389
|
+
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N>, RSetup>) => Effect.Effect<{
|
|
390
|
+
passkeyPersistence: {
|
|
391
|
+
readonly issue: <A>(input: {
|
|
392
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
393
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
394
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
395
|
+
readonly consume: <A>(input: {
|
|
396
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
397
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
398
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
399
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
400
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
401
|
+
readonly cleanup: <A>(input: {
|
|
402
|
+
readonly moduleId: string;
|
|
403
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
404
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
405
|
+
};
|
|
406
|
+
}, 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 AnySQLiteTable<{
|
|
2051
407
|
dialect: "sqlite";
|
|
2052
|
-
}>, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<
|
|
408
|
+
}>, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow>, RSetup>) => Effect.Effect<{
|
|
409
|
+
passkeyPersistence: {
|
|
410
|
+
readonly issue: <A>(input: {
|
|
411
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
412
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
413
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
414
|
+
readonly consume: <A>(input: {
|
|
415
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
416
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
417
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
418
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
419
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
420
|
+
readonly cleanup: <A>(input: {
|
|
421
|
+
readonly moduleId: string;
|
|
422
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
423
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
424
|
+
};
|
|
425
|
+
capabilities: {
|
|
426
|
+
purposes: readonly ["registration"];
|
|
427
|
+
issue: "registration-authority";
|
|
428
|
+
assertionConsumption: false;
|
|
429
|
+
};
|
|
430
|
+
}, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePasskeyPersistence: {
|
|
2053
431
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2054
432
|
dialect: "sqlite";
|
|
2055
433
|
}>, C extends AnySQLiteTable<{
|
|
2056
434
|
dialect: "sqlite";
|
|
2057
435
|
}>, F extends AnySQLiteTable<{
|
|
2058
436
|
dialect: "sqlite";
|
|
2059
|
-
}>, O extends AnySQLiteTable<{
|
|
2060
|
-
dialect: "sqlite";
|
|
2061
|
-
}>, H extends AnySQLiteTable<{
|
|
2062
|
-
dialect: "sqlite";
|
|
2063
|
-
}>, M extends AnySQLiteTable<{
|
|
2064
|
-
dialect: "sqlite";
|
|
2065
437
|
}>, Flow extends AnySQLiteTable<{
|
|
2066
438
|
dialect: "sqlite";
|
|
2067
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2068
|
-
dialect: "sqlite";
|
|
2069
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2070
|
-
dialect: "sqlite";
|
|
2071
439
|
}>, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2072
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F,
|
|
440
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N>, RSetup>;
|
|
2073
441
|
readonly transaction?: never;
|
|
2074
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
442
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2075
443
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2076
444
|
dialect: "sqlite";
|
|
2077
445
|
}>, C extends AnySQLiteTable<{
|
|
2078
446
|
dialect: "sqlite";
|
|
2079
447
|
}>, F extends AnySQLiteTable<{
|
|
2080
448
|
dialect: "sqlite";
|
|
2081
|
-
}>, O extends AnySQLiteTable<{
|
|
2082
|
-
dialect: "sqlite";
|
|
2083
|
-
}>, H extends AnySQLiteTable<{
|
|
2084
|
-
dialect: "sqlite";
|
|
2085
|
-
}>, M extends AnySQLiteTable<{
|
|
2086
|
-
dialect: "sqlite";
|
|
2087
449
|
}>, Flow extends AnySQLiteTable<{
|
|
2088
450
|
dialect: "sqlite";
|
|
2089
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2090
|
-
dialect: "sqlite";
|
|
2091
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2092
|
-
dialect: "sqlite";
|
|
2093
451
|
}>, N, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2094
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F,
|
|
452
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyPersistenceMapping<PasskeyCredentialMapping<S, C, F, N>, Flow, N>, RSetup>;
|
|
2095
453
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
2096
454
|
readonly transaction: (...args: any[]) => any;
|
|
2097
455
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2098
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
456
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2099
457
|
}, coordinatePasskeyRegistrationCeremony: {
|
|
2100
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
2101
|
-
dialect: "sqlite";
|
|
2102
|
-
}>, Flow extends AnySQLiteTable<{
|
|
2103
|
-
dialect: "sqlite";
|
|
2104
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2105
|
-
dialect: "sqlite";
|
|
2106
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2107
|
-
dialect: "sqlite";
|
|
2108
|
-
}>, Intent extends AnySQLiteTable<{
|
|
2109
|
-
dialect: "sqlite";
|
|
2110
|
-
}>, H extends AnySQLiteTable<{
|
|
458
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Flow extends AnySQLiteTable<{
|
|
2111
459
|
dialect: "sqlite";
|
|
2112
460
|
}>, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2113
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<
|
|
461
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow>, RSetup>;
|
|
2114
462
|
readonly transaction?: never;
|
|
2115
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
2116
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
2117
|
-
dialect: "sqlite";
|
|
2118
|
-
}>, Flow extends AnySQLiteTable<{
|
|
2119
|
-
dialect: "sqlite";
|
|
2120
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2121
|
-
dialect: "sqlite";
|
|
2122
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2123
|
-
dialect: "sqlite";
|
|
2124
|
-
}>, Intent extends AnySQLiteTable<{
|
|
2125
|
-
dialect: "sqlite";
|
|
2126
|
-
}>, H extends AnySQLiteTable<{
|
|
463
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
464
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Flow extends AnySQLiteTable<{
|
|
2127
465
|
dialect: "sqlite";
|
|
2128
466
|
}>, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2129
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<
|
|
467
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<Flow>, RSetup>;
|
|
2130
468
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
2131
469
|
readonly transaction: (...args: any[]) => any;
|
|
2132
470
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2133
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
471
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2134
472
|
}, makePasskeyManagementServices: <S extends AnySQLiteTable<{
|
|
2135
473
|
dialect: "sqlite";
|
|
2136
474
|
}>, C extends AnySQLiteTable<{
|
|
2137
475
|
dialect: "sqlite";
|
|
2138
476
|
}>, F extends AnySQLiteTable<{
|
|
2139
477
|
dialect: "sqlite";
|
|
2140
|
-
}>, O extends AnySQLiteTable<{
|
|
2141
|
-
dialect: "sqlite";
|
|
2142
|
-
}>, H extends AnySQLiteTable<{
|
|
2143
|
-
dialect: "sqlite";
|
|
2144
|
-
}>, M extends AnySQLiteTable<{
|
|
2145
|
-
dialect: "sqlite";
|
|
2146
478
|
}>, Flow extends AnySQLiteTable<{
|
|
2147
479
|
dialect: "sqlite";
|
|
2148
|
-
}>,
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
480
|
+
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N>, RSetup>) => Effect.Effect<{
|
|
481
|
+
passkeyManagementPersistence: {
|
|
482
|
+
readonly list: (input: {
|
|
483
|
+
readonly moduleId: string;
|
|
484
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
485
|
+
readonly cursor?: string;
|
|
486
|
+
readonly limit: number;
|
|
487
|
+
}) => Effect.Effect<{
|
|
488
|
+
readonly credentials: ReadonlyArray<import("@yielded/auth/Passkey").PasskeyCredentialSummary>;
|
|
489
|
+
readonly cursor?: string;
|
|
490
|
+
}, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
491
|
+
readonly completeEnrollment: <A>(input: {
|
|
492
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
493
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
494
|
+
readonly verified: import("@yielded/auth/Passkey").PasskeyRegistrationVerified;
|
|
495
|
+
readonly management: import("@yielded/auth/Passkey").PasskeyManagementPolicy;
|
|
496
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
497
|
+
readonly _tag: "Enrolled";
|
|
498
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredentialSummary;
|
|
499
|
+
} | {
|
|
500
|
+
readonly _tag: "Rejected";
|
|
501
|
+
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
502
|
+
readonly inspectRemove: (input: {
|
|
503
|
+
readonly moduleId: string;
|
|
504
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
505
|
+
readonly credentialId: string;
|
|
506
|
+
}) => Effect.Effect<{
|
|
507
|
+
readonly _tag: "Target";
|
|
508
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
509
|
+
} | {
|
|
510
|
+
readonly _tag: "Rejected";
|
|
511
|
+
}, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
512
|
+
readonly remove: <A>(input: {
|
|
513
|
+
readonly moduleId: string;
|
|
514
|
+
readonly commandId: string;
|
|
515
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
516
|
+
readonly authorization: import("@yielded/auth/Passkey").PasskeyActionAuthorization;
|
|
517
|
+
readonly management: import("@yielded/auth/Passkey").PasskeyManagementPolicy;
|
|
518
|
+
readonly invalidation: import("@yielded/auth/Sessions").SessionInvalidationWindow;
|
|
519
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
520
|
+
readonly _tag: "Removed";
|
|
521
|
+
readonly result: {
|
|
522
|
+
readonly credentialId: string;
|
|
523
|
+
readonly invalidation: {
|
|
524
|
+
readonly trigger: "all-session-revocation" | "credential-change" | "factor-reset" | "identifier-change" | "password-reset" | "subject-delete" | "subject-disable";
|
|
525
|
+
readonly existingSessions: "cache-expiry" | "immediate" | "original-absolute-expiry";
|
|
526
|
+
readonly maximumExposureMillis: number;
|
|
527
|
+
readonly oldAuthenticationEvidence: "rejected";
|
|
528
|
+
};
|
|
529
|
+
};
|
|
530
|
+
} | {
|
|
531
|
+
readonly _tag: "Rejected" | "LastSignInMethod";
|
|
532
|
+
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
533
|
+
readonly rename: <A>(input: {
|
|
534
|
+
readonly moduleId: string;
|
|
535
|
+
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
536
|
+
readonly commandId: string;
|
|
537
|
+
readonly credentialId: string;
|
|
538
|
+
readonly name: string;
|
|
539
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<{
|
|
540
|
+
readonly _tag: "Renamed";
|
|
541
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredentialSummary;
|
|
542
|
+
} | {
|
|
543
|
+
readonly _tag: "Rejected";
|
|
544
|
+
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
545
|
+
};
|
|
546
|
+
passkeyPersistence: {
|
|
547
|
+
readonly issue: <A>(input: {
|
|
548
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
549
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
550
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
551
|
+
readonly consume: <A>(input: {
|
|
552
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
553
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
554
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
555
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
556
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
557
|
+
readonly cleanup: <A>(input: {
|
|
558
|
+
readonly moduleId: string;
|
|
559
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
560
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
561
|
+
};
|
|
562
|
+
}, 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 AnySQLiteTable<{
|
|
2155
563
|
dialect: "sqlite";
|
|
2156
564
|
}>, C extends AnySQLiteTable<{
|
|
2157
565
|
dialect: "sqlite";
|
|
2158
566
|
}>, F extends AnySQLiteTable<{
|
|
2159
567
|
dialect: "sqlite";
|
|
2160
|
-
}>, O extends AnySQLiteTable<{
|
|
2161
|
-
dialect: "sqlite";
|
|
2162
|
-
}>, H extends AnySQLiteTable<{
|
|
2163
|
-
dialect: "sqlite";
|
|
2164
|
-
}>, M extends AnySQLiteTable<{
|
|
2165
|
-
dialect: "sqlite";
|
|
2166
568
|
}>, Flow extends AnySQLiteTable<{
|
|
2167
569
|
dialect: "sqlite";
|
|
2168
|
-
}>,
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
570
|
+
}>, N, Value, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value>, RSetup>) => Effect.Effect<{
|
|
571
|
+
passkeyRegistrationAuthority: import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>;
|
|
572
|
+
passkeyPersistence: {
|
|
573
|
+
readonly issue: <A>(input: {
|
|
574
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
575
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyIssueDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
576
|
+
readonly context: (input: import("@yielded/auth/Passkey").PasskeyAccess) => Effect.Effect<import("@yielded/auth/Passkey").PasskeyCeremony | undefined, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
577
|
+
readonly consume: <A>(input: {
|
|
578
|
+
readonly access: import("@yielded/auth/Passkey").PasskeyAccess;
|
|
579
|
+
readonly ceremony: import("@yielded/auth/Passkey").PasskeyCeremony;
|
|
580
|
+
readonly credential: import("@yielded/auth/Passkey").PasskeyCredential;
|
|
581
|
+
readonly assertion: import("@yielded/auth/Passkey").PasskeyAssertionVerified;
|
|
582
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Passkey").PasskeyConsumeDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
583
|
+
readonly cleanup: <A>(input: {
|
|
584
|
+
readonly moduleId: string;
|
|
585
|
+
readonly limit: import("@yielded/auth/Persistence").CleanupLimit;
|
|
586
|
+
}, prepare: import("@yielded/auth/Passkey").PreparePasskeyCommit<import("@yielded/auth/Persistence").CleanupResult, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Passkey").PasskeyUnavailable>;
|
|
587
|
+
};
|
|
588
|
+
}, 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: {
|
|
2175
589
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2176
590
|
dialect: "sqlite";
|
|
2177
591
|
}>, C extends AnySQLiteTable<{
|
|
2178
592
|
dialect: "sqlite";
|
|
2179
593
|
}>, F extends AnySQLiteTable<{
|
|
2180
594
|
dialect: "sqlite";
|
|
2181
|
-
}>, O extends AnySQLiteTable<{
|
|
2182
|
-
dialect: "sqlite";
|
|
2183
|
-
}>, H extends AnySQLiteTable<{
|
|
2184
|
-
dialect: "sqlite";
|
|
2185
|
-
}>, M extends AnySQLiteTable<{
|
|
2186
|
-
dialect: "sqlite";
|
|
2187
595
|
}>, Flow extends AnySQLiteTable<{
|
|
2188
596
|
dialect: "sqlite";
|
|
2189
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2190
|
-
dialect: "sqlite";
|
|
2191
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2192
|
-
dialect: "sqlite";
|
|
2193
|
-
}>, Command extends AnySQLiteTable<{
|
|
2194
|
-
dialect: "sqlite";
|
|
2195
597
|
}>, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2196
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F,
|
|
598
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N>, RSetup>;
|
|
2197
599
|
readonly transaction?: never;
|
|
2198
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
600
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Passkey").PasskeyManagementPersistence | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2199
601
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2200
602
|
dialect: "sqlite";
|
|
2201
603
|
}>, C extends AnySQLiteTable<{
|
|
2202
604
|
dialect: "sqlite";
|
|
2203
605
|
}>, F extends AnySQLiteTable<{
|
|
2204
606
|
dialect: "sqlite";
|
|
2205
|
-
}>, O extends AnySQLiteTable<{
|
|
2206
|
-
dialect: "sqlite";
|
|
2207
|
-
}>, H extends AnySQLiteTable<{
|
|
2208
|
-
dialect: "sqlite";
|
|
2209
|
-
}>, M extends AnySQLiteTable<{
|
|
2210
|
-
dialect: "sqlite";
|
|
2211
607
|
}>, Flow extends AnySQLiteTable<{
|
|
2212
608
|
dialect: "sqlite";
|
|
2213
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2214
|
-
dialect: "sqlite";
|
|
2215
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2216
|
-
dialect: "sqlite";
|
|
2217
|
-
}>, Command extends AnySQLiteTable<{
|
|
2218
|
-
dialect: "sqlite";
|
|
2219
609
|
}>, N, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2220
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F,
|
|
610
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, Flow, N>, RSetup>;
|
|
2221
611
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
2222
612
|
readonly transaction: (...args: any[]) => any;
|
|
2223
613
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2224
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
614
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Passkey").PasskeyManagementPersistence | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2225
615
|
}, coordinatePasskeyRegistration: {
|
|
2226
616
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2227
617
|
dialect: "sqlite";
|
|
@@ -2229,119 +619,123 @@ export declare const makePasskeyCredentialServices: <S extends AnySQLiteTable<{
|
|
|
2229
619
|
dialect: "sqlite";
|
|
2230
620
|
}>, F extends AnySQLiteTable<{
|
|
2231
621
|
dialect: "sqlite";
|
|
2232
|
-
}>, O extends AnySQLiteTable<{
|
|
2233
|
-
dialect: "sqlite";
|
|
2234
|
-
}>, H extends AnySQLiteTable<{
|
|
2235
|
-
dialect: "sqlite";
|
|
2236
|
-
}>, M extends AnySQLiteTable<{
|
|
2237
|
-
dialect: "sqlite";
|
|
2238
622
|
}>, Flow extends AnySQLiteTable<{
|
|
2239
623
|
dialect: "sqlite";
|
|
2240
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2241
|
-
dialect: "sqlite";
|
|
2242
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2243
|
-
dialect: "sqlite";
|
|
2244
|
-
}>, Intent extends AnySQLiteTable<{
|
|
2245
|
-
dialect: "sqlite";
|
|
2246
624
|
}>, N, Value, A, E, R, AuthorityId, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2247
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F,
|
|
625
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value>, RSetup>;
|
|
2248
626
|
readonly authority: Context.Key<AuthorityId, import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>>;
|
|
2249
627
|
readonly transaction?: never;
|
|
2250
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
628
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, AuthorityId | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2251
629
|
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2252
630
|
dialect: "sqlite";
|
|
2253
631
|
}>, C extends AnySQLiteTable<{
|
|
2254
632
|
dialect: "sqlite";
|
|
2255
633
|
}>, F extends AnySQLiteTable<{
|
|
2256
634
|
dialect: "sqlite";
|
|
2257
|
-
}>, O extends AnySQLiteTable<{
|
|
2258
|
-
dialect: "sqlite";
|
|
2259
|
-
}>, H extends AnySQLiteTable<{
|
|
2260
|
-
dialect: "sqlite";
|
|
2261
|
-
}>, M extends AnySQLiteTable<{
|
|
2262
|
-
dialect: "sqlite";
|
|
2263
635
|
}>, Flow extends AnySQLiteTable<{
|
|
2264
636
|
dialect: "sqlite";
|
|
2265
|
-
}>, Admission extends AnySQLiteTable<{
|
|
2266
|
-
dialect: "sqlite";
|
|
2267
|
-
}>, Charge extends AnySQLiteTable<{
|
|
2268
|
-
dialect: "sqlite";
|
|
2269
|
-
}>, Intent extends AnySQLiteTable<{
|
|
2270
|
-
dialect: "sqlite";
|
|
2271
637
|
}>, N, Value, A, E, R, AuthorityId, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2272
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F,
|
|
638
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, Flow, N, Value>, RSetup>;
|
|
2273
639
|
readonly authority: Context.Key<AuthorityId, import("@yielded/auth-persistence/Adapter").PasskeyRegistrationWriter<Value>>;
|
|
2274
640
|
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
2275
641
|
readonly transaction: (...args: any[]) => any;
|
|
2276
642
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2277
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError |
|
|
643
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, AuthorityId | TxId | import("@yielded/auth/Passkey").PasskeyPersistence>>;
|
|
2278
644
|
};
|
|
2279
|
-
export declare const
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
}>, N, RSetup = never>(mapping: TotpMappingSource<TotpMapping<S, F, C, N>, RSetup>) => Effect.Effect<TotpPersistenceServices, import("@yielded/auth-persistence/Adapter").PersistenceMappingError | import("@yielded/auth/Totp").TotpConfigurationError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinateTotpPersistence: {
|
|
2286
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2287
|
-
dialect: "sqlite";
|
|
2288
|
-
}>, F extends AnySQLiteTable<{
|
|
2289
|
-
dialect: "sqlite";
|
|
2290
|
-
}>, C extends AnySQLiteTable<{
|
|
2291
|
-
dialect: "sqlite";
|
|
2292
|
-
}>, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2293
|
-
readonly mapping: TotpMappingSource<TotpMapping<S, F, C, N>, RSetup>;
|
|
645
|
+
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>) => Effect.Effect<{
|
|
646
|
+
readonly phonePersistence: import("@yielded/auth/PhoneOtp").PhonePersistence["Service"];
|
|
647
|
+
readonly phoneSignInTargets: import("@yielded/auth/PhoneOtp").PhoneSignInTargets["Service"];
|
|
648
|
+
}, import("@yielded/auth/PhoneOtp").PhoneConfigurationError | import("@yielded/auth/PhoneOtp").PhoneOtpUnavailable, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePhonePersistence: {
|
|
649
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
650
|
+
readonly mapping: PhoneMapping<Subject, Identifier, Credential, Proof, NativeId>;
|
|
2294
651
|
readonly transaction?: never;
|
|
2295
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A,
|
|
2296
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>,
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
}>, C extends AnySQLiteTable<{
|
|
2301
|
-
dialect: "sqlite";
|
|
2302
|
-
}>, N, A, E, R, TxId, TxShape, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2303
|
-
readonly mapping: TotpMappingSource<TotpMapping<S, F, C, N>, RSetup>;
|
|
2304
|
-
readonly transaction: SuppliedService<TxId, NoInfer<Database extends {
|
|
2305
|
-
readonly transaction: (...args: any[]) => any;
|
|
2306
|
-
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2307
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DatabaseError | TotpCoordinatorError<E>, DatabaseRequirements | RSetup | import("effect/Crypto").Crypto | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Totp").TotpPersistence>>;
|
|
652
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
653
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<Database, DE, DR>, options: {
|
|
654
|
+
readonly mapping: PhoneMapping<Subject, Identifier, Credential, Proof, NativeId>;
|
|
655
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<Database>>, TxShape>;
|
|
656
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
2308
657
|
};
|
|
2309
|
-
export declare const
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
dialect: "sqlite";
|
|
2313
|
-
}>, F extends AnySQLiteTable<{
|
|
2314
|
-
dialect: "sqlite";
|
|
2315
|
-
}>, C extends AnySQLiteTable<{
|
|
2316
|
-
dialect: "sqlite";
|
|
2317
|
-
}>, N, RSetup = never>(mapping: PhoneMappingSource<PhoneMapping<S, I, C, F, N>, RSetup>) => Effect.Effect<PhonePersistenceServices, import("@yielded/auth-persistence/Adapter").PersistenceMappingError | import("@yielded/auth/PhoneOtp").PhoneConfigurationError, import("effect/Crypto").Crypto | Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePhonePersistence: {
|
|
2318
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2319
|
-
dialect: "sqlite";
|
|
2320
|
-
}>, I extends AnySQLiteTable<{
|
|
2321
|
-
dialect: "sqlite";
|
|
2322
|
-
}>, F extends AnySQLiteTable<{
|
|
2323
|
-
dialect: "sqlite";
|
|
2324
|
-
}>, C extends AnySQLiteTable<{
|
|
2325
|
-
dialect: "sqlite";
|
|
2326
|
-
}>, N, A, E, R, RSetup = never, DatabaseError = never, DatabaseRequirements = never>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
2327
|
-
readonly mapping: PhoneMappingSource<PhoneMapping<S, I, C, F, N>, RSetup>;
|
|
658
|
+
export declare const coordinateAuthenticationAuthority: {
|
|
659
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
660
|
+
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, P, N>;
|
|
2328
661
|
readonly transaction?: never;
|
|
2329
|
-
}, body: Effect.Effect<A, E, R>): Effect.Effect<A,
|
|
2330
|
-
<
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
662
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
663
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
664
|
+
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, P, N>;
|
|
665
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
666
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Sessions").AuthenticationAuthority>>;
|
|
667
|
+
}, coordinatePendingAuthentication: {
|
|
668
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
669
|
+
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, N>;
|
|
670
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
671
|
+
readonly transaction?: never;
|
|
672
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
673
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
674
|
+
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, N>;
|
|
675
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
676
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
677
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
678
|
+
}, coordinateSignedSessionValidity: {
|
|
679
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Id, S extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR>(acquire: Effect.Effect<DB, DE, DR>, options: {
|
|
680
|
+
readonly mapping: SignedSessionValidityMapping<S, T, N, NS>;
|
|
681
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
682
|
+
readonly transaction?: never;
|
|
683
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
684
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, Id, S extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS, A, E, R, DE, DR, TxId, TxShape>(acquire: Effect.Effect<DB, DE, DR>, options: {
|
|
685
|
+
readonly mapping: SignedSessionValidityMapping<S, T, N, NS>;
|
|
686
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
687
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
688
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
689
|
+
}, coordinateStatefulSessions: {
|
|
690
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
691
|
+
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, P, N, NS>;
|
|
692
|
+
readonly persistence: SuppliedService<Id, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
693
|
+
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
694
|
+
readonly transaction?: never;
|
|
695
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | RepositoryId>>;
|
|
696
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
697
|
+
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, P, N, NS>;
|
|
698
|
+
readonly persistence: SuppliedService<Id, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
699
|
+
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
700
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
701
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | RepositoryId | TxId>>;
|
|
702
|
+
}, 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>) => Effect.Effect<{
|
|
703
|
+
readonly authenticationAuthority: import("@yielded/auth/Sessions").AuthenticationAuthority["Service"];
|
|
704
|
+
}, 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>) => Effect.Effect<{
|
|
705
|
+
readonly pendingAuthentication: import("@yielded/auth/Sessions").PendingAuthentication<Claims>;
|
|
706
|
+
}, 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>) => Effect.Effect<{
|
|
707
|
+
readonly signedSessionValidity: import("@yielded/auth/Sessions").SignedSessionValidity;
|
|
708
|
+
}, 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>) => Effect.Effect<{
|
|
709
|
+
readonly statefulSessionPersistence: import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>;
|
|
710
|
+
readonly sessionRepository: import("@yielded/auth/Sessions").SessionRepository;
|
|
711
|
+
}, 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: Context.Service<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>) => Effect.Effect<{
|
|
712
|
+
sessionStepUpPersistence: import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>;
|
|
713
|
+
}, import("@yielded/auth/Sessions").SessionUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateSessionStepUp: {
|
|
714
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
715
|
+
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, P, Session, T, N, NS>;
|
|
716
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
717
|
+
readonly transaction?: never;
|
|
718
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id>>;
|
|
719
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
720
|
+
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, P, Session, T, N, NS>;
|
|
721
|
+
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
722
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
723
|
+
}, body: Effect.Effect<A, E, R>): Effect.Effect<A, DE | E | import("@yielded/auth/Sessions").SessionUnavailable, DR | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, Id | TxId>>;
|
|
724
|
+
}, makeSessionCleanupServices: <P extends import("drizzle-orm").Table, T extends import("drizzle-orm").Table, N, NS>(mapping: SessionCleanupMapping<P, T, N, NS>) => Effect.Effect<{
|
|
725
|
+
readonly sessionCleanup: import("@yielded/auth/Sessions").SessionCleanup;
|
|
726
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
727
|
+
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>) => Effect.Effect<{
|
|
728
|
+
readonly totpPersistence: import("@yielded/auth/Totp").TotpPersistence["Service"];
|
|
729
|
+
}, 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: {
|
|
730
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
731
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").TotpMappingSource<TotpMapping<S, F, C, N, P>, RS>;
|
|
732
|
+
readonly transaction?: never;
|
|
733
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
734
|
+
<DB extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, 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: Effect.Effect<DB, DE, DR>, options: {
|
|
735
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").TotpMappingSource<TotpMapping<S, F, C, N, P>, RS>;
|
|
736
|
+
readonly transaction: SuppliedService<TxId, NoInfer<NativeDriverTransaction<DB>>, TxShape>;
|
|
737
|
+
}, body: Effect.Effect<A, E, R>): 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>>;
|
|
2344
738
|
};
|
|
2345
739
|
//#endregion
|
|
2346
|
-
export { type DatabaseValue, OAuthProxyPersistence, type Transaction, makeDatabase
|
|
740
|
+
export { type DatabaseValue, OAuthProxyPersistence, type Transaction, makeDatabase };
|
|
2347
741
|
//# sourceMappingURL=SqliteDo.d.mts.map
|