import { apiKeyClient } from '@better-auth/api-key/client'; import { passkeyClient } from '@better-auth/passkey/client'; import { magicLinkClient, multiSessionClient, organizationClient, usernameClient } from 'better-auth/client/plugins'; import { createAuthClient } from 'better-auth/react'; export type AuthClient = ReturnType; export type MagicLinkAuthClient = ReturnType]; }>>; export type MultiSessionAuthClient = ReturnType]; }>>; export type PasskeyAuthClient = ReturnType]; }>>; export type ApiKeyAuthClient = ReturnType]; }>>; export type UsernameAuthClient = ReturnType]; }>>; export type OrganizationAuthClient = ReturnType>]; }>>; /** * Unwraps a Better Auth client method's `data` payload. * * Pass the method type directly, e.g. `TAuthClient["getSession"]` or * `TAuthClient["passkey"]["listUserPasskeys"]`. Keeping it method-typed * (instead of a path-string utility) preserves IntelliSense on the derived * types. */ export type InferData = TMethod extends (...args: infer _Args) => Promise ? TResult["data"] : never;