import type { BetterAuthOptions } from "better-auth"; export type CodemationAuthKind = "local" | "oauth" | "oidc" | "managed"; export type CodemationAuthOAuthProviderId = Extract< keyof NonNullable, "github" | "google" | "microsoft" >; export interface CodemationAuthOAuthProviderConfig { readonly provider: CodemationAuthOAuthProviderId; readonly clientIdEnv: string; readonly clientSecretEnv: string; readonly tenantIdEnv?: string; } export interface CodemationAuthOidcProviderConfig { readonly id: string; readonly issuer: string; readonly clientIdEnv: string; readonly clientSecretEnv: string; } export interface CodemationAuthConfig { readonly kind: CodemationAuthKind; readonly allowUnauthenticatedInDevelopment?: boolean; readonly oauth?: ReadonlyArray; readonly oidc?: ReadonlyArray; }