CodexManager — local desktop and service-process Codex account pool manager
Website · Sponsors
中文
English
Русский
한국어
GitHub Stars
AtomGit Stars
Gitee Stars
Community  LINUX DO   Xuanwu Community

CodexManager has joined the Xuanwu Community, a Rust technical community incubated and operated by the OpenAtom Foundation.

Source Code Note
This product was built under my direction with AI: Codex (98%) and Gemini (2%). If you encounter a problem, please communicate respectfully. I do not have enough environments to validate every package and can guarantee only the Windows desktop build. For other platforms, test thoroughly before opening an Issue. Thank you to everyone who reports platform-specific problems and helps with testing.
Disclaimer
This project is intended solely for learning and development; users must comply with the terms of service of the relevant platforms, including OpenAI and Anthropic; the author does not provide or distribute accounts, API keys, or proxy services and is not responsible for specific uses of this software; do not use this project to circumvent rate limits or service restrictions.

Sponsors

This project is open to sponsorship partnerships, with pricing negotiable. Sponsors may display their brand logo, introduction, and official link in the README and in-project sponsor areas. Exact wording, placement, display period, and launch time are agreed upon by both parties. Partnerships should be relevant to developers or the AI tooling ecosystem and comply with applicable laws and regulations.

Partnership contact: Reach out via WeChat, Telegram, or email at 18272669457@163.com; when adding on WeChat, please note “Sponsorship”.

Thanks to the following friends and partners for supporting CodexManager.

PatewayAI official high-quality model API relay service

Thanks to PatewayAI for sponsoring this project!

PatewayAI focuses on high-quality official model API relay services, with full support for Claude and Codex series models, transparent billing, and enterprise-grade service.

Economy mode starts as low as 5% of standard rates. Register through this link to receive trial credits, join occasional promotions for free credits, and earn up to $150 in two-way referral rewards.


VMCard VMCard enterprise virtual card issuing platform provides dedicated U.S. Visa BINs, API-based bulk card issuance, and enterprise card management for AI account platforms, AI API providers, and subscription teams operating at scale.
It offers highly competitive settlement rates for long-term, large-scale corporate payments. Business contact: @Vmcardio_yuki
88API 88API all-model aggregation platform
🧠 Language and coding models including GPT, Claude, Gemini, Grok, DeepSeek, Kimi, and GLM;
🎨 Image models including GPT-Image, Gemini, and Grok;
🎬 Video models including Seedance, Veo, MiniMax Hailuo H3, Kling, and Grok;
🎙️ Voice capabilities including Whisper and TTS, covering copywriting, image generation and editing, video generation, and voice-over.
🎁 New users receive trial credits for testing model capabilities, with human support available on the site.
👉 Operated by an overseas registered business, with formal invoices and a 1:1 top-up ratio.
FennoAI FennoAI provides highly stable, high-performance API relay services for enterprise R&D teams and developers. It supports OpenAI and Anthropic protocols and integrates with Codex, Claude Code, OpenCode, and other mainstream AI coding tools. Its enterprise-grade infrastructure supports hundreds of billions of tokens per day plus business settlement and invoicing. Codex-Manager users can purchase a $50 Coding Plan allowance for only $1.99 through the exclusive link; referral commission can reach 20%.
Qiniu Cloud AI Qiniu Cloud AI is an enterprise large-model MaaS platform from Qiniu Cloud (02567.HK), offering one-stop access to more than 150 mainstream global models across text, image, audio, video, and file processing. Through the exclusive link, Codex-Manager enterprise users can receive 12 million tokens free, while developers can receive 3 million tokens free.
AI夏末 AIXiamo AIXiamo official site | Legitimate ChatGPT Plus / Pro top-ups for your own account in China
Not enough Codex allowance—Plus or Pro? Choose Plus for everyday use; compare Pro 5x / 20x for frequent limits or long, intensive tasks.
Sponsor guide: 2026 guide to ChatGPT Plus / Pro top-ups and plan selection in China
Supports Alipay without an overseas bank card; never asks for passwords, verification codes, or recovery codes. Orders are traceable, Chinese support is available, and failed top-ups are fully refunded after verification. Claude Pro / Max, Gemini, Grok / SuperGrok, and other memberships are also available.
Enterprise purchasing is welcome. Completed orders can apply for an invoice after confirming with support.
Xing Si Yan Gateway Xing Si Yan Gateway provides stable relay and supporting services for Claude Code, Codex, and similar model-call scenarios. It suits developers and teams requiring highly available APIs, convenient onboarding, and continuous delivery support. Visit the official site for current plans.

