better-auth 1.4.21 → 1.4.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/dist/api/index.d.mts +407 -407
  2. package/dist/api/middlewares/origin-check.d.mts +4 -4
  3. package/dist/api/routes/account.d.mts +11 -11
  4. package/dist/api/routes/callback.d.mts +2 -2
  5. package/dist/api/routes/email-verification.d.mts +4 -4
  6. package/dist/api/routes/error.d.mts +2 -2
  7. package/dist/api/routes/ok.d.mts +2 -2
  8. package/dist/api/routes/password.d.mts +7 -7
  9. package/dist/api/routes/sign-in.d.mts +4 -4
  10. package/dist/api/routes/sign-out.d.mts +2 -2
  11. package/dist/api/routes/sign-up.d.mts +3 -3
  12. package/dist/api/routes/update-user.d.mts +13 -13
  13. package/dist/client/lynx/index.d.mts +15 -15
  14. package/dist/client/react/index.d.mts +15 -15
  15. package/dist/client/solid/index.d.mts +13 -13
  16. package/dist/client/svelte/index.d.mts +13 -13
  17. package/dist/client/vanilla.d.mts +15 -15
  18. package/dist/client/vue/index.d.mts +15 -15
  19. package/dist/db/field.d.mts +6 -6
  20. package/dist/integrations/next-js.d.mts +4 -4
  21. package/dist/integrations/svelte-kit.d.mts +2 -2
  22. package/dist/integrations/tanstack-start-solid.d.mts +4 -4
  23. package/dist/integrations/tanstack-start.d.mts +4 -4
  24. package/dist/plugins/admin/admin.d.mts +114 -114
  25. package/dist/plugins/anonymous/index.d.mts +5 -5
  26. package/dist/plugins/api-key/index.d.mts +79 -79
  27. package/dist/plugins/bearer/index.d.mts +6 -6
  28. package/dist/plugins/captcha/index.d.mts +2 -2
  29. package/dist/plugins/custom-session/index.d.mts +5 -5
  30. package/dist/plugins/device-authorization/index.d.mts +6 -6
  31. package/dist/plugins/email-otp/index.d.mts +52 -52
  32. package/dist/plugins/generic-oauth/index.d.mts +32 -32
  33. package/dist/plugins/haveibeenpwned/index.d.mts +3 -3
  34. package/dist/plugins/jwt/client.d.mts +2 -2
  35. package/dist/plugins/jwt/index.d.mts +7 -7
  36. package/dist/plugins/last-login-method/index.d.mts +4 -4
  37. package/dist/plugins/magic-link/index.d.mts +4 -4
  38. package/dist/plugins/mcp/index.d.mts +10 -10
  39. package/dist/plugins/multi-session/index.d.mts +9 -9
  40. package/dist/plugins/oauth-proxy/index.d.mts +8 -8
  41. package/dist/plugins/oidc-provider/index.d.mts +13 -13
  42. package/dist/plugins/one-tap/client.d.mts +4 -4
  43. package/dist/plugins/one-tap/index.d.mts +2 -2
  44. package/dist/plugins/one-time-token/index.d.mts +5 -5
  45. package/dist/plugins/open-api/index.d.mts +3 -3
  46. package/dist/plugins/organization/adapter.d.mts +24 -24
  47. package/dist/plugins/organization/client.d.mts +8 -8
  48. package/dist/plugins/organization/organization.d.mts +7 -7
  49. package/dist/plugins/organization/routes/crud-access-control.d.mts +22 -22
  50. package/dist/plugins/organization/routes/crud-invites.d.mts +69 -69
  51. package/dist/plugins/organization/routes/crud-members.d.mts +67 -67
  52. package/dist/plugins/organization/routes/crud-org.d.mts +59 -59
  53. package/dist/plugins/organization/routes/crud-team.d.mts +79 -79
  54. package/dist/plugins/phone-number/index.d.mts +33 -33
  55. package/dist/plugins/siwe/index.d.mts +3 -3
  56. package/dist/plugins/two-factor/backup-codes/index.d.mts +5 -5
  57. package/dist/plugins/two-factor/index.d.mts +16 -16
  58. package/dist/plugins/two-factor/otp/index.d.mts +3 -3
  59. package/dist/plugins/two-factor/totp/index.d.mts +5 -5
  60. package/dist/plugins/username/index.d.mts +9 -9
  61. package/dist/plugins/username/schema.d.mts +3 -3
  62. package/dist/test-utils/test-instance.d.mts +1225 -1225
  63. package/package.json +3 -3
@@ -10,11 +10,11 @@ import { PatreonOptions, patreon } from "./providers/patreon.mjs";
10
10
  import { SlackOptions, slack } from "./providers/slack.mjs";
11
11
  import "./providers/index.mjs";
12
12
  import { AuthContext } from "@better-auth/core";
13
- import * as _better_auth_core_oauth21 from "@better-auth/core/oauth2";
13
+ import * as _better_auth_core_oauth20 from "@better-auth/core/oauth2";
14
14
  import { OAuthProvider } from "@better-auth/core/oauth2";
15
- import * as better_call167 from "better-call";
16
- import * as zod468 from "zod";
17
- import * as zod_v4_core70 from "zod/v4/core";
15
+ import * as better_call37 from "better-call";
16
+ import * as zod26 from "zod";
17
+ import * as zod_v4_core8 from "zod/v4/core";
18
18
 
19
19
  //#region src/plugins/generic-oauth/index.d.ts
