1,380 prompts from top AI collections
← Back to Market
[LIVE] [yhfgyyf/codex-api-server] 1 endpoint(s)
ChatGPT API Proxy/ChatGPT
2,120 characters
Status: [LIVE] Endpoints found: https://chatgpt.com/backend-api` Source: https://github.com/yhfgyyf/codex-api-server # Codex API Server [中文文档](README_CN.md) OpenAI API-compatible proxy server that uses ChatGPT Plus (Codex) OAuth credentials to provide standard `/v1/chat/completions`, `/v1/responses`, and Anthropic `/v1/messages` endpoints. ## Features - **OpenAI API compatible** — works with any OpenAI SDK, vLLM client, or tool - **Anthropic Messages API** — full `/v1/messages` support with `thinking` content blocks - **Reasoning model support** — streams `reasoning_content` (thinking process) in DeepSeek/vLLM format - **Function calling** — full tool/function calling support with streaming tool_calls - **Auto token refresh** — reads `~/.codex/auth.json`, refreshes OAuth tokens before expiry - **Streaming SSE** — full Server-Sent Events support for all endpoints - **Responses API** — proxy passthrough for OpenAI's `/v1/responses` endpoint - **vLLM parameter compatible** — accepts all OpenAI/vLLM params, silently ignores unsupported ones - **Request logging** — all API calls stored in SQLite with full request/response data - **JSONL export** — download or export logs for analysis and fine-tuning - **Async & connection pooling** — built on FastAPI + httpx for high concurrency ## Supported Models - `gpt-5.5` - `gpt-5.4` - `gpt-5.4-mini` - `gpt-5.3-codex` - `gpt-5.3-codex-spark` - `gpt-image-2` ## Prerequisites - Python 3.11+ - A valid `~/.codex/auth.json` file with ChatGPT OAuth credentials (from [OpenAI Codex CLI](https://github.com/openai/codex)) ## Installation ```bash # Create conda environment conda create -n codex-api-server python=3.11 -y conda activate codex-api-server # Install dependencies pip install -r requirements.txt ``` ## Quick Start ```bash conda activate codex-api-server python server.py ``` The server starts on `http://127.0.0.1:18888` by default. ## Usage ### With curl ```bash # List models curl http://localhost:18888/v1/models # Chat completion curl http://localhost:18888/v1/chat/completions \ -H "Content-Type: ap
Download .txt