Connect a provider
API keys for Anthropic, OpenAI, Gemini and the rest: where they go, where they are kept, and which model a session uses.
An API key connects Sylphyx to a provider. Requests go from your computer straight to that provider, which bills you at its own prices. Pick one to see the lines for it:
- Get a keyconsole.anthropic.com/settings/keys
- Keep it in the keychainor for one terminal only, in a variable:
sylphyx login anthropic$env:ANTHROPIC_API_KEY = "your key" - Use itwhich picks
sylphyx --model anthropicclaude-sonnet-5-5; name another asanthropic/MODEL.
All of them at a glance: the name you use in --model and /model, and the variable that can hold the key.
| Provider | Name | Key variable | Model when none is named |
|---|---|---|---|
| Anthropic | anthropic | ANTHROPIC_API_KEY | claude-sonnet-5-5 |
| OpenAI | openai | OPENAI_API_KEY | gpt-6.1-sol |
| OpenRouter | openrouter | OPENROUTER_API_KEY | anthropic/claude-sonnet-5.5 |
| Google Gemini | google | GEMINI_API_KEY | gemini-4-argon |
| xAI Grok | xai | XAI_API_KEY | grok-4.7 |
| DeepSeek | deepseek | DEEPSEEK_API_KEY | deepseek-flash |
| Mistral | mistral | MISTRAL_API_KEY | mistral-medium-latest |
| Groq | groq | GROQ_API_KEY | openai/gpt-oss-120b |
Settings (Ctrl+,), Connections, then API keys. Each provider has a line: paste the key into its field and press Enter. Get a key opens the provider's page for one, and Remove deletes a stored key. The badge beside the name says where the key comes from: "key in keychain", "key from environment" or "no key".
sylphyx login anthropicIt asks for the key without showing it, stores it, and checks it at once by asking the provider for its models: "The key works: … models to choose from", or "The provider did not accept the key", with the provider's reason. sylphyx logout anthropic removes it. Any name from the table works in place of anthropic.
/config and /settings do not take keys; they choose what to use with them. To make a model the default for every session:
/config model openai/gpt-6.1-sol- Windows: Credential Manager, as a generic credential named
sylphyx:anthropic(and so on), readable by your user only. - macOS: the login keychain. Linux: the desktop's Secret Service through
secret-tool, or, where there is none, a file only your user can read. - The settings file,
config.json, never holds a provider key. The app and the CLI share the same keys and settings.
The first of these that names one, top to bottom:
--modelfor this run onlySYLPHYX_MODELthe environment variablemodelin the settings/config model …saves it- The first provider with a keyin the table's order; a ChatGPT sign-in comes right after OpenAI
- A local server that answersLM Studio, then Ollama
Naming only a provider, as in --model groq, takes the model in the table's last column. sylphyx models shows what is connected; sylphyx models openai lists every model the key can use.