@b3dotfun/sdk 0.1.69-alpha.16 → 0.1.69-alpha.18

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 (125) hide show
  1. package/dist/cjs/anyspend/constants/rpc.d.ts +1 -1
  2. package/dist/cjs/anyspend/constants/rpc.js +1 -1
  3. package/dist/cjs/anyspend/react/components/AnySpendNFT.js +2 -2
  4. package/dist/cjs/anyspend/react/components/checkout/CheckoutSuccess.js +3 -3
  5. package/dist/cjs/anyspend/react/components/common/InsufficientDepositPayment.js +2 -2
  6. package/dist/cjs/anyspend/react/components/common/OrderDetails.js +2 -2
  7. package/dist/cjs/anyspend/react/components/common/OrderDetailsCollapsible.js +2 -2
  8. package/dist/cjs/anyspend/react/components/common/TransferCryptoDetails.js +2 -2
  9. package/dist/cjs/anyspend/utils/chain.js +8 -7
  10. package/dist/cjs/global-account/better-auth-client.d.ts +1883 -0
  11. package/dist/cjs/global-account/better-auth-client.js +17 -0
  12. package/dist/cjs/global-account/react/components/B3Provider/B3ConfigProvider.d.ts +4 -1
  13. package/dist/cjs/global-account/react/components/B3Provider/B3ConfigProvider.js +2 -1
  14. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.d.ts +4 -1
  15. package/dist/cjs/global-account/react/components/B3Provider/B3Provider.js +3 -2
  16. package/dist/cjs/global-account/react/components/B3Provider/BetterAuthProvider.d.ts +16 -0
  17. package/dist/cjs/global-account/react/components/B3Provider/BetterAuthProvider.js +120 -0
  18. package/dist/cjs/global-account/react/components/SignInWithB3/BetterAuthResetPassword.d.ts +21 -0
  19. package/dist/cjs/global-account/react/components/SignInWithB3/BetterAuthResetPassword.js +67 -0
  20. package/dist/cjs/global-account/react/components/SignInWithB3/BetterAuthSignIn.d.ts +34 -0
  21. package/dist/cjs/global-account/react/components/SignInWithB3/BetterAuthSignIn.js +149 -0
  22. package/dist/cjs/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +9 -3
  23. package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.d.ts +6 -0
  24. package/dist/cjs/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.js +123 -0
  25. package/dist/cjs/global-account/react/components/SignInWithB3/utils/signInUtils.js +5 -1
  26. package/dist/cjs/global-account/react/components/custom/Button.d.ts +1 -1
  27. package/dist/cjs/global-account/react/components/index.d.ts +3 -0
  28. package/dist/cjs/global-account/react/components/index.js +7 -3
  29. package/dist/cjs/global-account/react/components/ui/button.d.ts +1 -1
  30. package/dist/cjs/global-account/react/hooks/index.d.ts +1 -0
  31. package/dist/cjs/global-account/react/hooks/index.js +4 -2
  32. package/dist/cjs/global-account/react/hooks/useBetterAuth.d.ts +969 -0
  33. package/dist/cjs/global-account/react/hooks/useBetterAuth.js +142 -0
  34. package/dist/cjs/shared/constants/chains/b3Chain.d.ts +7 -7
  35. package/dist/cjs/shared/constants/chains/b3Chain.js +4 -4
  36. package/dist/cjs/shared/constants/chains/b3Viem.d.ts +6 -0
  37. package/dist/cjs/shared/constants/chains/b3Viem.js +19 -0
  38. package/dist/cjs/shared/constants/chains/supported.d.ts +1 -1
  39. package/dist/cjs/shared/generated/chain-networks.json +2 -2
  40. package/dist/cjs/shared/utils/chains.d.ts +1 -1
  41. package/dist/cjs/shared/utils/chains.js +2 -2
  42. package/dist/esm/anyspend/constants/rpc.d.ts +1 -1
  43. package/dist/esm/anyspend/constants/rpc.js +1 -1
  44. package/dist/esm/anyspend/react/components/AnySpendNFT.js +2 -2
  45. package/dist/esm/anyspend/react/components/checkout/CheckoutSuccess.js +3 -3
  46. package/dist/esm/anyspend/react/components/common/InsufficientDepositPayment.js +2 -2
  47. package/dist/esm/anyspend/react/components/common/OrderDetails.js +2 -2
  48. package/dist/esm/anyspend/react/components/common/OrderDetailsCollapsible.js +2 -2
  49. package/dist/esm/anyspend/react/components/common/TransferCryptoDetails.js +2 -2
  50. package/dist/esm/anyspend/utils/chain.js +10 -9
  51. package/dist/esm/global-account/better-auth-client.d.ts +1883 -0
  52. package/dist/esm/global-account/better-auth-client.js +13 -0
  53. package/dist/esm/global-account/react/components/B3Provider/B3ConfigProvider.d.ts +4 -1
  54. package/dist/esm/global-account/react/components/B3Provider/B3ConfigProvider.js +2 -1
  55. package/dist/esm/global-account/react/components/B3Provider/B3Provider.d.ts +4 -1
  56. package/dist/esm/global-account/react/components/B3Provider/B3Provider.js +3 -2
  57. package/dist/esm/global-account/react/components/B3Provider/BetterAuthProvider.d.ts +16 -0
  58. package/dist/esm/global-account/react/components/B3Provider/BetterAuthProvider.js +115 -0
  59. package/dist/esm/global-account/react/components/SignInWithB3/BetterAuthResetPassword.d.ts +21 -0
  60. package/dist/esm/global-account/react/components/SignInWithB3/BetterAuthResetPassword.js +64 -0
  61. package/dist/esm/global-account/react/components/SignInWithB3/BetterAuthSignIn.d.ts +34 -0
  62. package/dist/esm/global-account/react/components/SignInWithB3/BetterAuthSignIn.js +146 -0
  63. package/dist/esm/global-account/react/components/SignInWithB3/SignInWithB3Flow.js +9 -3
  64. package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.d.ts +6 -0
  65. package/dist/esm/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.js +120 -0
  66. package/dist/esm/global-account/react/components/SignInWithB3/utils/signInUtils.js +5 -1
  67. package/dist/esm/global-account/react/components/custom/Button.d.ts +1 -1
  68. package/dist/esm/global-account/react/components/index.d.ts +3 -0
  69. package/dist/esm/global-account/react/components/index.js +2 -0
  70. package/dist/esm/global-account/react/components/ui/button.d.ts +1 -1
  71. package/dist/esm/global-account/react/hooks/index.d.ts +1 -0
  72. package/dist/esm/global-account/react/hooks/index.js +1 -0
  73. package/dist/esm/global-account/react/hooks/useBetterAuth.d.ts +969 -0
  74. package/dist/esm/global-account/react/hooks/useBetterAuth.js +136 -0
  75. package/dist/esm/shared/constants/chains/b3Chain.d.ts +7 -7
  76. package/dist/esm/shared/constants/chains/b3Chain.js +4 -4
  77. package/dist/esm/shared/constants/chains/b3Viem.d.ts +6 -0
  78. package/dist/esm/shared/constants/chains/b3Viem.js +16 -0
  79. package/dist/esm/shared/constants/chains/supported.d.ts +1 -1
  80. package/dist/esm/shared/generated/chain-networks.json +2 -2
  81. package/dist/esm/shared/utils/chains.d.ts +1 -1
  82. package/dist/esm/shared/utils/chains.js +2 -2
  83. package/dist/styles/index.css +1 -1
  84. package/dist/types/anyspend/constants/rpc.d.ts +1 -1
  85. package/dist/types/global-account/better-auth-client.d.ts +1883 -0
  86. package/dist/types/global-account/react/components/B3Provider/B3ConfigProvider.d.ts +4 -1
  87. package/dist/types/global-account/react/components/B3Provider/B3Provider.d.ts +4 -1
  88. package/dist/types/global-account/react/components/B3Provider/BetterAuthProvider.d.ts +16 -0
  89. package/dist/types/global-account/react/components/SignInWithB3/BetterAuthResetPassword.d.ts +21 -0
  90. package/dist/types/global-account/react/components/SignInWithB3/BetterAuthSignIn.d.ts +34 -0
  91. package/dist/types/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.d.ts +6 -0
  92. package/dist/types/global-account/react/components/custom/Button.d.ts +1 -1
  93. package/dist/types/global-account/react/components/index.d.ts +3 -0
  94. package/dist/types/global-account/react/components/ui/button.d.ts +1 -1
  95. package/dist/types/global-account/react/hooks/index.d.ts +1 -0
  96. package/dist/types/global-account/react/hooks/useBetterAuth.d.ts +969 -0
  97. package/dist/types/shared/constants/chains/b3Chain.d.ts +7 -7
  98. package/dist/types/shared/constants/chains/b3Viem.d.ts +6 -0
  99. package/dist/types/shared/constants/chains/supported.d.ts +1 -1
  100. package/dist/types/shared/utils/chains.d.ts +1 -1
  101. package/package.json +2 -1
  102. package/src/anyspend/constants/rpc.ts +2 -1
  103. package/src/anyspend/react/components/AnySpendNFT.tsx +2 -2
  104. package/src/anyspend/react/components/checkout/CheckoutSuccess.tsx +3 -3
  105. package/src/anyspend/react/components/common/InsufficientDepositPayment.tsx +2 -2
  106. package/src/anyspend/react/components/common/OrderDetails.tsx +2 -2
  107. package/src/anyspend/react/components/common/OrderDetailsCollapsible.tsx +4 -4
  108. package/src/anyspend/react/components/common/TransferCryptoDetails.tsx +2 -2
  109. package/src/anyspend/utils/chain.ts +9 -9
  110. package/src/global-account/better-auth-client.ts +17 -0
  111. package/src/global-account/react/components/B3Provider/B3ConfigProvider.tsx +6 -0
  112. package/src/global-account/react/components/B3Provider/B3Provider.tsx +15 -5
  113. package/src/global-account/react/components/B3Provider/BetterAuthProvider.tsx +127 -0
  114. package/src/global-account/react/components/SignInWithB3/BetterAuthResetPassword.tsx +146 -0
  115. package/src/global-account/react/components/SignInWithB3/BetterAuthSignIn.tsx +375 -0
  116. package/src/global-account/react/components/SignInWithB3/SignInWithB3Flow.tsx +9 -3
  117. package/src/global-account/react/components/SignInWithB3/steps/LoginStepBetterAuth.tsx +263 -0
  118. package/src/global-account/react/components/SignInWithB3/utils/signInUtils.ts +5 -1
  119. package/src/global-account/react/components/index.ts +3 -0
  120. package/src/global-account/react/hooks/index.ts +1 -0
  121. package/src/global-account/react/hooks/useBetterAuth.ts +177 -0
  122. package/src/shared/constants/chains/b3Chain.ts +5 -5
  123. package/src/shared/constants/chains/b3Viem.ts +18 -0
  124. package/src/shared/generated/chain-networks.json +2 -2
  125. package/src/shared/utils/chains.ts +3 -2
