@gatwech/auth 1.0.0-beta.24 → 1.0.0-beta.25
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/adapters/index.d.mts +1 -1
- package/dist/api/index.d.mts +1 -1
- package/dist/{audit-log-DhRRCMrv.mjs → audit-log-CQnf8nrN.mjs} +442 -46
- package/dist/client/index.d.mts +1 -1
- package/dist/client/plugins/index.d.mts +46 -46
- package/dist/client/plugins/index.mjs +2 -2
- package/dist/client/react/index.d.mts +15 -15
- package/dist/{client-CMsC6-rl.mjs → client-BkpNva-h.mjs} +3 -2
- package/dist/{client-CGV_kj99.d.mts → client-g0OAVuPQ.d.mts} +1 -1
- package/dist/{client-CT-acJeN.d.mts → client-zkWmSxqy.d.mts} +7 -4
- package/dist/cookies/index.d.mts +2 -2
- package/dist/db/index.d.mts +1 -1
- package/dist/{index-Czr_eQFE.d.mts → index-B4HTudhm.d.mts} +6 -6
- package/dist/{index-DYqQWdEv.d.mts → index-BHiF_ZfZ.d.mts} +13 -13
- package/dist/{index-Dmjw6re9.d.mts → index-BX55rZO5.d.mts} +2 -2
- package/dist/{index-Clwezlxm.d.mts → index-BfwCJQfM.d.mts} +8 -8
- package/dist/{index-DGRGLg16.d.mts → index-BhbilPfs.d.mts} +2 -2
- package/dist/{index-JzSy-vFn.d.mts → index-Bi-vEjDm.d.mts} +166 -166
- package/dist/{index-Cl9ITXy1.d.mts → index-BifhxQ8O.d.mts} +10 -10
- package/dist/{index-DWGj7du8.d.mts → index-BiomZttP.d.mts} +19 -19
- package/dist/{index-Hoybqpnt.d.mts → index-BoHrBgTB.d.mts} +9 -9
- package/dist/{index-UDzaYKxq.d.mts → index-C5W_sTlp.d.mts} +9 -9
- package/dist/{index-CLhlur69.d.mts → index-CNyQFga7.d.mts} +6 -6
- package/dist/{index-CZtQ0rUe.d.mts → index-CTjXncwM.d.mts} +113 -113
- package/dist/{index-CGGitykk.d.mts → index-CUUaJp3R.d.mts} +7 -7
- package/dist/{index-D85KXOKz.d.mts → index-CcJjgkwe.d.mts} +3 -3
- package/dist/{index-B-i2ob-C.d.mts → index-Cdfh66xb.d.mts} +9 -9
- package/dist/{index-CHMYUshk.d.mts → index-DBtm_waB.d.mts} +13 -13
- package/dist/{index-DWSbFJWU.d.mts → index-DD_pxX-h.d.mts} +662 -354
- package/dist/{index-BYxt8qOP.d.mts → index-DRoa3BGG.d.mts} +33 -33
- package/dist/{index-D5cyFBEb.d.mts → index-M0IQ_DTL.d.mts} +4 -4
- package/dist/{index-rcUKPBBy.d.mts → index-gRLqvVoc.d.mts} +6 -6
- package/dist/{index-Dt6JhAV4.d.mts → index-i1L-uguJ.d.mts} +6 -6
- package/dist/{index-B6to9CaK.d.mts → index-kBEBsEUr.d.mts} +1 -1
- package/dist/{index-BRUQHEUF.d.mts → index-mDmrBYrk.d.mts} +5 -5
- package/dist/index.d.mts +1 -1
- package/dist/integrations/next-js.d.mts +4 -4
- package/dist/integrations/node.d.mts +1 -1
- package/dist/integrations/react-start.d.mts +2 -2
- package/dist/oauth2/index.d.mts +1 -1
- package/dist/plugins/admin/index.d.mts +2 -2
- package/dist/plugins/anonymous/index.d.mts +2 -2
- package/dist/plugins/audit-log/client.d.mts +23 -23
- package/dist/plugins/audit-log/index.d.mts +23 -23
- package/dist/plugins/audit-log/index.mjs +3 -3
- package/dist/plugins/bearer/index.d.mts +1 -1
- package/dist/plugins/captcha/index.d.mts +1 -1
- package/dist/plugins/custom-session/index.d.mts +2 -2
- package/dist/plugins/device-authorization/index.d.mts +1 -1
- package/dist/plugins/email-otp/index.d.mts +1 -1
- package/dist/plugins/generic-oauth/index.d.mts +2 -2
- package/dist/plugins/haveibeenpwned/index.d.mts +1 -1
- package/dist/plugins/index.d.mts +23 -23
- package/dist/plugins/index.mjs +5 -5
- package/dist/plugins/jwt/index.d.mts +2 -2
- package/dist/plugins/magic-link/index.d.mts +1 -1
- package/dist/plugins/multi-session/index.d.mts +1 -1
- package/dist/plugins/oauth-proxy/index.d.mts +1 -1
- package/dist/plugins/one-tap/index.d.mts +1 -1
- package/dist/plugins/one-time-token/index.d.mts +2 -2
- package/dist/plugins/one-time-token/index.mjs +4 -4
- package/dist/plugins/organization/index.d.mts +2 -2
- package/dist/plugins/passkey/index.d.mts +2 -2
- package/dist/plugins/phone-number/index.d.mts +2 -2
- package/dist/plugins/sentinel/client.d.mts +23 -23
- package/dist/plugins/sentinel/client.mjs +2 -2
- package/dist/plugins/sentinel/index.d.mts +22 -22
- package/dist/plugins/sentinel/index.mjs +3 -3
- package/dist/plugins/two-factor/index.d.mts +2 -2
- package/dist/plugins/username/index.d.mts +1 -1
- package/dist/{registry-GztLf62p.mjs → registry-BjYhRF79.mjs} +69 -2
- package/dist/{sentinel-b8XEetew.mjs → sentinel-BttZLWPD.mjs} +70 -14
- package/dist/src/plugins/audit-log/error-codes.d.ts +7 -0
- package/dist/src/plugins/audit-log/events.d.ts +13 -0
- package/dist/src/plugins/audit-log/index.d.ts +114 -8
- package/dist/src/plugins/audit-log/integrity.d.ts +20 -0
- package/dist/src/plugins/audit-log/redact.d.ts +18 -0
- package/dist/src/plugins/audit-log/remote.d.ts +1 -0
- package/dist/src/plugins/audit-log/schema.d.ts +25 -0
- package/dist/src/plugins/audit-log/types.d.ts +73 -13
- package/dist/src/plugins/sentinel/actions.d.ts +0 -6
- package/dist/src/plugins/sentinel/client.d.ts +3 -0
- package/dist/src/plugins/sentinel/error-codes.d.ts +6 -0
- package/dist/src/plugins/sentinel/index.d.ts +80 -3
- package/dist/src/plugins/sentinel/types.d.ts +1 -1
- package/dist/test-utils/index.d.mts +2 -2
- package/dist/test-utils/index.mjs +4 -4
- package/dist/types/index.d.mts +1 -1
- package/package.json +3 -3
- /package/dist/{pow-DvkUopsK.mjs → pow-Vna_j4hx.mjs} +0 -0
package/dist/client/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { d as PrettifyDeep, h as UnionToIntersection } from "../helper-BgOIGHsu.mjs";
|
|
2
|
-
import { B as InferPluginsFromClient, F as ClientStore, G as PayvoAuthClientPlugin, H as InferUserFromClient, I as InferActions, K as SessionQueryParams, L as InferAdditionalFromClient, M as AtomListener, N as ClientAtomListener, P as ClientOptions, R as InferClientAPI, U as IsSignal, V as InferSessionFromClient, W as PayvoAuthClientOptions, q as Store, z as InferErrorCodes } from "../index-
|
|
2
|
+
import { B as InferPluginsFromClient, F as ClientStore, G as PayvoAuthClientPlugin, H as InferUserFromClient, I as InferActions, K as SessionQueryParams, L as InferAdditionalFromClient, M as AtomListener, N as ClientAtomListener, P as ClientOptions, R as InferClientAPI, U as IsSignal, V as InferSessionFromClient, W as PayvoAuthClientOptions, q as Store, z as InferErrorCodes } from "../index-CTjXncwM.mjs";
|
|
3
3
|
import "../types-DNQ9XQrB.mjs";
|
|
4
4
|
import "../index-BL_t8cRp-C4QYBsac.mjs";
|
|
5
5
|
import "../plugins-Dy_FrD4Y.mjs";
|
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
import { a as LiteralNumber, c as OmitId, d as PrettifyDeep, f as Primitive, g as WithoutEmpty, h as UnionToIntersection, i as HasRequiredKeys, l as PreserveJSDoc, m as StripEmptyObjects, n as DeepPartial, o as LiteralString, p as RequiredKeysOf, r as Expand, s as LiteralUnion, t as Awaitable, u as Prettify } from "../../helper-BgOIGHsu.mjs";
|
|
2
|
-
import { K as SessionQueryParams, Y as Auth, g as User$1, h as Session$1, i as PayvoAuthPlugin$1, mn as InferAdditionalFieldsFromPluginOptions, r as PayvoAuthOptions$1 } from "../../index-
|
|
2
|
+
import { K as SessionQueryParams, Y as Auth, g as User$1, h as Session$1, i as PayvoAuthPlugin$1, mn as InferAdditionalFieldsFromPluginOptions, r as PayvoAuthOptions$1 } from "../../index-CTjXncwM.mjs";
|
|
3
3
|
import "../../types-DNQ9XQrB.mjs";
|
|
4
4
|
import "../../index-BL_t8cRp-C4QYBsac.mjs";
|
|
5
5
|
import "../../plugins-Dy_FrD4Y.mjs";
|
|
6
6
|
import { a as Role, i as AccessControl, o as Statements } from "../../index-CxlWnL9c.mjs";
|
|
7
|
-
import { t as admin } from "../../index-
|
|
8
|
-
import { r as anonymous } from "../../index-
|
|
9
|
-
import {
|
|
10
|
-
import "../../index-
|
|
11
|
-
import "../../index-
|
|
12
|
-
import "../../index-
|
|
13
|
-
import { i as deviceAuthorizationClient } from "../../index-
|
|
14
|
-
import { n as emailOTP } from "../../index-
|
|
15
|
-
import { n as genericOAuth } from "../../index-
|
|
16
|
-
import "../../index-
|
|
17
|
-
import { t as jwt } from "../../index-
|
|
18
|
-
import { t as magicLink } from "../../index-
|
|
19
|
-
import { t as multiSession } from "../../index-
|
|
20
|
-
import "../../index-
|
|
21
|
-
import "../../index-
|
|
22
|
-
import { t as oneTimeToken } from "../../index-
|
|
7
|
+
import { t as admin } from "../../index-DRoa3BGG.mjs";
|
|
8
|
+
import { r as anonymous } from "../../index-i1L-uguJ.mjs";
|
|
9
|
+
import { B as apiKey } from "../../index-DD_pxX-h.mjs";
|
|
10
|
+
import "../../index-B4HTudhm.mjs";
|
|
11
|
+
import "../../index-BX55rZO5.mjs";
|
|
12
|
+
import "../../index-CNyQFga7.mjs";
|
|
13
|
+
import { i as deviceAuthorizationClient } from "../../index-gRLqvVoc.mjs";
|
|
14
|
+
import { n as emailOTP } from "../../index-BHiF_ZfZ.mjs";
|
|
15
|
+
import { n as genericOAuth } from "../../index-BfwCJQfM.mjs";
|
|
16
|
+
import "../../index-CcJjgkwe.mjs";
|
|
17
|
+
import { t as jwt } from "../../index-C5W_sTlp.mjs";
|
|
18
|
+
import { t as magicLink } from "../../index-M0IQ_DTL.mjs";
|
|
19
|
+
import { t as multiSession } from "../../index-Cdfh66xb.mjs";
|
|
20
|
+
import "../../index-BifhxQ8O.mjs";
|
|
21
|
+
import "../../index-BhbilPfs.mjs";
|
|
22
|
+
import { t as oneTimeToken } from "../../index-mDmrBYrk.mjs";
|
|
23
23
|
import "../../index-QmocqGM-.mjs";
|
|
24
|
-
import { F as OrganizationOptions, S as Team, b as OrganizationRole, c as InferMember, f as InferTeam, g as Member, l as InferOrganization, p as Invitation, r as OrganizationPlugin, s as InferInvitation, v as Organization, w as TeamMember } from "../../index-
|
|
25
|
-
import { r as phoneNumber } from "../../index-
|
|
26
|
-
import { n as twoFactorClient } from "../../index-
|
|
27
|
-
import { n as Passkey, t as passkey } from "../../index-
|
|
28
|
-
import { n as username } from "../../index-
|
|
29
|
-
import { t as auditLogClient } from "../../client-
|
|
30
|
-
import { t as sentinelClient } from "../../client-
|
|
31
|
-
import * as
|
|
24
|
+
import { F as OrganizationOptions, S as Team, b as OrganizationRole, c as InferMember, f as InferTeam, g as Member, l as InferOrganization, p as Invitation, r as OrganizationPlugin, s as InferInvitation, v as Organization, w as TeamMember } from "../../index-Bi-vEjDm.mjs";
|
|
25
|
+
import { r as phoneNumber } from "../../index-CUUaJp3R.mjs";
|
|
26
|
+
import { n as twoFactorClient } from "../../index-BiomZttP.mjs";
|
|
27
|
+
import { n as Passkey, t as passkey } from "../../index-DBtm_waB.mjs";
|
|
28
|
+
import { n as username } from "../../index-BoHrBgTB.mjs";
|
|
29
|
+
import { t as auditLogClient } from "../../client-g0OAVuPQ.mjs";
|
|
30
|
+
import { t as sentinelClient } from "../../client-zkWmSxqy.mjs";
|
|
31
|
+
import * as _gatwech_core54 from "@gatwech/core";
|
|
32
32
|
import { ClientStore, PayvoAuthOptions } from "@gatwech/core";
|
|
33
33
|
import { DBFieldAttribute } from "@gatwech/core/db";
|
|
34
|
-
import * as
|
|
34
|
+
import * as _better_fetch_fetch38 from "@better-fetch/fetch";
|
|
35
35
|
import { BetterFetch, BetterFetchOption } from "@better-fetch/fetch";
|
|
36
|
-
import * as
|
|
36
|
+
import * as nanostores3 from "nanostores";
|
|
37
37
|
import { atom } from "nanostores";
|
|
38
38
|
|
|
39
39
|
//#region src/plugins/additional-fields/client.d.ts
|
|
@@ -369,10 +369,10 @@ interface GoogleOneTapActionOptions extends Omit<GoogleOneTapOptions, "clientId"
|
|
|
369
369
|
}
|
|
370
370
|
declare const oneTapClient: (options: GoogleOneTapOptions) => {
|
|
371
371
|
id: "one-tap";
|
|
372
|
-
getActions: ($fetch:
|
|
372
|
+
getActions: ($fetch: _better_fetch_fetch38.BetterFetch, _: _gatwech_core54.ClientStore) => {
|
|
373
373
|
oneTap: (opts?: GoogleOneTapActionOptions | undefined, fetchOptions?: BetterFetchOption | undefined) => Promise<void>;
|
|
374
374
|
};
|
|
375
|
-
getAtoms($fetch:
|
|
375
|
+
getAtoms($fetch: _better_fetch_fetch38.BetterFetch): {};
|
|
376
376
|
};
|
|
377
377
|
//#endregion
|
|
378
378
|
//#region src/plugins/one-time-token/client.d.ts
|
|
@@ -471,7 +471,7 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
471
471
|
} ? true : false;
|
|
472
472
|
};
|
|
473
473
|
}>;
|
|
474
|
-
getActions: ($fetch:
|
|
474
|
+
getActions: ($fetch: _better_fetch_fetch38.BetterFetch, _$store: _gatwech_core54.ClientStore, co: _gatwech_core54.PayvoAuthClientOptions | undefined) => {
|
|
475
475
|
$Infer: {
|
|
476
476
|
ActiveOrganization: CO["teams"] extends {
|
|
477
477
|
enabled: true;
|
|
@@ -555,12 +555,12 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
555
555
|
}) => boolean;
|
|
556
556
|
};
|
|
557
557
|
};
|
|
558
|
-
getAtoms: ($fetch:
|
|
559
|
-
$listOrg:
|
|
560
|
-
$activeOrgSignal:
|
|
561
|
-
$activeMemberSignal:
|
|
562
|
-
$activeMemberRoleSignal:
|
|
563
|
-
activeOrganization:
|
|
558
|
+
getAtoms: ($fetch: _better_fetch_fetch38.BetterFetch) => {
|
|
559
|
+
$listOrg: nanostores3.PreinitializedWritableAtom<boolean> & object;
|
|
560
|
+
$activeOrgSignal: nanostores3.PreinitializedWritableAtom<boolean> & object;
|
|
561
|
+
$activeMemberSignal: nanostores3.PreinitializedWritableAtom<boolean> & object;
|
|
562
|
+
$activeMemberRoleSignal: nanostores3.PreinitializedWritableAtom<boolean> & object;
|
|
563
|
+
activeOrganization: nanostores3.PreinitializedWritableAtom<{
|
|
564
564
|
data: Prettify<({
|
|
565
565
|
id: string;
|
|
566
566
|
name: string;
|
|
@@ -572,14 +572,14 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
572
572
|
members: InferMember<CO, false>[];
|
|
573
573
|
invitations: InferInvitation<CO, false>[];
|
|
574
574
|
}> | null;
|
|
575
|
-
error: null |
|
|
575
|
+
error: null | _better_fetch_fetch38.BetterFetchError;
|
|
576
576
|
isPending: boolean;
|
|
577
577
|
isRefetching: boolean;
|
|
578
578
|
refetch: (queryParams?: {
|
|
579
579
|
query?: SessionQueryParams;
|
|
580
580
|
} | undefined) => void;
|
|
581
581
|
}> & object;
|
|
582
|
-
listOrganizations:
|
|
582
|
+
listOrganizations: nanostores3.PreinitializedWritableAtom<{
|
|
583
583
|
data: ({
|
|
584
584
|
id: string;
|
|
585
585
|
name: string;
|
|
@@ -588,14 +588,14 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
588
588
|
logo?: string | null | undefined;
|
|
589
589
|
metadata?: any;
|
|
590
590
|
} & InferAdditionalFieldsFromPluginOptions<"organization", CO, false> extends infer T_1 ? { [K in keyof T_1]: T_1[K] } : never)[] | null;
|
|
591
|
-
error: null |
|
|
591
|
+
error: null | _better_fetch_fetch38.BetterFetchError;
|
|
592
592
|
isPending: boolean;
|
|
593
593
|
isRefetching: boolean;
|
|
594
594
|
refetch: (queryParams?: {
|
|
595
595
|
query?: SessionQueryParams;
|
|
596
596
|
} | undefined) => void;
|
|
597
597
|
}> & object;
|
|
598
|
-
activeMember:
|
|
598
|
+
activeMember: nanostores3.PreinitializedWritableAtom<{
|
|
599
599
|
data: {
|
|
600
600
|
id: string;
|
|
601
601
|
organizationId: string;
|
|
@@ -603,18 +603,18 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
603
603
|
role: string;
|
|
604
604
|
createdAt: Date;
|
|
605
605
|
} | null;
|
|
606
|
-
error: null |
|
|
606
|
+
error: null | _better_fetch_fetch38.BetterFetchError;
|
|
607
607
|
isPending: boolean;
|
|
608
608
|
isRefetching: boolean;
|
|
609
609
|
refetch: (queryParams?: {
|
|
610
610
|
query?: SessionQueryParams;
|
|
611
611
|
} | undefined) => void;
|
|
612
612
|
}> & object;
|
|
613
|
-
activeMemberRole:
|
|
613
|
+
activeMemberRole: nanostores3.PreinitializedWritableAtom<{
|
|
614
614
|
data: {
|
|
615
615
|
role: string;
|
|
616
616
|
} | null;
|
|
617
|
-
error: null |
|
|
617
|
+
error: null | _better_fetch_fetch38.BetterFetchError;
|
|
618
618
|
isPending: boolean;
|
|
619
619
|
isRefetching: boolean;
|
|
620
620
|
refetch: (queryParams?: {
|
|
@@ -912,16 +912,16 @@ declare const passkeyClient: () => {
|
|
|
912
912
|
};
|
|
913
913
|
};
|
|
914
914
|
getAtoms($fetch: BetterFetch): {
|
|
915
|
-
listPasskeys:
|
|
915
|
+
listPasskeys: nanostores3.PreinitializedWritableAtom<{
|
|
916
916
|
data: Passkey[] | null;
|
|
917
|
-
error: null |
|
|
917
|
+
error: null | _better_fetch_fetch38.BetterFetchError;
|
|
918
918
|
isPending: boolean;
|
|
919
919
|
isRefetching: boolean;
|
|
920
920
|
refetch: (queryParams?: {
|
|
921
921
|
query?: SessionQueryParams;
|
|
922
922
|
} | undefined) => void;
|
|
923
923
|
}> & object;
|
|
924
|
-
$listPasskeys:
|
|
924
|
+
$listPasskeys: nanostores3.PreinitializedWritableAtom<any> & object;
|
|
925
925
|
};
|
|
926
926
|
pathMethods: {
|
|
927
927
|
"/passkey/register": "POST";
|
|
@@ -10,10 +10,10 @@ import { t as hasPermission } from "../../has-permission-Bvg8de8g.mjs";
|
|
|
10
10
|
import { t as deviceAuthorizationClient } from "../../client-cBiytuOL.mjs";
|
|
11
11
|
import { a as memberAc, o as ownerAc, r as defaultRoles, t as adminAc } from "../../access-CrwEFPHE.mjs";
|
|
12
12
|
import { n as hasPermissionFn } from "../../permission-CDDWgA_O.mjs";
|
|
13
|
-
import "../../pow-
|
|
13
|
+
import "../../pow-Vna_j4hx.mjs";
|
|
14
14
|
import { t as twoFactorClient } from "../../client-BuveH3MN.mjs";
|
|
15
15
|
import { t as auditLogClient } from "../../client-DzOqXJUm.mjs";
|
|
16
|
-
import { t as sentinelClient } from "../../client-
|
|
16
|
+
import { t as sentinelClient } from "../../client-BkpNva-h.mjs";
|
|
17
17
|
import { atom } from "nanostores";
|
|
18
18
|
import { WebAuthnError, startAuthentication, startRegistration } from "@simplewebauthn/browser";
|
|
19
19
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { d as PrettifyDeep, h as UnionToIntersection } from "../../helper-BgOIGHsu.mjs";
|
|
2
|
-
import { I as InferActions, K as SessionQueryParams, R as InferClientAPI, U as IsSignal, z as InferErrorCodes } from "../../index-
|
|
2
|
+
import { I as InferActions, K as SessionQueryParams, R as InferClientAPI, U as IsSignal, z as InferErrorCodes } from "../../index-CTjXncwM.mjs";
|
|
3
3
|
import "../../types-DNQ9XQrB.mjs";
|
|
4
4
|
import "../../index-BL_t8cRp-C4QYBsac.mjs";
|
|
5
5
|
import "../../plugins-Dy_FrD4Y.mjs";
|
|
6
6
|
import { PayvoAuthClientOptions, PayvoAuthClientPlugin } from "@gatwech/core";
|
|
7
7
|
import { BASE_ERROR_CODES } from "@gatwech/core/error";
|
|
8
|
-
import * as
|
|
8
|
+
import * as _better_fetch_fetch2 from "@better-fetch/fetch";
|
|
9
9
|
import { BetterFetchError } from "@better-fetch/fetch";
|
|
10
10
|
import * as nanostores0 from "nanostores";
|
|
11
11
|
import { Store, StoreValue } from "nanostores";
|
|
@@ -97,27 +97,27 @@ declare function createAuthClient<Option extends PayvoAuthClientOptions>(options
|
|
|
97
97
|
error: null;
|
|
98
98
|
} ? S : Res : never>;
|
|
99
99
|
};
|
|
100
|
-
$fetch:
|
|
101
|
-
plugins: (
|
|
100
|
+
$fetch: _better_fetch_fetch2.BetterFetch<{
|
|
101
|
+
plugins: (_better_fetch_fetch2.BetterFetchPlugin | {
|
|
102
102
|
id: string;
|
|
103
103
|
name: string;
|
|
104
104
|
hooks: {
|
|
105
|
-
onSuccess(context:
|
|
105
|
+
onSuccess(context: _better_fetch_fetch2.SuccessContext<any>): void;
|
|
106
106
|
};
|
|
107
107
|
} | {
|
|
108
108
|
id: string;
|
|
109
109
|
name: string;
|
|
110
110
|
hooks: {
|
|
111
|
-
onRequest<T extends Record<string, any>>(context:
|
|
111
|
+
onRequest<T extends Record<string, any>>(context: _better_fetch_fetch2.RequestContext<T>): void;
|
|
112
112
|
};
|
|
113
113
|
} | {
|
|
114
114
|
id: string;
|
|
115
115
|
name: string;
|
|
116
116
|
hooks: {
|
|
117
|
-
onSuccess: ((context:
|
|
118
|
-
onError: ((context:
|
|
119
|
-
onRequest: (<T extends Record<string, any>>(context:
|
|
120
|
-
onResponse: ((context:
|
|
117
|
+
onSuccess: ((context: _better_fetch_fetch2.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
118
|
+
onError: ((context: _better_fetch_fetch2.ErrorContext) => Promise<void> | void) | undefined;
|
|
119
|
+
onRequest: (<T extends Record<string, any>>(context: _better_fetch_fetch2.RequestContext<T>) => Promise<_better_fetch_fetch2.RequestContext | void> | _better_fetch_fetch2.RequestContext | void) | undefined;
|
|
120
|
+
onResponse: ((context: _better_fetch_fetch2.ResponseContext) => Promise<Response | void | _better_fetch_fetch2.ResponseContext> | Response | _better_fetch_fetch2.ResponseContext | void) | undefined;
|
|
121
121
|
};
|
|
122
122
|
})[];
|
|
123
123
|
method: string;
|
|
@@ -137,12 +137,12 @@ declare function createAuthClient<Option extends PayvoAuthClientOptions>(options
|
|
|
137
137
|
referrerPolicy?: ReferrerPolicy | undefined;
|
|
138
138
|
signal?: (AbortSignal | null) | undefined;
|
|
139
139
|
window?: null | undefined;
|
|
140
|
-
onRetry?: ((response:
|
|
140
|
+
onRetry?: ((response: _better_fetch_fetch2.ResponseContext) => Promise<void> | void) | undefined;
|
|
141
141
|
hookOptions?: {
|
|
142
142
|
cloneResponse?: boolean;
|
|
143
143
|
} | undefined;
|
|
144
144
|
timeout?: number | undefined;
|
|
145
|
-
customFetchImpl:
|
|
145
|
+
customFetchImpl: _better_fetch_fetch2.FetchEsque;
|
|
146
146
|
baseURL: string;
|
|
147
147
|
throw?: boolean | undefined;
|
|
148
148
|
auth?: ({
|
|
@@ -162,10 +162,10 @@ declare function createAuthClient<Option extends PayvoAuthClientOptions>(options
|
|
|
162
162
|
params?: any;
|
|
163
163
|
duplex?: "full" | "half" | undefined;
|
|
164
164
|
jsonParser: (text: string) => Promise<any> | any;
|
|
165
|
-
retry?:
|
|
165
|
+
retry?: _better_fetch_fetch2.RetryOptions | undefined;
|
|
166
166
|
retryAttempt?: number | undefined;
|
|
167
|
-
output?: (
|
|
168
|
-
errorSchema?:
|
|
167
|
+
output?: (_better_fetch_fetch2.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
168
|
+
errorSchema?: _better_fetch_fetch2.StandardSchemaV1 | undefined;
|
|
169
169
|
disableValidation?: boolean | undefined;
|
|
170
170
|
}, unknown, unknown, {}>;
|
|
171
171
|
$store: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as generateRandomString } from "./random-32E3cU5o.mjs";
|
|
2
|
-
import { n as POW_REASON_HEADER, o as parsePowHeader, r as POW_SOLUTION_HEADER, s as solveChallenge, t as POW_CHALLENGE_HEADER } from "./pow-
|
|
2
|
+
import { n as POW_REASON_HEADER, o as parsePowHeader, r as POW_SOLUTION_HEADER, s as solveChallenge, t as POW_CHALLENGE_HEADER } from "./pow-Vna_j4hx.mjs";
|
|
3
3
|
import { betterFetch } from "@better-fetch/fetch";
|
|
4
4
|
|
|
5
5
|
//#region src/plugins/sentinel/client.ts
|
|
@@ -87,7 +87,8 @@ const sentinelClient = (options) => {
|
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
}
|
|
90
|
-
}]
|
|
90
|
+
}],
|
|
91
|
+
pathMethods: { "/sentinel/list-blocks": "GET" }
|
|
91
92
|
};
|
|
92
93
|
};
|
|
93
94
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import * as
|
|
1
|
+
import { x as sentinel } from "./index-DD_pxX-h.mjs";
|
|
2
|
+
import * as _better_fetch_fetch0 from "@better-fetch/fetch";
|
|
3
3
|
|
|
4
4
|
//#region src/plugins/sentinel/client.d.ts
|
|
5
5
|
declare const sentinelClient: (options?: {
|
|
@@ -63,13 +63,16 @@ declare const sentinelClient: (options?: {
|
|
|
63
63
|
id: string;
|
|
64
64
|
name: string;
|
|
65
65
|
hooks: {
|
|
66
|
-
onRequest<T extends Record<string, any>>(context:
|
|
66
|
+
onRequest<T extends Record<string, any>>(context: _better_fetch_fetch0.RequestContext<T>): Promise<_better_fetch_fetch0.RequestContext<T>>;
|
|
67
67
|
onResponse({
|
|
68
68
|
response,
|
|
69
69
|
request
|
|
70
|
-
}:
|
|
70
|
+
}: _better_fetch_fetch0.ResponseContext): Promise<Response | undefined>;
|
|
71
71
|
};
|
|
72
72
|
}[];
|
|
73
|
+
pathMethods: {
|
|
74
|
+
"/sentinel/list-blocks": "GET";
|
|
75
|
+
};
|
|
73
76
|
};
|
|
74
77
|
//#endregion
|
|
75
78
|
export { sentinelClient as t };
|
package/dist/cookies/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "../helper-BgOIGHsu.mjs";
|
|
2
|
-
import "../index-
|
|
2
|
+
import "../index-CTjXncwM.mjs";
|
|
3
3
|
import "../types-DNQ9XQrB.mjs";
|
|
4
4
|
import "../index-BL_t8cRp-C4QYBsac.mjs";
|
|
5
5
|
import "../plugins-Dy_FrD4Y.mjs";
|
|
6
|
-
import { a as getCookies, c as setCookieCache, d as getChunkedCookie, f as parseSetCookieHeader, i as getCookieCache, l as setSessionCookie, n as createCookieGetter, o as getSessionCookie, p as setCookieToHeader, r as deleteSessionCookie, s as parseCookies, t as EligibleCookies, u as createSessionStore } from "../index-
|
|
6
|
+
import { a as getCookies, c as setCookieCache, d as getChunkedCookie, f as parseSetCookieHeader, i as getCookieCache, l as setSessionCookie, n as createCookieGetter, o as getSessionCookie, p as setCookieToHeader, r as deleteSessionCookie, s as parseCookies, t as EligibleCookies, u as createSessionStore } from "../index-kBEBsEUr.mjs";
|
|
7
7
|
export { EligibleCookies, createCookieGetter, createSessionStore, deleteSessionCookie, getChunkedCookie, getCookieCache, getCookies, getSessionCookie, parseCookies, parseSetCookieHeader, setCookieCache, setCookieToHeader, setSessionCookie };
|
package/dist/db/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "../helper-BgOIGHsu.mjs";
|
|
2
|
-
import { $t as mergeSchema, Jt as convertFromDB, Qt as toZodSchema, Sn as createFieldAttribute, Xt as getAdapter, Yt as convertToDB, Zt as FieldAttributeToSchema, _n as InferFieldsInput, an as parseSessionOutput, bn as InferValueType, cn as createInternalAdapter, dn as getMigrations, en as parseAccountInput, fn as matchType, gn as InferFieldsFromPlugins, hn as InferFieldsFromOptions, in as parseSessionInput, ln as getAuthTables, mn as InferAdditionalFieldsFromPluginOptions, nn as parseAdditionalUserInput, on as parseUserInput, pn as FieldAttributeToObject, qt as getWithHooks, rn as parseInputData, sn as parseUserOutput, tn as parseAccountOutput, un as getSchema, vn as InferFieldsInputClient, xn as PluginFieldAttribute, yn as InferFieldsOutput } from "../index-
|
|
2
|
+
import { $t as mergeSchema, Jt as convertFromDB, Qt as toZodSchema, Sn as createFieldAttribute, Xt as getAdapter, Yt as convertToDB, Zt as FieldAttributeToSchema, _n as InferFieldsInput, an as parseSessionOutput, bn as InferValueType, cn as createInternalAdapter, dn as getMigrations, en as parseAccountInput, fn as matchType, gn as InferFieldsFromPlugins, hn as InferFieldsFromOptions, in as parseSessionInput, ln as getAuthTables, mn as InferAdditionalFieldsFromPluginOptions, nn as parseAdditionalUserInput, on as parseUserInput, pn as FieldAttributeToObject, qt as getWithHooks, rn as parseInputData, sn as parseUserOutput, tn as parseAccountOutput, un as getSchema, vn as InferFieldsInputClient, xn as PluginFieldAttribute, yn as InferFieldsOutput } from "../index-CTjXncwM.mjs";
|
|
3
3
|
import "../types-DNQ9XQrB.mjs";
|
|
4
4
|
import "../index-BL_t8cRp-C4QYBsac.mjs";
|
|
5
5
|
import "../plugins-Dy_FrD4Y.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import * as
|
|
1
|
+
import * as _gatwech_core23 from "@gatwech/core";
|
|
2
|
+
import * as better_call161 from "better-call";
|
|
3
3
|
|
|
4
4
|
//#region src/plugins/bearer/index.d.ts
|
|
5
5
|
interface BearerOptions {
|
|
@@ -19,16 +19,16 @@ declare const bearer: (options?: BearerOptions | undefined) => {
|
|
|
19
19
|
id: "bearer";
|
|
20
20
|
hooks: {
|
|
21
21
|
before: {
|
|
22
|
-
matcher(context:
|
|
23
|
-
handler: (inputContext:
|
|
22
|
+
matcher(context: _gatwech_core23.HookEndpointContext): boolean;
|
|
23
|
+
handler: (inputContext: better_call161.MiddlewareInputContext<better_call161.MiddlewareOptions>) => Promise<{
|
|
24
24
|
context: {
|
|
25
25
|
headers: Headers;
|
|
26
26
|
};
|
|
27
27
|
} | undefined>;
|
|
28
28
|
}[];
|
|
29
29
|
after: {
|
|
30
|
-
matcher(context:
|
|
31
|
-
handler: (inputContext:
|
|
30
|
+
matcher(context: _gatwech_core23.HookEndpointContext): true;
|
|
31
|
+
handler: (inputContext: better_call161.MiddlewareInputContext<better_call161.MiddlewareOptions>) => Promise<void>;
|
|
32
32
|
}[];
|
|
33
33
|
};
|
|
34
34
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { s as User } from "./index-BL_t8cRp-C4QYBsac.mjs";
|
|
2
|
-
import * as
|
|
3
|
-
import * as
|
|
2
|
+
import * as _gatwech_core13 from "@gatwech/core";
|
|
3
|
+
import * as better_call147 from "better-call";
|
|
4
4
|
import * as z$1 from "zod";
|
|
5
5
|
|
|
6
6
|
//#region src/plugins/email-otp/index.d.ts
|
|
@@ -71,7 +71,7 @@ interface EmailOTPOptions {
|
|
|
71
71
|
}
|
|
72
72
|
declare const emailOTP: (options: EmailOTPOptions) => {
|
|
73
73
|
id: "email-otp";
|
|
74
|
-
init(ctx:
|
|
74
|
+
init(ctx: _gatwech_core13.AuthContext<_gatwech_core13.PayvoAuthOptions>): {
|
|
75
75
|
options: {
|
|
76
76
|
emailVerification: {
|
|
77
77
|
sendVerificationEmail(data: {
|
|
@@ -102,7 +102,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
102
102
|
} & {
|
|
103
103
|
asResponse?: boolean;
|
|
104
104
|
returnHeaders?: boolean;
|
|
105
|
-
use?:
|
|
105
|
+
use?: better_call147.Middleware[];
|
|
106
106
|
path?: string;
|
|
107
107
|
} & {
|
|
108
108
|
asResponse?: AsResponse | undefined;
|
|
@@ -175,7 +175,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
175
175
|
} & {
|
|
176
176
|
asResponse?: boolean;
|
|
177
177
|
returnHeaders?: boolean;
|
|
178
|
-
use?:
|
|
178
|
+
use?: better_call147.Middleware[];
|
|
179
179
|
path?: string;
|
|
180
180
|
} & {
|
|
181
181
|
asResponse?: AsResponse | undefined;
|
|
@@ -265,7 +265,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
265
265
|
} & {
|
|
266
266
|
asResponse?: boolean;
|
|
267
267
|
returnHeaders?: boolean;
|
|
268
|
-
use?:
|
|
268
|
+
use?: better_call147.Middleware[];
|
|
269
269
|
path?: string;
|
|
270
270
|
} & {
|
|
271
271
|
asResponse?: AsResponse | undefined;
|
|
@@ -350,7 +350,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
350
350
|
} & {
|
|
351
351
|
asResponse?: boolean;
|
|
352
352
|
returnHeaders?: boolean;
|
|
353
|
-
use?:
|
|
353
|
+
use?: better_call147.Middleware[];
|
|
354
354
|
path?: string;
|
|
355
355
|
} & {
|
|
356
356
|
asResponse?: AsResponse | undefined;
|
|
@@ -485,7 +485,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
485
485
|
} & {
|
|
486
486
|
asResponse?: boolean;
|
|
487
487
|
returnHeaders?: boolean;
|
|
488
|
-
use?:
|
|
488
|
+
use?: better_call147.Middleware[];
|
|
489
489
|
path?: string;
|
|
490
490
|
} & {
|
|
491
491
|
asResponse?: AsResponse | undefined;
|
|
@@ -587,7 +587,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
587
587
|
} & {
|
|
588
588
|
asResponse?: boolean;
|
|
589
589
|
returnHeaders?: boolean;
|
|
590
|
-
use?:
|
|
590
|
+
use?: better_call147.Middleware[];
|
|
591
591
|
path?: string;
|
|
592
592
|
} & {
|
|
593
593
|
asResponse?: AsResponse | undefined;
|
|
@@ -668,7 +668,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
668
668
|
} & {
|
|
669
669
|
asResponse?: boolean;
|
|
670
670
|
returnHeaders?: boolean;
|
|
671
|
-
use?:
|
|
671
|
+
use?: better_call147.Middleware[];
|
|
672
672
|
path?: string;
|
|
673
673
|
} & {
|
|
674
674
|
asResponse?: AsResponse | undefined;
|
|
@@ -749,7 +749,7 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
749
749
|
} & {
|
|
750
750
|
asResponse?: boolean;
|
|
751
751
|
returnHeaders?: boolean;
|
|
752
|
-
use?:
|
|
752
|
+
use?: better_call147.Middleware[];
|
|
753
753
|
path?: string;
|
|
754
754
|
} & {
|
|
755
755
|
asResponse?: AsResponse | undefined;
|
|
@@ -802,8 +802,8 @@ declare const emailOTP: (options: EmailOTPOptions) => {
|
|
|
802
802
|
};
|
|
803
803
|
hooks: {
|
|
804
804
|
after: {
|
|
805
|
-
matcher(context:
|
|
806
|
-
handler: (inputContext:
|
|
805
|
+
matcher(context: _gatwech_core13.HookEndpointContext): boolean;
|
|
806
|
+
handler: (inputContext: better_call147.MiddlewareInputContext<better_call147.MiddlewareOptions>) => Promise<void>;
|
|
807
807
|
}[];
|
|
808
808
|
};
|
|
809
809
|
$ERROR_CODES: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _gatwech_core45 from "@gatwech/core";
|
|
2
2
|
|
|
3
3
|
//#region src/plugins/captcha/constants.d.ts
|
|
4
4
|
declare const Providers: {
|
|
@@ -34,7 +34,7 @@ type CaptchaOptions = GoogleRecaptchaOptions | CloudflareTurnstileOptions | HCap
|
|
|
34
34
|
//#region src/plugins/captcha/index.d.ts
|
|
35
35
|
declare const captcha: (options: CaptchaOptions) => {
|
|
36
36
|
id: "captcha";
|
|
37
|
-
onRequest: (request: Request, ctx:
|
|
37
|
+
onRequest: (request: Request, ctx: _gatwech_core45.AuthContext<_gatwech_core45.PayvoAuthOptions>) => Promise<{
|
|
38
38
|
response: Response;
|
|
39
39
|
} | undefined>;
|
|
40
40
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { g as User } from "./index-
|
|
2
|
-
import * as
|
|
1
|
+
import { g as User } from "./index-CTjXncwM.mjs";
|
|
2
|
+
import * as _gatwech_core11 from "@gatwech/core";
|
|
3
3
|
import { GenericEndpointContext } from "@gatwech/core";
|
|
4
4
|
import * as _gatwech_core_oauth20 from "@gatwech/core/oauth2";
|
|
5
5
|
import { OAuth2Tokens, OAuth2UserInfo, OAuthProvider } from "@gatwech/core/oauth2";
|
|
6
|
-
import * as
|
|
6
|
+
import * as better_call142 from "better-call";
|
|
7
7
|
import * as z$1 from "zod";
|
|
8
8
|
|
|
9
9
|
//#region src/plugins/generic-oauth/index.d.ts
|
|
@@ -136,7 +136,7 @@ interface GenericOAuthOptions {
|
|
|
136
136
|
*/
|
|
137
137
|
declare const genericOAuth: (options: GenericOAuthOptions) => {
|
|
138
138
|
id: "generic-oauth";
|
|
139
|
-
init: (ctx:
|
|
139
|
+
init: (ctx: _gatwech_core11.AuthContext<_gatwech_core11.PayvoAuthOptions>) => {
|
|
140
140
|
context: {
|
|
141
141
|
socialProviders: OAuthProvider<Record<string, any>, Partial<_gatwech_core_oauth20.ProviderOptions<any>>>[];
|
|
142
142
|
};
|
|
@@ -182,7 +182,7 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
|
|
|
182
182
|
} & {
|
|
183
183
|
asResponse?: boolean;
|
|
184
184
|
returnHeaders?: boolean;
|
|
185
|
-
use?:
|
|
185
|
+
use?: better_call142.Middleware[];
|
|
186
186
|
path?: string;
|
|
187
187
|
} & {
|
|
188
188
|
asResponse?: AsResponse | undefined;
|
|
@@ -262,7 +262,7 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
|
|
|
262
262
|
} & {
|
|
263
263
|
asResponse?: boolean;
|
|
264
264
|
returnHeaders?: boolean;
|
|
265
|
-
use?:
|
|
265
|
+
use?: better_call142.Middleware[];
|
|
266
266
|
path?: string;
|
|
267
267
|
} & {
|
|
268
268
|
asResponse?: AsResponse | undefined;
|
|
@@ -343,7 +343,7 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
|
|
|
343
343
|
} & {
|
|
344
344
|
asResponse?: boolean;
|
|
345
345
|
returnHeaders?: boolean;
|
|
346
|
-
use?:
|
|
346
|
+
use?: better_call142.Middleware[];
|
|
347
347
|
path?: string;
|
|
348
348
|
} & {
|
|
349
349
|
asResponse?: AsResponse | undefined;
|
|
@@ -366,7 +366,7 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
|
|
|
366
366
|
scopes: z$1.ZodOptional<z$1.ZodArray<z$1.ZodString>>;
|
|
367
367
|
errorCallbackURL: z$1.ZodOptional<z$1.ZodString>;
|
|
368
368
|
}, z$1.core.$strip>;
|
|
369
|
-
use: ((inputContext:
|
|
369
|
+
use: ((inputContext: better_call142.MiddlewareInputContext<better_call142.MiddlewareOptions>) => Promise<{
|
|
370
370
|
session: {
|
|
371
371
|
session: Record<string, any> & {
|
|
372
372
|
id: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as better_call111 from "better-call";
|
|
2
2
|
import * as z$1 from "zod";
|
|
3
3
|
|
|
4
4
|
//#region src/plugins/one-tap/index.d.ts
|
|
@@ -38,7 +38,7 @@ declare const oneTap: (options?: OneTapOptions | undefined) => {
|
|
|
38
38
|
} & {
|
|
39
39
|
asResponse?: boolean;
|
|
40
40
|
returnHeaders?: boolean;
|
|
41
|
-
use?:
|
|
41
|
+
use?: better_call111.Middleware[];
|
|
42
42
|
path?: string;
|
|
43
43
|
} & {
|
|
44
44
|
asResponse?: AsResponse | undefined;
|