gitmyhub

CodexSwitch

C# ★ 124 updated 8d ago

A desktop app that lets OpenAI Codex talk to different AI providers like Anthropic or DeepSeek through a local proxy you control.

C#Avalonia.NETsetup: moderatecomplexity 2/5

CodexSwitch is a desktop application for Windows, macOS, and Linux that acts as a local routing layer between OpenAI Codex (an AI coding agent) and various AI providers. The problem it solves is that Codex normally only talks to one AI service, but developers may want to use different AI providers such as OpenAI, Anthropic (Claude), DeepSeek, or others depending on cost, availability, or capability.

CodexSwitch runs a small proxy server on your own computer at a local address. Codex is configured to send its requests to this local proxy instead of directly to the cloud. The proxy then selects the right AI provider based on the model requested, translates the request format if necessary (since different providers use different API formats), and forwards it. For example, if you ask for a Claude model, it converts the OpenAI-style request that Codex sends into Anthropic's format, sends it to Anthropic's servers, and converts the response back into the format Codex expects. It also records a local log of all requests, how many tokens were used, and the estimated cost.

The desktop interface, built with Avalonia (a cross-platform UI framework for .NET applications written in C#), lets you switch the active provider with one click, manage API keys, view usage statistics over 24 hours, 7 days, and 30 days, and customize which model names map to which upstream providers. You would use this if you run the Codex agent and want to control costs, swap providers without reconfiguring Codex, or track your AI usage locally.

Where it fits