@yielded/auth-persistence-drizzle 0.1.0-beta.0 → 0.1.0-beta.12
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 +6 -1
- package/dist/D1.d.mts +155 -40
- package/dist/D1.mjs +10 -6
- package/dist/D1.mjs.map +1 -1
- package/dist/Libsql.d.mts +251 -129
- package/dist/Libsql.mjs +20 -21
- package/dist/Libsql.mjs.map +1 -1
- package/dist/Mysql2.d.mts +208 -56
- package/dist/Mysql2.mjs +13 -8
- package/dist/Mysql2.mjs.map +1 -1
- package/dist/Pglite.d.mts +209 -57
- package/dist/Pglite.mjs +13 -9
- package/dist/Pglite.mjs.map +1 -1
- package/dist/Postgres.d.mts +207 -55
- package/dist/Postgres.mjs +13 -9
- package/dist/Postgres.mjs.map +1 -1
- package/dist/SqliteBun.d.mts +249 -126
- package/dist/SqliteBun.mjs +20 -18
- package/dist/SqliteBun.mjs.map +1 -1
- package/dist/SqliteDo.d.mts +248 -158
- package/dist/SqliteDo.mjs +26 -44
- package/dist/SqliteDo.mjs.map +1 -1
- package/dist/SqliteNode.d.mts +247 -124
- package/dist/SqliteNode.mjs +20 -18
- package/dist/SqliteNode.mjs.map +1 -1
- package/dist/SqliteWasm.d.mts +251 -128
- package/dist/SqliteWasm.mjs +20 -18
- package/dist/SqliteWasm.mjs.map +1 -1
- package/dist/drizzle/D1BatchStatements.d.mts +1 -1
- package/dist/drizzle/D1BatchStatements.mjs.map +1 -1
- package/dist/drizzle/d1-database.d.mts +11 -0
- package/dist/drizzle/d1-database.mjs +8 -0
- package/dist/drizzle/d1-database.mjs.map +1 -0
- package/dist/drizzle/d1-emails.d.mts +8 -7
- package/dist/drizzle/d1-emails.mjs +7 -4
- package/dist/drizzle/d1-emails.mjs.map +1 -1
- package/dist/drizzle/d1-generated-statement.mjs.map +1 -1
- package/dist/drizzle/d1-identity.mjs +12 -9
- package/dist/drizzle/d1-identity.mjs.map +1 -1
- package/dist/drizzle/d1-oauth.d.mts +41 -10
- package/dist/drizzle/d1-oauth.mjs +8 -5
- package/dist/drizzle/d1-oauth.mjs.map +1 -1
- package/dist/drizzle/d1-passkey.d.mts +3 -14
- package/dist/drizzle/d1-passkey.mjs +2 -1
- package/dist/drizzle/d1-passkey.mjs.map +1 -1
- package/dist/drizzle/d1-password-prepared.d.mts +4 -3
- package/dist/drizzle/d1-password-prepared.mjs +3 -1
- package/dist/drizzle/d1-password-prepared.mjs.map +1 -1
- package/dist/drizzle/d1-passwords.d.mts +7 -6
- package/dist/drizzle/d1-passwords.mjs +5 -2
- package/dist/drizzle/d1-passwords.mjs.map +1 -1
- package/dist/drizzle/d1-phone.d.mts +3 -4
- package/dist/drizzle/d1-phone.mjs +2 -1
- package/dist/drizzle/d1-phone.mjs.map +1 -1
- package/dist/drizzle/d1-planning.d.mts +1 -1
- package/dist/drizzle/d1-proofs.d.mts +5 -4
- package/dist/drizzle/d1-proofs.mjs +3 -1
- package/dist/drizzle/d1-proofs.mjs.map +1 -1
- package/dist/drizzle/d1-sessions.d.mts +14 -13
- package/dist/drizzle/d1-sessions.mjs +15 -9
- package/dist/drizzle/d1-sessions.mjs.map +1 -1
- package/dist/drizzle/d1-totp.d.mts +3 -4
- package/dist/drizzle/d1-totp.mjs +2 -1
- package/dist/drizzle/d1-totp.mjs.map +1 -1
- package/dist/drizzle/email-registration.d.mts +1 -1
- package/dist/drizzle/email-registration.mjs +2 -1
- package/dist/drizzle/email-registration.mjs.map +1 -1
- package/dist/drizzle/email-target.d.mts +8 -7
- package/dist/drizzle/email-target.mjs +10 -10
- package/dist/drizzle/email-target.mjs.map +1 -1
- package/dist/drizzle/model.d.mts +2 -126
- package/dist/drizzle/model.mjs +2 -21
- package/dist/drizzle/model.mjs.map +1 -1
- package/dist/drizzle/mysql-database.d.mts +8 -0
- package/dist/drizzle/mysql-database.mjs +8 -0
- package/dist/drizzle/mysql-database.mjs.map +1 -0
- package/dist/drizzle/mysql-emails.d.mts +8 -7
- package/dist/drizzle/mysql-emails.mjs +12 -8
- package/dist/drizzle/mysql-emails.mjs.map +1 -1
- package/dist/drizzle/mysql-identity.mjs +12 -9
- package/dist/drizzle/mysql-identity.mjs.map +1 -1
- package/dist/drizzle/mysql-password-prepared.d.mts +4 -3
- package/dist/drizzle/mysql-password-prepared.mjs +6 -2
- package/dist/drizzle/mysql-password-prepared.mjs.map +1 -1
- package/dist/drizzle/mysql-passwords.d.mts +7 -5
- package/dist/drizzle/mysql-passwords.mjs +11 -7
- package/dist/drizzle/mysql-passwords.mjs.map +1 -1
- package/dist/drizzle/mysql-proofs.d.mts +4 -3
- package/dist/drizzle/mysql-proofs.mjs +8 -4
- package/dist/drizzle/mysql-proofs.mjs.map +1 -1
- package/dist/drizzle/mysql-sessions.d.mts +12 -11
- package/dist/drizzle/mysql-sessions.mjs +16 -12
- package/dist/drizzle/mysql-sessions.mjs.map +1 -1
- package/dist/drizzle/native-database.mjs +10 -0
- package/dist/drizzle/native-database.mjs.map +1 -0
- package/dist/drizzle/oauth-accounts.mjs +1 -1
- package/dist/drizzle/oauth-connected-access.mjs +14 -12
- package/dist/drizzle/oauth-connected-access.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-custody.mjs +2 -2
- package/dist/drizzle/oauth-connected-drivers.mjs +11 -6
- package/dist/drizzle/oauth-connected-drivers.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-flow.mjs +2 -2
- package/dist/drizzle/oauth-connected-input.mjs +14 -1
- package/dist/drizzle/oauth-connected-input.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-maintenance.mjs +1 -1
- package/dist/drizzle/oauth-connected-management.mjs +2 -2
- package/dist/drizzle/oauth-connected-model.d.mts +17 -3
- package/dist/drizzle/oauth-connected-model.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-settlement.mjs +51 -41
- package/dist/drizzle/oauth-connected-settlement.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-sign-in.mjs +263 -0
- package/dist/drizzle/oauth-connected-sign-in.mjs.map +1 -0
- package/dist/drizzle/oauth-connected-state.d.mts +110 -2
- package/dist/drizzle/oauth-connected-state.mjs +9 -4
- package/dist/drizzle/oauth-connected-state.mjs.map +1 -1
- package/dist/drizzle/oauth-connected-target.d.mts +142 -15
- package/dist/drizzle/oauth-connected-target.mjs +9 -6
- package/dist/drizzle/oauth-connected-target.mjs.map +1 -1
- package/dist/drizzle/oauth-drivers.mjs +9 -7
- package/dist/drizzle/oauth-drivers.mjs.map +1 -1
- package/dist/drizzle/oauth-flow.d.mts +1 -1
- package/dist/drizzle/oauth-flow.mjs +1 -1
- package/dist/drizzle/oauth-input.mjs +1 -1
- package/dist/drizzle/oauth-model.d.mts +1 -1
- package/dist/drizzle/oauth-owner.d.mts +1 -1
- package/dist/drizzle/oauth-registration.d.mts +2 -2
- package/dist/drizzle/oauth-registration.mjs +1 -1
- package/dist/drizzle/oauth-state.mjs +5 -4
- package/dist/drizzle/oauth-state.mjs.map +1 -1
- package/dist/drizzle/oauth-target.d.mts +14 -13
- package/dist/drizzle/oauth-target.mjs +14 -13
- package/dist/drizzle/oauth-target.mjs.map +1 -1
- package/dist/drizzle/passkey-drivers.mjs +8 -6
- package/dist/drizzle/passkey-drivers.mjs.map +1 -1
- package/dist/drizzle/passkey-write-drivers.mjs +5 -3
- package/dist/drizzle/passkey-write-drivers.mjs.map +1 -1
- package/dist/drizzle/passkey-write-target.d.mts +1 -1
- package/dist/drizzle/password-prepared-sql.mjs +2 -1
- package/dist/drizzle/password-prepared-sql.mjs.map +1 -1
- package/dist/drizzle/password-prepared-state.mjs +1 -1
- package/dist/drizzle/password-prepared-target.d.mts +4 -3
- package/dist/drizzle/password-prepared-target.mjs +4 -3
- package/dist/drizzle/password-prepared-target.mjs.map +1 -1
- package/dist/drizzle/password-registration.mjs +2 -1
- package/dist/drizzle/password-registration.mjs.map +1 -1
- package/dist/drizzle/password-target.d.mts +6 -5
- package/dist/drizzle/password-target.mjs +8 -8
- package/dist/drizzle/password-target.mjs.map +1 -1
- package/dist/drizzle/pg-database.d.mts +9 -0
- package/dist/drizzle/pg-database.mjs +8 -0
- package/dist/drizzle/pg-database.mjs.map +1 -0
- package/dist/drizzle/pg-emails.d.mts +8 -7
- package/dist/drizzle/pg-emails.mjs +12 -8
- package/dist/drizzle/pg-emails.mjs.map +1 -1
- package/dist/drizzle/pg-identity.mjs +92 -0
- package/dist/drizzle/pg-identity.mjs.map +1 -0
- package/dist/drizzle/pg-password-prepared.d.mts +4 -3
- package/dist/drizzle/pg-password-prepared.mjs +6 -2
- package/dist/drizzle/pg-password-prepared.mjs.map +1 -1
- package/dist/drizzle/pg-passwords.d.mts +7 -5
- package/dist/drizzle/pg-passwords.mjs +11 -7
- package/dist/drizzle/pg-passwords.mjs.map +1 -1
- package/dist/drizzle/pg-proofs.d.mts +4 -3
- package/dist/drizzle/pg-proofs.mjs +8 -4
- package/dist/drizzle/pg-proofs.mjs.map +1 -1
- package/dist/drizzle/pg-sessions.d.mts +12 -11
- package/dist/drizzle/pg-sessions.mjs +16 -12
- package/dist/drizzle/pg-sessions.mjs.map +1 -1
- package/dist/drizzle/phone-model.d.mts +1 -1
- package/dist/drizzle/phone-target.d.mts +5 -4
- package/dist/drizzle/phone-target.mjs +12 -11
- package/dist/drizzle/phone-target.mjs.map +1 -1
- package/dist/drizzle/proof-target.d.mts +4 -3
- package/dist/drizzle/proof-target.mjs +5 -5
- package/dist/drizzle/proof-target.mjs.map +1 -1
- package/dist/drizzle/session-sql.d.mts +1 -0
- package/dist/drizzle/session-target.d.mts +11 -9
- package/dist/drizzle/session-target.mjs +11 -11
- package/dist/drizzle/session-target.mjs.map +1 -1
- package/dist/drizzle/sqlite-emails.mjs +9 -5
- package/dist/drizzle/sqlite-emails.mjs.map +1 -1
- package/dist/drizzle/sqlite-identity.mjs +14 -11
- package/dist/drizzle/sqlite-identity.mjs.map +1 -1
- package/dist/drizzle/sqlite-password-prepared.mjs +7 -3
- package/dist/drizzle/sqlite-password-prepared.mjs.map +1 -1
- package/dist/drizzle/sqlite-passwords.mjs +10 -6
- package/dist/drizzle/sqlite-passwords.mjs.map +1 -1
- package/dist/drizzle/sqlite-proofs.mjs +7 -3
- package/dist/drizzle/sqlite-proofs.mjs.map +1 -1
- package/dist/drizzle/sqlite-sessions.mjs +16 -12
- package/dist/drizzle/sqlite-sessions.mjs.map +1 -1
- package/dist/drizzle/standalone-guard.d.mts +2 -0
- package/dist/drizzle/standalone-guard.mjs +8 -4
- package/dist/drizzle/standalone-guard.mjs.map +1 -1
- package/dist/drizzle/totp-model.d.mts +1 -1
- package/dist/drizzle/totp-target.d.mts +5 -4
- package/dist/drizzle/totp-target.mjs +31 -28
- package/dist/drizzle/totp-target.mjs.map +1 -1
- package/dist/drizzle/transaction-mysql.mjs +1 -1
- package/dist/drizzle/transaction-mysql.mjs.map +1 -1
- package/dist/index.d.mts +2 -4
- package/dist/index.mjs +2 -4
- package/dist/internal/drizzle-postgres.mjs.map +1 -1
- package/dist/internal/drizzle-sqlite.mjs.map +1 -1
- package/package.json +1 -1
- package/src/D1.ts +37 -26
- package/src/Libsql.ts +45 -61
- package/src/Mysql2.ts +39 -35
- package/src/Pglite.ts +48 -30
- package/src/Postgres.ts +48 -30
- package/src/SqliteBun.ts +59 -68
- package/src/SqliteDo.ts +61 -274
- package/src/SqliteNode.ts +56 -66
- package/src/SqliteWasm.ts +56 -66
- package/src/drizzle/D1BatchStatements.ts +1 -1
- package/src/drizzle/d1-database.ts +10 -0
- package/src/drizzle/d1-emails.ts +86 -88
- package/src/drizzle/d1-generated-statement.ts +1 -1
- package/src/drizzle/d1-identity.ts +17 -20
- package/src/drizzle/d1-oauth.ts +19 -8
- package/src/drizzle/d1-passkey.ts +5 -1
- package/src/drizzle/d1-password-prepared.ts +40 -42
- package/src/drizzle/d1-passwords.ts +76 -80
- package/src/drizzle/d1-phone.ts +5 -1
- package/src/drizzle/d1-proofs.ts +31 -34
- package/src/drizzle/d1-sessions.ts +53 -40
- package/src/drizzle/d1-totp.ts +5 -1
- package/src/drizzle/email-registration.ts +6 -2
- package/src/drizzle/email-target.ts +18 -20
- package/src/drizzle/model.ts +1 -208
- package/src/drizzle/mysql-database.ts +8 -0
- package/src/drizzle/mysql-emails.ts +29 -17
- package/src/drizzle/mysql-identity.ts +18 -21
- package/src/drizzle/mysql-password-prepared.ts +11 -9
- package/src/drizzle/mysql-passwords.ts +22 -10
- package/src/drizzle/mysql-proofs.ts +17 -6
- package/src/drizzle/mysql-sessions.ts +41 -18
- package/src/drizzle/native-database.ts +22 -0
- package/src/drizzle/oauth-connected-access.ts +8 -1
- package/src/drizzle/oauth-connected-drivers.ts +21 -6
- package/src/drizzle/oauth-connected-input.ts +13 -0
- package/src/drizzle/oauth-connected-model.ts +17 -0
- package/src/drizzle/oauth-connected-settlement.ts +65 -42
- package/src/drizzle/oauth-connected-sign-in.ts +438 -0
- package/src/drizzle/oauth-connected-state.ts +19 -7
- package/src/drizzle/oauth-connected-target.ts +26 -18
- package/src/drizzle/oauth-drivers.ts +26 -10
- package/src/drizzle/oauth-state.ts +5 -4
- package/src/drizzle/oauth-target.ts +31 -43
- package/src/drizzle/passkey-drivers.ts +21 -13
- package/src/drizzle/passkey-write-drivers.ts +11 -6
- package/src/drizzle/password-prepared-sql.ts +2 -4
- package/src/drizzle/password-prepared-target.ts +10 -7
- package/src/drizzle/password-registration.ts +7 -8
- package/src/drizzle/password-target.ts +20 -19
- package/src/drizzle/pg-database.ts +10 -0
- package/src/drizzle/pg-emails.ts +29 -17
- package/src/drizzle/pg-identity.ts +297 -0
- package/src/drizzle/pg-password-prepared.ts +11 -9
- package/src/drizzle/pg-passwords.ts +22 -10
- package/src/drizzle/pg-proofs.ts +17 -6
- package/src/drizzle/pg-sessions.ts +41 -18
- package/src/drizzle/phone-target.ts +23 -18
- package/src/drizzle/proof-target.ts +10 -13
- package/src/drizzle/session-target.ts +33 -51
- package/src/drizzle/sqlite-emails.ts +31 -14
- package/src/drizzle/sqlite-identity.ts +22 -42
- package/src/drizzle/sqlite-password-prepared.ts +24 -10
- package/src/drizzle/sqlite-passwords.ts +30 -16
- package/src/drizzle/sqlite-proofs.ts +29 -6
- package/src/drizzle/sqlite-sessions.ts +50 -24
- package/src/drizzle/standalone-guard.ts +19 -7
- package/src/drizzle/totp-target.ts +62 -61
- package/src/drizzle/transaction-mysql.ts +1 -1
- package/src/index.ts +0 -24
- package/src/internal/drizzle-postgres.ts +1 -1
- package/src/internal/drizzle-sqlite.ts +1 -1
- package/dist/drizzle/d1-identity.d.mts +0 -30
- package/dist/drizzle/mysql-identity.d.mts +0 -21
- package/dist/drizzle/mysql.d.mts +0 -69
- package/dist/drizzle/mysql.mjs +0 -218
- package/dist/drizzle/mysql.mjs.map +0 -1
- package/dist/drizzle/pg.d.mts +0 -80
- package/dist/drizzle/pg.mjs +0 -289
- package/dist/drizzle/pg.mjs.map +0 -1
- package/dist/drizzle/sqlite.d.mts +0 -77
- package/dist/drizzle/sqlite.mjs +0 -217
- package/dist/drizzle/sqlite.mjs.map +0 -1
- package/src/drizzle/mysql.ts +0 -687
- package/src/drizzle/pg.ts +0 -984
- package/src/drizzle/sqlite.ts +0 -705
package/dist/SqliteDo.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DrizzleTableModel } from "./drizzle/table-model.mjs";
|
|
2
2
|
import { EmailAddressMapping, EmailRegistrationMapping, EmailSignInMapping } from "./drizzle/email-model.mjs";
|
|
3
3
|
import { PasswordRegistrationMapping } from "./drizzle/password-model.mjs";
|
|
4
|
-
import {
|
|
4
|
+
import { ExternalIdentityTables, IdentityTables, SubjectProvisioningTables } from "./drizzle/model.mjs";
|
|
5
5
|
import { ProofPersistenceMapping } from "./drizzle/proof-model.mjs";
|
|
6
6
|
import { PasswordPreparedPersistenceMapping, PasswordPreparedProofMapping } from "./drizzle/password-prepared-model.mjs";
|
|
7
7
|
import { AuthenticationAuthorityMapping, PendingAuthenticationMapping, SignedSessionValidityMapping, StatefulSessionMapping } from "./drizzle/session-model.mjs";
|
|
@@ -20,14 +20,17 @@ import "./index.mjs";
|
|
|
20
20
|
import { SuppliedService } from "./drizzle/SuppliedService.mjs";
|
|
21
21
|
import { TotpCoordinatorError } from "./drizzle/totp-target.mjs";
|
|
22
22
|
import { PhoneCoordinatorError } from "./drizzle/phone-target.mjs";
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import { Context, Effect } from "effect";
|
|
26
|
-
import { AuthStoreDecisions } from "@yielded/auth/Persistence";
|
|
23
|
+
import { NativeDatabase, PersistenceConfigurationError } from "@yielded/auth-persistence/Adapter";
|
|
24
|
+
import { Context, Effect, Layer } from "effect";
|
|
27
25
|
import { AnySQLiteTable } from "drizzle-orm/sqlite-core";
|
|
28
|
-
import {
|
|
26
|
+
import { SqliteClient } from "@effect/sql-sqlite-do/SqliteClient";
|
|
29
27
|
import { EffectSQLiteDoDatabase } from "drizzle-orm/effect-sqlite-do";
|
|
30
28
|
//#region src/SqliteDo.d.ts
|
|
29
|
+
declare const Database_base: Context.ServiceClass<Database, "effect-auth/persistence-drizzle/SqliteDo/Database", EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>>;
|
|
30
|
+
/** The application-owned Drizzle database used to construct persistence services. */
|
|
31
|
+
export declare class Database extends Database_base {}
|
|
32
|
+
/** The SQL-client Layer must configure storage so Drizzle owns transactionSync. */
|
|
33
|
+
export declare const databaseLayer: Layer.Layer<Database, PersistenceConfigurationError, SqliteClient>;
|
|
31
34
|
/**
|
|
32
35
|
* Email mutations must own their outer transactionSync. Arbitrary raw Drizzle
|
|
33
36
|
* nesting is not detectable; owner bodies and mapping allocators stay runSync-compatible.
|
|
@@ -37,26 +40,26 @@ export declare const coordinateEmailAddress: {
|
|
|
37
40
|
readonly mapping: EmailAddressMapping<S, I, C, AC, M, NativeId>;
|
|
38
41
|
readonly 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>>;
|
|
39
42
|
readonly transaction?: never;
|
|
40
|
-
}, body: Effect.Effect<Out, E, NoInfer<import("@yielded/auth/Email").EmailAddressPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
43
|
+
}, body: Effect.Effect<Out, E, NoInfer<import("@yielded/auth/Email").EmailAddressPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
41
44
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, NativeId, Out, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
42
45
|
readonly mapping: EmailAddressMapping<S, I, C, AC, M, NativeId>;
|
|
43
46
|
readonly 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>>;
|
|
44
47
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
45
|
-
}, body: Effect.Effect<Out, E, NoInfer<TxId | import("@yielded/auth/Email").EmailAddressPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
48
|
+
}, body: Effect.Effect<Out, E, NoInfer<TxId | import("@yielded/auth/Email").EmailAddressPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
46
49
|
}, coordinateEmailRegistration: {
|
|
47
50
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId, Out, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
48
51
|
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, Rq, NativeId>;
|
|
49
52
|
readonly 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>>;
|
|
50
53
|
readonly target: SuppliedService<TargetId, EmailRegistrationAuthority<Registration>>;
|
|
51
54
|
readonly transaction?: never;
|
|
52
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
55
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
53
56
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId, Out, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
54
57
|
readonly mapping: EmailRegistrationMapping<NoInfer<Registration>, S, I, C, AC, Rq, NativeId>;
|
|
55
58
|
readonly 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>>;
|
|
56
59
|
readonly target: SuppliedService<TargetId, EmailRegistrationAuthority<Registration>>;
|
|
57
60
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
58
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
59
|
-
}, makeEmailAddressServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(
|
|
61
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Email").EmailUnavailable | import("@yielded/auth/Hooks").HookConfigurationError | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
62
|
+
}, makeEmailAddressServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(mapping: EmailAddressMapping<S, I, C, AC, M, 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<{
|
|
60
63
|
emailAddressPersistence: {
|
|
61
64
|
readonly target: (input: {
|
|
62
65
|
readonly moduleId: string;
|
|
@@ -75,16 +78,16 @@ export declare const coordinateEmailAddress: {
|
|
|
75
78
|
readonly hasMore: boolean;
|
|
76
79
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
77
80
|
};
|
|
78
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailRegistrationServices: <Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId>(
|
|
81
|
+
}, never, 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<{
|
|
79
82
|
registrationAuthority: EmailRegistrationAuthority<Registration>;
|
|
80
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeEmailSignInServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, NativeId>(
|
|
83
|
+
}, never, 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<{
|
|
81
84
|
emailSignInTargets: {
|
|
82
85
|
readonly lookup: (input: {
|
|
83
86
|
readonly moduleId: string;
|
|
84
87
|
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
85
88
|
}) => Effect.Effect<import("effect/Option").Option<import("@yielded/auth/Email").EmailCredentialSnapshot>, import("@yielded/auth/Email").EmailUnavailable>;
|
|
86
89
|
};
|
|
87
|
-
}, never,
|
|
90
|
+
}, never, Database>;
|
|
88
91
|
/**
|
|
89
92
|
* Password mutations and registration must own their outer transactionSync.
|
|
90
93
|
* Arbitrary raw Drizzle nesting is not detectable; owner bodies must remain
|
|
@@ -95,24 +98,24 @@ export declare const coordinatePasswordPersistence: {
|
|
|
95
98
|
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<RS>, DrizzleTableModel<CE>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
96
99
|
readonly proofMapping?: PM | undefined;
|
|
97
100
|
readonly transaction?: never;
|
|
98
|
-
}, body: Effect.Effect<Out, E, NoInfer<import("@yielded/auth/Password").PasswordPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
101
|
+
}, body: Effect.Effect<Out, E, NoInfer<import("@yielded/auth/Password").PasswordPersistence>>): 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>;
|
|
99
102
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE extends AnySQLiteTable, M extends AnySQLiteTable, NativeId, PM extends ProofPersistenceMapping<any, any, any, any, any, any, any, any, any, any, any, any> | undefined, Out, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
100
103
|
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<RS>, DrizzleTableModel<CE>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
101
104
|
readonly proofMapping?: PM | undefined;
|
|
102
105
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
103
|
-
}, body: Effect.Effect<Out, E, NoInfer<TxId | import("@yielded/auth/Password").PasswordPersistence>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
106
|
+
}, body: Effect.Effect<Out, E, NoInfer<TxId | import("@yielded/auth/Password").PasswordPersistence>>): 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>;
|
|
104
107
|
}, coordinatePasswordRegistration: {
|
|
105
108
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId, Out, E, R, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
106
109
|
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, Rq, NativeId>;
|
|
107
110
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
108
111
|
readonly transaction?: never;
|
|
109
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
112
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): 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>;
|
|
110
113
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId, Out, E, R, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
111
114
|
readonly mapping: PasswordRegistrationMapping<NoInfer<Registration>, S, I, C, AC, Rq, NativeId>;
|
|
112
115
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
113
116
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
114
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
115
|
-
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(
|
|
117
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): 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>;
|
|
118
|
+
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<RS>, DrizzleTableModel<CE>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>, proofMapping?: ProofPersistenceMapping<any, any, any, any, any, any, any, any, any, any, any, any>) => Effect.Effect<{
|
|
116
119
|
passwordPersistence: {
|
|
117
120
|
readonly admitAttempt: <A_1>(input: {
|
|
118
121
|
readonly moduleId: string;
|
|
@@ -154,9 +157,9 @@ export declare const coordinatePasswordPersistence: {
|
|
|
154
157
|
readonly hasMore: boolean;
|
|
155
158
|
}, A_1>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A_1>, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
156
159
|
};
|
|
157
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makePasswordRegistrationServices: <Registration, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, Rq extends AnySQLiteTable, NativeId>(
|
|
160
|
+
}, never, 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<{
|
|
158
161
|
registrationAuthority: import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>;
|
|
159
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
162
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
160
163
|
/**
|
|
161
164
|
* Proof mutations and coordinateProofPersistence must own their outermost
|
|
162
165
|
* transactionSync call. The installed driver cannot detect an arbitrary raw
|
|
@@ -167,12 +170,12 @@ export declare const coordinateProofPersistence: {
|
|
|
167
170
|
<Database extends EffectSQLiteDoDatabase<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>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
168
171
|
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>>;
|
|
169
172
|
readonly transaction?: never;
|
|
170
|
-
}, body: Effect.Effect<A, E, NoInfer<import("@yielded/auth/Proofs").ProofPersistence>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Proofs").ProofUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
173
|
+
}, body: Effect.Effect<A, E, NoInfer<import("@yielded/auth/Proofs").ProofPersistence>>): 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>;
|
|
171
174
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
172
175
|
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>>;
|
|
173
176
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
174
|
-
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Proofs").ProofPersistence>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Proofs").ProofUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
175
|
-
}, 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>(
|
|
177
|
+
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Proofs").ProofPersistence>>): 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>;
|
|
178
|
+
}, 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<{
|
|
176
179
|
proofPersistence: {
|
|
177
180
|
readonly issue: <A_1>(input: {
|
|
178
181
|
readonly record: import("@yielded/auth/Proofs").ProofRecord;
|
|
@@ -222,7 +225,7 @@ export declare const coordinateProofPersistence: {
|
|
|
222
225
|
readonly limit: number;
|
|
223
226
|
}, 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>;
|
|
224
227
|
};
|
|
225
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
228
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
226
229
|
/**
|
|
227
230
|
* Session mutation methods and coordinate* functions must own their outermost
|
|
228
231
|
* transactionSync call. The installed Drizzle driver exposes no context marker
|
|
@@ -234,47 +237,47 @@ export declare const coordinateAuthenticationAuthority: {
|
|
|
234
237
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
235
238
|
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, F, P, NativeId>;
|
|
236
239
|
readonly transaction?: never;
|
|
237
|
-
}, body: Effect.Effect<A, E, NoInfer<import("@yielded/auth/Sessions").AuthenticationAuthority>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
240
|
+
}, body: Effect.Effect<A, E, NoInfer<import("@yielded/auth/Sessions").AuthenticationAuthority>>): 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>;
|
|
238
241
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
239
242
|
readonly mapping: AuthenticationAuthorityMapping<Claims, S, C, F, P, NativeId>;
|
|
240
243
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
241
|
-
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Sessions").AuthenticationAuthority>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
244
|
+
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Sessions").AuthenticationAuthority>>): 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>;
|
|
242
245
|
}, coordinatePendingAuthentication: {
|
|
243
246
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
244
247
|
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, F, NativeId>;
|
|
245
248
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
246
249
|
readonly transaction?: never;
|
|
247
|
-
}, body: Effect.Effect<A, E, NoInfer<TargetId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
250
|
+
}, body: Effect.Effect<A, E, NoInfer<TargetId>>): 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>;
|
|
248
251
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
249
252
|
readonly mapping: PendingAuthenticationMapping<NoInfer<Claims>, S, C, P, F, NativeId>;
|
|
250
253
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").PendingAuthentication<Claims>>;
|
|
251
254
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
252
|
-
}, body: Effect.Effect<A, E, NoInfer<TargetId | TxId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
255
|
+
}, body: Effect.Effect<A, E, NoInfer<TargetId | TxId>>): 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>;
|
|
253
256
|
}, coordinateSignedSessionValidity: {
|
|
254
257
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
255
258
|
readonly mapping: SignedSessionValidityMapping<S, T, NativeId, NativeSessionId>;
|
|
256
259
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
257
260
|
readonly transaction?: never;
|
|
258
|
-
}, body: Effect.Effect<A, E, NoInfer<TargetId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
261
|
+
}, body: Effect.Effect<A, E, NoInfer<TargetId>>): 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>;
|
|
259
262
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
260
263
|
readonly mapping: SignedSessionValidityMapping<S, T, NativeId, NativeSessionId>;
|
|
261
264
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Sessions").SignedSessionValidity>;
|
|
262
265
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
263
|
-
}, body: Effect.Effect<A, E, NoInfer<TargetId | TxId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
266
|
+
}, body: Effect.Effect<A, E, NoInfer<TargetId | TxId>>): 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>;
|
|
264
267
|
}, coordinateStatefulSessions: {
|
|
265
268
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
266
269
|
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, F, P, NativeId, NativeSessionId>;
|
|
267
270
|
readonly persistence: SuppliedService<PersistenceId, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
268
271
|
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
269
272
|
readonly transaction?: never;
|
|
270
|
-
}, body: Effect.Effect<A, E, NoInfer<PersistenceId | RepositoryId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
273
|
+
}, body: Effect.Effect<A, E, NoInfer<PersistenceId | RepositoryId>>): 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>;
|
|
271
274
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
272
275
|
readonly mapping: StatefulSessionMapping<NoInfer<Claims>, S, C, Session, F, P, NativeId, NativeSessionId>;
|
|
273
276
|
readonly persistence: SuppliedService<PersistenceId, import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>>;
|
|
274
277
|
readonly repository: SuppliedService<RepositoryId, import("@yielded/auth/Sessions").SessionRepository>;
|
|
275
278
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
276
|
-
}, body: Effect.Effect<A, E, NoInfer<PersistenceId | RepositoryId | TxId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
277
|
-
}, makeAuthenticationAuthorityServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId>(
|
|
279
|
+
}, body: Effect.Effect<A, E, NoInfer<PersistenceId | RepositoryId | TxId>>): 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>;
|
|
280
|
+
}, 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<{
|
|
278
281
|
authenticationAuthority: {
|
|
279
282
|
readonly capture: (subjectId: import("@yielded/auth/Schema").SubjectId, credentialIds: ReadonlyArray<string>) => Effect.Effect<import("@yielded/auth/Sessions").AuthenticationRevision, import("@yielded/auth/Sessions").StaleAuthentication | import("@yielded/auth/Sessions").SessionUnavailable>;
|
|
280
283
|
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>;
|
|
@@ -286,133 +289,61 @@ export declare const coordinateAuthenticationAuthority: {
|
|
|
286
289
|
readonly pending?: import("@yielded/auth/Sessions").PendingConsumption;
|
|
287
290
|
}, 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>;
|
|
288
291
|
};
|
|
289
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makePendingAuthenticationServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, P extends AnySQLiteTable, F extends AnySQLiteTable, NativeId>(
|
|
292
|
+
}, never, 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<{
|
|
290
293
|
pendingAuthentication: import("@yielded/auth/Sessions").PendingAuthentication<Claims>;
|
|
291
|
-
}, never, 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>(
|
|
294
|
+
}, never, 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<{
|
|
292
295
|
sessionStepUpPersistence: import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>;
|
|
293
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, coordinateSessionStepUp: {
|
|
296
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateSessionStepUp: {
|
|
294
297
|
<Database extends EffectSQLiteDoDatabase<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: {
|
|
295
298
|
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, I, Session, T, NativeId, NativeSessionId>;
|
|
296
299
|
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
297
300
|
readonly transaction?: never;
|
|
298
|
-
}, body: Effect.Effect<A, E, NoInfer<Id>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
301
|
+
}, body: Effect.Effect<A, E, NoInfer<Id>>): 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>;
|
|
299
302
|
<Database extends EffectSQLiteDoDatabase<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, TxId, TxShape>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
300
303
|
readonly mapping: SessionStepUpMapping<NoInfer<Claims>, S, C, I, Session, T, NativeId, NativeSessionId>;
|
|
301
304
|
readonly target: SuppliedService<Id, import("@yielded/auth/Sessions").SessionStepUpPersistence<Claims>>;
|
|
302
305
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
303
|
-
}, body: Effect.Effect<A, E, NoInfer<Id | TxId>>): Effect.Effect<A, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Sessions").SessionUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
304
|
-
}, makeSignedSessionValidityServices: <S extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId>(
|
|
306
|
+
}, body: Effect.Effect<A, E, NoInfer<Id | TxId>>): 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>;
|
|
307
|
+
}, makeSignedSessionValidityServices: <S extends AnySQLiteTable, T extends AnySQLiteTable, NativeId, NativeSessionId>(mapping: SignedSessionValidityMapping<S, T, NativeId, NativeSessionId>) => Effect.Effect<{
|
|
305
308
|
signedSessionValidity: import("@yielded/auth/Sessions").SignedSessionValidity;
|
|
306
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeStatefulSessionServices: <Claims, S extends AnySQLiteTable, C extends AnySQLiteTable, Session extends AnySQLiteTable, F extends AnySQLiteTable, P extends AnySQLiteTable, NativeId, NativeSessionId>(
|
|
309
|
+
}, never, 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<{
|
|
307
310
|
readonly statefulSessionPersistence: import("@yielded/auth/Sessions").StatefulSessionPersistence<Claims>;
|
|
308
311
|
readonly sessionRepository: import("@yielded/auth/Sessions").SessionRepository;
|
|
309
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
312
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
310
313
|
export declare const commitMode: "synchronous";
|
|
311
|
-
export declare const
|
|
312
|
-
readonly authStore: {
|
|
313
|
-
readonly issueChallenge: (input: import("@yielded/auth/Schema").NewChallenge) => Effect.Effect<void, import("@yielded/auth/AuthStore").IssueChallengeError>;
|
|
314
|
-
readonly consumeChallenge: (input: import("@yielded/auth/Schema").ConsumeChallenge) => Effect.Effect<import("@yielded/auth/Schema").VerifiedEmail, import("@yielded/auth/AuthStore").EmailOtpRejected | import("@yielded/auth/Errors").AuthStoreError>;
|
|
315
|
-
readonly issueRegistration: (input: import("@yielded/auth/Schema").NewRegistration) => Effect.Effect<void, import("@yielded/auth/Errors").AuthStoreError>;
|
|
316
|
-
readonly inspectRegistration: (tokenDigest: import("@yielded/auth/Schema").TokenDigest) => Effect.Effect<import("@yielded/auth/Schema").PendingRegistration, import("@yielded/auth/Errors").InvalidRegistration | import("@yielded/auth/Errors").AuthStoreError>;
|
|
317
|
-
readonly consumeRegistration: (input: import("@yielded/auth/Schema").ConsumeRegistration) => Effect.Effect<void, import("@yielded/auth/Errors").InvalidRegistration | import("@yielded/auth/Errors").AuthStoreError>;
|
|
318
|
-
};
|
|
319
|
-
readonly decisions: {
|
|
320
|
-
readonly consumeChallenge: (input: import("@yielded/auth/Schema").ConsumeChallenge) => Effect.Effect<import("@yielded/auth/AuthStore").ChallengeConsumeDecision, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
321
|
-
readonly consumeRegistration: (input: import("@yielded/auth/Schema").ConsumeRegistration) => Effect.Effect<import("@yielded/auth/AuthStore").ConsumeDecision<void>, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
322
|
-
};
|
|
323
|
-
};
|
|
324
|
-
export declare const makeOAuthStateServices: <S extends AnySQLiteTable>(database: EffectSQLiteDoDatabase<AnyRelations>, mapping: OAuthStateTables<S>) => {
|
|
325
|
-
readonly oauthStateStore: {
|
|
326
|
-
readonly issue: (state: import("@yielded/auth/OAuth").OAuthState) => Effect.Effect<void, import("@yielded/auth/Errors").AuthStoreError>;
|
|
327
|
-
readonly consume: (stateDigest: import("@yielded/auth/Schema").TokenDigest) => Effect.Effect<import("@yielded/auth/OAuth").OAuthState, import("@yielded/auth/OAuth").InvalidOAuthState | import("@yielded/auth/Errors").AuthStoreError>;
|
|
328
|
-
};
|
|
329
|
-
readonly decisions: {
|
|
330
|
-
readonly consumeOAuthState: (digest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">) => Effect.Effect<import("@yielded/auth/AuthStore").ConsumeDecision<import("@yielded/auth/OAuth").OAuthState>, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
331
|
-
};
|
|
332
|
-
};
|
|
333
|
-
export declare const makeAuthServices: <C extends AnySQLiteTable, R extends AnySQLiteTable, S extends AnySQLiteTable>(database: EffectSQLiteDoDatabase<AnyRelations>, mapping: AuthTables<C, R, S>) => {
|
|
334
|
-
readonly authStore: {
|
|
335
|
-
readonly issueChallenge: (input: import("@yielded/auth/Schema").NewChallenge) => Effect.Effect<void, import("@yielded/auth/AuthStore").IssueChallengeError>;
|
|
336
|
-
readonly consumeChallenge: (input: import("@yielded/auth/Schema").ConsumeChallenge) => Effect.Effect<import("@yielded/auth/Schema").VerifiedEmail, import("@yielded/auth/AuthStore").EmailOtpRejected | import("@yielded/auth/Errors").AuthStoreError>;
|
|
337
|
-
readonly issueRegistration: (input: import("@yielded/auth/Schema").NewRegistration) => Effect.Effect<void, import("@yielded/auth/Errors").AuthStoreError>;
|
|
338
|
-
readonly inspectRegistration: (tokenDigest: import("@yielded/auth/Schema").TokenDigest) => Effect.Effect<import("@yielded/auth/Schema").PendingRegistration, import("@yielded/auth/Errors").InvalidRegistration | import("@yielded/auth/Errors").AuthStoreError>;
|
|
339
|
-
readonly consumeRegistration: (input: import("@yielded/auth/Schema").ConsumeRegistration) => Effect.Effect<void, import("@yielded/auth/Errors").InvalidRegistration | import("@yielded/auth/Errors").AuthStoreError>;
|
|
340
|
-
};
|
|
341
|
-
readonly oauthStateStore: {
|
|
342
|
-
readonly issue: (state: import("@yielded/auth/OAuth").OAuthState) => Effect.Effect<void, import("@yielded/auth/Errors").AuthStoreError>;
|
|
343
|
-
readonly consume: (stateDigest: import("@yielded/auth/Schema").TokenDigest) => Effect.Effect<import("@yielded/auth/OAuth").OAuthState, import("@yielded/auth/OAuth").InvalidOAuthState | import("@yielded/auth/Errors").AuthStoreError>;
|
|
344
|
-
};
|
|
345
|
-
readonly decisions: {
|
|
346
|
-
readonly consumeChallenge: (input: import("@yielded/auth/Schema").ConsumeChallenge) => Effect.Effect<import("@yielded/auth/AuthStore").ChallengeConsumeDecision, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
347
|
-
readonly consumeRegistration: (input: import("@yielded/auth/Schema").ConsumeRegistration) => Effect.Effect<import("@yielded/auth/AuthStore").ConsumeDecision<void>, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
348
|
-
readonly consumeOAuthState: (digest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">) => Effect.Effect<import("@yielded/auth/AuthStore").ConsumeDecision<import("@yielded/auth/OAuth").OAuthState>, import("@yielded/auth/Errors").AuthStoreError, never>;
|
|
349
|
-
};
|
|
350
|
-
};
|
|
351
|
-
type TransactionOf<D extends EffectSQLiteDoDatabase<AnyRelations>> = Parameters<Parameters<D["transaction"]>[0]>[0];
|
|
352
|
-
export declare function coordinateAuthStoreTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, C extends AnySQLiteTable, R extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
353
|
-
readonly mapping: AuthStoreTables<C, R>;
|
|
354
|
-
readonly transaction?: never;
|
|
355
|
-
}, body: Effect.Effect<A, E, NoInfer<AuthStoreDecisions>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
356
|
-
export declare function coordinateAuthStoreTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, C extends AnySQLiteTable, R extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
357
|
-
readonly mapping: AuthStoreTables<C, R>;
|
|
358
|
-
readonly transaction: SuppliedService<TxId, NoInfer<TransactionOf<D>>, TxShape>;
|
|
359
|
-
}, body: Effect.Effect<A, E, NoInfer<AuthStoreDecisions | TxId>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
360
|
-
export declare function coordinateOAuthStateTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, S extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
361
|
-
readonly mapping: OAuthStateTables<S>;
|
|
362
|
-
readonly transaction?: never;
|
|
363
|
-
}, body: Effect.Effect<A, E, NoInfer<OAuthStateDecisions>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
364
|
-
export declare function coordinateOAuthStateTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, S extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
365
|
-
readonly mapping: OAuthStateTables<S>;
|
|
366
|
-
readonly transaction: SuppliedService<TxId, NoInfer<TransactionOf<D>>, TxShape>;
|
|
367
|
-
}, body: Effect.Effect<A, E, NoInfer<OAuthStateDecisions | TxId>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
368
|
-
/**
|
|
369
|
-
* Supported composition boundary for Durable Objects. The owner must return
|
|
370
|
-
* decisions as values and translate rejection only after this root
|
|
371
|
-
* transactionSync commit. Its body may contain only runSync-compatible Effects;
|
|
372
|
-
* the installed driver rejects suspension and rolls back. Owner failure rolls
|
|
373
|
-
* back synchronously, so no retry is performed inside this boundary.
|
|
374
|
-
*/
|
|
375
|
-
export declare function coordinateAuthTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, C extends AnySQLiteTable, R extends AnySQLiteTable, S extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
376
|
-
readonly mapping: AuthTables<C, R, S>;
|
|
377
|
-
readonly transaction?: never;
|
|
378
|
-
}, body: Effect.Effect<A, E, NoInfer<AuthStoreDecisions | OAuthStateDecisions>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
379
|
-
export declare function coordinateAuthTransaction<D extends EffectSQLiteDoDatabase<AnyRelations>, C extends AnySQLiteTable, R extends AnySQLiteTable, S extends AnySQLiteTable, A, E, DatabaseError, DatabaseRequirements, TxId, TxShape>(acquire: Effect.Effect<D, DatabaseError, DatabaseRequirements>, options: {
|
|
380
|
-
readonly mapping: AuthTables<C, R, S>;
|
|
381
|
-
readonly transaction: SuppliedService<TxId, NoInfer<TransactionOf<D>>, TxShape>;
|
|
382
|
-
}, body: Effect.Effect<A, E, NoInfer<AuthStoreDecisions | OAuthStateDecisions | TxId>>): Effect.Effect<A, E | DatabaseError | SqlError, DatabaseRequirements>;
|
|
383
|
-
export declare const makeIdentityServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, External extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(database: EffectSQLiteDoDatabase<AnyRelations>, mapping: IdentityTables<Subject, Identifier, External, Request, NativeId>) => {
|
|
314
|
+
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<{
|
|
384
315
|
subjectProvisioner: {
|
|
385
316
|
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").ProvisioningResult, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
386
317
|
};
|
|
387
318
|
externalIdentityMutation: {
|
|
388
319
|
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>;
|
|
389
320
|
};
|
|
390
|
-
}
|
|
391
|
-
export declare const makeSubjectProvisioningServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(
|
|
321
|
+
}, never, Database>;
|
|
322
|
+
export declare const makeSubjectProvisioningServices: <Subject extends AnySQLiteTable, Identifier extends AnySQLiteTable, Request extends AnySQLiteTable, NativeId>(mapping: SubjectProvisioningTables<Subject, Identifier, Request, NativeId>) => Effect.Effect<{
|
|
392
323
|
readonly subjectProvisioner: {
|
|
393
324
|
readonly provision: (input: import("@yielded/auth/Identity").SubjectProvisioningInput) => Effect.Effect<import("@yielded/auth/Identity").ProvisioningResult, import("@yielded/auth/Identity").IdentityConflict | import("@yielded/auth/Identity").IdentityUnavailable>;
|
|
394
325
|
};
|
|
395
|
-
}
|
|
396
|
-
export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTable, External extends AnySQLiteTable, NativeId>(
|
|
326
|
+
}, never, Database>;
|
|
327
|
+
export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTable, External extends AnySQLiteTable, NativeId>(mapping: ExternalIdentityTables<Subject, External, NativeId>) => Effect.Effect<{
|
|
397
328
|
readonly externalIdentityMutation: {
|
|
398
329
|
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>;
|
|
399
330
|
};
|
|
400
|
-
}
|
|
401
|
-
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE 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>(
|
|
331
|
+
}, never, Database>;
|
|
332
|
+
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE 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, A, RS, CE, M, T, B, NativeId>, proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined) => Effect.Effect<{
|
|
402
333
|
passwordPreparedPersistence: import("@yielded/auth/Password").PasswordPreparedPersistence;
|
|
403
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
334
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
404
335
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE 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: {
|
|
405
336
|
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, RS, CE, M, T, B, NativeId>;
|
|
406
337
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
407
338
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
408
339
|
readonly transaction?: never;
|
|
409
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
340
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId>>): 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>;
|
|
410
341
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, RS extends AnySQLiteTable, CE 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: {
|
|
411
342
|
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, RS, CE, M, T, B, NativeId>;
|
|
412
343
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
413
344
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
414
345
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
415
|
-
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
346
|
+
}, body: Effect.Effect<Out, E, NoInfer<TargetId | TxId>>): 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>;
|
|
416
347
|
};
|
|
417
348
|
export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
418
349
|
dialect: "sqlite";
|
|
@@ -428,7 +359,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
428
359
|
dialect: "sqlite";
|
|
429
360
|
}>, U extends AnySQLiteTable<{
|
|
430
361
|
dialect: "sqlite";
|
|
431
|
-
}>, N>(
|
|
362
|
+
}>, N>(mapping: OAuthAccountsMapping<S, O, C, AC, F, TA, U, N>) => Effect.Effect<{
|
|
432
363
|
oauthAccountsPersistence: {
|
|
433
364
|
readonly capture: (input: {
|
|
434
365
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
@@ -438,8 +369,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
438
369
|
readonly flow: import("@yielded/auth/OAuth").OAuthLinkPendingFlow;
|
|
439
370
|
readonly authorization: import("@yielded/auth/OAuth").OAuthActionAuthorization;
|
|
440
371
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
441
|
-
readonly _tag: "Rejected";
|
|
442
|
-
} | {
|
|
443
372
|
readonly _tag: "Issued";
|
|
444
373
|
readonly flow: {
|
|
445
374
|
readonly context: {
|
|
@@ -454,6 +383,21 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
454
383
|
readonly generation: number;
|
|
455
384
|
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
456
385
|
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
386
|
+
readonly access?: {
|
|
387
|
+
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
388
|
+
readonly generation: number;
|
|
389
|
+
readonly issuance: "active" | "retired";
|
|
390
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
391
|
+
readonly clientRegistrationId: string;
|
|
392
|
+
readonly scopes: readonly string[];
|
|
393
|
+
readonly resources: readonly string[];
|
|
394
|
+
readonly retention: "access-and-refresh" | "access-only";
|
|
395
|
+
readonly maximumAccessLifetimeMillis: number;
|
|
396
|
+
readonly maximumRefreshLifetimeMillis?: number | undefined;
|
|
397
|
+
readonly refreshAheadMillis: number;
|
|
398
|
+
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
399
|
+
readonly revocation: "cohort" | "unsupported";
|
|
400
|
+
} | undefined;
|
|
457
401
|
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
458
402
|
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
459
403
|
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
@@ -480,6 +424,8 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
480
424
|
};
|
|
481
425
|
readonly retentionUntilMillis: number;
|
|
482
426
|
};
|
|
427
|
+
} | {
|
|
428
|
+
readonly _tag: "Rejected";
|
|
483
429
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
484
430
|
readonly preflight: (input: import("@yielded/auth/OAuth").OAuthLinkAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthLinkPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
485
431
|
readonly claim: <A>(input: {
|
|
@@ -505,6 +451,21 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
505
451
|
readonly generation: number;
|
|
506
452
|
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
507
453
|
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
454
|
+
readonly access?: {
|
|
455
|
+
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
456
|
+
readonly generation: number;
|
|
457
|
+
readonly issuance: "active" | "retired";
|
|
458
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
459
|
+
readonly clientRegistrationId: string;
|
|
460
|
+
readonly scopes: readonly string[];
|
|
461
|
+
readonly resources: readonly string[];
|
|
462
|
+
readonly retention: "access-and-refresh" | "access-only";
|
|
463
|
+
readonly maximumAccessLifetimeMillis: number;
|
|
464
|
+
readonly maximumRefreshLifetimeMillis?: number | undefined;
|
|
465
|
+
readonly refreshAheadMillis: number;
|
|
466
|
+
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
467
|
+
readonly revocation: "cohort" | "unsupported";
|
|
468
|
+
} | undefined;
|
|
508
469
|
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
509
470
|
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
510
471
|
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
@@ -544,8 +505,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
544
505
|
readonly nowMillis: number;
|
|
545
506
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
546
507
|
readonly _tag: "Rejected";
|
|
547
|
-
} | {
|
|
548
|
-
readonly _tag: "Conflict";
|
|
549
508
|
} | {
|
|
550
509
|
readonly _tag: "Cancelled";
|
|
551
510
|
} | {
|
|
@@ -571,6 +530,8 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
571
530
|
};
|
|
572
531
|
};
|
|
573
532
|
readonly changed: boolean;
|
|
533
|
+
} | {
|
|
534
|
+
readonly _tag: "Conflict";
|
|
574
535
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
575
536
|
readonly inspectUnlink: (input: {
|
|
576
537
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
@@ -648,7 +609,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
648
609
|
readonly hasMore: boolean;
|
|
649
610
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
650
611
|
};
|
|
651
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthSignInServices: <S extends AnySQLiteTable<{
|
|
612
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthSignInServices: <S extends AnySQLiteTable<{
|
|
652
613
|
dialect: "sqlite";
|
|
653
614
|
}>, O extends AnySQLiteTable<{
|
|
654
615
|
dialect: "sqlite";
|
|
@@ -658,7 +619,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
658
619
|
dialect: "sqlite";
|
|
659
620
|
}>, F extends AnySQLiteTable<{
|
|
660
621
|
dialect: "sqlite";
|
|
661
|
-
}>, N>(
|
|
622
|
+
}>, N>(mapping: OAuthSignInMapping<S, O, C, AC, F, N>) => Effect.Effect<{
|
|
662
623
|
oauthSignInPersistence: {
|
|
663
624
|
readonly issue: <A>(input: import("@yielded/auth/OAuth").OAuthPendingFlow, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<import("@yielded/auth/OAuth").OAuthIssueDecision, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
664
625
|
readonly claim: <A>(input: {
|
|
@@ -690,7 +651,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
690
651
|
readonly hasMore: boolean;
|
|
691
652
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
692
653
|
};
|
|
693
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationIntentServices: <S extends AnySQLiteTable<{
|
|
654
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationIntentServices: <S extends AnySQLiteTable<{
|
|
694
655
|
dialect: "sqlite";
|
|
695
656
|
}>, O extends AnySQLiteTable<{
|
|
696
657
|
dialect: "sqlite";
|
|
@@ -704,7 +665,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
704
665
|
dialect: "sqlite";
|
|
705
666
|
}>, I extends AnySQLiteTable<{
|
|
706
667
|
dialect: "sqlite";
|
|
707
|
-
}>, N>(
|
|
668
|
+
}>, N>(mapping: OAuthRegistrationIntentMapping<S, O, C, AC, F, TA, I, N>) => Effect.Effect<{
|
|
708
669
|
oauthRegistrationIntents: {
|
|
709
670
|
readonly settle: <A>(input: {
|
|
710
671
|
readonly claim: import("@yielded/auth/OAuth").OAuthClaim;
|
|
@@ -713,7 +674,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
713
674
|
readonly nowMillis: number;
|
|
714
675
|
}, 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>;
|
|
715
676
|
};
|
|
716
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationServices: <Registration, S extends AnySQLiteTable<{
|
|
677
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthRegistrationServices: <Registration, S extends AnySQLiteTable<{
|
|
717
678
|
dialect: "sqlite";
|
|
718
679
|
}>, O extends AnySQLiteTable<{
|
|
719
680
|
dialect: "sqlite";
|
|
@@ -727,9 +688,9 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
727
688
|
dialect: "sqlite";
|
|
728
689
|
}>, R extends AnySQLiteTable<{
|
|
729
690
|
dialect: "sqlite";
|
|
730
|
-
}>, N>(
|
|
691
|
+
}>, N>(mapping: OAuthRegistrationMapping<Registration, S, O, C, AC, TA, I, R, N>) => Effect.Effect<{
|
|
731
692
|
registrationAuthority: OAuthRegistrationAuthority<Registration>;
|
|
732
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthRegistration: {
|
|
693
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthRegistration: {
|
|
733
694
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, Registration, S extends AnySQLiteTable<{
|
|
734
695
|
dialect: "sqlite";
|
|
735
696
|
}>, O extends AnySQLiteTable<{
|
|
@@ -901,8 +862,100 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
901
862
|
dialect: "sqlite";
|
|
902
863
|
}>, N, J extends AnySQLiteTable<{
|
|
903
864
|
dialect: "sqlite";
|
|
904
|
-
}> = never>(
|
|
865
|
+
}> = never>(mapping: OAuthConnectedMapping<S, AC, T, O, F, G, C, H, UA, DC, N, J>) => Effect.Effect<{
|
|
905
866
|
oauthConnectedPersistence: {
|
|
867
|
+
readonly claimSignIn: <A>(input: {
|
|
868
|
+
readonly claim: import("@yielded/auth/OAuth").OAuthClaim;
|
|
869
|
+
readonly configuration: import("@yielded/auth/OAuth").OAuthConnectedConfiguration;
|
|
870
|
+
}, 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>;
|
|
871
|
+
readonly inspectSignIn: (input: {
|
|
872
|
+
readonly reservation: import("@yielded/auth/OAuth").OAuthSignInAccessClaim;
|
|
873
|
+
readonly credential: import("@yielded/auth/OAuth").OAuthCredentialSnapshot;
|
|
874
|
+
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
875
|
+
}) => Effect.Effect<import("@yielded/auth/OAuth").OAuthSignInAccessInspection, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
876
|
+
readonly settleSignIn: <A>(input: {
|
|
877
|
+
readonly reservation: import("@yielded/auth/OAuth").OAuthSignInAccessClaim;
|
|
878
|
+
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
879
|
+
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
880
|
+
readonly _tag: "Rejected";
|
|
881
|
+
} | {
|
|
882
|
+
readonly _tag: "Cancelled";
|
|
883
|
+
} | {
|
|
884
|
+
readonly _tag: "Ambiguous";
|
|
885
|
+
} | {
|
|
886
|
+
readonly _tag: "Conflict";
|
|
887
|
+
} | {
|
|
888
|
+
readonly _tag: "Connected";
|
|
889
|
+
readonly grant: {
|
|
890
|
+
readonly context: {
|
|
891
|
+
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
892
|
+
readonly exchangeOrder: string;
|
|
893
|
+
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
894
|
+
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
895
|
+
readonly identity: {
|
|
896
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
897
|
+
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
898
|
+
readonly subject: string;
|
|
899
|
+
};
|
|
900
|
+
readonly configuration: {
|
|
901
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
902
|
+
readonly protocol: "oauth" | "oidc";
|
|
903
|
+
readonly configurationGeneration: number;
|
|
904
|
+
readonly issuer: string & import("effect/Brand").Brand<"effect-auth/OAuthIssuer">;
|
|
905
|
+
readonly responseIssuerMode: "required" | "unsupported";
|
|
906
|
+
readonly callbackId: string & import("effect/Brand").Brand<"effect-auth/OAuthCallbackId">;
|
|
907
|
+
readonly redirectUri: string & import("effect/Brand").Brand<"effect-auth/OAuthRedirectUri">;
|
|
908
|
+
readonly profile: {
|
|
909
|
+
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
910
|
+
readonly generation: number;
|
|
911
|
+
readonly issuance: "active" | "retired";
|
|
912
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
913
|
+
readonly clientRegistrationId: string;
|
|
914
|
+
readonly scopes: readonly string[];
|
|
915
|
+
readonly resources: readonly string[];
|
|
916
|
+
readonly retention: "access-and-refresh" | "access-only";
|
|
917
|
+
readonly maximumAccessLifetimeMillis: number;
|
|
918
|
+
readonly maximumRefreshLifetimeMillis?: number | undefined;
|
|
919
|
+
readonly refreshAheadMillis: number;
|
|
920
|
+
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
921
|
+
readonly revocation: "cohort" | "unsupported";
|
|
922
|
+
};
|
|
923
|
+
};
|
|
924
|
+
readonly grantId: string & import("effect/Brand").Brand<"effect-auth/OAuthGrantId">;
|
|
925
|
+
readonly grantVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
926
|
+
readonly tokenVersion: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
927
|
+
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
928
|
+
readonly metadata: {
|
|
929
|
+
readonly scopes: readonly string[];
|
|
930
|
+
readonly resources: readonly string[];
|
|
931
|
+
readonly accessExpiresAtMillis?: number | undefined;
|
|
932
|
+
readonly refreshExpiresAtMillis?: number | undefined;
|
|
933
|
+
readonly useUntilMillis: number;
|
|
934
|
+
readonly refreshUseUntilMillis?: number | undefined;
|
|
935
|
+
readonly obtainedAtMillis: number;
|
|
936
|
+
readonly profile?: {
|
|
937
|
+
readonly displayName?: string | undefined;
|
|
938
|
+
readonly handle?: string | undefined;
|
|
939
|
+
readonly avatarUrl?: string | undefined;
|
|
940
|
+
readonly profileUrl?: string | undefined;
|
|
941
|
+
readonly email?: string | undefined;
|
|
942
|
+
readonly emailVerified?: boolean | undefined;
|
|
943
|
+
readonly providerData?: {
|
|
944
|
+
readonly [x: string]: import("effect/Schema").Json;
|
|
945
|
+
} | undefined;
|
|
946
|
+
} | undefined;
|
|
947
|
+
};
|
|
948
|
+
};
|
|
949
|
+
readonly sealed: {
|
|
950
|
+
readonly format: "oauth-connected-xchacha20poly1305-v1";
|
|
951
|
+
readonly keyId: string;
|
|
952
|
+
readonly nonce: string;
|
|
953
|
+
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
954
|
+
};
|
|
955
|
+
};
|
|
956
|
+
} | {
|
|
957
|
+
readonly _tag: "Busy";
|
|
958
|
+
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
906
959
|
readonly capture: (input: {
|
|
907
960
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
908
961
|
readonly subjectId: import("@yielded/auth/Schema").SubjectId;
|
|
@@ -915,6 +968,8 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
915
968
|
readonly flow: import("@yielded/auth/OAuth").OAuthConnectedPendingFlow;
|
|
916
969
|
readonly authorization: import("@yielded/auth/OAuth").OAuthConnectedActionAuthorization;
|
|
917
970
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
971
|
+
readonly _tag: "Rejected";
|
|
972
|
+
} | {
|
|
918
973
|
readonly _tag: "Issued";
|
|
919
974
|
readonly flow: {
|
|
920
975
|
readonly context: {
|
|
@@ -929,6 +984,21 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
929
984
|
readonly generation: number;
|
|
930
985
|
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
931
986
|
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
987
|
+
readonly access?: {
|
|
988
|
+
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
989
|
+
readonly generation: number;
|
|
990
|
+
readonly issuance: "active" | "retired";
|
|
991
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
992
|
+
readonly clientRegistrationId: string;
|
|
993
|
+
readonly scopes: readonly string[];
|
|
994
|
+
readonly resources: readonly string[];
|
|
995
|
+
readonly retention: "access-and-refresh" | "access-only";
|
|
996
|
+
readonly maximumAccessLifetimeMillis: number;
|
|
997
|
+
readonly maximumRefreshLifetimeMillis?: number | undefined;
|
|
998
|
+
readonly refreshAheadMillis: number;
|
|
999
|
+
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1000
|
+
readonly revocation: "cohort" | "unsupported";
|
|
1001
|
+
} | undefined;
|
|
932
1002
|
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
933
1003
|
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
934
1004
|
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
@@ -1006,8 +1076,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1006
1076
|
};
|
|
1007
1077
|
readonly retentionUntilMillis: number;
|
|
1008
1078
|
};
|
|
1009
|
-
} | {
|
|
1010
|
-
readonly _tag: "Rejected";
|
|
1011
1079
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1012
1080
|
readonly preflight: (input: import("@yielded/auth/OAuth").OAuthConnectedAccess) => Effect.Effect<import("@yielded/auth/OAuth").OAuthConnectedPendingFlow | undefined, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1013
1081
|
readonly claim: <A>(input: {
|
|
@@ -1033,6 +1101,21 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1033
1101
|
readonly generation: number;
|
|
1034
1102
|
readonly flowId: string & import("effect/Brand").Brand<"effect-auth/RequestBindingFlowId">;
|
|
1035
1103
|
readonly commandId: string & import("effect/Brand").Brand<"effect-auth/OAuthCommandId">;
|
|
1104
|
+
readonly access?: {
|
|
1105
|
+
readonly key: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1106
|
+
readonly generation: number;
|
|
1107
|
+
readonly issuance: "active" | "retired";
|
|
1108
|
+
readonly provider: string & import("effect/Brand").Brand<"effect-auth/OAuthProviderKey">;
|
|
1109
|
+
readonly clientRegistrationId: string;
|
|
1110
|
+
readonly scopes: readonly string[];
|
|
1111
|
+
readonly resources: readonly string[];
|
|
1112
|
+
readonly retention: "access-and-refresh" | "access-only";
|
|
1113
|
+
readonly maximumAccessLifetimeMillis: number;
|
|
1114
|
+
readonly maximumRefreshLifetimeMillis?: number | undefined;
|
|
1115
|
+
readonly refreshAheadMillis: number;
|
|
1116
|
+
readonly refresh: "confidential" | "rotating" | "unsupported";
|
|
1117
|
+
readonly revocation: "cohort" | "unsupported";
|
|
1118
|
+
} | undefined;
|
|
1036
1119
|
readonly returnTarget: string & import("effect/Brand").Brand<"effect-auth/OAuthReturnTarget">;
|
|
1037
1120
|
readonly stateDigest: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
1038
1121
|
readonly requestBindingVerifier: string & import("effect/Brand").Brand<"effect-auth/TokenDigest">;
|
|
@@ -1125,14 +1208,14 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1125
1208
|
};
|
|
1126
1209
|
}) => Effect.Effect<{
|
|
1127
1210
|
readonly _tag: "Rejected";
|
|
1211
|
+
} | {
|
|
1212
|
+
readonly _tag: "Conflict";
|
|
1128
1213
|
} | {
|
|
1129
1214
|
readonly _tag: "Target";
|
|
1130
1215
|
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1131
1216
|
} | {
|
|
1132
1217
|
readonly _tag: "Quarantine";
|
|
1133
1218
|
readonly cohortGeneration: string & import("effect/Brand").Brand<"effect-auth/SecurityRevision">;
|
|
1134
|
-
} | {
|
|
1135
|
-
readonly _tag: "Conflict";
|
|
1136
1219
|
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1137
1220
|
readonly settle: <A>(input: {
|
|
1138
1221
|
readonly claim: import("@yielded/auth/OAuth").OAuthConnectedClaim;
|
|
@@ -1141,17 +1224,18 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1141
1224
|
readonly nowMillis: number;
|
|
1142
1225
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1143
1226
|
readonly _tag: "Rejected";
|
|
1144
|
-
} | {
|
|
1145
|
-
readonly _tag: "Conflict";
|
|
1146
1227
|
} | {
|
|
1147
1228
|
readonly _tag: "Cancelled";
|
|
1148
1229
|
} | {
|
|
1149
1230
|
readonly _tag: "Ambiguous";
|
|
1231
|
+
} | {
|
|
1232
|
+
readonly _tag: "Conflict";
|
|
1150
1233
|
} | {
|
|
1151
1234
|
readonly _tag: "Connected";
|
|
1152
1235
|
readonly grant: {
|
|
1153
1236
|
readonly context: {
|
|
1154
1237
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1238
|
+
readonly exchangeOrder: string;
|
|
1155
1239
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1156
1240
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1157
1241
|
readonly identity: {
|
|
@@ -1262,6 +1346,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1262
1346
|
readonly grant: {
|
|
1263
1347
|
readonly context: {
|
|
1264
1348
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1349
|
+
readonly exchangeOrder: string;
|
|
1265
1350
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1266
1351
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1267
1352
|
readonly identity: {
|
|
@@ -1374,6 +1459,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1374
1459
|
readonly grant: {
|
|
1375
1460
|
readonly context: {
|
|
1376
1461
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1462
|
+
readonly exchangeOrder: string;
|
|
1377
1463
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1378
1464
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1379
1465
|
readonly identity: {
|
|
@@ -1458,6 +1544,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1458
1544
|
readonly grant: {
|
|
1459
1545
|
readonly context: {
|
|
1460
1546
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1547
|
+
readonly exchangeOrder: string;
|
|
1461
1548
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1462
1549
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1463
1550
|
readonly identity: {
|
|
@@ -1521,6 +1608,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1521
1608
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1522
1609
|
};
|
|
1523
1610
|
};
|
|
1611
|
+
readonly order: string;
|
|
1524
1612
|
readonly claimId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1525
1613
|
readonly claimedAtMillis: number;
|
|
1526
1614
|
readonly claimExpiresAtMillis: number;
|
|
@@ -1540,6 +1628,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1540
1628
|
readonly grant: {
|
|
1541
1629
|
readonly context: {
|
|
1542
1630
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1631
|
+
readonly exchangeOrder: string;
|
|
1543
1632
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1544
1633
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1545
1634
|
readonly identity: {
|
|
@@ -1629,7 +1718,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1629
1718
|
readonly hasMore: boolean;
|
|
1630
1719
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
1631
1720
|
};
|
|
1632
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthConnectedRevocationServices: <T extends AnySQLiteTable<{
|
|
1721
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, makeOAuthConnectedRevocationServices: <T extends AnySQLiteTable<{
|
|
1633
1722
|
dialect: "sqlite";
|
|
1634
1723
|
}>, O extends AnySQLiteTable<{
|
|
1635
1724
|
dialect: "sqlite";
|
|
@@ -1643,7 +1732,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1643
1732
|
dialect: "sqlite";
|
|
1644
1733
|
}>, J extends AnySQLiteTable<{
|
|
1645
1734
|
dialect: "sqlite";
|
|
1646
|
-
}>, N>(
|
|
1735
|
+
}>, N>(mapping: OAuthConnectedRevocationMapping<T, O, F, G, C, H, J, N>) => Effect.Effect<{
|
|
1647
1736
|
oauthConnectedRevocations: {
|
|
1648
1737
|
readonly claim: <A>(input: {
|
|
1649
1738
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
@@ -1658,6 +1747,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1658
1747
|
readonly jobId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
|
1659
1748
|
readonly token: {
|
|
1660
1749
|
readonly namespace: "effect-auth/oauth-connected-token-context/v1";
|
|
1750
|
+
readonly exchangeOrder: string;
|
|
1661
1751
|
readonly moduleId: string & import("effect/Brand").Brand<"effect-auth/OAuthModuleId">;
|
|
1662
1752
|
readonly subjectId: string & import("effect/Brand").Brand<"effect-auth/SubjectId">;
|
|
1663
1753
|
readonly identity: {
|
|
@@ -1736,7 +1826,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1736
1826
|
readonly settled: boolean;
|
|
1737
1827
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1738
1828
|
};
|
|
1739
|
-
}, never, import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthConnected: {
|
|
1829
|
+
}, never, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinateOAuthConnected: {
|
|
1740
1830
|
<D extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
1741
1831
|
dialect: "sqlite";
|
|
1742
1832
|
}>, AC extends AnySQLiteTable<{
|
|
@@ -1831,7 +1921,7 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1831
1921
|
} ? Parameters<Parameters<D["transaction"]>[0]>[0] : never>, TxShape>;
|
|
1832
1922
|
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/OAuth").OAuthConnectedRevocations>>): Effect.Effect<A, DatabaseError | OAuthCoordinatorError<E>, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
1833
1923
|
};
|
|
1834
|
-
export declare const makePasskeyCredentialServices: <
|
|
1924
|
+
export declare const makePasskeyCredentialServices: <S extends AnySQLiteTable<{
|
|
1835
1925
|
dialect: "sqlite";
|
|
1836
1926
|
}>, C extends AnySQLiteTable<{
|
|
1837
1927
|
dialect: "sqlite";
|
|
@@ -1841,7 +1931,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1841
1931
|
dialect: "sqlite";
|
|
1842
1932
|
}>, H extends AnySQLiteTable<{
|
|
1843
1933
|
dialect: "sqlite";
|
|
1844
|
-
}>, N, RSetup = never>(
|
|
1934
|
+
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyCredentialMapping<S, C, F, O, H, N>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyCredentialServices, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | Exclude<RSetup, NativeDatabase>>, makePasskeyPersistenceServices: <S extends AnySQLiteTable<{
|
|
1845
1935
|
dialect: "sqlite";
|
|
1846
1936
|
}>, C extends AnySQLiteTable<{
|
|
1847
1937
|
dialect: "sqlite";
|
|
@@ -1859,7 +1949,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1859
1949
|
dialect: "sqlite";
|
|
1860
1950
|
}>, Charge extends AnySQLiteTable<{
|
|
1861
1951
|
dialect: "sqlite";
|
|
1862
|
-
}>, N, RSetup = never>(
|
|
1952
|
+
}>, 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, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, makePasskeyEnrollmentContextServices: <S extends AnySQLiteTable<{
|
|
1863
1953
|
dialect: "sqlite";
|
|
1864
1954
|
}>, C extends AnySQLiteTable<{
|
|
1865
1955
|
dialect: "sqlite";
|
|
@@ -1871,7 +1961,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1871
1961
|
dialect: "sqlite";
|
|
1872
1962
|
}>, M extends AnySQLiteTable<{
|
|
1873
1963
|
dialect: "sqlite";
|
|
1874
|
-
}>, N, RSetup = never>(
|
|
1964
|
+
}>, 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, Database | Exclude<RSetup, NativeDatabase>>, makePasskeyRegistrationCeremonyServices: <M extends AnySQLiteTable<{
|
|
1875
1965
|
dialect: "sqlite";
|
|
1876
1966
|
}>, Flow extends AnySQLiteTable<{
|
|
1877
1967
|
dialect: "sqlite";
|
|
@@ -1883,7 +1973,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1883
1973
|
dialect: "sqlite";
|
|
1884
1974
|
}>, H extends AnySQLiteTable<{
|
|
1885
1975
|
dialect: "sqlite";
|
|
1886
|
-
}>, RSetup = never>(
|
|
1976
|
+
}>, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationCeremonyMapping<M, Flow, Admission, Charge, Intent, H>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyRegistrationCeremonyServices, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePasskeyPersistence: {
|
|
1887
1977
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
1888
1978
|
dialect: "sqlite";
|
|
1889
1979
|
}>, C extends AnySQLiteTable<{
|
|
@@ -1965,7 +2055,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1965
2055
|
readonly transaction: (...args: any[]) => any;
|
|
1966
2056
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
1967
2057
|
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Passkey").PasskeyPersistence>>): Effect.Effect<A, DatabaseError | import("@yielded/auth-persistence/Adapter").PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
1968
|
-
}, makePasskeyManagementServices: <
|
|
2058
|
+
}, makePasskeyManagementServices: <S extends AnySQLiteTable<{
|
|
1969
2059
|
dialect: "sqlite";
|
|
1970
2060
|
}>, C extends AnySQLiteTable<{
|
|
1971
2061
|
dialect: "sqlite";
|
|
@@ -1985,7 +2075,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
1985
2075
|
dialect: "sqlite";
|
|
1986
2076
|
}>, Command extends AnySQLiteTable<{
|
|
1987
2077
|
dialect: "sqlite";
|
|
1988
|
-
}>, N, RSetup = never>(
|
|
2078
|
+
}>, N, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyManagementMapping<S, C, F, O, H, M, Flow, Admission, Charge, Command, N>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyManagementServices, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, makePasskeyRegistrationServices: <S extends AnySQLiteTable<{
|
|
1989
2079
|
dialect: "sqlite";
|
|
1990
2080
|
}>, C extends AnySQLiteTable<{
|
|
1991
2081
|
dialect: "sqlite";
|
|
@@ -2005,7 +2095,7 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
2005
2095
|
dialect: "sqlite";
|
|
2006
2096
|
}>, Intent extends AnySQLiteTable<{
|
|
2007
2097
|
dialect: "sqlite";
|
|
2008
|
-
}>, N, Value, RSetup = never>(
|
|
2098
|
+
}>, N, Value, RSetup = never>(mapping: import("@yielded/auth-persistence/Adapter").PasskeyMappingSource<PasskeyRegistrationMapping<S, C, F, O, H, M, Flow, Admission, Charge, Intent, N, Value>, RSetup>) => Effect.Effect<import("@yielded/auth-persistence/Adapter").PasskeyRegistrationServices<Value>, import("@yielded/auth/Passkey").PasskeyConfigurationError | import("@yielded/auth-persistence/Adapter").PersistenceMappingError, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePasskeyManagement: {
|
|
2009
2099
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2010
2100
|
dialect: "sqlite";
|
|
2011
2101
|
}>, C extends AnySQLiteTable<{
|
|
@@ -2110,13 +2200,13 @@ export declare const makePasskeyCredentialServices: <Database extends EffectSQLi
|
|
|
2110
2200
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2111
2201
|
}, body: Effect.Effect<A, E, NoInfer<AuthorityId | TxId | import("@yielded/auth/Passkey").PasskeyPersistence>>): Effect.Effect<A, DatabaseError | import("@yielded/auth-persistence/Adapter").PasskeyCoordinatorError<E>, DatabaseRequirements | RSetup | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
2112
2202
|
};
|
|
2113
|
-
export declare const makeTotpPersistenceServices: <
|
|
2203
|
+
export declare const makeTotpPersistenceServices: <S extends AnySQLiteTable<{
|
|
2114
2204
|
dialect: "sqlite";
|
|
2115
2205
|
}>, F extends AnySQLiteTable<{
|
|
2116
2206
|
dialect: "sqlite";
|
|
2117
2207
|
}>, C extends AnySQLiteTable<{
|
|
2118
2208
|
dialect: "sqlite";
|
|
2119
|
-
}>, N, RSetup = never>(
|
|
2209
|
+
}>, 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, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinateTotpPersistence: {
|
|
2120
2210
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2121
2211
|
dialect: "sqlite";
|
|
2122
2212
|
}>, F extends AnySQLiteTable<{
|
|
@@ -2140,7 +2230,7 @@ export declare const makeTotpPersistenceServices: <Database extends EffectSQLite
|
|
|
2140
2230
|
} ? Parameters<Parameters<Database["transaction"]>[0]>[0] : never>, TxShape>;
|
|
2141
2231
|
}, body: Effect.Effect<A, E, NoInfer<TxId | import("@yielded/auth/Totp").TotpPersistence>>): Effect.Effect<A, DatabaseError | TotpCoordinatorError<E>, DatabaseRequirements | RSetup | import("@yielded/auth/Hooks").LifecycleHooks>;
|
|
2142
2232
|
};
|
|
2143
|
-
export declare const makePhonePersistenceServices: <
|
|
2233
|
+
export declare const makePhonePersistenceServices: <S extends AnySQLiteTable<{
|
|
2144
2234
|
dialect: "sqlite";
|
|
2145
2235
|
}>, I extends AnySQLiteTable<{
|
|
2146
2236
|
dialect: "sqlite";
|
|
@@ -2148,7 +2238,7 @@ export declare const makePhonePersistenceServices: <Database extends EffectSQLit
|
|
|
2148
2238
|
dialect: "sqlite";
|
|
2149
2239
|
}>, C extends AnySQLiteTable<{
|
|
2150
2240
|
dialect: "sqlite";
|
|
2151
|
-
}>, N, RSetup = never>(
|
|
2241
|
+
}>, 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, Database | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<RSetup, NativeDatabase>>, coordinatePhonePersistence: {
|
|
2152
2242
|
<Database extends EffectSQLiteDoDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable<{
|
|
2153
2243
|
dialect: "sqlite";
|
|
2154
2244
|
}>, I extends AnySQLiteTable<{
|