Other supporters: 呆头呆脑, Wonderdch, suxinwl, Hermit, Suifeng023, HK-hub

☕ Support the Project

If this project has helped you, donations are welcome!

Alipay WeChat Pay
Alipay donation QR code WeChat Pay donation QR code

Star History

Codex Manager Star History Chart

Home Navigation

What you want to do Go directly to
First launch, deployment, Docker, or macOS allowlisting Runtime and Deployment Guide
Configure Codex CLI / ccswitch, auth.json, and config.toml Runtime and Deployment Guide
Import an account from ChatGPT /api/auth/session without logging in through Codex Chinese guide: Import ChatGPT auth session
Configure ports, proxy, database, Web password, and environment variables Environment and Runtime Configuration
Troubleshoot account routing, import failures, challenge interception, or request errors FAQ and Account Routing Rules
Understand why background jobs skip, disable, or deactivate accounts Background Task Account Skip Notes
Manage models, pricing, routes, instructions policy, and local cache exports Chinese guide: Model Catalog V2 Management and Billing
Minimal plugin center integration and quick onboarding Plugin Center Minimal Integration
Integrate with the plugin center, view interfaces, marketplace modes, and Rhai APIs Plugin Center Integration and Interfaces
View every internal integration interface System Internal Interface Inventory
Build, package, release, or call scripts locally Build, Release, and Script Guide

Feature Overview

  • Account pool management: groups, tags, ordering, notes, ban recognition, and ban filtering.
  • Batch import/export: multi-file import, recursive JSON folder import on desktop, and per-account single-file export.
  • Usage display: standard 5-hour + 7-day windows, 7-day-only accounts, and official additional buckets such as Code Review / Spark; refresh shows remaining percentages and reset times consistently.
  • Account authorization: chatgpt.com browser OAuth and Device Code login; browser OAuth also supports manually pasting the callback URL.
  • Platform keys: random or custom fixed keys, disabling, deletion, model binding, reasoning tier, and service tier (follow request / Standard / Fast / Ultrafast / Flex). Keys can be bound to custom account groups and intersected with plan filters so rotation stays inside the authorized pool.
  • Model management: Model Catalog V2 is the sole runtime source of truth. It supports builtin/custom models, integer three-tier and long-context pricing, account-pool and aggregate-API routes, instructions policy, local JSON preview/commit, and proactive Codex cache export from desktop and Web.
  • Aggregate API: manage minimal third-party upstreams, including create, edit, balance, and connectivity tests against configured V2 routes. It does not auto-discover provider models; administrators fetch and selectively link models to Catalog V2.
  • Plugin center: /plugins/ supports built-in curated, enterprise private, and custom source marketplace modes, plus manifests, tasks, logs, and Rhai interfaces.
  • Skills and plugins: /skills/ separates Skills Installation from Codex Plugin Installation. It supports GitHub repositories, skills.sh search, ZIP/directory import, installed-item management, and the native Marketplace plugin flow; .system Skills remain read-only.
  • Desktop project launcher: bookmark local directories; Windows and macOS open them in the ChatGPT Codex App, while Sessions opens the resume selector in a new terminal with the local CodexManager profile.
  • Settings: includes system-derived settings, per-account concurrency, upstream proxy, total and stream-idle timeouts, SSE keepalive, and conservative high-concurrency degradation. Disable keepalive with CODEXMANAGER_SSE_KEEPALIVE_ENABLED=0; enable experimental upstream WebSocket with CODEXMANAGER_USE_WEBSOCKET_UPSTREAM=1.
  • System internal interface inventory: all desktop/service commands, RPC methods, and built-in plugin functions.
  • Local service: automatic startup with configurable port and listen address.
  • Local gateway: one OpenAI-compatible endpoint for Codex CLI, Gemini CLI, Claude Code, and third-party tools; supports Gemini to /v1/responses, SSE, tools, MCP, skills, and request/stream timeouts.
  • Image generation: injects the official Codex image_generation tool for /v1/responses by default and provides /v1/images/generations and /v1/images/edits; the default model is gpt-image-2.

Screenshots

Dashboard Account Management Platform Key Aggregate API Plugin Center Log View Settings

