whatisgithub

What is oc-codex?

angusdevgo/oc-codex — explained in plain English

Analysis updated 2026-05-18

30PowerShellAudience · developerComplexity · 2/5Setup · easy

In one sentence

A Windows tool that switches Codex between an official account login and an API relay service without losing local chat history.

Mindmap

mindmap
  root((repo))
    What it does
      Switches Codex login mode
      Backs up local config
      Resyncs chat history metadata
    Tech stack
      PowerShell
      Windows GUI launcher
    Use cases
      Move to API relay after quota runs out
      Return to official OAuth login
      Keep chat history visible across modes
    Audience
      Codex Desktop users
    Safety
      Local only, no uploads
      Automatic backups before switching

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Switch Codex Desktop from an official OAuth login to a CPAMC API relay when the account quota runs out.

USE CASE 2

Switch back to an official OpenAI account login without losing existing projects and chats.

USE CASE 3

Automatically back up Codex configuration and chat history before changing login modes.

USE CASE 4

Keep two separate Codex configuration files ready and swap between them with one click.

What is it built with?

PowerShellWindows

How does it compare?

angusdevgo/oc-codexrefrainwww/codex-windows-computer-usezy-zmc/tianming-skill
Stars303127
LanguagePowerShellPowerShellPowerShell
Setup difficultyeasymoderatehard
Complexity2/53/53/5
Audiencedeveloperdeveloperwriter

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 30min

Requires closing Codex Desktop before switching modes for a stable result.

The repository includes a LICENSE file that governs use of the project.

So what is it?

O-C is a Windows desktop tool that helps people switch back and forth between two ways of using Codex, OpenAI's coding assistant: signing in with an official ChatGPT or OpenAI account, or connecting through a third party API relay service the README calls CPAMC. Many users rely on both at different times, using the official account until its usage limit runs out, then switching to the API relay to keep working, and switching back later. The problem is that Codex Desktop stores local chat history, project sidebar entries, and account state in a folder on your computer, but the two login methods use different internal provider identifiers, so switching between them can make your existing chats and projects appear to vanish from the sidebar even though nothing was actually deleted. O-C solves this by automating the whole switch. Before changing anything, it backs up your current Codex configuration, account cache, and chat history metadata. It then writes in the configuration file that matches the mode you are switching to, removes authentication files that are incompatible with the new mode, and resyncs your local chat history's provider metadata so old conversations reappear under the new mode. You manage two separate configuration files, one for the official login and one for the API relay, and O-C switches between them with a single click through its graphical interface, so you never have to edit configuration files by hand. The tool keeps timestamped backups in folders it creates for you, split into categories such as switch related backups, chat history sync backups, and general safety backups made during cleanup or upgrades. The README states plainly that O-C works only on your own machine and never uploads your configuration, account cache, API keys, or chat history anywhere, and that it cannot recover chat history that has already been deleted, only keep existing history visible across mode switches. It does not provide or sell OpenAI accounts, CPAMC accounts, API keys, or any third party service quota itself.

Copy-paste prompts

Prompt 1
Explain how switching Codex login modes can make old chat history disappear from the sidebar.
Prompt 2
Walk me through setting up my official OAuth config.toml and CPAMC config.toml for this tool.
Prompt 3
Show me what O-C backs up before it switches modes and where those backups are stored.
Prompt 4
Help me recover from a failed mode switch using O-C's backup folders.

Frequently asked questions

What is oc-codex?

A Windows tool that switches Codex between an official account login and an API relay service without losing local chat history.

What language is oc-codex written in?

Mainly PowerShell. The stack also includes PowerShell, Windows.

What license does oc-codex use?

The repository includes a LICENSE file that governs use of the project.

How hard is oc-codex to set up?

Setup difficulty is rated easy, with roughly 30min to a first successful run.

Who is oc-codex for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.