8 months ago
9c7f4d7Refactor provider authentication logic into a new ProviderAuthManager class (src/server/session/ProviderAuthManager.ts). Moved handling for setModel, authorizeProviderAuth, callbackProviderAuth, and setProviderApiKey out of AgentSession and delegate to the new manager. Wire ProviderAuthManager into AgentSession (new property, constructor wiring and delegation). Adjust runProviderConnect signature to accept the connectModelProvider parameter shape and use provided paths/cwd/oauthStdioMode defaults. Add emitConfigUpdated helper in AgentSession and update imports accordingly.
Parent9268dd6