20
20
  /**
@@ -32,22 +32,22 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
32
32
  id: "generic-oauth";
33
33
  init: (ctx: AuthContext) => {
34
34
  context: {
35
- socialProviders: OAuthProvider<Record<string, any>, Partial<_better_auth_core_oauth21.ProviderOptions<any>>>[];
35
+ socialProviders: OAuthProvider<Record<string, any>, Partial<_better_auth_core_oauth20.ProviderOptions<any>>>[];
36
36
  };
37
37
  };
38
38
  endpoints: {
39
- signInWithOAuth2: better_call167.StrictEndpoint<"/sign-in/oauth2", {
39
+ signInWithOAuth2: better_call37.StrictEndpoint<"/sign-in/oauth2", {
40
40
  method: "POST";
41
- body: zod468.ZodObject<{
42
- providerId: zod468.ZodString;
43
- callbackURL: zod468.ZodOptional<zod468.ZodString>;
44
- errorCallbackURL: zod468.ZodOptional<zod468.ZodString>;
45
- newUserCallbackURL: zod468.ZodOptional<zod468.ZodString>;
46
- disableRedirect: zod468.ZodOptional<zod468.ZodBoolean>;
47
- scopes: zod468.ZodOptional<zod468.ZodArray<zod468.ZodString>>;
48
- requestSignUp: zod468.ZodOptional<zod468.ZodBoolean>;
49
- additionalData: zod468.ZodOptional<zod468.ZodRecord<zod468.ZodString, zod468.ZodAny>>;
50
- }, zod_v4_core70.$strip>;
41
+ body: zod26.ZodObject<{
42
+ providerId: zod26.ZodString;
43
+ callbackURL: zod26.ZodOptional<zod26.ZodString>;
44
+ errorCallbackURL: zod26.ZodOptional<zod26.ZodString>;
45
+ newUserCallbackURL: zod26.ZodOptional<zod26.ZodString>;
46
+ disableRedirect: zod26.ZodOptional<zod26.ZodBoolean>;
47
+ scopes: zod26.ZodOptional<zod26.ZodArray<zod26.ZodString>>;
48
+ requestSignUp: zod26.ZodOptional<zod26.ZodBoolean>;
49
+ additionalData: zod26.ZodOptional<zod26.ZodRecord<zod26.ZodString, zod26.ZodAny>>;
50
+ }, zod_v4_core8.$strip>;
51
51
  metadata: {
52
52
  openapi: {
53
53
  description: string;
@@ -77,15 +77,15 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
77
77
  url: string;
78
78
  redirect: boolean;
79
79
  }>;
80
- oAuth2Callback: better_call167.StrictEndpoint<"/oauth2/callback/:providerId", {
80
+ oAuth2Callback: better_call37.StrictEndpoint<"/oauth2/callback/:providerId", {
81
81
  method: "GET";
82
- query: zod468.ZodObject<{
83
- code: zod468.ZodOptional<zod468.ZodString>;
84
- error: zod468.ZodOptional<zod468.ZodString>;
85
- error_description: zod468.ZodOptional<zod468.ZodString>;
86
- state: zod468.ZodOptional<zod468.ZodString>;
87
- iss: zod468.ZodOptional<zod468.ZodString>;
88
- }, zod_v4_core70.$strip>;
82
+ query: zod26.ZodObject<{
83
+ code: zod26.ZodOptional<zod26.ZodString>;
84
+ error: zod26.ZodOptional<zod26.ZodString>;
85
+ error_description: zod26.ZodOptional<zod26.ZodString>;
86
+ state: zod26.ZodOptional<zod26.ZodString>;
87
+ iss: zod26.ZodOptional<zod26.ZodString>;
88
+ }, zod_v4_core8.$strip>;
89
89
  metadata: {
90
90
  allowedMediaTypes: string[];
91
91
  openapi: {
@@ -111,15 +111,15 @@ declare const genericOAuth: (options: GenericOAuthOptions) => {
111
111
  scope: "server";
112
112
  };
113
113
  }, void>;
114
- oAuth2LinkAccount: better_call167.StrictEndpoint<"/oauth2/link", {
114
+ oAuth2LinkAccount: better_call37.StrictEndpoint<"/oauth2/link", {
115
115
  method: "POST";
116
- body: zod468.ZodObject<{
117
- providerId: zod468.ZodString;
118
- callbackURL: zod468.ZodString;
119
- scopes: zod468.ZodOptional<zod468.ZodArray<zod468.ZodString>>;
120
- errorCallbackURL: zod468.ZodOptional<zod468.ZodString>;
121
- }, zod_v4_core70.$strip>;
122
- use: ((inputContext: better_call167.MiddlewareInputContext<better_call167.MiddlewareOptions>) => Promise<{
116
+ body: zod26.ZodObject<{
117
+ providerId: zod26.ZodString;
118
+ callbackURL: zod26.ZodString;
119
+ scopes: zod26.ZodOptional<zod26.ZodArray<zod26.ZodString>>;
120
+ errorCallbackURL: zod26.ZodOptional<zod26.ZodString>;
121
+ }, zod_v4_core8.$strip>;
122
+ use: ((inputContext: better_call37.MiddlewareInputContext<better_call37.MiddlewareOptions>) => Promise<{
123
123
  session: {
124
124
  session: Record<string, any> & {
125
125
  id: string;
@@ -1,4 +1,4 @@
1
- import * as _better_auth_core17 from "@better-auth/core";
1
+ import * as _better_auth_core16 from "@better-auth/core";
2
2
 
3
3
  //#region src/plugins/haveibeenpwned/index.d.ts
4
4
  interface HaveIBeenPwnedOptions {
@@ -12,7 +12,7 @@ interface HaveIBeenPwnedOptions {
12
12
  }
13
13
  declare const haveIBeenPwned: (options?: HaveIBeenPwnedOptions | undefined) => {
14
14
  id: "haveIBeenPwned";
15
- init(ctx: _better_auth_core17.AuthContext): {
15
+ init(ctx: _better_auth_core16.AuthContext): {
16
16
  context: {
17
17
  password: {
18
18
  hash(password: string): Promise<string>;
@@ -24,7 +24,7 @@ declare const haveIBeenPwned: (options?: HaveIBeenPwnedOptions | undefined) => {
24
24
  minPasswordLength: number;
25
25
  maxPasswordLength: number;
26
26
  };
27
- checkPassword: (userId: string, ctx: _better_auth_core17.GenericEndpointContext<_better_auth_core17.BetterAuthOptions>) => Promise<boolean>;
27
+ checkPassword: (userId: string, ctx: _better_auth_core16.GenericEndpointContext<_better_auth_core16.BetterAuthOptions>) => Promise<boolean>;
28
28
  };
29
29
  };
30
30
  };
@@ -1,7 +1,7 @@
1
1
  import { JWKOptions, JWSAlgorithms, Jwk, JwtOptions } from "./types.mjs";
2
2
  import { jwt } from "./index.mjs";
3
3
  import { JSONWebKeySet } from "jose";
4
- import * as _better_fetch_fetch95 from "@better-fetch/fetch";
4
+ import * as _better_fetch_fetch111 from "@better-fetch/fetch";
5
5
 
6
6
  //#region src/plugins/jwt/client.d.ts
7
7
  interface JwtClientOptions {
@@ -21,7 +21,7 @@ declare const jwtClient: (options?: JwtClientOptions) => {
21
21
  pathMethods: {
22
22
  [x: string]: "GET";
23
23
  };
24
- getActions: ($fetch: _better_fetch_fetch95.BetterFetch) => {
24
+ getActions: ($fetch: _better_fetch_fetch111.BetterFetch) => {
25
25
  jwks: (fetchOptions?: any) => Promise<{
26
26
  data: null;
27
27
  error: {
@@ -3,7 +3,7 @@ import { getJwtToken, signJWT } from "./sign.mjs";
3
3
  import { createJwk, generateExportedKeyPair, toExpJWT } from "./utils.mjs";
4
4
  import { verifyJWT } from "./verify.mjs";
5
5
  import * as _better_auth_core8 from "@better-auth/core";
6
- import * as better_call176 from "better-call";
6
+ import * as better_call42 from "better-call";
7
7
  import * as z from "zod";
8
8
  import { JSONWebKeySet, JWTPayload } from "jose";
9
9
 
@@ -12,7 +12,7 @@ declare const jwt: <O extends JwtOptions>(options?: O) => {
12
12
  id: "jwt";
13
13
  options: NoInfer<O>;
14
14
  endpoints: {
15
- getJwks: better_call176.StrictEndpoint<string, {
15
+ getJwks: better_call42.StrictEndpoint<string, {
16
16
  method: "GET";
17
17
  metadata: {
18
18
  openapi: {
@@ -89,10 +89,10 @@ declare const jwt: <O extends JwtOptions>(options?: O) => {
89
89
  };
90
90
  };
91
91
  }, JSONWebKeySet>;
92
- getToken: better_call176.StrictEndpoint<"/token", {
92
+ getToken: better_call42.StrictEndpoint<"/token", {
93
93
  method: "GET";
94
94
  requireHeaders: true;
95
- use: ((inputContext: better_call176.MiddlewareInputContext<better_call176.MiddlewareOptions>) => Promise<{
95
+ use: ((inputContext: better_call42.MiddlewareInputContext<better_call42.MiddlewareOptions>) => Promise<{
96
96
  session: {
97
97
  session: Record<string, any> & {
98
98
  id: string;
@@ -141,7 +141,7 @@ declare const jwt: <O extends JwtOptions>(options?: O) => {
141
141
  }, {
142
142
  token: string;
143
143
  }>;
144
- signJWT: better_call176.StrictEndpoint<string, {
144
+ signJWT: better_call42.StrictEndpoint<string, {
145
145
  method: "POST";
146
146
  metadata: {
147
147
  $Infer: {
@@ -158,7 +158,7 @@ declare const jwt: <O extends JwtOptions>(options?: O) => {
158
158
  }, {
159
159
  token: string;
160
160
  }>;
161
- verifyJWT: better_call176.StrictEndpoint<string, {
161
+ verifyJWT: better_call42.StrictEndpoint<string, {
162
162
  method: "POST";
163
163
  metadata: {
164
164
  $Infer: {
@@ -186,7 +186,7 @@ declare const jwt: <O extends JwtOptions>(options?: O) => {
186
186
  hooks: {
187
187
  after: {
188
188
  matcher(context: _better_auth_core8.HookEndpointContext): boolean;
189
- handler: (inputContext: better_call176.MiddlewareInputContext<better_call176.MiddlewareOptions>) => Promise<void>;
189
+ handler: (inputContext: better_call42.MiddlewareInputContext<better_call42.MiddlewareOptions>) => Promise<void>;
190
190
  }[];
191
191
  };
192
192
  schema: {
@@ -1,6 +1,6 @@
1
- import * as _better_auth_core41 from "@better-auth/core";
1
+ import * as _better_auth_core37 from "@better-auth/core";
2
2
  import { GenericEndpointContext } from "@better-auth/core";
3
- import * as better_call729 from "better-call";
3
+ import * as better_call688 from "better-call";
4
4
 
5
5
  //#region src/plugins/last-login-method/index.d.ts
6
6
  /**
@@ -43,7 +43,7 @@ interface LastLoginMethodOptions {
43
43
  */
