better-auth 1.4.10 → 1.5.0-beta.2
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 +400 -399
- package/dist/api/index.mjs +6 -4
- package/dist/api/index.mjs.map +1 -1
- package/dist/api/middlewares/origin-check.d.mts +4 -4
- package/dist/api/middlewares/origin-check.mjs +14 -5
- package/dist/api/middlewares/origin-check.mjs.map +1 -1
- package/dist/api/routes/account.d.mts +11 -11
- package/dist/api/routes/account.mjs +59 -30
- package/dist/api/routes/account.mjs.map +1 -1
- package/dist/api/routes/callback.d.mts +2 -2
- package/dist/api/routes/email-verification.d.mts +4 -4
- package/dist/api/routes/email-verification.mjs +14 -14
- package/dist/api/routes/email-verification.mjs.map +1 -1
- 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/reset-password.mjs +9 -7
- package/dist/api/routes/reset-password.mjs.map +1 -1
- package/dist/api/routes/session.d.mts +14 -14
- package/dist/api/routes/session.mjs +31 -11
- package/dist/api/routes/session.mjs.map +1 -1
- package/dist/api/routes/sign-in.d.mts +4 -4
- package/dist/api/routes/sign-in.mjs +22 -17
- package/dist/api/routes/sign-in.mjs.map +1 -1
- package/dist/api/routes/sign-out.d.mts +2 -2
- package/dist/api/routes/sign-up.d.mts +3 -3
- package/dist/api/routes/sign-up.mjs +16 -13
- package/dist/api/routes/sign-up.mjs.map +1 -1
- package/dist/api/routes/update-user.d.mts +13 -13
- package/dist/api/routes/update-user.mjs +29 -24
- package/dist/api/routes/update-user.mjs.map +1 -1
- package/dist/api/to-auth-endpoints.mjs +8 -6
- package/dist/api/to-auth-endpoints.mjs.map +1 -1
- package/dist/client/lynx/index.d.mts +13 -13
- package/dist/client/plugins/index.d.mts +11 -1
- package/dist/client/plugins/index.mjs +11 -1
- package/dist/client/svelte/index.d.mts +15 -15
- package/dist/client/types.d.mts +4 -1
- package/dist/client/vue/index.d.mts +15 -15
- package/dist/context/create-context.mjs +2 -2
- 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/db/schema.mjs +14 -5
- package/dist/db/schema.mjs.map +1 -1
- package/dist/index.d.mts +1 -1
- 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/oauth2/link-account.mjs +3 -2
- package/dist/oauth2/link-account.mjs.map +1 -1
- package/dist/oauth2/state.mjs +3 -3
- package/dist/oauth2/state.mjs.map +1 -1
- package/dist/plugins/admin/admin.d.mts +84 -21
- package/dist/plugins/admin/admin.mjs +3 -4
- package/dist/plugins/admin/admin.mjs.map +1 -1
- package/dist/plugins/admin/client.d.mts +87 -0
- package/dist/plugins/admin/client.mjs +3 -1
- package/dist/plugins/admin/client.mjs.map +1 -1
- package/dist/plugins/admin/error-codes.d.mts +90 -0
- package/dist/plugins/admin/error-codes.mjs.map +1 -1
- package/dist/plugins/admin/routes.mjs +40 -46
- package/dist/plugins/admin/routes.mjs.map +1 -1
- package/dist/plugins/anonymous/client.d.mts +19 -0
- package/dist/plugins/anonymous/client.mjs +4 -1
- package/dist/plugins/anonymous/client.mjs.map +1 -1
- package/dist/plugins/anonymous/error-codes.d.mts +22 -0
- package/dist/plugins/anonymous/index.d.mts +21 -9
- package/dist/plugins/anonymous/index.mjs +5 -5
- package/dist/plugins/anonymous/index.mjs.map +1 -1
- package/dist/plugins/api-key/client.d.mts +103 -0
- package/dist/plugins/api-key/client.mjs +4 -1
- package/dist/plugins/api-key/client.mjs.map +1 -1
- package/dist/plugins/api-key/error-codes.d.mts +106 -0
- package/dist/plugins/api-key/error-codes.mjs +34 -0
- package/dist/plugins/api-key/error-codes.mjs.map +1 -0
- package/dist/plugins/api-key/index.d.mts +138 -69
- package/dist/plugins/api-key/index.mjs +7 -34
- package/dist/plugins/api-key/index.mjs.map +1 -1
- package/dist/plugins/api-key/rate-limit.mjs +3 -2
- package/dist/plugins/api-key/rate-limit.mjs.map +1 -1
- package/dist/plugins/api-key/routes/create-api-key.mjs +19 -17
- package/dist/plugins/api-key/routes/create-api-key.mjs.map +1 -1
- package/dist/plugins/api-key/routes/delete-api-key.mjs +7 -5
- package/dist/plugins/api-key/routes/delete-api-key.mjs.map +1 -1
- package/dist/plugins/api-key/routes/get-api-key.mjs +5 -3
- package/dist/plugins/api-key/routes/get-api-key.mjs.map +1 -1
- package/dist/plugins/api-key/routes/update-api-key.mjs +18 -16
- package/dist/plugins/api-key/routes/update-api-key.mjs.map +1 -1
- package/dist/plugins/api-key/routes/verify-api-key.mjs +16 -35
- package/dist/plugins/api-key/routes/verify-api-key.mjs.map +1 -1
- package/dist/plugins/bearer/index.d.mts +6 -6
- package/dist/plugins/captcha/index.d.mts +2 -2
- package/dist/plugins/captcha/index.mjs +3 -3
- package/dist/plugins/captcha/index.mjs.map +1 -1
- package/dist/plugins/captcha/verify-handlers/captchafox.mjs +2 -2
- package/dist/plugins/captcha/verify-handlers/captchafox.mjs.map +1 -1
- package/dist/plugins/captcha/verify-handlers/cloudflare-turnstile.mjs +2 -2
- package/dist/plugins/captcha/verify-handlers/cloudflare-turnstile.mjs.map +1 -1
- package/dist/plugins/captcha/verify-handlers/google-recaptcha.mjs +2 -2
- package/dist/plugins/captcha/verify-handlers/google-recaptcha.mjs.map +1 -1
- package/dist/plugins/captcha/verify-handlers/h-captcha.mjs +2 -2
- package/dist/plugins/captcha/verify-handlers/h-captcha.mjs.map +1 -1
- package/dist/plugins/custom-session/index.d.mts +5 -5
- package/dist/plugins/device-authorization/index.d.mts +54 -18
- package/dist/plugins/device-authorization/routes.mjs +18 -18
- package/dist/plugins/device-authorization/routes.mjs.map +1 -1
- package/dist/plugins/email-otp/client.d.mts +15 -0
- package/dist/plugins/email-otp/client.mjs +4 -1
- package/dist/plugins/email-otp/client.mjs.map +1 -1
- package/dist/plugins/email-otp/error-codes.d.mts +18 -0
- package/dist/plugins/email-otp/error-codes.mjs +12 -0
- package/dist/plugins/email-otp/error-codes.mjs.map +1 -0
- package/dist/plugins/email-otp/index.d.mts +64 -55
- package/dist/plugins/email-otp/index.mjs +4 -3
- package/dist/plugins/email-otp/index.mjs.map +1 -1
- package/dist/plugins/email-otp/routes.mjs +30 -35
- package/dist/plugins/email-otp/routes.mjs.map +1 -1
- package/dist/plugins/generic-oauth/client.d.mts +27 -0
- package/dist/plugins/generic-oauth/client.mjs +4 -1
- package/dist/plugins/generic-oauth/client.mjs.map +1 -1
- package/dist/plugins/generic-oauth/error-codes.d.mts +30 -0
- package/dist/plugins/generic-oauth/index.d.mts +55 -37
- package/dist/plugins/generic-oauth/index.mjs +4 -4
- package/dist/plugins/generic-oauth/index.mjs.map +1 -1
- package/dist/plugins/generic-oauth/routes.mjs +11 -12
- package/dist/plugins/generic-oauth/routes.mjs.map +1 -1
- package/dist/plugins/haveibeenpwned/index.d.mts +7 -4
- package/dist/plugins/haveibeenpwned/index.mjs +5 -4
- package/dist/plugins/haveibeenpwned/index.mjs.map +1 -1
- package/dist/plugins/index.d.mts +4 -2
- package/dist/plugins/index.mjs +6 -4
- package/dist/plugins/jwt/client.d.mts +2 -2
- package/dist/plugins/jwt/index.d.mts +9 -9
- package/dist/plugins/jwt/index.mjs +2 -2
- package/dist/plugins/jwt/index.mjs.map +1 -1
- package/dist/plugins/last-login-method/index.d.mts +2 -2
- package/dist/plugins/magic-link/index.d.mts +4 -4
- package/dist/plugins/mcp/authorize.mjs +1 -1
- package/dist/plugins/mcp/authorize.mjs.map +1 -1
- package/dist/plugins/mcp/index.d.mts +10 -10
- package/dist/plugins/multi-session/client.d.mts +7 -0
- package/dist/plugins/multi-session/client.mjs +4 -1
- package/dist/plugins/multi-session/client.mjs.map +1 -1
- package/dist/plugins/multi-session/error-codes.d.mts +10 -0
- package/dist/plugins/multi-session/error-codes.mjs +8 -0
- package/dist/plugins/multi-session/error-codes.mjs.map +1 -0
- package/dist/plugins/multi-session/index.d.mts +20 -16
- 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/authorize.mjs +1 -1
- package/dist/plugins/oidc-provider/authorize.mjs.map +1 -1
- package/dist/plugins/oidc-provider/error.mjs +1 -1
- package/dist/plugins/oidc-provider/error.mjs.map +1 -1
- package/dist/plugins/oidc-provider/index.d.mts +15 -15
- package/dist/plugins/one-tap/client.d.mts +5 -5
- 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 +236 -9
- package/dist/plugins/organization/client.mjs +3 -1
- package/dist/plugins/organization/client.mjs.map +1 -1
- package/dist/plugins/organization/error-codes.d.mts +224 -56
- package/dist/plugins/organization/organization.d.mts +7 -7
- package/dist/plugins/organization/organization.mjs +4 -4
- package/dist/plugins/organization/organization.mjs.map +1 -1
- package/dist/plugins/organization/routes/crud-access-control.d.mts +22 -22
- package/dist/plugins/organization/routes/crud-access-control.mjs +40 -39
- package/dist/plugins/organization/routes/crud-access-control.mjs.map +1 -1
- package/dist/plugins/organization/routes/crud-invites.d.mts +58 -58
- package/dist/plugins/organization/routes/crud-invites.mjs +42 -40
- package/dist/plugins/organization/routes/crud-invites.mjs.map +1 -1
- package/dist/plugins/organization/routes/crud-members.d.mts +67 -67
- package/dist/plugins/organization/routes/crud-members.mjs +41 -54
- package/dist/plugins/organization/routes/crud-members.mjs.map +1 -1
- package/dist/plugins/organization/routes/crud-org.d.mts +22 -22
- package/dist/plugins/organization/routes/crud-org.mjs +28 -25
- package/dist/plugins/organization/routes/crud-org.mjs.map +1 -1
- package/dist/plugins/organization/routes/crud-team.d.mts +34 -34
- package/dist/plugins/organization/routes/crud-team.mjs +41 -47
- package/dist/plugins/organization/routes/crud-team.mjs.map +1 -1
- package/dist/plugins/phone-number/client.d.mts +51 -0
- package/dist/plugins/phone-number/client.mjs +4 -1
- package/dist/plugins/phone-number/client.mjs.map +1 -1
- package/dist/plugins/phone-number/error-codes.d.mts +54 -0
- package/dist/plugins/phone-number/index.d.mts +81 -45
- package/dist/plugins/phone-number/index.mjs +2 -2
- package/dist/plugins/phone-number/index.mjs.map +1 -1
- package/dist/plugins/phone-number/routes.mjs +27 -28
- package/dist/plugins/phone-number/routes.mjs.map +1 -1
- package/dist/plugins/siwe/index.d.mts +3 -3
- package/dist/plugins/siwe/index.mjs +7 -6
- package/dist/plugins/siwe/index.mjs.map +1 -1
- package/dist/plugins/two-factor/backup-codes/index.mjs +7 -7
- package/dist/plugins/two-factor/backup-codes/index.mjs.map +1 -1
- package/dist/plugins/two-factor/client.d.mts +39 -0
- package/dist/plugins/two-factor/client.mjs +4 -1
- package/dist/plugins/two-factor/client.mjs.map +1 -1
- package/dist/plugins/two-factor/error-code.d.mts +36 -9
- package/dist/plugins/two-factor/index.d.mts +54 -27
- package/dist/plugins/two-factor/index.mjs +4 -5
- package/dist/plugins/two-factor/index.mjs.map +1 -1
- package/dist/plugins/two-factor/otp/index.mjs +8 -6
- package/dist/plugins/two-factor/otp/index.mjs.map +1 -1
- package/dist/plugins/two-factor/totp/index.mjs +16 -8
- package/dist/plugins/two-factor/totp/index.mjs.map +1 -1
- package/dist/plugins/two-factor/verify-two-factor.mjs +9 -6
- package/dist/plugins/two-factor/verify-two-factor.mjs.map +1 -1
- package/dist/plugins/username/client.d.mts +35 -0
- package/dist/plugins/username/client.mjs +4 -1
- package/dist/plugins/username/client.mjs.map +1 -1
- package/dist/plugins/username/error-codes.d.mts +32 -8
- package/dist/plugins/username/index.d.mts +44 -20
- package/dist/plugins/username/index.mjs +21 -31
- package/dist/plugins/username/index.mjs.map +1 -1
- package/dist/plugins/username/schema.d.mts +3 -3
- package/dist/test-utils/test-instance.d.mts +481 -344
- package/dist/utils/is-api-error.d.mts +7 -0
- package/dist/utils/is-api-error.mjs +11 -0
- package/dist/utils/is-api-error.mjs.map +1 -0
- package/dist/utils/password.mjs +3 -3
- package/dist/utils/password.mjs.map +1 -1
- package/dist/utils/plugin-helper.mjs +2 -2
- package/dist/utils/plugin-helper.mjs.map +1 -1
- package/package.json +3 -3
package/dist/api/index.d.mts
CHANGED
|
@@ -6,6 +6,7 @@ import { Auth } from "../types/auth.mjs";
|
|
|
6
6
|
import "../types/index.mjs";
|
|
7
7
|
import "../index.mjs";
|
|
8
8
|
import { getIp } from "../utils/get-request-ip.mjs";
|
|
9
|
+
import { isAPIError } from "../utils/is-api-error.mjs";
|
|
9
10
|
import { getOAuthState } from "./middlewares/oauth.mjs";
|
|
10
11
|
import { formCsrfMiddleware, originCheck, originCheckMiddleware } from "./middlewares/origin-check.mjs";
|
|
11
12
|
import "./middlewares/index.mjs";
|
|
@@ -23,18 +24,18 @@ import { changeEmail, changePassword, deleteUser, deleteUserCallback, setPasswor
|
|
|
23
24
|
import "./routes/index.mjs";
|
|
24
25
|
import { AuthContext, Awaitable, BetterAuthOptions, BetterAuthPlugin } from "@better-auth/core";
|
|
25
26
|
import { InternalLogger } from "@better-auth/core/env";
|
|
27
|
+
import { APIError } from "@better-auth/core/error";
|
|
26
28
|
import * as _better_auth_core_oauth20 from "@better-auth/core/oauth2";
|
|
27
|
-
import * as
|
|
28
|
-
import * as
|
|
29
|
-
import { APIError } from "better-call";
|
|
29
|
+
import * as zod80 from "zod";
|
|
30
|
+
import * as better_call118 from "better-call";
|
|
30
31
|
import { AuthEndpoint, AuthMiddleware, createAuthEndpoint, createAuthMiddleware, optionsMiddleware } from "@better-auth/core/api";
|
|
31
|
-
import * as
|
|
32
|
+
import * as zod_v4_core15 from "zod/v4/core";
|
|
32
33
|
|
|
33
34
|
//#region src/api/index.d.ts
|
|
34
35
|
declare function checkEndpointConflicts(options: BetterAuthOptions, logger: InternalLogger): void;
|
|
35
36
|
declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<AuthContext>, options: Option): {
|
|
36
37
|
api: {
|
|
37
|
-
readonly ok:
|
|
38
|
+
readonly ok: better_call118.StrictEndpoint<"/ok", {
|
|
38
39
|
method: "GET";
|
|
39
40
|
metadata: {
|
|
40
41
|
openapi: {
|
|
@@ -64,7 +65,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
64
65
|
}, {
|
|
65
66
|
ok: boolean;
|
|
66
67
|
}>;
|
|
67
|
-
readonly error:
|
|
68
|
+
readonly error: better_call118.StrictEndpoint<"/error", {
|
|
68
69
|
method: "GET";
|
|
69
70
|
metadata: {
|
|
70
71
|
openapi: {
|
|
@@ -86,47 +87,47 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
86
87
|
scope: "server";
|
|
87
88
|
};
|
|
88
89
|
}, Response>;
|
|
89
|
-
readonly signInSocial:
|
|
90
|
+
readonly signInSocial: better_call118.StrictEndpoint<"/sign-in/social", {
|
|
90
91
|
method: "POST";
|
|
91
92
|
operationId: string;
|
|
92
|
-
body:
|
|
93
|
-
callbackURL:
|
|
94
|
-
newUserCallbackURL:
|
|
95
|
-
errorCallbackURL:
|
|
96
|
-
provider:
|
|
97
|
-
disableRedirect:
|
|
98
|
-
idToken:
|
|
99
|
-
token:
|
|
100
|
-
nonce:
|
|
101
|
-
accessToken:
|
|
102
|
-
refreshToken:
|
|
103
|
-
expiresAt:
|
|
104
|
-
},
|
|
105
|
-
scopes:
|
|
106
|
-
requestSignUp:
|
|
107
|
-
loginHint:
|
|
108
|
-
additionalData:
|
|
109
|
-
},
|
|
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>;
|
|
110
111
|
metadata: {
|
|
111
112
|
$Infer: {
|
|
112
|
-
body:
|
|
113
|
-
callbackURL:
|
|
114
|
-
newUserCallbackURL:
|
|
115
|
-
errorCallbackURL:
|
|
116
|
-
provider:
|
|
117
|
-
disableRedirect:
|
|
118
|
-
idToken:
|
|
119
|
-
token:
|
|
120
|
-
nonce:
|
|
121
|
-
accessToken:
|
|
122
|
-
refreshToken:
|
|
123
|
-
expiresAt:
|
|
124
|
-
},
|
|
125
|
-
scopes:
|
|
126
|
-
requestSignUp:
|
|
127
|
-
loginHint:
|
|
128
|
-
additionalData:
|
|
129
|
-
},
|
|
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>>;
|
|
130
131
|
returned: {
|
|
131
132
|
redirect: boolean;
|
|
132
133
|
token?: string | undefined;
|
|
@@ -194,37 +195,37 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
194
195
|
image?: string | null | undefined;
|
|
195
196
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
196
197
|
}>;
|
|
197
|
-
readonly callbackOAuth:
|
|
198
|
+
readonly callbackOAuth: better_call118.StrictEndpoint<"/callback/:id", {
|
|
198
199
|
method: ("GET" | "POST")[];
|
|
199
200
|
operationId: string;
|
|
200
|
-
body:
|
|
201
|
-
code:
|
|
202
|
-
error:
|
|
203
|
-
device_id:
|
|
204
|
-
error_description:
|
|
205
|
-
state:
|
|
206
|
-
user:
|
|
207
|
-
},
|
|
208
|
-
query:
|
|
209
|
-
code:
|
|
210
|
-
error:
|
|
211
|
-
device_id:
|
|
212
|
-
error_description:
|
|
213
|
-
state:
|
|
214
|
-
user:
|
|
215
|
-
},
|
|
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>>;
|
|
216
217
|
metadata: {
|
|
217
218
|
allowedMediaTypes: string[];
|
|
218
219
|
scope: "server";
|
|
219
220
|
};
|
|
220
221
|
}, void>;
|
|
221
|
-
readonly getSession:
|
|
222
|
+
readonly getSession: better_call118.StrictEndpoint<"/get-session", {
|
|
222
223
|
method: "GET";
|
|
223
224
|
operationId: string;
|
|
224
|
-
query:
|
|
225
|
-
disableCookieCache:
|
|
226
|
-
disableRefresh:
|
|
227
|
-
},
|
|
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>>;
|
|
228
229
|
requireHeaders: true;
|
|
229
230
|
metadata: {
|
|
230
231
|
openapi: {
|
|
@@ -275,7 +276,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
275
276
|
image?: string | null | undefined;
|
|
276
277
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
277
278
|
} | null>;
|
|
278
|
-
readonly signOut:
|
|
279
|
+
readonly signOut: better_call118.StrictEndpoint<"/sign-out", {
|
|
279
280
|
method: "POST";
|
|
280
281
|
operationId: string;
|
|
281
282
|
requireHeaders: true;
|
|
@@ -305,18 +306,18 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
305
306
|
}, {
|
|
306
307
|
success: boolean;
|
|
307
308
|
}>;
|
|
308
|
-
readonly signUpEmail:
|
|
309
|
+
readonly signUpEmail: better_call118.StrictEndpoint<"/sign-up/email", {
|
|
309
310
|
method: "POST";
|
|
310
311
|
operationId: string;
|
|
311
|
-
use: ((inputContext:
|
|
312
|
-
body:
|
|
313
|
-
name:
|
|
314
|
-
email:
|
|
315
|
-
password:
|
|
316
|
-
image:
|
|
317
|
-
callbackURL:
|
|
318
|
-
rememberMe:
|
|
319
|
-
},
|
|
312
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
313
|
+
body: zod80.ZodIntersection<zod80.ZodObject<{
|
|
314
|
+
name: zod80.ZodString;
|
|
315
|
+
email: zod80.ZodEmail;
|
|
316
|
+
password: zod80.ZodString;
|
|
317
|
+
image: zod80.ZodOptional<zod80.ZodString>;
|
|
318
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
319
|
+
rememberMe: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
320
|
+
}, zod_v4_core15.$strip>, zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
320
321
|
metadata: {
|
|
321
322
|
allowedMediaTypes: string[];
|
|
322
323
|
$Infer: {
|
|
@@ -479,16 +480,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
479
480
|
image?: string | null | undefined;
|
|
480
481
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
481
482
|
}>;
|
|
482
|
-
readonly signInEmail:
|
|
483
|
+
readonly signInEmail: better_call118.StrictEndpoint<"/sign-in/email", {
|
|
483
484
|
method: "POST";
|
|
484
485
|
operationId: string;
|
|
485
|
-
use: ((inputContext:
|
|
486
|
-
body:
|
|
487
|
-
email:
|
|
488
|
-
password:
|
|
489
|
-
callbackURL:
|
|
490
|
-
rememberMe:
|
|
491
|
-
},
|
|
486
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
487
|
+
body: zod80.ZodObject<{
|
|
488
|
+
email: zod80.ZodString;
|
|
489
|
+
password: zod80.ZodString;
|
|
490
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
491
|
+
rememberMe: zod80.ZodOptional<zod80.ZodDefault<zod80.ZodBoolean>>;
|
|
492
|
+
}, zod_v4_core15.$strip>;
|
|
492
493
|
metadata: {
|
|
493
494
|
allowedMediaTypes: string[];
|
|
494
495
|
$Infer: {
|
|
@@ -564,16 +565,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
564
565
|
image?: string | null | undefined;
|
|
565
566
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
566
567
|
}>;
|
|
567
|
-
readonly resetPassword:
|
|
568
|
+
readonly resetPassword: better_call118.StrictEndpoint<"/reset-password", {
|
|
568
569
|
method: "POST";
|
|
569
570
|
operationId: string;
|
|
570
|
-
query:
|
|
571
|
-
token:
|
|
572
|
-
},
|
|
573
|
-
body:
|
|
574
|
-
newPassword:
|
|
575
|
-
token:
|
|
576
|
-
},
|
|
571
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
572
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
573
|
+
}, zod_v4_core15.$strip>>;
|
|
574
|
+
body: zod80.ZodObject<{
|
|
575
|
+
newPassword: zod80.ZodString;
|
|
576
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
577
|
+
}, zod_v4_core15.$strip>;
|
|
577
578
|
metadata: {
|
|
578
579
|
openapi: {
|
|
579
580
|
operationId: string;
|
|
@@ -600,14 +601,14 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
600
601
|
}, {
|
|
601
602
|
status: boolean;
|
|
602
603
|
}>;
|
|
603
|
-
readonly verifyEmail:
|
|
604
|
+
readonly verifyEmail: better_call118.StrictEndpoint<"/verify-email", {
|
|
604
605
|
method: "GET";
|
|
605
606
|
operationId: string;
|
|
606
|
-
query:
|
|
607
|
-
token:
|
|
608
|
-
callbackURL:
|
|
609
|
-
},
|
|
610
|
-
use: ((inputContext:
|
|
607
|
+
query: zod80.ZodObject<{
|
|
608
|
+
token: zod80.ZodString;
|
|
609
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
610
|
+
}, zod_v4_core15.$strip>;
|
|
611
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
611
612
|
metadata: {
|
|
612
613
|
openapi: {
|
|
613
614
|
description: string;
|
|
@@ -656,13 +657,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
656
657
|
}, void | {
|
|
657
658
|
status: boolean;
|
|
658
659
|
}>;
|
|
659
|
-
readonly sendVerificationEmail:
|
|
660
|
+
readonly sendVerificationEmail: better_call118.StrictEndpoint<"/send-verification-email", {
|
|
660
661
|
method: "POST";
|
|
661
662
|
operationId: string;
|
|
662
|
-
body:
|
|
663
|
-
email:
|
|
664
|
-
callbackURL:
|
|
665
|
-
},
|
|
663
|
+
body: zod80.ZodObject<{
|
|
664
|
+
email: zod80.ZodEmail;
|
|
665
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
666
|
+
}, zod_v4_core15.$strip>;
|
|
666
667
|
metadata: {
|
|
667
668
|
openapi: {
|
|
668
669
|
operationId: string;
|
|
@@ -731,13 +732,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
731
732
|
}, {
|
|
732
733
|
status: boolean;
|
|
733
734
|
}>;
|
|
734
|
-
readonly changeEmail:
|
|
735
|
+
readonly changeEmail: better_call118.StrictEndpoint<"/change-email", {
|
|
735
736
|
method: "POST";
|
|
736
|
-
body:
|
|
737
|
-
newEmail:
|
|
738
|
-
callbackURL:
|
|
739
|
-
},
|
|
740
|
-
use: ((inputContext:
|
|
737
|
+
body: zod80.ZodObject<{
|
|
738
|
+
newEmail: zod80.ZodEmail;
|
|
739
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
740
|
+
}, zod_v4_core15.$strip>;
|
|
741
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
741
742
|
session: {
|
|
742
743
|
session: Record<string, any> & {
|
|
743
744
|
id: string;
|
|
@@ -812,15 +813,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
812
813
|
}, {
|
|
813
814
|
status: boolean;
|
|
814
815
|
}>;
|
|
815
|
-
readonly changePassword:
|
|
816
|
+
readonly changePassword: better_call118.StrictEndpoint<"/change-password", {
|
|
816
817
|
method: "POST";
|
|
817
818
|
operationId: string;
|
|
818
|
-
body:
|
|
819
|
-
newPassword:
|
|
820
|
-
currentPassword:
|
|
821
|
-
revokeOtherSessions:
|
|
822
|
-
},
|
|
823
|
-
use: ((inputContext:
|
|
819
|
+
body: zod80.ZodObject<{
|
|
820
|
+
newPassword: zod80.ZodString;
|
|
821
|
+
currentPassword: zod80.ZodString;
|
|
822
|
+
revokeOtherSessions: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
823
|
+
}, zod_v4_core15.$strip>;
|
|
824
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
824
825
|
session: {
|
|
825
826
|
session: Record<string, any> & {
|
|
826
827
|
id: string;
|
|
@@ -920,12 +921,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
920
921
|
updatedAt: Date;
|
|
921
922
|
};
|
|
922
923
|
}>;
|
|
923
|
-
readonly setPassword:
|
|
924
|
+
readonly setPassword: better_call118.StrictEndpoint<string, {
|
|
924
925
|
method: "POST";
|
|
925
|
-
body:
|
|
926
|
-
newPassword:
|
|
927
|
-
},
|
|
928
|
-
use: ((inputContext:
|
|
926
|
+
body: zod80.ZodObject<{
|
|
927
|
+
newPassword: zod80.ZodString;
|
|
928
|
+
}, zod_v4_core15.$strip>;
|
|
929
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
929
930
|
session: {
|
|
930
931
|
session: Record<string, any> & {
|
|
931
932
|
id: string;
|
|
@@ -951,11 +952,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
951
952
|
}, {
|
|
952
953
|
status: boolean;
|
|
953
954
|
}>;
|
|
954
|
-
readonly updateUser:
|
|
955
|
+
readonly updateUser: better_call118.StrictEndpoint<"/update-user", {
|
|
955
956
|
method: "POST";
|
|
956
957
|
operationId: string;
|
|
957
|
-
body:
|
|
958
|
-
use: ((inputContext:
|
|
958
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
959
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
959
960
|
session: {
|
|
960
961
|
session: Record<string, any> & {
|
|
961
962
|
id: string;
|
|
@@ -1031,9 +1032,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1031
1032
|
}, {
|
|
1032
1033
|
status: boolean;
|
|
1033
1034
|
}>;
|
|
1034
|
-
readonly deleteUser:
|
|
1035
|
+
readonly deleteUser: better_call118.StrictEndpoint<"/delete-user", {
|
|
1035
1036
|
method: "POST";
|
|
1036
|
-
use: ((inputContext:
|
|
1037
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1037
1038
|
session: {
|
|
1038
1039
|
session: Record<string, any> & {
|
|
1039
1040
|
id: string;
|
|
@@ -1056,11 +1057,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1056
1057
|
};
|
|
1057
1058
|
};
|
|
1058
1059
|
}>)[];
|
|
1059
|
-
body:
|
|
1060
|
-
callbackURL:
|
|
1061
|
-
password:
|
|
1062
|
-
token:
|
|
1063
|
-
},
|
|
1060
|
+
body: zod80.ZodObject<{
|
|
1061
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1062
|
+
password: zod80.ZodOptional<zod80.ZodString>;
|
|
1063
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
1064
|
+
}, zod_v4_core15.$strip>;
|
|
1064
1065
|
metadata: {
|
|
1065
1066
|
openapi: {
|
|
1066
1067
|
operationId: string;
|
|
@@ -1118,12 +1119,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1118
1119
|
success: boolean;
|
|
1119
1120
|
message: string;
|
|
1120
1121
|
}>;
|
|
1121
|
-
readonly requestPasswordReset:
|
|
1122
|
+
readonly requestPasswordReset: better_call118.StrictEndpoint<"/request-password-reset", {
|
|
1122
1123
|
method: "POST";
|
|
1123
|
-
body:
|
|
1124
|
-
email:
|
|
1125
|
-
redirectTo:
|
|
1126
|
-
},
|
|
1124
|
+
body: zod80.ZodObject<{
|
|
1125
|
+
email: zod80.ZodEmail;
|
|
1126
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
1127
|
+
}, zod_v4_core15.$strip>;
|
|
1127
1128
|
metadata: {
|
|
1128
1129
|
openapi: {
|
|
1129
1130
|
operationId: string;
|
|
@@ -1154,13 +1155,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1154
1155
|
status: boolean;
|
|
1155
1156
|
message: string;
|
|
1156
1157
|
}>;
|
|
1157
|
-
readonly requestPasswordResetCallback:
|
|
1158
|
+
readonly requestPasswordResetCallback: better_call118.StrictEndpoint<"/reset-password/:token", {
|
|
1158
1159
|
method: "GET";
|
|
1159
1160
|
operationId: string;
|
|
1160
|
-
query:
|
|
1161
|
-
callbackURL:
|
|
1162
|
-
},
|
|
1163
|
-
use: ((inputContext:
|
|
1161
|
+
query: zod80.ZodObject<{
|
|
1162
|
+
callbackURL: zod80.ZodString;
|
|
1163
|
+
}, zod_v4_core15.$strip>;
|
|
1164
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
1164
1165
|
metadata: {
|
|
1165
1166
|
openapi: {
|
|
1166
1167
|
operationId: string;
|
|
@@ -1202,10 +1203,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1202
1203
|
};
|
|
1203
1204
|
};
|
|
1204
1205
|
}, never>;
|
|
1205
|
-
readonly listSessions:
|
|
1206
|
+
readonly listSessions: better_call118.StrictEndpoint<"/list-sessions", {
|
|
1206
1207
|
method: "GET";
|
|
1207
1208
|
operationId: string;
|
|
1208
|
-
use: ((inputContext:
|
|
1209
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1209
1210
|
session: {
|
|
1210
1211
|
session: Record<string, any> & {
|
|
1211
1212
|
id: string;
|
|
@@ -1260,12 +1261,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1260
1261
|
ipAddress?: string | null | undefined;
|
|
1261
1262
|
userAgent?: string | null | undefined;
|
|
1262
1263
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
1263
|
-
readonly revokeSession:
|
|
1264
|
+
readonly revokeSession: better_call118.StrictEndpoint<"/revoke-session", {
|
|
1264
1265
|
method: "POST";
|
|
1265
|
-
body:
|
|
1266
|
-
token:
|
|
1267
|
-
},
|
|
1268
|
-
use: ((inputContext:
|
|
1266
|
+
body: zod80.ZodObject<{
|
|
1267
|
+
token: zod80.ZodString;
|
|
1268
|
+
}, zod_v4_core15.$strip>;
|
|
1269
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1269
1270
|
session: {
|
|
1270
1271
|
session: Record<string, any> & {
|
|
1271
1272
|
id: string;
|
|
@@ -1332,9 +1333,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1332
1333
|
}, {
|
|
1333
1334
|
status: boolean;
|
|
1334
1335
|
}>;
|
|
1335
|
-
readonly revokeSessions:
|
|
1336
|
+
readonly revokeSessions: better_call118.StrictEndpoint<"/revoke-sessions", {
|
|
1336
1337
|
method: "POST";
|
|
1337
|
-
use: ((inputContext:
|
|
1338
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1338
1339
|
session: {
|
|
1339
1340
|
session: Record<string, any> & {
|
|
1340
1341
|
id: string;
|
|
@@ -1385,10 +1386,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1385
1386
|
}, {
|
|
1386
1387
|
status: boolean;
|
|
1387
1388
|
}>;
|
|
1388
|
-
readonly revokeOtherSessions:
|
|
1389
|
+
readonly revokeOtherSessions: better_call118.StrictEndpoint<"/revoke-other-sessions", {
|
|
1389
1390
|
method: "POST";
|
|
1390
1391
|
requireHeaders: true;
|
|
1391
|
-
use: ((inputContext:
|
|
1392
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1392
1393
|
session: {
|
|
1393
1394
|
session: Record<string, any> & {
|
|
1394
1395
|
id: string;
|
|
@@ -1438,26 +1439,26 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1438
1439
|
}, {
|
|
1439
1440
|
status: boolean;
|
|
1440
1441
|
}>;
|
|
1441
|
-
readonly linkSocialAccount:
|
|
1442
|
+
readonly linkSocialAccount: better_call118.StrictEndpoint<"/link-social", {
|
|
1442
1443
|
method: "POST";
|
|
1443
1444
|
requireHeaders: true;
|
|
1444
|
-
body:
|
|
1445
|
-
callbackURL:
|
|
1446
|
-
provider:
|
|
1447
|
-
idToken:
|
|
1448
|
-
token:
|
|
1449
|
-
nonce:
|
|
1450
|
-
accessToken:
|
|
1451
|
-
refreshToken:
|
|
1452
|
-
scopes:
|
|
1453
|
-
},
|
|
1454
|
-
requestSignUp:
|
|
1455
|
-
scopes:
|
|
1456
|
-
errorCallbackURL:
|
|
1457
|
-
disableRedirect:
|
|
1458
|
-
additionalData:
|
|
1459
|
-
},
|
|
1460
|
-
use: ((inputContext:
|
|
1445
|
+
body: zod80.ZodObject<{
|
|
1446
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1447
|
+
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>>;
|
|
1448
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1449
|
+
token: zod80.ZodString;
|
|
1450
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1451
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1452
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1453
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1454
|
+
}, zod_v4_core15.$strip>>;
|
|
1455
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1456
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1457
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1458
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1459
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1460
|
+
}, zod_v4_core15.$strip>;
|
|
1461
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1461
1462
|
session: {
|
|
1462
1463
|
session: Record<string, any> & {
|
|
1463
1464
|
id: string;
|
|
@@ -1516,9 +1517,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1516
1517
|
url: string;
|
|
1517
1518
|
redirect: boolean;
|
|
1518
1519
|
}>;
|
|
1519
|
-
readonly listUserAccounts:
|
|
1520
|
+
readonly listUserAccounts: better_call118.StrictEndpoint<"/list-accounts", {
|
|
1520
1521
|
method: "GET";
|
|
1521
|
-
use: ((inputContext:
|
|
1522
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1522
1523
|
session: {
|
|
1523
1524
|
session: Record<string, any> & {
|
|
1524
1525
|
id: string;
|
|
@@ -1600,13 +1601,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1600
1601
|
userId: string;
|
|
1601
1602
|
scopes: string[];
|
|
1602
1603
|
}[]>;
|
|
1603
|
-
readonly deleteUserCallback:
|
|
1604
|
+
readonly deleteUserCallback: better_call118.StrictEndpoint<"/delete-user/callback", {
|
|
1604
1605
|
method: "GET";
|
|
1605
|
-
query:
|
|
1606
|
-
token:
|
|
1607
|
-
callbackURL:
|
|
1608
|
-
},
|
|
1609
|
-
use: ((inputContext:
|
|
1606
|
+
query: zod80.ZodObject<{
|
|
1607
|
+
token: zod80.ZodString;
|
|
1608
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1609
|
+
}, zod_v4_core15.$strip>;
|
|
1610
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
1610
1611
|
metadata: {
|
|
1611
1612
|
openapi: {
|
|
1612
1613
|
description: string;
|
|
@@ -1640,13 +1641,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1640
1641
|
success: boolean;
|
|
1641
1642
|
message: string;
|
|
1642
1643
|
}>;
|
|
1643
|
-
readonly unlinkAccount:
|
|
1644
|
+
readonly unlinkAccount: better_call118.StrictEndpoint<"/unlink-account", {
|
|
1644
1645
|
method: "POST";
|
|
1645
|
-
body:
|
|
1646
|
-
providerId:
|
|
1647
|
-
accountId:
|
|
1648
|
-
},
|
|
1649
|
-
use: ((inputContext:
|
|
1646
|
+
body: zod80.ZodObject<{
|
|
1647
|
+
providerId: zod80.ZodString;
|
|
1648
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1649
|
+
}, zod_v4_core15.$strip>;
|
|
1650
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1650
1651
|
session: {
|
|
1651
1652
|
session: Record<string, any> & {
|
|
1652
1653
|
id: string;
|
|
@@ -1694,13 +1695,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1694
1695
|
}, {
|
|
1695
1696
|
status: boolean;
|
|
1696
1697
|
}>;
|
|
1697
|
-
readonly refreshToken:
|
|
1698
|
+
readonly refreshToken: better_call118.StrictEndpoint<"/refresh-token", {
|
|
1698
1699
|
method: "POST";
|
|
1699
|
-
body:
|
|
1700
|
-
providerId:
|
|
1701
|
-
accountId:
|
|
1702
|
-
userId:
|
|
1703
|
-
},
|
|
1700
|
+
body: zod80.ZodObject<{
|
|
1701
|
+
providerId: zod80.ZodString;
|
|
1702
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1703
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
1704
|
+
}, zod_v4_core15.$strip>;
|
|
1704
1705
|
metadata: {
|
|
1705
1706
|
openapi: {
|
|
1706
1707
|
description: string;
|
|
@@ -1753,13 +1754,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1753
1754
|
providerId: string;
|
|
1754
1755
|
accountId: string;
|
|
1755
1756
|
}>;
|
|
1756
|
-
readonly getAccessToken:
|
|
1757
|
+
readonly getAccessToken: better_call118.StrictEndpoint<"/get-access-token", {
|
|
1757
1758
|
method: "POST";
|
|
1758
|
-
body:
|
|
1759
|
-
providerId:
|
|
1760
|
-
accountId:
|
|
1761
|
-
userId:
|
|
1762
|
-
},
|
|
1759
|
+
body: zod80.ZodObject<{
|
|
1760
|
+
providerId: zod80.ZodString;
|
|
1761
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1762
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
1763
|
+
}, zod_v4_core15.$strip>;
|
|
1763
1764
|
metadata: {
|
|
1764
1765
|
openapi: {
|
|
1765
1766
|
description: string;
|
|
@@ -1808,9 +1809,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1808
1809
|
scopes: string[];
|
|
1809
1810
|
idToken: string | undefined;
|
|
1810
1811
|
}>;
|
|
1811
|
-
readonly accountInfo:
|
|
1812
|
+
readonly accountInfo: better_call118.StrictEndpoint<"/account-info", {
|
|
1812
1813
|
method: "GET";
|
|
1813
|
-
use: ((inputContext:
|
|
1814
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
1814
1815
|
session: {
|
|
1815
1816
|
session: Record<string, any> & {
|
|
1816
1817
|
id: string;
|
|
@@ -1880,9 +1881,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1880
1881
|
};
|
|
1881
1882
|
};
|
|
1882
1883
|
};
|
|
1883
|
-
query:
|
|
1884
|
-
accountId:
|
|
1885
|
-
},
|
|
1884
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
1885
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1886
|
+
}, zod_v4_core15.$strip>>;
|
|
1886
1887
|
}, {
|
|
1887
1888
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
1888
1889
|
data: Record<string, any>;
|
|
@@ -1898,7 +1899,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1898
1899
|
declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, options: Option) => {
|
|
1899
1900
|
handler: (request: Request) => Promise<Response>;
|
|
1900
1901
|
endpoints: {
|
|
1901
|
-
readonly ok:
|
|
1902
|
+
readonly ok: better_call118.StrictEndpoint<"/ok", {
|
|
1902
1903
|
method: "GET";
|
|
1903
1904
|
metadata: {
|
|
1904
1905
|
openapi: {
|
|
@@ -1928,7 +1929,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1928
1929
|
}, {
|
|
1929
1930
|
ok: boolean;
|
|
1930
1931
|
}>;
|
|
1931
|
-
readonly error:
|
|
1932
|
+
readonly error: better_call118.StrictEndpoint<"/error", {
|
|
1932
1933
|
method: "GET";
|
|
1933
1934
|
metadata: {
|
|
1934
1935
|
openapi: {
|
|
@@ -1950,47 +1951,47 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1950
1951
|
scope: "server";
|
|
1951
1952
|
};
|
|
1952
1953
|
}, Response>;
|
|
1953
|
-
readonly signInSocial:
|
|
1954
|
+
readonly signInSocial: better_call118.StrictEndpoint<"/sign-in/social", {
|
|
1954
1955
|
method: "POST";
|
|
1955
1956
|
operationId: string;
|
|
1956
|
-
body:
|
|
1957
|
-
callbackURL:
|
|
1958
|
-
newUserCallbackURL:
|
|
1959
|
-
errorCallbackURL:
|
|
1960
|
-
provider:
|
|
1961
|
-
disableRedirect:
|
|
1962
|
-
idToken:
|
|
1963
|
-
token:
|
|
1964
|
-
nonce:
|
|
1965
|
-
accessToken:
|
|
1966
|
-
refreshToken:
|
|
1967
|
-
expiresAt:
|
|
1968
|
-
},
|
|
1969
|
-
scopes:
|
|
1970
|
-
requestSignUp:
|
|
1971
|
-
loginHint:
|
|
1972
|
-
additionalData:
|
|
1973
|
-
},
|
|
1957
|
+
body: zod80.ZodObject<{
|
|
1958
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1959
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1960
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1961
|
+
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>>;
|
|
1962
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1963
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1964
|
+
token: zod80.ZodString;
|
|
1965
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1966
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1967
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1968
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
1969
|
+
}, zod_v4_core15.$strip>>;
|
|
1970
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1971
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1972
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
1973
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1974
|
+
}, zod_v4_core15.$strip>;
|
|
1974
1975
|
metadata: {
|
|
1975
1976
|
$Infer: {
|
|
1976
|
-
body:
|
|
1977
|
-
callbackURL:
|
|
1978
|
-
newUserCallbackURL:
|
|
1979
|
-
errorCallbackURL:
|
|
1980
|
-
provider:
|
|
1981
|
-
disableRedirect:
|
|
1982
|
-
idToken:
|
|
1983
|
-
token:
|
|
1984
|
-
nonce:
|
|
1985
|
-
accessToken:
|
|
1986
|
-
refreshToken:
|
|
1987
|
-
expiresAt:
|
|
1988
|
-
},
|
|
1989
|
-
scopes:
|
|
1990
|
-
requestSignUp:
|
|
1991
|
-
loginHint:
|
|
1992
|
-
additionalData:
|
|
1993
|
-
},
|
|
1977
|
+
body: zod80.infer<zod80.ZodObject<{
|
|
1978
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1979
|
+
newUserCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1980
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
1981
|
+
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>>;
|
|
1982
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1983
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
1984
|
+
token: zod80.ZodString;
|
|
1985
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
1986
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1987
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
1988
|
+
expiresAt: zod80.ZodOptional<zod80.ZodNumber>;
|
|
1989
|
+
}, zod_v4_core15.$strip>>;
|
|
1990
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
1991
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
1992
|
+
loginHint: zod80.ZodOptional<zod80.ZodString>;
|
|
1993
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
1994
|
+
}, zod_v4_core15.$strip>>;
|
|
1994
1995
|
returned: {
|
|
1995
1996
|
redirect: boolean;
|
|
1996
1997
|
token?: string | undefined;
|
|
@@ -2058,37 +2059,37 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2058
2059
|
image?: string | null | undefined;
|
|
2059
2060
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2060
2061
|
}>;
|
|
2061
|
-
readonly callbackOAuth:
|
|
2062
|
+
readonly callbackOAuth: better_call118.StrictEndpoint<"/callback/:id", {
|
|
2062
2063
|
method: ("GET" | "POST")[];
|
|
2063
2064
|
operationId: string;
|
|
2064
|
-
body:
|
|
2065
|
-
code:
|
|
2066
|
-
error:
|
|
2067
|
-
device_id:
|
|
2068
|
-
error_description:
|
|
2069
|
-
state:
|
|
2070
|
-
user:
|
|
2071
|
-
},
|
|
2072
|
-
query:
|
|
2073
|
-
code:
|
|
2074
|
-
error:
|
|
2075
|
-
device_id:
|
|
2076
|
-
error_description:
|
|
2077
|
-
state:
|
|
2078
|
-
user:
|
|
2079
|
-
},
|
|
2065
|
+
body: zod80.ZodOptional<zod80.ZodObject<{
|
|
2066
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
2067
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
2068
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
2069
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
2070
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
2071
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
2072
|
+
}, zod_v4_core15.$strip>>;
|
|
2073
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2074
|
+
code: zod80.ZodOptional<zod80.ZodString>;
|
|
2075
|
+
error: zod80.ZodOptional<zod80.ZodString>;
|
|
2076
|
+
device_id: zod80.ZodOptional<zod80.ZodString>;
|
|
2077
|
+
error_description: zod80.ZodOptional<zod80.ZodString>;
|
|
2078
|
+
state: zod80.ZodOptional<zod80.ZodString>;
|
|
2079
|
+
user: zod80.ZodOptional<zod80.ZodString>;
|
|
2080
|
+
}, zod_v4_core15.$strip>>;
|
|
2080
2081
|
metadata: {
|
|
2081
2082
|
allowedMediaTypes: string[];
|
|
2082
2083
|
scope: "server";
|
|
2083
2084
|
};
|
|
2084
2085
|
}, void>;
|
|
2085
|
-
readonly getSession:
|
|
2086
|
+
readonly getSession: better_call118.StrictEndpoint<"/get-session", {
|
|
2086
2087
|
method: "GET";
|
|
2087
2088
|
operationId: string;
|
|
2088
|
-
query:
|
|
2089
|
-
disableCookieCache:
|
|
2090
|
-
disableRefresh:
|
|
2091
|
-
},
|
|
2089
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2090
|
+
disableCookieCache: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
2091
|
+
disableRefresh: zod80.ZodOptional<zod80.ZodCoercedBoolean<unknown>>;
|
|
2092
|
+
}, zod_v4_core15.$strip>>;
|
|
2092
2093
|
requireHeaders: true;
|
|
2093
2094
|
metadata: {
|
|
2094
2095
|
openapi: {
|
|
@@ -2139,7 +2140,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2139
2140
|
image?: string | null | undefined;
|
|
2140
2141
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2141
2142
|
} | null>;
|
|
2142
|
-
readonly signOut:
|
|
2143
|
+
readonly signOut: better_call118.StrictEndpoint<"/sign-out", {
|
|
2143
2144
|
method: "POST";
|
|
2144
2145
|
operationId: string;
|
|
2145
2146
|
requireHeaders: true;
|
|
@@ -2169,18 +2170,18 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2169
2170
|
}, {
|
|
2170
2171
|
success: boolean;
|
|
2171
2172
|
}>;
|
|
2172
|
-
readonly signUpEmail:
|
|
2173
|
+
readonly signUpEmail: better_call118.StrictEndpoint<"/sign-up/email", {
|
|
2173
2174
|
method: "POST";
|
|
2174
2175
|
operationId: string;
|
|
2175
|
-
use: ((inputContext:
|
|
2176
|
-
body:
|
|
2177
|
-
name:
|
|
2178
|
-
email:
|
|
2179
|
-
password:
|
|
2180
|
-
image:
|
|
2181
|
-
callbackURL:
|
|
2182
|
-
rememberMe:
|
|
2183
|
-
},
|
|
2176
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2177
|
+
body: zod80.ZodIntersection<zod80.ZodObject<{
|
|
2178
|
+
name: zod80.ZodString;
|
|
2179
|
+
email: zod80.ZodEmail;
|
|
2180
|
+
password: zod80.ZodString;
|
|
2181
|
+
image: zod80.ZodOptional<zod80.ZodString>;
|
|
2182
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2183
|
+
rememberMe: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
2184
|
+
}, zod_v4_core15.$strip>, zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
2184
2185
|
metadata: {
|
|
2185
2186
|
allowedMediaTypes: string[];
|
|
2186
2187
|
$Infer: {
|
|
@@ -2343,16 +2344,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2343
2344
|
image?: string | null | undefined;
|
|
2344
2345
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2345
2346
|
}>;
|
|
2346
|
-
readonly signInEmail:
|
|
2347
|
+
readonly signInEmail: better_call118.StrictEndpoint<"/sign-in/email", {
|
|
2347
2348
|
method: "POST";
|
|
2348
2349
|
operationId: string;
|
|
2349
|
-
use: ((inputContext:
|
|
2350
|
-
body:
|
|
2351
|
-
email:
|
|
2352
|
-
password:
|
|
2353
|
-
callbackURL:
|
|
2354
|
-
rememberMe:
|
|
2355
|
-
},
|
|
2350
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2351
|
+
body: zod80.ZodObject<{
|
|
2352
|
+
email: zod80.ZodString;
|
|
2353
|
+
password: zod80.ZodString;
|
|
2354
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2355
|
+
rememberMe: zod80.ZodOptional<zod80.ZodDefault<zod80.ZodBoolean>>;
|
|
2356
|
+
}, zod_v4_core15.$strip>;
|
|
2356
2357
|
metadata: {
|
|
2357
2358
|
allowedMediaTypes: string[];
|
|
2358
2359
|
$Infer: {
|
|
@@ -2428,16 +2429,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2428
2429
|
image?: string | null | undefined;
|
|
2429
2430
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2430
2431
|
}>;
|
|
2431
|
-
readonly resetPassword:
|
|
2432
|
+
readonly resetPassword: better_call118.StrictEndpoint<"/reset-password", {
|
|
2432
2433
|
method: "POST";
|
|
2433
2434
|
operationId: string;
|
|
2434
|
-
query:
|
|
2435
|
-
token:
|
|
2436
|
-
},
|
|
2437
|
-
body:
|
|
2438
|
-
newPassword:
|
|
2439
|
-
token:
|
|
2440
|
-
},
|
|
2435
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
2436
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2437
|
+
}, zod_v4_core15.$strip>>;
|
|
2438
|
+
body: zod80.ZodObject<{
|
|
2439
|
+
newPassword: zod80.ZodString;
|
|
2440
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2441
|
+
}, zod_v4_core15.$strip>;
|
|
2441
2442
|
metadata: {
|
|
2442
2443
|
openapi: {
|
|
2443
2444
|
operationId: string;
|
|
@@ -2464,14 +2465,14 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2464
2465
|
}, {
|
|
2465
2466
|
status: boolean;
|
|
2466
2467
|
}>;
|
|
2467
|
-
readonly verifyEmail:
|
|
2468
|
+
readonly verifyEmail: better_call118.StrictEndpoint<"/verify-email", {
|
|
2468
2469
|
method: "GET";
|
|
2469
2470
|
operationId: string;
|
|
2470
|
-
query:
|
|
2471
|
-
token:
|
|
2472
|
-
callbackURL:
|
|
2473
|
-
},
|
|
2474
|
-
use: ((inputContext:
|
|
2471
|
+
query: zod80.ZodObject<{
|
|
2472
|
+
token: zod80.ZodString;
|
|
2473
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2474
|
+
}, zod_v4_core15.$strip>;
|
|
2475
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
2475
2476
|
metadata: {
|
|
2476
2477
|
openapi: {
|
|
2477
2478
|
description: string;
|
|
@@ -2520,13 +2521,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2520
2521
|
}, void | {
|
|
2521
2522
|
status: boolean;
|
|
2522
2523
|
}>;
|
|
2523
|
-
readonly sendVerificationEmail:
|
|
2524
|
+
readonly sendVerificationEmail: better_call118.StrictEndpoint<"/send-verification-email", {
|
|
2524
2525
|
method: "POST";
|
|
2525
2526
|
operationId: string;
|
|
2526
|
-
body:
|
|
2527
|
-
email:
|
|
2528
|
-
callbackURL:
|
|
2529
|
-
},
|
|
2527
|
+
body: zod80.ZodObject<{
|
|
2528
|
+
email: zod80.ZodEmail;
|
|
2529
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2530
|
+
}, zod_v4_core15.$strip>;
|
|
2530
2531
|
metadata: {
|
|
2531
2532
|
openapi: {
|
|
2532
2533
|
operationId: string;
|
|
@@ -2595,13 +2596,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2595
2596
|
}, {
|
|
2596
2597
|
status: boolean;
|
|
2597
2598
|
}>;
|
|
2598
|
-
readonly changeEmail:
|
|
2599
|
+
readonly changeEmail: better_call118.StrictEndpoint<"/change-email", {
|
|
2599
2600
|
method: "POST";
|
|
2600
|
-
body:
|
|
2601
|
-
newEmail:
|
|
2602
|
-
callbackURL:
|
|
2603
|
-
},
|
|
2604
|
-
use: ((inputContext:
|
|
2601
|
+
body: zod80.ZodObject<{
|
|
2602
|
+
newEmail: zod80.ZodEmail;
|
|
2603
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2604
|
+
}, zod_v4_core15.$strip>;
|
|
2605
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2605
2606
|
session: {
|
|
2606
2607
|
session: Record<string, any> & {
|
|
2607
2608
|
id: string;
|
|
@@ -2676,15 +2677,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2676
2677
|
}, {
|
|
2677
2678
|
status: boolean;
|
|
2678
2679
|
}>;
|
|
2679
|
-
readonly changePassword:
|
|
2680
|
+
readonly changePassword: better_call118.StrictEndpoint<"/change-password", {
|
|
2680
2681
|
method: "POST";
|
|
2681
2682
|
operationId: string;
|
|
2682
|
-
body:
|
|
2683
|
-
newPassword:
|
|
2684
|
-
currentPassword:
|
|
2685
|
-
revokeOtherSessions:
|
|
2686
|
-
},
|
|
2687
|
-
use: ((inputContext:
|
|
2683
|
+
body: zod80.ZodObject<{
|
|
2684
|
+
newPassword: zod80.ZodString;
|
|
2685
|
+
currentPassword: zod80.ZodString;
|
|
2686
|
+
revokeOtherSessions: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
2687
|
+
}, zod_v4_core15.$strip>;
|
|
2688
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2688
2689
|
session: {
|
|
2689
2690
|
session: Record<string, any> & {
|
|
2690
2691
|
id: string;
|
|
@@ -2784,12 +2785,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2784
2785
|
updatedAt: Date;
|
|
2785
2786
|
};
|
|
2786
2787
|
}>;
|
|
2787
|
-
readonly setPassword:
|
|
2788
|
+
readonly setPassword: better_call118.StrictEndpoint<string, {
|
|
2788
2789
|
method: "POST";
|
|
2789
|
-
body:
|
|
2790
|
-
newPassword:
|
|
2791
|
-
},
|
|
2792
|
-
use: ((inputContext:
|
|
2790
|
+
body: zod80.ZodObject<{
|
|
2791
|
+
newPassword: zod80.ZodString;
|
|
2792
|
+
}, zod_v4_core15.$strip>;
|
|
2793
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2793
2794
|
session: {
|
|
2794
2795
|
session: Record<string, any> & {
|
|
2795
2796
|
id: string;
|
|
@@ -2815,11 +2816,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2815
2816
|
}, {
|
|
2816
2817
|
status: boolean;
|
|
2817
2818
|
}>;
|
|
2818
|
-
readonly updateUser:
|
|
2819
|
+
readonly updateUser: better_call118.StrictEndpoint<"/update-user", {
|
|
2819
2820
|
method: "POST";
|
|
2820
2821
|
operationId: string;
|
|
2821
|
-
body:
|
|
2822
|
-
use: ((inputContext:
|
|
2822
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
2823
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2823
2824
|
session: {
|
|
2824
2825
|
session: Record<string, any> & {
|
|
2825
2826
|
id: string;
|
|
@@ -2895,9 +2896,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2895
2896
|
}, {
|
|
2896
2897
|
status: boolean;
|
|
2897
2898
|
}>;
|
|
2898
|
-
readonly deleteUser:
|
|
2899
|
+
readonly deleteUser: better_call118.StrictEndpoint<"/delete-user", {
|
|
2899
2900
|
method: "POST";
|
|
2900
|
-
use: ((inputContext:
|
|
2901
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
2901
2902
|
session: {
|
|
2902
2903
|
session: Record<string, any> & {
|
|
2903
2904
|
id: string;
|
|
@@ -2920,11 +2921,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2920
2921
|
};
|
|
2921
2922
|
};
|
|
2922
2923
|
}>)[];
|
|
2923
|
-
body:
|
|
2924
|
-
callbackURL:
|
|
2925
|
-
password:
|
|
2926
|
-
token:
|
|
2927
|
-
},
|
|
2924
|
+
body: zod80.ZodObject<{
|
|
2925
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2926
|
+
password: zod80.ZodOptional<zod80.ZodString>;
|
|
2927
|
+
token: zod80.ZodOptional<zod80.ZodString>;
|
|
2928
|
+
}, zod_v4_core15.$strip>;
|
|
2928
2929
|
metadata: {
|
|
2929
2930
|
openapi: {
|
|
2930
2931
|
operationId: string;
|
|
@@ -2982,12 +2983,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2982
2983
|
success: boolean;
|
|
2983
2984
|
message: string;
|
|
2984
2985
|
}>;
|
|
2985
|
-
readonly requestPasswordReset:
|
|
2986
|
+
readonly requestPasswordReset: better_call118.StrictEndpoint<"/request-password-reset", {
|
|
2986
2987
|
method: "POST";
|
|
2987
|
-
body:
|
|
2988
|
-
email:
|
|
2989
|
-
redirectTo:
|
|
2990
|
-
},
|
|
2988
|
+
body: zod80.ZodObject<{
|
|
2989
|
+
email: zod80.ZodEmail;
|
|
2990
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
2991
|
+
}, zod_v4_core15.$strip>;
|
|
2991
2992
|
metadata: {
|
|
2992
2993
|
openapi: {
|
|
2993
2994
|
operationId: string;
|
|
@@ -3018,13 +3019,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3018
3019
|
status: boolean;
|
|
3019
3020
|
message: string;
|
|
3020
3021
|
}>;
|
|
3021
|
-
readonly requestPasswordResetCallback:
|
|
3022
|
+
readonly requestPasswordResetCallback: better_call118.StrictEndpoint<"/reset-password/:token", {
|
|
3022
3023
|
method: "GET";
|
|
3023
3024
|
operationId: string;
|
|
3024
|
-
query:
|
|
3025
|
-
callbackURL:
|
|
3026
|
-
},
|
|
3027
|
-
use: ((inputContext:
|
|
3025
|
+
query: zod80.ZodObject<{
|
|
3026
|
+
callbackURL: zod80.ZodString;
|
|
3027
|
+
}, zod_v4_core15.$strip>;
|
|
3028
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
3028
3029
|
metadata: {
|
|
3029
3030
|
openapi: {
|
|
3030
3031
|
operationId: string;
|
|
@@ -3066,10 +3067,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3066
3067
|
};
|
|
3067
3068
|
};
|
|
3068
3069
|
}, never>;
|
|
3069
|
-
readonly listSessions:
|
|
3070
|
+
readonly listSessions: better_call118.StrictEndpoint<"/list-sessions", {
|
|
3070
3071
|
method: "GET";
|
|
3071
3072
|
operationId: string;
|
|
3072
|
-
use: ((inputContext:
|
|
3073
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3073
3074
|
session: {
|
|
3074
3075
|
session: Record<string, any> & {
|
|
3075
3076
|
id: string;
|
|
@@ -3124,12 +3125,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3124
3125
|
ipAddress?: string | null | undefined;
|
|
3125
3126
|
userAgent?: string | null | undefined;
|
|
3126
3127
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
3127
|
-
readonly revokeSession:
|
|
3128
|
+
readonly revokeSession: better_call118.StrictEndpoint<"/revoke-session", {
|
|
3128
3129
|
method: "POST";
|
|
3129
|
-
body:
|
|
3130
|
-
token:
|
|
3131
|
-
},
|
|
3132
|
-
use: ((inputContext:
|
|
3130
|
+
body: zod80.ZodObject<{
|
|
3131
|
+
token: zod80.ZodString;
|
|
3132
|
+
}, zod_v4_core15.$strip>;
|
|
3133
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3133
3134
|
session: {
|
|
3134
3135
|
session: Record<string, any> & {
|
|
3135
3136
|
id: string;
|
|
@@ -3196,9 +3197,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3196
3197
|
}, {
|
|
3197
3198
|
status: boolean;
|
|
3198
3199
|
}>;
|
|
3199
|
-
readonly revokeSessions:
|
|
3200
|
+
readonly revokeSessions: better_call118.StrictEndpoint<"/revoke-sessions", {
|
|
3200
3201
|
method: "POST";
|
|
3201
|
-
use: ((inputContext:
|
|
3202
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3202
3203
|
session: {
|
|
3203
3204
|
session: Record<string, any> & {
|
|
3204
3205
|
id: string;
|
|
@@ -3249,10 +3250,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3249
3250
|
}, {
|
|
3250
3251
|
status: boolean;
|
|
3251
3252
|
}>;
|
|
3252
|
-
readonly revokeOtherSessions:
|
|
3253
|
+
readonly revokeOtherSessions: better_call118.StrictEndpoint<"/revoke-other-sessions", {
|
|
3253
3254
|
method: "POST";
|
|
3254
3255
|
requireHeaders: true;
|
|
3255
|
-
use: ((inputContext:
|
|
3256
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3256
3257
|
session: {
|
|
3257
3258
|
session: Record<string, any> & {
|
|
3258
3259
|
id: string;
|
|
@@ -3302,26 +3303,26 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3302
3303
|
}, {
|
|
3303
3304
|
status: boolean;
|
|
3304
3305
|
}>;
|
|
3305
|
-
readonly linkSocialAccount:
|
|
3306
|
+
readonly linkSocialAccount: better_call118.StrictEndpoint<"/link-social", {
|
|
3306
3307
|
method: "POST";
|
|
3307
3308
|
requireHeaders: true;
|
|
3308
|
-
body:
|
|
3309
|
-
callbackURL:
|
|
3310
|
-
provider:
|
|
3311
|
-
idToken:
|
|
3312
|
-
token:
|
|
3313
|
-
nonce:
|
|
3314
|
-
accessToken:
|
|
3315
|
-
refreshToken:
|
|
3316
|
-
scopes:
|
|
3317
|
-
},
|
|
3318
|
-
requestSignUp:
|
|
3319
|
-
scopes:
|
|
3320
|
-
errorCallbackURL:
|
|
3321
|
-
disableRedirect:
|
|
3322
|
-
additionalData:
|
|
3323
|
-
},
|
|
3324
|
-
use: ((inputContext:
|
|
3309
|
+
body: zod80.ZodObject<{
|
|
3310
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3311
|
+
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>>;
|
|
3312
|
+
idToken: zod80.ZodOptional<zod80.ZodObject<{
|
|
3313
|
+
token: zod80.ZodString;
|
|
3314
|
+
nonce: zod80.ZodOptional<zod80.ZodString>;
|
|
3315
|
+
accessToken: zod80.ZodOptional<zod80.ZodString>;
|
|
3316
|
+
refreshToken: zod80.ZodOptional<zod80.ZodString>;
|
|
3317
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
3318
|
+
}, zod_v4_core15.$strip>>;
|
|
3319
|
+
requestSignUp: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
3320
|
+
scopes: zod80.ZodOptional<zod80.ZodArray<zod80.ZodString>>;
|
|
3321
|
+
errorCallbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3322
|
+
disableRedirect: zod80.ZodOptional<zod80.ZodBoolean>;
|
|
3323
|
+
additionalData: zod80.ZodOptional<zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>>;
|
|
3324
|
+
}, zod_v4_core15.$strip>;
|
|
3325
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3325
3326
|
session: {
|
|
3326
3327
|
session: Record<string, any> & {
|
|
3327
3328
|
id: string;
|
|
@@ -3380,9 +3381,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3380
3381
|
url: string;
|
|
3381
3382
|
redirect: boolean;
|
|
3382
3383
|
}>;
|
|
3383
|
-
readonly listUserAccounts:
|
|
3384
|
+
readonly listUserAccounts: better_call118.StrictEndpoint<"/list-accounts", {
|
|
3384
3385
|
method: "GET";
|
|
3385
|
-
use: ((inputContext:
|
|
3386
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3386
3387
|
session: {
|
|
3387
3388
|
session: Record<string, any> & {
|
|
3388
3389
|
id: string;
|
|
@@ -3464,13 +3465,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3464
3465
|
userId: string;
|
|
3465
3466
|
scopes: string[];
|
|
3466
3467
|
}[]>;
|
|
3467
|
-
readonly deleteUserCallback:
|
|
3468
|
+
readonly deleteUserCallback: better_call118.StrictEndpoint<"/delete-user/callback", {
|
|
3468
3469
|
method: "GET";
|
|
3469
|
-
query:
|
|
3470
|
-
token:
|
|
3471
|
-
callbackURL:
|
|
3472
|
-
},
|
|
3473
|
-
use: ((inputContext:
|
|
3470
|
+
query: zod80.ZodObject<{
|
|
3471
|
+
token: zod80.ZodString;
|
|
3472
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
3473
|
+
}, zod_v4_core15.$strip>;
|
|
3474
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<void>)[];
|
|
3474
3475
|
metadata: {
|
|
3475
3476
|
openapi: {
|
|
3476
3477
|
description: string;
|
|
@@ -3504,13 +3505,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3504
3505
|
success: boolean;
|
|
3505
3506
|
message: string;
|
|
3506
3507
|
}>;
|
|
3507
|
-
readonly unlinkAccount:
|
|
3508
|
+
readonly unlinkAccount: better_call118.StrictEndpoint<"/unlink-account", {
|
|
3508
3509
|
method: "POST";
|
|
3509
|
-
body:
|
|
3510
|
-
providerId:
|
|
3511
|
-
accountId:
|
|
3512
|
-
},
|
|
3513
|
-
use: ((inputContext:
|
|
3510
|
+
body: zod80.ZodObject<{
|
|
3511
|
+
providerId: zod80.ZodString;
|
|
3512
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3513
|
+
}, zod_v4_core15.$strip>;
|
|
3514
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3514
3515
|
session: {
|
|
3515
3516
|
session: Record<string, any> & {
|
|
3516
3517
|
id: string;
|
|
@@ -3558,13 +3559,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3558
3559
|
}, {
|
|
3559
3560
|
status: boolean;
|
|
3560
3561
|
}>;
|
|
3561
|
-
readonly refreshToken:
|
|
3562
|
+
readonly refreshToken: better_call118.StrictEndpoint<"/refresh-token", {
|
|
3562
3563
|
method: "POST";
|
|
3563
|
-
body:
|
|
3564
|
-
providerId:
|
|
3565
|
-
accountId:
|
|
3566
|
-
userId:
|
|
3567
|
-
},
|
|
3564
|
+
body: zod80.ZodObject<{
|
|
3565
|
+
providerId: zod80.ZodString;
|
|
3566
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3567
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
3568
|
+
}, zod_v4_core15.$strip>;
|
|
3568
3569
|
metadata: {
|
|
3569
3570
|
openapi: {
|
|
3570
3571
|
description: string;
|
|
@@ -3617,13 +3618,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3617
3618
|
providerId: string;
|
|
3618
3619
|
accountId: string;
|
|
3619
3620
|
}>;
|
|
3620
|
-
readonly getAccessToken:
|
|
3621
|
+
readonly getAccessToken: better_call118.StrictEndpoint<"/get-access-token", {
|
|
3621
3622
|
method: "POST";
|
|
3622
|
-
body:
|
|
3623
|
-
providerId:
|
|
3624
|
-
accountId:
|
|
3625
|
-
userId:
|
|
3626
|
-
},
|
|
3623
|
+
body: zod80.ZodObject<{
|
|
3624
|
+
providerId: zod80.ZodString;
|
|
3625
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3626
|
+
userId: zod80.ZodOptional<zod80.ZodString>;
|
|
3627
|
+
}, zod_v4_core15.$strip>;
|
|
3627
3628
|
metadata: {
|
|
3628
3629
|
openapi: {
|
|
3629
3630
|
description: string;
|
|
@@ -3672,9 +3673,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3672
3673
|
scopes: string[];
|
|
3673
3674
|
idToken: string | undefined;
|
|
3674
3675
|
}>;
|
|
3675
|
-
readonly accountInfo:
|
|
3676
|
+
readonly accountInfo: better_call118.StrictEndpoint<"/account-info", {
|
|
3676
3677
|
method: "GET";
|
|
3677
|
-
use: ((inputContext:
|
|
3678
|
+
use: ((inputContext: better_call118.MiddlewareInputContext<better_call118.MiddlewareOptions>) => Promise<{
|
|
3678
3679
|
session: {
|
|
3679
3680
|
session: Record<string, any> & {
|
|
3680
3681
|
id: string;
|
|
@@ -3744,9 +3745,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3744
3745
|
};
|
|
3745
3746
|
};
|
|
3746
3747
|
};
|
|
3747
|
-
query:
|
|
3748
|
-
accountId:
|
|
3749
|
-
},
|
|
3748
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
3749
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3750
|
+
}, zod_v4_core15.$strip>>;
|
|
3750
3751
|
}, {
|
|
3751
3752
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
3752
3753
|
data: Record<string, any>;
|
|
@@ -3756,5 +3757,5 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3756
3757
|
} ? E : {} : {} : {}>;
|
|
3757
3758
|
};
|
|
3758
3759
|
//#endregion
|
|
3759
|
-
export { APIError, type AuthEndpoint, type AuthMiddleware, accountInfo, callbackOAuth, changeEmail, changePassword, checkEndpointConflicts, createAuthEndpoint, createAuthMiddleware, createEmailVerificationToken, deleteUser, deleteUserCallback, error, formCsrfMiddleware, freshSessionMiddleware, getAccessToken, getEndpoints, getIp, getOAuthState, getSession, getSessionFromCtx, linkSocialAccount, listSessions, listUserAccounts, ok, optionsMiddleware, originCheck, originCheckMiddleware, refreshToken, requestOnlySessionMiddleware, requestPasswordReset, requestPasswordResetCallback, resetPassword, revokeOtherSessions, revokeSession, revokeSessions, router, sendVerificationEmail, sendVerificationEmailFn, sensitiveSessionMiddleware, sessionMiddleware, setPassword, signInEmail, signInSocial, signOut, signUpEmail, unlinkAccount, updateUser, verifyEmail };
|
|
3760
|
+
export { APIError, type AuthEndpoint, type AuthMiddleware, accountInfo, callbackOAuth, changeEmail, changePassword, checkEndpointConflicts, createAuthEndpoint, createAuthMiddleware, createEmailVerificationToken, deleteUser, deleteUserCallback, error, formCsrfMiddleware, freshSessionMiddleware, getAccessToken, getEndpoints, getIp, getOAuthState, getSession, getSessionFromCtx, isAPIError, linkSocialAccount, listSessions, listUserAccounts, ok, optionsMiddleware, originCheck, originCheckMiddleware, refreshToken, requestOnlySessionMiddleware, requestPasswordReset, requestPasswordResetCallback, resetPassword, revokeOtherSessions, revokeSession, revokeSessions, router, sendVerificationEmail, sendVerificationEmailFn, sensitiveSessionMiddleware, sessionMiddleware, setPassword, signInEmail, signInSocial, signOut, signUpEmail, unlinkAccount, updateUser, verifyEmail };
|
|
3760
3761
|
//# sourceMappingURL=index.d.mts.map
|