Commit Graph
3 Commits
Author SHA1 Message Date
yetone 35ebc94d58 provider: a preset's provider takes request headers of the user's own, and a preset can be added more than once (#50) — which workspace a key that reaches several is for (anthropic-workspace-id), or who the app is to OpenRouter, could only be said by a custom provider, so it meant giving up the preset's endpoints and catalog; the editor now shows headers for presets as well, offering the ones the vendor documents with their values left to fill in, and "Add another" makes one more provider of a preset under an id of its own (anthropic-2) where adding again replaced the first; the same key, host and headers twice is refused as the one already there, and importers keep a preset's headers and its preset when they split an entry off to a free id 2026-09-25 09:36:42 +08:00
jimyag 6b8e125df3 fix(provider): preserve Codex import headers (#46)
* fix(provider): preserve Codex import headers

Copy fixed Codex provider headers into imported providers, including entries that match a preset. Compare headers when detecting duplicates or merging keys so reimports and distinct relay accounts retain their request configuration.

Signed-off-by: jimyag <git@jimyag.com>

* fix(provider): keep Codex preset identity on import

Import fixed headers only for custom providers, matching the existing Alma importer and preset request-shape rule. Cover a preset-host Codex entry so its preset and header behavior remain explicit.

Signed-off-by: jimyag <git@jimyag.com>

* fix(provider): normalize headers before import comparison

Compare headers as they are stored so importing a Codex provider again does not report a duplicate when source values contain surrounding whitespace.

Signed-off-by: jimyag <git@jimyag.com>

* fix(gateway): retain Devin reply channel while awaiting

The response reader can delete a pending call before its caller looks up the channel, causing intermittent no such call errors. Return the reply channel from send so await can receive even after the reader removes the pending entry.

Signed-off-by: jimyag <git@jimyag.com>

* Revert "fix(gateway): retain Devin reply channel while awaiting"

This reverts commit 6278c793b9b4f45dc09106168269915007abffe5.

Signed-off-by: jimyag <git@jimyag.com>

---------

Signed-off-by: jimyag <git@jimyag.com>
2026-09-25 08:32:29 +08:00
jimyagandjimyag 00b173682f provider: Codex is one of the apps magpie imports providers from (#45)
Each [model_providers.<id>] table in ~/.codex/config.toml (or $CODEX_HOME) becomes a provider — its base_url, wire_api and bearer token, with the models the top level and the profiles pick for it and their model catalogs; magpie's own table and catalog are left out, as are sub-tables such as http_headers. Claude Code's settings are read from $CLAUDE_CONFIG_DIR when it is set.

Co-authored-by: jimyag <jimyag@users.noreply.github.com>
2026-09-25 07:31:30 +08:00