@yielded/auth-persistence-drizzle 0.1.0-beta.21 → 0.1.0-beta.23
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/dist/Libsql.d.mts +19 -19
- package/dist/Mysql2.d.mts +14 -14
- package/dist/Pglite.d.mts +14 -14
- package/dist/Postgres.d.mts +6 -6
- package/dist/SqliteBun.d.mts +27 -27
- package/dist/SqliteDo.d.mts +13 -13
- package/dist/SqliteNode.d.mts +23 -23
- package/dist/SqliteWasm.d.mts +13 -13
- package/dist/drizzle/d1-password-prepared.d.mts +3 -3
- package/dist/drizzle/d1-password-prepared.mjs.map +1 -1
- package/dist/drizzle/d1-passwords.d.mts +8 -9
- package/dist/drizzle/d1-passwords.mjs +103 -173
- package/dist/drizzle/d1-passwords.mjs.map +1 -1
- package/dist/drizzle/d1-proofs.d.mts +1 -1
- package/dist/drizzle/d1-sessions.d.mts +1 -1
- package/dist/drizzle/mysql-password-prepared.d.mts +5 -5
- package/dist/drizzle/mysql-password-prepared.mjs.map +1 -1
- package/dist/drizzle/mysql-passwords.d.mts +9 -9
- package/dist/drizzle/mysql-passwords.mjs.map +1 -1
- package/dist/drizzle/native-sql-table.mjs +110 -0
- package/dist/drizzle/native-sql-table.mjs.map +1 -0
- package/dist/drizzle/oauth-connected-target.d.mts +5 -5
- package/dist/drizzle/oauth-target.d.mts +1 -1
- package/dist/drizzle/password-model.d.mts +5 -7
- package/dist/drizzle/password-prepared-model.d.mts +5 -5
- package/dist/drizzle/password-prepared-model.mjs.map +1 -1
- package/dist/drizzle/password-sql.mjs +2 -1
- package/dist/drizzle/password-sql.mjs.map +1 -1
- package/dist/drizzle/password-target.mjs +13 -2
- package/dist/drizzle/password-target.mjs.map +1 -1
- package/dist/drizzle/pg-password-prepared.d.mts +5 -5
- package/dist/drizzle/pg-password-prepared.mjs.map +1 -1
- package/dist/drizzle/pg-passwords.d.mts +9 -9
- package/dist/drizzle/pg-passwords.mjs.map +1 -1
- package/dist/drizzle/phone-target.d.mts +1 -1
- package/dist/drizzle/session-sql.mjs +2 -1
- package/dist/drizzle/session-sql.mjs.map +1 -1
- package/dist/drizzle/sqlite-password-prepared.mjs.map +1 -1
- package/dist/drizzle/sqlite-passwords.mjs.map +1 -1
- package/dist/drizzle/storage-validation.mjs +0 -13
- package/dist/drizzle/storage-validation.mjs.map +1 -1
- package/dist/drizzle/totp-target.d.mts +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/internal/drizzle-postgres.mjs +2 -0
- package/dist/internal/drizzle-postgres.mjs.map +1 -1
- package/dist/internal/drizzle-sqlite.mjs +2 -0
- package/dist/internal/drizzle-sqlite.mjs.map +1 -1
- package/package.json +1 -1
- package/src/drizzle/d1-password-prepared.ts +2 -20
- package/src/drizzle/d1-passwords.ts +232 -519
- package/src/drizzle/mysql-password-prepared.ts +4 -12
- package/src/drizzle/mysql-passwords.ts +5 -15
- package/src/drizzle/native-sql-table.ts +229 -0
- package/src/drizzle/password-model.ts +0 -20
- package/src/drizzle/password-prepared-model.ts +0 -12
- package/src/drizzle/password-sql.ts +3 -0
- package/src/drizzle/password-target.ts +41 -4
- package/src/drizzle/pg-password-prepared.ts +4 -12
- package/src/drizzle/pg-passwords.ts +5 -15
- package/src/drizzle/session-sql.ts +2 -1
- package/src/drizzle/sqlite-password-prepared.ts +4 -48
- package/src/drizzle/sqlite-passwords.ts +7 -21
- package/src/drizzle/storage-validation.ts +0 -8
- package/src/index.ts +0 -4
- package/src/internal/drizzle-postgres.ts +2 -0
- package/src/internal/drizzle-sqlite.ts +2 -0
package/dist/Libsql.d.mts
CHANGED
|
@@ -88,13 +88,13 @@ export declare const coordinateEmailAddress: {
|
|
|
88
88
|
};
|
|
89
89
|
}, EmailUnavailable, Database>;
|
|
90
90
|
export declare const coordinatePasswordPersistence: {
|
|
91
|
-
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
92
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
91
|
+
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
92
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
93
93
|
readonly proofMapping?: PM;
|
|
94
94
|
readonly transaction?: never;
|
|
95
95
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Password").PasswordPersistence>>;
|
|
96
|
-
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
97
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
96
|
+
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
97
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
98
98
|
readonly proofMapping?: PM;
|
|
99
99
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
100
100
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Password").PasswordPersistence>>;
|
|
@@ -109,15 +109,15 @@ export declare const coordinatePasswordPersistence: {
|
|
|
109
109
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
110
110
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
111
111
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
112
|
-
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
112
|
+
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>, proofMapping?: ProofPersistenceMapping<any, any, any, any, any, any, any, any, any, any, any, any>) => Effect.Effect<{
|
|
113
113
|
passwordPersistence: {
|
|
114
|
-
readonly
|
|
114
|
+
readonly prepareAttempt: (input: {
|
|
115
115
|
readonly moduleId: string;
|
|
116
116
|
readonly action: "sign-in" | "change";
|
|
117
117
|
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
118
118
|
readonly subjectId?: import("@yielded/auth/Schema").SubjectId;
|
|
119
|
-
readonly
|
|
120
|
-
}
|
|
119
|
+
readonly attemptLifetimeMillis: number;
|
|
120
|
+
}) => Effect.Effect<import("@yielded/auth/Password").PasswordAttemptPreparation, PasswordUnavailable>;
|
|
121
121
|
readonly settleAttempt: <A_1>(input: {
|
|
122
122
|
readonly moduleId: string;
|
|
123
123
|
readonly attemptId: import("@yielded/auth/Password").PasswordAttemptId;
|
|
@@ -310,17 +310,17 @@ export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTab
|
|
|
310
310
|
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>;
|
|
311
311
|
};
|
|
312
312
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
313
|
-
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
313
|
+
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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, M, T, B, NativeId>, proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined) => Effect.Effect<{
|
|
314
314
|
passwordPreparedPersistence: import("@yielded/auth/Password").PasswordPreparedPersistence;
|
|
315
315
|
}, PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
316
|
-
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
317
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
316
|
+
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
317
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
318
318
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
319
319
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
320
320
|
readonly transaction?: never;
|
|
321
321
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
322
|
-
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
323
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
322
|
+
<Database extends EffectLibsqlDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
323
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
324
324
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
325
325
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
326
326
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
@@ -486,10 +486,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
486
486
|
readonly nowMillis: number;
|
|
487
487
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
488
488
|
readonly _tag: "Rejected";
|
|
489
|
-
} | {
|
|
490
|
-
readonly _tag: "Cancelled";
|
|
491
489
|
} | {
|
|
492
490
|
readonly _tag: "Ambiguous";
|
|
491
|
+
} | {
|
|
492
|
+
readonly _tag: "Cancelled";
|
|
493
493
|
} | {
|
|
494
494
|
readonly _tag: "Conflict";
|
|
495
495
|
} | {
|
|
@@ -859,10 +859,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
859
859
|
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
860
860
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
861
861
|
readonly _tag: "Rejected";
|
|
862
|
-
} | {
|
|
863
|
-
readonly _tag: "Cancelled";
|
|
864
862
|
} | {
|
|
865
863
|
readonly _tag: "Ambiguous";
|
|
864
|
+
} | {
|
|
865
|
+
readonly _tag: "Cancelled";
|
|
866
866
|
} | {
|
|
867
867
|
readonly _tag: "Connected";
|
|
868
868
|
readonly grant: {
|
|
@@ -1319,10 +1319,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1319
1319
|
readonly nowMillis: number;
|
|
1320
1320
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1321
1321
|
readonly _tag: "Rejected";
|
|
1322
|
-
} | {
|
|
1323
|
-
readonly _tag: "Cancelled";
|
|
1324
1322
|
} | {
|
|
1325
1323
|
readonly _tag: "Ambiguous";
|
|
1324
|
+
} | {
|
|
1325
|
+
readonly _tag: "Cancelled";
|
|
1326
1326
|
} | {
|
|
1327
1327
|
readonly _tag: "Connected";
|
|
1328
1328
|
readonly grant: {
|
package/dist/Mysql2.d.mts
CHANGED
|
@@ -201,10 +201,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
201
201
|
readonly nowMillis: number;
|
|
202
202
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
203
203
|
readonly _tag: "Rejected";
|
|
204
|
-
} | {
|
|
205
|
-
readonly _tag: "Cancelled";
|
|
206
204
|
} | {
|
|
207
205
|
readonly _tag: "Ambiguous";
|
|
206
|
+
} | {
|
|
207
|
+
readonly _tag: "Cancelled";
|
|
208
208
|
} | {
|
|
209
209
|
readonly _tag: "Conflict";
|
|
210
210
|
} | {
|
|
@@ -574,10 +574,12 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
574
574
|
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
575
575
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
576
576
|
readonly _tag: "Rejected";
|
|
577
|
+
} | {
|
|
578
|
+
readonly _tag: "Ambiguous";
|
|
577
579
|
} | {
|
|
578
580
|
readonly _tag: "Cancelled";
|
|
579
581
|
} | {
|
|
580
|
-
readonly _tag: "
|
|
582
|
+
readonly _tag: "Conflict";
|
|
581
583
|
} | {
|
|
582
584
|
readonly _tag: "Connected";
|
|
583
585
|
readonly grant: {
|
|
@@ -647,8 +649,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
647
649
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
648
650
|
};
|
|
649
651
|
};
|
|
650
|
-
} | {
|
|
651
|
-
readonly _tag: "Conflict";
|
|
652
652
|
} | {
|
|
653
653
|
readonly _tag: "Busy";
|
|
654
654
|
}, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1034,10 +1034,12 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1034
1034
|
readonly nowMillis: number;
|
|
1035
1035
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1036
1036
|
readonly _tag: "Rejected";
|
|
1037
|
+
} | {
|
|
1038
|
+
readonly _tag: "Ambiguous";
|
|
1037
1039
|
} | {
|
|
1038
1040
|
readonly _tag: "Cancelled";
|
|
1039
1041
|
} | {
|
|
1040
|
-
readonly _tag: "
|
|
1042
|
+
readonly _tag: "Conflict";
|
|
1041
1043
|
} | {
|
|
1042
1044
|
readonly _tag: "Connected";
|
|
1043
1045
|
readonly grant: {
|
|
@@ -1107,8 +1109,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1107
1109
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1108
1110
|
};
|
|
1109
1111
|
};
|
|
1110
|
-
} | {
|
|
1111
|
-
readonly _tag: "Conflict";
|
|
1112
1112
|
} | {
|
|
1113
1113
|
readonly _tag: "Busy";
|
|
1114
1114
|
}, A>) => import("effect/Effect").Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1262,6 +1262,8 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1262
1262
|
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1263
1263
|
}) => import("effect/Effect").Effect<{
|
|
1264
1264
|
readonly _tag: "Rejected";
|
|
1265
|
+
} | {
|
|
1266
|
+
readonly _tag: "ReauthorizationRequired";
|
|
1265
1267
|
} | {
|
|
1266
1268
|
readonly _tag: "Busy";
|
|
1267
1269
|
} | {
|
|
@@ -1333,8 +1335,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1333
1335
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1334
1336
|
};
|
|
1335
1337
|
};
|
|
1336
|
-
} | {
|
|
1337
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1338
1338
|
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1339
1339
|
readonly claimRefresh: <A>(input: {
|
|
1340
1340
|
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
@@ -1344,10 +1344,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1344
1344
|
readonly lifetimeMillis: number;
|
|
1345
1345
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1346
1346
|
readonly _tag: "Rejected";
|
|
1347
|
-
} | {
|
|
1348
|
-
readonly _tag: "Busy";
|
|
1349
1347
|
} | {
|
|
1350
1348
|
readonly _tag: "ReauthorizationRequired";
|
|
1349
|
+
} | {
|
|
1350
|
+
readonly _tag: "Busy";
|
|
1351
1351
|
} | {
|
|
1352
1352
|
readonly _tag: "Claimed";
|
|
1353
1353
|
readonly claim: {
|
|
@@ -1510,10 +1510,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyMySqlTable<{
|
|
|
1510
1510
|
readonly lifetimeMillis: number;
|
|
1511
1511
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1512
1512
|
readonly _tag: "Rejected";
|
|
1513
|
-
} | {
|
|
1514
|
-
readonly _tag: "Busy";
|
|
1515
1513
|
} | {
|
|
1516
1514
|
readonly _tag: "ReauthorizationRequired";
|
|
1515
|
+
} | {
|
|
1516
|
+
readonly _tag: "Busy";
|
|
1517
1517
|
} | {
|
|
1518
1518
|
readonly _tag: "Admitted";
|
|
1519
1519
|
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
package/dist/Pglite.d.mts
CHANGED
|
@@ -201,10 +201,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
201
201
|
readonly nowMillis: number;
|
|
202
202
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
203
203
|
readonly _tag: "Rejected";
|
|
204
|
-
} | {
|
|
205
|
-
readonly _tag: "Cancelled";
|
|
206
204
|
} | {
|
|
207
205
|
readonly _tag: "Ambiguous";
|
|
206
|
+
} | {
|
|
207
|
+
readonly _tag: "Cancelled";
|
|
208
208
|
} | {
|
|
209
209
|
readonly _tag: "Conflict";
|
|
210
210
|
} | {
|
|
@@ -574,10 +574,12 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
574
574
|
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
575
575
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
576
576
|
readonly _tag: "Rejected";
|
|
577
|
+
} | {
|
|
578
|
+
readonly _tag: "Ambiguous";
|
|
577
579
|
} | {
|
|
578
580
|
readonly _tag: "Cancelled";
|
|
579
581
|
} | {
|
|
580
|
-
readonly _tag: "
|
|
582
|
+
readonly _tag: "Conflict";
|
|
581
583
|
} | {
|
|
582
584
|
readonly _tag: "Connected";
|
|
583
585
|
readonly grant: {
|
|
@@ -647,8 +649,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
647
649
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
648
650
|
};
|
|
649
651
|
};
|
|
650
|
-
} | {
|
|
651
|
-
readonly _tag: "Conflict";
|
|
652
652
|
} | {
|
|
653
653
|
readonly _tag: "Busy";
|
|
654
654
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1034,10 +1034,12 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1034
1034
|
readonly nowMillis: number;
|
|
1035
1035
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1036
1036
|
readonly _tag: "Rejected";
|
|
1037
|
+
} | {
|
|
1038
|
+
readonly _tag: "Ambiguous";
|
|
1037
1039
|
} | {
|
|
1038
1040
|
readonly _tag: "Cancelled";
|
|
1039
1041
|
} | {
|
|
1040
|
-
readonly _tag: "
|
|
1042
|
+
readonly _tag: "Conflict";
|
|
1041
1043
|
} | {
|
|
1042
1044
|
readonly _tag: "Connected";
|
|
1043
1045
|
readonly grant: {
|
|
@@ -1107,8 +1109,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1107
1109
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1108
1110
|
};
|
|
1109
1111
|
};
|
|
1110
|
-
} | {
|
|
1111
|
-
readonly _tag: "Conflict";
|
|
1112
1112
|
} | {
|
|
1113
1113
|
readonly _tag: "Busy";
|
|
1114
1114
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1262,6 +1262,8 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1262
1262
|
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1263
1263
|
}) => Effect.Effect<{
|
|
1264
1264
|
readonly _tag: "Rejected";
|
|
1265
|
+
} | {
|
|
1266
|
+
readonly _tag: "ReauthorizationRequired";
|
|
1265
1267
|
} | {
|
|
1266
1268
|
readonly _tag: "Busy";
|
|
1267
1269
|
} | {
|
|
@@ -1333,8 +1335,6 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1333
1335
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1334
1336
|
};
|
|
1335
1337
|
};
|
|
1336
|
-
} | {
|
|
1337
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1338
1338
|
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1339
1339
|
readonly claimRefresh: <A>(input: {
|
|
1340
1340
|
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
@@ -1344,10 +1344,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1344
1344
|
readonly lifetimeMillis: number;
|
|
1345
1345
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1346
1346
|
readonly _tag: "Rejected";
|
|
1347
|
-
} | {
|
|
1348
|
-
readonly _tag: "Busy";
|
|
1349
1347
|
} | {
|
|
1350
1348
|
readonly _tag: "ReauthorizationRequired";
|
|
1349
|
+
} | {
|
|
1350
|
+
readonly _tag: "Busy";
|
|
1351
1351
|
} | {
|
|
1352
1352
|
readonly _tag: "Claimed";
|
|
1353
1353
|
readonly claim: {
|
|
@@ -1510,10 +1510,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1510
1510
|
readonly lifetimeMillis: number;
|
|
1511
1511
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1512
1512
|
readonly _tag: "Rejected";
|
|
1513
|
-
} | {
|
|
1514
|
-
readonly _tag: "Busy";
|
|
1515
1513
|
} | {
|
|
1516
1514
|
readonly _tag: "ReauthorizationRequired";
|
|
1515
|
+
} | {
|
|
1516
|
+
readonly _tag: "Busy";
|
|
1517
1517
|
} | {
|
|
1518
1518
|
readonly _tag: "Admitted";
|
|
1519
1519
|
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
package/dist/Postgres.d.mts
CHANGED
|
@@ -201,10 +201,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
201
201
|
readonly nowMillis: number;
|
|
202
202
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
203
203
|
readonly _tag: "Rejected";
|
|
204
|
-
} | {
|
|
205
|
-
readonly _tag: "Cancelled";
|
|
206
204
|
} | {
|
|
207
205
|
readonly _tag: "Ambiguous";
|
|
206
|
+
} | {
|
|
207
|
+
readonly _tag: "Cancelled";
|
|
208
208
|
} | {
|
|
209
209
|
readonly _tag: "Conflict";
|
|
210
210
|
} | {
|
|
@@ -574,10 +574,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
574
574
|
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
575
575
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
576
576
|
readonly _tag: "Rejected";
|
|
577
|
-
} | {
|
|
578
|
-
readonly _tag: "Cancelled";
|
|
579
577
|
} | {
|
|
580
578
|
readonly _tag: "Ambiguous";
|
|
579
|
+
} | {
|
|
580
|
+
readonly _tag: "Cancelled";
|
|
581
581
|
} | {
|
|
582
582
|
readonly _tag: "Connected";
|
|
583
583
|
readonly grant: {
|
|
@@ -1034,10 +1034,10 @@ export declare const makeOAuthAccountsServices: <S extends AnyPgTable<{
|
|
|
1034
1034
|
readonly nowMillis: number;
|
|
1035
1035
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1036
1036
|
readonly _tag: "Rejected";
|
|
1037
|
-
} | {
|
|
1038
|
-
readonly _tag: "Cancelled";
|
|
1039
1037
|
} | {
|
|
1040
1038
|
readonly _tag: "Ambiguous";
|
|
1039
|
+
} | {
|
|
1040
|
+
readonly _tag: "Cancelled";
|
|
1041
1041
|
} | {
|
|
1042
1042
|
readonly _tag: "Connected";
|
|
1043
1043
|
readonly grant: {
|
package/dist/SqliteBun.d.mts
CHANGED
|
@@ -84,13 +84,13 @@ export declare const coordinateEmailAddress: {
|
|
|
84
84
|
};
|
|
85
85
|
}, import("@yielded/auth/Email").EmailUnavailable, Database>;
|
|
86
86
|
export declare const coordinatePasswordPersistence: {
|
|
87
|
-
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
88
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
87
|
+
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
88
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
89
89
|
readonly proofMapping?: PM;
|
|
90
90
|
readonly transaction?: never;
|
|
91
91
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Password").PasswordPersistence>>;
|
|
92
|
-
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
93
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
92
|
+
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
93
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
94
94
|
readonly proofMapping?: PM;
|
|
95
95
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
96
96
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Password").PasswordPersistence>>;
|
|
@@ -105,15 +105,15 @@ export declare const coordinatePasswordPersistence: {
|
|
|
105
105
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
106
106
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
107
107
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
108
|
-
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
108
|
+
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>, proofMapping?: ProofPersistenceMapping<any, any, any, any, any, any, any, any, any, any, any, any>) => Effect.Effect<{
|
|
109
109
|
passwordPersistence: {
|
|
110
|
-
readonly
|
|
110
|
+
readonly prepareAttempt: (input: {
|
|
111
111
|
readonly moduleId: string;
|
|
112
112
|
readonly action: "sign-in" | "change";
|
|
113
113
|
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
114
114
|
readonly subjectId?: import("@yielded/auth/Schema").SubjectId;
|
|
115
|
-
readonly
|
|
116
|
-
}
|
|
115
|
+
readonly attemptLifetimeMillis: number;
|
|
116
|
+
}) => Effect.Effect<import("@yielded/auth/Password").PasswordAttemptPreparation, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
117
117
|
readonly settleAttempt: <A_1>(input: {
|
|
118
118
|
readonly moduleId: string;
|
|
119
119
|
readonly attemptId: import("@yielded/auth/Password").PasswordAttemptId;
|
|
@@ -306,17 +306,17 @@ export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTab
|
|
|
306
306
|
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>;
|
|
307
307
|
};
|
|
308
308
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
309
|
-
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
309
|
+
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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, M, T, B, NativeId>, proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined) => Effect.Effect<{
|
|
310
310
|
passwordPreparedPersistence: import("@yielded/auth/Password").PasswordPreparedPersistence;
|
|
311
311
|
}, import("@yielded/auth/Password").PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
312
|
-
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
313
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
312
|
+
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
313
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
314
314
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
315
315
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
316
316
|
readonly transaction?: never;
|
|
317
317
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
318
|
-
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
319
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
318
|
+
<Database extends EffectSQLiteBunDatabase<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
319
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
320
320
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
321
321
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
322
322
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
@@ -482,10 +482,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
482
482
|
readonly nowMillis: number;
|
|
483
483
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
484
484
|
readonly _tag: "Rejected";
|
|
485
|
-
} | {
|
|
486
|
-
readonly _tag: "Cancelled";
|
|
487
485
|
} | {
|
|
488
486
|
readonly _tag: "Ambiguous";
|
|
487
|
+
} | {
|
|
488
|
+
readonly _tag: "Cancelled";
|
|
489
489
|
} | {
|
|
490
490
|
readonly _tag: "Conflict";
|
|
491
491
|
} | {
|
|
@@ -855,10 +855,12 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
855
855
|
readonly outcome: import("@yielded/auth/OAuth").OAuthSignInAccessOutcome;
|
|
856
856
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
857
857
|
readonly _tag: "Rejected";
|
|
858
|
+
} | {
|
|
859
|
+
readonly _tag: "Ambiguous";
|
|
858
860
|
} | {
|
|
859
861
|
readonly _tag: "Cancelled";
|
|
860
862
|
} | {
|
|
861
|
-
readonly _tag: "
|
|
863
|
+
readonly _tag: "Conflict";
|
|
862
864
|
} | {
|
|
863
865
|
readonly _tag: "Connected";
|
|
864
866
|
readonly grant: {
|
|
@@ -928,8 +930,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
928
930
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
929
931
|
};
|
|
930
932
|
};
|
|
931
|
-
} | {
|
|
932
|
-
readonly _tag: "Conflict";
|
|
933
933
|
} | {
|
|
934
934
|
readonly _tag: "Busy";
|
|
935
935
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1315,10 +1315,12 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1315
1315
|
readonly nowMillis: number;
|
|
1316
1316
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1317
1317
|
readonly _tag: "Rejected";
|
|
1318
|
+
} | {
|
|
1319
|
+
readonly _tag: "Ambiguous";
|
|
1318
1320
|
} | {
|
|
1319
1321
|
readonly _tag: "Cancelled";
|
|
1320
1322
|
} | {
|
|
1321
|
-
readonly _tag: "
|
|
1323
|
+
readonly _tag: "Conflict";
|
|
1322
1324
|
} | {
|
|
1323
1325
|
readonly _tag: "Connected";
|
|
1324
1326
|
readonly grant: {
|
|
@@ -1388,8 +1390,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1388
1390
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1389
1391
|
};
|
|
1390
1392
|
};
|
|
1391
|
-
} | {
|
|
1392
|
-
readonly _tag: "Conflict";
|
|
1393
1393
|
} | {
|
|
1394
1394
|
readonly _tag: "Busy";
|
|
1395
1395
|
}, A>) => Effect.Effect<import("@yielded/auth/Hooks").PreparedCommit<A>, import("@yielded/auth/OAuth").OAuthUnavailable, never>;
|
|
@@ -1543,6 +1543,8 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1543
1543
|
readonly profileKey: string & import("effect/Brand").Brand<"effect-auth/OAuthPermissionProfileKey">;
|
|
1544
1544
|
}) => Effect.Effect<{
|
|
1545
1545
|
readonly _tag: "Rejected";
|
|
1546
|
+
} | {
|
|
1547
|
+
readonly _tag: "ReauthorizationRequired";
|
|
1546
1548
|
} | {
|
|
1547
1549
|
readonly _tag: "Busy";
|
|
1548
1550
|
} | {
|
|
@@ -1614,8 +1616,6 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1614
1616
|
readonly ciphertext: import("effect/Redacted").Redacted<string>;
|
|
1615
1617
|
};
|
|
1616
1618
|
};
|
|
1617
|
-
} | {
|
|
1618
|
-
readonly _tag: "ReauthorizationRequired";
|
|
1619
1619
|
}, import("@yielded/auth/OAuth").OAuthUnavailable>;
|
|
1620
1620
|
readonly claimRefresh: <A>(input: {
|
|
1621
1621
|
readonly grant: import("@yielded/auth/OAuth").OAuthConnectedStoredGrant;
|
|
@@ -1625,10 +1625,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1625
1625
|
readonly lifetimeMillis: number;
|
|
1626
1626
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1627
1627
|
readonly _tag: "Rejected";
|
|
1628
|
-
} | {
|
|
1629
|
-
readonly _tag: "Busy";
|
|
1630
1628
|
} | {
|
|
1631
1629
|
readonly _tag: "ReauthorizationRequired";
|
|
1630
|
+
} | {
|
|
1631
|
+
readonly _tag: "Busy";
|
|
1632
1632
|
} | {
|
|
1633
1633
|
readonly _tag: "Claimed";
|
|
1634
1634
|
readonly claim: {
|
|
@@ -1791,10 +1791,10 @@ export declare const makeOAuthAccountsServices: <S extends AnySQLiteTable<{
|
|
|
1791
1791
|
readonly lifetimeMillis: number;
|
|
1792
1792
|
}, prepare: import("@yielded/auth/OAuth").PrepareOAuthCommit<{
|
|
1793
1793
|
readonly _tag: "Rejected";
|
|
1794
|
-
} | {
|
|
1795
|
-
readonly _tag: "Busy";
|
|
1796
1794
|
} | {
|
|
1797
1795
|
readonly _tag: "ReauthorizationRequired";
|
|
1796
|
+
} | {
|
|
1797
|
+
readonly _tag: "Busy";
|
|
1798
1798
|
} | {
|
|
1799
1799
|
readonly _tag: "Admitted";
|
|
1800
1800
|
readonly admissionId: string & import("effect/Brand").Brand<"effect-auth/OAuthClaimId">;
|
package/dist/SqliteDo.d.mts
CHANGED
|
@@ -85,13 +85,13 @@ export declare const coordinateEmailAddress: {
|
|
|
85
85
|
};
|
|
86
86
|
}, import("@yielded/auth/Email").EmailUnavailable, Database>;
|
|
87
87
|
export declare const coordinatePasswordPersistence: {
|
|
88
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
89
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
88
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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>(acquire: Effect.Effect<Database, DatabaseError, DatabaseRequirements>, options: {
|
|
89
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
90
90
|
readonly proofMapping?: PM;
|
|
91
91
|
readonly transaction?: never;
|
|
92
92
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, import("@yielded/auth/Password").PasswordPersistence>>;
|
|
93
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
94
|
-
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<
|
|
93
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
94
|
+
readonly mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>;
|
|
95
95
|
readonly proofMapping?: PM;
|
|
96
96
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
97
97
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TxId | import("@yielded/auth/Password").PasswordPersistence>>;
|
|
@@ -106,15 +106,15 @@ export declare const coordinatePasswordPersistence: {
|
|
|
106
106
|
readonly target: SuppliedService<TargetId, import("@yielded/auth-persistence/Adapter").PasswordRegistrationAuthority<Registration>>;
|
|
107
107
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|
|
108
108
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId | TxId>>;
|
|
109
|
-
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
109
|
+
}, makePasswordPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable, M extends AnySQLiteTable, NativeId>(mapping: import("@yielded/auth-persistence/Adapter").PasswordPersistenceMapping<DrizzleTableModel<S>, DrizzleTableModel<I>, DrizzleTableModel<C>, DrizzleTableModel<AC>, DrizzleTableModel<A>, DrizzleTableModel<M>, NativeId, import("drizzle-orm").SQL<unknown>>, proofMapping?: ProofPersistenceMapping<any, any, any, any, any, any, any, any, any, any, any, any>) => Effect.Effect<{
|
|
110
110
|
passwordPersistence: {
|
|
111
|
-
readonly
|
|
111
|
+
readonly prepareAttempt: (input: {
|
|
112
112
|
readonly moduleId: string;
|
|
113
113
|
readonly action: "sign-in" | "change";
|
|
114
114
|
readonly identifier: import("@yielded/auth/Identity").LoginIdentifier;
|
|
115
115
|
readonly subjectId?: import("@yielded/auth/Schema").SubjectId;
|
|
116
|
-
readonly
|
|
117
|
-
}
|
|
116
|
+
readonly attemptLifetimeMillis: number;
|
|
117
|
+
}) => Effect.Effect<import("@yielded/auth/Password").PasswordAttemptPreparation, import("@yielded/auth/Password").PasswordUnavailable>;
|
|
118
118
|
readonly settleAttempt: <A_1>(input: {
|
|
119
119
|
readonly moduleId: string;
|
|
120
120
|
readonly attemptId: import("@yielded/auth/Password").PasswordAttemptId;
|
|
@@ -307,17 +307,17 @@ export declare const makeExternalIdentityServices: <Subject extends AnySQLiteTab
|
|
|
307
307
|
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>;
|
|
308
308
|
};
|
|
309
309
|
}, import("@yielded/auth/Identity").IdentityUnavailable, Database>;
|
|
310
|
-
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
310
|
+
export declare const makePasswordPreparedPersistenceServices: <S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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, M, T, B, NativeId>, proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined) => Effect.Effect<{
|
|
311
311
|
passwordPreparedPersistence: import("@yielded/auth/Password").PasswordPreparedPersistence;
|
|
312
312
|
}, import("@yielded/auth/Password").PasswordUnavailable, Database | import("@yielded/auth/Hooks").LifecycleHooks>, coordinatePasswordPreparedPersistence: {
|
|
313
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
314
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
313
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
314
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
315
315
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
316
316
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
317
317
|
readonly transaction?: never;
|
|
318
318
|
}, body: Effect.Effect<Out, E, R>): Effect.Effect<Out, DatabaseError | E | import("@yielded/auth/Hooks").HookConfigurationError | import("@yielded/auth/Password").PasswordUnavailable | import("effect/sql/SqlError").SqlError, DatabaseRequirements | import("@yielded/auth/Hooks").LifecycleHooks | Exclude<R, TargetId>>;
|
|
319
|
-
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A extends AnySQLiteTable,
|
|
320
|
-
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A,
|
|
319
|
+
<Database extends DatabaseValue<import("drizzle-orm").TablesRelationalConfig>, TargetId, S extends AnySQLiteTable, I extends AnySQLiteTable, C extends AnySQLiteTable, AC extends AnySQLiteTable, A 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: {
|
|
320
|
+
readonly mapping: PasswordPreparedPersistenceMapping<S, I, C, AC, A, M, T, B, NativeId>;
|
|
321
321
|
readonly proofMapping?: PasswordPreparedProofMapping<PS, PC, PM, PSub, PI, PCr, PNativeId> | undefined;
|
|
322
322
|
readonly target: SuppliedService<TargetId, import("@yielded/auth/Password").PasswordPreparedPersistence>;
|
|
323
323
|
readonly transaction: SuppliedService<TxId, NoInfer<Parameters<Parameters<Database["transaction"]>[0]>[0]>, TxShape>;
|