better-auth-ui 3.2.23 → 3.2.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{auth-hooks-BuniCu20.d.cts → auth-hooks-Kg4U0adj.d.cts} +16 -546
- package/dist/{auth-hooks-BuniCu20.d.ts → auth-hooks-Kg4U0adj.d.ts} +16 -546
- package/dist/{auth-ui-provider-mrVNJ6zj.d.ts → auth-ui-provider-B4nloIHk.d.ts} +1 -1
- package/dist/{auth-ui-provider-D3GrYvcj.d.cts → auth-ui-provider-DndP_Qgj.d.cts} +1 -1
- package/dist/index.cjs +1 -4
- package/dist/index.d.cts +4 -6
- package/dist/index.d.ts +4 -6
- package/dist/index.js +0 -3
- package/dist/instantdb.d.cts +1 -3
- package/dist/instantdb.d.ts +1 -3
- package/dist/metafile-cjs.json +1 -1
- package/dist/metafile-esm.json +1 -1
- package/dist/tanstack.d.cts +2 -4
- package/dist/tanstack.d.ts +2 -4
- package/dist/triplit.d.cts +1 -3
- package/dist/triplit.d.ts +1 -3
- package/package.json +1 -1
- package/src/index.ts +1 -0
- package/src/lib/auth-ui-provider.tsx +11 -11
- package/src/types/any-auth-client.ts +3 -1
- package/src/types/auth-client.ts +8 -4
|
@@ -6,25 +6,15 @@ import * as better_auth_plugins_organization from 'better-auth/plugins/organizat
|
|
|
6
6
|
import { Member } from 'better-auth/plugins/organization';
|
|
7
7
|
import * as better_auth_react from 'better-auth/react';
|
|
8
8
|
import { createAuthClient } from 'better-auth/react';
|
|
9
|
-
import * as inspector from 'inspector';
|
|
10
9
|
import * as better_auth_client_plugins from 'better-auth/client/plugins';
|
|
11
|
-
import * as better_auth_plugins_passkey from 'better-auth/plugins/passkey';
|
|
12
10
|
|
|
13
11
|
type Refetch = () => Promise<unknown> | unknown;
|
|
14
12
|
|
|
15
|
-
type AnyAuthClient = Omit<ReturnType<typeof createAuthClient>, "signUp" | "getSession"
|
|
13
|
+
type AnyAuthClient = Omit<ReturnType<typeof createAuthClient>, "signUp" | "getSession"> & {
|
|
14
|
+
[key: string]: any;
|
|
15
|
+
};
|
|
16
16
|
|
|
17
|
-
declare const authClient: {
|
|
18
|
-
useListPasskeys: () => {
|
|
19
|
-
data: better_auth_plugins_passkey.Passkey[] | null;
|
|
20
|
-
error: null | _better_fetch_fetch.BetterFetchError;
|
|
21
|
-
isPending: boolean;
|
|
22
|
-
isRefetching: boolean;
|
|
23
|
-
refetch: (queryParams?: {
|
|
24
|
-
query?: better_auth.SessionQueryParams;
|
|
25
|
-
} | undefined) => void;
|
|
26
|
-
};
|
|
27
|
-
} & {} & {
|
|
17
|
+
declare const authClient: {} & {
|
|
28
18
|
useActiveOrganization: () => {
|
|
29
19
|
data: better_auth.Prettify<{
|
|
30
20
|
id: string;
|
|
@@ -2766,482 +2756,6 @@ declare const authClient: {
|
|
|
2766
2756
|
message?: string;
|
|
2767
2757
|
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
2768
2758
|
};
|
|
2769
|
-
} & {
|
|
2770
|
-
passkey: {
|
|
2771
|
-
generateRegisterOptions: <FetchOptions extends {
|
|
2772
|
-
method?: string | undefined;
|
|
2773
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
2774
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
2775
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
2776
|
-
authorization: "Bearer" | "Basic";
|
|
2777
|
-
})) | undefined;
|
|
2778
|
-
cache?: RequestCache | undefined;
|
|
2779
|
-
credentials?: RequestCredentials | undefined;
|
|
2780
|
-
integrity?: string | undefined;
|
|
2781
|
-
keepalive?: boolean | undefined;
|
|
2782
|
-
mode?: RequestMode | undefined;
|
|
2783
|
-
priority?: RequestPriority | undefined;
|
|
2784
|
-
redirect?: RequestRedirect | undefined;
|
|
2785
|
-
referrer?: string | undefined;
|
|
2786
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
2787
|
-
signal?: (AbortSignal | null) | undefined;
|
|
2788
|
-
window?: null | undefined;
|
|
2789
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
2790
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
2791
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
2792
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
2793
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
2794
|
-
hookOptions?: {
|
|
2795
|
-
cloneResponse?: boolean;
|
|
2796
|
-
} | undefined;
|
|
2797
|
-
timeout?: number | undefined;
|
|
2798
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
2799
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
2800
|
-
baseURL?: string | undefined;
|
|
2801
|
-
throw?: boolean | undefined;
|
|
2802
|
-
auth?: ({
|
|
2803
|
-
type: "Bearer";
|
|
2804
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
2805
|
-
} | {
|
|
2806
|
-
type: "Basic";
|
|
2807
|
-
username: string | (() => string | undefined) | undefined;
|
|
2808
|
-
password: string | (() => string | undefined) | undefined;
|
|
2809
|
-
} | {
|
|
2810
|
-
type: "Custom";
|
|
2811
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
2812
|
-
value: string | (() => string | undefined) | undefined;
|
|
2813
|
-
}) | undefined;
|
|
2814
|
-
body?: undefined;
|
|
2815
|
-
query?: (Partial<{
|
|
2816
|
-
authenticatorAttachment?: "platform" | "cross-platform" | undefined;
|
|
2817
|
-
name?: string | undefined;
|
|
2818
|
-
}> & Record<string, any>) | undefined;
|
|
2819
|
-
params?: Record<string, any> | undefined;
|
|
2820
|
-
duplex?: "full" | "half" | undefined;
|
|
2821
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
2822
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
2823
|
-
retryAttempt?: number | undefined;
|
|
2824
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
2825
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
2826
|
-
disableValidation?: boolean | undefined;
|
|
2827
|
-
}>(data_0?: better_auth.Prettify<{
|
|
2828
|
-
query?: {
|
|
2829
|
-
authenticatorAttachment?: "platform" | "cross-platform" | undefined;
|
|
2830
|
-
name?: string | undefined;
|
|
2831
|
-
} | undefined;
|
|
2832
|
-
fetchOptions?: FetchOptions | undefined;
|
|
2833
|
-
}> | undefined, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<better_auth_client_plugins.PublicKeyCredentialCreationOptionsJSON, {
|
|
2834
|
-
code?: string;
|
|
2835
|
-
message?: string;
|
|
2836
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
2837
|
-
};
|
|
2838
|
-
} & {
|
|
2839
|
-
passkey: {
|
|
2840
|
-
generateAuthenticateOptions: <FetchOptions extends {
|
|
2841
|
-
method?: string | undefined;
|
|
2842
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
2843
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
2844
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
2845
|
-
authorization: "Bearer" | "Basic";
|
|
2846
|
-
})) | undefined;
|
|
2847
|
-
cache?: RequestCache | undefined;
|
|
2848
|
-
credentials?: RequestCredentials | undefined;
|
|
2849
|
-
integrity?: string | undefined;
|
|
2850
|
-
keepalive?: boolean | undefined;
|
|
2851
|
-
mode?: RequestMode | undefined;
|
|
2852
|
-
priority?: RequestPriority | undefined;
|
|
2853
|
-
redirect?: RequestRedirect | undefined;
|
|
2854
|
-
referrer?: string | undefined;
|
|
2855
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
2856
|
-
signal?: (AbortSignal | null) | undefined;
|
|
2857
|
-
window?: null | undefined;
|
|
2858
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
2859
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
2860
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
2861
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
2862
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
2863
|
-
hookOptions?: {
|
|
2864
|
-
cloneResponse?: boolean;
|
|
2865
|
-
} | undefined;
|
|
2866
|
-
timeout?: number | undefined;
|
|
2867
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
2868
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
2869
|
-
baseURL?: string | undefined;
|
|
2870
|
-
throw?: boolean | undefined;
|
|
2871
|
-
auth?: ({
|
|
2872
|
-
type: "Bearer";
|
|
2873
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
2874
|
-
} | {
|
|
2875
|
-
type: "Basic";
|
|
2876
|
-
username: string | (() => string | undefined) | undefined;
|
|
2877
|
-
password: string | (() => string | undefined) | undefined;
|
|
2878
|
-
} | {
|
|
2879
|
-
type: "Custom";
|
|
2880
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
2881
|
-
value: string | (() => string | undefined) | undefined;
|
|
2882
|
-
}) | undefined;
|
|
2883
|
-
body?: undefined;
|
|
2884
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
2885
|
-
params?: Record<string, any> | undefined;
|
|
2886
|
-
duplex?: "full" | "half" | undefined;
|
|
2887
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
2888
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
2889
|
-
retryAttempt?: number | undefined;
|
|
2890
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
2891
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
2892
|
-
disableValidation?: boolean | undefined;
|
|
2893
|
-
}>(data_0?: better_auth.Prettify<{
|
|
2894
|
-
query?: Record<string, any> | undefined;
|
|
2895
|
-
fetchOptions?: FetchOptions | undefined;
|
|
2896
|
-
}> | undefined, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<better_auth_client_plugins.PublicKeyCredentialRequestOptionsJSON, {
|
|
2897
|
-
code?: string;
|
|
2898
|
-
message?: string;
|
|
2899
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
2900
|
-
};
|
|
2901
|
-
} & {
|
|
2902
|
-
passkey: {
|
|
2903
|
-
verifyRegistration: <FetchOptions extends {
|
|
2904
|
-
method?: string | undefined;
|
|
2905
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
2906
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
2907
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
2908
|
-
authorization: "Bearer" | "Basic";
|
|
2909
|
-
})) | undefined;
|
|
2910
|
-
cache?: RequestCache | undefined;
|
|
2911
|
-
credentials?: RequestCredentials | undefined;
|
|
2912
|
-
integrity?: string | undefined;
|
|
2913
|
-
keepalive?: boolean | undefined;
|
|
2914
|
-
mode?: RequestMode | undefined;
|
|
2915
|
-
priority?: RequestPriority | undefined;
|
|
2916
|
-
redirect?: RequestRedirect | undefined;
|
|
2917
|
-
referrer?: string | undefined;
|
|
2918
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
2919
|
-
signal?: (AbortSignal | null) | undefined;
|
|
2920
|
-
window?: null | undefined;
|
|
2921
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
2922
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
2923
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
2924
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
2925
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
2926
|
-
hookOptions?: {
|
|
2927
|
-
cloneResponse?: boolean;
|
|
2928
|
-
} | undefined;
|
|
2929
|
-
timeout?: number | undefined;
|
|
2930
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
2931
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
2932
|
-
baseURL?: string | undefined;
|
|
2933
|
-
throw?: boolean | undefined;
|
|
2934
|
-
auth?: ({
|
|
2935
|
-
type: "Bearer";
|
|
2936
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
2937
|
-
} | {
|
|
2938
|
-
type: "Basic";
|
|
2939
|
-
username: string | (() => string | undefined) | undefined;
|
|
2940
|
-
password: string | (() => string | undefined) | undefined;
|
|
2941
|
-
} | {
|
|
2942
|
-
type: "Custom";
|
|
2943
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
2944
|
-
value: string | (() => string | undefined) | undefined;
|
|
2945
|
-
}) | undefined;
|
|
2946
|
-
body?: (Partial<{
|
|
2947
|
-
response: any;
|
|
2948
|
-
name?: string | undefined;
|
|
2949
|
-
}> & Record<string, any>) | undefined;
|
|
2950
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
2951
|
-
params?: Record<string, any> | undefined;
|
|
2952
|
-
duplex?: "full" | "half" | undefined;
|
|
2953
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
2954
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
2955
|
-
retryAttempt?: number | undefined;
|
|
2956
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
2957
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
2958
|
-
disableValidation?: boolean | undefined;
|
|
2959
|
-
}>(data_0: better_auth.Prettify<{
|
|
2960
|
-
response: any;
|
|
2961
|
-
name?: string | undefined;
|
|
2962
|
-
} & {
|
|
2963
|
-
fetchOptions?: FetchOptions | undefined;
|
|
2964
|
-
}>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<better_auth_plugins_passkey.Passkey, {
|
|
2965
|
-
code?: string;
|
|
2966
|
-
message?: string;
|
|
2967
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
2968
|
-
};
|
|
2969
|
-
} & {
|
|
2970
|
-
passkey: {
|
|
2971
|
-
verifyAuthentication: <FetchOptions extends {
|
|
2972
|
-
method?: string | undefined;
|
|
2973
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
2974
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
2975
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
2976
|
-
authorization: "Bearer" | "Basic";
|
|
2977
|
-
})) | undefined;
|
|
2978
|
-
cache?: RequestCache | undefined;
|
|
2979
|
-
credentials?: RequestCredentials | undefined;
|
|
2980
|
-
integrity?: string | undefined;
|
|
2981
|
-
keepalive?: boolean | undefined;
|
|
2982
|
-
mode?: RequestMode | undefined;
|
|
2983
|
-
priority?: RequestPriority | undefined;
|
|
2984
|
-
redirect?: RequestRedirect | undefined;
|
|
2985
|
-
referrer?: string | undefined;
|
|
2986
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
2987
|
-
signal?: (AbortSignal | null) | undefined;
|
|
2988
|
-
window?: null | undefined;
|
|
2989
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
2990
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
2991
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
2992
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
2993
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
2994
|
-
hookOptions?: {
|
|
2995
|
-
cloneResponse?: boolean;
|
|
2996
|
-
} | undefined;
|
|
2997
|
-
timeout?: number | undefined;
|
|
2998
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
2999
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
3000
|
-
baseURL?: string | undefined;
|
|
3001
|
-
throw?: boolean | undefined;
|
|
3002
|
-
auth?: ({
|
|
3003
|
-
type: "Bearer";
|
|
3004
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
3005
|
-
} | {
|
|
3006
|
-
type: "Basic";
|
|
3007
|
-
username: string | (() => string | undefined) | undefined;
|
|
3008
|
-
password: string | (() => string | undefined) | undefined;
|
|
3009
|
-
} | {
|
|
3010
|
-
type: "Custom";
|
|
3011
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
3012
|
-
value: string | (() => string | undefined) | undefined;
|
|
3013
|
-
}) | undefined;
|
|
3014
|
-
body?: (Partial<{
|
|
3015
|
-
response: better_auth_client_plugins.AuthenticationResponseJSON;
|
|
3016
|
-
}> & Record<string, any>) | undefined;
|
|
3017
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
3018
|
-
params?: Record<string, any> | undefined;
|
|
3019
|
-
duplex?: "full" | "half" | undefined;
|
|
3020
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
3021
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
3022
|
-
retryAttempt?: number | undefined;
|
|
3023
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
3024
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
3025
|
-
disableValidation?: boolean | undefined;
|
|
3026
|
-
}>(data_0: better_auth.Prettify<{
|
|
3027
|
-
response: better_auth_client_plugins.AuthenticationResponseJSON;
|
|
3028
|
-
} & {
|
|
3029
|
-
fetchOptions?: FetchOptions | undefined;
|
|
3030
|
-
}>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<{
|
|
3031
|
-
session: {
|
|
3032
|
-
id: string;
|
|
3033
|
-
createdAt: Date;
|
|
3034
|
-
updatedAt: Date;
|
|
3035
|
-
userId: string;
|
|
3036
|
-
expiresAt: Date;
|
|
3037
|
-
token: string;
|
|
3038
|
-
ipAddress?: string | null | undefined;
|
|
3039
|
-
userAgent?: string | null | undefined;
|
|
3040
|
-
};
|
|
3041
|
-
}, {
|
|
3042
|
-
code?: string;
|
|
3043
|
-
message?: string;
|
|
3044
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
3045
|
-
};
|
|
3046
|
-
} & {
|
|
3047
|
-
passkey: {
|
|
3048
|
-
listUserPasskeys: <FetchOptions extends {
|
|
3049
|
-
method?: string | undefined;
|
|
3050
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
3051
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
3052
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
3053
|
-
authorization: "Bearer" | "Basic";
|
|
3054
|
-
})) | undefined;
|
|
3055
|
-
cache?: RequestCache | undefined;
|
|
3056
|
-
credentials?: RequestCredentials | undefined;
|
|
3057
|
-
integrity?: string | undefined;
|
|
3058
|
-
keepalive?: boolean | undefined;
|
|
3059
|
-
mode?: RequestMode | undefined;
|
|
3060
|
-
priority?: RequestPriority | undefined;
|
|
3061
|
-
redirect?: RequestRedirect | undefined;
|
|
3062
|
-
referrer?: string | undefined;
|
|
3063
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
3064
|
-
signal?: (AbortSignal | null) | undefined;
|
|
3065
|
-
window?: null | undefined;
|
|
3066
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
3067
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
3068
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
3069
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
3070
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
3071
|
-
hookOptions?: {
|
|
3072
|
-
cloneResponse?: boolean;
|
|
3073
|
-
} | undefined;
|
|
3074
|
-
timeout?: number | undefined;
|
|
3075
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
3076
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
3077
|
-
baseURL?: string | undefined;
|
|
3078
|
-
throw?: boolean | undefined;
|
|
3079
|
-
auth?: ({
|
|
3080
|
-
type: "Bearer";
|
|
3081
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
3082
|
-
} | {
|
|
3083
|
-
type: "Basic";
|
|
3084
|
-
username: string | (() => string | undefined) | undefined;
|
|
3085
|
-
password: string | (() => string | undefined) | undefined;
|
|
3086
|
-
} | {
|
|
3087
|
-
type: "Custom";
|
|
3088
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
3089
|
-
value: string | (() => string | undefined) | undefined;
|
|
3090
|
-
}) | undefined;
|
|
3091
|
-
body?: undefined;
|
|
3092
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
3093
|
-
params?: Record<string, any> | undefined;
|
|
3094
|
-
duplex?: "full" | "half" | undefined;
|
|
3095
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
3096
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
3097
|
-
retryAttempt?: number | undefined;
|
|
3098
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
3099
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
3100
|
-
disableValidation?: boolean | undefined;
|
|
3101
|
-
}>(data_0?: better_auth.Prettify<{
|
|
3102
|
-
query?: Record<string, any> | undefined;
|
|
3103
|
-
fetchOptions?: FetchOptions | undefined;
|
|
3104
|
-
}> | undefined, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<better_auth_plugins_passkey.Passkey[], {
|
|
3105
|
-
code?: string;
|
|
3106
|
-
message?: string;
|
|
3107
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
3108
|
-
};
|
|
3109
|
-
} & {
|
|
3110
|
-
passkey: {
|
|
3111
|
-
deletePasskey: <FetchOptions extends {
|
|
3112
|
-
method?: string | undefined;
|
|
3113
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
3114
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
3115
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
3116
|
-
authorization: "Bearer" | "Basic";
|
|
3117
|
-
})) | undefined;
|
|
3118
|
-
cache?: RequestCache | undefined;
|
|
3119
|
-
credentials?: RequestCredentials | undefined;
|
|
3120
|
-
integrity?: string | undefined;
|
|
3121
|
-
keepalive?: boolean | undefined;
|
|
3122
|
-
mode?: RequestMode | undefined;
|
|
3123
|
-
priority?: RequestPriority | undefined;
|
|
3124
|
-
redirect?: RequestRedirect | undefined;
|
|
3125
|
-
referrer?: string | undefined;
|
|
3126
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
3127
|
-
signal?: (AbortSignal | null) | undefined;
|
|
3128
|
-
window?: null | undefined;
|
|
3129
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
3130
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
3131
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
3132
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
3133
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
3134
|
-
hookOptions?: {
|
|
3135
|
-
cloneResponse?: boolean;
|
|
3136
|
-
} | undefined;
|
|
3137
|
-
timeout?: number | undefined;
|
|
3138
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
3139
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
3140
|
-
baseURL?: string | undefined;
|
|
3141
|
-
throw?: boolean | undefined;
|
|
3142
|
-
auth?: ({
|
|
3143
|
-
type: "Bearer";
|
|
3144
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
3145
|
-
} | {
|
|
3146
|
-
type: "Basic";
|
|
3147
|
-
username: string | (() => string | undefined) | undefined;
|
|
3148
|
-
password: string | (() => string | undefined) | undefined;
|
|
3149
|
-
} | {
|
|
3150
|
-
type: "Custom";
|
|
3151
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
3152
|
-
value: string | (() => string | undefined) | undefined;
|
|
3153
|
-
}) | undefined;
|
|
3154
|
-
body?: (Partial<{
|
|
3155
|
-
id: string;
|
|
3156
|
-
}> & Record<string, any>) | undefined;
|
|
3157
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
3158
|
-
params?: Record<string, any> | undefined;
|
|
3159
|
-
duplex?: "full" | "half" | undefined;
|
|
3160
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
3161
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
3162
|
-
retryAttempt?: number | undefined;
|
|
3163
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
3164
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
3165
|
-
disableValidation?: boolean | undefined;
|
|
3166
|
-
}>(data_0: better_auth.Prettify<{
|
|
3167
|
-
id: string;
|
|
3168
|
-
} & {
|
|
3169
|
-
fetchOptions?: FetchOptions | undefined;
|
|
3170
|
-
}>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<never, {
|
|
3171
|
-
code?: string;
|
|
3172
|
-
message?: string;
|
|
3173
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
3174
|
-
};
|
|
3175
|
-
} & {
|
|
3176
|
-
passkey: {
|
|
3177
|
-
updatePasskey: <FetchOptions extends {
|
|
3178
|
-
method?: string | undefined;
|
|
3179
|
-
headers?: (HeadersInit & (HeadersInit | {
|
|
3180
|
-
accept: "application/json" | "text/plain" | "application/octet-stream";
|
|
3181
|
-
"content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
|
|
3182
|
-
authorization: "Bearer" | "Basic";
|
|
3183
|
-
})) | undefined;
|
|
3184
|
-
cache?: RequestCache | undefined;
|
|
3185
|
-
credentials?: RequestCredentials | undefined;
|
|
3186
|
-
integrity?: string | undefined;
|
|
3187
|
-
keepalive?: boolean | undefined;
|
|
3188
|
-
mode?: RequestMode | undefined;
|
|
3189
|
-
priority?: RequestPriority | undefined;
|
|
3190
|
-
redirect?: RequestRedirect | undefined;
|
|
3191
|
-
referrer?: string | undefined;
|
|
3192
|
-
referrerPolicy?: ReferrerPolicy | undefined;
|
|
3193
|
-
signal?: (AbortSignal | null) | undefined;
|
|
3194
|
-
window?: null | undefined;
|
|
3195
|
-
onRequest?: (<T extends Record<string, any>>(context: _better_fetch_fetch.RequestContext<T>) => Promise<_better_fetch_fetch.RequestContext | void> | _better_fetch_fetch.RequestContext | void) | undefined;
|
|
3196
|
-
onResponse?: ((context: _better_fetch_fetch.ResponseContext) => Promise<Response | void | _better_fetch_fetch.ResponseContext> | Response | _better_fetch_fetch.ResponseContext | void) | undefined;
|
|
3197
|
-
onSuccess?: ((context: _better_fetch_fetch.SuccessContext<any>) => Promise<void> | void) | undefined;
|
|
3198
|
-
onError?: ((context: _better_fetch_fetch.ErrorContext) => Promise<void> | void) | undefined;
|
|
3199
|
-
onRetry?: ((response: _better_fetch_fetch.ResponseContext) => Promise<void> | void) | undefined;
|
|
3200
|
-
hookOptions?: {
|
|
3201
|
-
cloneResponse?: boolean;
|
|
3202
|
-
} | undefined;
|
|
3203
|
-
timeout?: number | undefined;
|
|
3204
|
-
customFetchImpl?: _better_fetch_fetch.FetchEsque | undefined;
|
|
3205
|
-
plugins?: _better_fetch_fetch.BetterFetchPlugin[] | undefined;
|
|
3206
|
-
baseURL?: string | undefined;
|
|
3207
|
-
throw?: boolean | undefined;
|
|
3208
|
-
auth?: ({
|
|
3209
|
-
type: "Bearer";
|
|
3210
|
-
token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
|
|
3211
|
-
} | {
|
|
3212
|
-
type: "Basic";
|
|
3213
|
-
username: string | (() => string | undefined) | undefined;
|
|
3214
|
-
password: string | (() => string | undefined) | undefined;
|
|
3215
|
-
} | {
|
|
3216
|
-
type: "Custom";
|
|
3217
|
-
prefix: string | (() => string | undefined) | undefined;
|
|
3218
|
-
value: string | (() => string | undefined) | undefined;
|
|
3219
|
-
}) | undefined;
|
|
3220
|
-
body?: (Partial<{
|
|
3221
|
-
id: string;
|
|
3222
|
-
name: string;
|
|
3223
|
-
}> & Record<string, any>) | undefined;
|
|
3224
|
-
query?: (Partial<Record<string, any>> & Record<string, any>) | undefined;
|
|
3225
|
-
params?: Record<string, any> | undefined;
|
|
3226
|
-
duplex?: "full" | "half" | undefined;
|
|
3227
|
-
jsonParser?: ((text: string) => Promise<any> | any) | undefined;
|
|
3228
|
-
retry?: _better_fetch_fetch.RetryOptions | undefined;
|
|
3229
|
-
retryAttempt?: number | undefined;
|
|
3230
|
-
output?: (_better_fetch_fetch.StandardSchemaV1 | typeof Blob | typeof File) | undefined;
|
|
3231
|
-
errorSchema?: _better_fetch_fetch.StandardSchemaV1 | undefined;
|
|
3232
|
-
disableValidation?: boolean | undefined;
|
|
3233
|
-
}>(data_0: better_auth.Prettify<{
|
|
3234
|
-
id: string;
|
|
3235
|
-
name: string;
|
|
3236
|
-
} & {
|
|
3237
|
-
fetchOptions?: FetchOptions | undefined;
|
|
3238
|
-
}>, data_1?: FetchOptions | undefined) => Promise<_better_fetch_fetch.BetterFetchResponse<{
|
|
3239
|
-
passkey: better_auth_plugins_passkey.Passkey;
|
|
3240
|
-
}, {
|
|
3241
|
-
code?: string;
|
|
3242
|
-
message?: string;
|
|
3243
|
-
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
3244
|
-
};
|
|
3245
2759
|
} & {
|
|
3246
2760
|
signIn: {
|
|
3247
2761
|
oauth2: <FetchOptions extends {
|
|
@@ -6606,60 +6120,6 @@ declare const authClient: {
|
|
|
6606
6120
|
message?: string;
|
|
6607
6121
|
}, FetchOptions["throw"] extends true ? true : false>>;
|
|
6608
6122
|
};
|
|
6609
|
-
} & {
|
|
6610
|
-
signIn: {
|
|
6611
|
-
passkey: (opts?: {
|
|
6612
|
-
autoFill?: boolean;
|
|
6613
|
-
fetchOptions?: _better_fetch_fetch.BetterFetchOption;
|
|
6614
|
-
}, options?: _better_fetch_fetch.BetterFetchOption) => Promise<{
|
|
6615
|
-
data: null;
|
|
6616
|
-
error: {
|
|
6617
|
-
message?: string | undefined;
|
|
6618
|
-
status: number;
|
|
6619
|
-
statusText: string;
|
|
6620
|
-
};
|
|
6621
|
-
} | {
|
|
6622
|
-
data: {
|
|
6623
|
-
session: inspector.Session;
|
|
6624
|
-
user: better_auth.User;
|
|
6625
|
-
};
|
|
6626
|
-
error: null;
|
|
6627
|
-
} | {
|
|
6628
|
-
data: null;
|
|
6629
|
-
error: {
|
|
6630
|
-
code: string;
|
|
6631
|
-
message: string;
|
|
6632
|
-
status: number;
|
|
6633
|
-
statusText: string;
|
|
6634
|
-
};
|
|
6635
|
-
}>;
|
|
6636
|
-
};
|
|
6637
|
-
passkey: {
|
|
6638
|
-
addPasskey: (opts?: {
|
|
6639
|
-
fetchOptions?: _better_fetch_fetch.BetterFetchOption;
|
|
6640
|
-
name?: string;
|
|
6641
|
-
authenticatorAttachment?: "platform" | "cross-platform";
|
|
6642
|
-
useAutoRegister?: boolean;
|
|
6643
|
-
}, fetchOpts?: _better_fetch_fetch.BetterFetchOption) => Promise<{
|
|
6644
|
-
data: null;
|
|
6645
|
-
error: {
|
|
6646
|
-
message?: string | undefined;
|
|
6647
|
-
status: number;
|
|
6648
|
-
statusText: string;
|
|
6649
|
-
};
|
|
6650
|
-
} | {
|
|
6651
|
-
data: null;
|
|
6652
|
-
error: {
|
|
6653
|
-
code: string;
|
|
6654
|
-
message: string;
|
|
6655
|
-
status: number;
|
|
6656
|
-
statusText: string;
|
|
6657
|
-
};
|
|
6658
|
-
} | undefined>;
|
|
6659
|
-
};
|
|
6660
|
-
$Infer: {
|
|
6661
|
-
Passkey: better_auth_plugins_passkey.Passkey;
|
|
6662
|
-
};
|
|
6663
6123
|
} & {
|
|
6664
6124
|
oneTap: (opts?: better_auth_client_plugins.GoogleOneTapActionOptions, fetchOptions?: _better_fetch_fetch.BetterFetchOption) => Promise<void>;
|
|
6665
6125
|
} & {
|
|
@@ -6900,7 +6360,17 @@ declare const authClient: {
|
|
|
6900
6360
|
USER_ALREADY_HAS_PASSWORD: string;
|
|
6901
6361
|
};
|
|
6902
6362
|
};
|
|
6903
|
-
type AuthClient = typeof authClient
|
|
6363
|
+
type AuthClient = typeof authClient & {
|
|
6364
|
+
passkey: {
|
|
6365
|
+
addPasskey: (opts?: any) => Promise<any>;
|
|
6366
|
+
deletePasskey: (opts?: any) => Promise<any>;
|
|
6367
|
+
};
|
|
6368
|
+
useListPasskeys: () => {
|
|
6369
|
+
data?: any[];
|
|
6370
|
+
isPending?: boolean;
|
|
6371
|
+
refetch?: () => void;
|
|
6372
|
+
};
|
|
6373
|
+
};
|
|
6904
6374
|
type Session = AuthClient["$Infer"]["Session"]["session"];
|
|
6905
6375
|
type User = AuthClient["$Infer"]["Session"]["user"];
|
|
6906
6376
|
|
|
@@ -6964,4 +6434,4 @@ type AuthHooks = {
|
|
|
6964
6434
|
useIsRestoring?: () => boolean;
|
|
6965
6435
|
};
|
|
6966
6436
|
|
|
6967
|
-
export {
|
|
6437
|
+
export type { AnyAuthClient as A, Invitation as I, Refetch as R, Session as S, User as U, AuthClient as a, AuthHooks as b };
|