add server URL selection for Clara Companion authentication#2
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR updates the Clara Companion MCP bridge to allow users to choose which server URL to authenticate against, rather than defaulting to the cloud URL.
Changes
Clara Companion MCP Bridge
Updated backend/mcp-bridge/internal/commands/login.go to include a server URL selection prompt during authentication:
Added promptServerURL() function that presents users with two options:
Default - Uses the build-time configured URL (dev or prod)
Custom URL - Allows users to enter their own ClaraVerse server URL
The default URL is determined by the build-time DefaultBackendURL configuration
Custom URLs are automatically converted to WebSocket URLs for the MCP connection
Users can authenticate against self-hosted instances or the cloud service
Testing
Test the authentication flow:
bash
./clara-companion login
You will be prompted to choose between the default server or enter a custom URL.
Related Issues
N/A