44
44
  declare const lastLoginMethod: <O extends LastLoginMethodOptions>(userConfig?: O | undefined) => {
45
45
  id: "last-login-method";
46
- init(ctx: _better_auth_core41.AuthContext): {
46
+ init(ctx: _better_auth_core37.AuthContext): {
47
47
  options: {
48
48
  databaseHooks: {
49
49
  user: {
@@ -90,7 +90,7 @@ declare const lastLoginMethod: <O extends LastLoginMethodOptions>(userConfig?: O
90
90
  hooks: {
91
91
  after: {
92
92
  matcher(): true;
93
- handler: (inputContext: better_call729.MiddlewareInputContext<better_call729.MiddlewareOptions>) => Promise<void>;
93
+ handler: (inputContext: better_call688.MiddlewareInputContext<better_call688.MiddlewareOptions>) => Promise<void>;
94
94
  }[];
95
95
  };
96
96
  schema: O["storeInDatabase"] extends true ? {
@@ -1,5 +1,5 @@
1
1
  import { Awaitable, GenericEndpointContext } from "@better-auth/core";
2
- import * as better_call184 from "better-call";
2
+ import * as better_call75 from "better-call";
3
3
  import * as z from "zod";
4
4
 
5
5
  //#region src/plugins/magic-link/index.d.ts
@@ -68,7 +68,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
68
68
  *
69
69
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/sign-in#api-method-sign-in-magic-link)
70
70
  */
71
- signInMagicLink: better_call184.StrictEndpoint<"/sign-in/magic-link", {
71
+ signInMagicLink: better_call75.StrictEndpoint<"/sign-in/magic-link", {
72
72
  method: "POST";
73
73
  requireHeaders: true;
74
74
  body: z.ZodObject<{
@@ -119,7 +119,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
119
119
  *
120
120
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/magic-link#api-method-magic-link-verify)
121
121
  */
122
- magicLinkVerify: better_call184.StrictEndpoint<"/magic-link/verify", {
122
+ magicLinkVerify: better_call75.StrictEndpoint<"/magic-link/verify", {
123
123
  method: "GET";
124
124
  query: z.ZodObject<{
125
125
  token: z.ZodString;
@@ -127,7 +127,7 @@ declare const magicLink: (options: MagicLinkOptions) => {
127
127
  errorCallbackURL: z.ZodOptional<z.ZodString>;
128
128
  newUserCallbackURL: z.ZodOptional<z.ZodString>;
129
129
  }, z.core.$strip>;
130
- use: ((inputContext: better_call184.MiddlewareInputContext<better_call184.MiddlewareOptions>) => Promise<void>)[];
130
+ use: ((inputContext: better_call75.MiddlewareInputContext<better_call75.MiddlewareOptions>) => Promise<void>)[];
131
131
  requireHeaders: true;
132
132
  metadata: {
133
133
  openapi: {
@@ -1,7 +1,7 @@
1
1
  import { OAuthAccessToken, OIDCMetadata, OIDCOptions } from "../oidc-provider/types.mjs";
2
2
  import "../oidc-provider/index.mjs";
3
3
  import { BetterAuthOptions, GenericEndpointContext } from "@better-auth/core";
4
- import * as better_call731 from "better-call";
4
+ import * as better_call690 from "better-call";
5
5
  import * as z from "zod";
6
6
 
7
7
  //#region src/plugins/mcp/index.d.ts
@@ -24,18 +24,18 @@ declare const mcp: (options: MCPOptions) => {
24
24
  hooks: {
25
25
  after: {
26
26
  matcher(): true;
27
- handler: (inputContext: better_call731.MiddlewareInputContext<better_call731.MiddlewareOptions>) => Promise<void>;
27
+ handler: (inputContext: better_call690.MiddlewareInputContext<better_call690.MiddlewareOptions>) => Promise<void>;
28
28
  }[];
29
29
  };
30
30
  endpoints: {
31
- oAuthConsent: better_call731.StrictEndpoint<"/oauth2/consent", {
31
+ oAuthConsent: better_call690.StrictEndpoint<"/oauth2/consent", {
32
32
  method: "POST";
33
33
  operationId: string;
34
34
  body: z.ZodObject<{
35
35
  accept: z.ZodBoolean;
36
36
  consent_code: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
37
37
  }, z.core.$strip>;
38
- use: ((inputContext: better_call731.MiddlewareInputContext<better_call731.MiddlewareOptions>) => Promise<{
38
+ use: ((inputContext: better_call690.MiddlewareInputContext<better_call690.MiddlewareOptions>) => Promise<{
39
39
  session: {
40
40
  session: Record<string, any> & {
41
41
  id: string;
@@ -107,13 +107,13 @@ declare const mcp: (options: MCPOptions) => {
107
107
  }, {
108
108
  redirectURI: string;
109
109
  }>;
110
- getMcpOAuthConfig: better_call731.StrictEndpoint<"/.well-known/oauth-authorization-server", {
110
+ getMcpOAuthConfig: better_call690.StrictEndpoint<"/.well-known/oauth-authorization-server", {
111
111
  method: "GET";
112
112
  metadata: {
113
113
  readonly scope: "server";
114
114
  };
115
115
  }, OIDCMetadata | null>;
116
- getMCPProtectedResource: better_call731.StrictEndpoint<"/.well-known/oauth-protected-resource", {
116
+ getMCPProtectedResource: better_call690.StrictEndpoint<"/.well-known/oauth-protected-resource", {
117
117
  method: "GET";
118
118
  metadata: {
119
119
  readonly scope: "server";
@@ -126,7 +126,7 @@ declare const mcp: (options: MCPOptions) => {
126
126
  bearer_methods_supported: string[];
127
127
  resource_signing_alg_values_supported: string[];
128
128
  }>;
129
- mcpOAuthAuthorize: better_call731.StrictEndpoint<"/mcp/authorize", {
129
+ mcpOAuthAuthorize: better_call690.StrictEndpoint<"/mcp/authorize", {
130
130
  method: "GET";
131
131
  query: z.ZodRecord<z.ZodString, z.ZodAny>;
132
132
  metadata: {
@@ -149,7 +149,7 @@ declare const mcp: (options: MCPOptions) => {
149
149
  };
150
150
  };
151
151
  }, void>;
152
- mcpOAuthToken: better_call731.StrictEndpoint<"/mcp/token", {
152
+ mcpOAuthToken: better_call690.StrictEndpoint<"/mcp/token", {
153
153
  method: "POST";
154
154
  body: z.ZodRecord<z.ZodAny, z.ZodAny>;
155
155
  metadata: {
@@ -170,7 +170,7 @@ declare const mcp: (options: MCPOptions) => {
170
170
  scope: string;
171
171
  id_token: string | undefined;
172
172
  }>;
173
- registerMcpClient: better_call731.StrictEndpoint<"/mcp/register", {
173
+ registerMcpClient: better_call690.StrictEndpoint<"/mcp/register", {
174
174
  method: "POST";
175
175
  body: z.ZodObject<{
176
176
  redirect_uris: z.ZodArray<z.ZodString>;
@@ -288,7 +288,7 @@ declare const mcp: (options: MCPOptions) => {
288
288
  };
289
289
  };
290
290
  }, Response>;
291
- getMcpSession: better_call731.StrictEndpoint<"/mcp/get-session", {
291
+ getMcpSession: better_call690.StrictEndpoint<"/mcp/get-session", {
292
292
  method: "GET";
293
293
  requireHeaders: true;
294
294
  }, OAuthAccessToken | null>;
@@ -1,5 +1,5 @@
1
- import * as _better_auth_core10 from "@better-auth/core";
2
- import * as better_call191 from "better-call";
1
+ import * as _better_auth_core9 from "@better-auth/core";
2
+ import * as better_call66 from "better-call";
3
3
  import * as z from "zod";
4
4
 
5
5
  //#region src/plugins/multi-session/index.d.ts
@@ -29,7 +29,7 @@ declare const multiSession: (options?: MultiSessionConfig | undefined) => {
29
29
  *
30
30
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/multi-session#api-method-multi-session-list-device-sessions)
31
31
  */
32
- listDeviceSessions: better_call191.StrictEndpoint<"/multi-session/list-device-sessions", {
32
+ listDeviceSessions: better_call66.StrictEndpoint<"/multi-session/list-device-sessions", {
33
33
  method: "GET";
34
34
  requireHeaders: true;
35
35
  }, {
@@ -68,13 +68,13 @@ declare const multiSession: (options?: MultiSessionConfig | undefined) => {
68
68
  *
69
69
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/multi-session#api-method-multi-session-set-active)
70
70
  */
71
- setActiveSession: better_call191.StrictEndpoint<"/multi-session/set-active", {
71
+ setActiveSession: better_call66.StrictEndpoint<"/multi-session/set-active", {
72
72
  method: "POST";
73
73
  body: z.ZodObject<{
74
74
  sessionToken: z.ZodString;
75
75
  }, z.core.$strip>;
76
76
  requireHeaders: true;
77
- use: ((inputContext: better_call191.MiddlewareInputContext<better_call191.MiddlewareOptions>) => Promise<{
77
+ use: ((inputContext: better_call66.MiddlewareInputContext<better_call66.MiddlewareOptions>) => Promise<{
78
78
  session: {
79
79
  session: Record<string, any> & {
80
80
  id: string;
@@ -155,13 +155,13 @@ declare const multiSession: (options?: MultiSessionConfig | undefined) => {
155
155
  *
156
156
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/multi-session#api-method-multi-session-revoke)
157
157
  */
158
- revokeDeviceSession: better_call191.StrictEndpoint<"/multi-session/revoke", {
158
+ revokeDeviceSession: better_call66.StrictEndpoint<"/multi-session/revoke", {
159
159
  method: "POST";
160
160
  body: z.ZodObject<{
161
161
  sessionToken: z.ZodString;
162
162
  }, z.core.$strip>;
163
163
  requireHeaders: true;
164
- use: ((inputContext: better_call191.MiddlewareInputContext<better_call191.MiddlewareOptions>) => Promise<{
164
+ use: ((inputContext: better_call66.MiddlewareInputContext<better_call66.MiddlewareOptions>) => Promise<{
165
165
  session: {
166
166
  session: Record<string, any> & {
167
167
  id: string;
@@ -212,8 +212,8 @@ declare const multiSession: (options?: MultiSessionConfig | undefined) => {
212
212
  };
213
213
  hooks: {
214
214
  after: {
215
- matcher: (context: _better_auth_core10.HookEndpointContext) => boolean;
216
- handler: (inputContext: better_call191.MiddlewareInputContext<better_call191.MiddlewareOptions>) => Promise<void>;
215
+ matcher: (context: _better_auth_core9.HookEndpointContext) => boolean;
216
+ handler: (inputContext: better_call66.MiddlewareInputContext<better_call66.MiddlewareOptions>) => Promise<void>;
217
217
  }[];
218
218
  };
219
219
  options: MultiSessionConfig | undefined;
@@ -1,5 +1,5 @@
1
- import * as _better_auth_core20 from "@better-auth/core";
2
- import * as better_call247 from "better-call";
1
+ import * as _better_auth_core2 from "@better-auth/core";
2
+ import * as better_call15 from "better-call";
3
3
  import * as z from "zod";
4
4
 
5
5
  //#region src/plugins/oauth-proxy/index.d.ts
@@ -34,14 +34,14 @@ declare const oAuthProxy: <O extends OAuthProxyOptions>(opts?: O) => {
34
34
  id: "oauth-proxy";
35
35
  options: NoInfer<O>;
36
36
  endpoints: {
37
- oAuthProxy: better_call247.StrictEndpoint<"/oauth-proxy-callback", {
37
+ oAuthProxy: better_call15.StrictEndpoint<"/oauth-proxy-callback", {
38
38
  method: "GET";
39
39
  operationId: string;
40
40
  query: z.ZodObject<{
41
41
  callbackURL: z.ZodString;
42
42
  cookies: z.ZodString;
43
43
  }, z.core.$strip>;
44
- use: ((inputContext: better_call247.MiddlewareInputContext<better_call247.MiddlewareOptions>) => Promise<void>)[];
44
+ use: ((inputContext: better_call15.MiddlewareInputContext<better_call15.MiddlewareOptions>) => Promise<void>)[];
45
45
  metadata: {
46
46
  openapi: {
47
47
  operationId: string;
@@ -71,12 +71,12 @@ declare const oAuthProxy: <O extends OAuthProxyOptions>(opts?: O) => {
71
71
  };
72
72
  hooks: {
73
73
  before: {
74
- matcher(context: _better_auth_core20.HookEndpointContext): boolean;
75
- handler: (inputContext: better_call247.MiddlewareInputContext<better_call247.MiddlewareOptions>) => Promise<void>;
74
+ matcher(context: _better_auth_core2.HookEndpointContext): boolean;
75
+ handler: (inputContext: better_call15.MiddlewareInputContext<better_call15.MiddlewareOptions>) => Promise<void>;
76
76
  }[];
77
77
  after: {
78
- matcher(context: _better_auth_core20.HookEndpointContext): boolean;
79
- handler: (inputContext: better_call247.MiddlewareInputContext<better_call247.MiddlewareOptions>) => Promise<void>;
78
+ matcher(context: _better_auth_core2.HookEndpointContext): boolean;
79
+ handler: (inputContext: better_call15.MiddlewareInputContext<better_call15.MiddlewareOptions>) => Promise<void>;
80
80
  }[];
81
81
  };
82
82
  };
@@ -4,7 +4,7 @@ import { AuthorizationQuery, Client, CodeVerificationValue, OAuthAccessToken, OI
4
4
  import "../index.mjs";
5
5
  import { GenericEndpointContext } from "@better-auth/core";
6
6
  import * as _better_auth_core_db0 from "@better-auth/core/db";
7
- import * as better_call221 from "better-call";
7
+ import * as better_call51 from "better-call";
8
8
  import { OpenAPIParameter } from "better-call";
9
9
  import * as z from "zod";
10
10
 
@@ -31,21 +31,21 @@ declare const oidcProvider: (options: OIDCOptions) => {
31
31
  hooks: {
32
32
  after: {
33
33
  matcher(): true;
34
- handler: (inputContext: better_call221.MiddlewareInputContext<better_call221.MiddlewareOptions>) => Promise<Response | {
34
+ handler: (inputContext: better_call51.MiddlewareInputContext<better_call51.MiddlewareOptions>) => Promise<Response | {
35
35
  redirect: boolean;
36
36
  url: string;
37
37
  } | undefined>;
38
38
  }[];
39
39
  };
40
40
  endpoints: {
41
- getOpenIdConfig: better_call221.StrictEndpoint<"/.well-known/openid-configuration", {
41
+ getOpenIdConfig: better_call51.StrictEndpoint<"/.well-known/openid-configuration", {
42
42
  method: "GET";
43
43
  operationId: string;
44
44
  metadata: {
45
45
  readonly scope: "server";
46
46
  };
47
47
  }, OIDCMetadata>;
48
- oAuth2authorize: better_call221.StrictEndpoint<"/oauth2/authorize", {
48
+ oAuth2authorize: better_call51.StrictEndpoint<"/oauth2/authorize", {
49
49
  method: "GET";
50
50
  operationId: string;
51
51
  query: z.ZodRecord<z.ZodString, z.ZodAny>;
@@ -72,14 +72,14 @@ declare const oidcProvider: (options: OIDCOptions) => {
72
72
  redirect: boolean;
73
73
  url: string;
74
74
  }>;
75
- oAuthConsent: better_call221.StrictEndpoint<"/oauth2/consent", {
75
+ oAuthConsent: better_call51.StrictEndpoint<"/oauth2/consent", {
76
76
  method: "POST";
77
77
  operationId: string;
78
78
  body: z.ZodObject<{
79
79
  accept: z.ZodBoolean;
80
80
  consent_code: z.ZodOptional<z.ZodNullable<z.ZodOptional<z.ZodString>>>;
81
81
  }, z.core.$strip>;
82
- use: ((inputContext: better_call221.MiddlewareInputContext<better_call221.MiddlewareOptions>) => Promise<{
82
+ use: ((inputContext: better_call51.MiddlewareInputContext<better_call51.MiddlewareOptions>) => Promise<{
83
83
  session: {
84
84
  session: Record<string, any> & {
85
85
  id: string;
@@ -151,7 +151,7 @@ declare const oidcProvider: (options: OIDCOptions) => {
151
151
  }, {
152
152
  redirectURI: string;
153
153
  }>;
154
- oAuth2token: better_call221.StrictEndpoint<"/oauth2/token", {
154
+ oAuth2token: better_call51.StrictEndpoint<"/oauth2/token", {
155
155
  method: "POST";
156
156
  operationId: string;
157
157
  body: z.ZodRecord<z.ZodAny, z.ZodAny>;
@@ -173,7 +173,7 @@ declare const oidcProvider: (options: OIDCOptions) => {
173
173
  scope: string;
174
174
  id_token: string | undefined;
175
175
  }>;
176
- oAuth2userInfo: better_call221.StrictEndpoint<"/oauth2/userinfo", {
176
+ oAuth2userInfo: better_call51.StrictEndpoint<"/oauth2/userinfo", {
177
177
  method: "GET";
178
178
  operationId: string;
179
179
  metadata: {
@@ -265,7 +265,7 @@ declare const oidcProvider: (options: OIDCOptions) => {
265
265
  *
266
266
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/oidc-provider#api-method-oauth2-register)
267
267
  */
268
- registerOAuthApplication: better_call221.StrictEndpoint<"/oauth2/register", {
268
+ registerOAuthApplication: better_call51.StrictEndpoint<"/oauth2/register", {
269
269
  method: "POST";
270
270
  body: z.ZodObject<{
271
271
  redirect_uris: z.ZodArray<z.ZodString>;
@@ -405,9 +405,9 @@ declare const oidcProvider: (options: OIDCOptions) => {
405
405
  client_secret?: string | undefined;
406
406
  client_id: string;
407
407
  }>;
408
- getOAuthClient: better_call221.StrictEndpoint<"/oauth2/client/:id", {
408
+ getOAuthClient: better_call51.StrictEndpoint<"/oauth2/client/:id", {
409
409
  method: "GET";
410
- use: ((inputContext: better_call221.MiddlewareInputContext<better_call221.MiddlewareOptions>) => Promise<{
410
+ use: ((inputContext: better_call51.MiddlewareInputContext<better_call51.MiddlewareOptions>) => Promise<{
411
411
  session: {
412
412
  session: Record<string, any> & {
413
413
  id: string;
@@ -478,7 +478,7 @@ declare const oidcProvider: (options: OIDCOptions) => {
478
478
  *
479
479
  * @see [OpenID Connect RP-Initiated Logout Spec](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
480
480
  */
481
- endSession: better_call221.StrictEndpoint<"/oauth2/endsession", {
481
+ endSession: better_call51.StrictEndpoint<"/oauth2/endsession", {
482
482
  method: ("GET" | "POST")[];
483
483
  query: z.ZodOptional<z.ZodObject<{
484
484
  id_token_hint: z.ZodOptional<z.ZodString>;
@@ -504,7 +504,7 @@ declare const oidcProvider: (options: OIDCOptions) => {
504
504
  scope: "server";
505
505
  };
506
506
  }, {
507
- status: ("OK" | "CREATED" | "ACCEPTED" | "NO_CONTENT" | "MULTIPLE_CHOICES" | "MOVED_PERMANENTLY" | "FOUND" | "SEE_OTHER" | "NOT_MODIFIED" | "TEMPORARY_REDIRECT" | "BAD_REQUEST" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_ALLOWED" | "NOT_ACCEPTABLE" | "PROXY_AUTHENTICATION_REQUIRED" | "REQUEST_TIMEOUT" | "CONFLICT" | "GONE" | "LENGTH_REQUIRED" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "URI_TOO_LONG" | "UNSUPPORTED_MEDIA_TYPE" | "RANGE_NOT_SATISFIABLE" | "EXPECTATION_FAILED" | "I'M_A_TEAPOT" | "MISDIRECTED_REQUEST" | "UNPROCESSABLE_ENTITY" | "LOCKED" | "FAILED_DEPENDENCY" | "TOO_EARLY" | "UPGRADE_REQUIRED" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "REQUEST_HEADER_FIELDS_TOO_LARGE" | "UNAVAILABLE_FOR_LEGAL_REASONS" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "HTTP_VERSION_NOT_SUPPORTED" | "VARIANT_ALSO_NEGOTIATES" | "INSUFFICIENT_STORAGE" | "LOOP_DETECTED" | "NOT_EXTENDED" | "NETWORK_AUTHENTICATION_REQUIRED") | better_call221.Status;
507
+ status: ("OK" | "CREATED" | "ACCEPTED" | "NO_CONTENT" | "MULTIPLE_CHOICES" | "MOVED_PERMANENTLY" | "FOUND" | "SEE_OTHER" | "NOT_MODIFIED" | "TEMPORARY_REDIRECT" | "BAD_REQUEST" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_ALLOWED" | "NOT_ACCEPTABLE" | "PROXY_AUTHENTICATION_REQUIRED" | "REQUEST_TIMEOUT" | "CONFLICT" | "GONE" | "LENGTH_REQUIRED" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "URI_TOO_LONG" | "UNSUPPORTED_MEDIA_TYPE" | "RANGE_NOT_SATISFIABLE" | "EXPECTATION_FAILED" | "I'M_A_TEAPOT" | "MISDIRECTED_REQUEST" | "UNPROCESSABLE_ENTITY" | "LOCKED" | "FAILED_DEPENDENCY" | "TOO_EARLY" | "UPGRADE_REQUIRED" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "REQUEST_HEADER_FIELDS_TOO_LARGE" | "UNAVAILABLE_FOR_LEGAL_REASONS" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "HTTP_VERSION_NOT_SUPPORTED" | "VARIANT_ALSO_NEGOTIATES" | "INSUFFICIENT_STORAGE" | "LOOP_DETECTED" | "NOT_EXTENDED" | "NETWORK_AUTHENTICATION_REQUIRED") | better_call51.Status;
508
508
  body: ({
509
509
  message?: string;
510
510
  code?: string;
@@ -1,6 +1,6 @@
1
1
  import * as _better_auth_core42 from "@better-auth/core";
2
2
  import { ClientFetchOption } from "@better-auth/core";
3
- import * as _better_fetch_fetch96 from "@better-fetch/fetch";
3
+ import * as _better_fetch_fetch112 from "@better-fetch/fetch";
4
4
 
5
5
  //#region src/plugins/one-tap/client.d.ts
6
6
  declare global {
@@ -161,13 +161,13 @@ declare const oneTapClient: (options: GoogleOneTapOptions) => {
161
161
  id: string;
162
162
  name: string;
163
163
  hooks: {
164
- onResponse(ctx: _better_fetch_fetch96.ResponseContext): Promise<void>;
164
+ onResponse(ctx: _better_fetch_fetch112.ResponseContext): Promise<void>;
165
165
  };
166
166
  }[];
167
- getActions: ($fetch: _better_fetch_fetch96.BetterFetch, _: _better_auth_core42.ClientStore) => {
167
+ getActions: ($fetch: _better_fetch_fetch112.BetterFetch, _: _better_auth_core42.ClientStore) => {
168
168
  oneTap: (opts?: GoogleOneTapActionOptions | undefined, fetchOptions?: ClientFetchOption | undefined) => Promise<void>;
169
169
  };
170
- getAtoms($fetch: _better_fetch_fetch96.BetterFetch): {};
170
+ getAtoms($fetch: _better_fetch_fetch112.BetterFetch): {};
171
171
  };
172
172
  //#endregion
173
173
  export { GoogleOneTapActionOptions, GoogleOneTapOptions, GsiButtonConfiguration, oneTapClient };
@@ -1,4 +1,4 @@
1
- import * as better_call200 from "better-call";
1
+ import * as better_call50 from "better-call";
2
2
  import * as z from "zod";
3
3
 
4
4
  //#region src/plugins/one-tap/index.d.ts
@@ -20,7 +20,7 @@ interface OneTapOptions {
20
20
  declare const oneTap: (options?: OneTapOptions | undefined) => {
21
21
  id: "one-tap";
22
22
  endpoints: {
23
- oneTapCallback: better_call200.StrictEndpoint<"/one-tap/callback", {
23
+ oneTapCallback: better_call50.StrictEndpoint<"/one-tap/callback", {
24
24
  method: "POST";
25
25
  body: z.ZodObject<{
26
26
  idToken: z.ZodString;
@@ -1,7 +1,7 @@
1
1
  import { Session, User } from "../../types/models.mjs";
2
2
  import "../../types/index.mjs";
3
3
  import { GenericEndpointContext } from "@better-auth/core";
4
- import * as better_call256 from "better-call";
4
+ import * as better_call110 from "better-call";
5
5
  import * as z from "zod";
6
6
 
7
7
  //#region src/plugins/one-time-token/index.d.ts
@@ -60,9 +60,9 @@ declare const oneTimeToken: (options?: OneTimeTokenOptions | undefined) => {
60
60
  *
61
61
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/one-time-token#api-method-one-time-token-generate)
62
62
  */
63
- generateOneTimeToken: better_call256.StrictEndpoint<"/one-time-token/generate", {
63
+ generateOneTimeToken: better_call110.StrictEndpoint<"/one-time-token/generate", {
64
64
  method: "GET";
65
- use: ((inputContext: better_call256.MiddlewareInputContext<better_call256.MiddlewareOptions>) => Promise<{
65
+ use: ((inputContext: better_call110.MiddlewareInputContext<better_call110.MiddlewareOptions>) => Promise<{
66
66
  session: {
67
67
  session: Record<string, any> & {
68
68
  id: string;
@@ -103,7 +103,7 @@ declare const oneTimeToken: (options?: OneTimeTokenOptions | undefined) => {
103
103
  *
104
104
  * @see [Read our docs to learn more.](https://better-auth.com/docs/plugins/one-time-token#api-method-one-time-token-verify)
105
105
  */
106
- verifyOneTimeToken: better_call256.StrictEndpoint<"/one-time-token/verify", {
106
+ verifyOneTimeToken: better_call110.StrictEndpoint<"/one-time-token/verify", {
107
107
  method: "POST";
108
108
  body: z.ZodObject<{
109
109
  token: z.ZodString;
@@ -116,7 +116,7 @@ declare const oneTimeToken: (options?: OneTimeTokenOptions | undefined) => {
116
116
  hooks: {
117
117
  after: {
118
118
  matcher: () => true;
119
- handler: (inputContext: better_call256.MiddlewareInputContext<better_call256.MiddlewareOptions>) => Promise<void>;
119
+ handler: (inputContext: better_call110.MiddlewareInputContext<better_call110.MiddlewareOptions>) => Promise<void>;
120
120
  }[];
121
121
  };
122
122
  options: OneTimeTokenOptions | undefined;