How find-xposed-magisk/chatgpt-web works
Project type and purpose
• This is a full-stack web application (“ChatGPT Web”) split into a Vue3-based frontend (under /src) and a Node.js/TypeScript backend service (under /service).
• It serves a single-page application that lets users chat with ChatGPT via two interchangeable methods: the official OpenAI API or an unofficial proxy.
File structure
• Top-level:
• src/ – Vue3 SPA (Vite, Pinia, Router, NaiveUI)
• service/ – Node.js HTTP service (TS entry, middleware for auth & rate limiting, ChatGPT adapter modules)
• docker-compose/, kubernetes/ – deployment manifests and reverse-proxy (Nginx) configs
• CI/CD: .github/workflows/*.yml
• Config & tooling: Dockerfile, tsconfig.json, Vite config, eslint, husky, pnpm lockfiles
• No traditional database directory: session/context state is managed in-memory or client-side (localStorage).
README for additional insights
• Dual-model support (official vs proxy API)
• ENV‐driven configuration for OpenAI keys, proxies, rate limits, auth secret
• Packaging targets: standalone Docker image, Docker Compose with optional Nginx anti-crawler, Railway, Sealos, or manual build.
Essential architectural elements
• Don’t omit middleware (auth, rate limiter) – they enforce security & quotas.
• Both API methods to ChatGPT (official vs proxy) as parallel or conditional flows.
• CI/CD and deployment infra to show how changes propagate from code to running service.