Who it is forA developer whose app is built on one vendor's SDK and who wants to try or switch to a model from another vendor without rewriting the calls.
The problemEach vendor has its own API format, so switching models usually means changing client code.
The outcomeThe existing SDK keeps working unchanged and reaches a model from another vendor through the gateway's local endpoint.
What you need first
- Python with pip, or a Rust toolchain with cargo, or Docker
- An API key for at least one model vendor, such as OPENAI_API_KEY
- An existing app or SDK that accepts a custom base URL
- Optional: a Respan API key for tracing and a tool vendor key for MCP tools
Steps
- Install the gateway with
pip install respan-gateway. - Set a vendor key in your shell with
export OPENAI_API_KEY=sk-.... - Start the gateway by running
respan-gateway. - In your app, create the client with base_url set to http://localhost:8080 and call a model such as gpt-6-luna, as in the README example.
- Open http://localhost:8080/ui/ to confirm the request appears in the live log.
Prompt for your agent
In the respan-gateway repo, start the gateway with the OPENAI_API_KEY from the environment, then send one chat request through http://localhost:8080 using the Anthropic SDK with model <target-model>. Return the reply text, and verify that the request appears in the live log at localhost:8080/ui/.
Caveat. The gateway answers only on loopback unless client keys are configured, and it refuses to start on a public address without them.
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Disclaimer
Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked "Seen in the wild", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email [email protected] and we will look at it promptly. Full disclaimer page