better-auth 1.4.9 → 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 +396 -395
- package/dist/api/index.mjs +6 -4
- package/dist/api/index.mjs.map +1 -1
- package/dist/api/middlewares/origin-check.d.mts +3 -3
- package/dist/api/middlewares/origin-check.mjs +14 -4
- 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 +3 -3
- 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 +2 -2
- package/dist/api/routes/sign-up.mjs +15 -12
- 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 +7 -6
- package/dist/api/to-auth-endpoints.mjs.map +1 -1
- package/dist/client/lynx/index.d.mts +15 -15
- package/dist/client/plugins/index.d.mts +12 -2
- package/dist/client/plugins/index.mjs +11 -1
- package/dist/client/react/index.d.mts +13 -13
- package/dist/client/solid/index.d.mts +13 -13
- package/dist/client/svelte/index.d.mts +15 -15
- package/dist/client/types.d.mts +4 -1
- package/dist/client/vue/index.d.mts +13 -13
- 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 +200 -137
- 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 +181 -112
- 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 +3 -3
- 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/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 +4 -4
- 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 +10 -14
- package/dist/plugins/multi-session/client.mjs +5 -2
- 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 +18 -14
- 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 +2 -2
- 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 +229 -2
- 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 +51 -51
- 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 +77 -77
- 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 +41 -17
- 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 +1349 -1198
- 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 { 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_call116 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_call116.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_call116.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_call116.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_call116.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_call116.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_call116.StrictEndpoint<"/sign-out", {
|
|
279
280
|
method: "POST";
|
|
280
281
|
operationId: string;
|
|
281
282
|
requireHeaders: true;
|
|
@@ -305,17 +306,17 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
305
306
|
}, {
|
|
306
307
|
success: boolean;
|
|
307
308
|
}>;
|
|
308
|
-
readonly signUpEmail:
|
|
309
|
+
readonly signUpEmail: better_call116.StrictEndpoint<"/sign-up/email", {
|
|
309
310
|
method: "POST";
|
|
310
311
|
operationId: string;
|
|
311
|
-
body:
|
|
312
|
-
name:
|
|
313
|
-
email:
|
|
314
|
-
password:
|
|
315
|
-
image:
|
|
316
|
-
callbackURL:
|
|
317
|
-
rememberMe:
|
|
318
|
-
},
|
|
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>>;
|
|
319
320
|
metadata: {
|
|
320
321
|
$Infer: {
|
|
321
322
|
body: {
|
|
@@ -477,15 +478,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
477
478
|
image?: string | null | undefined;
|
|
478
479
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
479
480
|
}>;
|
|
480
|
-
readonly signInEmail:
|
|
481
|
+
readonly signInEmail: better_call116.StrictEndpoint<"/sign-in/email", {
|
|
481
482
|
method: "POST";
|
|
482
483
|
operationId: string;
|
|
483
|
-
body:
|
|
484
|
-
email:
|
|
485
|
-
password:
|
|
486
|
-
callbackURL:
|
|
487
|
-
rememberMe:
|
|
488
|
-
},
|
|
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>;
|
|
489
490
|
metadata: {
|
|
490
491
|
$Infer: {
|
|
491
492
|
body: {
|
|
@@ -560,16 +561,16 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
560
561
|
image?: string | null | undefined;
|
|
561
562
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
562
563
|
}>;
|
|
563
|
-
readonly resetPassword:
|
|
564
|
+
readonly resetPassword: better_call116.StrictEndpoint<"/reset-password", {
|
|
564
565
|
method: "POST";
|
|
565
566
|
operationId: string;
|
|
566
|
-
query:
|
|
567
|
-
token:
|
|
568
|
-
},
|
|
569
|
-
body:
|
|
570
|
-
newPassword:
|
|
571
|
-
token:
|
|
572
|
-
},
|
|
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>;
|
|
573
574
|
metadata: {
|
|
574
575
|
openapi: {
|
|
575
576
|
operationId: string;
|
|
@@ -596,14 +597,14 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
596
597
|
}, {
|
|
597
598
|
status: boolean;
|
|
598
599
|
}>;
|
|
599
|
-
readonly verifyEmail:
|
|
600
|
+
readonly verifyEmail: better_call116.StrictEndpoint<"/verify-email", {
|
|
600
601
|
method: "GET";
|
|
601
602
|
operationId: string;
|
|
602
|
-
query:
|
|
603
|
-
token:
|
|
604
|
-
callbackURL:
|
|
605
|
-
},
|
|
606
|
-
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>)[];
|
|
607
608
|
metadata: {
|
|
608
609
|
openapi: {
|
|
609
610
|
description: string;
|
|
@@ -652,13 +653,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
652
653
|
}, void | {
|
|
653
654
|
status: boolean;
|
|
654
655
|
}>;
|
|
655
|
-
readonly sendVerificationEmail:
|
|
656
|
+
readonly sendVerificationEmail: better_call116.StrictEndpoint<"/send-verification-email", {
|
|
656
657
|
method: "POST";
|
|
657
658
|
operationId: string;
|
|
658
|
-
body:
|
|
659
|
-
email:
|
|
660
|
-
callbackURL:
|
|
661
|
-
},
|
|
659
|
+
body: zod80.ZodObject<{
|
|
660
|
+
email: zod80.ZodEmail;
|
|
661
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
662
|
+
}, zod_v4_core15.$strip>;
|
|
662
663
|
metadata: {
|
|
663
664
|
openapi: {
|
|
664
665
|
operationId: string;
|
|
@@ -727,13 +728,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
727
728
|
}, {
|
|
728
729
|
status: boolean;
|
|
729
730
|
}>;
|
|
730
|
-
readonly changeEmail:
|
|
731
|
+
readonly changeEmail: better_call116.StrictEndpoint<"/change-email", {
|
|
731
732
|
method: "POST";
|
|
732
|
-
body:
|
|
733
|
-
newEmail:
|
|
734
|
-
callbackURL:
|
|
735
|
-
},
|
|
736
|
-
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<{
|
|
737
738
|
session: {
|
|
738
739
|
session: Record<string, any> & {
|
|
739
740
|
id: string;
|
|
@@ -808,15 +809,15 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
808
809
|
}, {
|
|
809
810
|
status: boolean;
|
|
810
811
|
}>;
|
|
811
|
-
readonly changePassword:
|
|
812
|
+
readonly changePassword: better_call116.StrictEndpoint<"/change-password", {
|
|
812
813
|
method: "POST";
|
|
813
814
|
operationId: string;
|
|
814
|
-
body:
|
|
815
|
-
newPassword:
|
|
816
|
-
currentPassword:
|
|
817
|
-
revokeOtherSessions:
|
|
818
|
-
},
|
|
819
|
-
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<{
|
|
820
821
|
session: {
|
|
821
822
|
session: Record<string, any> & {
|
|
822
823
|
id: string;
|
|
@@ -916,12 +917,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
916
917
|
updatedAt: Date;
|
|
917
918
|
};
|
|
918
919
|
}>;
|
|
919
|
-
readonly setPassword:
|
|
920
|
+
readonly setPassword: better_call116.StrictEndpoint<string, {
|
|
920
921
|
method: "POST";
|
|
921
|
-
body:
|
|
922
|
-
newPassword:
|
|
923
|
-
},
|
|
924
|
-
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<{
|
|
925
926
|
session: {
|
|
926
927
|
session: Record<string, any> & {
|
|
927
928
|
id: string;
|
|
@@ -947,11 +948,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
947
948
|
}, {
|
|
948
949
|
status: boolean;
|
|
949
950
|
}>;
|
|
950
|
-
readonly updateUser:
|
|
951
|
+
readonly updateUser: better_call116.StrictEndpoint<"/update-user", {
|
|
951
952
|
method: "POST";
|
|
952
953
|
operationId: string;
|
|
953
|
-
body:
|
|
954
|
-
use: ((inputContext:
|
|
954
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
955
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
955
956
|
session: {
|
|
956
957
|
session: Record<string, any> & {
|
|
957
958
|
id: string;
|
|
@@ -1027,9 +1028,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1027
1028
|
}, {
|
|
1028
1029
|
status: boolean;
|
|
1029
1030
|
}>;
|
|
1030
|
-
readonly deleteUser:
|
|
1031
|
+
readonly deleteUser: better_call116.StrictEndpoint<"/delete-user", {
|
|
1031
1032
|
method: "POST";
|
|
1032
|
-
use: ((inputContext:
|
|
1033
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1033
1034
|
session: {
|
|
1034
1035
|
session: Record<string, any> & {
|
|
1035
1036
|
id: string;
|
|
@@ -1052,11 +1053,11 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1052
1053
|
};
|
|
1053
1054
|
};
|
|
1054
1055
|
}>)[];
|
|
1055
|
-
body:
|
|
1056
|
-
callbackURL:
|
|
1057
|
-
password:
|
|
1058
|
-
token:
|
|
1059
|
-
},
|
|
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>;
|
|
1060
1061
|
metadata: {
|
|
1061
1062
|
openapi: {
|
|
1062
1063
|
operationId: string;
|
|
@@ -1114,12 +1115,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1114
1115
|
success: boolean;
|
|
1115
1116
|
message: string;
|
|
1116
1117
|
}>;
|
|
1117
|
-
readonly requestPasswordReset:
|
|
1118
|
+
readonly requestPasswordReset: better_call116.StrictEndpoint<"/request-password-reset", {
|
|
1118
1119
|
method: "POST";
|
|
1119
|
-
body:
|
|
1120
|
-
email:
|
|
1121
|
-
redirectTo:
|
|
1122
|
-
},
|
|
1120
|
+
body: zod80.ZodObject<{
|
|
1121
|
+
email: zod80.ZodEmail;
|
|
1122
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
1123
|
+
}, zod_v4_core15.$strip>;
|
|
1123
1124
|
metadata: {
|
|
1124
1125
|
openapi: {
|
|
1125
1126
|
operationId: string;
|
|
@@ -1150,13 +1151,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1150
1151
|
status: boolean;
|
|
1151
1152
|
message: string;
|
|
1152
1153
|
}>;
|
|
1153
|
-
readonly requestPasswordResetCallback:
|
|
1154
|
+
readonly requestPasswordResetCallback: better_call116.StrictEndpoint<"/reset-password/:token", {
|
|
1154
1155
|
method: "GET";
|
|
1155
1156
|
operationId: string;
|
|
1156
|
-
query:
|
|
1157
|
-
callbackURL:
|
|
1158
|
-
},
|
|
1159
|
-
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>)[];
|
|
1160
1161
|
metadata: {
|
|
1161
1162
|
openapi: {
|
|
1162
1163
|
operationId: string;
|
|
@@ -1198,10 +1199,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1198
1199
|
};
|
|
1199
1200
|
};
|
|
1200
1201
|
}, never>;
|
|
1201
|
-
readonly listSessions:
|
|
1202
|
+
readonly listSessions: better_call116.StrictEndpoint<"/list-sessions", {
|
|
1202
1203
|
method: "GET";
|
|
1203
1204
|
operationId: string;
|
|
1204
|
-
use: ((inputContext:
|
|
1205
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1205
1206
|
session: {
|
|
1206
1207
|
session: Record<string, any> & {
|
|
1207
1208
|
id: string;
|
|
@@ -1256,12 +1257,12 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1256
1257
|
ipAddress?: string | null | undefined;
|
|
1257
1258
|
userAgent?: string | null | undefined;
|
|
1258
1259
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
1259
|
-
readonly revokeSession:
|
|
1260
|
+
readonly revokeSession: better_call116.StrictEndpoint<"/revoke-session", {
|
|
1260
1261
|
method: "POST";
|
|
1261
|
-
body:
|
|
1262
|
-
token:
|
|
1263
|
-
},
|
|
1264
|
-
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<{
|
|
1265
1266
|
session: {
|
|
1266
1267
|
session: Record<string, any> & {
|
|
1267
1268
|
id: string;
|
|
@@ -1328,9 +1329,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1328
1329
|
}, {
|
|
1329
1330
|
status: boolean;
|
|
1330
1331
|
}>;
|
|
1331
|
-
readonly revokeSessions:
|
|
1332
|
+
readonly revokeSessions: better_call116.StrictEndpoint<"/revoke-sessions", {
|
|
1332
1333
|
method: "POST";
|
|
1333
|
-
use: ((inputContext:
|
|
1334
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1334
1335
|
session: {
|
|
1335
1336
|
session: Record<string, any> & {
|
|
1336
1337
|
id: string;
|
|
@@ -1381,10 +1382,10 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1381
1382
|
}, {
|
|
1382
1383
|
status: boolean;
|
|
1383
1384
|
}>;
|
|
1384
|
-
readonly revokeOtherSessions:
|
|
1385
|
+
readonly revokeOtherSessions: better_call116.StrictEndpoint<"/revoke-other-sessions", {
|
|
1385
1386
|
method: "POST";
|
|
1386
1387
|
requireHeaders: true;
|
|
1387
|
-
use: ((inputContext:
|
|
1388
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1388
1389
|
session: {
|
|
1389
1390
|
session: Record<string, any> & {
|
|
1390
1391
|
id: string;
|
|
@@ -1434,26 +1435,26 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1434
1435
|
}, {
|
|
1435
1436
|
status: boolean;
|
|
1436
1437
|
}>;
|
|
1437
|
-
readonly linkSocialAccount:
|
|
1438
|
+
readonly linkSocialAccount: better_call116.StrictEndpoint<"/link-social", {
|
|
1438
1439
|
method: "POST";
|
|
1439
1440
|
requireHeaders: true;
|
|
1440
|
-
body:
|
|
1441
|
-
callbackURL:
|
|
1442
|
-
provider:
|
|
1443
|
-
idToken:
|
|
1444
|
-
token:
|
|
1445
|
-
nonce:
|
|
1446
|
-
accessToken:
|
|
1447
|
-
refreshToken:
|
|
1448
|
-
scopes:
|
|
1449
|
-
},
|
|
1450
|
-
requestSignUp:
|
|
1451
|
-
scopes:
|
|
1452
|
-
errorCallbackURL:
|
|
1453
|
-
disableRedirect:
|
|
1454
|
-
additionalData:
|
|
1455
|
-
},
|
|
1456
|
-
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<{
|
|
1457
1458
|
session: {
|
|
1458
1459
|
session: Record<string, any> & {
|
|
1459
1460
|
id: string;
|
|
@@ -1512,9 +1513,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1512
1513
|
url: string;
|
|
1513
1514
|
redirect: boolean;
|
|
1514
1515
|
}>;
|
|
1515
|
-
readonly listUserAccounts:
|
|
1516
|
+
readonly listUserAccounts: better_call116.StrictEndpoint<"/list-accounts", {
|
|
1516
1517
|
method: "GET";
|
|
1517
|
-
use: ((inputContext:
|
|
1518
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1518
1519
|
session: {
|
|
1519
1520
|
session: Record<string, any> & {
|
|
1520
1521
|
id: string;
|
|
@@ -1596,13 +1597,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1596
1597
|
userId: string;
|
|
1597
1598
|
scopes: string[];
|
|
1598
1599
|
}[]>;
|
|
1599
|
-
readonly deleteUserCallback:
|
|
1600
|
+
readonly deleteUserCallback: better_call116.StrictEndpoint<"/delete-user/callback", {
|
|
1600
1601
|
method: "GET";
|
|
1601
|
-
query:
|
|
1602
|
-
token:
|
|
1603
|
-
callbackURL:
|
|
1604
|
-
},
|
|
1605
|
-
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>)[];
|
|
1606
1607
|
metadata: {
|
|
1607
1608
|
openapi: {
|
|
1608
1609
|
description: string;
|
|
@@ -1636,13 +1637,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1636
1637
|
success: boolean;
|
|
1637
1638
|
message: string;
|
|
1638
1639
|
}>;
|
|
1639
|
-
readonly unlinkAccount:
|
|
1640
|
+
readonly unlinkAccount: better_call116.StrictEndpoint<"/unlink-account", {
|
|
1640
1641
|
method: "POST";
|
|
1641
|
-
body:
|
|
1642
|
-
providerId:
|
|
1643
|
-
accountId:
|
|
1644
|
-
},
|
|
1645
|
-
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<{
|
|
1646
1647
|
session: {
|
|
1647
1648
|
session: Record<string, any> & {
|
|
1648
1649
|
id: string;
|
|
@@ -1690,13 +1691,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1690
1691
|
}, {
|
|
1691
1692
|
status: boolean;
|
|
1692
1693
|
}>;
|
|
1693
|
-
readonly refreshToken:
|
|
1694
|
+
readonly refreshToken: better_call116.StrictEndpoint<"/refresh-token", {
|
|
1694
1695
|
method: "POST";
|
|
1695
|
-
body:
|
|
1696
|
-
providerId:
|
|
1697
|
-
accountId:
|
|
1698
|
-
userId:
|
|
1699
|
-
},
|
|
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>;
|
|
1700
1701
|
metadata: {
|
|
1701
1702
|
openapi: {
|
|
1702
1703
|
description: string;
|
|
@@ -1749,13 +1750,13 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1749
1750
|
providerId: string;
|
|
1750
1751
|
accountId: string;
|
|
1751
1752
|
}>;
|
|
1752
|
-
readonly getAccessToken:
|
|
1753
|
+
readonly getAccessToken: better_call116.StrictEndpoint<"/get-access-token", {
|
|
1753
1754
|
method: "POST";
|
|
1754
|
-
body:
|
|
1755
|
-
providerId:
|
|
1756
|
-
accountId:
|
|
1757
|
-
userId:
|
|
1758
|
-
},
|
|
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>;
|
|
1759
1760
|
metadata: {
|
|
1760
1761
|
openapi: {
|
|
1761
1762
|
description: string;
|
|
@@ -1804,9 +1805,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1804
1805
|
scopes: string[];
|
|
1805
1806
|
idToken: string | undefined;
|
|
1806
1807
|
}>;
|
|
1807
|
-
readonly accountInfo:
|
|
1808
|
+
readonly accountInfo: better_call116.StrictEndpoint<"/account-info", {
|
|
1808
1809
|
method: "GET";
|
|
1809
|
-
use: ((inputContext:
|
|
1810
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
1810
1811
|
session: {
|
|
1811
1812
|
session: Record<string, any> & {
|
|
1812
1813
|
id: string;
|
|
@@ -1876,9 +1877,9 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1876
1877
|
};
|
|
1877
1878
|
};
|
|
1878
1879
|
};
|
|
1879
|
-
query:
|
|
1880
|
-
accountId:
|
|
1881
|
-
},
|
|
1880
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
1881
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
1882
|
+
}, zod_v4_core15.$strip>>;
|
|
1882
1883
|
}, {
|
|
1883
1884
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
1884
1885
|
data: Record<string, any>;
|
|
@@ -1894,7 +1895,7 @@ declare function getEndpoints<Option extends BetterAuthOptions>(ctx: Awaitable<A
|
|
|
1894
1895
|
declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, options: Option) => {
|
|
1895
1896
|
handler: (request: Request) => Promise<Response>;
|
|
1896
1897
|
endpoints: {
|
|
1897
|
-
readonly ok:
|
|
1898
|
+
readonly ok: better_call116.StrictEndpoint<"/ok", {
|
|
1898
1899
|
method: "GET";
|
|
1899
1900
|
metadata: {
|
|
1900
1901
|
openapi: {
|
|
@@ -1924,7 +1925,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1924
1925
|
}, {
|
|
1925
1926
|
ok: boolean;
|
|
1926
1927
|
}>;
|
|
1927
|
-
readonly error:
|
|
1928
|
+
readonly error: better_call116.StrictEndpoint<"/error", {
|
|
1928
1929
|
method: "GET";
|
|
1929
1930
|
metadata: {
|
|
1930
1931
|
openapi: {
|
|
@@ -1946,47 +1947,47 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
1946
1947
|
scope: "server";
|
|
1947
1948
|
};
|
|
1948
1949
|
}, Response>;
|
|
1949
|
-
readonly signInSocial:
|
|
1950
|
+
readonly signInSocial: better_call116.StrictEndpoint<"/sign-in/social", {
|
|
1950
1951
|
method: "POST";
|
|
1951
1952
|
operationId: string;
|
|
1952
|
-
body:
|
|
1953
|
-
callbackURL:
|
|
1954
|
-
newUserCallbackURL:
|
|
1955
|
-
errorCallbackURL:
|
|
1956
|
-
provider:
|
|
1957
|
-
disableRedirect:
|
|
1958
|
-
idToken:
|
|
1959
|
-
token:
|
|
1960
|
-
nonce:
|
|
1961
|
-
accessToken:
|
|
1962
|
-
refreshToken:
|
|
1963
|
-
expiresAt:
|
|
1964
|
-
},
|
|
1965
|
-
scopes:
|
|
1966
|
-
requestSignUp:
|
|
1967
|
-
loginHint:
|
|
1968
|
-
additionalData:
|
|
1969
|
-
},
|
|
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>;
|
|
1970
1971
|
metadata: {
|
|
1971
1972
|
$Infer: {
|
|
1972
|
-
body:
|
|
1973
|
-
callbackURL:
|
|
1974
|
-
newUserCallbackURL:
|
|
1975
|
-
errorCallbackURL:
|
|
1976
|
-
provider:
|
|
1977
|
-
disableRedirect:
|
|
1978
|
-
idToken:
|
|
1979
|
-
token:
|
|
1980
|
-
nonce:
|
|
1981
|
-
accessToken:
|
|
1982
|
-
refreshToken:
|
|
1983
|
-
expiresAt:
|
|
1984
|
-
},
|
|
1985
|
-
scopes:
|
|
1986
|
-
requestSignUp:
|
|
1987
|
-
loginHint:
|
|
1988
|
-
additionalData:
|
|
1989
|
-
},
|
|
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>>;
|
|
1990
1991
|
returned: {
|
|
1991
1992
|
redirect: boolean;
|
|
1992
1993
|
token?: string | undefined;
|
|
@@ -2054,37 +2055,37 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2054
2055
|
image?: string | null | undefined;
|
|
2055
2056
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2056
2057
|
}>;
|
|
2057
|
-
readonly callbackOAuth:
|
|
2058
|
+
readonly callbackOAuth: better_call116.StrictEndpoint<"/callback/:id", {
|
|
2058
2059
|
method: ("GET" | "POST")[];
|
|
2059
2060
|
operationId: string;
|
|
2060
|
-
body:
|
|
2061
|
-
code:
|
|
2062
|
-
error:
|
|
2063
|
-
device_id:
|
|
2064
|
-
error_description:
|
|
2065
|
-
state:
|
|
2066
|
-
user:
|
|
2067
|
-
},
|
|
2068
|
-
query:
|
|
2069
|
-
code:
|
|
2070
|
-
error:
|
|
2071
|
-
device_id:
|
|
2072
|
-
error_description:
|
|
2073
|
-
state:
|
|
2074
|
-
user:
|
|
2075
|
-
},
|
|
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>>;
|
|
2076
2077
|
metadata: {
|
|
2077
2078
|
allowedMediaTypes: string[];
|
|
2078
2079
|
scope: "server";
|
|
2079
2080
|
};
|
|
2080
2081
|
}, void>;
|
|
2081
|
-
readonly getSession:
|
|
2082
|
+
readonly getSession: better_call116.StrictEndpoint<"/get-session", {
|
|
2082
2083
|
method: "GET";
|
|
2083
2084
|
operationId: string;
|
|
2084
|
-
query:
|
|
2085
|
-
disableCookieCache:
|
|
2086
|
-
disableRefresh:
|
|
2087
|
-
},
|
|
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>>;
|
|
2088
2089
|
requireHeaders: true;
|
|
2089
2090
|
metadata: {
|
|
2090
2091
|
openapi: {
|
|
@@ -2135,7 +2136,7 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2135
2136
|
image?: string | null | undefined;
|
|
2136
2137
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2137
2138
|
} | null>;
|
|
2138
|
-
readonly signOut:
|
|
2139
|
+
readonly signOut: better_call116.StrictEndpoint<"/sign-out", {
|
|
2139
2140
|
method: "POST";
|
|
2140
2141
|
operationId: string;
|
|
2141
2142
|
requireHeaders: true;
|
|
@@ -2165,17 +2166,17 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2165
2166
|
}, {
|
|
2166
2167
|
success: boolean;
|
|
2167
2168
|
}>;
|
|
2168
|
-
readonly signUpEmail:
|
|
2169
|
+
readonly signUpEmail: better_call116.StrictEndpoint<"/sign-up/email", {
|
|
2169
2170
|
method: "POST";
|
|
2170
2171
|
operationId: string;
|
|
2171
|
-
body:
|
|
2172
|
-
name:
|
|
2173
|
-
email:
|
|
2174
|
-
password:
|
|
2175
|
-
image:
|
|
2176
|
-
callbackURL:
|
|
2177
|
-
rememberMe:
|
|
2178
|
-
},
|
|
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>>;
|
|
2179
2180
|
metadata: {
|
|
2180
2181
|
$Infer: {
|
|
2181
2182
|
body: {
|
|
@@ -2337,15 +2338,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2337
2338
|
image?: string | null | undefined;
|
|
2338
2339
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2339
2340
|
}>;
|
|
2340
|
-
readonly signInEmail:
|
|
2341
|
+
readonly signInEmail: better_call116.StrictEndpoint<"/sign-in/email", {
|
|
2341
2342
|
method: "POST";
|
|
2342
2343
|
operationId: string;
|
|
2343
|
-
body:
|
|
2344
|
-
email:
|
|
2345
|
-
password:
|
|
2346
|
-
callbackURL:
|
|
2347
|
-
rememberMe:
|
|
2348
|
-
},
|
|
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>;
|
|
2349
2350
|
metadata: {
|
|
2350
2351
|
$Infer: {
|
|
2351
2352
|
body: {
|
|
@@ -2420,16 +2421,16 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2420
2421
|
image?: string | null | undefined;
|
|
2421
2422
|
} & (Option extends BetterAuthOptions ? AdditionalUserFieldsOutput<Option> : Option extends Auth ? AdditionalUserFieldsOutput<Option["options"]> : {})>>;
|
|
2422
2423
|
}>;
|
|
2423
|
-
readonly resetPassword:
|
|
2424
|
+
readonly resetPassword: better_call116.StrictEndpoint<"/reset-password", {
|
|
2424
2425
|
method: "POST";
|
|
2425
2426
|
operationId: string;
|
|
2426
|
-
query:
|
|
2427
|
-
token:
|
|
2428
|
-
},
|
|
2429
|
-
body:
|
|
2430
|
-
newPassword:
|
|
2431
|
-
token:
|
|
2432
|
-
},
|
|
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>;
|
|
2433
2434
|
metadata: {
|
|
2434
2435
|
openapi: {
|
|
2435
2436
|
operationId: string;
|
|
@@ -2456,14 +2457,14 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2456
2457
|
}, {
|
|
2457
2458
|
status: boolean;
|
|
2458
2459
|
}>;
|
|
2459
|
-
readonly verifyEmail:
|
|
2460
|
+
readonly verifyEmail: better_call116.StrictEndpoint<"/verify-email", {
|
|
2460
2461
|
method: "GET";
|
|
2461
2462
|
operationId: string;
|
|
2462
|
-
query:
|
|
2463
|
-
token:
|
|
2464
|
-
callbackURL:
|
|
2465
|
-
},
|
|
2466
|
-
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>)[];
|
|
2467
2468
|
metadata: {
|
|
2468
2469
|
openapi: {
|
|
2469
2470
|
description: string;
|
|
@@ -2512,13 +2513,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2512
2513
|
}, void | {
|
|
2513
2514
|
status: boolean;
|
|
2514
2515
|
}>;
|
|
2515
|
-
readonly sendVerificationEmail:
|
|
2516
|
+
readonly sendVerificationEmail: better_call116.StrictEndpoint<"/send-verification-email", {
|
|
2516
2517
|
method: "POST";
|
|
2517
2518
|
operationId: string;
|
|
2518
|
-
body:
|
|
2519
|
-
email:
|
|
2520
|
-
callbackURL:
|
|
2521
|
-
},
|
|
2519
|
+
body: zod80.ZodObject<{
|
|
2520
|
+
email: zod80.ZodEmail;
|
|
2521
|
+
callbackURL: zod80.ZodOptional<zod80.ZodString>;
|
|
2522
|
+
}, zod_v4_core15.$strip>;
|
|
2522
2523
|
metadata: {
|
|
2523
2524
|
openapi: {
|
|
2524
2525
|
operationId: string;
|
|
@@ -2587,13 +2588,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2587
2588
|
}, {
|
|
2588
2589
|
status: boolean;
|
|
2589
2590
|
}>;
|
|
2590
|
-
readonly changeEmail:
|
|
2591
|
+
readonly changeEmail: better_call116.StrictEndpoint<"/change-email", {
|
|
2591
2592
|
method: "POST";
|
|
2592
|
-
body:
|
|
2593
|
-
newEmail:
|
|
2594
|
-
callbackURL:
|
|
2595
|
-
},
|
|
2596
|
-
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<{
|
|
2597
2598
|
session: {
|
|
2598
2599
|
session: Record<string, any> & {
|
|
2599
2600
|
id: string;
|
|
@@ -2668,15 +2669,15 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2668
2669
|
}, {
|
|
2669
2670
|
status: boolean;
|
|
2670
2671
|
}>;
|
|
2671
|
-
readonly changePassword:
|
|
2672
|
+
readonly changePassword: better_call116.StrictEndpoint<"/change-password", {
|
|
2672
2673
|
method: "POST";
|
|
2673
2674
|
operationId: string;
|
|
2674
|
-
body:
|
|
2675
|
-
newPassword:
|
|
2676
|
-
currentPassword:
|
|
2677
|
-
revokeOtherSessions:
|
|
2678
|
-
},
|
|
2679
|
-
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<{
|
|
2680
2681
|
session: {
|
|
2681
2682
|
session: Record<string, any> & {
|
|
2682
2683
|
id: string;
|
|
@@ -2776,12 +2777,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2776
2777
|
updatedAt: Date;
|
|
2777
2778
|
};
|
|
2778
2779
|
}>;
|
|
2779
|
-
readonly setPassword:
|
|
2780
|
+
readonly setPassword: better_call116.StrictEndpoint<string, {
|
|
2780
2781
|
method: "POST";
|
|
2781
|
-
body:
|
|
2782
|
-
newPassword:
|
|
2783
|
-
},
|
|
2784
|
-
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<{
|
|
2785
2786
|
session: {
|
|
2786
2787
|
session: Record<string, any> & {
|
|
2787
2788
|
id: string;
|
|
@@ -2807,11 +2808,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2807
2808
|
}, {
|
|
2808
2809
|
status: boolean;
|
|
2809
2810
|
}>;
|
|
2810
|
-
readonly updateUser:
|
|
2811
|
+
readonly updateUser: better_call116.StrictEndpoint<"/update-user", {
|
|
2811
2812
|
method: "POST";
|
|
2812
2813
|
operationId: string;
|
|
2813
|
-
body:
|
|
2814
|
-
use: ((inputContext:
|
|
2814
|
+
body: zod80.ZodRecord<zod80.ZodString, zod80.ZodAny>;
|
|
2815
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2815
2816
|
session: {
|
|
2816
2817
|
session: Record<string, any> & {
|
|
2817
2818
|
id: string;
|
|
@@ -2887,9 +2888,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2887
2888
|
}, {
|
|
2888
2889
|
status: boolean;
|
|
2889
2890
|
}>;
|
|
2890
|
-
readonly deleteUser:
|
|
2891
|
+
readonly deleteUser: better_call116.StrictEndpoint<"/delete-user", {
|
|
2891
2892
|
method: "POST";
|
|
2892
|
-
use: ((inputContext:
|
|
2893
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
2893
2894
|
session: {
|
|
2894
2895
|
session: Record<string, any> & {
|
|
2895
2896
|
id: string;
|
|
@@ -2912,11 +2913,11 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2912
2913
|
};
|
|
2913
2914
|
};
|
|
2914
2915
|
}>)[];
|
|
2915
|
-
body:
|
|
2916
|
-
callbackURL:
|
|
2917
|
-
password:
|
|
2918
|
-
token:
|
|
2919
|
-
},
|
|
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>;
|
|
2920
2921
|
metadata: {
|
|
2921
2922
|
openapi: {
|
|
2922
2923
|
operationId: string;
|
|
@@ -2974,12 +2975,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
2974
2975
|
success: boolean;
|
|
2975
2976
|
message: string;
|
|
2976
2977
|
}>;
|
|
2977
|
-
readonly requestPasswordReset:
|
|
2978
|
+
readonly requestPasswordReset: better_call116.StrictEndpoint<"/request-password-reset", {
|
|
2978
2979
|
method: "POST";
|
|
2979
|
-
body:
|
|
2980
|
-
email:
|
|
2981
|
-
redirectTo:
|
|
2982
|
-
},
|
|
2980
|
+
body: zod80.ZodObject<{
|
|
2981
|
+
email: zod80.ZodEmail;
|
|
2982
|
+
redirectTo: zod80.ZodOptional<zod80.ZodString>;
|
|
2983
|
+
}, zod_v4_core15.$strip>;
|
|
2983
2984
|
metadata: {
|
|
2984
2985
|
openapi: {
|
|
2985
2986
|
operationId: string;
|
|
@@ -3010,13 +3011,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3010
3011
|
status: boolean;
|
|
3011
3012
|
message: string;
|
|
3012
3013
|
}>;
|
|
3013
|
-
readonly requestPasswordResetCallback:
|
|
3014
|
+
readonly requestPasswordResetCallback: better_call116.StrictEndpoint<"/reset-password/:token", {
|
|
3014
3015
|
method: "GET";
|
|
3015
3016
|
operationId: string;
|
|
3016
|
-
query:
|
|
3017
|
-
callbackURL:
|
|
3018
|
-
},
|
|
3019
|
-
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>)[];
|
|
3020
3021
|
metadata: {
|
|
3021
3022
|
openapi: {
|
|
3022
3023
|
operationId: string;
|
|
@@ -3058,10 +3059,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3058
3059
|
};
|
|
3059
3060
|
};
|
|
3060
3061
|
}, never>;
|
|
3061
|
-
readonly listSessions:
|
|
3062
|
+
readonly listSessions: better_call116.StrictEndpoint<"/list-sessions", {
|
|
3062
3063
|
method: "GET";
|
|
3063
3064
|
operationId: string;
|
|
3064
|
-
use: ((inputContext:
|
|
3065
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3065
3066
|
session: {
|
|
3066
3067
|
session: Record<string, any> & {
|
|
3067
3068
|
id: string;
|
|
@@ -3116,12 +3117,12 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3116
3117
|
ipAddress?: string | null | undefined;
|
|
3117
3118
|
userAgent?: string | null | undefined;
|
|
3118
3119
|
} & (Option extends BetterAuthOptions ? AdditionalSessionFieldsOutput<Option> : Option extends Auth ? AdditionalSessionFieldsOutput<Option["options"]> : {})>>>[]>;
|
|
3119
|
-
readonly revokeSession:
|
|
3120
|
+
readonly revokeSession: better_call116.StrictEndpoint<"/revoke-session", {
|
|
3120
3121
|
method: "POST";
|
|
3121
|
-
body:
|
|
3122
|
-
token:
|
|
3123
|
-
},
|
|
3124
|
-
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<{
|
|
3125
3126
|
session: {
|
|
3126
3127
|
session: Record<string, any> & {
|
|
3127
3128
|
id: string;
|
|
@@ -3188,9 +3189,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3188
3189
|
}, {
|
|
3189
3190
|
status: boolean;
|
|
3190
3191
|
}>;
|
|
3191
|
-
readonly revokeSessions:
|
|
3192
|
+
readonly revokeSessions: better_call116.StrictEndpoint<"/revoke-sessions", {
|
|
3192
3193
|
method: "POST";
|
|
3193
|
-
use: ((inputContext:
|
|
3194
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3194
3195
|
session: {
|
|
3195
3196
|
session: Record<string, any> & {
|
|
3196
3197
|
id: string;
|
|
@@ -3241,10 +3242,10 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3241
3242
|
}, {
|
|
3242
3243
|
status: boolean;
|
|
3243
3244
|
}>;
|
|
3244
|
-
readonly revokeOtherSessions:
|
|
3245
|
+
readonly revokeOtherSessions: better_call116.StrictEndpoint<"/revoke-other-sessions", {
|
|
3245
3246
|
method: "POST";
|
|
3246
3247
|
requireHeaders: true;
|
|
3247
|
-
use: ((inputContext:
|
|
3248
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3248
3249
|
session: {
|
|
3249
3250
|
session: Record<string, any> & {
|
|
3250
3251
|
id: string;
|
|
@@ -3294,26 +3295,26 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3294
3295
|
}, {
|
|
3295
3296
|
status: boolean;
|
|
3296
3297
|
}>;
|
|
3297
|
-
readonly linkSocialAccount:
|
|
3298
|
+
readonly linkSocialAccount: better_call116.StrictEndpoint<"/link-social", {
|
|
3298
3299
|
method: "POST";
|
|
3299
3300
|
requireHeaders: true;
|
|
3300
|
-
body:
|
|
3301
|
-
callbackURL:
|
|
3302
|
-
provider:
|
|
3303
|
-
idToken:
|
|
3304
|
-
token:
|
|
3305
|
-
nonce:
|
|
3306
|
-
accessToken:
|
|
3307
|
-
refreshToken:
|
|
3308
|
-
scopes:
|
|
3309
|
-
},
|
|
3310
|
-
requestSignUp:
|
|
3311
|
-
scopes:
|
|
3312
|
-
errorCallbackURL:
|
|
3313
|
-
disableRedirect:
|
|
3314
|
-
additionalData:
|
|
3315
|
-
},
|
|
3316
|
-
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<{
|
|
3317
3318
|
session: {
|
|
3318
3319
|
session: Record<string, any> & {
|
|
3319
3320
|
id: string;
|
|
@@ -3372,9 +3373,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3372
3373
|
url: string;
|
|
3373
3374
|
redirect: boolean;
|
|
3374
3375
|
}>;
|
|
3375
|
-
readonly listUserAccounts:
|
|
3376
|
+
readonly listUserAccounts: better_call116.StrictEndpoint<"/list-accounts", {
|
|
3376
3377
|
method: "GET";
|
|
3377
|
-
use: ((inputContext:
|
|
3378
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3378
3379
|
session: {
|
|
3379
3380
|
session: Record<string, any> & {
|
|
3380
3381
|
id: string;
|
|
@@ -3456,13 +3457,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3456
3457
|
userId: string;
|
|
3457
3458
|
scopes: string[];
|
|
3458
3459
|
}[]>;
|
|
3459
|
-
readonly deleteUserCallback:
|
|
3460
|
+
readonly deleteUserCallback: better_call116.StrictEndpoint<"/delete-user/callback", {
|
|
3460
3461
|
method: "GET";
|
|
3461
|
-
query:
|
|
3462
|
-
token:
|
|
3463
|
-
callbackURL:
|
|
3464
|
-
},
|
|
3465
|
-
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>)[];
|
|
3466
3467
|
metadata: {
|
|
3467
3468
|
openapi: {
|
|
3468
3469
|
description: string;
|
|
@@ -3496,13 +3497,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3496
3497
|
success: boolean;
|
|
3497
3498
|
message: string;
|
|
3498
3499
|
}>;
|
|
3499
|
-
readonly unlinkAccount:
|
|
3500
|
+
readonly unlinkAccount: better_call116.StrictEndpoint<"/unlink-account", {
|
|
3500
3501
|
method: "POST";
|
|
3501
|
-
body:
|
|
3502
|
-
providerId:
|
|
3503
|
-
accountId:
|
|
3504
|
-
},
|
|
3505
|
-
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<{
|
|
3506
3507
|
session: {
|
|
3507
3508
|
session: Record<string, any> & {
|
|
3508
3509
|
id: string;
|
|
@@ -3550,13 +3551,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3550
3551
|
}, {
|
|
3551
3552
|
status: boolean;
|
|
3552
3553
|
}>;
|
|
3553
|
-
readonly refreshToken:
|
|
3554
|
+
readonly refreshToken: better_call116.StrictEndpoint<"/refresh-token", {
|
|
3554
3555
|
method: "POST";
|
|
3555
|
-
body:
|
|
3556
|
-
providerId:
|
|
3557
|
-
accountId:
|
|
3558
|
-
userId:
|
|
3559
|
-
},
|
|
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>;
|
|
3560
3561
|
metadata: {
|
|
3561
3562
|
openapi: {
|
|
3562
3563
|
description: string;
|
|
@@ -3609,13 +3610,13 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3609
3610
|
providerId: string;
|
|
3610
3611
|
accountId: string;
|
|
3611
3612
|
}>;
|
|
3612
|
-
readonly getAccessToken:
|
|
3613
|
+
readonly getAccessToken: better_call116.StrictEndpoint<"/get-access-token", {
|
|
3613
3614
|
method: "POST";
|
|
3614
|
-
body:
|
|
3615
|
-
providerId:
|
|
3616
|
-
accountId:
|
|
3617
|
-
userId:
|
|
3618
|
-
},
|
|
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>;
|
|
3619
3620
|
metadata: {
|
|
3620
3621
|
openapi: {
|
|
3621
3622
|
description: string;
|
|
@@ -3664,9 +3665,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3664
3665
|
scopes: string[];
|
|
3665
3666
|
idToken: string | undefined;
|
|
3666
3667
|
}>;
|
|
3667
|
-
readonly accountInfo:
|
|
3668
|
+
readonly accountInfo: better_call116.StrictEndpoint<"/account-info", {
|
|
3668
3669
|
method: "GET";
|
|
3669
|
-
use: ((inputContext:
|
|
3670
|
+
use: ((inputContext: better_call116.MiddlewareInputContext<better_call116.MiddlewareOptions>) => Promise<{
|
|
3670
3671
|
session: {
|
|
3671
3672
|
session: Record<string, any> & {
|
|
3672
3673
|
id: string;
|
|
@@ -3736,9 +3737,9 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3736
3737
|
};
|
|
3737
3738
|
};
|
|
3738
3739
|
};
|
|
3739
|
-
query:
|
|
3740
|
-
accountId:
|
|
3741
|
-
},
|
|
3740
|
+
query: zod80.ZodOptional<zod80.ZodObject<{
|
|
3741
|
+
accountId: zod80.ZodOptional<zod80.ZodString>;
|
|
3742
|
+
}, zod_v4_core15.$strip>>;
|
|
3742
3743
|
}, {
|
|
3743
3744
|
user: _better_auth_core_oauth20.OAuth2UserInfo;
|
|
3744
3745
|
data: Record<string, any>;
|
|
@@ -3748,5 +3749,5 @@ declare const router: <Option extends BetterAuthOptions>(ctx: AuthContext, optio
|
|
|
3748
3749
|
} ? E : {} : {} : {}>;
|
|
3749
3750
|
};
|
|
3750
3751
|
//#endregion
|
|
3751
|
-
export { APIError, type AuthEndpoint, type AuthMiddleware, accountInfo, callbackOAuth, changeEmail, changePassword, checkEndpointConflicts, createAuthEndpoint, createAuthMiddleware, createEmailVerificationToken, deleteUser, deleteUserCallback, error, 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 };
|
|
3752
|
+
export { APIError, type AuthEndpoint, type AuthMiddleware, accountInfo, callbackOAuth, changeEmail, changePassword, checkEndpointConflicts, createAuthEndpoint, createAuthMiddleware, createEmailVerificationToken, deleteUser, deleteUserCallback, error, 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 };
|
|
3752
3753
|
//# sourceMappingURL=index.d.mts.map
|