better-auth 1.4.2-beta.2 → 1.4.2-beta.4
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/auth/minimal.d.mts +1 -1
- package/dist/client/index.d.mts +1 -1
- package/dist/client/lynx/index.d.mts +17 -17
- package/dist/client/plugins/index.d.mts +33 -33
- package/dist/client/react/index.d.mts +1 -1
- package/dist/client/solid/index.d.mts +15 -15
- package/dist/client/svelte/index.d.mts +17 -17
- package/dist/client/vue/index.d.mts +1 -1
- package/dist/cookies/index.d.mts +2 -2
- package/dist/db/index.d.mts +1 -1
- package/dist/{index-D8lKwnHW.d.mts → index-5hoDwGsC.d.mts} +4 -4
- package/dist/{index-B8iZdexj.d.mts → index-8qta2CLk.d.mts} +6 -6
- package/dist/{index-DjxXMbRL.d.mts → index-B3owHI1p.d.mts} +6 -6
- package/dist/{index-CYZkpU1a.d.mts → index-BCE_X8rq.d.mts} +31 -31
- package/dist/{index-BnHKsXEx.d.mts → index-BMWasIyr.d.mts} +2 -2
- package/dist/{index-BIMkk_Is.d.mts → index-BaXNkF5E.d.mts} +9 -9
- package/dist/{index-CpQt5ADy.d.mts → index-ByqTLVKc.d.mts} +337 -337
- package/dist/{index-3xdcOhdN.d.mts → index-C5Jwdf1z.d.mts} +3 -3
- package/dist/{index-DnXfdN_t.d.mts → index-C68ILwLf.d.mts} +3 -3
- package/dist/{index-CF_nUlMh.d.mts → index-CAhRHwXI.d.mts} +10 -10
- package/dist/{index-CJhWbySX.d.mts → index-CPjGb_ru.d.mts} +10 -10
- package/dist/{index-CoEZS0aP.d.mts → index-CdJFONwC.d.mts} +163 -163
- package/dist/{index-C-9zeT9-.d.mts → index-CuWf7oAq.d.mts} +5 -5
- package/dist/{index-ZUjXNTd3.d.mts → index-DBcQnmQv.d.mts} +3 -3
- package/dist/{index-CRLTcfaR.d.mts → index-DEQkYuXb.d.mts} +6 -6
- package/dist/{index-DxC0Oz-W.d.mts → index-DEn45P4J.d.mts} +14 -14
- package/dist/{index-CgXEU_AF.d.mts → index-DRHyXDvb.d.mts} +6 -6
- package/dist/{index-f6cpQBBQ.d.mts → index-DmXfXd2r.d.mts} +10 -10
- package/dist/{index-qbWQLec6.d.mts → index-DuvnR38d.d.mts} +6 -6
- package/dist/{index-BiX0SvHm.d.mts → index-a2S_5MKw.d.mts} +1 -1
- package/dist/{index-CQ1783c3.d.mts → index-hwZnuAAY.d.mts} +8 -8
- package/dist/{index-4w_p-JEd.d.mts → index-toYrE8p0.d.mts} +2 -2
- 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/svelte-kit.d.mts +1 -1
- package/dist/integrations/tanstack-start.d.mts +4 -4
- package/dist/oauth2/index.d.mts +1 -1
- package/dist/plugins/admin/access/index.d.mts +21 -21
- package/dist/plugins/admin/index.d.mts +21 -21
- package/dist/plugins/anonymous/index.d.mts +2 -2
- 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 +21 -21
- 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/oidc-provider/index.d.mts +21 -21
- package/dist/plugins/one-tap/index.d.mts +1 -1
- package/dist/plugins/one-time-token/index.d.mts +2 -2
- package/dist/plugins/open-api/index.d.mts +1 -1
- package/dist/plugins/organization/access/index.d.mts +21 -21
- package/dist/plugins/organization/index.d.mts +21 -21
- package/dist/plugins/phone-number/index.d.mts +2 -2
- package/dist/plugins/siwe/index.d.mts +2 -2
- package/dist/plugins/two-factor/index.d.mts +2 -2
- package/dist/plugins/username/index.d.mts +1 -1
- package/dist/test-utils/index.d.mts +21 -21
- package/dist/types/index.d.mts +1 -1
- package/package.json +3 -3
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $t as AdapterSchemaCreation, an as Where$1, in as TransactionAdapter } from "../index-
|
|
1
|
+
import { $t as AdapterSchemaCreation, an as Where$1, in as TransactionAdapter } from "../index-CdJFONwC.mjs";
|
|
2
2
|
import "../types-CRiHq5rJ.mjs";
|
|
3
3
|
import { u as Prettify } from "../helper-DU33OcfW.mjs";
|
|
4
4
|
import "../index-CNCxG_Zo.mjs";
|
package/dist/api/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as createEmailVerificationToken, A as deleteUser, B as getSessionFromCtx, C as createAuthEndpoint, D as router, E as optionsMiddleware, F as signOut, G as revokeSessions, H as requestOnlySessionMiddleware, I as signInEmail, J as requestPasswordReset, K as sensitiveSessionMiddleware, L as signInSocial, M as setPassword, N as updateUser, O as changeEmail, P as signUpEmail, Q as error, R as freshSessionMiddleware, S as checkEndpointConflicts, T as getEndpoints, U as revokeOtherSessions, V as listSessions, W as revokeSession, X as resetPassword, Y as requestPasswordResetCallback, Z as ok, at as getAccessToken, b as AuthEndpoint, ct as refreshToken, dt as originCheckMiddleware, et as sendVerificationEmail, ft as getOAuthState, it as accountInfo, j as deleteUserCallback, k as changePassword, lt as unlinkAccount, nt as verifyEmail, ot as linkSocialAccount, pt as getIp, q as sessionMiddleware, rt as callbackOAuth, st as listUserAccounts, tt as sendVerificationEmailFn, ut as originCheck, w as createAuthMiddleware, x as AuthMiddleware, y as APIError, z as getSession } from "../index-
|
|
1
|
+
import { $ as createEmailVerificationToken, A as deleteUser, B as getSessionFromCtx, C as createAuthEndpoint, D as router, E as optionsMiddleware, F as signOut, G as revokeSessions, H as requestOnlySessionMiddleware, I as signInEmail, J as requestPasswordReset, K as sensitiveSessionMiddleware, L as signInSocial, M as setPassword, N as updateUser, O as changeEmail, P as signUpEmail, Q as error, R as freshSessionMiddleware, S as checkEndpointConflicts, T as getEndpoints, U as revokeOtherSessions, V as listSessions, W as revokeSession, X as resetPassword, Y as requestPasswordResetCallback, Z as ok, at as getAccessToken, b as AuthEndpoint, ct as refreshToken, dt as originCheckMiddleware, et as sendVerificationEmail, ft as getOAuthState, it as accountInfo, j as deleteUserCallback, k as changePassword, lt as unlinkAccount, nt as verifyEmail, ot as linkSocialAccount, pt as getIp, q as sessionMiddleware, rt as callbackOAuth, st as listUserAccounts, tt as sendVerificationEmailFn, ut as originCheck, w as createAuthMiddleware, x as AuthMiddleware, y as APIError, z as getSession } from "../index-CdJFONwC.mjs";
|
|
2
2
|
import "../types-CRiHq5rJ.mjs";
|
|
3
3
|
import "../helper-DU33OcfW.mjs";
|
|
4
4
|
import "../index-CNCxG_Zo.mjs";
|
package/dist/auth/minimal.d.mts
CHANGED
package/dist/client/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { At as BroadcastMessage, Ct as OnlineManager, Dt as kFocusManager, Et as FocusManager, Mt as kBroadcastChannel, Ot as BroadcastChannel, St as OnlineListener, Tt as FocusListener, _n as InferSessionFromClient, _t as AuthClient, bn as SessionQueryParams, bt as createSessionRefreshManager, cn as BetterAuthClientPlugin, dn as ClientStore, fn as InferActions, gn as InferPluginsFromClient, gt as Primitive, hn as InferErrorCodes, ht as InferPlugin, jt as getGlobalBroadcastChannel, kt as BroadcastListener, ln as ClientAtomListener, mn as InferClientAPI, mt as InferAuth, on as AtomListener, pn as InferAdditionalFromClient, sn as BetterAuthClientOptions, un as ClientOptions, vn as InferUserFromClient, vt as createAuthClient, wt as kOnlineManager, xn as Store, xt as useAuthQuery, yn as IsSignal, yt as SessionRefreshOptions } from "../index-
|
|
1
|
+
import { At as BroadcastMessage, Ct as OnlineManager, Dt as kFocusManager, Et as FocusManager, Mt as kBroadcastChannel, Ot as BroadcastChannel, St as OnlineListener, Tt as FocusListener, _n as InferSessionFromClient, _t as AuthClient, bn as SessionQueryParams, bt as createSessionRefreshManager, cn as BetterAuthClientPlugin, dn as ClientStore, fn as InferActions, gn as InferPluginsFromClient, gt as Primitive, hn as InferErrorCodes, ht as InferPlugin, jt as getGlobalBroadcastChannel, kt as BroadcastListener, ln as ClientAtomListener, mn as InferClientAPI, mt as InferAuth, on as AtomListener, pn as InferAdditionalFromClient, sn as BetterAuthClientOptions, un as ClientOptions, vn as InferUserFromClient, vt as createAuthClient, wt as kOnlineManager, xn as Store, xt as useAuthQuery, yn as IsSignal, yt as SessionRefreshOptions } from "../index-CdJFONwC.mjs";
|
|
2
2
|
import "../types-CRiHq5rJ.mjs";
|
|
3
3
|
import { a as LiteralNumber, c as OmitId, d as PrettifyDeep, 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-DU33OcfW.mjs";
|
|
4
4
|
import { a as Role, c as Subset, i as AccessControl, n as createAccessControl, o as Statements, r as role, s as SubArray, t as AuthorizeResponse } from "../index-CNCxG_Zo.mjs";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { bn as SessionQueryParams, fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-
|
|
1
|
+
import { bn as SessionQueryParams, fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import "../../index-CNCxG_Zo.mjs";
|
|
5
5
|
import "../../plugins-Brc8BsoZ.mjs";
|
|
6
6
|
import { BetterAuthClientOptions, BetterAuthClientPlugin } from "@better-auth/core";
|
|
7
7
|
import { BASE_ERROR_CODES } from "@better-auth/core/error";
|
|
8
|
-
import * as
|
|
8
|
+
import * as nanostores2 from "nanostores";
|
|
9
9
|
import { Store, StoreValue } from "nanostores";
|
|
10
|
-
import * as
|
|
10
|
+
import * as _better_fetch_fetch67 from "@better-fetch/fetch";
|
|
11
11
|
import { BetterFetchError } from "@better-fetch/fetch";
|
|
12
12
|
import { DependencyList } from "@lynx-js/react";
|
|
13
13
|
export * from "nanostores";
|
|
@@ -96,27 +96,27 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
96
96
|
error: null;
|
|
97
97
|
} ? S : Res : never>;
|
|
98
98
|
};
|
|
99
|
-
$fetch:
|
|
100
|
-
plugins: (
|
|
99
|
+
$fetch: _better_fetch_fetch67.BetterFetch<{
|
|
100
|
+
plugins: (_better_fetch_fetch67.BetterFetchPlugin | {
|
|
101
101
|
id: string;
|
|
102
102
|
name: string;
|
|
103
103
|
hooks: {
|
|
104
|
-
onSuccess(context:
|
|
104
|
+
onSuccess(context: _better_fetch_fetch67.SuccessContext<any>): void;
|
|
105
105
|
};
|
|
106
106
|
} | {
|
|
107
107
|
id: string;
|
|
108
108
|
name: string;
|
|
109
109
|
hooks: {
|
|
110
|
-
onRequest<T extends Record<string, any>>(context:
|
|
110
|
+
onRequest<T extends Record<string, any>>(context: _better_fetch_fetch67.RequestContext<T>): void;
|
|
111
111
|
};
|
|
112
112
|
} | {
|
|
113
113
|
id: string;
|
|
114
114
|
name: string;
|
|
115
115
|
hooks: {
|
|
116
|
-
onSuccess: ((context:
|
|
117
|
-
onError: ((context:
|
|
118
|
-
onRequest: (<T extends Record<string, any>>(context:
|
|
119
|
-
onResponse: ((context:
|
|
116
|
+
onSuccess: ((context: _better_fetch_fetch67.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
117
|
+
onError: ((context: _better_fetch_fetch67.ErrorContext) => Promise<void> | void) | undefined;
|
|
118
|
+
onRequest: (<T extends Record<string, any>>(context: _better_fetch_fetch67.RequestContext<T>) => Promise<_better_fetch_fetch67.RequestContext | void> | _better_fetch_fetch67.RequestContext | void) | undefined;
|
|
119
|
+
onResponse: ((context: _better_fetch_fetch67.ResponseContext) => Promise<Response | void | _better_fetch_fetch67.ResponseContext> | Response | _better_fetch_fetch67.ResponseContext | void) | undefined;
|
|
120
120
|
};
|
|
121
121
|
})[];
|
|
122
122
|
cache?: RequestCache | undefined;
|
|
@@ -136,12 +136,12 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
136
136
|
referrerPolicy?: ReferrerPolicy | undefined;
|
|
137
137
|
signal?: (AbortSignal | null) | undefined;
|
|
138
138
|
window?: null | undefined;
|
|
139
|
-
onRetry?: ((response:
|
|
139
|
+
onRetry?: ((response: _better_fetch_fetch67.ResponseContext) => Promise<void> | void) | undefined;
|
|
140
140
|
hookOptions?: {
|
|
141
141
|
cloneResponse?: boolean;
|
|
142
142
|
} | undefined;
|
|
143
143
|
timeout?: number | undefined;
|
|
144
|
-
customFetchImpl:
|
|
144
|
+
customFetchImpl: _better_fetch_fetch67.FetchEsque;
|
|
145
145
|
baseURL: string;
|
|
146
146
|
throw?: boolean | undefined;
|
|
147
147
|
auth?: ({
|
|
@@ -161,17 +161,17 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
161
161
|
params?: any;
|
|
162
162
|
duplex?: "full" | "half" | undefined;
|
|
163
163
|
jsonParser: (text: string) => Promise<any> | any;
|
|
164
|
-
retry?:
|
|
164
|
+
retry?: _better_fetch_fetch67.RetryOptions | undefined;
|
|
165
165
|
retryAttempt?: number | undefined;
|
|
166
|
-
output?: (
|
|
167
|
-
errorSchema?:
|
|
166
|
+
output?: (_better_fetch_fetch67.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
167
|
+
errorSchema?: _better_fetch_fetch67.StandardSchemaV1 | undefined;
|
|
168
168
|
disableValidation?: boolean | undefined;
|
|
169
169
|
disableSignal?: boolean | undefined;
|
|
170
170
|
}, unknown, unknown, {}>;
|
|
171
171
|
$store: {
|
|
172
172
|
notify: (signal?: (Omit<string, "$sessionSignal"> | "$sessionSignal") | undefined) => void;
|
|
173
173
|
listen: (signal: Omit<string, "$sessionSignal"> | "$sessionSignal", listener: (value: boolean, oldValue?: boolean | undefined) => void) => void;
|
|
174
|
-
atoms: Record<string,
|
|
174
|
+
atoms: Record<string, nanostores2.WritableAtom<any>>;
|
|
175
175
|
};
|
|
176
176
|
$ERROR_CODES: PrettifyDeep<InferErrorCodes<Option> & typeof BASE_ERROR_CODES>;
|
|
177
177
|
};
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
import { Un as InferAdditionalFieldsFromPluginOptions, bn as SessionQueryParams, r as BetterAuthOptions$1 } from "../../index-
|
|
1
|
+
import { Un as InferAdditionalFieldsFromPluginOptions, bn as SessionQueryParams, r as BetterAuthOptions$1 } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import { a as Role, i as AccessControl, o as Statements } from "../../index-CNCxG_Zo.mjs";
|
|
5
5
|
import "../../plugins-Brc8BsoZ.mjs";
|
|
6
|
-
import { B as OrganizationOptions, C as Organization, D as Team, T as OrganizationRole, _ as InferTeam, _t as admin, at as OAuthAccessToken, bt as SessionWithImpersonatedBy, c as OrganizationPlugin, ct as TokenBody, f as InferInvitation, gt as ApiKeyOptions, ht as ApiKey, it as CodeVerificationValue, k as TeamMember, m as InferOrganization, nt as AuthorizationQuery, ot as OIDCMetadata, p as InferMember, pt as apiKey, rt as Client, st as OIDCOptions, tt as oidcProvider, v as Invitation, vt as AdminOptions, x as Member, xt as UserWithRole, yt as InferAdminRolesFromOption } from "../../index-
|
|
7
|
-
import { i as schema, n as AnonymousOptions, r as UserWithAnonymous, t as anonymous } from "../../index-
|
|
8
|
-
import "../../index-
|
|
9
|
-
import "../../index-
|
|
10
|
-
import "../../index-
|
|
11
|
-
import { n as deviceAuthorization } from "../../index-
|
|
12
|
-
import { n as emailOTP } from "../../index-
|
|
13
|
-
import { _ as Auth0Options, a as SlackOptions, c as okta, d as LineOptions, f as line, g as hubspot, h as HubSpotOptions, i as genericOAuth, l as MicrosoftEntraIdOptions, m as keycloak, n as GenericOAuthConfig, o as slack, p as KeycloakOptions, r as GenericOAuthOptions, s as OktaOptions, t as BaseOAuthProviderOptions, u as microsoftEntraId, v as auth0 } from "../../index-
|
|
14
|
-
import "../../index-
|
|
15
|
-
import { c as Jwk, l as JwtOptions, o as JWKOptions, s as JWSAlgorithms, t as jwt } from "../../index-
|
|
16
|
-
import { n as magicLink } from "../../index-
|
|
17
|
-
import { n as multiSession, t as MultiSessionConfig } from "../../index-
|
|
18
|
-
import "../../index-
|
|
19
|
-
import "../../index-
|
|
20
|
-
import { n as oneTimeToken, t as OneTimeTokenOptions } from "../../index-
|
|
21
|
-
import "../../index-
|
|
22
|
-
import { n as PhoneNumberOptions, r as UserWithPhoneNumber, t as phoneNumber } from "../../index-
|
|
23
|
-
import { n as siwe } from "../../index-
|
|
24
|
-
import { a as TwoFactorProvider, c as TOTPOptions, d as otp2fa, f as BackupCodeOptions, g as verifyBackupCode, h as getBackupCodes, i as TwoFactorOptions, l as totp2fa, m as generateBackupCodes, n as twoFactorClient, o as TwoFactorTable, p as backupCode2fa, s as UserWithTwoFactor, u as OTPOptions } from "../../index-
|
|
25
|
-
import { n as username } from "../../index-
|
|
26
|
-
import * as
|
|
6
|
+
import { B as OrganizationOptions, C as Organization, D as Team, T as OrganizationRole, _ as InferTeam, _t as admin, at as OAuthAccessToken, bt as SessionWithImpersonatedBy, c as OrganizationPlugin, ct as TokenBody, f as InferInvitation, gt as ApiKeyOptions, ht as ApiKey, it as CodeVerificationValue, k as TeamMember, m as InferOrganization, nt as AuthorizationQuery, ot as OIDCMetadata, p as InferMember, pt as apiKey, rt as Client, st as OIDCOptions, tt as oidcProvider, v as Invitation, vt as AdminOptions, x as Member, xt as UserWithRole, yt as InferAdminRolesFromOption } from "../../index-ByqTLVKc.mjs";
|
|
7
|
+
import { i as schema, n as AnonymousOptions, r as UserWithAnonymous, t as anonymous } from "../../index-DuvnR38d.mjs";
|
|
8
|
+
import "../../index-DRHyXDvb.mjs";
|
|
9
|
+
import "../../index-BMWasIyr.mjs";
|
|
10
|
+
import "../../index-8qta2CLk.mjs";
|
|
11
|
+
import { n as deviceAuthorization } from "../../index-B3owHI1p.mjs";
|
|
12
|
+
import { n as emailOTP } from "../../index-DmXfXd2r.mjs";
|
|
13
|
+
import { _ as Auth0Options, a as SlackOptions, c as okta, d as LineOptions, f as line, g as hubspot, h as HubSpotOptions, i as genericOAuth, l as MicrosoftEntraIdOptions, m as keycloak, n as GenericOAuthConfig, o as slack, p as KeycloakOptions, r as GenericOAuthOptions, s as OktaOptions, t as BaseOAuthProviderOptions, u as microsoftEntraId, v as auth0 } from "../../index-DEQkYuXb.mjs";
|
|
14
|
+
import "../../index-DBcQnmQv.mjs";
|
|
15
|
+
import { c as Jwk, l as JwtOptions, o as JWKOptions, s as JWSAlgorithms, t as jwt } from "../../index-CAhRHwXI.mjs";
|
|
16
|
+
import { n as magicLink } from "../../index-5hoDwGsC.mjs";
|
|
17
|
+
import { n as multiSession, t as MultiSessionConfig } from "../../index-BaXNkF5E.mjs";
|
|
18
|
+
import "../../index-hwZnuAAY.mjs";
|
|
19
|
+
import "../../index-toYrE8p0.mjs";
|
|
20
|
+
import { n as oneTimeToken, t as OneTimeTokenOptions } from "../../index-CuWf7oAq.mjs";
|
|
21
|
+
import "../../index-C68ILwLf.mjs";
|
|
22
|
+
import { n as PhoneNumberOptions, r as UserWithPhoneNumber, t as phoneNumber } from "../../index-CPjGb_ru.mjs";
|
|
23
|
+
import { n as siwe } from "../../index-C5Jwdf1z.mjs";
|
|
24
|
+
import { a as TwoFactorProvider, c as TOTPOptions, d as otp2fa, f as BackupCodeOptions, g as verifyBackupCode, h as getBackupCodes, i as TwoFactorOptions, l as totp2fa, m as generateBackupCodes, n as twoFactorClient, o as TwoFactorTable, p as backupCode2fa, s as UserWithTwoFactor, u as OTPOptions } from "../../index-BCE_X8rq.mjs";
|
|
25
|
+
import { n as username } from "../../index-DEn45P4J.mjs";
|
|
26
|
+
import * as _better_auth_core28 from "@better-auth/core";
|
|
27
27
|
import { BetterAuthOptions, BetterAuthPlugin, ClientFetchOption } from "@better-auth/core";
|
|
28
28
|
import { DBFieldAttribute } from "@better-auth/core/db";
|
|
29
|
-
import * as
|
|
29
|
+
import * as nanostores5 from "nanostores";
|
|
30
30
|
import * as _better_fetch_fetch101 from "@better-fetch/fetch";
|
|
31
31
|
import { Auth } from "better-auth";
|
|
32
32
|
|
|
@@ -387,7 +387,7 @@ interface GoogleOneTapActionOptions extends Omit<GoogleOneTapOptions, "clientId"
|
|
|
387
387
|
}
|
|
388
388
|
declare const oneTapClient: (options: GoogleOneTapOptions) => {
|
|
389
389
|
id: "one-tap";
|
|
390
|
-
getActions: ($fetch: _better_fetch_fetch101.BetterFetch, _:
|
|
390
|
+
getActions: ($fetch: _better_fetch_fetch101.BetterFetch, _: _better_auth_core28.ClientStore) => {
|
|
391
391
|
oneTap: (opts?: GoogleOneTapActionOptions | undefined, fetchOptions?: ClientFetchOption | undefined) => Promise<void>;
|
|
392
392
|
};
|
|
393
393
|
getAtoms($fetch: _better_fetch_fetch101.BetterFetch): {};
|
|
@@ -489,7 +489,7 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
489
489
|
} ? true : false;
|
|
490
490
|
};
|
|
491
491
|
}>;
|
|
492
|
-
getActions: ($fetch: _better_fetch_fetch101.BetterFetch, _$store:
|
|
492
|
+
getActions: ($fetch: _better_fetch_fetch101.BetterFetch, _$store: _better_auth_core28.ClientStore, co: _better_auth_core28.BetterAuthClientOptions | undefined) => {
|
|
493
493
|
$Infer: {
|
|
494
494
|
ActiveOrganization: CO["teams"] extends {
|
|
495
495
|
enabled: true;
|
|
@@ -574,11 +574,11 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
574
574
|
};
|
|
575
575
|
};
|
|
576
576
|
getAtoms: ($fetch: _better_fetch_fetch101.BetterFetch) => {
|
|
577
|
-
$listOrg:
|
|
578
|
-
$activeOrgSignal:
|
|
579
|
-
$activeMemberSignal:
|
|
580
|
-
$activeMemberRoleSignal:
|
|
581
|
-
activeOrganization:
|
|
577
|
+
$listOrg: nanostores5.PreinitializedWritableAtom<boolean> & object;
|
|
578
|
+
$activeOrgSignal: nanostores5.PreinitializedWritableAtom<boolean> & object;
|
|
579
|
+
$activeMemberSignal: nanostores5.PreinitializedWritableAtom<boolean> & object;
|
|
580
|
+
$activeMemberRoleSignal: nanostores5.PreinitializedWritableAtom<boolean> & object;
|
|
581
|
+
activeOrganization: nanostores5.PreinitializedWritableAtom<{
|
|
582
582
|
data: Prettify<({
|
|
583
583
|
id: string;
|
|
584
584
|
name: string;
|
|
@@ -597,7 +597,7 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
597
597
|
query?: SessionQueryParams;
|
|
598
598
|
} | undefined) => Promise<void>;
|
|
599
599
|
}> & object;
|
|
600
|
-
listOrganizations:
|
|
600
|
+
listOrganizations: nanostores5.PreinitializedWritableAtom<{
|
|
601
601
|
data: ({
|
|
602
602
|
id: string;
|
|
603
603
|
name: string;
|
|
@@ -613,7 +613,7 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
613
613
|
query?: SessionQueryParams;
|
|
614
614
|
} | undefined) => Promise<void>;
|
|
615
615
|
}> & object;
|
|
616
|
-
activeMember:
|
|
616
|
+
activeMember: nanostores5.PreinitializedWritableAtom<{
|
|
617
617
|
data: {
|
|
618
618
|
id: string;
|
|
619
619
|
organizationId: string;
|
|
@@ -628,7 +628,7 @@ declare const organizationClient: <CO extends OrganizationClientOptions>(options
|
|
|
628
628
|
query?: SessionQueryParams;
|
|
629
629
|
} | undefined) => Promise<void>;
|
|
630
630
|
}> & object;
|
|
631
|
-
activeMemberRole:
|
|
631
|
+
activeMemberRole: nanostores5.PreinitializedWritableAtom<{
|
|
632
632
|
data: {
|
|
633
633
|
role: string;
|
|
634
634
|
} | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { bn as SessionQueryParams, fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-
|
|
1
|
+
import { bn as SessionQueryParams, fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import "../../index-CNCxG_Zo.mjs";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-
|
|
1
|
+
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import "../../index-CNCxG_Zo.mjs";
|
|
5
5
|
import "../../plugins-Brc8BsoZ.mjs";
|
|
6
6
|
import { BetterAuthClientOptions, BetterAuthClientPlugin } from "@better-auth/core";
|
|
7
7
|
import { BASE_ERROR_CODES } from "@better-auth/core/error";
|
|
8
|
-
import * as
|
|
8
|
+
import * as _better_fetch_fetch50 from "@better-fetch/fetch";
|
|
9
9
|
import { BetterFetchError } from "@better-fetch/fetch";
|
|
10
10
|
import { Accessor } from "solid-js";
|
|
11
11
|
export * from "nanostores";
|
|
@@ -49,27 +49,27 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
49
49
|
error: null;
|
|
50
50
|
} ? S : Res extends Record<string, any> ? Res : never : never>;
|
|
51
51
|
};
|
|
52
|
-
$fetch:
|
|
53
|
-
plugins: (
|
|
52
|
+
$fetch: _better_fetch_fetch50.BetterFetch<{
|
|
53
|
+
plugins: (_better_fetch_fetch50.BetterFetchPlugin | {
|
|
54
54
|
id: string;
|
|
55
55
|
name: string;
|
|
56
56
|
hooks: {
|
|
57
|
-
onSuccess(context:
|
|
57
|
+
onSuccess(context: _better_fetch_fetch50.SuccessContext<any>): void;
|
|
58
58
|
};
|
|
59
59
|
} | {
|
|
60
60
|
id: string;
|
|
61
61
|
name: string;
|
|
62
62
|
hooks: {
|
|
63
|
-
onRequest<T extends Record<string, any>>(context:
|
|
63
|
+
onRequest<T extends Record<string, any>>(context: _better_fetch_fetch50.RequestContext<T>): void;
|
|
64
64
|
};
|
|
65
65
|
} | {
|
|
66
66
|
id: string;
|
|
67
67
|
name: string;
|
|
68
68
|
hooks: {
|
|
69
|
-
onSuccess: ((context:
|
|
70
|
-
onError: ((context:
|
|
71
|
-
onRequest: (<T extends Record<string, any>>(context:
|
|
72
|
-
onResponse: ((context:
|
|
69
|
+
onSuccess: ((context: _better_fetch_fetch50.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
70
|
+
onError: ((context: _better_fetch_fetch50.ErrorContext) => Promise<void> | void) | undefined;
|
|
71
|
+
onRequest: (<T extends Record<string, any>>(context: _better_fetch_fetch50.RequestContext<T>) => Promise<_better_fetch_fetch50.RequestContext | void> | _better_fetch_fetch50.RequestContext | void) | undefined;
|
|
72
|
+
onResponse: ((context: _better_fetch_fetch50.ResponseContext) => Promise<Response | void | _better_fetch_fetch50.ResponseContext> | Response | _better_fetch_fetch50.ResponseContext | void) | undefined;
|
|
73
73
|
};
|
|
74
74
|
})[];
|
|
75
75
|
cache?: RequestCache | undefined;
|
|
@@ -89,12 +89,12 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
89
89
|
referrerPolicy?: ReferrerPolicy | undefined;
|
|
90
90
|
signal?: (AbortSignal | null) | undefined;
|
|
91
91
|
window?: null | undefined;
|
|
92
|
-
onRetry?: ((response:
|
|
92
|
+
onRetry?: ((response: _better_fetch_fetch50.ResponseContext) => Promise<void> | void) | undefined;
|
|
93
93
|
hookOptions?: {
|
|
94
94
|
cloneResponse?: boolean;
|
|
95
95
|
} | undefined;
|
|
96
96
|
timeout?: number | undefined;
|
|
97
|
-
customFetchImpl:
|
|
97
|
+
customFetchImpl: _better_fetch_fetch50.FetchEsque;
|
|
98
98
|
baseURL: string;
|
|
99
99
|
throw?: boolean | undefined;
|
|
100
100
|
auth?: ({
|
|
@@ -114,10 +114,10 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
114
114
|
params?: any;
|
|
115
115
|
duplex?: "full" | "half" | undefined;
|
|
116
116
|
jsonParser: (text: string) => Promise<any> | any;
|
|
117
|
-
retry?:
|
|
117
|
+
retry?: _better_fetch_fetch50.RetryOptions | undefined;
|
|
118
118
|
retryAttempt?: number | undefined;
|
|
119
|
-
output?: (
|
|
120
|
-
errorSchema?:
|
|
119
|
+
output?: (_better_fetch_fetch50.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
120
|
+
errorSchema?: _better_fetch_fetch50.StandardSchemaV1 | undefined;
|
|
121
121
|
disableValidation?: boolean | undefined;
|
|
122
122
|
disableSignal?: boolean | undefined;
|
|
123
123
|
}, unknown, unknown, {}>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-
|
|
1
|
+
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import "../../index-CNCxG_Zo.mjs";
|
|
5
5
|
import "../../plugins-Brc8BsoZ.mjs";
|
|
6
6
|
import { BetterAuthClientOptions, BetterAuthClientPlugin } from "@better-auth/core";
|
|
7
7
|
import { BASE_ERROR_CODES } from "@better-auth/core/error";
|
|
8
|
-
import * as
|
|
8
|
+
import * as nanostores1 from "nanostores";
|
|
9
9
|
import { Atom } from "nanostores";
|
|
10
|
-
import * as
|
|
10
|
+
import * as _better_fetch_fetch33 from "@better-fetch/fetch";
|
|
11
11
|
import { BetterFetchError } from "@better-fetch/fetch";
|
|
12
12
|
export * from "nanostores";
|
|
13
13
|
export * from "@better-fetch/fetch";
|
|
@@ -35,27 +35,27 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
35
35
|
isPending: boolean;
|
|
36
36
|
isRefetching: boolean;
|
|
37
37
|
}>;
|
|
38
|
-
$fetch:
|
|
39
|
-
plugins: (
|
|
38
|
+
$fetch: _better_fetch_fetch33.BetterFetch<{
|
|
39
|
+
plugins: (_better_fetch_fetch33.BetterFetchPlugin | {
|
|
40
40
|
id: string;
|
|
41
41
|
name: string;
|
|
42
42
|
hooks: {
|
|
43
|
-
onSuccess(context:
|
|
43
|
+
onSuccess(context: _better_fetch_fetch33.SuccessContext<any>): void;
|
|
44
44
|
};
|
|
45
45
|
} | {
|
|
46
46
|
id: string;
|
|
47
47
|
name: string;
|
|
48
48
|
hooks: {
|
|
49
|
-
onRequest<T extends Record<string, any>>(context:
|
|
49
|
+
onRequest<T extends Record<string, any>>(context: _better_fetch_fetch33.RequestContext<T>): void;
|
|
50
50
|
};
|
|
51
51
|
} | {
|
|
52
52
|
id: string;
|
|
53
53
|
name: string;
|
|
54
54
|
hooks: {
|
|
55
|
-
onSuccess: ((context:
|
|
56
|
-
onError: ((context:
|
|
57
|
-
onRequest: (<T extends Record<string, any>>(context:
|
|
58
|
-
onResponse: ((context:
|
|
55
|
+
onSuccess: ((context: _better_fetch_fetch33.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
56
|
+
onError: ((context: _better_fetch_fetch33.ErrorContext) => Promise<void> | void) | undefined;
|
|
57
|
+
onRequest: (<T extends Record<string, any>>(context: _better_fetch_fetch33.RequestContext<T>) => Promise<_better_fetch_fetch33.RequestContext | void> | _better_fetch_fetch33.RequestContext | void) | undefined;
|
|
58
|
+
onResponse: ((context: _better_fetch_fetch33.ResponseContext) => Promise<Response | void | _better_fetch_fetch33.ResponseContext> | Response | _better_fetch_fetch33.ResponseContext | void) | undefined;
|
|
59
59
|
};
|
|
60
60
|
})[];
|
|
61
61
|
cache?: RequestCache | undefined;
|
|
@@ -75,12 +75,12 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
75
75
|
referrerPolicy?: ReferrerPolicy | undefined;
|
|
76
76
|
signal?: (AbortSignal | null) | undefined;
|
|
77
77
|
window?: null | undefined;
|
|
78
|
-
onRetry?: ((response:
|
|
78
|
+
onRetry?: ((response: _better_fetch_fetch33.ResponseContext) => Promise<void> | void) | undefined;
|
|
79
79
|
hookOptions?: {
|
|
80
80
|
cloneResponse?: boolean;
|
|
81
81
|
} | undefined;
|
|
82
82
|
timeout?: number | undefined;
|
|
83
|
-
customFetchImpl:
|
|
83
|
+
customFetchImpl: _better_fetch_fetch33.FetchEsque;
|
|
84
84
|
baseURL: string;
|
|
85
85
|
throw?: boolean | undefined;
|
|
86
86
|
auth?: ({
|
|
@@ -100,17 +100,17 @@ declare function createAuthClient<Option extends BetterAuthClientOptions>(option
|
|
|
100
100
|
params?: any;
|
|
101
101
|
duplex?: "full" | "half" | undefined;
|
|
102
102
|
jsonParser: (text: string) => Promise<any> | any;
|
|
103
|
-
retry?:
|
|
103
|
+
retry?: _better_fetch_fetch33.RetryOptions | undefined;
|
|
104
104
|
retryAttempt?: number | undefined;
|
|
105
|
-
output?: (
|
|
106
|
-
errorSchema?:
|
|
105
|
+
output?: (_better_fetch_fetch33.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
106
|
+
errorSchema?: _better_fetch_fetch33.StandardSchemaV1 | undefined;
|
|
107
107
|
disableValidation?: boolean | undefined;
|
|
108
108
|
disableSignal?: boolean | undefined;
|
|
109
109
|
}, unknown, unknown, {}>;
|
|
110
110
|
$store: {
|
|
111
111
|
notify: (signal?: (Omit<string, "$sessionSignal"> | "$sessionSignal") | undefined) => void;
|
|
112
112
|
listen: (signal: Omit<string, "$sessionSignal"> | "$sessionSignal", listener: (value: boolean, oldValue?: boolean | undefined) => void) => void;
|
|
113
|
-
atoms: Record<string,
|
|
113
|
+
atoms: Record<string, nanostores1.WritableAtom<any>>;
|
|
114
114
|
};
|
|
115
115
|
$Infer: {
|
|
116
116
|
Session: NonNullable<InferClientAPI<Option> extends {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-
|
|
1
|
+
import { fn as InferActions, hn as InferErrorCodes, mn as InferClientAPI, yn as IsSignal } from "../../index-CdJFONwC.mjs";
|
|
2
2
|
import "../../types-CRiHq5rJ.mjs";
|
|
3
3
|
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-DU33OcfW.mjs";
|
|
4
4
|
import "../../index-CNCxG_Zo.mjs";
|
package/dist/cookies/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import "../index-
|
|
1
|
+
import "../index-CdJFONwC.mjs";
|
|
2
2
|
import "../types-CRiHq5rJ.mjs";
|
|
3
3
|
import "../helper-DU33OcfW.mjs";
|
|
4
4
|
import "../index-CNCxG_Zo.mjs";
|
|
5
5
|
import "../plugins-Brc8BsoZ.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-a2S_5MKw.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,4 +1,4 @@
|
|
|
1
|
-
import { $n as getBaseAdapter, An as parseInputData, Bn as convertFromDB, Cn as getWithHooks, Dn as parseAccountInput, En as mergeSchema, Fn as createInternalAdapter, Gn as InferFieldsFromPlugins, Hn as FieldAttributeToObject, In as getAuthTables, Jn as InferFieldsOutput, Kn as InferFieldsInput, Ln as getSchema, Mn as parseSessionOutput, Nn as parseUserInput, On as parseAccountOutput, Pn as parseUserOutput, Qn as getAdapter, Rn as getMigrations, Tn as toZodSchema, Un as InferAdditionalFieldsFromPluginOptions, Vn as convertToDB, Wn as InferFieldsFromOptions, Xn as PluginFieldAttribute, Yn as InferValueType, Zn as createFieldAttribute, jn as parseSessionInput, kn as parseAdditionalUserInput, qn as InferFieldsInputClient, wn as FieldAttributeToSchema, zn as matchType } from "../index-
|
|
1
|
+
import { $n as getBaseAdapter, An as parseInputData, Bn as convertFromDB, Cn as getWithHooks, Dn as parseAccountInput, En as mergeSchema, Fn as createInternalAdapter, Gn as InferFieldsFromPlugins, Hn as FieldAttributeToObject, In as getAuthTables, Jn as InferFieldsOutput, Kn as InferFieldsInput, Ln as getSchema, Mn as parseSessionOutput, Nn as parseUserInput, On as parseAccountOutput, Pn as parseUserOutput, Qn as getAdapter, Rn as getMigrations, Tn as toZodSchema, Un as InferAdditionalFieldsFromPluginOptions, Vn as convertToDB, Wn as InferFieldsFromOptions, Xn as PluginFieldAttribute, Yn as InferValueType, Zn as createFieldAttribute, jn as parseSessionInput, kn as parseAdditionalUserInput, qn as InferFieldsInputClient, wn as FieldAttributeToSchema, zn as matchType } from "../index-CdJFONwC.mjs";
|
|
2
2
|
import "../types-CRiHq5rJ.mjs";
|
|
3
3
|
import "../helper-DU33OcfW.mjs";
|
|
4
4
|
import "../index-CNCxG_Zo.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GenericEndpointContext } from "@better-auth/core";
|
|
2
|
-
import * as
|
|
2
|
+
import * as better_call172 from "better-call";
|
|
3
3
|
import * as z from "zod";
|
|
4
4
|
|
|
5
5
|
//#region src/plugins/magic-link/index.d.ts
|
|
@@ -68,7 +68,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
|
|
|
68
68
|
*
|
|
69
69
|
* @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/sign-in#api-method-sign-in-magic-link)
|
|
70
70
|
*/
|
|
71
|
-
signInMagicLink:
|
|
71
|
+
signInMagicLink: better_call172.StrictEndpoint<"/sign-in/magic-link", {
|
|
72
72
|
method: "POST";
|
|
73
73
|
requireHeaders: true;
|
|
74
74
|
body: z.ZodObject<{
|
|
@@ -121,7 +121,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
|
|
|
121
121
|
*
|
|
122
122
|
* @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/magic-link#api-method-magic-link-verify)
|
|
123
123
|
*/
|
|
124
|
-
magicLinkVerify:
|
|
124
|
+
magicLinkVerify: better_call172.StrictEndpoint<"/magic-link/verify", {
|
|
125
125
|
method: "GET";
|
|
126
126
|
query: z.ZodObject<{
|
|
127
127
|
token: z.ZodString;
|
|
@@ -129,7 +129,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
|
|
|
129
129
|
errorCallbackURL: z.ZodOptional<z.ZodString>;
|
|
130
130
|
newUserCallbackURL: z.ZodOptional<z.ZodString>;
|
|
131
131
|
}, z.core.$strip>;
|
|
132
|
-
use: ((inputContext:
|
|
132
|
+
use: ((inputContext: better_call172.MiddlewareInputContext<better_call172.MiddlewareOptions>) => Promise<void>)[];
|
|
133
133
|
requireHeaders: true;
|
|
134
134
|
metadata: {
|
|
135
135
|
openapi: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { m as InferUser, p as InferSession } from "./index-
|
|
2
|
-
import * as
|
|
1
|
+
import { m as InferUser, p as InferSession } from "./index-CdJFONwC.mjs";
|
|
2
|
+
import * as _better_auth_core2 from "@better-auth/core";
|
|
3
3
|
import { BetterAuthOptions, GenericEndpointContext } from "@better-auth/core";
|
|
4
|
-
import * as
|
|
4
|
+
import * as better_call132 from "better-call";
|
|
5
5
|
import * as z from "zod";
|
|
6
6
|
|
|
7
7
|
//#region src/plugins/custom-session/index.d.ts
|
|
@@ -19,12 +19,12 @@ declare const customSession: <Returns extends Record<string, any>, O extends Bet
|
|
|
19
19
|
id: "custom-session";
|
|
20
20
|
hooks: {
|
|
21
21
|
after: {
|
|
22
|
-
matcher: (ctx:
|
|
23
|
-
handler: (inputContext:
|
|
22
|
+
matcher: (ctx: _better_auth_core2.HookEndpointContext) => boolean;
|
|
23
|
+
handler: (inputContext: better_call132.MiddlewareInputContext<better_call132.MiddlewareOptions>) => Promise<Awaited<Returns>[] | undefined>;
|
|
24
24
|
}[];
|
|
25
25
|
};
|
|
26
26
|
endpoints: {
|
|
27
|
-
getSession:
|
|
27
|
+
getSession: better_call132.StrictEndpoint<"/get-session", {
|
|
28
28
|
method: "GET";
|
|
29
29
|
query: z.ZodOptional<z.ZodObject<{
|
|
30
30
|
disableCookieCache: z.ZodOptional<z.ZodUnion<[z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<boolean, string>>]>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as better_call135 from "better-call";
|
|
2
2
|
import * as z from "zod";
|
|
3
3
|
import { StringValue } from "ms";
|
|
4
4
|
|
|
@@ -91,7 +91,7 @@ declare const deviceAuthorization: (options?: Partial<DeviceAuthorizationOptions
|
|
|
91
91
|
};
|
|
92
92
|
};
|
|
93
93
|
endpoints: {
|
|
94
|
-
deviceCode:
|
|
94
|
+
deviceCode: better_call135.StrictEndpoint<"/device/code", {
|
|
95
95
|
method: "POST";
|
|
96
96
|
body: z.ZodObject<{
|
|
97
97
|
client_id: z.ZodString;
|
|
@@ -178,7 +178,7 @@ declare const deviceAuthorization: (options?: Partial<DeviceAuthorizationOptions
|
|
|
178
178
|
expires_in: number;
|
|
179
179
|
interval: number;
|
|
180
180
|
}>;
|
|
181
|
-
deviceToken:
|
|
181
|
+
deviceToken: better_call135.StrictEndpoint<"/device/token", {
|
|
182
182
|
method: "POST";
|
|
183
183
|
body: z.ZodObject<{
|
|
184
184
|
grant_type: z.ZodLiteral<"urn:ietf:params:oauth:grant-type:device_code">;
|
|
@@ -248,7 +248,7 @@ declare const deviceAuthorization: (options?: Partial<DeviceAuthorizationOptions
|
|
|
248
248
|
expires_in: number;
|
|
249
249
|
scope: string;
|
|
250
250
|
}>;
|
|
251
|
-
deviceVerify:
|
|
251
|
+
deviceVerify: better_call135.StrictEndpoint<"/device", {
|
|
252
252
|
method: "GET";
|
|
253
253
|
query: z.ZodObject<{
|
|
254
254
|
user_code: z.ZodString;
|
|
@@ -293,7 +293,7 @@ declare const deviceAuthorization: (options?: Partial<DeviceAuthorizationOptions
|
|
|
293
293
|
user_code: string;
|
|
294
294
|
status: string;
|
|
295
295
|
}>;
|
|
296
|
-
deviceApprove:
|
|
296
|
+
deviceApprove: better_call135.StrictEndpoint<"/device/approve", {
|
|
297
297
|
method: "POST";
|
|
298
298
|
body: z.ZodObject<{
|
|
299
299
|
userCode: z.ZodString;
|
|
@@ -334,7 +334,7 @@ declare const deviceAuthorization: (options?: Partial<DeviceAuthorizationOptions
|
|
|
334
334
|
}, {
|
|
335
335
|
success: boolean;
|
|
336
336
|
}>;
|
|
337
|
-
deviceDeny:
|
|
337
|
+
deviceDeny: better_call135.StrictEndpoint<"/device/deny", {
|
|
338
338
|
method: "POST";
|
|
339
339
|
body: z.ZodObject<{
|
|
340
340
|
userCode: z.ZodString;
|