Status: [UNTESTED] Endpoints found: http://localhost:8088/v1/chat/completions Source: https://github.com/steventong/codex-openai-proxy # Codex OpenAI Proxy A lightweight, self-hosted FastAPI proxy that exposes a standard OpenAI-compatible API (`/v1/chat/completions`) while managing multiple accounts, automatic token refresh, and session stickiness behind the scenes. > **Disclaimer:** This project is not affiliated with or endorsed by OpenAI. Use it responsibly and in accordance with OpenAI's Terms of Service. --- ## ✨ Features | Feature | Description | |---|---| | **Multi-account Pool** | Register multiple accounts; the proxy auto-rotates on `429` / `403` errors and places failing accounts in a cooldown queue. | | **Sticky Sessions** | Requests bearing the same `user` field or `x-session-id` header are pinned to the same account, maximising cache-hit rates. | | **Automatic Token Refresh** | A background daemon silently refreshes tokens every ~45 minutes, keeping the proxy alive 24/7 without manual intervention. | | **OAuth Login Flow** | Web admin panel supports one-click login via the official Auth0 PKCE flow — no manual token copying needed. | | **Reasoning Compat** | Translates private `reasoning` / `summary` stream events into standard `…` tags understood by most clients. | | **OpenAI-compatible API** | Drop-in replacement for `https://api.openai.com/v1`. Point any OpenAI SDK or tool at `http://localhost:8088/v1`. | | **Glassmorphism Admin UI** | Beautiful dark-mode web dashboard for managing accounts, monitoring status, and viewing live logs. | | **Docker-ready** | Single `docker compose up -d` to deploy. Cross-compiles to `linux/amd64` on Apple Silicon. | --- ## 🚀 Quick Start ### Option 1 — Local (Python) ```bash # 1. Install dependencies pip install -r requirements.txt # 2. Start the proxy python main.py # → Listening on http://0.0.0.0:8088 ``` Then open **http://localhost:8088/admin** in your browser to log in and manage accounts. ### Option 2 — Docker Compose ```bash docker compose up -d ``` The `data/` directory is mounted as a volume, so your a