better-auth 1.4.21 → 1.4.22
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/api/index.d.mts +407 -407
- package/dist/api/middlewares/origin-check.d.mts +4 -4
- package/dist/api/routes/account.d.mts +11 -11
- package/dist/api/routes/callback.d.mts +2 -2
- package/dist/api/routes/email-verification.d.mts +4 -4
- package/dist/api/routes/error.d.mts +2 -2
- package/dist/api/routes/ok.d.mts +2 -2
- package/dist/api/routes/password.d.mts +7 -7
- package/dist/api/routes/sign-in.d.mts +4 -4
- package/dist/api/routes/sign-out.d.mts +2 -2
- package/dist/api/routes/sign-up.d.mts +3 -3
- package/dist/api/routes/update-user.d.mts +13 -13
- package/dist/client/lynx/index.d.mts +15 -15
- package/dist/client/react/index.d.mts +15 -15
- package/dist/client/solid/index.d.mts +13 -13
- package/dist/client/svelte/index.d.mts +13 -13
- package/dist/client/vanilla.d.mts +15 -15
- package/dist/client/vue/index.d.mts +15 -15
- package/dist/db/field.d.mts +6 -6
- package/dist/integrations/next-js.d.mts +4 -4
- package/dist/integrations/svelte-kit.d.mts +2 -2
- package/dist/integrations/tanstack-start-solid.d.mts +4 -4
- package/dist/integrations/tanstack-start.d.mts +4 -4
- package/dist/plugins/admin/admin.d.mts +114 -114
- package/dist/plugins/anonymous/index.d.mts +5 -5
- package/dist/plugins/api-key/index.d.mts +79 -79
- package/dist/plugins/bearer/index.d.mts +6 -6
- package/dist/plugins/captcha/index.d.mts +2 -2
- package/dist/plugins/custom-session/index.d.mts +5 -5
- package/dist/plugins/device-authorization/index.d.mts +6 -6
- package/dist/plugins/email-otp/index.d.mts +52 -52
- package/dist/plugins/generic-oauth/index.d.mts +32 -32
- package/dist/plugins/haveibeenpwned/index.d.mts +3 -3
- package/dist/plugins/jwt/client.d.mts +2 -2
- package/dist/plugins/jwt/index.d.mts +7 -7
- package/dist/plugins/last-login-method/index.d.mts +4 -4
- package/dist/plugins/magic-link/index.d.mts +4 -4
- package/dist/plugins/mcp/index.d.mts +10 -10
- package/dist/plugins/multi-session/index.d.mts +9 -9
- package/dist/plugins/oauth-proxy/index.d.mts +8 -8
- package/dist/plugins/oidc-provider/index.d.mts +13 -13
- package/dist/plugins/one-tap/client.d.mts +4 -4
- package/dist/plugins/one-tap/index.d.mts +2 -2
- package/dist/plugins/one-time-token/index.d.mts +5 -5
- package/dist/plugins/open-api/index.d.mts +3 -3
- package/dist/plugins/organization/adapter.d.mts +24 -24
- package/dist/plugins/organization/client.d.mts +8 -8
- package/dist/plugins/organization/organization.d.mts +7 -7
- package/dist/plugins/organization/routes/crud-access-control.d.mts +22 -22
- package/dist/plugins/organization/routes/crud-invites.d.mts +69 -69
- package/dist/plugins/organization/routes/crud-members.d.mts +67 -67
- package/dist/plugins/organization/routes/crud-org.d.mts +59 -59
- package/dist/plugins/organization/routes/crud-team.d.mts +79 -79
- package/dist/plugins/phone-number/index.d.mts +33 -33
- package/dist/plugins/siwe/index.d.mts +3 -3
- package/dist/plugins/two-factor/backup-codes/index.d.mts +5 -5
- package/dist/plugins/two-factor/index.d.mts +16 -16
- package/dist/plugins/two-factor/otp/index.d.mts +3 -3
- package/dist/plugins/two-factor/totp/index.d.mts +5 -5
- package/dist/plugins/username/index.d.mts +9 -9
- package/dist/plugins/username/schema.d.mts +3 -3
- package/dist/test-utils/test-instance.d.mts +1225 -1225
- package/package.json +3 -3
package/dist/api/index.d.mts
CHANGED
|
@@ -23,17 +23,17 @@ import "./routes/index.mjs";
|
|
|
23
23
|
import { AuthContext, Awaitable, BetterAuthOptions, BetterAuthPlugin } from "@better-auth/core";
|
|
24
24
|
import { InternalLogger } from "@better-auth/core/env";
|
|
25
25
|
import * as _better_auth_core_oauth20 from "@better-auth/core/oauth2";
|
|
26
|
-
import * as
|
|
26
|
+
import * as better_call118 from "better-call";
|
|
27
27
|
import { APIError } from "better-call";
|
|
28
|
-
import * as
|
|
28
|
+
import * as zod88 from "zod";
|
|
29
29
|
import { AuthEndpoint, AuthMiddleware, createAuthEndpoint, createAuthMiddleware, optionsMiddleware } from "@better-auth/core/api";
|
|
30
|
-
import * as
|
|
30
|
+
import * as zod_v4_core16 from "zod/v4/core";
|
|
31
31
|
|
|
32
32
|
//#region src/api/index.d.ts
|
|
33
33
|
declare function checkEndpointConflicts(options: BetterAuthOptions, logger: InternalLogger): void;
|
|
34
34
|
declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<AuthContext>, options: Option): {
|
|
35
35
|
api: {
|
|
36
|
-
readonly ok:
|
|
36
|
+
readonly ok: better_call118.StrictEndpoint<"/ok", {
|
|
37
37
|
method: "GET";
|
|
38
38
|
metadata: {
|
|
39
39
|
openapi: {
|
|
@@ -63,7 +63,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
63
63
|
}, {
|
|
64
64
|
ok: boolean;
|
|
65
65
|
}>;
|
|
66
|
-
readonly error:
|
|
66
|
+
readonly error: better_call118.StrictEndpoint<"/error", {
|
|
67
67
|
method: "GET";
|
|
68
68
|
metadata: {
|
|
69
69
|
openapi: {
|
|
@@ -85,47 +85,47 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
85
85
|
scope: "server";
|
|
86
86
|
};
|
|
87
87
|
}, Response>;
|
|
88
|
-
readonly signInSocial:
|
|
88
|
+
readonly signInSocial: better_call118.StrictEndpoint<"/sign-in/social", {
|
|
89
89
|
method: "POST";
|
|
90
90
|
operationId: string;
|
|
91
|
-
body:
|
|
92
|
-
callbackURL:
|
|
93
|
-
newUserCallbackURL:
|
|
94
|
-
errorCallbackURL:
|
|
95
|
-
provider:
|
|
96
|
-
disableRedirect:
|
|
97
|
-
idToken:
|
|
98
|
-
token:
|
|
99
|
-
nonce:
|
|
100
|
-
accessToken:
|
|
101
|
-
refreshToken:
|
|
102
|
-
expiresAt:
|
|
103
|
-
},
|
|
104
|
-
scopes:
|
|
105
|
-
requestSignUp:
|
|
106
|
-
loginHint:
|
|
107
|
-
additionalData:
|
|
108
|
-
},
|
|
91
|
+
body: zod88.ZodObject<{
|
|
92
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
93
|
+
newUserCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
94
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
95
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
96
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
97
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
98
|
+
token: zod88.ZodString;
|
|
99
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
100
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
101
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
102
|
+
expiresAt: zod88.ZodOptional<zod88.ZodNumber>;
|
|
103
|
+
}, zod_v4_core16.$strip>>;
|
|
104
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
105
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
106
|
+
loginHint: zod88.ZodOptional<zod88.ZodString>;
|
|
107
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
108
|
+
}, zod_v4_core16.$strip>;
|
|
109
109
|
metadata: {
|
|
110
110
|
$Infer: {
|
|
111
|
-
body:
|
|
112
|
-
callbackURL:
|
|
113
|
-
newUserCallbackURL:
|
|
114
|
-
errorCallbackURL:
|
|
115
|
-
provider:
|
|
116
|
-
disableRedirect:
|
|
117
|
-
idToken:
|
|
118
|
-
token:
|
|
119
|
-
nonce:
|
|
120
|
-
accessToken:
|
|
121
|
-
refreshToken:
|
|
122
|
-
expiresAt:
|
|
123
|
-
},
|
|
124
|
-
scopes:
|
|
125
|
-
requestSignUp:
|
|
126
|
-
loginHint:
|
|
127
|
-
additionalData:
|
|
128
|
-
},
|
|
111
|
+
body: zod88.infer<zod88.ZodObject<{
|
|
112
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
113
|
+
newUserCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
114
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
115
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
116
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
117
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
118
|
+
token: zod88.ZodString;
|
|
119
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
120
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
121
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
122
|
+
expiresAt: zod88.ZodOptional<zod88.ZodNumber>;
|
|
123
|
+
}, zod_v4_core16.$strip>>;
|
|
124
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
125
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
126
|
+
loginHint: zod88.ZodOptional<zod88.ZodString>;
|
|
127
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
128
|
+
}, zod_v4_core16.$strip>>;
|
|
129
129
|
returned: {
|
|
130
130
|
redirect: boolean;
|
|
131
131
|
token?: string | undefined;
|
|
@@ -193,37 +193,37 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
193
193
|
image?: string | null | undefined;
|
|
194
194
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
195
195
|
}>;
|
|
196
|
-
readonly callbackOAuth:
|
|
196
|
+
readonly callbackOAuth: better_call118.StrictEndpoint<"/callback/:id", {
|
|
197
197
|
method: ("GET" | "POST")[];
|
|
198
198
|
operationId: string;
|
|
199
|
-
body:
|
|
200
|
-
code:
|
|
201
|
-
error:
|
|
202
|
-
device_id:
|
|
203
|
-
error_description:
|
|
204
|
-
state:
|
|
205
|
-
user:
|
|
206
|
-
},
|
|
207
|
-
query:
|
|
208
|
-
code:
|
|
209
|
-
error:
|
|
210
|
-
device_id:
|
|
211
|
-
error_description:
|
|
212
|
-
state:
|
|
213
|
-
user:
|
|
214
|
-
},
|
|
199
|
+
body: zod88.ZodOptional<zod88.ZodObject<{
|
|
200
|
+
code: zod88.ZodOptional<zod88.ZodString>;
|
|
201
|
+
error: zod88.ZodOptional<zod88.ZodString>;
|
|
202
|
+
device_id: zod88.ZodOptional<zod88.ZodString>;
|
|
203
|
+
error_description: zod88.ZodOptional<zod88.ZodString>;
|
|
204
|
+
state: zod88.ZodOptional<zod88.ZodString>;
|
|
205
|
+
user: zod88.ZodOptional<zod88.ZodString>;
|
|
206
|
+
}, zod_v4_core16.$strip>>;
|
|
207
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
208
|
+
code: zod88.ZodOptional<zod88.ZodString>;
|
|
209
|
+
error: zod88.ZodOptional<zod88.ZodString>;
|
|
210
|
+
device_id: zod88.ZodOptional<zod88.ZodString>;
|
|
211
|
+
error_description: zod88.ZodOptional<zod88.ZodString>;
|
|
212
|
+
state: zod88.ZodOptional<zod88.ZodString>;
|
|
213
|
+
user: zod88.ZodOptional<zod88.ZodString>;
|
|
214
|
+
}, zod_v4_core16.$strip>>;
|
|
215
215
|
metadata: {
|
|
216
216
|
allowedMediaTypes: string[];
|
|
217
217
|
scope: "server";
|
|
218
218
|
};
|
|
219
219
|
}, void>;
|
|
220
|
-
readonly getSession:
|
|
220
|
+
readonly getSession: better_call118.StrictEndpoint<"/get-session", {
|
|
221
221
|
method: "GET";
|
|
222
222
|
operationId: string;
|
|
223
|
-
query:
|
|
224
|
-
disableCookieCache:
|
|
225
|
-
disableRefresh:
|
|
226
|
-
},
|
|
223
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
224
|
+
disableCookieCache: zod88.ZodOptional<zod88.ZodCoercedBoolean<unknown>>;
|
|
225
|
+
disableRefresh: zod88.ZodOptional<zod88.ZodCoercedBoolean<unknown>>;
|
|
226
|
+
}, zod_v4_core16.$strip>>;
|
|
227
227
|
requireHeaders: true;
|
|
228
228
|
metadata: {
|
|
229
229
|
openapi: {
|
|
@@ -274,7 +274,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
274
274
|
image?: string | null | undefined;
|
|
275
275
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
276
276
|
} | null>;
|
|
277
|
-
readonly signOut:
|
|
277
|
+
readonly signOut: better_call118.StrictEndpoint<"/sign-out", {
|
|
278
278
|
method: "POST";
|
|
279
279
|
operationId: string;
|
|
280
280
|
requireHeaders: true;
|
|
@@ -304,18 +304,18 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
304
304
|
}, {
|
|
305
305
|
success: boolean;
|
|
306
306
|
}>;
|
|
307
|
-
readonly signUpEmail:
|
|
307
|
+
readonly signUpEmail: better_call118.StrictEndpoint<"/sign-up/email", {
|
|
308
308
|
method: "POST";
|
|
309
309
|
operationId: string;
|
|
310
|
-
use: ((inputContext:
|
|
311
|
-
body:
|
|
312
|
-
name:
|
|
313
|
-
email:
|
|
314
|
-
password:
|
|
315
|
-
image:
|
|
316
|
-
callbackURL:
|
|
317
|
-
rememberMe:
|
|
318
|
-
},
|
|
310
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
311
|
+
body: zod88.ZodIntersection<zod88.ZodObject<{
|
|
312
|
+
name: zod88.ZodString;
|
|
313
|
+
email: zod88.ZodEmail;
|
|
314
|
+
password: zod88.ZodString;
|
|
315
|
+
image: zod88.ZodOptional<zod88.ZodString>;
|
|
316
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
317
|
+
rememberMe: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
318
|
+
}, zod_v4_core16.$strip>, zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
319
319
|
metadata: {
|
|
320
320
|
allowedMediaTypes: string[];
|
|
321
321
|
$Infer: {
|
|
@@ -478,16 +478,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
478
478
|
image?: string | null | undefined;
|
|
479
479
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
480
480
|
}>;
|
|
481
|
-
readonly signInEmail:
|
|
481
|
+
readonly signInEmail: better_call118.StrictEndpoint<"/sign-in/email", {
|
|
482
482
|
method: "POST";
|
|
483
483
|
operationId: string;
|
|
484
|
-
use: ((inputContext:
|
|
485
|
-
body:
|
|
486
|
-
email:
|
|
487
|
-
password:
|
|
488
|
-
callbackURL:
|
|
489
|
-
rememberMe:
|
|
490
|
-
},
|
|
484
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
485
|
+
body: zod88.ZodObject<{
|
|
486
|
+
email: zod88.ZodString;
|
|
487
|
+
password: zod88.ZodString;
|
|
488
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
489
|
+
rememberMe: zod88.ZodOptional<zod88.ZodDefault<zod88.ZodBoolean>>;
|
|
490
|
+
}, zod_v4_core16.$strip>;
|
|
491
491
|
metadata: {
|
|
492
492
|
allowedMediaTypes: string[];
|
|
493
493
|
$Infer: {
|
|
@@ -563,16 +563,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
563
563
|
image?: string | null | undefined;
|
|
564
564
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
565
565
|
}>;
|
|
566
|
-
readonly resetPassword:
|
|
566
|
+
readonly resetPassword: better_call118.StrictEndpoint<"/reset-password", {
|
|
567
567
|
method: "POST";
|
|
568
568
|
operationId: string;
|
|
569
|
-
query:
|
|
570
|
-
token:
|
|
571
|
-
},
|
|
572
|
-
body:
|
|
573
|
-
newPassword:
|
|
574
|
-
token:
|
|
575
|
-
},
|
|
569
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
570
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
571
|
+
}, zod_v4_core16.$strip>>;
|
|
572
|
+
body: zod88.ZodObject<{
|
|
573
|
+
newPassword: zod88.ZodString;
|
|
574
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
575
|
+
}, zod_v4_core16.$strip>;
|
|
576
576
|
metadata: {
|
|
577
577
|
openapi: {
|
|
578
578
|
operationId: string;
|
|
@@ -599,11 +599,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
599
599
|
}, {
|
|
600
600
|
status: boolean;
|
|
601
601
|
}>;
|
|
602
|
-
readonly verifyPassword:
|
|
602
|
+
readonly verifyPassword: better_call118.StrictEndpoint<"/verify-password", {
|
|
603
603
|
method: "POST";
|
|
604
|
-
body:
|
|
605
|
-
password:
|
|
606
|
-
},
|
|
604
|
+
body: zod88.ZodObject<{
|
|
605
|
+
password: zod88.ZodString;
|
|
606
|
+
}, zod_v4_core16.$strip>;
|
|
607
607
|
metadata: {
|
|
608
608
|
scope: "server";
|
|
609
609
|
openapi: {
|
|
@@ -628,7 +628,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
628
628
|
};
|
|
629
629
|
};
|
|
630
630
|
};
|
|
631
|
-
use: ((inputContext:
|
|
631
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
632
632
|
session: {
|
|
633
633
|
session: Record<string, any> & {
|
|
634
634
|
id: string;
|
|
@@ -654,14 +654,14 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
654
654
|
}, {
|
|
655
655
|
status: boolean;
|
|
656
656
|
}>;
|
|
657
|
-
readonly verifyEmail:
|
|
657
|
+
readonly verifyEmail: better_call118.StrictEndpoint<"/verify-email", {
|
|
658
658
|
method: "GET";
|
|
659
659
|
operationId: string;
|
|
660
|
-
query:
|
|
661
|
-
token:
|
|
662
|
-
callbackURL:
|
|
663
|
-
},
|
|
664
|
-
use: ((inputContext:
|
|
660
|
+
query: zod88.ZodObject<{
|
|
661
|
+
token: zod88.ZodString;
|
|
662
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
663
|
+
}, zod_v4_core16.$strip>;
|
|
664
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
665
665
|
metadata: {
|
|
666
666
|
openapi: {
|
|
667
667
|
description: string;
|
|
@@ -710,13 +710,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
710
710
|
}, void | {
|
|
711
711
|
status: boolean;
|
|
712
712
|
}>;
|
|
713
|
-
readonly sendVerificationEmail:
|
|
713
|
+
readonly sendVerificationEmail: better_call118.StrictEndpoint<"/send-verification-email", {
|
|
714
714
|
method: "POST";
|
|
715
715
|
operationId: string;
|
|
716
|
-
body:
|
|
717
|
-
email:
|
|
718
|
-
callbackURL:
|
|
719
|
-
},
|
|
716
|
+
body: zod88.ZodObject<{
|
|
717
|
+
email: zod88.ZodEmail;
|
|
718
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
719
|
+
}, zod_v4_core16.$strip>;
|
|
720
720
|
metadata: {
|
|
721
721
|
openapi: {
|
|
722
722
|
operationId: string;
|
|
@@ -785,13 +785,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
785
785
|
}, {
|
|
786
786
|
status: boolean;
|
|
787
787
|
}>;
|
|
788
|
-
readonly changeEmail:
|
|
788
|
+
readonly changeEmail: better_call118.StrictEndpoint<"/change-email", {
|
|
789
789
|
method: "POST";
|
|
790
|
-
body:
|
|
791
|
-
newEmail:
|
|
792
|
-
callbackURL:
|
|
793
|
-
},
|
|
794
|
-
use: ((inputContext:
|
|
790
|
+
body: zod88.ZodObject<{
|
|
791
|
+
newEmail: zod88.ZodEmail;
|
|
792
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
793
|
+
}, zod_v4_core16.$strip>;
|
|
794
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
795
795
|
session: {
|
|
796
796
|
session: Record<string, any> & {
|
|
797
797
|
id: string;
|
|
@@ -866,15 +866,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
866
866
|
}, {
|
|
867
867
|
status: boolean;
|
|
868
868
|
}>;
|
|
869
|
-
readonly changePassword:
|
|
869
|
+
readonly changePassword: better_call118.StrictEndpoint<"/change-password", {
|
|
870
870
|
method: "POST";
|
|
871
871
|
operationId: string;
|
|
872
|
-
body:
|
|
873
|
-
newPassword:
|
|
874
|
-
currentPassword:
|
|
875
|
-
revokeOtherSessions:
|
|
876
|
-
},
|
|
877
|
-
use: ((inputContext:
|
|
872
|
+
body: zod88.ZodObject<{
|
|
873
|
+
newPassword: zod88.ZodString;
|
|
874
|
+
currentPassword: zod88.ZodString;
|
|
875
|
+
revokeOtherSessions: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
876
|
+
}, zod_v4_core16.$strip>;
|
|
877
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
878
878
|
session: {
|
|
879
879
|
session: Record<string, any> & {
|
|
880
880
|
id: string;
|
|
@@ -974,12 +974,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
974
974
|
image?: string | null | undefined;
|
|
975
975
|
} & Record<string, any>;
|
|
976
976
|
}>;
|
|
977
|
-
readonly setPassword:
|
|
977
|
+
readonly setPassword: better_call118.StrictEndpoint<string, {
|
|
978
978
|
method: "POST";
|
|
979
|
-
body:
|
|
980
|
-
newPassword:
|
|
981
|
-
},
|
|
982
|
-
use: ((inputContext:
|
|
979
|
+
body: zod88.ZodObject<{
|
|
980
|
+
newPassword: zod88.ZodString;
|
|
981
|
+
}, zod_v4_core16.$strip>;
|
|
982
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
983
983
|
session: {
|
|
984
984
|
session: Record<string, any> & {
|
|
985
985
|
id: string;
|
|
@@ -1005,11 +1005,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1005
1005
|
}, {
|
|
1006
1006
|
status: boolean;
|
|
1007
1007
|
}>;
|
|
1008
|
-
readonly updateUser:
|
|
1008
|
+
readonly updateUser: better_call118.StrictEndpoint<"/update-user", {
|
|
1009
1009
|
method: "POST";
|
|
1010
1010
|
operationId: string;
|
|
1011
|
-
body:
|
|
1012
|
-
use: ((inputContext:
|
|
1011
|
+
body: zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>;
|
|
1012
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1013
1013
|
session: {
|
|
1014
1014
|
session: Record<string, any> & {
|
|
1015
1015
|
id: string;
|
|
@@ -1085,9 +1085,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1085
1085
|
}, {
|
|
1086
1086
|
status: boolean;
|
|
1087
1087
|
}>;
|
|
1088
|
-
readonly deleteUser:
|
|
1088
|
+
readonly deleteUser: better_call118.StrictEndpoint<"/delete-user", {
|
|
1089
1089
|
method: "POST";
|
|
1090
|
-
use: ((inputContext:
|
|
1090
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1091
1091
|
session: {
|
|
1092
1092
|
session: Record<string, any> & {
|
|
1093
1093
|
id: string;
|
|
@@ -1110,11 +1110,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1110
1110
|
};
|
|
1111
1111
|
};
|
|
1112
1112
|
}>)[];
|
|
1113
|
-
body:
|
|
1114
|
-
callbackURL:
|
|
1115
|
-
password:
|
|
1116
|
-
token:
|
|
1117
|
-
},
|
|
1113
|
+
body: zod88.ZodObject<{
|
|
1114
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
1115
|
+
password: zod88.ZodOptional<zod88.ZodString>;
|
|
1116
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
1117
|
+
}, zod_v4_core16.$strip>;
|
|
1118
1118
|
metadata: {
|
|
1119
1119
|
openapi: {
|
|
1120
1120
|
operationId: string;
|
|
@@ -1172,12 +1172,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1172
1172
|
success: boolean;
|
|
1173
1173
|
message: string;
|
|
1174
1174
|
}>;
|
|
1175
|
-
readonly requestPasswordReset:
|
|
1175
|
+
readonly requestPasswordReset: better_call118.StrictEndpoint<"/request-password-reset", {
|
|
1176
1176
|
method: "POST";
|
|
1177
|
-
body:
|
|
1178
|
-
email:
|
|
1179
|
-
redirectTo:
|
|
1180
|
-
},
|
|
1177
|
+
body: zod88.ZodObject<{
|
|
1178
|
+
email: zod88.ZodEmail;
|
|
1179
|
+
redirectTo: zod88.ZodOptional<zod88.ZodString>;
|
|
1180
|
+
}, zod_v4_core16.$strip>;
|
|
1181
1181
|
metadata: {
|
|
1182
1182
|
openapi: {
|
|
1183
1183
|
operationId: string;
|
|
@@ -1208,13 +1208,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1208
1208
|
status: boolean;
|
|
1209
1209
|
message: string;
|
|
1210
1210
|
}>;
|
|
1211
|
-
readonly requestPasswordResetCallback:
|
|
1211
|
+
readonly requestPasswordResetCallback: better_call118.StrictEndpoint<"/reset-password/:token", {
|
|
1212
1212
|
method: "GET";
|
|
1213
1213
|
operationId: string;
|
|
1214
|
-
query:
|
|
1215
|
-
callbackURL:
|
|
1216
|
-
},
|
|
1217
|
-
use: ((inputContext:
|
|
1214
|
+
query: zod88.ZodObject<{
|
|
1215
|
+
callbackURL: zod88.ZodString;
|
|
1216
|
+
}, zod_v4_core16.$strip>;
|
|
1217
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
1218
1218
|
metadata: {
|
|
1219
1219
|
openapi: {
|
|
1220
1220
|
operationId: string;
|
|
@@ -1256,10 +1256,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1256
1256
|
};
|
|
1257
1257
|
};
|
|
1258
1258
|
}, never>;
|
|
1259
|
-
readonly listSessions:
|
|
1259
|
+
readonly listSessions: better_call118.StrictEndpoint<"/list-sessions", {
|
|
1260
1260
|
method: "GET";
|
|
1261
1261
|
operationId: string;
|
|
1262
|
-
use: ((inputContext:
|
|
1262
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1263
1263
|
session: {
|
|
1264
1264
|
session: Record<string, any> & {
|
|
1265
1265
|
id: string;
|
|
@@ -1314,12 +1314,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1314
1314
|
ipAddress?: string | null | undefined;
|
|
1315
1315
|
userAgent?: string | null | undefined;
|
|
1316
1316
|
} & InferFieldsFromPlugins<Option, "session", "output"> & InferFieldsFromOptions<Option, "session", "output">>>>[]>;
|
|
1317
|
-
readonly revokeSession:
|
|
1317
|
+
readonly revokeSession: better_call118.StrictEndpoint<"/revoke-session", {
|
|
1318
1318
|
method: "POST";
|
|
1319
|
-
body:
|
|
1320
|
-
token:
|
|
1321
|
-
},
|
|
1322
|
-
use: ((inputContext:
|
|
1319
|
+
body: zod88.ZodObject<{
|
|
1320
|
+
token: zod88.ZodString;
|
|
1321
|
+
}, zod_v4_core16.$strip>;
|
|
1322
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1323
1323
|
session: {
|
|
1324
1324
|
session: Record<string, any> & {
|
|
1325
1325
|
id: string;
|
|
@@ -1386,9 +1386,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1386
1386
|
}, {
|
|
1387
1387
|
status: boolean;
|
|
1388
1388
|
}>;
|
|
1389
|
-
readonly revokeSessions:
|
|
1389
|
+
readonly revokeSessions: better_call118.StrictEndpoint<"/revoke-sessions", {
|
|
1390
1390
|
method: "POST";
|
|
1391
|
-
use: ((inputContext:
|
|
1391
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1392
1392
|
session: {
|
|
1393
1393
|
session: Record<string, any> & {
|
|
1394
1394
|
id: string;
|
|
@@ -1439,10 +1439,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1439
1439
|
}, {
|
|
1440
1440
|
status: boolean;
|
|
1441
1441
|
}>;
|
|
1442
|
-
readonly revokeOtherSessions:
|
|
1442
|
+
readonly revokeOtherSessions: better_call118.StrictEndpoint<"/revoke-other-sessions", {
|
|
1443
1443
|
method: "POST";
|
|
1444
1444
|
requireHeaders: true;
|
|
1445
|
-
use: ((inputContext:
|
|
1445
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1446
1446
|
session: {
|
|
1447
1447
|
session: Record<string, any> & {
|
|
1448
1448
|
id: string;
|
|
@@ -1492,26 +1492,26 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1492
1492
|
}, {
|
|
1493
1493
|
status: boolean;
|
|
1494
1494
|
}>;
|
|
1495
|
-
readonly linkSocialAccount:
|
|
1495
|
+
readonly linkSocialAccount: better_call118.StrictEndpoint<"/link-social", {
|
|
1496
1496
|
method: "POST";
|
|
1497
1497
|
requireHeaders: true;
|
|
1498
|
-
body:
|
|
1499
|
-
callbackURL:
|
|
1500
|
-
provider:
|
|
1501
|
-
idToken:
|
|
1502
|
-
token:
|
|
1503
|
-
nonce:
|
|
1504
|
-
accessToken:
|
|
1505
|
-
refreshToken:
|
|
1506
|
-
scopes:
|
|
1507
|
-
},
|
|
1508
|
-
requestSignUp:
|
|
1509
|
-
scopes:
|
|
1510
|
-
errorCallbackURL:
|
|
1511
|
-
disableRedirect:
|
|
1512
|
-
additionalData:
|
|
1513
|
-
},
|
|
1514
|
-
use: ((inputContext:
|
|
1498
|
+
body: zod88.ZodObject<{
|
|
1499
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
1500
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
1501
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
1502
|
+
token: zod88.ZodString;
|
|
1503
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
1504
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
1505
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
1506
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
1507
|
+
}, zod_v4_core16.$strip>>;
|
|
1508
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
1509
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
1510
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
1511
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
1512
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
1513
|
+
}, zod_v4_core16.$strip>;
|
|
1514
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1515
1515
|
session: {
|
|
1516
1516
|
session: Record<string, any> & {
|
|
1517
1517
|
id: string;
|
|
@@ -1570,9 +1570,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1570
1570
|
url: string;
|
|
1571
1571
|
redirect: boolean;
|
|
1572
1572
|
}>;
|
|
1573
|
-
readonly listUserAccounts:
|
|
1573
|
+
readonly listUserAccounts: better_call118.StrictEndpoint<"/list-accounts", {
|
|
1574
1574
|
method: "GET";
|
|
1575
|
-
use: ((inputContext:
|
|
1575
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1576
1576
|
session: {
|
|
1577
1577
|
session: Record<string, any> & {
|
|
1578
1578
|
id: string;
|
|
@@ -1654,13 +1654,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1654
1654
|
providerId: string;
|
|
1655
1655
|
accountId: string;
|
|
1656
1656
|
}[]>;
|
|
1657
|
-
readonly deleteUserCallback:
|
|
1657
|
+
readonly deleteUserCallback: better_call118.StrictEndpoint<"/delete-user/callback", {
|
|
1658
1658
|
method: "GET";
|
|
1659
|
-
query:
|
|
1660
|
-
token:
|
|
1661
|
-
callbackURL:
|
|
1662
|
-
},
|
|
1663
|
-
use: ((inputContext:
|
|
1659
|
+
query: zod88.ZodObject<{
|
|
1660
|
+
token: zod88.ZodString;
|
|
1661
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
1662
|
+
}, zod_v4_core16.$strip>;
|
|
1663
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
1664
1664
|
metadata: {
|
|
1665
1665
|
openapi: {
|
|
1666
1666
|
description: string;
|
|
@@ -1694,13 +1694,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1694
1694
|
success: boolean;
|
|
1695
1695
|
message: string;
|
|
1696
1696
|
}>;
|
|
1697
|
-
readonly unlinkAccount:
|
|
1697
|
+
readonly unlinkAccount: better_call118.StrictEndpoint<"/unlink-account", {
|
|
1698
1698
|
method: "POST";
|
|
1699
|
-
body:
|
|
1700
|
-
providerId:
|
|
1701
|
-
accountId:
|
|
1702
|
-
},
|
|
1703
|
-
use: ((inputContext:
|
|
1699
|
+
body: zod88.ZodObject<{
|
|
1700
|
+
providerId: zod88.ZodString;
|
|
1701
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
1702
|
+
}, zod_v4_core16.$strip>;
|
|
1703
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1704
1704
|
session: {
|
|
1705
1705
|
session: Record<string, any> & {
|
|
1706
1706
|
id: string;
|
|
@@ -1748,13 +1748,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1748
1748
|
}, {
|
|
1749
1749
|
status: boolean;
|
|
1750
1750
|
}>;
|
|
1751
|
-
readonly refreshToken:
|
|
1751
|
+
readonly refreshToken: better_call118.StrictEndpoint<"/refresh-token", {
|
|
1752
1752
|
method: "POST";
|
|
1753
|
-
body:
|
|
1754
|
-
providerId:
|
|
1755
|
-
accountId:
|
|
1756
|
-
userId:
|
|
1757
|
-
},
|
|
1753
|
+
body: zod88.ZodObject<{
|
|
1754
|
+
providerId: zod88.ZodString;
|
|
1755
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
1756
|
+
userId: zod88.ZodOptional<zod88.ZodString>;
|
|
1757
|
+
}, zod_v4_core16.$strip>;
|
|
1758
1758
|
metadata: {
|
|
1759
1759
|
openapi: {
|
|
1760
1760
|
description: string;
|
|
@@ -1807,13 +1807,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1807
1807
|
providerId: string;
|
|
1808
1808
|
accountId: string;
|
|
1809
1809
|
}>;
|
|
1810
|
-
readonly getAccessToken:
|
|
1810
|
+
readonly getAccessToken: better_call118.StrictEndpoint<"/get-access-token", {
|
|
1811
1811
|
method: "POST";
|
|
1812
|
-
body:
|
|
1813
|
-
providerId:
|
|
1814
|
-
accountId:
|
|
1815
|
-
userId:
|
|
1816
|
-
},
|
|
1812
|
+
body: zod88.ZodObject<{
|
|
1813
|
+
providerId: zod88.ZodString;
|
|
1814
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
1815
|
+
userId: zod88.ZodOptional<zod88.ZodString>;
|
|
1816
|
+
}, zod_v4_core16.$strip>;
|
|
1817
1817
|
metadata: {
|
|
1818
1818
|
openapi: {
|
|
1819
1819
|
description: string;
|
|
@@ -1855,9 +1855,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1855
1855
|
scopes: string[];
|
|
1856
1856
|
idToken: string | undefined;
|
|
1857
1857
|
}>;
|
|
1858
|
-
readonly accountInfo:
|
|
1858
|
+
readonly accountInfo: better_call118.StrictEndpoint<"/account-info", {
|
|
1859
1859
|
method: "GET";
|
|
1860
|
-
use: ((inputContext:
|
|
1860
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1861
1861
|
session: {
|
|
1862
1862
|
session: Record<string, any> & {
|
|
1863
1863
|
id: string;
|
|
@@ -1927,9 +1927,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1927
1927
|
};
|
|
1928
1928
|
};
|
|
1929
1929
|
};
|
|
1930
|
-
query:
|
|
1931
|
-
accountId:
|
|
1932
|
-
},
|
|
1930
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
1931
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
1932
|
+
}, zod_v4_core16.$strip>>;
|
|
1933
1933
|
}, {
|
|
1934
1934
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
1935
1935
|
data: Record<string, any>;
|
|
@@ -1945,7 +1945,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1945
1945
|
declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, options: Option) => {
|
|
1946
1946
|
handler: (request: Request) => Promise<Response>;
|
|
1947
1947
|
endpoints: {
|
|
1948
|
-
readonly ok:
|
|
1948
|
+
readonly ok: better_call118.StrictEndpoint<"/ok", {
|
|
1949
1949
|
method: "GET";
|
|
1950
1950
|
metadata: {
|
|
1951
1951
|
openapi: {
|
|
@@ -1975,7 +1975,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1975
1975
|
}, {
|
|
1976
1976
|
ok: boolean;
|
|
1977
1977
|
}>;
|
|
1978
|
-
readonly error:
|
|
1978
|
+
readonly error: better_call118.StrictEndpoint<"/error", {
|
|
1979
1979
|
method: "GET";
|
|
1980
1980
|
metadata: {
|
|
1981
1981
|
openapi: {
|
|
@@ -1997,47 +1997,47 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1997
1997
|
scope: "server";
|
|
1998
1998
|
};
|
|
1999
1999
|
}, Response>;
|
|
2000
|
-
readonly signInSocial:
|
|
2000
|
+
readonly signInSocial: better_call118.StrictEndpoint<"/sign-in/social", {
|
|
2001
2001
|
method: "POST";
|
|
2002
2002
|
operationId: string;
|
|
2003
|
-
body:
|
|
2004
|
-
callbackURL:
|
|
2005
|
-
newUserCallbackURL:
|
|
2006
|
-
errorCallbackURL:
|
|
2007
|
-
provider:
|
|
2008
|
-
disableRedirect:
|
|
2009
|
-
idToken:
|
|
2010
|
-
token:
|
|
2011
|
-
nonce:
|
|
2012
|
-
accessToken:
|
|
2013
|
-
refreshToken:
|
|
2014
|
-
expiresAt:
|
|
2015
|
-
},
|
|
2016
|
-
scopes:
|
|
2017
|
-
requestSignUp:
|
|
2018
|
-
loginHint:
|
|
2019
|
-
additionalData:
|
|
2020
|
-
},
|
|
2003
|
+
body: zod88.ZodObject<{
|
|
2004
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2005
|
+
newUserCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2006
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2007
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
2008
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2009
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
2010
|
+
token: zod88.ZodString;
|
|
2011
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
2012
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
2013
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
2014
|
+
expiresAt: zod88.ZodOptional<zod88.ZodNumber>;
|
|
2015
|
+
}, zod_v4_core16.$strip>>;
|
|
2016
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
2017
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2018
|
+
loginHint: zod88.ZodOptional<zod88.ZodString>;
|
|
2019
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
2020
|
+
}, zod_v4_core16.$strip>;
|
|
2021
2021
|
metadata: {
|
|
2022
2022
|
$Infer: {
|
|
2023
|
-
body:
|
|
2024
|
-
callbackURL:
|
|
2025
|
-
newUserCallbackURL:
|
|
2026
|
-
errorCallbackURL:
|
|
2027
|
-
provider:
|
|
2028
|
-
disableRedirect:
|
|
2029
|
-
idToken:
|
|
2030
|
-
token:
|
|
2031
|
-
nonce:
|
|
2032
|
-
accessToken:
|
|
2033
|
-
refreshToken:
|
|
2034
|
-
expiresAt:
|
|
2035
|
-
},
|
|
2036
|
-
scopes:
|
|
2037
|
-
requestSignUp:
|
|
2038
|
-
loginHint:
|
|
2039
|
-
additionalData:
|
|
2040
|
-
},
|
|
2023
|
+
body: zod88.infer<zod88.ZodObject<{
|
|
2024
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2025
|
+
newUserCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2026
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2027
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
2028
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2029
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
2030
|
+
token: zod88.ZodString;
|
|
2031
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
2032
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
2033
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
2034
|
+
expiresAt: zod88.ZodOptional<zod88.ZodNumber>;
|
|
2035
|
+
}, zod_v4_core16.$strip>>;
|
|
2036
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
2037
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2038
|
+
loginHint: zod88.ZodOptional<zod88.ZodString>;
|
|
2039
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
2040
|
+
}, zod_v4_core16.$strip>>;
|
|
2041
2041
|
returned: {
|
|
2042
2042
|
redirect: boolean;
|
|
2043
2043
|
token?: string | undefined;
|
|
@@ -2105,37 +2105,37 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2105
2105
|
image?: string | null | undefined;
|
|
2106
2106
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
2107
2107
|
}>;
|
|
2108
|
-
readonly callbackOAuth:
|
|
2108
|
+
readonly callbackOAuth: better_call118.StrictEndpoint<"/callback/:id", {
|
|
2109
2109
|
method: ("GET" | "POST")[];
|
|
2110
2110
|
operationId: string;
|
|
2111
|
-
body:
|
|
2112
|
-
code:
|
|
2113
|
-
error:
|
|
2114
|
-
device_id:
|
|
2115
|
-
error_description:
|
|
2116
|
-
state:
|
|
2117
|
-
user:
|
|
2118
|
-
},
|
|
2119
|
-
query:
|
|
2120
|
-
code:
|
|
2121
|
-
error:
|
|
2122
|
-
device_id:
|
|
2123
|
-
error_description:
|
|
2124
|
-
state:
|
|
2125
|
-
user:
|
|
2126
|
-
},
|
|
2111
|
+
body: zod88.ZodOptional<zod88.ZodObject<{
|
|
2112
|
+
code: zod88.ZodOptional<zod88.ZodString>;
|
|
2113
|
+
error: zod88.ZodOptional<zod88.ZodString>;
|
|
2114
|
+
device_id: zod88.ZodOptional<zod88.ZodString>;
|
|
2115
|
+
error_description: zod88.ZodOptional<zod88.ZodString>;
|
|
2116
|
+
state: zod88.ZodOptional<zod88.ZodString>;
|
|
2117
|
+
user: zod88.ZodOptional<zod88.ZodString>;
|
|
2118
|
+
}, zod_v4_core16.$strip>>;
|
|
2119
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
2120
|
+
code: zod88.ZodOptional<zod88.ZodString>;
|
|
2121
|
+
error: zod88.ZodOptional<zod88.ZodString>;
|
|
2122
|
+
device_id: zod88.ZodOptional<zod88.ZodString>;
|
|
2123
|
+
error_description: zod88.ZodOptional<zod88.ZodString>;
|
|
2124
|
+
state: zod88.ZodOptional<zod88.ZodString>;
|
|
2125
|
+
user: zod88.ZodOptional<zod88.ZodString>;
|
|
2126
|
+
}, zod_v4_core16.$strip>>;
|
|
2127
2127
|
metadata: {
|
|
2128
2128
|
allowedMediaTypes: string[];
|
|
2129
2129
|
scope: "server";
|
|
2130
2130
|
};
|
|
2131
2131
|
}, void>;
|
|
2132
|
-
readonly getSession:
|
|
2132
|
+
readonly getSession: better_call118.StrictEndpoint<"/get-session", {
|
|
2133
2133
|
method: "GET";
|
|
2134
2134
|
operationId: string;
|
|
2135
|
-
query:
|
|
2136
|
-
disableCookieCache:
|
|
2137
|
-
disableRefresh:
|
|
2138
|
-
},
|
|
2135
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
2136
|
+
disableCookieCache: zod88.ZodOptional<zod88.ZodCoercedBoolean<unknown>>;
|
|
2137
|
+
disableRefresh: zod88.ZodOptional<zod88.ZodCoercedBoolean<unknown>>;
|
|
2138
|
+
}, zod_v4_core16.$strip>>;
|
|
2139
2139
|
requireHeaders: true;
|
|
2140
2140
|
metadata: {
|
|
2141
2141
|
openapi: {
|
|
@@ -2186,7 +2186,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2186
2186
|
image?: string | null | undefined;
|
|
2187
2187
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
2188
2188
|
} | null>;
|
|
2189
|
-
readonly signOut:
|
|
2189
|
+
readonly signOut: better_call118.StrictEndpoint<"/sign-out", {
|
|
2190
2190
|
method: "POST";
|
|
2191
2191
|
operationId: string;
|
|
2192
2192
|
requireHeaders: true;
|
|
@@ -2216,18 +2216,18 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2216
2216
|
}, {
|
|
2217
2217
|
success: boolean;
|
|
2218
2218
|
}>;
|
|
2219
|
-
readonly signUpEmail:
|
|
2219
|
+
readonly signUpEmail: better_call118.StrictEndpoint<"/sign-up/email", {
|
|
2220
2220
|
method: "POST";
|
|
2221
2221
|
operationId: string;
|
|
2222
|
-
use: ((inputContext:
|
|
2223
|
-
body:
|
|
2224
|
-
name:
|
|
2225
|
-
email:
|
|
2226
|
-
password:
|
|
2227
|
-
image:
|
|
2228
|
-
callbackURL:
|
|
2229
|
-
rememberMe:
|
|
2230
|
-
},
|
|
2222
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2223
|
+
body: zod88.ZodIntersection<zod88.ZodObject<{
|
|
2224
|
+
name: zod88.ZodString;
|
|
2225
|
+
email: zod88.ZodEmail;
|
|
2226
|
+
password: zod88.ZodString;
|
|
2227
|
+
image: zod88.ZodOptional<zod88.ZodString>;
|
|
2228
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2229
|
+
rememberMe: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2230
|
+
}, zod_v4_core16.$strip>, zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
2231
2231
|
metadata: {
|
|
2232
2232
|
allowedMediaTypes: string[];
|
|
2233
2233
|
$Infer: {
|
|
@@ -2390,16 +2390,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2390
2390
|
image?: string | null | undefined;
|
|
2391
2391
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
2392
2392
|
}>;
|
|
2393
|
-
readonly signInEmail:
|
|
2393
|
+
readonly signInEmail: better_call118.StrictEndpoint<"/sign-in/email", {
|
|
2394
2394
|
method: "POST";
|
|
2395
2395
|
operationId: string;
|
|
2396
|
-
use: ((inputContext:
|
|
2397
|
-
body:
|
|
2398
|
-
email:
|
|
2399
|
-
password:
|
|
2400
|
-
callbackURL:
|
|
2401
|
-
rememberMe:
|
|
2402
|
-
},
|
|
2396
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2397
|
+
body: zod88.ZodObject<{
|
|
2398
|
+
email: zod88.ZodString;
|
|
2399
|
+
password: zod88.ZodString;
|
|
2400
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2401
|
+
rememberMe: zod88.ZodOptional<zod88.ZodDefault<zod88.ZodBoolean>>;
|
|
2402
|
+
}, zod_v4_core16.$strip>;
|
|
2403
2403
|
metadata: {
|
|
2404
2404
|
allowedMediaTypes: string[];
|
|
2405
2405
|
$Infer: {
|
|
@@ -2475,16 +2475,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2475
2475
|
image?: string | null | undefined;
|
|
2476
2476
|
} & InferFieldsFromPlugins<Option, "user", "output"> & InferFieldsFromOptions<Option, "user", "output">>>;
|
|
2477
2477
|
}>;
|
|
2478
|
-
readonly resetPassword:
|
|
2478
|
+
readonly resetPassword: better_call118.StrictEndpoint<"/reset-password", {
|
|
2479
2479
|
method: "POST";
|
|
2480
2480
|
operationId: string;
|
|
2481
|
-
query:
|
|
2482
|
-
token:
|
|
2483
|
-
},
|
|
2484
|
-
body:
|
|
2485
|
-
newPassword:
|
|
2486
|
-
token:
|
|
2487
|
-
},
|
|
2481
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
2482
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
2483
|
+
}, zod_v4_core16.$strip>>;
|
|
2484
|
+
body: zod88.ZodObject<{
|
|
2485
|
+
newPassword: zod88.ZodString;
|
|
2486
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
2487
|
+
}, zod_v4_core16.$strip>;
|
|
2488
2488
|
metadata: {
|
|
2489
2489
|
openapi: {
|
|
2490
2490
|
operationId: string;
|
|
@@ -2511,11 +2511,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2511
2511
|
}, {
|
|
2512
2512
|
status: boolean;
|
|
2513
2513
|
}>;
|
|
2514
|
-
readonly verifyPassword:
|
|
2514
|
+
readonly verifyPassword: better_call118.StrictEndpoint<"/verify-password", {
|
|
2515
2515
|
method: "POST";
|
|
2516
|
-
body:
|
|
2517
|
-
password:
|
|
2518
|
-
},
|
|
2516
|
+
body: zod88.ZodObject<{
|
|
2517
|
+
password: zod88.ZodString;
|
|
2518
|
+
}, zod_v4_core16.$strip>;
|
|
2519
2519
|
metadata: {
|
|
2520
2520
|
scope: "server";
|
|
2521
2521
|
openapi: {
|
|
@@ -2540,7 +2540,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2540
2540
|
};
|
|
2541
2541
|
};
|
|
2542
2542
|
};
|
|
2543
|
-
use: ((inputContext:
|
|
2543
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2544
2544
|
session: {
|
|
2545
2545
|
session: Record<string, any> & {
|
|
2546
2546
|
id: string;
|
|
@@ -2566,14 +2566,14 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2566
2566
|
}, {
|
|
2567
2567
|
status: boolean;
|
|
2568
2568
|
}>;
|
|
2569
|
-
readonly verifyEmail:
|
|
2569
|
+
readonly verifyEmail: better_call118.StrictEndpoint<"/verify-email", {
|
|
2570
2570
|
method: "GET";
|
|
2571
2571
|
operationId: string;
|
|
2572
|
-
query:
|
|
2573
|
-
token:
|
|
2574
|
-
callbackURL:
|
|
2575
|
-
},
|
|
2576
|
-
use: ((inputContext:
|
|
2572
|
+
query: zod88.ZodObject<{
|
|
2573
|
+
token: zod88.ZodString;
|
|
2574
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2575
|
+
}, zod_v4_core16.$strip>;
|
|
2576
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2577
2577
|
metadata: {
|
|
2578
2578
|
openapi: {
|
|
2579
2579
|
description: string;
|
|
@@ -2622,13 +2622,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2622
2622
|
}, void | {
|
|
2623
2623
|
status: boolean;
|
|
2624
2624
|
}>;
|
|
2625
|
-
readonly sendVerificationEmail:
|
|
2625
|
+
readonly sendVerificationEmail: better_call118.StrictEndpoint<"/send-verification-email", {
|
|
2626
2626
|
method: "POST";
|
|
2627
2627
|
operationId: string;
|
|
2628
|
-
body:
|
|
2629
|
-
email:
|
|
2630
|
-
callbackURL:
|
|
2631
|
-
},
|
|
2628
|
+
body: zod88.ZodObject<{
|
|
2629
|
+
email: zod88.ZodEmail;
|
|
2630
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2631
|
+
}, zod_v4_core16.$strip>;
|
|
2632
2632
|
metadata: {
|
|
2633
2633
|
openapi: {
|
|
2634
2634
|
operationId: string;
|
|
@@ -2697,13 +2697,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2697
2697
|
}, {
|
|
2698
2698
|
status: boolean;
|
|
2699
2699
|
}>;
|
|
2700
|
-
readonly changeEmail:
|
|
2700
|
+
readonly changeEmail: better_call118.StrictEndpoint<"/change-email", {
|
|
2701
2701
|
method: "POST";
|
|
2702
|
-
body:
|
|
2703
|
-
newEmail:
|
|
2704
|
-
callbackURL:
|
|
2705
|
-
},
|
|
2706
|
-
use: ((inputContext:
|
|
2702
|
+
body: zod88.ZodObject<{
|
|
2703
|
+
newEmail: zod88.ZodEmail;
|
|
2704
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
2705
|
+
}, zod_v4_core16.$strip>;
|
|
2706
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2707
2707
|
session: {
|
|
2708
2708
|
session: Record<string, any> & {
|
|
2709
2709
|
id: string;
|
|
@@ -2778,15 +2778,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2778
2778
|
}, {
|
|
2779
2779
|
status: boolean;
|
|
2780
2780
|
}>;
|
|
2781
|
-
readonly changePassword:
|
|
2781
|
+
readonly changePassword: better_call118.StrictEndpoint<"/change-password", {
|
|
2782
2782
|
method: "POST";
|
|
2783
2783
|
operationId: string;
|
|
2784
|
-
body:
|
|
2785
|
-
newPassword:
|
|
2786
|
-
currentPassword:
|
|
2787
|
-
revokeOtherSessions:
|
|
2788
|
-
},
|
|
2789
|
-
use: ((inputContext:
|
|
2784
|
+
body: zod88.ZodObject<{
|
|
2785
|
+
newPassword: zod88.ZodString;
|
|
2786
|
+
currentPassword: zod88.ZodString;
|
|
2787
|
+
revokeOtherSessions: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
2788
|
+
}, zod_v4_core16.$strip>;
|
|
2789
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2790
2790
|
session: {
|
|
2791
2791
|
session: Record<string, any> & {
|
|
2792
2792
|
id: string;
|
|
@@ -2886,12 +2886,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2886
2886
|
image?: string | null | undefined;
|
|
2887
2887
|
} & Record<string, any>;
|
|
2888
2888
|
}>;
|
|
2889
|
-
readonly setPassword:
|
|
2889
|
+
readonly setPassword: better_call118.StrictEndpoint<string, {
|
|
2890
2890
|
method: "POST";
|
|
2891
|
-
body:
|
|
2892
|
-
newPassword:
|
|
2893
|
-
},
|
|
2894
|
-
use: ((inputContext:
|
|
2891
|
+
body: zod88.ZodObject<{
|
|
2892
|
+
newPassword: zod88.ZodString;
|
|
2893
|
+
}, zod_v4_core16.$strip>;
|
|
2894
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2895
2895
|
session: {
|
|
2896
2896
|
session: Record<string, any> & {
|
|
2897
2897
|
id: string;
|
|
@@ -2917,11 +2917,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2917
2917
|
}, {
|
|
2918
2918
|
status: boolean;
|
|
2919
2919
|
}>;
|
|
2920
|
-
readonly updateUser:
|
|
2920
|
+
readonly updateUser: better_call118.StrictEndpoint<"/update-user", {
|
|
2921
2921
|
method: "POST";
|
|
2922
2922
|
operationId: string;
|
|
2923
|
-
body:
|
|
2924
|
-
use: ((inputContext:
|
|
2923
|
+
body: zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>;
|
|
2924
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2925
2925
|
session: {
|
|
2926
2926
|
session: Record<string, any> & {
|
|
2927
2927
|
id: string;
|
|
@@ -2997,9 +2997,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2997
2997
|
}, {
|
|
2998
2998
|
status: boolean;
|
|
2999
2999
|
}>;
|
|
3000
|
-
readonly deleteUser:
|
|
3000
|
+
readonly deleteUser: better_call118.StrictEndpoint<"/delete-user", {
|
|
3001
3001
|
method: "POST";
|
|
3002
|
-
use: ((inputContext:
|
|
3002
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3003
3003
|
session: {
|
|
3004
3004
|
session: Record<string, any> & {
|
|
3005
3005
|
id: string;
|
|
@@ -3022,11 +3022,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3022
3022
|
};
|
|
3023
3023
|
};
|
|
3024
3024
|
}>)[];
|
|
3025
|
-
body:
|
|
3026
|
-
callbackURL:
|
|
3027
|
-
password:
|
|
3028
|
-
token:
|
|
3029
|
-
},
|
|
3025
|
+
body: zod88.ZodObject<{
|
|
3026
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
3027
|
+
password: zod88.ZodOptional<zod88.ZodString>;
|
|
3028
|
+
token: zod88.ZodOptional<zod88.ZodString>;
|
|
3029
|
+
}, zod_v4_core16.$strip>;
|
|
3030
3030
|
metadata: {
|
|
3031
3031
|
openapi: {
|
|
3032
3032
|
operationId: string;
|
|
@@ -3084,12 +3084,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3084
3084
|
success: boolean;
|
|
3085
3085
|
message: string;
|
|
3086
3086
|
}>;
|
|
3087
|
-
readonly requestPasswordReset:
|
|
3087
|
+
readonly requestPasswordReset: better_call118.StrictEndpoint<"/request-password-reset", {
|
|
3088
3088
|
method: "POST";
|
|
3089
|
-
body:
|
|
3090
|
-
email:
|
|
3091
|
-
redirectTo:
|
|
3092
|
-
},
|
|
3089
|
+
body: zod88.ZodObject<{
|
|
3090
|
+
email: zod88.ZodEmail;
|
|
3091
|
+
redirectTo: zod88.ZodOptional<zod88.ZodString>;
|
|
3092
|
+
}, zod_v4_core16.$strip>;
|
|
3093
3093
|
metadata: {
|
|
3094
3094
|
openapi: {
|
|
3095
3095
|
operationId: string;
|
|
@@ -3120,13 +3120,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3120
3120
|
status: boolean;
|
|
3121
3121
|
message: string;
|
|
3122
3122
|
}>;
|
|
3123
|
-
readonly requestPasswordResetCallback:
|
|
3123
|
+
readonly requestPasswordResetCallback: better_call118.StrictEndpoint<"/reset-password/:token", {
|
|
3124
3124
|
method: "GET";
|
|
3125
3125
|
operationId: string;
|
|
3126
|
-
query:
|
|
3127
|
-
callbackURL:
|
|
3128
|
-
},
|
|
3129
|
-
use: ((inputContext:
|
|
3126
|
+
query: zod88.ZodObject<{
|
|
3127
|
+
callbackURL: zod88.ZodString;
|
|
3128
|
+
}, zod_v4_core16.$strip>;
|
|
3129
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
3130
3130
|
metadata: {
|
|
3131
3131
|
openapi: {
|
|
3132
3132
|
operationId: string;
|
|
@@ -3168,10 +3168,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3168
3168
|
};
|
|
3169
3169
|
};
|
|
3170
3170
|
}, never>;
|
|
3171
|
-
readonly listSessions:
|
|
3171
|
+
readonly listSessions: better_call118.StrictEndpoint<"/list-sessions", {
|
|
3172
3172
|
method: "GET";
|
|
3173
3173
|
operationId: string;
|
|
3174
|
-
use: ((inputContext:
|
|
3174
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3175
3175
|
session: {
|
|
3176
3176
|
session: Record<string, any> & {
|
|
3177
3177
|
id: string;
|
|
@@ -3226,12 +3226,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3226
3226
|
ipAddress?: string | null | undefined;
|
|
3227
3227
|
userAgent?: string | null | undefined;
|
|
3228
3228
|
} & InferFieldsFromPlugins<Option, "session", "output"> & InferFieldsFromOptions<Option, "session", "output">>>>[]>;
|
|
3229
|
-
readonly revokeSession:
|
|
3229
|
+
readonly revokeSession: better_call118.StrictEndpoint<"/revoke-session", {
|
|
3230
3230
|
method: "POST";
|
|
3231
|
-
body:
|
|
3232
|
-
token:
|
|
3233
|
-
},
|
|
3234
|
-
use: ((inputContext:
|
|
3231
|
+
body: zod88.ZodObject<{
|
|
3232
|
+
token: zod88.ZodString;
|
|
3233
|
+
}, zod_v4_core16.$strip>;
|
|
3234
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3235
3235
|
session: {
|
|
3236
3236
|
session: Record<string, any> & {
|
|
3237
3237
|
id: string;
|
|
@@ -3298,9 +3298,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3298
3298
|
}, {
|
|
3299
3299
|
status: boolean;
|
|
3300
3300
|
}>;
|
|
3301
|
-
readonly revokeSessions:
|
|
3301
|
+
readonly revokeSessions: better_call118.StrictEndpoint<"/revoke-sessions", {
|
|
3302
3302
|
method: "POST";
|
|
3303
|
-
use: ((inputContext:
|
|
3303
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3304
3304
|
session: {
|
|
3305
3305
|
session: Record<string, any> & {
|
|
3306
3306
|
id: string;
|
|
@@ -3351,10 +3351,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3351
3351
|
}, {
|
|
3352
3352
|
status: boolean;
|
|
3353
3353
|
}>;
|
|
3354
|
-
readonly revokeOtherSessions:
|
|
3354
|
+
readonly revokeOtherSessions: better_call118.StrictEndpoint<"/revoke-other-sessions", {
|
|
3355
3355
|
method: "POST";
|
|
3356
3356
|
requireHeaders: true;
|
|
3357
|
-
use: ((inputContext:
|
|
3357
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3358
3358
|
session: {
|
|
3359
3359
|
session: Record<string, any> & {
|
|
3360
3360
|
id: string;
|
|
@@ -3404,26 +3404,26 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3404
3404
|
}, {
|
|
3405
3405
|
status: boolean;
|
|
3406
3406
|
}>;
|
|
3407
|
-
readonly linkSocialAccount:
|
|
3407
|
+
readonly linkSocialAccount: better_call118.StrictEndpoint<"/link-social", {
|
|
3408
3408
|
method: "POST";
|
|
3409
3409
|
requireHeaders: true;
|
|
3410
|
-
body:
|
|
3411
|
-
callbackURL:
|
|
3412
|
-
provider:
|
|
3413
|
-
idToken:
|
|
3414
|
-
token:
|
|
3415
|
-
nonce:
|
|
3416
|
-
accessToken:
|
|
3417
|
-
refreshToken:
|
|
3418
|
-
scopes:
|
|
3419
|
-
},
|
|
3420
|
-
requestSignUp:
|
|
3421
|
-
scopes:
|
|
3422
|
-
errorCallbackURL:
|
|
3423
|
-
disableRedirect:
|
|
3424
|
-
additionalData:
|
|
3425
|
-
},
|
|
3426
|
-
use: ((inputContext:
|
|
3410
|
+
body: zod88.ZodObject<{
|
|
3411
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
3412
|
+
provider: zod88.ZodType<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown, zod_v4_core16.$ZodTypeInternals<"github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "huggingface" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linear" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "line" | "paybin" | "paypal" | "polar" | "vercel" | (string & {}), unknown>>;
|
|
3413
|
+
idToken: zod88.ZodOptional<zod88.ZodObject<{
|
|
3414
|
+
token: zod88.ZodString;
|
|
3415
|
+
nonce: zod88.ZodOptional<zod88.ZodString>;
|
|
3416
|
+
accessToken: zod88.ZodOptional<zod88.ZodString>;
|
|
3417
|
+
refreshToken: zod88.ZodOptional<zod88.ZodString>;
|
|
3418
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
3419
|
+
}, zod_v4_core16.$strip>>;
|
|
3420
|
+
requestSignUp: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
3421
|
+
scopes: zod88.ZodOptional<zod88.ZodArray<zod88.ZodString>>;
|
|
3422
|
+
errorCallbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
3423
|
+
disableRedirect: zod88.ZodOptional<zod88.ZodBoolean>;
|
|
3424
|
+
additionalData: zod88.ZodOptional<zod88.ZodRecord<zod88.ZodString, zod88.ZodAny>>;
|
|
3425
|
+
}, zod_v4_core16.$strip>;
|
|
3426
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3427
3427
|
session: {
|
|
3428
3428
|
session: Record<string, any> & {
|
|
3429
3429
|
id: string;
|
|
@@ -3482,9 +3482,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3482
3482
|
url: string;
|
|
3483
3483
|
redirect: boolean;
|
|
3484
3484
|
}>;
|
|
3485
|
-
readonly listUserAccounts:
|
|
3485
|
+
readonly listUserAccounts: better_call118.StrictEndpoint<"/list-accounts", {
|
|
3486
3486
|
method: "GET";
|
|
3487
|
-
use: ((inputContext:
|
|
3487
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3488
3488
|
session: {
|
|
3489
3489
|
session: Record<string, any> & {
|
|
3490
3490
|
id: string;
|
|
@@ -3566,13 +3566,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3566
3566
|
providerId: string;
|
|
3567
3567
|
accountId: string;
|
|
3568
3568
|
}[]>;
|
|
3569
|
-
readonly deleteUserCallback:
|
|
3569
|
+
readonly deleteUserCallback: better_call118.StrictEndpoint<"/delete-user/callback", {
|
|
3570
3570
|
method: "GET";
|
|
3571
|
-
query:
|
|
3572
|
-
token:
|
|
3573
|
-
callbackURL:
|
|
3574
|
-
},
|
|
3575
|
-
use: ((inputContext:
|
|
3571
|
+
query: zod88.ZodObject<{
|
|
3572
|
+
token: zod88.ZodString;
|
|
3573
|
+
callbackURL: zod88.ZodOptional<zod88.ZodString>;
|
|
3574
|
+
}, zod_v4_core16.$strip>;
|
|
3575
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
3576
3576
|
metadata: {
|
|
3577
3577
|
openapi: {
|
|
3578
3578
|
description: string;
|
|
@@ -3606,13 +3606,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3606
3606
|
success: boolean;
|
|
3607
3607
|
message: string;
|
|
3608
3608
|
}>;
|
|
3609
|
-
readonly unlinkAccount:
|
|
3609
|
+
readonly unlinkAccount: better_call118.StrictEndpoint<"/unlink-account", {
|
|
3610
3610
|
method: "POST";
|
|
3611
|
-
body:
|
|
3612
|
-
providerId:
|
|
3613
|
-
accountId:
|
|
3614
|
-
},
|
|
3615
|
-
use: ((inputContext:
|
|
3611
|
+
body: zod88.ZodObject<{
|
|
3612
|
+
providerId: zod88.ZodString;
|
|
3613
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
3614
|
+
}, zod_v4_core16.$strip>;
|
|
3615
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3616
3616
|
session: {
|
|
3617
3617
|
session: Record<string, any> & {
|
|
3618
3618
|
id: string;
|
|
@@ -3660,13 +3660,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3660
3660
|
}, {
|
|
3661
3661
|
status: boolean;
|
|
3662
3662
|
}>;
|
|
3663
|
-
readonly refreshToken:
|
|
3663
|
+
readonly refreshToken: better_call118.StrictEndpoint<"/refresh-token", {
|
|
3664
3664
|
method: "POST";
|
|
3665
|
-
body:
|
|
3666
|
-
providerId:
|
|
3667
|
-
accountId:
|
|
3668
|
-
userId:
|
|
3669
|
-
},
|
|
3665
|
+
body: zod88.ZodObject<{
|
|
3666
|
+
providerId: zod88.ZodString;
|
|
3667
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
3668
|
+
userId: zod88.ZodOptional<zod88.ZodString>;
|
|
3669
|
+
}, zod_v4_core16.$strip>;
|
|
3670
3670
|
metadata: {
|
|
3671
3671
|
openapi: {
|
|
3672
3672
|
description: string;
|
|
@@ -3719,13 +3719,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3719
3719
|
providerId: string;
|
|
3720
3720
|
accountId: string;
|
|
3721
3721
|
}>;
|
|
3722
|
-
readonly getAccessToken:
|
|
3722
|
+
readonly getAccessToken: better_call118.StrictEndpoint<"/get-access-token", {
|
|
3723
3723
|
method: "POST";
|
|
3724
|
-
body:
|
|
3725
|
-
providerId:
|
|
3726
|
-
accountId:
|
|
3727
|
-
userId:
|
|
3728
|
-
},
|
|
3724
|
+
body: zod88.ZodObject<{
|
|
3725
|
+
providerId: zod88.ZodString;
|
|
3726
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
3727
|
+
userId: zod88.ZodOptional<zod88.ZodString>;
|
|
3728
|
+
}, zod_v4_core16.$strip>;
|
|
3729
3729
|
metadata: {
|
|
3730
3730
|
openapi: {
|
|
3731
3731
|
description: string;
|
|
@@ -3767,9 +3767,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3767
3767
|
scopes: string[];
|
|
3768
3768
|
idToken: string | undefined;
|
|
3769
3769
|
}>;
|
|
3770
|
-
readonly accountInfo:
|
|
3770
|
+
readonly accountInfo: better_call118.StrictEndpoint<"/account-info", {
|
|
3771
3771
|
method: "GET";
|
|
3772
|
-
use: ((inputContext:
|
|
3772
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3773
3773
|
session: {
|
|
3774
3774
|
session: Record<string, any> & {
|
|
3775
3775
|
id: string;
|
|
@@ -3839,9 +3839,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3839
3839
|
};
|
|
3840
3840
|
};
|
|
3841
3841
|
};
|
|
3842
|
-
query:
|
|
3843
|
-
accountId:
|
|
3844
|
-
},
|
|
3842
|
+
query: zod88.ZodOptional<zod88.ZodObject<{
|
|
3843
|
+
accountId: zod88.ZodOptional<zod88.ZodString>;
|
|
3844
|
+
}, zod_v4_core16.$strip>>;
|
|
3845
3845
|
}, {
|
|
3846
3846
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
3847
3847
|
data: Record<string, any>;
|