This project wraps the Google Gemini web interface into an OpenAI-compatible API, allowing developers to use Gemini models with tools expecting the OpenAI API format. It emphasizes ease of use with zero authentication, cross-platform compatibility, and a single-file deployment. The core value is bridging Gemini's capabilities with existing OpenAI-centric ecosystems.
A starter prompt for Claude Code, what you'll need, and how to reach them.
You are an expert full-stack developer. Build a web application using Next.js 16 App Router, React 19, Tailwind v4, and Neon Postgres on Vercel. The core functionality is to act as a proxy for the Google Gemini web interface, converting incoming requests formatted for the OpenAI Chat Completions API into requests that interact with the Gemini web UI. For the MVP, focus on implementing the `/v1/chat/completions` endpoint. Use a headless browser library like Playwright or Puppeteer to programmatically control the Gemini web interface, send user prompts, extract Gemini's response, and format it back into an OpenAI-compatible JSON response. Ensure the application can be deployed as a single file or a minimal set of files. Start by setting up the project, then create the API route structure, and finally implement the headless browser interaction and response mapping. The build/verify gate is a successful API call from an OpenAI client (e.g., `openai-python` library) to your local proxy, returning a valid Gemini response.
Reach out to developers integrating AI models who are looking for alternatives to OpenAI, promoting how Lumivara's MCP server starter and agent evaluation tools can leverage this OpenAI-compatible Gemini API.
Convert Google Gemini web into OpenAI-compatible API. Zero auth, cross-platform, single file.
Open a pull request on the GitHub repository `Sophomoresty/gemini-web2api` with a feature improvement or an issue detailing a bug fix.
“I've been impressed by your `gemini-web2api` project and built a robust, Next.js-based version with better resilience to UI changes. I'd love to contribute it as an alternative implementation or discuss potential improvements for your project.”
Open the original ↗