import { createAuthClient } from 'better-auth/react';
import { adminClient, genericOAuthClient } from 'better-auth/client/plugins';

// The gateway and BetterAuth client both use /api/auth. Omitting baseURL keeps
// every browser request on the current origin in development and production.
export const authClient = createAuthClient({
  plugins: [adminClient(), genericOAuthClient()],
});

export const { useSession, signIn, signUp, signOut } = authClient;
