Skip to content

Add quick access to API key URLs via Tab key in settings - #24

Merged
brianlovin merged 3 commits into
mainfrom
claude/add-api-key-links-2faqv
Jan 26, 2026
Merged

Add quick access to API key URLs via Tab key in settings#24
brianlovin merged 3 commits into
mainfrom
claude/add-api-key-links-2faqv

Conversation

@brianlovin

Copy link
Copy Markdown
Owner

Summary

Added functionality to quickly open API key registration URLs directly from the settings panel. When a user selects a provider that doesn't have an API key configured, pressing Tab will open the appropriate provider's API key page.

Key Changes

  • Added getSelectedProviderUrl() function to SettingsPanel that returns the API key URL for the currently selected provider if it lacks a configured key
  • Integrated Tab key handler in the main app to detect when a provider without a key is selected and trigger the onOpenUrl callback
  • Updated settings panel UI to display the API key URL and hint that Tab can be used to open it
  • Changed hint text from generic "Add API Key" to show the actual provider URL (e.g., "console.anthropic.com (tab)")
  • Updated hint color to use textTertiary for better visual hierarchy

Implementation Details

  • The feature only activates when a provider item is selected that doesn't have a key configured
  • Returns null if the selection is not a provider or if the provider already has a key configured
  • Supports both Anthropic (console.anthropic.com) and OpenAI (platform.openai.com) providers
  • Uses the existing onOpenUrl callback mechanism for opening URLs

claude and others added 3 commits January 26, 2026 12:55
When no API key is configured, display the provider's console URL
(console.anthropic.com or platform.openai.com) next to the provider name.
Pressing Tab on a provider without a key opens the URL in the browser.
- Update Anthropic URL to platform.claude.com/settings/keys
- Update OpenAI URL to platform.openai.com/api-keys
- Extract provider URLs to shared PROVIDER_API_KEY_URLS constant
- Add tests for getSelectedProviderUrl function

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@brianlovin
brianlovin merged commit 3fd43dc into main Jan 26, 2026
1 check passed
@brianlovin
brianlovin deleted the claude/add-api-key-links-2faqv branch January 26, 2026 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants