@neondatabase/auth 0.2.0-beta.1 → 0.3.0-beta

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 (37) hide show
  1. package/LICENSE +201 -0
  2. package/dist/{adapter-core-CnrOXh1T.d.mts → adapter-core-B9uDhoYq.d.mts} +291 -362
  3. package/dist/{adapter-core-CtmnMMJ7.mjs → adapter-core-D00qcqMo.mjs} +1 -1
  4. package/dist/{better-auth-react-adapter-DNi5PC5D.d.mts → better-auth-react-adapter-BO4jLN4H.d.mts} +251 -251
  5. package/dist/{better-auth-react-adapter-Dv-o6A6O.mjs → better-auth-react-adapter-Xdj-69i9.mjs} +1 -1
  6. package/dist/{index-CzsGMS7C.d.mts → index-B_Q0Tp1D.d.mts} +0 -1
  7. package/dist/index.d.mts +92 -4
  8. package/dist/index.mjs +2 -2
  9. package/dist/{neon-auth-Cs2cWh1B.mjs → neon-auth-DBOB8sXF.mjs} +1 -1
  10. package/dist/next/index.d.mts +17 -17
  11. package/dist/next/index.mjs +3 -3
  12. package/dist/next/server/index.d.mts +2 -4
  13. package/dist/next/server/index.mjs +323 -235
  14. package/dist/react/adapters/index.d.mts +3 -3
  15. package/dist/react/adapters/index.mjs +2 -2
  16. package/dist/react/index.d.mts +6 -5
  17. package/dist/react/index.mjs +5 -5
  18. package/dist/react/ui/index.d.mts +1 -2
  19. package/dist/react/ui/index.mjs +2 -4
  20. package/dist/react/ui/server.mjs +2 -2
  21. package/dist/{supabase-adapter-BlcGPyOf.mjs → supabase-adapter-CIBMebXB.mjs} +1 -1
  22. package/dist/{supabase-adapter-DUqw2fw8.d.mts → supabase-adapter-CSDRL1ZU.d.mts} +285 -316
  23. package/dist/types/index.d.mts +2 -2
  24. package/dist/ui/.safelist.html +1 -1
  25. package/dist/ui/css.css +2 -2
  26. package/dist/ui/theme.css +1 -1
  27. package/dist/ui-CnVnqGns.mjs +3 -0
  28. package/dist/vanilla/adapters/index.d.mts +3 -3
  29. package/dist/vanilla/adapters/index.mjs +2 -2
  30. package/dist/vanilla/index.d.mts +3 -3
  31. package/dist/vanilla/index.mjs +2 -2
  32. package/package.json +23 -21
  33. package/dist/chunk-VCZJYX65-CLnrj1o7-D6ZQkcc_.mjs +0 -543
  34. package/dist/neon-auth-BEGCfAe6.d.mts +0 -107
  35. package/dist/ui-COLWzDsu.mjs +0 -12469
  36. /package/dist/{adapters-B7YKkjaL.mjs → adapters-CUvhsAvY.mjs} +0 -0
  37. /package/dist/{index-OEBbnNdr.d.mts → index-UW23fDSn.d.mts} +0 -0
@@ -1,14 +1,14 @@
1
+ import * as better_auth_react1 from "better-auth/react";
1
2
  import { createAuthClient } from "better-auth/react";
2
- import * as better_auth_client11 from "better-auth/client";
3
+ import * as better_auth_client0 from "better-auth/client";
3
4
  import { BetterAuthClientOptions, createAuthClient as createAuthClient$1 } from "better-auth/client";
4
- import * as jose0 from "jose";
5
+ import * as zod0 from "zod";
6
+ import * as jose1 from "jose";
5
7
  import { Session, User } from "better-auth/types";
6
- import * as better_auth151 from "better-auth";
7
- import * as _better_fetch_fetch88 from "@better-fetch/fetch";
8
+ import * as better_auth_plugins35 from "better-auth/plugins";
9
+ import * as better_auth303 from "better-auth";
10
+ import * as _better_fetch_fetch177 from "@better-fetch/fetch";
8
11
  import { BetterFetchError, BetterFetchError as BetterFetchError$1 } from "@better-fetch/fetch";
9
- import * as better_auth_plugins5 from "better-auth/plugins";
10
- import * as nanostores0 from "nanostores";
11
- import * as better_call0 from "better-call";
12
12
  import { Invitation, InvitationInput, InvitationStatus, Member, MemberInput, Organization, OrganizationInput, OrganizationRole, Team, TeamInput, TeamMember, TeamMemberInput } from "better-auth/plugins/organization";
13
13
  import { JWKOptions, JWSAlgorithms, Jwk, JwtOptions } from "better-auth/plugins/jwt";
14
14
  import { AdminOptions, InferAdminRolesFromOption, SessionWithImpersonatedBy, UserWithRole } from "better-auth/plugins/admin";
@@ -20,11 +20,19 @@ type BetterAuthUser = User;
20
20
  type BetterAuthErrorResponse = BetterFetchError;
21
21
  //#endregion
22
22
  //#region src/types/index.d.ts
