better-auth 1.4.10-beta.1 → 1.5.0-beta.1
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 +393 -393
- 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/reset-password.d.mts +5 -5
- package/dist/api/routes/session.d.mts +14 -14
- package/dist/api/routes/sign-in.d.mts +3 -3
- package/dist/api/routes/sign-out.d.mts +2 -2
- package/dist/api/routes/sign-up.d.mts +2 -2
- package/dist/api/routes/update-user.d.mts +13 -13
- package/dist/client/plugins/index.d.mts +1 -1
- package/dist/client/react/index.d.mts +13 -13
- package/dist/client/vanilla.d.mts +13 -13
- package/dist/client/vue/index.d.mts +13 -13
- package/dist/context/create-context.mjs +3 -3
- package/dist/context/create-context.mjs.map +1 -1
- package/dist/context/helpers.mjs +2 -2
- package/dist/context/helpers.mjs.map +1 -1
- 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.d.mts +4 -4
- package/dist/plugins/admin/admin.d.mts +15 -15
- package/dist/plugins/anonymous/index.d.mts +5 -5
- package/dist/plugins/api-key/index.d.mts +6 -6
- 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 +13 -13
- package/dist/plugins/generic-oauth/index.d.mts +5 -5
- package/dist/plugins/haveibeenpwned/index.d.mts +3 -3
- package/dist/plugins/index.d.mts +2 -1
- package/dist/plugins/index.mjs +2 -1
- package/dist/plugins/jwt/client.d.mts +2 -2
- package/dist/plugins/jwt/index.d.mts +9 -9
- package/dist/plugins/last-login-method/index.d.mts +2 -2
- package/dist/plugins/magic-link/index.d.mts +4 -4
- package/dist/plugins/multi-session/client.d.mts +1 -1
- package/dist/plugins/multi-session/index.d.mts +11 -10
- package/dist/plugins/multi-session/index.mjs +6 -7
- package/dist/plugins/multi-session/index.mjs.map +1 -1
- 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/client.d.mts +3 -3
- package/dist/plugins/organization/routes/crud-access-control.d.mts +22 -22
- package/dist/plugins/organization/routes/crud-invites.d.mts +58 -58
- package/dist/plugins/organization/routes/crud-members.d.mts +62 -62
- package/dist/plugins/organization/routes/crud-org.d.mts +51 -51
- package/dist/plugins/organization/routes/crud-team.d.mts +76 -76
- 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/client.d.mts +2 -2
- package/dist/plugins/two-factor/index.d.mts +18 -18
- 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 +15 -15
- package/package.json +3 -3
package/dist/api/index.d.mts
CHANGED
|
@@ -26,16 +26,16 @@ import { AuthContext, Awaitable, BetterAuthOptions, BetterAuthPlugin } from "@be
|
|
|
26
26
|
import { InternalLogger } from "@better-auth/core/env";
|
|
27
27
|
import { APIError } from "@better-auth/core/error";
|
|
28
28
|
import * as _better_auth_core_oauth20 from "@better-auth/core/oauth2";
|
|
29
|
-
import * as
|
|
30
|
-
import * as
|
|
29
|
+
import * as zod80 from "zod";
|
|
30
|
+
import * as better_call116 from "better-call";
|
|
31
31
|
import { AuthEndpoint, AuthMiddleware, createAuthEndpoint, createAuthMiddleware, optionsMiddleware } from "@better-auth/core/api";
|
|
32
|
-
import * as
|
|
32
|
+
import * as zod_v4_core15 from "zod/v4/core";
|
|
33
33
|
|
|
34
34
|
//#region src/api/index.d.ts
|
|
35
35
|
declare function checkEndpointConflicts(options: BetterAuthOptions, logger: InternalLogger): void;
|
|
36
36
|
declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<AuthContext>, options: Option): {
|
|
37
37
|
api: {
|
|
38
|
-
readonly ok:
|
|
38
|
+
readonly ok: better_call116.StrictEndpoint<"/ok", {
|
|
39
39
|
method: "GET";
|
|
40
40
|
metadata: {
|
|
41
41
|
openapi: {
|
|
@@ -65,7 +65,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
65
65
|
}, {
|
|
66
66
|
ok: boolean;
|
|
67
67
|
}>;
|
|
68
|
-
readonly error:
|
|
68
|
+
readonly error: better_call116.StrictEndpoint<"/error", {
|
|
69
69
|
method: "GET";
|
|
70
70
|
metadata: {
|
|
71
71
|
openapi: {
|
|
@@ -87,47 +87,47 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
87
87
|
scope: "server";
|
|
88
88
|
};
|
|
89
89
|
}, Response>;
|
|
90
|
-
readonly signInSocial:
|
|
90
|
+
readonly signInSocial: better_call116.StrictEndpoint<"/sign-in/social", {
|
|
91
91
|
method: "POST";
|
|
92
92
|
operationId: string;
|
|
93
|
-
body:
|
|
94
|
-
callbackURL:
|
|
95
|
-
newUserCallbackURL:
|
|
96
|
-
errorCallbackURL:
|
|
97
|
-
provider:
|
|
98
|
-
disableRedirect:
|
|
99
|
-
idToken:
|
|
100
|
-
token:
|
|
101
|
-
nonce:
|
|
102
|
-
accessToken:
|
|
103
|
-
refreshToken:
|
|
104
|
-
expiresAt:
|
|
105
|
-
},
|
|
106
|
-
scopes:
|
|
107
|
-
requestSignUp:
|
|
108
|
-
loginHint:
|
|
109
|
-
additionalData:
|
|
110
|
-
},
|
|
93
|
+
body: zod80.ZodObject<{
|
|
94
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
95
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
96
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
97
|
+
provider: zod80.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_core15.$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>>;
|
|
98
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
99
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
100
|
+
token: zod80.ZodString;
|
|
101
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
102
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
103
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
104
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
105
|
+
}, zod_v4_core15.$strip>>;
|
|
106
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
107
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
108
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
109
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
110
|
+
}, zod_v4_core15.$strip>;
|
|
111
111
|
metadata: {
|
|
112
112
|
$Infer: {
|
|
113
|
-
body:
|
|
114
|
-
callbackURL:
|
|
115
|
-
newUserCallbackURL:
|
|
116
|
-
errorCallbackURL:
|
|
117
|
-
provider:
|
|
118
|
-
disableRedirect:
|
|
119
|
-
idToken:
|
|
120
|
-
token:
|
|
121
|
-
nonce:
|
|
122
|
-
accessToken:
|
|
123
|
-
refreshToken:
|
|
124
|
-
expiresAt:
|
|
125
|
-
},
|
|
126
|
-
scopes:
|
|
127
|
-
requestSignUp:
|
|
128
|
-
loginHint:
|
|
129
|
-
additionalData:
|
|
130
|
-
},
|
|
113
|
+
body: zod80.infer<zod80.ZodObject<{
|
|
114
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
115
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
116
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
117
|
+
provider: zod80.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_core15.$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>>;
|
|
118
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
119
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
120
|
+
token: zod80.ZodString;
|
|
121
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
122
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
123
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
124
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
125
|
+
}, zod_v4_core15.$strip>>;
|
|
126
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
127
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
128
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
129
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
130
|
+
}, zod_v4_core15.$strip>>;
|
|
131
131
|
returned: {
|
|
132
132
|
redirect: boolean;
|
|
133
133
|
token?: string | undefined;
|
|
@@ -195,37 +195,37 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
195
195
|
image?: string | null | undefined;
|
|
196
196
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
197
197
|
}>;
|
|
198
|
-
readonly callbackOAuth:
|
|
198
|
+
readonly callbackOAuth: better_call116.StrictEndpoint<"/callback/:id", {
|
|
199
199
|
method: ("GET" | "POST")[];
|
|
200
200
|
operationId: string;
|
|
201
|
-
body:
|
|
202
|
-
code:
|
|
203
|
-
error:
|
|
204
|
-
device_id:
|
|
205
|
-
error_description:
|
|
206
|
-
state:
|
|
207
|
-
user:
|
|
208
|
-
},
|
|
209
|
-
query:
|
|
210
|
-
code:
|
|
211
|
-
error:
|
|
212
|
-
device_id:
|
|
213
|
-
error_description:
|
|
214
|
-
state:
|
|
215
|
-
user:
|
|
216
|
-
},
|
|
201
|
+
body: zod80.ZodOptional<zod80.ZodObject<{
|
|
202
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
203
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
204
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
205
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
206
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
207
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
208
|
+
}, zod_v4_core15.$strip>>;
|
|
209
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
210
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
211
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
212
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
213
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
214
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
215
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
216
|
+
}, zod_v4_core15.$strip>>;
|
|
217
217
|
metadata: {
|
|
218
218
|
allowedMediaTypes: string[];
|
|
219
219
|
scope: "server";
|
|
220
220
|
};
|
|
221
221
|
}, void>;
|
|
222
|
-
readonly getSession:
|
|
222
|
+
readonly getSession: better_call116.StrictEndpoint<"/get-session", {
|
|
223
223
|
method: "GET";
|
|
224
224
|
operationId: string;
|
|
225
|
-
query:
|
|
226
|
-
disableCookieCache:
|
|
227
|
-
disableRefresh:
|
|
228
|
-
},
|
|
225
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
226
|
+
disableCookieCache: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
227
|
+
disableRefresh: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
228
|
+
}, zod_v4_core15.$strip>>;
|
|
229
229
|
requireHeaders: true;
|
|
230
230
|
metadata: {
|
|
231
231
|
openapi: {
|
|
@@ -276,7 +276,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
276
276
|
image?: string | null | undefined;
|
|
277
277
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
278
278
|
} | null>;
|
|
279
|
-
readonly signOut:
|
|
279
|
+
readonly signOut: better_call116.StrictEndpoint<"/sign-out", {
|
|
280
280
|
method: "POST";
|
|
281
281
|
operationId: string;
|
|
282
282
|
requireHeaders: true;
|
|
@@ -306,17 +306,17 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
306
306
|
}, {
|
|
307
307
|
success: boolean;
|
|
308
308
|
}>;
|
|
309
|
-
readonly signUpEmail:
|
|
309
|
+
readonly signUpEmail: better_call116.StrictEndpoint<"/sign-up/email", {
|
|
310
310
|
method: "POST";
|
|
311
311
|
operationId: string;
|
|
312
|
-
body:
|
|
313
|
-
name:
|
|
314
|
-
email:
|
|
315
|
-
password:
|
|
316
|
-
image:
|
|
317
|
-
callbackURL:
|
|
318
|
-
rememberMe:
|
|
319
|
-
},
|
|
312
|
+
body: zod80.ZodIntersection<zod80.ZodObject<{
|
|
313
|
+
name: zod80.ZodString;
|
|
314
|
+
email: zod80.ZodEmail;
|
|
315
|
+
password: zod80.ZodString;
|
|
316
|
+
image: zod80.ZodOptional<zod80.ZodString>;
|
|
317
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
318
|
+
rememberMe: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
319
|
+
}, zod_v4_core15.$strip>, zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
320
320
|
metadata: {
|
|
321
321
|
$Infer: {
|
|
322
322
|
body: {
|
|
@@ -478,15 +478,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
478
478
|
image?: string | null | undefined;
|
|
479
479
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
480
480
|
}>;
|
|
481
|
-
readonly signInEmail:
|
|
481
|
+
readonly signInEmail: better_call116.StrictEndpoint<"/sign-in/email", {
|
|
482
482
|
method: "POST";
|
|
483
483
|
operationId: string;
|
|
484
|
-
body:
|
|
485
|
-
email:
|
|
486
|
-
password:
|
|
487
|
-
callbackURL:
|
|
488
|
-
rememberMe:
|
|
489
|
-
},
|
|
484
|
+
body: zod80.ZodObject<{
|
|
485
|
+
email: zod80.ZodString;
|
|
486
|
+
password: zod80.ZodString;
|
|
487
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
488
|
+
rememberMe: zod80.ZodOptional<zod80.ZodDefault<zod80.ZodBoolean>>;
|
|
489
|
+
}, zod_v4_core15.$strip>;
|
|
490
490
|
metadata: {
|
|
491
491
|
$Infer: {
|
|
492
492
|
body: {
|
|
@@ -561,16 +561,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
561
561
|
image?: string | null | undefined;
|
|
562
562
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
563
563
|
}>;
|
|
564
|
-
readonly resetPassword:
|
|
564
|
+
readonly resetPassword: better_call116.StrictEndpoint<"/reset-password", {
|
|
565
565
|
method: "POST";
|
|
566
566
|
operationId: string;
|
|
567
|
-
query:
|
|
568
|
-
token:
|
|
569
|
-
},
|
|
570
|
-
body:
|
|
571
|
-
newPassword:
|
|
572
|
-
token:
|
|
573
|
-
},
|
|
567
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
568
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
569
|
+
}, zod_v4_core15.$strip>>;
|
|
570
|
+
body: zod80.ZodObject<{
|
|
571
|
+
newPassword: zod80.ZodString;
|
|
572
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
573
|
+
}, zod_v4_core15.$strip>;
|
|
574
574
|
metadata: {
|
|
575
575
|
openapi: {
|
|
576
576
|
operationId: string;
|
|
@@ -597,14 +597,14 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
597
597
|
}, {
|
|
598
598
|
status: boolean;
|
|
599
599
|
}>;
|
|
600
|
-
readonly verifyEmail:
|
|
600
|
+
readonly verifyEmail: better_call116.StrictEndpoint<"/verify-email", {
|
|
601
601
|
method: "GET";
|
|
602
602
|
operationId: string;
|
|
603
|
-
query:
|
|
604
|
-
token:
|
|
605
|
-
callbackURL:
|
|
606
|
-
},
|
|
607
|
-
use: ((inputContext:
|
|
603
|
+
query: zod80.ZodObject<{
|
|
604
|
+
token: zod80.ZodString;
|
|
605
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
606
|
+
}, zod_v4_core15.$strip>;
|
|
607
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
608
608
|
metadata: {
|
|
609
609
|
openapi: {
|
|
610
610
|
description: string;
|
|
@@ -653,13 +653,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
653
653
|
}, void | {
|
|
654
654
|
status: boolean;
|
|
655
655
|
}>;
|
|
656
|
-
readonly sendVerificationEmail:
|
|
656
|
+
readonly sendVerificationEmail: better_call116.StrictEndpoint<"/send-verification-email", {
|
|
657
657
|
method: "POST";
|
|
658
658
|
operationId: string;
|
|
659
|
-
body:
|
|
660
|
-
email:
|
|
661
|
-
callbackURL:
|
|
662
|
-
},
|
|
659
|
+
body: zod80.ZodObject<{
|
|
660
|
+
email: zod80.ZodEmail;
|
|
661
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
662
|
+
}, zod_v4_core15.$strip>;
|
|
663
663
|
metadata: {
|
|
664
664
|
openapi: {
|
|
665
665
|
operationId: string;
|
|
@@ -728,13 +728,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
728
728
|
}, {
|
|
729
729
|
status: boolean;
|
|
730
730
|
}>;
|
|
731
|
-
readonly changeEmail:
|
|
731
|
+
readonly changeEmail: better_call116.StrictEndpoint<"/change-email", {
|
|
732
732
|
method: "POST";
|
|
733
|
-
body:
|
|
734
|
-
newEmail:
|
|
735
|
-
callbackURL:
|
|
736
|
-
},
|
|
737
|
-
use: ((inputContext:
|
|
733
|
+
body: zod80.ZodObject<{
|
|
734
|
+
newEmail: zod80.ZodEmail;
|
|
735
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
736
|
+
}, zod_v4_core15.$strip>;
|
|
737
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
738
738
|
session: {
|
|
739
739
|
session: Record<string, any> & {
|
|
740
740
|
id: string;
|
|
@@ -809,15 +809,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
809
809
|
}, {
|
|
810
810
|
status: boolean;
|
|
811
811
|
}>;
|
|
812
|
-
readonly changePassword:
|
|
812
|
+
readonly changePassword: better_call116.StrictEndpoint<"/change-password", {
|
|
813
813
|
method: "POST";
|
|
814
814
|
operationId: string;
|
|
815
|
-
body:
|
|
816
|
-
newPassword:
|
|
817
|
-
currentPassword:
|
|
818
|
-
revokeOtherSessions:
|
|
819
|
-
},
|
|
820
|
-
use: ((inputContext:
|
|
815
|
+
body: zod80.ZodObject<{
|
|
816
|
+
newPassword: zod80.ZodString;
|
|
817
|
+
currentPassword: zod80.ZodString;
|
|
818
|
+
revokeOtherSessions: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
819
|
+
}, zod_v4_core15.$strip>;
|
|
820
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
821
821
|
session: {
|
|
822
822
|
session: Record<string, any> & {
|
|
823
823
|
id: string;
|
|
@@ -917,12 +917,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
917
917
|
updatedAt: Date;
|
|
918
918
|
};
|
|
919
919
|
}>;
|
|
920
|
-
readonly setPassword:
|
|
920
|
+
readonly setPassword: better_call116.StrictEndpoint<string, {
|
|
921
921
|
method: "POST";
|
|
922
|
-
body:
|
|
923
|
-
newPassword:
|
|
924
|
-
},
|
|
925
|
-
use: ((inputContext:
|
|
922
|
+
body: zod80.ZodObject<{
|
|
923
|
+
newPassword: zod80.ZodString;
|
|
924
|
+
}, zod_v4_core15.$strip>;
|
|
925
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
926
926
|
session: {
|
|
927
927
|
session: Record<string, any> & {
|
|
928
928
|
id: string;
|
|
@@ -948,11 +948,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
948
948
|
}, {
|
|
949
949
|
status: boolean;
|
|
950
950
|
}>;
|
|
951
|
-
readonly updateUser:
|
|
951
|
+
readonly updateUser: better_call116.StrictEndpoint<"/update-user", {
|
|
952
952
|
method: "POST";
|
|
953
953
|
operationId: string;
|
|
954
|
-
body:
|
|
955
|
-
use: ((inputContext:
|
|
954
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
955
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
956
956
|
session: {
|
|
957
957
|
session: Record<string, any> & {
|
|
958
958
|
id: string;
|
|
@@ -1028,9 +1028,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1028
1028
|
}, {
|
|
1029
1029
|
status: boolean;
|
|
1030
1030
|
}>;
|
|
1031
|
-
readonly deleteUser:
|
|
1031
|
+
readonly deleteUser: better_call116.StrictEndpoint<"/delete-user", {
|
|
1032
1032
|
method: "POST";
|
|
1033
|
-
use: ((inputContext:
|
|
1033
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1034
1034
|
session: {
|
|
1035
1035
|
session: Record<string, any> & {
|
|
1036
1036
|
id: string;
|
|
@@ -1053,11 +1053,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1053
1053
|
};
|
|
1054
1054
|
};
|
|
1055
1055
|
}>)[];
|
|
1056
|
-
body:
|
|
1057
|
-
callbackURL:
|
|
1058
|
-
password:
|
|
1059
|
-
token:
|
|
1060
|
-
},
|
|
1056
|
+
body: zod80.ZodObject<{
|
|
1057
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1058
|
+
password: zod80.ZodOptional<zod80.ZodString>;
|
|
1059
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
1060
|
+
}, zod_v4_core15.$strip>;
|
|
1061
1061
|
metadata: {
|
|
1062
1062
|
openapi: {
|
|
1063
1063
|
operationId: string;
|
|
@@ -1115,12 +1115,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1115
1115
|
success: boolean;
|
|
1116
1116
|
message: string;
|
|
1117
1117
|
}>;
|
|
1118
|
-
readonly requestPasswordReset:
|
|
1118
|
+
readonly requestPasswordReset: better_call116.StrictEndpoint<"/request-password-reset", {
|
|
1119
1119
|
method: "POST";
|
|
1120
|
-
body:
|
|
1121
|
-
email:
|
|
1122
|
-
redirectTo:
|
|
1123
|
-
},
|
|
1120
|
+
body: zod80.ZodObject<{
|
|
1121
|
+
email: zod80.ZodEmail;
|
|
1122
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
1123
|
+
}, zod_v4_core15.$strip>;
|
|
1124
1124
|
metadata: {
|
|
1125
1125
|
openapi: {
|
|
1126
1126
|
operationId: string;
|
|
@@ -1151,13 +1151,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1151
1151
|
status: boolean;
|
|
1152
1152
|
message: string;
|
|
1153
1153
|
}>;
|
|
1154
|
-
readonly requestPasswordResetCallback:
|
|
1154
|
+
readonly requestPasswordResetCallback: better_call116.StrictEndpoint<"/reset-password/:token", {
|
|
1155
1155
|
method: "GET";
|
|
1156
1156
|
operationId: string;
|
|
1157
|
-
query:
|
|
1158
|
-
callbackURL:
|
|
1159
|
-
},
|
|
1160
|
-
use: ((inputContext:
|
|
1157
|
+
query: zod80.ZodObject<{
|
|
1158
|
+
callbackURL: zod80.ZodString;
|
|
1159
|
+
}, zod_v4_core15.$strip>;
|
|
1160
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
1161
1161
|
metadata: {
|
|
1162
1162
|
openapi: {
|
|
1163
1163
|
operationId: string;
|
|
@@ -1199,10 +1199,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1199
1199
|
};
|
|
1200
1200
|
};
|
|
1201
1201
|
}, never>;
|
|
1202
|
-
readonly listSessions:
|
|
1202
|
+
readonly listSessions: better_call116.StrictEndpoint<"/list-sessions", {
|
|
1203
1203
|
method: "GET";
|
|
1204
1204
|
operationId: string;
|
|
1205
|
-
use: ((inputContext:
|
|
1205
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1206
1206
|
session: {
|
|
1207
1207
|
session: Record<string, any> & {
|
|
1208
1208
|
id: string;
|
|
@@ -1257,12 +1257,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1257
1257
|
ipAddress?: string | null | undefined;
|
|
1258
1258
|
userAgent?: string | null | undefined;
|
|
1259
1259
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
1260
|
-
readonly revokeSession:
|
|
1260
|
+
readonly revokeSession: better_call116.StrictEndpoint<"/revoke-session", {
|
|
1261
1261
|
method: "POST";
|
|
1262
|
-
body:
|
|
1263
|
-
token:
|
|
1264
|
-
},
|
|
1265
|
-
use: ((inputContext:
|
|
1262
|
+
body: zod80.ZodObject<{
|
|
1263
|
+
token: zod80.ZodString;
|
|
1264
|
+
}, zod_v4_core15.$strip>;
|
|
1265
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1266
1266
|
session: {
|
|
1267
1267
|
session: Record<string, any> & {
|
|
1268
1268
|
id: string;
|
|
@@ -1329,9 +1329,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1329
1329
|
}, {
|
|
1330
1330
|
status: boolean;
|
|
1331
1331
|
}>;
|
|
1332
|
-
readonly revokeSessions:
|
|
1332
|
+
readonly revokeSessions: better_call116.StrictEndpoint<"/revoke-sessions", {
|
|
1333
1333
|
method: "POST";
|
|
1334
|
-
use: ((inputContext:
|
|
1334
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1335
1335
|
session: {
|
|
1336
1336
|
session: Record<string, any> & {
|
|
1337
1337
|
id: string;
|
|
@@ -1382,10 +1382,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1382
1382
|
}, {
|
|
1383
1383
|
status: boolean;
|
|
1384
1384
|
}>;
|
|
1385
|
-
readonly revokeOtherSessions:
|
|
1385
|
+
readonly revokeOtherSessions: better_call116.StrictEndpoint<"/revoke-other-sessions", {
|
|
1386
1386
|
method: "POST";
|
|
1387
1387
|
requireHeaders: true;
|
|
1388
|
-
use: ((inputContext:
|
|
1388
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1389
1389
|
session: {
|
|
1390
1390
|
session: Record<string, any> & {
|
|
1391
1391
|
id: string;
|
|
@@ -1435,26 +1435,26 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1435
1435
|
}, {
|
|
1436
1436
|
status: boolean;
|
|
1437
1437
|
}>;
|
|
1438
|
-
readonly linkSocialAccount:
|
|
1438
|
+
readonly linkSocialAccount: better_call116.StrictEndpoint<"/link-social", {
|
|
1439
1439
|
method: "POST";
|
|
1440
1440
|
requireHeaders: true;
|
|
1441
|
-
body:
|
|
1442
|
-
callbackURL:
|
|
1443
|
-
provider:
|
|
1444
|
-
idToken:
|
|
1445
|
-
token:
|
|
1446
|
-
nonce:
|
|
1447
|
-
accessToken:
|
|
1448
|
-
refreshToken:
|
|
1449
|
-
scopes:
|
|
1450
|
-
},
|
|
1451
|
-
requestSignUp:
|
|
1452
|
-
scopes:
|
|
1453
|
-
errorCallbackURL:
|
|
1454
|
-
disableRedirect:
|
|
1455
|
-
additionalData:
|
|
1456
|
-
},
|
|
1457
|
-
use: ((inputContext:
|
|
1441
|
+
body: zod80.ZodObject<{
|
|
1442
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1443
|
+
provider: zod80.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_core15.$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>>;
|
|
1444
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1445
|
+
token: zod80.ZodString;
|
|
1446
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1447
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1448
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1449
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1450
|
+
}, zod_v4_core15.$strip>>;
|
|
1451
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1452
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1453
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1454
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1455
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1456
|
+
}, zod_v4_core15.$strip>;
|
|
1457
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1458
1458
|
session: {
|
|
1459
1459
|
session: Record<string, any> & {
|
|
1460
1460
|
id: string;
|
|
@@ -1513,9 +1513,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1513
1513
|
url: string;
|
|
1514
1514
|
redirect: boolean;
|
|
1515
1515
|
}>;
|
|
1516
|
-
readonly listUserAccounts:
|
|
1516
|
+
readonly listUserAccounts: better_call116.StrictEndpoint<"/list-accounts", {
|
|
1517
1517
|
method: "GET";
|
|
1518
|
-
use: ((inputContext:
|
|
1518
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1519
1519
|
session: {
|
|
1520
1520
|
session: Record<string, any> & {
|
|
1521
1521
|
id: string;
|
|
@@ -1597,13 +1597,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1597
1597
|
userId: string;
|
|
1598
1598
|
scopes: string[];
|
|
1599
1599
|
}[]>;
|
|
1600
|
-
readonly deleteUserCallback:
|
|
1600
|
+
readonly deleteUserCallback: better_call116.StrictEndpoint<"/delete-user/callback", {
|
|
1601
1601
|
method: "GET";
|
|
1602
|
-
query:
|
|
1603
|
-
token:
|
|
1604
|
-
callbackURL:
|
|
1605
|
-
},
|
|
1606
|
-
use: ((inputContext:
|
|
1602
|
+
query: zod80.ZodObject<{
|
|
1603
|
+
token: zod80.ZodString;
|
|
1604
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1605
|
+
}, zod_v4_core15.$strip>;
|
|
1606
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
1607
1607
|
metadata: {
|
|
1608
1608
|
openapi: {
|
|
1609
1609
|
description: string;
|
|
@@ -1637,13 +1637,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1637
1637
|
success: boolean;
|
|
1638
1638
|
message: string;
|
|
1639
1639
|
}>;
|
|
1640
|
-
readonly unlinkAccount:
|
|
1640
|
+
readonly unlinkAccount: better_call116.StrictEndpoint<"/unlink-account", {
|
|
1641
1641
|
method: "POST";
|
|
1642
|
-
body:
|
|
1643
|
-
providerId:
|
|
1644
|
-
accountId:
|
|
1645
|
-
},
|
|
1646
|
-
use: ((inputContext:
|
|
1642
|
+
body: zod80.ZodObject<{
|
|
1643
|
+
providerId: zod80.ZodString;
|
|
1644
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1645
|
+
}, zod_v4_core15.$strip>;
|
|
1646
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1647
1647
|
session: {
|
|
1648
1648
|
session: Record<string, any> & {
|
|
1649
1649
|
id: string;
|
|
@@ -1691,13 +1691,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1691
1691
|
}, {
|
|
1692
1692
|
status: boolean;
|
|
1693
1693
|
}>;
|
|
1694
|
-
readonly refreshToken:
|
|
1694
|
+
readonly refreshToken: better_call116.StrictEndpoint<"/refresh-token", {
|
|
1695
1695
|
method: "POST";
|
|
1696
|
-
body:
|
|
1697
|
-
providerId:
|
|
1698
|
-
accountId:
|
|
1699
|
-
userId:
|
|
1700
|
-
},
|
|
1696
|
+
body: zod80.ZodObject<{
|
|
1697
|
+
providerId: zod80.ZodString;
|
|
1698
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1699
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
1700
|
+
}, zod_v4_core15.$strip>;
|
|
1701
1701
|
metadata: {
|
|
1702
1702
|
openapi: {
|
|
1703
1703
|
description: string;
|
|
@@ -1750,13 +1750,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1750
1750
|
providerId: string;
|
|
1751
1751
|
accountId: string;
|
|
1752
1752
|
}>;
|
|
1753
|
-
readonly getAccessToken:
|
|
1753
|
+
readonly getAccessToken: better_call116.StrictEndpoint<"/get-access-token", {
|
|
1754
1754
|
method: "POST";
|
|
1755
|
-
body:
|
|
1756
|
-
providerId:
|
|
1757
|
-
accountId:
|
|
1758
|
-
userId:
|
|
1759
|
-
},
|
|
1755
|
+
body: zod80.ZodObject<{
|
|
1756
|
+
providerId: zod80.ZodString;
|
|
1757
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1758
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
1759
|
+
}, zod_v4_core15.$strip>;
|
|
1760
1760
|
metadata: {
|
|
1761
1761
|
openapi: {
|
|
1762
1762
|
description: string;
|
|
@@ -1805,9 +1805,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1805
1805
|
scopes: string[];
|
|
1806
1806
|
idToken: string | undefined;
|
|
1807
1807
|
}>;
|
|
1808
|
-
readonly accountInfo:
|
|
1808
|
+
readonly accountInfo: better_call116.StrictEndpoint<"/account-info", {
|
|
1809
1809
|
method: "GET";
|
|
1810
|
-
use: ((inputContext:
|
|
1810
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1811
1811
|
session: {
|
|
1812
1812
|
session: Record<string, any> & {
|
|
1813
1813
|
id: string;
|
|
@@ -1877,9 +1877,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1877
1877
|
};
|
|
1878
1878
|
};
|
|
1879
1879
|
};
|
|
1880
|
-
query:
|
|
1881
|
-
accountId:
|
|
1882
|
-
},
|
|
1880
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
1881
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1882
|
+
}, zod_v4_core15.$strip>>;
|
|
1883
1883
|
}, {
|
|
1884
1884
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
1885
1885
|
data: Record<string, any>;
|
|
@@ -1895,7 +1895,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1895
1895
|
declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, options: Option) => {
|
|
1896
1896
|
handler: (request: Request) => Promise<Response>;
|
|
1897
1897
|
endpoints: {
|
|
1898
|
-
readonly ok:
|
|
1898
|
+
readonly ok: better_call116.StrictEndpoint<"/ok", {
|
|
1899
1899
|
method: "GET";
|
|
1900
1900
|
metadata: {
|
|
1901
1901
|
openapi: {
|
|
@@ -1925,7 +1925,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1925
1925
|
}, {
|
|
1926
1926
|
ok: boolean;
|
|
1927
1927
|
}>;
|
|
1928
|
-
readonly error:
|
|
1928
|
+
readonly error: better_call116.StrictEndpoint<"/error", {
|
|
1929
1929
|
method: "GET";
|
|
1930
1930
|
metadata: {
|
|
1931
1931
|
openapi: {
|
|
@@ -1947,47 +1947,47 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1947
1947
|
scope: "server";
|
|
1948
1948
|
};
|
|
1949
1949
|
}, Response>;
|
|
1950
|
-
readonly signInSocial:
|
|
1950
|
+
readonly signInSocial: better_call116.StrictEndpoint<"/sign-in/social", {
|
|
1951
1951
|
method: "POST";
|
|
1952
1952
|
operationId: string;
|
|
1953
|
-
body:
|
|
1954
|
-
callbackURL:
|
|
1955
|
-
newUserCallbackURL:
|
|
1956
|
-
errorCallbackURL:
|
|
1957
|
-
provider:
|
|
1958
|
-
disableRedirect:
|
|
1959
|
-
idToken:
|
|
1960
|
-
token:
|
|
1961
|
-
nonce:
|
|
1962
|
-
accessToken:
|
|
1963
|
-
refreshToken:
|
|
1964
|
-
expiresAt:
|
|
1965
|
-
},
|
|
1966
|
-
scopes:
|
|
1967
|
-
requestSignUp:
|
|
1968
|
-
loginHint:
|
|
1969
|
-
additionalData:
|
|
1970
|
-
},
|
|
1953
|
+
body: zod80.ZodObject<{
|
|
1954
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1955
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1956
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1957
|
+
provider: zod80.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_core15.$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>>;
|
|
1958
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1959
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1960
|
+
token: zod80.ZodString;
|
|
1961
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1962
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1963
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1964
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
1965
|
+
}, zod_v4_core15.$strip>>;
|
|
1966
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1967
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1968
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
1969
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1970
|
+
}, zod_v4_core15.$strip>;
|
|
1971
1971
|
metadata: {
|
|
1972
1972
|
$Infer: {
|
|
1973
|
-
body:
|
|
1974
|
-
callbackURL:
|
|
1975
|
-
newUserCallbackURL:
|
|
1976
|
-
errorCallbackURL:
|
|
1977
|
-
provider:
|
|
1978
|
-
disableRedirect:
|
|
1979
|
-
idToken:
|
|
1980
|
-
token:
|
|
1981
|
-
nonce:
|
|
1982
|
-
accessToken:
|
|
1983
|
-
refreshToken:
|
|
1984
|
-
expiresAt:
|
|
1985
|
-
},
|
|
1986
|
-
scopes:
|
|
1987
|
-
requestSignUp:
|
|
1988
|
-
loginHint:
|
|
1989
|
-
additionalData:
|
|
1990
|
-
},
|
|
1973
|
+
body: zod80.infer<zod80.ZodObject<{
|
|
1974
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1975
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1976
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1977
|
+
provider: zod80.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_core15.$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>>;
|
|
1978
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1979
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1980
|
+
token: zod80.ZodString;
|
|
1981
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1982
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1983
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1984
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
1985
|
+
}, zod_v4_core15.$strip>>;
|
|
1986
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1987
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1988
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
1989
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1990
|
+
}, zod_v4_core15.$strip>>;
|
|
1991
1991
|
returned: {
|
|
1992
1992
|
redirect: boolean;
|
|
1993
1993
|
token?: string | undefined;
|
|
@@ -2055,37 +2055,37 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2055
2055
|
image?: string | null | undefined;
|
|
2056
2056
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2057
2057
|
}>;
|
|
2058
|
-
readonly callbackOAuth:
|
|
2058
|
+
readonly callbackOAuth: better_call116.StrictEndpoint<"/callback/:id", {
|
|
2059
2059
|
method: ("GET" | "POST")[];
|
|
2060
2060
|
operationId: string;
|
|
2061
|
-
body:
|
|
2062
|
-
code:
|
|
2063
|
-
error:
|
|
2064
|
-
device_id:
|
|
2065
|
-
error_description:
|
|
2066
|
-
state:
|
|
2067
|
-
user:
|
|
2068
|
-
},
|
|
2069
|
-
query:
|
|
2070
|
-
code:
|
|
2071
|
-
error:
|
|
2072
|
-
device_id:
|
|
2073
|
-
error_description:
|
|
2074
|
-
state:
|
|
2075
|
-
user:
|
|
2076
|
-
},
|
|
2061
|
+
body: zod80.ZodOptional<zod80.ZodObject<{
|
|
2062
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
2063
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
2064
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
2065
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
2066
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
2067
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
2068
|
+
}, zod_v4_core15.$strip>>;
|
|
2069
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2070
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
2071
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
2072
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
2073
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
2074
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
2075
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
2076
|
+
}, zod_v4_core15.$strip>>;
|
|
2077
2077
|
metadata: {
|
|
2078
2078
|
allowedMediaTypes: string[];
|
|
2079
2079
|
scope: "server";
|
|
2080
2080
|
};
|
|
2081
2081
|
}, void>;
|
|
2082
|
-
readonly getSession:
|
|
2082
|
+
readonly getSession: better_call116.StrictEndpoint<"/get-session", {
|
|
2083
2083
|
method: "GET";
|
|
2084
2084
|
operationId: string;
|
|
2085
|
-
query:
|
|
2086
|
-
disableCookieCache:
|
|
2087
|
-
disableRefresh:
|
|
2088
|
-
},
|
|
2085
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2086
|
+
disableCookieCache: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
2087
|
+
disableRefresh: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
2088
|
+
}, zod_v4_core15.$strip>>;
|
|
2089
2089
|
requireHeaders: true;
|
|
2090
2090
|
metadata: {
|
|
2091
2091
|
openapi: {
|
|
@@ -2136,7 +2136,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2136
2136
|
image?: string | null | undefined;
|
|
2137
2137
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2138
2138
|
} | null>;
|
|
2139
|
-
readonly signOut:
|
|
2139
|
+
readonly signOut: better_call116.StrictEndpoint<"/sign-out", {
|
|
2140
2140
|
method: "POST";
|
|
2141
2141
|
operationId: string;
|
|
2142
2142
|
requireHeaders: true;
|
|
@@ -2166,17 +2166,17 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2166
2166
|
}, {
|
|
2167
2167
|
success: boolean;
|
|
2168
2168
|
}>;
|
|
2169
|
-
readonly signUpEmail:
|
|
2169
|
+
readonly signUpEmail: better_call116.StrictEndpoint<"/sign-up/email", {
|
|
2170
2170
|
method: "POST";
|
|
2171
2171
|
operationId: string;
|
|
2172
|
-
body:
|
|
2173
|
-
name:
|
|
2174
|
-
email:
|
|
2175
|
-
password:
|
|
2176
|
-
image:
|
|
2177
|
-
callbackURL:
|
|
2178
|
-
rememberMe:
|
|
2179
|
-
},
|
|
2172
|
+
body: zod80.ZodIntersection<zod80.ZodObject<{
|
|
2173
|
+
name: zod80.ZodString;
|
|
2174
|
+
email: zod80.ZodEmail;
|
|
2175
|
+
password: zod80.ZodString;
|
|
2176
|
+
image: zod80.ZodOptional<zod80.ZodString>;
|
|
2177
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2178
|
+
rememberMe: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
2179
|
+
}, zod_v4_core15.$strip>, zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
2180
2180
|
metadata: {
|
|
2181
2181
|
$Infer: {
|
|
2182
2182
|
body: {
|
|
@@ -2338,15 +2338,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2338
2338
|
image?: string | null | undefined;
|
|
2339
2339
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2340
2340
|
}>;
|
|
2341
|
-
readonly signInEmail:
|
|
2341
|
+
readonly signInEmail: better_call116.StrictEndpoint<"/sign-in/email", {
|
|
2342
2342
|
method: "POST";
|
|
2343
2343
|
operationId: string;
|
|
2344
|
-
body:
|
|
2345
|
-
email:
|
|
2346
|
-
password:
|
|
2347
|
-
callbackURL:
|
|
2348
|
-
rememberMe:
|
|
2349
|
-
},
|
|
2344
|
+
body: zod80.ZodObject<{
|
|
2345
|
+
email: zod80.ZodString;
|
|
2346
|
+
password: zod80.ZodString;
|
|
2347
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2348
|
+
rememberMe: zod80.ZodOptional<zod80.ZodDefault<zod80.ZodBoolean>>;
|
|
2349
|
+
}, zod_v4_core15.$strip>;
|
|
2350
2350
|
metadata: {
|
|
2351
2351
|
$Infer: {
|
|
2352
2352
|
body: {
|
|
@@ -2421,16 +2421,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2421
2421
|
image?: string | null | undefined;
|
|
2422
2422
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2423
2423
|
}>;
|
|
2424
|
-
readonly resetPassword:
|
|
2424
|
+
readonly resetPassword: better_call116.StrictEndpoint<"/reset-password", {
|
|
2425
2425
|
method: "POST";
|
|
2426
2426
|
operationId: string;
|
|
2427
|
-
query:
|
|
2428
|
-
token:
|
|
2429
|
-
},
|
|
2430
|
-
body:
|
|
2431
|
-
newPassword:
|
|
2432
|
-
token:
|
|
2433
|
-
},
|
|
2427
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2428
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2429
|
+
}, zod_v4_core15.$strip>>;
|
|
2430
|
+
body: zod80.ZodObject<{
|
|
2431
|
+
newPassword: zod80.ZodString;
|
|
2432
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2433
|
+
}, zod_v4_core15.$strip>;
|
|
2434
2434
|
metadata: {
|
|
2435
2435
|
openapi: {
|
|
2436
2436
|
operationId: string;
|
|
@@ -2457,14 +2457,14 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2457
2457
|
}, {
|
|
2458
2458
|
status: boolean;
|
|
2459
2459
|
}>;
|
|
2460
|
-
readonly verifyEmail:
|
|
2460
|
+
readonly verifyEmail: better_call116.StrictEndpoint<"/verify-email", {
|
|
2461
2461
|
method: "GET";
|
|
2462
2462
|
operationId: string;
|
|
2463
|
-
query:
|
|
2464
|
-
token:
|
|
2465
|
-
callbackURL:
|
|
2466
|
-
},
|
|
2467
|
-
use: ((inputContext:
|
|
2463
|
+
query: zod80.ZodObject<{
|
|
2464
|
+
token: zod80.ZodString;
|
|
2465
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2466
|
+
}, zod_v4_core15.$strip>;
|
|
2467
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
2468
2468
|
metadata: {
|
|
2469
2469
|
openapi: {
|
|
2470
2470
|
description: string;
|
|
@@ -2513,13 +2513,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2513
2513
|
}, void | {
|
|
2514
2514
|
status: boolean;
|
|
2515
2515
|
}>;
|
|
2516
|
-
readonly sendVerificationEmail:
|
|
2516
|
+
readonly sendVerificationEmail: better_call116.StrictEndpoint<"/send-verification-email", {
|
|
2517
2517
|
method: "POST";
|
|
2518
2518
|
operationId: string;
|
|
2519
|
-
body:
|
|
2520
|
-
email:
|
|
2521
|
-
callbackURL:
|
|
2522
|
-
},
|
|
2519
|
+
body: zod80.ZodObject<{
|
|
2520
|
+
email: zod80.ZodEmail;
|
|
2521
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2522
|
+
}, zod_v4_core15.$strip>;
|
|
2523
2523
|
metadata: {
|
|
2524
2524
|
openapi: {
|
|
2525
2525
|
operationId: string;
|
|
@@ -2588,13 +2588,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2588
2588
|
}, {
|
|
2589
2589
|
status: boolean;
|
|
2590
2590
|
}>;
|
|
2591
|
-
readonly changeEmail:
|
|
2591
|
+
readonly changeEmail: better_call116.StrictEndpoint<"/change-email", {
|
|
2592
2592
|
method: "POST";
|
|
2593
|
-
body:
|
|
2594
|
-
newEmail:
|
|
2595
|
-
callbackURL:
|
|
2596
|
-
},
|
|
2597
|
-
use: ((inputContext:
|
|
2593
|
+
body: zod80.ZodObject<{
|
|
2594
|
+
newEmail: zod80.ZodEmail;
|
|
2595
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2596
|
+
}, zod_v4_core15.$strip>;
|
|
2597
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2598
2598
|
session: {
|
|
2599
2599
|
session: Record<string, any> & {
|
|
2600
2600
|
id: string;
|
|
@@ -2669,15 +2669,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2669
2669
|
}, {
|
|
2670
2670
|
status: boolean;
|
|
2671
2671
|
}>;
|
|
2672
|
-
readonly changePassword:
|
|
2672
|
+
readonly changePassword: better_call116.StrictEndpoint<"/change-password", {
|
|
2673
2673
|
method: "POST";
|
|
2674
2674
|
operationId: string;
|
|
2675
|
-
body:
|
|
2676
|
-
newPassword:
|
|
2677
|
-
currentPassword:
|
|
2678
|
-
revokeOtherSessions:
|
|
2679
|
-
},
|
|
2680
|
-
use: ((inputContext:
|
|
2675
|
+
body: zod80.ZodObject<{
|
|
2676
|
+
newPassword: zod80.ZodString;
|
|
2677
|
+
currentPassword: zod80.ZodString;
|
|
2678
|
+
revokeOtherSessions: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
2679
|
+
}, zod_v4_core15.$strip>;
|
|
2680
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2681
2681
|
session: {
|
|
2682
2682
|
session: Record<string, any> & {
|
|
2683
2683
|
id: string;
|
|
@@ -2777,12 +2777,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2777
2777
|
updatedAt: Date;
|
|
2778
2778
|
};
|
|
2779
2779
|
}>;
|
|
2780
|
-
readonly setPassword:
|
|
2780
|
+
readonly setPassword: better_call116.StrictEndpoint<string, {
|
|
2781
2781
|
method: "POST";
|
|
2782
|
-
body:
|
|
2783
|
-
newPassword:
|
|
2784
|
-
},
|
|
2785
|
-
use: ((inputContext:
|
|
2782
|
+
body: zod80.ZodObject<{
|
|
2783
|
+
newPassword: zod80.ZodString;
|
|
2784
|
+
}, zod_v4_core15.$strip>;
|
|
2785
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2786
2786
|
session: {
|
|
2787
2787
|
session: Record<string, any> & {
|
|
2788
2788
|
id: string;
|
|
@@ -2808,11 +2808,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2808
2808
|
}, {
|
|
2809
2809
|
status: boolean;
|
|
2810
2810
|
}>;
|
|
2811
|
-
readonly updateUser:
|
|
2811
|
+
readonly updateUser: better_call116.StrictEndpoint<"/update-user", {
|
|
2812
2812
|
method: "POST";
|
|
2813
2813
|
operationId: string;
|
|
2814
|
-
body:
|
|
2815
|
-
use: ((inputContext:
|
|
2814
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
2815
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2816
2816
|
session: {
|
|
2817
2817
|
session: Record<string, any> & {
|
|
2818
2818
|
id: string;
|
|
@@ -2888,9 +2888,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2888
2888
|
}, {
|
|
2889
2889
|
status: boolean;
|
|
2890
2890
|
}>;
|
|
2891
|
-
readonly deleteUser:
|
|
2891
|
+
readonly deleteUser: better_call116.StrictEndpoint<"/delete-user", {
|
|
2892
2892
|
method: "POST";
|
|
2893
|
-
use: ((inputContext:
|
|
2893
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2894
2894
|
session: {
|
|
2895
2895
|
session: Record<string, any> & {
|
|
2896
2896
|
id: string;
|
|
@@ -2913,11 +2913,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2913
2913
|
};
|
|
2914
2914
|
};
|
|
2915
2915
|
}>)[];
|
|
2916
|
-
body:
|
|
2917
|
-
callbackURL:
|
|
2918
|
-
password:
|
|
2919
|
-
token:
|
|
2920
|
-
},
|
|
2916
|
+
body: zod80.ZodObject<{
|
|
2917
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2918
|
+
password: zod80.ZodOptional<zod80.ZodString>;
|
|
2919
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2920
|
+
}, zod_v4_core15.$strip>;
|
|
2921
2921
|
metadata: {
|
|
2922
2922
|
openapi: {
|
|
2923
2923
|
operationId: string;
|
|
@@ -2975,12 +2975,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2975
2975
|
success: boolean;
|
|
2976
2976
|
message: string;
|
|
2977
2977
|
}>;
|
|
2978
|
-
readonly requestPasswordReset:
|
|
2978
|
+
readonly requestPasswordReset: better_call116.StrictEndpoint<"/request-password-reset", {
|
|
2979
2979
|
method: "POST";
|
|
2980
|
-
body:
|
|
2981
|
-
email:
|
|
2982
|
-
redirectTo:
|
|
2983
|
-
},
|
|
2980
|
+
body: zod80.ZodObject<{
|
|
2981
|
+
email: zod80.ZodEmail;
|
|
2982
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
2983
|
+
}, zod_v4_core15.$strip>;
|
|
2984
2984
|
metadata: {
|
|
2985
2985
|
openapi: {
|
|
2986
2986
|
operationId: string;
|
|
@@ -3011,13 +3011,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3011
3011
|
status: boolean;
|
|
3012
3012
|
message: string;
|
|
3013
3013
|
}>;
|
|
3014
|
-
readonly requestPasswordResetCallback:
|
|
3014
|
+
readonly requestPasswordResetCallback: better_call116.StrictEndpoint<"/reset-password/:token", {
|
|
3015
3015
|
method: "GET";
|
|
3016
3016
|
operationId: string;
|
|
3017
|
-
query:
|
|
3018
|
-
callbackURL:
|
|
3019
|
-
},
|
|
3020
|
-
use: ((inputContext:
|
|
3017
|
+
query: zod80.ZodObject<{
|
|
3018
|
+
callbackURL: zod80.ZodString;
|
|
3019
|
+
}, zod_v4_core15.$strip>;
|
|
3020
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
3021
3021
|
metadata: {
|
|
3022
3022
|
openapi: {
|
|
3023
3023
|
operationId: string;
|
|
@@ -3059,10 +3059,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3059
3059
|
};
|
|
3060
3060
|
};
|
|
3061
3061
|
}, never>;
|
|
3062
|
-
readonly listSessions:
|
|
3062
|
+
readonly listSessions: better_call116.StrictEndpoint<"/list-sessions", {
|
|
3063
3063
|
method: "GET";
|
|
3064
3064
|
operationId: string;
|
|
3065
|
-
use: ((inputContext:
|
|
3065
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3066
3066
|
session: {
|
|
3067
3067
|
session: Record<string, any> & {
|
|
3068
3068
|
id: string;
|
|
@@ -3117,12 +3117,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3117
3117
|
ipAddress?: string | null | undefined;
|
|
3118
3118
|
userAgent?: string | null | undefined;
|
|
3119
3119
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
3120
|
-
readonly revokeSession:
|
|
3120
|
+
readonly revokeSession: better_call116.StrictEndpoint<"/revoke-session", {
|
|
3121
3121
|
method: "POST";
|
|
3122
|
-
body:
|
|
3123
|
-
token:
|
|
3124
|
-
},
|
|
3125
|
-
use: ((inputContext:
|
|
3122
|
+
body: zod80.ZodObject<{
|
|
3123
|
+
token: zod80.ZodString;
|
|
3124
|
+
}, zod_v4_core15.$strip>;
|
|
3125
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3126
3126
|
session: {
|
|
3127
3127
|
session: Record<string, any> & {
|
|
3128
3128
|
id: string;
|
|
@@ -3189,9 +3189,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3189
3189
|
}, {
|
|
3190
3190
|
status: boolean;
|
|
3191
3191
|
}>;
|
|
3192
|
-
readonly revokeSessions:
|
|
3192
|
+
readonly revokeSessions: better_call116.StrictEndpoint<"/revoke-sessions", {
|
|
3193
3193
|
method: "POST";
|
|
3194
|
-
use: ((inputContext:
|
|
3194
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3195
3195
|
session: {
|
|
3196
3196
|
session: Record<string, any> & {
|
|
3197
3197
|
id: string;
|
|
@@ -3242,10 +3242,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3242
3242
|
}, {
|
|
3243
3243
|
status: boolean;
|
|
3244
3244
|
}>;
|
|
3245
|
-
readonly revokeOtherSessions:
|
|
3245
|
+
readonly revokeOtherSessions: better_call116.StrictEndpoint<"/revoke-other-sessions", {
|
|
3246
3246
|
method: "POST";
|
|
3247
3247
|
requireHeaders: true;
|
|
3248
|
-
use: ((inputContext:
|
|
3248
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3249
3249
|
session: {
|
|
3250
3250
|
session: Record<string, any> & {
|
|
3251
3251
|
id: string;
|
|
@@ -3295,26 +3295,26 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3295
3295
|
}, {
|
|
3296
3296
|
status: boolean;
|
|
3297
3297
|
}>;
|
|
3298
|
-
readonly linkSocialAccount:
|
|
3298
|
+
readonly linkSocialAccount: better_call116.StrictEndpoint<"/link-social", {
|
|
3299
3299
|
method: "POST";
|
|
3300
3300
|
requireHeaders: true;
|
|
3301
|
-
body:
|
|
3302
|
-
callbackURL:
|
|
3303
|
-
provider:
|
|
3304
|
-
idToken:
|
|
3305
|
-
token:
|
|
3306
|
-
nonce:
|
|
3307
|
-
accessToken:
|
|
3308
|
-
refreshToken:
|
|
3309
|
-
scopes:
|
|
3310
|
-
},
|
|
3311
|
-
requestSignUp:
|
|
3312
|
-
scopes:
|
|
3313
|
-
errorCallbackURL:
|
|
3314
|
-
disableRedirect:
|
|
3315
|
-
additionalData:
|
|
3316
|
-
},
|
|
3317
|
-
use: ((inputContext:
|
|
3301
|
+
body: zod80.ZodObject<{
|
|
3302
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3303
|
+
provider: zod80.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_core15.$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>>;
|
|
3304
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
3305
|
+
token: zod80.ZodString;
|
|
3306
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
3307
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
3308
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
3309
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
3310
|
+
}, zod_v4_core15.$strip>>;
|
|
3311
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
3312
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
3313
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3314
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
3315
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
3316
|
+
}, zod_v4_core15.$strip>;
|
|
3317
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3318
3318
|
session: {
|
|
3319
3319
|
session: Record<string, any> & {
|
|
3320
3320
|
id: string;
|
|
@@ -3373,9 +3373,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3373
3373
|
url: string;
|
|
3374
3374
|
redirect: boolean;
|
|
3375
3375
|
}>;
|
|
3376
|
-
readonly listUserAccounts:
|
|
3376
|
+
readonly listUserAccounts: better_call116.StrictEndpoint<"/list-accounts", {
|
|
3377
3377
|
method: "GET";
|
|
3378
|
-
use: ((inputContext:
|
|
3378
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3379
3379
|
session: {
|
|
3380
3380
|
session: Record<string, any> & {
|
|
3381
3381
|
id: string;
|
|
@@ -3457,13 +3457,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3457
3457
|
userId: string;
|
|
3458
3458
|
scopes: string[];
|
|
3459
3459
|
}[]>;
|
|
3460
|
-
readonly deleteUserCallback:
|
|
3460
|
+
readonly deleteUserCallback: better_call116.StrictEndpoint<"/delete-user/callback", {
|
|
3461
3461
|
method: "GET";
|
|
3462
|
-
query:
|
|
3463
|
-
token:
|
|
3464
|
-
callbackURL:
|
|
3465
|
-
},
|
|
3466
|
-
use: ((inputContext:
|
|
3462
|
+
query: zod80.ZodObject<{
|
|
3463
|
+
token: zod80.ZodString;
|
|
3464
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3465
|
+
}, zod_v4_core15.$strip>;
|
|
3466
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<void>)[];
|
|
3467
3467
|
metadata: {
|
|
3468
3468
|
openapi: {
|
|
3469
3469
|
description: string;
|
|
@@ -3497,13 +3497,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3497
3497
|
success: boolean;
|
|
3498
3498
|
message: string;
|
|
3499
3499
|
}>;
|
|
3500
|
-
readonly unlinkAccount:
|
|
3500
|
+
readonly unlinkAccount: better_call116.StrictEndpoint<"/unlink-account", {
|
|
3501
3501
|
method: "POST";
|
|
3502
|
-
body:
|
|
3503
|
-
providerId:
|
|
3504
|
-
accountId:
|
|
3505
|
-
},
|
|
3506
|
-
use: ((inputContext:
|
|
3502
|
+
body: zod80.ZodObject<{
|
|
3503
|
+
providerId: zod80.ZodString;
|
|
3504
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3505
|
+
}, zod_v4_core15.$strip>;
|
|
3506
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3507
3507
|
session: {
|
|
3508
3508
|
session: Record<string, any> & {
|
|
3509
3509
|
id: string;
|
|
@@ -3551,13 +3551,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3551
3551
|
}, {
|
|
3552
3552
|
status: boolean;
|
|
3553
3553
|
}>;
|
|
3554
|
-
readonly refreshToken:
|
|
3554
|
+
readonly refreshToken: better_call116.StrictEndpoint<"/refresh-token", {
|
|
3555
3555
|
method: "POST";
|
|
3556
|
-
body:
|
|
3557
|
-
providerId:
|
|
3558
|
-
accountId:
|
|
3559
|
-
userId:
|
|
3560
|
-
},
|
|
3556
|
+
body: zod80.ZodObject<{
|
|
3557
|
+
providerId: zod80.ZodString;
|
|
3558
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3559
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
3560
|
+
}, zod_v4_core15.$strip>;
|
|
3561
3561
|
metadata: {
|
|
3562
3562
|
openapi: {
|
|
3563
3563
|
description: string;
|
|
@@ -3610,13 +3610,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3610
3610
|
providerId: string;
|
|
3611
3611
|
accountId: string;
|
|
3612
3612
|
}>;
|
|
3613
|
-
readonly getAccessToken:
|
|
3613
|
+
readonly getAccessToken: better_call116.StrictEndpoint<"/get-access-token", {
|
|
3614
3614
|
method: "POST";
|
|
3615
|
-
body:
|
|
3616
|
-
providerId:
|
|
3617
|
-
accountId:
|
|
3618
|
-
userId:
|
|
3619
|
-
},
|
|
3615
|
+
body: zod80.ZodObject<{
|
|
3616
|
+
providerId: zod80.ZodString;
|
|
3617
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3618
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
3619
|
+
}, zod_v4_core15.$strip>;
|
|
3620
3620
|
metadata: {
|
|
3621
3621
|
openapi: {
|
|
3622
3622
|
description: string;
|
|
@@ -3665,9 +3665,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3665
3665
|
scopes: string[];
|
|
3666
3666
|
idToken: string | undefined;
|
|
3667
3667
|
}>;
|
|
3668
|
-
readonly accountInfo:
|
|
3668
|
+
readonly accountInfo: better_call116.StrictEndpoint<"/account-info", {
|
|
3669
3669
|
method: "GET";
|
|
3670
|
-
use: ((inputContext:
|
|
3670
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3671
3671
|
session: {
|
|
3672
3672
|
session: Record<string, any> & {
|
|
3673
3673
|
id: string;
|
|
@@ -3737,9 +3737,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3737
3737
|
};
|
|
3738
3738
|
};
|
|
3739
3739
|
};
|
|
3740
|
-
query:
|
|
3741
|
-
accountId:
|
|
3742
|
-
},
|
|
3740
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
3741
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3742
|
+
}, zod_v4_core15.$strip>>;
|
|
3743
3743
|
}, {
|
|
3744
3744
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
3745
3745
|
data: Record<string, any>;
|