Magpie Setup Guide: Import LumeCoder in One Click for Claude Code and Codex
Magpie is an open-source desktop app (with a terminal version) that runs a local gateway so agents such as Claude Code, Codex, Gemini CLI and OpenCode can share one set of providers. This guide shows how to import LumeCoder into Magpie: the dashboard one-click import first, then how to pick models for each agent, then troubleshooting.
1. What Magpie is
According to the Magpie website, it runs a gateway on your computer (127.0.0.1:3425) that speaks OpenAI Chat / Responses, Anthropic Messages and Google Gemini, and converts between them. That lets Codex (Responses only) and Claude Code (Messages only) both use models from other providers.
You add a provider once and then choose its models inside each agent. The site lists Claude Code, Codex, Gemini CLI, OpenCode, Pi, Hermes Agent and more.
The site describes it as free and open source, with macOS, Windows and Linux builds.
2. Prepare
- Download and install Magpie from usemagpie.ai. One-click import needs version 0.1.8 or newer.
- Install the command-line tool you want to use, such as Claude Code or Codex.
- Create an API key in the LumeCoder dashboard.
3. One-click import from the dashboard
On the API Keys page of the LumeCoder dashboard, each key has an "Import to Magpie" button. It imports the key as a provider, together with the models the key allows and a point-balance lookup.
Open the import dialog
Go to the API Keys page in the dashboard and click "Import to Magpie" next to the key.
Confirm the provider name
The default name is "LumeCoder · key name" and you can change it. Importing the same key again replaces the earlier entry instead of creating a duplicate; different keys do not overwrite each other.
Check endpoints and models
The dialog lists the endpoints and models this key can use. Claude models use Anthropic Messages, GPT models use OpenAI Responses.
Confirm in Magpie
The browser opens usemagpie.ai/import and launches Magpie. Magpie lists the name, the addresses your key will be sent to and the models. Nothing is saved until you click Add.
4. Pick models for each agent
Once the provider is added, choose models per agent in Magpie's UI or from the command line. Use the provider id shown in Magpie (generated per key at import time, shaped like lumecoder-xxxxxxxx).
# See which model each agent uses magpie ls # Point Claude Code at a Claude model from LumeCoder magpie claude <provider-id>/<model> # Point Codex at a GPT model magpie codex <provider-id>/<model>
Start a new session for the change to take effect. When you switch back to a native model, Magpie restores that agent's config (per its website). The models you can pick are the ones listed in the import dialog.
5. Add it by hand instead
You can also add a custom provider in Magpie and fill in the base URLs below. Use the full API key from the dashboard (starts with sk-).
| Protocol | Base URL | Notes |
|---|---|---|
| Anthropic Messages | https://api.lumecoder.com | Root URL, no /v1; for Claude models |
| OpenAI Responses | https://api.lumecoder.com/v1 | Ends in /v1; for GPT models, used by Codex |
Use model names LumeCoder supports; see the dashboard or the models page. LumeCoder currently has no Google models for Gemini, so the import does not include a Gemini endpoint.
6. Magpie or CC Switch
Both can bring LumeCoder into Claude Code and Codex, and the LumeCoder dashboard offers one-click import for both. Going by their own sites, Magpie runs a local protocol-converting gateway with intent routing, multi-account rotation and local redaction, while CC Switch focuses on managing each tool's provider config. If you only want LumeCoder configured in your tools, either works; if you need the gateway features, consider Magpie. CC Switch setup guide
7. FAQ
I clicked "Import to Magpie" and nothing happened, or I was sent to a download page
The browser did not launch Magpie. Make sure version 0.1.8 or newer is installed; if it is not, usemagpie.ai/import guides you to the download.
Can I see my point balance after importing?
Yes. The import link includes LumeCoder's balance endpoint, and Magpie queries it after you add the provider.
What happens if I import the same key again?
Magpie uses the provider id to tell providers apart. The id is fixed per key, so the button becomes Replace and no duplicate is created.
I get 401 or an authentication error
Check that the key is complete (starts with sk-, no extra spaces) and that it is not disabled or restricted.
Requests are rejected or I am told I am out of points
Check your point balance in the dashboard and confirm the model is allowed for this key.
Why are there no Gemini models?
LumeCoder's model catalog has no Google models right now, so the import does not include a Gemini endpoint.