@@ -0,0 +1,969 @@
1
+ export type BetterAuthSocialProvider = "google" | "discord" | "apple" | "github" | "slack" | "microsoft";
2
+ /**
3
+ * Hook for authentication via Better Auth (email/password + social providers).
4
+ *
5
+ * Follows the same pattern as Thirdweb auth:
6
+ * 1. Better Auth sign-in returns a session token
7
+ * 2. Token is passed as accessToken to app.authenticate({ strategy: "better-auth" })
8
+ * 3. BetterAuthStrategy verifies the token and issues a Feathers JWT
9
+ */
10
+ export declare function useBetterAuth(): {
11
+ signInWithEmail: (email: string, password: string) => Promise<import("@feathersjs/authentication").AuthenticationResult>;
12
+ signUpWithEmail: (email: string, password: string, name: string) => Promise<import("@feathersjs/authentication").AuthenticationResult>;
13
+ signInWithSocial: (provider: BetterAuthSocialProvider) => Promise<void>;
14
+ requestPasswordReset: (email: string, redirectTo?: string) => Promise<{
15
+ data: {
16
+ status: boolean;
17
+ message: string;
18
+ };
19
+ error: null;
20
+ }>;
21
+ resetPassword: (newPassword: string, token: string) => Promise<{
22
+ data: {
23
+ status: boolean;
24
+ };
25
+ error: null;
26
+ }>;
27
+ exchangeForFeathersJWT: (sessionToken: string) => Promise<import("@feathersjs/authentication").AuthenticationResult>;
28
+ betterAuthClient: {
29
+ signIn: {
30
+ social: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
31
+ provider: (string & {}) | "apple" | "google" | "github" | "discord" | "line" | "facebook" | "twitch" | "tiktok" | "zoom" | "linear" | "huggingface" | "atlassian" | "cognito" | "figma" | "microsoft" | "slack" | "spotify" | "twitter" | "dropbox" | "kick" | "linkedin" | "gitlab" | "reddit" | "roblox" | "salesforce" | "vk" | "notion" | "kakao" | "naver" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
32
+ callbackURL?: string | undefined;
33
+ newUserCallbackURL?: string | undefined;
34
+ errorCallbackURL?: string | undefined;
35
+ disableRedirect?: boolean | undefined;
36
+ idToken?: {
37
+ token: string;
38
+ nonce?: string | undefined;
39
+ accessToken?: string | undefined;
40
+ refreshToken?: string | undefined;
41
+ expiresAt?: number | undefined;
42
+ user?: {
43
+ name?: {
44
+ firstName?: string | undefined;
45
+ lastName?: string | undefined;
46
+ } | undefined;
47
+ email?: string | undefined;
48
+ } | undefined;
49
+ } | undefined;
50
+ scopes?: string[] | undefined;
51
+ requestSignUp?: boolean | undefined;
52
+ loginHint?: string | undefined;
53
+ additionalData?: Record<string, any> | undefined;
54
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
55
+ provider: (string & {}) | "apple" | "google" | "github" | "discord" | "line" | "facebook" | "twitch" | "tiktok" | "zoom" | "linear" | "huggingface" | "atlassian" | "cognito" | "figma" | "microsoft" | "slack" | "spotify" | "twitter" | "dropbox" | "kick" | "linkedin" | "gitlab" | "reddit" | "roblox" | "salesforce" | "vk" | "notion" | "kakao" | "naver" | "paybin" | "paypal" | "polar" | "railway" | "vercel" | "wechat";
56
+ callbackURL?: string | undefined;
57
+ newUserCallbackURL?: string | undefined;
58
+ errorCallbackURL?: string | undefined;
59
+ disableRedirect?: boolean | undefined;
60
+ idToken?: {
61
+ token: string;
62
+ nonce?: string | undefined;
63
+ accessToken?: string | undefined;
64
+ refreshToken?: string | undefined;
65
+ expiresAt?: number | undefined;
66
+ user?: {
67
+ name?: {
68
+ firstName?: string | undefined;
69
+ lastName?: string | undefined;
70
+ } | undefined;
71
+ email?: string | undefined;
72
+ } | undefined;
73
+ } | undefined;
74
+ scopes?: string[] | undefined;
75
+ requestSignUp?: boolean | undefined;
76
+ loginHint?: string | undefined;
77
+ additionalData?: Record<string, any> | undefined;
78
+ } & {
79
+ fetchOptions?: FetchOptions | undefined;
80
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
81
+ redirect: boolean;
82
+ url: string;
83
+ } | (Omit<{
84
+ redirect: boolean;
85
+ token: string;
86
+ url: undefined;
87
+ user: {
88
+ id: string;
89
+ createdAt: Date;
90
+ updatedAt: Date;
91
+ email: string;
92
+ emailVerified: boolean;
93
+ name: string;
94
+ image?: string | null | undefined | undefined;
95
+ };
96
+ }, "user"> & {
97
+ user: import("better-auth/client").StripEmptyObjects<{
98
+ id: string;
99
+ createdAt: Date;
100
+ updatedAt: Date;
101
+ email: string;
102
+ emailVerified: boolean;
103
+ name: string;
104
+ image?: string | null | undefined;
105
+ }>;
106
+ }), {
107
+ code?: string | undefined;
108
+ message?: string | undefined;
109
+ }, FetchOptions["throw"] extends true ? true : false>>;
110
+ };
111
+ } & {
112
+ signOut: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
113
+ query?: Record<string, any> | undefined;
114
+ fetchOptions?: FetchOptions | undefined;
115
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
116
+ success: boolean;
117
+ }, {
118
+ code?: string | undefined;
119
+ message?: string | undefined;
120
+ }, FetchOptions["throw"] extends true ? true : false>>;
121
+ } & {
122
+ signUp: {
123
+ email: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
124
+ name: string;
125
+ email: string;
126
+ password: string;
127
+ image?: string | undefined;
128
+ callbackURL?: string | undefined;
129
+ rememberMe?: boolean | undefined;
130
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
131
+ email: string;
132
+ name: string;
133
+ password: string;
134
+ image?: string | undefined;
135
+ callbackURL?: string | undefined;
136
+ fetchOptions?: FetchOptions | undefined;
137
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<(Omit<{
138
+ token: null;
139
+ user: {
140
+ id: string;
141
+ createdAt: Date;
142
+ updatedAt: Date;
143
+ email: string;
144
+ emailVerified: boolean;
145
+ name: string;
146
+ image?: string | null | undefined | undefined;
147
+ };
148
+ }, "user"> & {
149
+ user: import("better-auth/client").StripEmptyObjects<{
150
+ id: string;
151
+ createdAt: Date;
152
+ updatedAt: Date;
153
+ email: string;
154
+ emailVerified: boolean;
155
+ name: string;
156
+ image?: string | null | undefined;
157
+ }>;
158
+ }) | (Omit<{
159
+ token: string;
160
+ user: {
161
+ id: string;
162
+ createdAt: Date;
163
+ updatedAt: Date;
164
+ email: string;
165
+ emailVerified: boolean;
166
+ name: string;
167
+ image?: string | null | undefined | undefined;
168
+ };
169
+ }, "user"> & {
170
+ user: import("better-auth/client").StripEmptyObjects<{
171
+ id: string;
172
+ createdAt: Date;
173
+ updatedAt: Date;
174
+ email: string;
175
+ emailVerified: boolean;
176
+ name: string;
177
+ image?: string | null | undefined;
178
+ }>;
179
+ }), {
180
+ code?: string | undefined;
181
+ message?: string | undefined;
182
+ }, FetchOptions["throw"] extends true ? true : false>>;
183
+ };
184
+ } & {
185
+ signIn: {
186
+ email: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
187
+ email: string;
188
+ password: string;
189
+ callbackURL?: string | undefined;
190
+ rememberMe?: boolean | undefined;
191
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
192
+ email: string;
193
+ password: string;
194
+ callbackURL?: string | undefined;
195
+ rememberMe?: boolean | undefined;
196
+ } & {
197
+ fetchOptions?: FetchOptions | undefined;
198
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<Omit<{
199
+ redirect: boolean;
200
+ token: string;
201
+ url?: string | undefined;
202
+ user: {
203
+ id: string;
204
+ createdAt: Date;
205
+ updatedAt: Date;
206
+ email: string;
207
+ emailVerified: boolean;
208
+ name: string;
209
+ image?: string | null | undefined | undefined;
210
+ };
211
+ }, "user"> & {
212
+ user: import("better-auth/client").StripEmptyObjects<{
213
+ id: string;
214
+ createdAt: Date;
215
+ updatedAt: Date;
216
+ email: string;
217
+ emailVerified: boolean;
218
+ name: string;
219
+ image?: string | null | undefined;
220
+ }>;
221
+ }, {
222
+ code?: string | undefined;
223
+ message?: string | undefined;
224
+ }, FetchOptions["throw"] extends true ? true : false>>;
225
+ };
226
+ } & {
227
+ resetPassword: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
228
+ newPassword: string;
229
+ token?: string | undefined;
230
+ }> & Record<string, any>, Partial<{
231
+ token?: string | undefined;
232
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
233
+ newPassword: string;
234
+ token?: string | undefined;
235
+ } & {
236
+ fetchOptions?: FetchOptions | undefined;
237
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
238
+ status: boolean;
239
+ }, {
240
+ code?: string | undefined;
241
+ message?: string | undefined;
242
+ }, FetchOptions["throw"] extends true ? true : false>>;
243
+ } & {
244
+ verifyEmail: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<{
245
+ token: string;
246
+ callbackURL?: string | undefined;
247
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
248
+ query: {
249
+ token: string;
250
+ callbackURL?: string | undefined;
251
+ };
252
+ fetchOptions?: FetchOptions | undefined;
253
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<NonNullable<void | {
254
+ status: boolean;
255
+ }>, {
256
+ code?: string | undefined;
257
+ message?: string | undefined;
258
+ }, FetchOptions["throw"] extends true ? true : false>>;
259
+ } & {
260
+ sendVerificationEmail: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
261
+ email: string;
262
+ callbackURL?: string | undefined;
263
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
264
+ email: string;
265
+ callbackURL?: string | undefined;
266
+ } & {
267
+ fetchOptions?: FetchOptions | undefined;
268
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
269
+ status: boolean;
270
+ }, {
271
+ code?: string | undefined;
272
+ message?: string | undefined;
273
+ }, FetchOptions["throw"] extends true ? true : false>>;
274
+ } & {
275
+ changeEmail: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
276
+ newEmail: string;
277
+ callbackURL?: string | undefined;
278
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
279
+ newEmail: string;
280
+ callbackURL?: string | undefined;
281
+ } & {
282
+ fetchOptions?: FetchOptions | undefined;
283
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
284
+ status: boolean;
285
+ }, {
286
+ code?: string | undefined;
287
+ message?: string | undefined;
288
+ }, FetchOptions["throw"] extends true ? true : false>>;
289
+ } & {
290
+ changePassword: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
291
+ newPassword: string;
292
+ currentPassword: string;
293
+ revokeOtherSessions?: boolean | undefined;
294
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
295
+ newPassword: string;
296
+ currentPassword: string;
297
+ revokeOtherSessions?: boolean | undefined;
298
+ } & {
299
+ fetchOptions?: FetchOptions | undefined;
300
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<Omit<{
301
+ token: string | null;
302
+ user: {
303
+ id: string;
304
+ createdAt: Date;
305
+ updatedAt: Date;
306
+ email: string;
307
+ emailVerified: boolean;
308
+ name: string;
309
+ image?: string | null | undefined;
310
+ } & Record<string, any> & {
311
+ id: string;
312
+ createdAt: Date;
313
+ updatedAt: Date;
314
+ email: string;
315
+ emailVerified: boolean;
316
+ name: string;
317
+ image?: string | null | undefined;
318
+ };
319
+ }, "user"> & {
320
+ user: import("better-auth/client").StripEmptyObjects<{
321
+ id: string;
322
+ createdAt: Date;
323
+ updatedAt: Date;
324
+ email: string;
325
+ emailVerified: boolean;
326
+ name: string;
327
+ image?: string | null | undefined;
328
+ }>;
329
+ }, {
330
+ code?: string | undefined;
331
+ message?: string | undefined;
332
+ }, FetchOptions["throw"] extends true ? true : false>>;
333
+ } & {
334
+ updateSession: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<Partial<{}>> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<Partial<{}> & {
335
+ fetchOptions?: FetchOptions | undefined;
336
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
337
+ session: {
338
+ id: string;
339
+ createdAt: Date;
340
+ updatedAt: Date;
341
+ userId: string;
342
+ expiresAt: Date;
343
+ token: string;
344
+ ipAddress?: string | null | undefined;
345
+ userAgent?: string | null | undefined;
346
+ };
347
+ }, {
348
+ code?: string | undefined;
349
+ message?: string | undefined;
350
+ }, FetchOptions["throw"] extends true ? true : false>>;
351
+ } & {
352
+ updateUser: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<Partial<{}> & {
353
+ name?: string | undefined;
354
+ image?: string | undefined | null;
355
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<import("better-auth/client").InferUserUpdateCtx<{
356
+ baseURL: string;
357
+ basePath: string;
358
+ fetchOptions: {
359
+ credentials: "include";
360
+ };
361
+ }, FetchOptions>> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
362
+ status: boolean;
363
+ }, {
364
+ code?: string | undefined;
365
+ message?: string | undefined;
366
+ }, FetchOptions["throw"] extends true ? true : false>>;
367
+ } & {
368
+ deleteUser: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
369
+ callbackURL?: string | undefined;
370
+ password?: string | undefined;
371
+ token?: string | undefined;
372
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
373
+ callbackURL?: string | undefined;
374
+ password?: string | undefined;
375
+ token?: string | undefined;
376
+ } & {
377
+ fetchOptions?: FetchOptions | undefined;
378
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
379
+ success: boolean;
380
+ message: string;
381
+ }, {
382
+ code?: string | undefined;
383
+ message?: string | undefined;
384
+ }, FetchOptions["throw"] extends true ? true : false>>;
385
+ } & {
386
+ requestPasswordReset: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
387
+ email: string;
388
+ redirectTo?: string | undefined;
389
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
390
+ email: string;
391
+ redirectTo?: string | undefined;
392
+ } & {
393
+ fetchOptions?: FetchOptions | undefined;
394
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
395
+ status: boolean;
396
+ message: string;
397
+ }, {
398
+ code?: string | undefined;
399
+ message?: string | undefined;
400
+ }, FetchOptions["throw"] extends true ? true : false>>;
401
+ } & {
402
+ resetPassword: {
403
+ ":token": <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<{
404
+ callbackURL: string;
405
+ }> & Record<string, any>, {
406
+ token: string;
407
+ }>>(data_0: import("better-auth/client").Prettify<{
408
+ query: {
409
+ callbackURL: string;
410
+ };
411
+ fetchOptions?: FetchOptions | undefined;
412
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<never, {
413
+ code?: string | undefined;
414
+ message?: string | undefined;
415
+ }, FetchOptions["throw"] extends true ? true : false>>;
416
+ };
417
+ } & {
418
+ listSessions: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
419
+ query?: Record<string, any> | undefined;
420
+ fetchOptions?: FetchOptions | undefined;
421
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<import("better-auth/client").Prettify<{
422
+ id: string;
423
+ createdAt: Date;
424
+ updatedAt: Date;
425
+ userId: string;
426
+ expiresAt: Date;
427
+ token: string;
428
+ ipAddress?: string | null | undefined | undefined;
429
+ userAgent?: string | null | undefined | undefined;
430
+ }>[], {
431
+ code?: string | undefined;
432
+ message?: string | undefined;
433
+ }, FetchOptions["throw"] extends true ? true : false>>;
434
+ } & {
435
+ revokeSession: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
436
+ token: string;
437
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
438
+ token: string;
439
+ } & {
440
+ fetchOptions?: FetchOptions | undefined;
441
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
442
+ status: boolean;
443
+ }, {
444
+ code?: string | undefined;
445
+ message?: string | undefined;
446
+ }, FetchOptions["throw"] extends true ? true : false>>;
447
+ } & {
448
+ revokeSessions: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
449
+ query?: Record<string, any> | undefined;
450
+ fetchOptions?: FetchOptions | undefined;
451
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
452
+ status: boolean;
453
+ }, {
454
+ code?: string | undefined;
455
+ message?: string | undefined;
456
+ }, FetchOptions["throw"] extends true ? true : false>>;
457
+ } & {
458
+ revokeOtherSessions: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
459
+ query?: Record<string, any> | undefined;
460
+ fetchOptions?: FetchOptions | undefined;
461
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
462
+ status: boolean;
463
+ }, {
464
+ code?: string | undefined;
465
+ message?: string | undefined;
466
+ }, FetchOptions["throw"] extends true ? true : false>>;
467
+ } & {
468
+ linkSocial: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
469
+ provider: unknown;
470
+ callbackURL?: string | undefined;
471
+ idToken?: {
472
+ token: string;
473
+ nonce?: string | undefined;
474
+ accessToken?: string | undefined;
475
+ refreshToken?: string | undefined;
476
+ scopes?: string[] | undefined;
477
+ } | undefined;
478
+ requestSignUp?: boolean | undefined;
479
+ scopes?: string[] | undefined;
480
+ errorCallbackURL?: string | undefined;
481
+ disableRedirect?: boolean | undefined;
482
+ additionalData?: Record<string, any> | undefined;
483
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
484
+ provider: unknown;
485
+ callbackURL?: string | undefined;
486
+ idToken?: {
487
+ token: string;
488
+ nonce?: string | undefined;
489
+ accessToken?: string | undefined;
490
+ refreshToken?: string | undefined;
491
+ scopes?: string[] | undefined;
492
+ } | undefined;
493
+ requestSignUp?: boolean | undefined;
494
+ scopes?: string[] | undefined;
495
+ errorCallbackURL?: string | undefined;
496
+ disableRedirect?: boolean | undefined;
497
+ additionalData?: Record<string, any> | undefined;
498
+ } & {
499
+ fetchOptions?: FetchOptions | undefined;
500
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
501
+ url: string;
502
+ redirect: boolean;
503
+ }, {
504
+ code?: string | undefined;
505
+ message?: string | undefined;
506
+ }, FetchOptions["throw"] extends true ? true : false>>;
507
+ } & {
508
+ listAccounts: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
509
+ query?: Record<string, any> | undefined;
510
+ fetchOptions?: FetchOptions | undefined;
511
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
512
+ scopes: string[];
513
+ id: string;
514
+ createdAt: Date;
515
+ updatedAt: Date;
516
+ userId: string;
517
+ providerId: string;
518
+ accountId: string;
519
+ }[], {
520
+ code?: string | undefined;
521
+ message?: string | undefined;
522
+ }, FetchOptions["throw"] extends true ? true : false>>;
523
+ } & {
524
+ deleteUser: {
525
+ callback: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<{
526
+ token: string;
527
+ callbackURL?: string | undefined;
528
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
529
+ query: {
530
+ token: string;
531
+ callbackURL?: string | undefined;
532
+ };
533
+ fetchOptions?: FetchOptions | undefined;
534
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
535
+ success: boolean;
536
+ message: string;
537
+ }, {
538
+ code?: string | undefined;
539
+ message?: string | undefined;
540
+ }, FetchOptions["throw"] extends true ? true : false>>;
541
+ };
542
+ } & {
543
+ unlinkAccount: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
544
+ providerId: string;
545
+ accountId?: string | undefined;
546
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
547
+ providerId: string;
548
+ accountId?: string | undefined;
549
+ } & {
550
+ fetchOptions?: FetchOptions | undefined;
551
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
552
+ status: boolean;
553
+ }, {
554
+ code?: string | undefined;
555
+ message?: string | undefined;
556
+ }, FetchOptions["throw"] extends true ? true : false>>;
557
+ } & {
558
+ refreshToken: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
559
+ providerId: string;
560
+ accountId?: string | undefined;
561
+ userId?: string | undefined;
562
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
563
+ providerId: string;
564
+ accountId?: string | undefined;
565
+ userId?: string | undefined;
566
+ } & {
567
+ fetchOptions?: FetchOptions | undefined;
568
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
569
+ accessToken: string | undefined;
570
+ refreshToken: string;
571
+ accessTokenExpiresAt: Date | undefined;
572
+ refreshTokenExpiresAt: Date | null | undefined;
573
+ scope: string | null | undefined;
574
+ idToken: string | null | undefined;
575
+ providerId: string;
576
+ accountId: string;
577
+ }, {
578
+ code?: string | undefined;
579
+ message?: string | undefined;
580
+ }, FetchOptions["throw"] extends true ? true : false>>;
581
+ } & {
582
+ getAccessToken: <FetchOptions extends import("@better-auth/core").ClientFetchOption<Partial<{
583
+ providerId: string;
584
+ accountId?: string | undefined;
585
+ userId?: string | undefined;
586
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import("better-auth/client").Prettify<{
587
+ providerId: string;
588
+ accountId?: string | undefined;
589
+ userId?: string | undefined;
590
+ } & {
591
+ fetchOptions?: FetchOptions | undefined;
592
+ }>, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
593
+ accessToken: string;
594
+ accessTokenExpiresAt: Date | undefined;
595
+ scopes: string[];
596
+ idToken: string | undefined;
597
+ }, {
598
+ code?: string | undefined;
599
+ message?: string | undefined;
600
+ }, FetchOptions["throw"] extends true ? true : false>>;
601
+ } & {
602
+ accountInfo: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<{
603
+ accountId?: string | undefined;
604
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
605
+ query?: {
606
+ accountId?: string | undefined;
607
+ } | undefined;
608
+ fetchOptions?: FetchOptions | undefined;
609
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
610
+ user: import("@better-auth/core/oauth2").OAuth2UserInfo;
611
+ data: Record<string, any>;
612
+ }, {
613
+ code?: string | undefined;
614
+ message?: string | undefined;
615
+ }, FetchOptions["throw"] extends true ? true : false>>;
616
+ } & {
617
+ getSession: <FetchOptions extends import("@better-auth/core").ClientFetchOption<never, Partial<{
618
+ disableCookieCache?: unknown;
619
+ disableRefresh?: unknown;
620
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import("better-auth/client").Prettify<{
621
+ query?: {
622
+ disableCookieCache?: unknown;
623
+ disableRefresh?: unknown;
624
+ } | undefined;
625
+ fetchOptions?: FetchOptions | undefined;
626
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import("@better-fetch/fetch").BetterFetchResponse<{
627
+ user: import("better-auth/client").StripEmptyObjects<{
628
+ id: string;
629
+ createdAt: Date;
630
+ updatedAt: Date;
631
+ email: string;
632
+ emailVerified: boolean;
633
+ name: string;
634
+ image?: string | null | undefined;
635
+ }>;
636
+ session: import("better-auth/client").StripEmptyObjects<{
637
+ id: string;
638
+ createdAt: Date;
639
+ updatedAt: Date;
640
+ userId: string;
641
+ expiresAt: Date;
642
+ token: string;
643
+ ipAddress?: string | null | undefined;
644
+ userAgent?: string | null | undefined;
645
+ }>;
646
+ } | null, {
647
+ code?: string | undefined;
648
+ message?: string | undefined;
649
+ }, FetchOptions["throw"] extends true ? true : false>>;
650
+ } & {
651
+ useSession: import("nanostores").Atom<{
652
+ data: {
653
+ user: import("better-auth/client").StripEmptyObjects<{
654
+ id: string;
655
+ createdAt: Date;
656
+ updatedAt: Date;
657
+ email: string;
658
+ emailVerified: boolean;
659
+ name: string;
660
+ image?: string | null | undefined;
661
+ }>;
662
+ session: import("better-auth/client").StripEmptyObjects<{
663
+ id: string;
664
+ createdAt: Date;
665
+ updatedAt: Date;
666
+ userId: string;
667
+ expiresAt: Date;
668
+ token: string;
669
+ ipAddress?: string | null | undefined;
670
+ userAgent?: string | null | undefined;
671
+ }>;
672
+ } | null;
673
+ error: import("@better-fetch/fetch").BetterFetchError | null;
674
+ isPending: boolean;
675
+ isRefetching: boolean;
676
+ refetch: (queryParams?: {
677
+ query?: import("better-auth/client").SessionQueryParams;
678
+ } | undefined) => Promise<void>;
679
+ }>;
680
+ $fetch: import("@better-fetch/fetch").BetterFetch<{
681
+ plugins: (import("@better-fetch/fetch").BetterFetchPlugin<Record<string, any>> | {
682
+ id: string;
683
+ name: string;
684
+ hooks: {
685
+ onSuccess(context: import("@better-fetch/fetch").SuccessContext<any>): void;
686
+ };
687
+ } | {
688
+ id: string;
689
+ name: string;
690
+ hooks: {
691
+ onSuccess: ((context: import("@better-fetch/fetch").SuccessContext<any>) => Promise<void> | void) | undefined;
692
+ onError: ((context: import("@better-fetch/fetch").ErrorContext) => Promise<void> | void) | undefined;
693
+ onRequest: (<T extends Record<string, any>>(context: import("@better-fetch/fetch").RequestContext<T>) => Promise<import("@better-fetch/fetch").RequestContext | void> | import("@better-fetch/fetch").RequestContext | void) | undefined;
694
+ onResponse: ((context: import("@better-fetch/fetch").ResponseContext) => Promise<Response | void | import("@better-fetch/fetch").ResponseContext> | Response | import("@better-fetch/fetch").ResponseContext | void) | undefined;
695
+ };
696
+ })[];
697
+ cache?: RequestCache | undefined;
698
+ priority?: RequestPriority | undefined;
699
+ credentials?: RequestCredentials;
700
+ headers?: (HeadersInit & (HeadersInit | {
701
+ accept: "application/json" | "text/plain" | "application/octet-stream";
702
+ "content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
703
+ authorization: "Bearer" | "Basic";
704
+ })) | undefined;
705
+ integrity?: string | undefined;
706
+ keepalive?: boolean | undefined;
707
+ method: string;
708
+ mode?: RequestMode | undefined;
709
+ redirect?: RequestRedirect | undefined;
710
+ referrer?: string | undefined;
711
+ referrerPolicy?: ReferrerPolicy | undefined;
712
+ signal?: (AbortSignal | null) | undefined;
713
+ window?: null | undefined;
714
+ onRetry?: ((response: import("@better-fetch/fetch").ResponseContext) => Promise<void> | void) | undefined;
715
+ hookOptions?: {
716
+ cloneResponse?: boolean;
717
+ } | undefined;
718
+ timeout?: number | undefined;
719
+ customFetchImpl: import("@better-fetch/fetch").FetchEsque;
720
+ baseURL: string;
721
+ throw?: boolean | undefined;
722
+ auth?: ({
723
+ type: "Bearer";
724
+ token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
725
+ } | {
726
+ type: "Basic";
727
+ username: string | (() => string | undefined) | undefined;
728
+ password: string | (() => string | undefined) | undefined;
729
+ } | {
730
+ type: "Custom";
731
+ prefix: string | (() => string | undefined) | undefined;
732
+ value: string | (() => string | undefined) | undefined;
733
+ }) | undefined;
734
+ body?: any;
735
+ query?: any;
736
+ params?: any;
737
+ duplex?: "full" | "half" | undefined;
738
+ jsonParser: (text: string) => Promise<any> | any;
739
+ retry?: import("@better-fetch/fetch").RetryOptions | undefined;
740
+ retryAttempt?: number | undefined;
741
+ output?: (import("@better-fetch/fetch").StandardSchemaV1 | typeof Blob | typeof File) | undefined;
742
+ errorSchema?: import("@better-fetch/fetch").StandardSchemaV1 | undefined;
743
+ disableValidation?: boolean | undefined;
744
+ disableSignal?: boolean | undefined;
745
+ }, unknown, unknown, {}>;
746
+ $store: {
747
+ notify: (signal?: (Omit<string, "$sessionSignal"> | "$sessionSignal") | undefined) => void;
748
+ listen: (signal: Omit<string, "$sessionSignal"> | "$sessionSignal", listener: (value: boolean, oldValue?: boolean | undefined) => void) => void;
749
+ atoms: Record<string, import("nanostores").WritableAtom<any>>;
750
+ };
751
+ $Infer: {
752
+ Session: {
753
+ user: import("better-auth/client").StripEmptyObjects<{
754
+ id: string;
755
+ createdAt: Date;
756
+ updatedAt: Date;
757
+ email: string;
758
+ emailVerified: boolean;
759
+ name: string;
760
+ image?: string | null | undefined;
761
+ }>;
762
+ session: import("better-auth/client").StripEmptyObjects<{
763
+ id: string;
764
+ createdAt: Date;
765
+ updatedAt: Date;
766
+ userId: string;
767
+ expiresAt: Date;
768
+ token: string;
769
+ ipAddress?: string | null | undefined;
770
+ userAgent?: string | null | undefined;
771
+ }>;
772
+ };
773
+ };
774
+ $ERROR_CODES: {
775
+ USER_NOT_FOUND: {
776
+ readonly code: "USER_NOT_FOUND";
777
+ message: string;
778
+ };
779
+ FAILED_TO_CREATE_USER: {
780
+ readonly code: "FAILED_TO_CREATE_USER";
781
+ message: string;
782
+ };
783
+ FAILED_TO_CREATE_SESSION: {
784
+ readonly code: "FAILED_TO_CREATE_SESSION";
785
+ message: string;
786
+ };
787
+ FAILED_TO_UPDATE_USER: {
788
+ readonly code: "FAILED_TO_UPDATE_USER";
789
+ message: string;
790
+ };
791
+ FAILED_TO_GET_SESSION: {
792
+ readonly code: "FAILED_TO_GET_SESSION";
793
+ message: string;
794
+ };
795
+ INVALID_PASSWORD: {
796
+ readonly code: "INVALID_PASSWORD";
797
+ message: string;
798
+ };
799
+ INVALID_EMAIL: {
800
+ readonly code: "INVALID_EMAIL";
801
+ message: string;
802
+ };
803
+ INVALID_EMAIL_OR_PASSWORD: {
804
+ readonly code: "INVALID_EMAIL_OR_PASSWORD";
805
+ message: string;
806
+ };
807
+ INVALID_USER: {
808
+ readonly code: "INVALID_USER";
809
+ message: string;
810
+ };
811
+ SOCIAL_ACCOUNT_ALREADY_LINKED: {
812
+ readonly code: "SOCIAL_ACCOUNT_ALREADY_LINKED";
813
+ message: string;
814
+ };
815
+ PROVIDER_NOT_FOUND: {
816
+ readonly code: "PROVIDER_NOT_FOUND";
817
+ message: string;
818
+ };
819
+ INVALID_TOKEN: {
820
+ readonly code: "INVALID_TOKEN";
821
+ message: string;
822
+ };
823
+ TOKEN_EXPIRED: {
824
+ readonly code: "TOKEN_EXPIRED";
825
+ message: string;
826
+ };
827
+ ID_TOKEN_NOT_SUPPORTED: {
828
+ readonly code: "ID_TOKEN_NOT_SUPPORTED";
829
+ message: string;
830
+ };
831
+ FAILED_TO_GET_USER_INFO: {
832
+ readonly code: "FAILED_TO_GET_USER_INFO";
833
+ message: string;
834
+ };
835
+ USER_EMAIL_NOT_FOUND: {
836
+ readonly code: "USER_EMAIL_NOT_FOUND";
837
+ message: string;
838
+ };
839
+ EMAIL_NOT_VERIFIED: {
840
+ readonly code: "EMAIL_NOT_VERIFIED";
841
+ message: string;
842
+ };
843
+ PASSWORD_TOO_SHORT: {
844
+ readonly code: "PASSWORD_TOO_SHORT";
845
+ message: string;
846
+ };
847
+ PASSWORD_TOO_LONG: {
848
+ readonly code: "PASSWORD_TOO_LONG";
849
+ message: string;
850
+ };
851
+ USER_ALREADY_EXISTS: {
852
+ readonly code: "USER_ALREADY_EXISTS";
853
+ message: string;
854
+ };
855
+ USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL: {
856
+ readonly code: "USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL";
857
+ message: string;
858
+ };
859
+ EMAIL_CAN_NOT_BE_UPDATED: {
860
+ readonly code: "EMAIL_CAN_NOT_BE_UPDATED";
861
+ message: string;
862
+ };
863
+ CREDENTIAL_ACCOUNT_NOT_FOUND: {
864
+ readonly code: "CREDENTIAL_ACCOUNT_NOT_FOUND";
865
+ message: string;
866
+ };
867
+ ACCOUNT_NOT_FOUND: {
868
+ readonly code: "ACCOUNT_NOT_FOUND";
869
+ message: string;
870
+ };
871
+ SESSION_EXPIRED: {
872
+ readonly code: "SESSION_EXPIRED";
873
+ message: string;
874
+ };
875
+ FAILED_TO_UNLINK_LAST_ACCOUNT: {
876
+ readonly code: "FAILED_TO_UNLINK_LAST_ACCOUNT";
877
+ message: string;
878
+ };
879
+ USER_ALREADY_HAS_PASSWORD: {
880
+ readonly code: "USER_ALREADY_HAS_PASSWORD";
881
+ message: string;
882
+ };
883
+ CROSS_SITE_NAVIGATION_LOGIN_BLOCKED: {
884
+ readonly code: "CROSS_SITE_NAVIGATION_LOGIN_BLOCKED";
885
+ message: string;
886
+ };
887
+ VERIFICATION_EMAIL_NOT_ENABLED: {
888
+ readonly code: "VERIFICATION_EMAIL_NOT_ENABLED";
889
+ message: string;
890
+ };
891
+ EMAIL_ALREADY_VERIFIED: {
892
+ readonly code: "EMAIL_ALREADY_VERIFIED";
893
+ message: string;
894
+ };
895
+ EMAIL_MISMATCH: {
896
+ readonly code: "EMAIL_MISMATCH";
897
+ message: string;
898
+ };
899
+ SESSION_NOT_FRESH: {
900
+ readonly code: "SESSION_NOT_FRESH";
901
+ message: string;
902
+ };
903
+ LINKED_ACCOUNT_ALREADY_EXISTS: {
904
+ readonly code: "LINKED_ACCOUNT_ALREADY_EXISTS";
905
+ message: string;
906
+ };
907
+ INVALID_ORIGIN: {
908
+ readonly code: "INVALID_ORIGIN";
909
+ message: string;
910
+ };
911
+ INVALID_CALLBACK_URL: {
912
+ readonly code: "INVALID_CALLBACK_URL";
913
+ message: string;
914
+ };
915
+ INVALID_REDIRECT_URL: {
916
+ readonly code: "INVALID_REDIRECT_URL";
917
+ message: string;
918
+ };
919
+ INVALID_ERROR_CALLBACK_URL: {
920
+ readonly code: "INVALID_ERROR_CALLBACK_URL";
921
+ message: string;
922
+ };
923
+ INVALID_NEW_USER_CALLBACK_URL: {
924
+ readonly code: "INVALID_NEW_USER_CALLBACK_URL";
925
+ message: string;
926
+ };
927
+ MISSING_OR_NULL_ORIGIN: {
928
+ readonly code: "MISSING_OR_NULL_ORIGIN";
929
+ message: string;
930
+ };
931
+ CALLBACK_URL_REQUIRED: {
932
+ readonly code: "CALLBACK_URL_REQUIRED";
933
+ message: string;
934
+ };
935
+ FAILED_TO_CREATE_VERIFICATION: {
936
+ readonly code: "FAILED_TO_CREATE_VERIFICATION";
937
+ message: string;
938
+ };
939
+ FIELD_NOT_ALLOWED: {
940
+ readonly code: "FIELD_NOT_ALLOWED";
941
+ message: string;
942
+ };
943
+ ASYNC_VALIDATION_NOT_SUPPORTED: {
944
+ readonly code: "ASYNC_VALIDATION_NOT_SUPPORTED";
945
+ message: string;
946
+ };
947
+ VALIDATION_ERROR: {
948
+ readonly code: "VALIDATION_ERROR";
949
+ message: string;
950
+ };
951
+ MISSING_FIELD: {
952
+ readonly code: "MISSING_FIELD";
953
+ message: string;
954
+ };
955
+ METHOD_NOT_ALLOWED_DEFER_SESSION_REQUIRED: {
956
+ readonly code: "METHOD_NOT_ALLOWED_DEFER_SESSION_REQUIRED";
957
+ message: string;
958
+ };
959
+ BODY_MUST_BE_AN_OBJECT: {
960
+ readonly code: "BODY_MUST_BE_AN_OBJECT";
961
+ message: string;
962
+ };
963
+ PASSWORD_ALREADY_SET: {
964
+ readonly code: "PASSWORD_ALREADY_SET";
965
+ message: string;
966
+ };
967
+ };
968
+ };
969
+ };