23
- type BetterAuthInstance = ReturnType<typeof createAuthClient$1<{
23
+ /**
24
+ * Type representing the Better Auth React client
25
+ */
26
+ type ReactBetterAuthClient = ReturnType<typeof createAuthClient<{
24
27
  plugins: SupportedBetterAuthClientPlugins;
25
- }> | typeof createAuthClient<{
28
+ }>>;
29
+ /**
30
+ * Type representing the Better Auth Vanilla client
31
+ */
32
+ type VanillaBetterAuthClient = ReturnType<typeof createAuthClient$1<{
26
33
  plugins: SupportedBetterAuthClientPlugins;
27
34
  }>>;
35
+ type BetterAuthInstance = VanillaBetterAuthClient | ReactBetterAuthClient;
28
36
  //#endregion
29
37
  //#region src/core/adapter-core.d.ts
30
38
  interface NeonAuthAdapterCoreAuthOptions extends Omit<BetterAuthClientOptions, 'plugins'> {}
@@ -33,7 +41,7 @@ declare const supportedBetterAuthClientPlugins: ({
33
41
  pathMethods: {
34
42
  "/token/anonymous": "GET";
35
43
  };
36
- getActions: ($fetch: _better_fetch_fetch88.BetterFetch) => {
44
+ getActions: ($fetch: _better_fetch_fetch177.BetterFetch) => {
37
45
  getAnonymousToken: (fetchOptions?: any) => Promise<{
38
46
  data: {
39
47
  token: string;
@@ -51,11 +59,11 @@ declare const supportedBetterAuthClientPlugins: ({
51
59
  };
52
60
  } | {
53
61
  id: "better-auth-client";
54
- $InferServerPlugin: ReturnType<(options?: better_auth_plugins5.JwtOptions | undefined) => {
62
+ $InferServerPlugin: ReturnType<(<O extends better_auth_plugins35.JwtOptions>(options?: O) => {
55
63
  id: "jwt";
56
- options: better_auth_plugins5.JwtOptions | undefined;
64
+ options: NoInfer<O>;
57
65
  endpoints: {
58
- getJwks: better_call0.StrictEndpoint<string, {
66
+ getJwks: better_auth303.StrictEndpoint<string, {
59
67
  method: "GET";
60
68
  metadata: {
61
69
  openapi: {
@@ -131,13 +139,11 @@ declare const supportedBetterAuthClientPlugins: ({
131
139
  };
132
140
  };
133
141
  };
134
- } & {
135
- use: any[];
136
- }, jose0.JSONWebKeySet>;
137
- getToken: better_call0.StrictEndpoint<"/token", {
142
+ }, jose1.JSONWebKeySet>;
143
+ getToken: better_auth303.StrictEndpoint<"/token", {
138
144
  method: "GET";
139
145
  requireHeaders: true;
140
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
146
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
141
147
  session: {
142
148
  session: Record<string, any> & {
143
149
  id: string;
@@ -183,35 +189,29 @@ declare const supportedBetterAuthClientPlugins: ({
183
189
  };
184
190
  };
185
191
  };
186
- } & {
187
- use: any[];
188
192
  }, {
189
193
  token: string;
190
194
  }>;
191
- signJWT: better_call0.StrictEndpoint<"/sign-jwt", {
195
+ signJWT: better_auth303.StrictEndpoint<string, {
192
196
  method: "POST";
193
197
  metadata: {
194
- SERVER_ONLY: true;
195
198
  $Infer: {
196
199
  body: {
197
- payload: jose0.JWTPayload;
198
- overrideOptions?: better_auth_plugins5.JwtOptions | undefined;
200
+ payload: jose1.JWTPayload;
201
+ overrideOptions?: better_auth_plugins35.JwtOptions | undefined;
199
202
  };
200
203
  };
201
204
  };
202
- body: better_auth151.ZodObject<{
203
- payload: better_auth151.ZodRecord<better_auth151.ZodString, better_auth151.ZodAny>;
204
- overrideOptions: better_auth151.ZodOptional<better_auth151.ZodRecord<better_auth151.ZodString, better_auth151.ZodAny>>;
205
- }, better_auth151.$strip>;
206
- } & {
207
- use: any[];
205
+ body: zod0.ZodObject<{
206
+ payload: zod0.ZodRecord<zod0.ZodString, zod0.ZodAny>;
207
+ overrideOptions: zod0.ZodOptional<zod0.ZodRecord<zod0.ZodString, zod0.ZodAny>>;
208
+ }, better_auth303.$strip>;
208
209
  }, {
209
210
  token: string;
210
211
  }>;
211
- verifyJWT: better_call0.StrictEndpoint<"/verify-jwt", {
212
+ verifyJWT: better_auth303.StrictEndpoint<string, {
212
213
  method: "POST";
213
214
  metadata: {
214
- SERVER_ONLY: true;
215
215
  $Infer: {
216
216
  body: {
217
217
  token: string;
@@ -226,20 +226,18 @@ declare const supportedBetterAuthClientPlugins: ({
226
226
  };
227
227
  };
228
228
  };
229
- body: better_auth151.ZodObject<{
230
- token: better_auth151.ZodString;
231
- issuer: better_auth151.ZodOptional<better_auth151.ZodString>;
232
- }, better_auth151.$strip>;
233
- } & {
234
- use: any[];
229
+ body: zod0.ZodObject<{
230
+ token: zod0.ZodString;
231
+ issuer: zod0.ZodOptional<zod0.ZodString>;
232
+ }, better_auth303.$strip>;
235
233
  }, {
236
- payload: (jose0.JWTPayload & Required<Pick<jose0.JWTPayload, "sub" | "aud">>) | null;
234
+ payload: (jose1.JWTPayload & Required<Pick<jose1.JWTPayload, "sub" | "aud">>) | null;
237
235
  }>;
238
236
  };
239
237
  hooks: {
240
238
  after: {
241
- matcher(context: better_auth151.HookEndpointContext): boolean;
242
- handler: (inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<void>;
239
+ matcher(context: better_auth303.HookEndpointContext): boolean;
240
+ handler: (inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<void>;
243
241
  }[];
244
242
  };
245
243
  schema: {
@@ -264,11 +262,11 @@ declare const supportedBetterAuthClientPlugins: ({
264
262
  };
265
263
  };
266
264
  };
267
- }>;
265
+ })>;
268
266
  pathMethods: {
269
267
  [x: string]: "GET";
270
268
  };
271
- getActions: ($fetch: _better_fetch_fetch88.BetterFetch) => {
269
+ getActions: ($fetch: _better_fetch_fetch177.BetterFetch) => {
272
270
  jwks: (fetchOptions?: any) => Promise<{
273
271
  data: null;
274
272
  error: {
@@ -277,7 +275,7 @@ declare const supportedBetterAuthClientPlugins: ({
277
275
  statusText: string;
278
276
  };
279
277
  } | {
280
- data: jose0.JSONWebKeySet;
278
+ data: jose1.JSONWebKeySet;
281
279
  error: null;
282
280
  }>;
283
281
  };
@@ -323,7 +321,7 @@ declare const supportedBetterAuthClientPlugins: ({
323
321
  token: string;
324
322
  ipAddress?: string | null | undefined;
325
323
  userAgent?: string | null | undefined;
326
- } & Record<string, unknown>, ctx: better_auth151.GenericEndpointContext | null): Promise<void>;
324
+ } & Record<string, unknown>, ctx: better_auth303.GenericEndpointContext | null): Promise<void>;
327
325
  };
328
326
  };
329
327
  };
@@ -331,22 +329,22 @@ declare const supportedBetterAuthClientPlugins: ({
331
329
  };
332
330
  hooks: {
333
331
  after: {
334
- matcher(context: better_auth151.HookEndpointContext): boolean;
335
- handler: (inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<better_auth_plugins5.SessionWithImpersonatedBy[] | undefined>;
332
+ matcher(context: better_auth303.HookEndpointContext): boolean;
333
+ handler: (inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<better_auth_plugins35.SessionWithImpersonatedBy[] | undefined>;
336
334
  }[];
337
335
  };
338
336
  endpoints: {
339
- setRole: better_call0.StrictEndpoint<"/admin/set-role", {
337
+ setRole: better_auth303.StrictEndpoint<"/admin/set-role", {
340
338
  method: "POST";
341
- body: better_auth151.ZodObject<{
342
- userId: better_auth151.ZodCoercedString<unknown>;
343
- role: better_auth151.ZodUnion<readonly [better_auth151.ZodString, better_auth151.ZodArray<better_auth151.ZodString>]>;
344
- }, better_auth151.$strip>;
339
+ body: zod0.ZodObject<{
340
+ userId: zod0.ZodCoercedString<unknown>;
341
+ role: zod0.ZodUnion<readonly [zod0.ZodString, zod0.ZodArray<zod0.ZodString>]>;
342
+ }, better_auth303.$strip>;
345
343
  requireHeaders: true;
346
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
344
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
347
345
  session: {
348
- user: better_auth_plugins5.UserWithRole;
349
- session: better_auth151.Session;
346
+ user: better_auth_plugins35.UserWithRole;
347
+ session: better_auth303.Session;
350
348
  };
351
349
  }>)[];
352
350
  metadata: {
@@ -379,20 +377,18 @@ declare const supportedBetterAuthClientPlugins: ({
379
377
  };
380
378
  };
381
379
  };
382
- } & {
383
- use: any[];
384
380
  }, {
385
- user: better_auth_plugins5.UserWithRole;
381
+ user: better_auth_plugins35.UserWithRole;
386
382
  }>;
387
- getUser: better_call0.StrictEndpoint<"/admin/get-user", {
383
+ getUser: better_auth303.StrictEndpoint<"/admin/get-user", {
388
384
  method: "GET";
389
- query: better_auth151.ZodObject<{
390
- id: better_auth151.ZodString;
391
- }, better_auth151.$strip>;
392
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
385
+ query: zod0.ZodObject<{
386
+ id: zod0.ZodString;
387
+ }, better_auth303.$strip>;
388
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
393
389
  session: {
394
- user: better_auth_plugins5.UserWithRole;
395
- session: better_auth151.Session;
390
+ user: better_auth_plugins35.UserWithRole;
391
+ session: better_auth303.Session;
396
392
  };
397
393
  }>)[];
398
394
  metadata: {
@@ -419,8 +415,6 @@ declare const supportedBetterAuthClientPlugins: ({
419
415
  };
420
416
  };
421
417
  };
422
- } & {
423
- use: any[];
424
418
  }, {
425
419
  id: string;
426
420
  createdAt: Date;
@@ -430,15 +424,15 @@ declare const supportedBetterAuthClientPlugins: ({
430
424
  name: string;
431
425
  image?: string | null | undefined;
432
426
  }>;
433
- createUser: better_call0.StrictEndpoint<"/admin/create-user", {
427
+ createUser: better_auth303.StrictEndpoint<"/admin/create-user", {
434
428
  method: "POST";
435
- body: better_auth151.ZodObject<{
436
- email: better_auth151.ZodString;
437
- password: better_auth151.ZodString;
438
- name: better_auth151.ZodString;
439
- role: better_auth151.ZodOptional<better_auth151.ZodUnion<readonly [better_auth151.ZodString, better_auth151.ZodArray<better_auth151.ZodString>]>>;
440
- data: better_auth151.ZodOptional<better_auth151.ZodRecord<better_auth151.ZodString, better_auth151.ZodAny>>;
441
- }, better_auth151.$strip>;
429
+ body: zod0.ZodObject<{
430
+ email: zod0.ZodString;
431
+ password: zod0.ZodString;
432
+ name: zod0.ZodString;
433
+ role: zod0.ZodOptional<zod0.ZodUnion<readonly [zod0.ZodString, zod0.ZodArray<zod0.ZodString>]>>;
434
+ data: zod0.ZodOptional<zod0.ZodRecord<zod0.ZodString, zod0.ZodAny>>;
435
+ }, better_auth303.$strip>;
442
436
  metadata: {
443
437
  openapi: {
444
438
  operationId: string;
@@ -472,21 +466,19 @@ declare const supportedBetterAuthClientPlugins: ({
472
466
  };
473
467
  };
474
468
  };
475
- } & {
476
- use: any[];
477
469
  }, {
478
- user: better_auth_plugins5.UserWithRole;
470
+ user: better_auth_plugins35.UserWithRole;
479
471
  }>;
480
- adminUpdateUser: better_call0.StrictEndpoint<"/admin/update-user", {
472
+ adminUpdateUser: better_auth303.StrictEndpoint<"/admin/update-user", {
481
473
  method: "POST";
482
- body: better_auth151.ZodObject<{
483
- userId: better_auth151.ZodCoercedString<unknown>;
484
- data: better_auth151.ZodRecord<better_auth151.ZodAny, better_auth151.ZodAny>;
485
- }, better_auth151.$strip>;
486
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
474
+ body: zod0.ZodObject<{
475
+ userId: zod0.ZodCoercedString<unknown>;
476
+ data: zod0.ZodRecord<zod0.ZodAny, zod0.ZodAny>;
477
+ }, better_auth303.$strip>;
478
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
487
479
  session: {
488
- user: better_auth_plugins5.UserWithRole;
489
- session: better_auth151.Session;
480
+ user: better_auth_plugins35.UserWithRole;
481
+ session: better_auth303.Session;
490
482
  };
491
483
  }>)[];
492
484
  metadata: {
@@ -513,38 +505,36 @@ declare const supportedBetterAuthClientPlugins: ({
513
505
  };
514
506
  };
515
507
  };
516
- } & {
517
- use: any[];
518
- }, better_auth_plugins5.UserWithRole>;
519
- listUsers: better_call0.StrictEndpoint<"/admin/list-users", {
508
+ }, better_auth_plugins35.UserWithRole>;
509
+ listUsers: better_auth303.StrictEndpoint<"/admin/list-users", {
520
510
  method: "GET";
521
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
511
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
522
512
  session: {
523
- user: better_auth_plugins5.UserWithRole;
524
- session: better_auth151.Session;
513
+ user: better_auth_plugins35.UserWithRole;
514
+ session: better_auth303.Session;
525
515
  };
526
516
  }>)[];
527
- query: better_auth151.ZodObject<{
528
- searchValue: better_auth151.ZodOptional<better_auth151.ZodString>;
529
- searchField: better_auth151.ZodOptional<better_auth151.ZodEnum<{
517
+ query: zod0.ZodObject<{
518
+ searchValue: zod0.ZodOptional<zod0.ZodString>;
519
+ searchField: zod0.ZodOptional<zod0.ZodEnum<{
530
520
  name: "name";
531
521
  email: "email";
532
522
  }>>;
533
- searchOperator: better_auth151.ZodOptional<better_auth151.ZodEnum<{
523
+ searchOperator: zod0.ZodOptional<zod0.ZodEnum<{
534
524
  contains: "contains";
535
525
  starts_with: "starts_with";
536
526
  ends_with: "ends_with";
537
527
  }>>;
538
- limit: better_auth151.ZodOptional<better_auth151.ZodUnion<[better_auth151.ZodString, better_auth151.ZodNumber]>>;
539
- offset: better_auth151.ZodOptional<better_auth151.ZodUnion<[better_auth151.ZodString, better_auth151.ZodNumber]>>;
540
- sortBy: better_auth151.ZodOptional<better_auth151.ZodString>;
541
- sortDirection: better_auth151.ZodOptional<better_auth151.ZodEnum<{
528
+ limit: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>>;
529
+ offset: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>>;
530
+ sortBy: zod0.ZodOptional<zod0.ZodString>;
531
+ sortDirection: zod0.ZodOptional<zod0.ZodEnum<{
542
532
  asc: "asc";
543
533
  desc: "desc";
544
534
  }>>;
545
- filterField: better_auth151.ZodOptional<better_auth151.ZodString>;
546
- filterValue: better_auth151.ZodOptional<better_auth151.ZodUnion<[better_auth151.ZodUnion<[better_auth151.ZodString, better_auth151.ZodNumber]>, better_auth151.ZodBoolean]>>;
547
- filterOperator: better_auth151.ZodOptional<better_auth151.ZodEnum<{
535
+ filterField: zod0.ZodOptional<zod0.ZodString>;
536
+ filterValue: zod0.ZodOptional<zod0.ZodUnion<[zod0.ZodUnion<[zod0.ZodString, zod0.ZodNumber]>, zod0.ZodBoolean]>>;
537
+ filterOperator: zod0.ZodOptional<zod0.ZodEnum<{
548
538
  eq: "eq";
549
539
  ne: "ne";
550
540
  lt: "lt";
@@ -553,7 +543,7 @@ declare const supportedBetterAuthClientPlugins: ({
553
543
  gte: "gte";
554
544
  contains: "contains";
555
545
  }>>;
556
- }, better_auth151.$strip>;
546
+ }, better_auth303.$strip>;
557
547
  metadata: {
558
548
  openapi: {
559
549
  operationId: string;
@@ -591,10 +581,8 @@ declare const supportedBetterAuthClientPlugins: ({
591
581
  };
592
582
  };
593
583
  };
594
- } & {
595
- use: any[];
596
584
  }, {
597
- users: better_auth_plugins5.UserWithRole[];
585
+ users: better_auth_plugins35.UserWithRole[];
598
586
  total: number;
599
587
  limit: number | undefined;
600
588
  offset: number | undefined;
@@ -602,17 +590,17 @@ declare const supportedBetterAuthClientPlugins: ({
602
590
  users: never[];
603
591
  total: number;
604
592
  }>;
605
- listUserSessions: better_call0.StrictEndpoint<"/admin/list-user-sessions", {
593
+ listUserSessions: better_auth303.StrictEndpoint<"/admin/list-user-sessions", {
606
594
  method: "POST";
607
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
595
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
608
596
  session: {
609
- user: better_auth_plugins5.UserWithRole;
610
- session: better_auth151.Session;
597
+ user: better_auth_plugins35.UserWithRole;
598
+ session: better_auth303.Session;
611
599
  };
612
600
  }>)[];
613
- body: better_auth151.ZodObject<{
614
- userId: better_auth151.ZodCoercedString<unknown>;
615
- }, better_auth151.$strip>;
601
+ body: zod0.ZodObject<{
602
+ userId: zod0.ZodCoercedString<unknown>;
603
+ }, better_auth303.$strip>;
616
604
  metadata: {
617
605
  openapi: {
618
606
  operationId: string;
@@ -640,20 +628,18 @@ declare const supportedBetterAuthClientPlugins: ({
640
628
  };
641
629
  };
642
630
  };
643
- } & {
644
- use: any[];
645
631
  }, {
646
- sessions: better_auth_plugins5.SessionWithImpersonatedBy[];
632
+ sessions: better_auth_plugins35.SessionWithImpersonatedBy[];
647
633
  }>;
648
- unbanUser: better_call0.StrictEndpoint<"/admin/unban-user", {
634
+ unbanUser: better_auth303.StrictEndpoint<"/admin/unban-user", {
649
635
  method: "POST";
650
- body: better_auth151.ZodObject<{
651
- userId: better_auth151.ZodCoercedString<unknown>;
652
- }, better_auth151.$strip>;
653
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
636
+ body: zod0.ZodObject<{
637
+ userId: zod0.ZodCoercedString<unknown>;
638
+ }, better_auth303.$strip>;
639
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
654
640
  session: {
655
- user: better_auth_plugins5.UserWithRole;
656
- session: better_auth151.Session;
641
+ user: better_auth_plugins35.UserWithRole;
642
+ session: better_auth303.Session;
657
643
  };
658
644
  }>)[];
659
645
  metadata: {
@@ -680,8 +666,6 @@ declare const supportedBetterAuthClientPlugins: ({
680
666
  };
681
667
  };
682
668
  };
683
- } & {
684
- use: any[];
685
669
  }, {
686
670
  user: {
687
671
  id: string;
@@ -693,17 +677,17 @@ declare const supportedBetterAuthClientPlugins: ({
693
677
  image?: string | null | undefined;
694
678
  } & Record<string, any>;
695
679
  }>;
696
- banUser: better_call0.StrictEndpoint<"/admin/ban-user", {
680
+ banUser: better_auth303.StrictEndpoint<"/admin/ban-user", {
697
681
  method: "POST";
698
- body: better_auth151.ZodObject<{
699
- userId: better_auth151.ZodCoercedString<unknown>;
700
- banReason: better_auth151.ZodOptional<better_auth151.ZodString>;
701
- banExpiresIn: better_auth151.ZodOptional<better_auth151.ZodNumber>;
702
- }, better_auth151.$strip>;
703
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
682
+ body: zod0.ZodObject<{
683
+ userId: zod0.ZodCoercedString<unknown>;
684
+ banReason: zod0.ZodOptional<zod0.ZodString>;
685
+ banExpiresIn: zod0.ZodOptional<zod0.ZodNumber>;
686
+ }, better_auth303.$strip>;
687
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
704
688
  session: {
705
- user: better_auth_plugins5.UserWithRole;
706
- session: better_auth151.Session;
689
+ user: better_auth_plugins35.UserWithRole;
690
+ session: better_auth303.Session;
707
691
  };
708
692
  }>)[];
709
693
  metadata: {
@@ -730,8 +714,6 @@ declare const supportedBetterAuthClientPlugins: ({
730
714
  };
731
715
  };
732
716
  };
733
- } & {
734
- use: any[];
735
717
  }, {
736
718
  user: {
737
719
  id: string;
@@ -743,15 +725,15 @@ declare const supportedBetterAuthClientPlugins: ({
743
725
  image?: string | null | undefined;
744
726
  } & Record<string, any>;
745
727
  }>;
746
- impersonateUser: better_call0.StrictEndpoint<"/admin/impersonate-user", {
728
+ impersonateUser: better_auth303.StrictEndpoint<"/admin/impersonate-user", {
747
729
  method: "POST";
748
- body: better_auth151.ZodObject<{
749
- userId: better_auth151.ZodCoercedString<unknown>;
750
- }, better_auth151.$strip>;
751
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
730
+ body: zod0.ZodObject<{
731
+ userId: zod0.ZodCoercedString<unknown>;
732
+ }, better_auth303.$strip>;
733
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
752
734
  session: {
753
- user: better_auth_plugins5.UserWithRole;
754
- session: better_auth151.Session;
735
+ user: better_auth_plugins35.UserWithRole;
736
+ session: better_auth303.Session;
755
737
  };
756
738
  }>)[];
757
739
  metadata: {
@@ -781,8 +763,6 @@ declare const supportedBetterAuthClientPlugins: ({
781
763
  };
782
764
  };
783
765
  };
784
- } & {
785
- use: any[];
786
766
  }, {
787
767
  session: {
788
768
  id: string;
@@ -794,26 +774,24 @@ declare const supportedBetterAuthClientPlugins: ({
794
774
  ipAddress?: string | null | undefined;
795
775
  userAgent?: string | null | undefined;
796
776
  };
797
- user: better_auth_plugins5.UserWithRole;
777
+ user: better_auth_plugins35.UserWithRole;
798
778
  }>;
799
- stopImpersonating: better_call0.StrictEndpoint<"/admin/stop-impersonating", {
779
+ stopImpersonating: better_auth303.StrictEndpoint<"/admin/stop-impersonating", {
800
780
  method: "POST";
801
781
  requireHeaders: true;
802
- } & {
803
- use: any[];
804
782
  }, {
805
- session: better_auth151.Session & Record<string, any>;
806
- user: better_auth151.User & Record<string, any>;
783
+ session: better_auth303.Session & Record<string, any>;
784
+ user: better_auth303.User & Record<string, any>;
807
785
  }>;
808
- revokeUserSession: better_call0.StrictEndpoint<"/admin/revoke-user-session", {
786
+ revokeUserSession: better_auth303.StrictEndpoint<"/admin/revoke-user-session", {
809
787
  method: "POST";
810
- body: better_auth151.ZodObject<{
811
- sessionToken: better_auth151.ZodString;
812
- }, better_auth151.$strip>;
813
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
788
+ body: zod0.ZodObject<{
789
+ sessionToken: zod0.ZodString;
790
+ }, better_auth303.$strip>;
791
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
814
792
  session: {
815
- user: better_auth_plugins5.UserWithRole;
816
- session: better_auth151.Session;
793
+ user: better_auth_plugins35.UserWithRole;
794
+ session: better_auth303.Session;
817
795
  };
818
796
  }>)[];
819
797
  metadata: {
@@ -840,20 +818,18 @@ declare const supportedBetterAuthClientPlugins: ({
840
818
  };
841
819
  };
842
820
  };
843
- } & {
844
- use: any[];
845
821
  }, {
846
822
  success: boolean;
847
823
  }>;
848
- revokeUserSessions: better_call0.StrictEndpoint<"/admin/revoke-user-sessions", {
824
+ revokeUserSessions: better_auth303.StrictEndpoint<"/admin/revoke-user-sessions", {
849
825
  method: "POST";
850
- body: better_auth151.ZodObject<{
851
- userId: better_auth151.ZodCoercedString<unknown>;
852
- }, better_auth151.$strip>;
853
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
826
+ body: zod0.ZodObject<{
827
+ userId: zod0.ZodCoercedString<unknown>;
828
+ }, better_auth303.$strip>;
829
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
854
830
  session: {
855
- user: better_auth_plugins5.UserWithRole;
856
- session: better_auth151.Session;
831
+ user: better_auth_plugins35.UserWithRole;
832
+ session: better_auth303.Session;
857
833
  };
858
834
  }>)[];
859
835
  metadata: {
@@ -880,20 +856,18 @@ declare const supportedBetterAuthClientPlugins: ({
880
856
  };
881
857
  };
882
858
  };
883
- } & {
884
- use: any[];
885
859
  }, {
886
860
  success: boolean;
887
861
  }>;
888
- removeUser: better_call0.StrictEndpoint<"/admin/remove-user", {
862
+ removeUser: better_auth303.StrictEndpoint<"/admin/remove-user", {
889
863
  method: "POST";
890
- body: better_auth151.ZodObject<{
891
- userId: better_auth151.ZodCoercedString<unknown>;
892
- }, better_auth151.$strip>;
893
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
864
+ body: zod0.ZodObject<{
865
+ userId: zod0.ZodCoercedString<unknown>;
866
+ }, better_auth303.$strip>;
867
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
894
868
  session: {
895
- user: better_auth_plugins5.UserWithRole;
896
- session: better_auth151.Session;
869
+ user: better_auth_plugins35.UserWithRole;
870
+ session: better_auth303.Session;
897
871
  };
898
872
  }>)[];
899
873
  metadata: {
@@ -920,21 +894,19 @@ declare const supportedBetterAuthClientPlugins: ({
920
894
  };
921
895
  };
922
896
  };
923
- } & {
924
- use: any[];
925
897
  }, {
926
898
  success: boolean;
927
899
  }>;
928
- setUserPassword: better_call0.StrictEndpoint<"/admin/set-user-password", {
900
+ setUserPassword: better_auth303.StrictEndpoint<"/admin/set-user-password", {
929
901
  method: "POST";
930
- body: better_auth151.ZodObject<{
931
- newPassword: better_auth151.ZodString;
932
- userId: better_auth151.ZodCoercedString<unknown>;
933
- }, better_auth151.$strip>;
934
- use: ((inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{
902
+ body: zod0.ZodObject<{
903
+ newPassword: zod0.ZodString;
904
+ userId: zod0.ZodCoercedString<unknown>;
905
+ }, better_auth303.$strip>;
906
+ use: ((inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<{
935
907
  session: {
936
- user: better_auth_plugins5.UserWithRole;
937
- session: better_auth151.Session;
908
+ user: better_auth_plugins35.UserWithRole;
909
+ session: better_auth303.Session;
938
910
  };
939
911
  }>)[];
940
912
  metadata: {
@@ -961,23 +933,21 @@ declare const supportedBetterAuthClientPlugins: ({
961
933
  };
962
934
  };
963
935
  };
964
- } & {
965
- use: any[];
966
936
  }, {
967
937
  status: boolean;
968
938
  }>;
969
- userHasPermission: better_call0.StrictEndpoint<"/admin/has-permission", {
939
+ userHasPermission: better_auth303.StrictEndpoint<"/admin/has-permission", {
970
940
  method: "POST";
971
- body: better_auth151.ZodIntersection<better_auth151.ZodObject<{
972
- userId: better_auth151.ZodOptional<better_auth151.ZodCoercedString<unknown>>;
973
- role: better_auth151.ZodOptional<better_auth151.ZodString>;
974
- }, better_auth151.$strip>, better_auth151.ZodUnion<readonly [better_auth151.ZodObject<{
975
- permission: better_auth151.ZodRecord<better_auth151.ZodString, better_auth151.ZodArray<better_auth151.ZodString>>;
976
- permissions: better_auth151.ZodUndefined;
977
- }, better_auth151.$strip>, better_auth151.ZodObject<{
978
- permission: better_auth151.ZodUndefined;
979
- permissions: better_auth151.ZodRecord<better_auth151.ZodString, better_auth151.ZodArray<better_auth151.ZodString>>;
980
- }, better_auth151.$strip>]>>;
941
+ body: zod0.ZodIntersection<zod0.ZodObject<{
942
+ userId: zod0.ZodOptional<zod0.ZodCoercedString<unknown>>;
943
+ role: zod0.ZodOptional<zod0.ZodString>;
944
+ }, better_auth303.$strip>, zod0.ZodUnion<readonly [zod0.ZodObject<{
945
+ permission: zod0.ZodRecord<zod0.ZodString, zod0.ZodArray<zod0.ZodString>>;
946
+ permissions: zod0.ZodUndefined;
947
+ }, better_auth303.$strip>, zod0.ZodObject<{
948
+ permission: zod0.ZodUndefined;
949
+ permissions: zod0.ZodRecord<zod0.ZodString, zod0.ZodArray<zod0.ZodString>>;
950
+ }, better_auth303.$strip>]>>;
981
951
  metadata: {
982
952
  openapi: {
983
953
  description: string;
@@ -1043,8 +1013,6 @@ declare const supportedBetterAuthClientPlugins: ({
1043
1013
  };
1044
1014
  };
1045
1015
  };
1046
- } & {
1047
- use: any[];
1048
1016
  }, {
1049
1017
  error: null;
1050
1018
  success: boolean;
@@ -1071,6 +1039,7 @@ declare const supportedBetterAuthClientPlugins: ({
1071
1039
  readonly YOU_CANNOT_REMOVE_YOURSELF: "You cannot remove yourself";
1072
1040
  readonly YOU_ARE_NOT_ALLOWED_TO_SET_NON_EXISTENT_VALUE: "You are not allowed to set a non-existent role value";
1073
1041
  readonly YOU_CANNOT_IMPERSONATE_ADMINS: "You cannot impersonate admins";
1042
+ readonly INVALID_ROLE_TYPE: "Invalid role type";
1074
1043
  };
1075
1044
  schema: {
1076
1045
  user: {
@@ -1107,7 +1076,16 @@ declare const supportedBetterAuthClientPlugins: ({
1107
1076
  };
1108
1077
  };
1109
1078
  };
1110
- options: any;
1079
+ options: NoInfer<{
1080
+ ac: better_auth_plugins35.AccessControl<{
1081
+ readonly user: readonly ["create", "list", "set-role", "ban", "impersonate", "delete", "set-password", "get", "update"];
1082
+ readonly session: readonly ["list", "revoke", "delete"];
1083
+ }>;
1084
+ roles: {
1085
+ admin: better_auth_plugins35.Role;
1086
+ user: better_auth_plugins35.Role;
1087
+ };
1088
+ }>;
1111
1089
  };
1112
1090
  getActions: () => {
1113
1091
  admin: {
@@ -1134,8 +1112,8 @@ declare const supportedBetterAuthClientPlugins: ({
1134
1112
  };
1135
1113
  } | {
1136
1114
  id: "organization";
1137
- $InferServerPlugin: better_auth_client11.OrganizationPlugin<{
1138
- ac: better_auth_client11.AccessControl<{
1115
+ $InferServerPlugin: better_auth_plugins35.OrganizationPlugin<{
1116
+ ac: better_auth_plugins35.AccessControl<{
1139
1117
  readonly organization: readonly ["update", "delete"];
1140
1118
  readonly member: readonly ["create", "update", "delete"];
1141
1119
  readonly invitation: readonly ["create", "cancel"];
@@ -1143,9 +1121,9 @@ declare const supportedBetterAuthClientPlugins: ({
1143
1121
  readonly ac: readonly ["create", "read", "update", "delete"];
1144
1122
  }>;
1145
1123
  roles: {
1146
- admin: better_auth_client11.Role;
1147
- member: better_auth_client11.Role;
1148
- owner: better_auth_client11.Role;
1124
+ admin: better_auth_plugins35.Role;
1125
+ member: better_auth_plugins35.Role;
1126
+ owner: better_auth_plugins35.Role;
1149
1127
  };
1150
1128
  teams: {
1151
1129
  enabled: false;
@@ -1153,27 +1131,27 @@ declare const supportedBetterAuthClientPlugins: ({
1153
1131
  schema: {
1154
1132
  organization?: {
1155
1133
  additionalFields?: {
1156
- [key: string]: better_auth151.DBFieldAttribute;
1134
+ [key: string]: better_auth303.DBFieldAttribute;
1157
1135
  };
1158
1136
  };
1159
1137
  member?: {
1160
1138
  additionalFields?: {
1161
- [key: string]: better_auth151.DBFieldAttribute;
1139
+ [key: string]: better_auth303.DBFieldAttribute;
1162
1140
  };
1163
1141
  };
1164
1142
  invitation?: {
1165
1143
  additionalFields?: {
1166
- [key: string]: better_auth151.DBFieldAttribute;
1144
+ [key: string]: better_auth303.DBFieldAttribute;
1167
1145
  };
1168
1146
  };
1169
1147
  team?: {
1170
1148
  additionalFields?: {
1171
- [key: string]: better_auth151.DBFieldAttribute;
1149
+ [key: string]: better_auth303.DBFieldAttribute;
1172
1150
  };
1173
1151
  };
1174
1152
  organizationRole?: {
1175
1153
  additionalFields?: {
1176
- [key: string]: better_auth151.DBFieldAttribute;
1154
+ [key: string]: better_auth303.DBFieldAttribute;
1177
1155
  };
1178
1156
  };
1179
1157
  } | undefined;
@@ -1181,7 +1159,7 @@ declare const supportedBetterAuthClientPlugins: ({
1181
1159
  enabled: false;
1182
1160
  };
1183
1161
  }>;
1184
- getActions: ($fetch: _better_fetch_fetch88.BetterFetch, _$store: better_auth151.ClientStore, co: BetterAuthClientOptions | undefined) => {
1162
+ getActions: ($fetch: _better_fetch_fetch177.BetterFetch, _$store: better_auth303.ClientStore, co: BetterAuthClientOptions | undefined) => {
1185
1163
  $Infer: {
1186
1164
  ActiveOrganization: {
1187
1165
  members: {
@@ -1202,7 +1180,7 @@ declare const supportedBetterAuthClientPlugins: ({
1202
1180
  organizationId: string;
1203
1181
  email: string;
1204
1182
  role: "admin" | "member" | "owner";
1205
- status: better_auth_client11.InvitationStatus;
1183
+ status: better_auth_plugins35.InvitationStatus;
1206
1184
  inviterId: string;
1207
1185
  expiresAt: Date;
1208
1186
  createdAt: Date;
@@ -1228,7 +1206,7 @@ declare const supportedBetterAuthClientPlugins: ({
1228
1206
  organizationId: string;
1229
1207
  email: string;
1230
1208
  role: "admin" | "member" | "owner";
1231
- status: better_auth_client11.InvitationStatus;
1209
+ status: better_auth_plugins35.InvitationStatus;
1232
1210
  inviterId: string;
1233
1211
  expiresAt: Date;
1234
1212
  createdAt: Date;
@@ -1278,93 +1256,61 @@ declare const supportedBetterAuthClientPlugins: ({
1278
1256
  }) => boolean;
1279
1257
  };
1280
1258
  };
1281
- getAtoms: ($fetch: _better_fetch_fetch88.BetterFetch) => {
1282
- $listOrg: nanostores0.PreinitializedWritableAtom<boolean> & object;
1283
- $activeOrgSignal: nanostores0.PreinitializedWritableAtom<boolean> & object;
1284
- $activeMemberSignal: nanostores0.PreinitializedWritableAtom<boolean> & object;
1285
- $activeMemberRoleSignal: nanostores0.PreinitializedWritableAtom<boolean> & object;
1286
- activeOrganization: nanostores0.PreinitializedWritableAtom<{
1287
- data: better_auth151.Prettify<{
1259
+ getAtoms: ($fetch: _better_fetch_fetch177.BetterFetch) => {
1260
+ $listOrg: better_auth_react1.PreinitializedWritableAtom<boolean> & object;
1261
+ $activeOrgSignal: better_auth_react1.PreinitializedWritableAtom<boolean> & object;
1262
+ $activeMemberSignal: better_auth_react1.PreinitializedWritableAtom<boolean> & object;
1263
+ $activeMemberRoleSignal: better_auth_react1.PreinitializedWritableAtom<boolean> & object;
1264
+ activeOrganization: better_auth_client0.AuthQueryAtom<better_auth303.Prettify<{
1265
+ id: string;
1266
+ name: string;
1267
+ slug: string;
1268
+ createdAt: Date;
1269
+ logo?: string | null | undefined | undefined;
1270
+ metadata?: any;
1271
+ } & {
1272
+ members: {
1288
1273
  id: string;
1289
- name: string;
1290
- slug: string;
1274
+ organizationId: string;
1275
+ role: "admin" | "member" | "owner";
1291
1276
  createdAt: Date;
1292
- logo?: string | null | undefined | undefined;
1293
- metadata?: any;
1294
- } & {
1295
- members: {
1296
- id: string;
1297
- organizationId: string;
1298
- role: "admin" | "member" | "owner";
1299
- createdAt: Date;
1300
- userId: string;
1301
- user: {
1302
- id: string;
1303
- email: string;
1304
- name: string;
1305
- image?: string | undefined;
1306
- };
1307
- }[];
1308
- invitations: {
1277
+ userId: string;
1278
+ user: {
1309
1279
  id: string;
1310
- organizationId: string;
1311
1280
  email: string;
1312
- role: "admin" | "member" | "owner";
1313
- status: better_auth_client11.InvitationStatus;
1314
- inviterId: string;
1315
- expiresAt: Date;
1316
- createdAt: Date;
1317
- }[];
1318
- }> | null;
1319
- error: null | _better_fetch_fetch88.BetterFetchError;
1320
- isPending: boolean;
1321
- isRefetching: boolean;
1322
- refetch: (queryParams?: {
1323
- query?: better_auth151.SessionQueryParams;
1324
- } | undefined) => Promise<void>;
1325
- }> & object;
1326
- listOrganizations: nanostores0.PreinitializedWritableAtom<{
1327
- data: {
1328
- id: string;
1329
- name: string;
1330
- slug: string;
1331
- createdAt: Date;
1332
- logo?: string | null | undefined | undefined;
1333
- metadata?: any;
1334
- }[] | null;
1335
- error: null | _better_fetch_fetch88.BetterFetchError;
1336
- isPending: boolean;
1337
- isRefetching: boolean;
1338
- refetch: (queryParams?: {
1339
- query?: better_auth151.SessionQueryParams;
1340
- } | undefined) => Promise<void>;
1341
- }> & object;
1342
- activeMember: nanostores0.PreinitializedWritableAtom<{
1343
- data: {
1281
+ name: string;
1282
+ image?: string | undefined;
1283
+ };
1284
+ }[];
1285
+ invitations: {
1344
1286
  id: string;
1345
1287
  organizationId: string;
1346
- userId: string;
1347
- role: string;
1288
+ email: string;
1289
+ role: "admin" | "member" | "owner";
1290
+ status: better_auth_plugins35.InvitationStatus;
1291
+ inviterId: string;
1292
+ expiresAt: Date;
1348
1293
  createdAt: Date;
1349
- } | null;
1350
- error: null | _better_fetch_fetch88.BetterFetchError;
1351
- isPending: boolean;
1352
- isRefetching: boolean;
1353
- refetch: (queryParams?: {
1354
- query?: better_auth151.SessionQueryParams;
1355
- } | undefined) => Promise<void>;
1356
- }> & object;
1357
- activeMemberRole: nanostores0.PreinitializedWritableAtom<{
1358
- data: {
1359
- role: string;
1360
- } | null;
1361
- error: null | _better_fetch_fetch88.BetterFetchError;
1362
- isPending: boolean;
1363
- isRefetching: boolean;
1364
- refetch: (queryParams?: {
1365
- query?: better_auth151.SessionQueryParams;
1366
- } | undefined) => Promise<void>;
1367
- }> & object;
1294
+ }[];
1295
+ }>>;
1296
+ listOrganizations: better_auth_client0.AuthQueryAtom<{
1297
+ id: string;
1298
+ name: string;
1299
+ slug: string;
1300
+ createdAt: Date;
1301
+ logo?: string | null | undefined | undefined;
1302
+ metadata?: any;
1303
+ }[]>;
1304
+ activeMember: better_auth_client0.AuthQueryAtom<{
1305
+ id: string;
1306
+ organizationId: string;
1307
+ userId: string;
1308
+ role: string;
1309
+ createdAt: Date;
1310
+ }>;
1311
+ activeMemberRole: better_auth_client0.AuthQueryAtom<{
1312
+ role: string;
1313
+ }>;
1368
1314
  };
1369
1315
  pathMethods: {
1370
1316
  "/organization/get-full-organization": "GET";
@@ -1388,13 +1334,13 @@ declare const supportedBetterAuthClientPlugins: ({
1388
1334
  })[];
1389
1335
  } | {
1390
1336
  id: "email-otp";
1391
- $InferServerPlugin: ReturnType<(options: better_auth_plugins5.EmailOTPOptions) => {
1337
+ $InferServerPlugin: ReturnType<(options: better_auth_plugins35.EmailOTPOptions) => {
1392
1338
  id: "email-otp";
1393
- init(ctx: better_auth151.AuthContext): {
1339
+ init(ctx: better_auth303.AuthContext): {
1394
1340
  options: {
1395
1341
  emailVerification: {
1396
1342
  sendVerificationEmail(data: {
1397
- user: better_auth151.User;
1343
+ user: better_auth303.User;
1398
1344
  url: string;
1399
1345
  token: string;
1400
1346
  }, request: Request | undefined): Promise<void>;
@@ -1402,16 +1348,16 @@ declare const supportedBetterAuthClientPlugins: ({
1402
1348
  };
1403
1349
  } | undefined;
1404
1350
  endpoints: {
1405
- sendVerificationOTP: better_call0.StrictEndpoint<"/email-otp/send-verification-otp", {
1351
+ sendVerificationOTP: better_auth303.StrictEndpoint<"/email-otp/send-verification-otp", {
1406
1352
  method: "POST";
1407
- body: better_auth151.ZodObject<{
1408
- email: better_auth151.ZodString;
1409
- type: better_auth151.ZodEnum<{
1353
+ body: zod0.ZodObject<{
1354
+ email: zod0.ZodString;
1355
+ type: zod0.ZodEnum<{
1410
1356
  "sign-in": "sign-in";
1411
1357
  "email-verification": "email-verification";
1412
1358
  "forget-password": "forget-password";
1413
1359
  }>;
1414
- }, better_auth151.$strip>;
1360
+ }, better_auth303.$strip>;
1415
1361
  metadata: {
1416
1362
  openapi: {
1417
1363
  operationId: string;
@@ -1435,23 +1381,20 @@ declare const supportedBetterAuthClientPlugins: ({
1435
1381
  };
1436
1382
  };
1437
1383
  };
1438
- } & {
1439
- use: any[];
1440
1384
  }, {
1441
1385
  success: boolean;
1442
1386
  }>;
1443
- createVerificationOTP: better_call0.StrictEndpoint<"/email-otp/create-verification-otp", {
1387
+ createVerificationOTP: better_auth303.StrictEndpoint<string, {
1444
1388
  method: "POST";
1445
- body: better_auth151.ZodObject<{
1446
- email: better_auth151.ZodString;
1447
- type: better_auth151.ZodEnum<{
1389
+ body: zod0.ZodObject<{
1390
+ email: zod0.ZodString;
1391
+ type: zod0.ZodEnum<{
1448
1392
  "sign-in": "sign-in";
1449
1393
  "email-verification": "email-verification";
1450
1394
  "forget-password": "forget-password";
1451
1395
  }>;
1452
- }, better_auth151.$strip>;
1396
+ }, better_auth303.$strip>;
1453
1397
  metadata: {
1454
- SERVER_ONLY: true;
1455
1398
  openapi: {
1456
1399
  operationId: string;
1457
1400
  description: string;
@@ -1469,21 +1412,18 @@ declare const supportedBetterAuthClientPlugins: ({
1469
1412
  };
1470
1413
  };
1471
1414
  };
1472
- } & {
1473
- use: any[];
1474
1415
  }, string>;
1475
- getVerificationOTP: better_call0.StrictEndpoint<"/email-otp/get-verification-otp", {
1416
+ getVerificationOTP: better_auth303.StrictEndpoint<string, {
1476
1417
  method: "GET";
1477
- query: better_auth151.ZodObject<{
1478
- email: better_auth151.ZodString;
1479
- type: better_auth151.ZodEnum<{
1418
+ query: zod0.ZodObject<{
1419
+ email: zod0.ZodString;
1420
+ type: zod0.ZodEnum<{
1480
1421
  "sign-in": "sign-in";
1481
1422
  "email-verification": "email-verification";
1482
1423
  "forget-password": "forget-password";
1483
1424
  }>;
1484
- }, better_auth151.$strip>;
1425
+ }, better_auth303.$strip>;
1485
1426
  metadata: {
1486
- SERVER_ONLY: true;
1487
1427
  openapi: {
1488
1428
  operationId: string;
1489
1429
  description: string;
@@ -1509,24 +1449,22 @@ declare const supportedBetterAuthClientPlugins: ({
1509
1449
  };
1510
1450
  };
1511
1451
  };
1512
- } & {
1513
- use: any[];
1514
1452
  }, {
1515
1453
  otp: null;
1516
1454
  } | {
1517
1455
  otp: string;
1518
1456
  }>;
1519
- checkVerificationOTP: better_call0.StrictEndpoint<"/email-otp/check-verification-otp", {
1457
+ checkVerificationOTP: better_auth303.StrictEndpoint<"/email-otp/check-verification-otp", {
1520
1458
  method: "POST";
1521
- body: better_auth151.ZodObject<{
1522
- email: better_auth151.ZodString;
1523
- type: better_auth151.ZodEnum<{
1459
+ body: zod0.ZodObject<{
1460
+ email: zod0.ZodString;
1461
+ type: zod0.ZodEnum<{
1524
1462
  "sign-in": "sign-in";
1525
1463
  "email-verification": "email-verification";
1526
1464
  "forget-password": "forget-password";
1527
1465
  }>;
1528
- otp: better_auth151.ZodString;
1529
- }, better_auth151.$strip>;
1466
+ otp: zod0.ZodString;
1467
+ }, better_auth303.$strip>;
1530
1468
  metadata: {
1531
1469
  openapi: {
1532
1470
  operationId: string;
@@ -1550,17 +1488,15 @@ declare const supportedBetterAuthClientPlugins: ({
1550
1488
  };
1551
1489
  };
1552
1490
  };
1553
- } & {
1554
- use: any[];
1555
1491
  }, {
1556
1492
  success: boolean;
1557
1493
  }>;
1558
- verifyEmailOTP: better_call0.StrictEndpoint<"/email-otp/verify-email", {
1494
+ verifyEmailOTP: better_auth303.StrictEndpoint<"/email-otp/verify-email", {
1559
1495
  method: "POST";
1560
- body: better_auth151.ZodObject<{
1561
- email: better_auth151.ZodString;
1562
- otp: better_auth151.ZodString;
1563
- }, better_auth151.$strip>;
1496
+ body: zod0.ZodObject<{
1497
+ email: zod0.ZodString;
1498
+ otp: zod0.ZodString;
1499
+ }, better_auth303.$strip>;
1564
1500
  metadata: {
1565
1501
  openapi: {
1566
1502
  description: string;
@@ -1594,8 +1530,6 @@ declare const supportedBetterAuthClientPlugins: ({
1594
1530
  };
1595
1531
  };
1596
1532
  };
1597
- } & {
1598
- use: any[];
1599
1533
  }, {
1600
1534
  status: boolean;
1601
1535
  token: string;
@@ -1621,12 +1555,12 @@ declare const supportedBetterAuthClientPlugins: ({
1621
1555
  updatedAt: Date;
1622
1556
  };
1623
1557
  }>;
1624
- signInEmailOTP: better_call0.StrictEndpoint<"/sign-in/email-otp", {
1558
+ signInEmailOTP: better_auth303.StrictEndpoint<"/sign-in/email-otp", {
1625
1559
  method: "POST";
1626
- body: better_auth151.ZodObject<{
1627
- email: better_auth151.ZodString;
1628
- otp: better_auth151.ZodString;
1629
- }, better_auth151.$strip>;
1560
+ body: zod0.ZodObject<{
1561
+ email: zod0.ZodString;
1562
+ otp: zod0.ZodString;
1563
+ }, better_auth303.$strip>;
1630
1564
  metadata: {
1631
1565
  openapi: {
1632
1566
  operationId: string;
@@ -1655,8 +1589,6 @@ declare const supportedBetterAuthClientPlugins: ({
1655
1589
  };
1656
1590
  };
1657
1591
  };
1658
- } & {
1659
- use: any[];
1660
1592
  }, {
1661
1593
  token: string;
1662
1594
  user: {
@@ -1669,11 +1601,11 @@ declare const supportedBetterAuthClientPlugins: ({
1669
1601
  updatedAt: Date;
1670
1602
  };
1671
1603
  }>;
1672
- forgetPasswordEmailOTP: better_call0.StrictEndpoint<"/forget-password/email-otp", {
1604
+ forgetPasswordEmailOTP: better_auth303.StrictEndpoint<"/forget-password/email-otp", {
1673
1605
  method: "POST";
1674
- body: better_auth151.ZodObject<{
1675
- email: better_auth151.ZodString;
1676
- }, better_auth151.$strip>;
1606
+ body: zod0.ZodObject<{
1607
+ email: zod0.ZodString;
1608
+ }, better_auth303.$strip>;
1677
1609
  metadata: {
1678
1610
  openapi: {
1679
1611
  operationId: string;
@@ -1698,18 +1630,16 @@ declare const supportedBetterAuthClientPlugins: ({
1698
1630
  };
1699
1631
  };
1700
1632
  };
1701
- } & {
1702
- use: any[];
1703
1633
  }, {
1704
1634
  success: boolean;
1705
1635
  }>;
1706
- resetPasswordEmailOTP: better_call0.StrictEndpoint<"/email-otp/reset-password", {
1636
+ resetPasswordEmailOTP: better_auth303.StrictEndpoint<"/email-otp/reset-password", {
1707
1637
  method: "POST";
1708
- body: better_auth151.ZodObject<{
1709
- email: better_auth151.ZodString;
1710
- otp: better_auth151.ZodString;
1711
- password: better_auth151.ZodString;
1712
- }, better_auth151.$strip>;
1638
+ body: zod0.ZodObject<{
1639
+ email: zod0.ZodString;
1640
+ otp: zod0.ZodString;
1641
+ password: zod0.ZodString;
1642
+ }, better_auth303.$strip>;
1713
1643
  metadata: {
1714
1644
  openapi: {
1715
1645
  operationId: string;
@@ -1733,16 +1663,14 @@ declare const supportedBetterAuthClientPlugins: ({
1733
1663
  };
1734
1664
  };
1735
1665
  };
1736
- } & {
1737
- use: any[];
1738
1666
  }, {
1739
1667
  success: boolean;
1740
1668
  }>;
1741
1669
  };
1742
1670
  hooks: {
1743
1671
  after: {
1744
- matcher(context: better_auth151.HookEndpointContext): boolean;
1745
- handler: (inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<void>;
1672
+ matcher(context: better_auth303.HookEndpointContext): boolean;
1673
+ handler: (inputContext: better_auth303.MiddlewareInputContext<better_auth303.MiddlewareOptions>) => Promise<void>;
1746
1674
  }[];
1747
1675
  };
1748
1676
  $ERROR_CODES: {
@@ -1767,6 +1695,7 @@ declare const supportedBetterAuthClientPlugins: ({
1767
1695
  window: number;
1768
1696
  max: number;
1769
1697
  })[];
1698
+ options: better_auth_plugins35.EmailOTPOptions;
1770
1699
  }>;
1771
1700
  atomListeners: {
1772
1701
  matcher: (path: string) => path is "/email-otp/verify-email" | "/sign-in/email-otp";
@@ -1797,4 +1726,4 @@ declare abstract class NeonAuthAdapterCore {
1797
1726
  getJWTToken(allowAnonymous: boolean): Promise<string | null>;
1798
1727
  }
1799
1728
  //#endregion
1800
- export { TeamInput as C, BetterAuthErrorResponse as D, UserWithRole as E, BetterAuthSession as O, Team as S, TeamMemberInput as T, MemberInput as _, BetterAuthInstance as a, OrganizationRole as b, InferAdminRolesFromOption as c, InvitationStatus as d, JWKOptions as f, Member as g, JwtOptions as h, AdminOptions as i, BetterAuthUser as k, Invitation as l, Jwk as m, NeonAuthAdapterCoreAuthOptions as n, BetterFetchError$1 as o, JWSAlgorithms as p, SupportedBetterAuthClientPlugins as r, EmailOTPOptions as s, NeonAuthAdapterCore as t, InvitationInput as u, Organization as v, TeamMember as w, SessionWithImpersonatedBy as x, OrganizationInput as y };
1729
+ export { BetterAuthSession as A, Team as C, UserWithRole as D, TeamMemberInput as E, VanillaBetterAuthClient as O, SessionWithImpersonatedBy as S, TeamMember as T, MemberInput as _, BetterAuthInstance as a, OrganizationRole as b, InferAdminRolesFromOption as c, InvitationStatus as d, JWKOptions as f, Member as g, JwtOptions as h, AdminOptions as i, BetterAuthUser as j, BetterAuthErrorResponse as k, Invitation as l, Jwk as m, NeonAuthAdapterCoreAuthOptions as n, BetterFetchError$1 as o, JWSAlgorithms as p, SupportedBetterAuthClientPlugins as r, EmailOTPOptions as s, NeonAuthAdapterCore as t, InvitationInput as u, Organization as v, TeamInput as w, ReactBetterAuthClient as x, OrganizationInput as y };