import { logger } from "../util/logger.js"; import { BaseService } from "./BaseService.js"; import { AuthServiceState } from "./types.js"; /** * Service for managing authentication state. * Hub/WorkOS auth has been removed - this is a minimal stub that always * reports unauthenticated. */ export class AuthService extends BaseService { constructor() { super("AuthService", { authConfig: null, isAuthenticated: false, }); } async doInitialize(): Promise { const state: AuthServiceState = { authConfig: null, isAuthenticated: false, }; logger.debug("AuthService initialized (no auth)"); return state; } async login(): Promise { throw new Error( "Login is not available. Hub authentication has been removed.", ); } async logout(): Promise { logger.debug("Logout (no-op)"); return this.getState(); } async ensureOrganization( _isHeadless: boolean = false, _cliOrganizationSlug?: string, ): Promise { return this.getState(); } async switchOrganization( _organizationId: string | null, ): Promise { return this.getState(); } async getAvailableOrganizations(): Promise { return null; } async hasMultipleOrganizations(): Promise { return false; } async refresh(): Promise { return this.reload(); } }