Quick Start

  1. Launch the desktop app and click Start Service.
  2. Open Account Management and choose browser authorization or Device Code login for chatgpt.com.
  3. If the browser callback fails, paste the callback URL to complete parsing manually.
  4. Refresh usage and verify account status.

Default Data Directory

  • The desktop app stores its SQLite database in the application data directory as codexmanager.db.
  • Windows: %APPDATA%\\com.codexmanager.desktop\\codexmanager.db
  • macOS: ~/Library/Application Support/com.codexmanager.desktop/codexmanager.db
  • Linux: ~/.local/share/com.codexmanager.desktop/codexmanager.db
  • Before first initialization after an upgrade, a codexmanager.db.pre-<version>.bak snapshot is retained in the same directory; retries for the same version do not overwrite it.
  • Desktop Diagnostics can enable Debug mode, disable ordinary file logs, and open the log directory. Runtime logs are capped at 512 KB; request logs and token/cost statistics are unaffected.
  • If the UI cannot start, use CodexManager.exe --debug (CodexManager --debug on macOS/Linux). Startup failures display the reason and write startup-error.log to the shown log directory.
  • For database, proxy, listen-address, and other settings, see Environment and Runtime Configuration.
  • Docker defaults to TZ=Asia/Shanghai; Compose inherits the deployment TZ or falls back to Asia/Shanghai. Use the appropriate IANA time zone elsewhere.

Product Views

Desktop

  • Account Management: import, export, refresh accounts and usage, with low-quota/ban filters and reset times.
  • Platform Key: bind keys by model, reasoning tier, and service tier, and inspect request logs.
  • Model Management: desktop and Web do not write or download ~/.codex/models_cache.json; direct accounts follow the official catalog, while the local gateway uses an independent managed catalog.
  • Plugin Center: /plugins/ provides marketplace switching, installation, enable/disable, tasks, logs, and Rhai integration.
  • Skills and Plugins: /skills/ separates Skills and Codex plugins, with repository/skills.sh install, ZIP/directory import, safe uninstall, native Marketplace flow, and read-only system Skills.
  • Project Launcher: desktop bookmarks local folders; Windows/macOS open them in the ChatGPT Codex App, Sessions uses the local CLI, and Web/Docker do not access device directories.
  • Settings: manage port, listen address, proxy, timeouts, SSE keepalive, theme, updates, and background behavior.

Service Edition

  • codexmanager-service: local OpenAI-compatible gateway.
  • codexmanager-web: browser management page plus /api/runtime and /api/rpc proxies.
  • codexmanager-start: starts service + web together.

Common Documentation

Topic Pages

Page Contents
Runtime and Deployment Guide First launch, Docker, Service edition, and macOS allowlisting
Environment and Runtime Configuration Application settings, proxy, listen address, database, and Web security
FAQ and Account Routing Rules Account routing, challenge interception, import/export, and common errors
Chinese guide: Import ChatGPT auth session Copy ChatGPT session JSON and batch-import it into the account pool
Background Task Account Skip Notes Background filtering, disabled accounts, and workspace deactivation
Minimal Troubleshooting Guide Service startup, request forwarding, and model refresh failures
Plugin Center Integration and Interfaces Routes, marketplace modes, Tauri/RPC interfaces, manifest fields, and Rhai functions
Build, Release, and Script Guide Local builds, Tauri packaging, workflows, and script parameters
Release and Artifacts Platform artifacts, naming, and pre-release behavior
Script and Release Responsibility Matrix Script responsibilities and usage scenarios
Gateway vs Codex Headers and Params Gateway forwarding compared with Codex headers and parameters
System Internal Interface Inventory Desktop, service, and plugin-center interfaces
CHANGELOG.md Releases, unreleased changes, and full history

Directory Structure

.
├─ apps/                # Frontend and Tauri desktop app
│  ├─ src/
│  ├─ src-tauri/
│  └─ out/
├─ crates/              # Rust core/service
│  ├─ core
│  ├─ service
│  ├─ start              # Starts service + web
│  └─ web                # Service Web UI and /api/rpc proxy
├─ docs/                # Official documentation
├─ scripts/             # Build and release scripts
└─ README.md

Acknowledgements and Reference Projects

Contact

  • WeChat public account: 七线牛马
  • WeChat: add ProsperGao to join the group and state your purpose
  • Telegram group: CodexManager TG group