Expose Google's Gemini models as OpenAI-compatible API endpoints using Cloudflare Workers and OAuth2 authentication.
Gemini CLI OpenAI Worker is a serverless adapter that exposes Google's Gemini AI models through an OpenAI-compatible API. It solves the problem of integrating Gemini models into applications and tools designed for the OpenAI API by providing a translation layer that handles authentication, request formatting, and response streaming. Developers can deploy it on Cloudflare Workers to create their own gateway to Gemini's capabilities.
Developers and teams building AI-powered applications who want to use Google's Gemini models but need compatibility with the OpenAI API ecosystem, including tools like Open WebUI, Cline, and various AI client libraries.
It offers a free, self-hostable alternative to proprietary API gateways, leveraging Google's free tier access via the Code Assist API. The unique OAuth2 authentication method removes the need for traditional API keys, and its deployment on Cloudflare Workers ensures global edge performance with minimal setup.
Expose Gemini CLI endpoints as OpenAI API with Cloudflare Workers
Eliminates API key management by using Google account credentials via the Gemini CLI, as outlined in the setup requiring OAuth2 tokens from a local credentials file.
Acts as a drop-in replacement for OpenAI endpoints, supporting chat completions, streaming, and tool calling, enabling compatibility with tools like Open WebUI and Cline without code changes.
Provides access to Gemini's latest models with vision support, reasoning capabilities, and automatic fallback between Pro and Flash variants, detailed in the supported models and thinking configuration sections.
Deploys on Cloudflare Workers for global low-latency access, with smart token caching via KV storage to optimize OAuth2 token efficiency and reduce authentication overhead.
Requires multiple steps: installing Gemini CLI for OAuth2 credentials, creating Cloudflare KV namespaces, and configuring environment variables, which can be time-consuming and error-prone for quick deployments.
Relies on Google's Code Assist API with potential usage limits and policy compliance issues, and authentication is tied to Google accounts, limiting flexibility for non-Google users.
Designed specifically for Cloudflare Workers, making it difficult to port to other serverless platforms without significant code changes, as noted in the deployment prerequisites.
Numerous environment variables for thinking modes, safety thresholds, and tool integrations add complexity, and the README warns that misconfiguration can lead to authentication errors or public API exposure.
Gemini CLI to API Proxy is a FastAPI-based server that converts the Gemini CLI tool into standard API endpoints. It enables developers to use Google's free Gemini API quota through familiar OpenAI API interfaces or direct Gemini API calls, making it simple to integrate Gemini capabilities into existing applications. ## Key Features - **OpenAI-Compatible API** — Drop-in replacement for OpenAI's chat completions API, allowing seamless integration with tools expecting OpenAI's format. - **Native Gemini API** — Direct proxy to Google's Gemini API, supporting all its endpoints and features. - **Streaming Support** — Real-time streaming responses for both API formats, enabling interactive applications. - **Multimodal Support** — Handles text and image inputs, leveraging Gemini's multimodal capabilities. - **Authentication Flexibility** — Supports multiple auth methods including Bearer tokens, Basic auth, query parameters, and Google API headers. - **Model Variants** — Automatically creates model variants with Google Search grounding and thinking/reasoning controls. - **Docker Ready** — Containerized for easy deployment and includes Hugging Face Spaces compatibility. ## Philosophy The project aims to bridge the gap between Google's Gemini CLI and the broader ecosystem of AI tools by providing a standardized, easy-to-deploy API layer that maintains compatibility with popular interfaces.
Gemini-CLI-Termux is an automated deployment tool designed specifically for the Android Termux environment. It enables users to easily run a reverse proxy service for Google's Gemini AI models on their mobile devices, providing OpenAI-compatible API endpoints. This makes advanced AI capabilities accessible directly from a smartphone, turning it into a local API server. ## Key Features - **One-Click Deployment** — Single command installs and configures the entire service with an interactive menu. - **OpenAI-Compatible API** — Provides `/v1/chat/completions` and `/v1/models` endpoints for seamless integration with existing tools. - **Full Gemini Model Support** — Supports Gemini 3.1 Pro, 3 Pro, 3 Flash, 2.5 Pro, and 2.5 Flash series, including search-enhanced and thinking variants. - **Multiple Authentication Methods** — Includes HTTP Basic Auth, Bearer Token, API Key query parameter, and Google API Key header support. - **LAN Accessibility** — Configurable to allow network listening, enabling other devices on the same network to use the API. - **Interactive Management Menu** — Visual interface for service control, configuration changes, and system maintenance without command-line expertise. ## Philosophy The project prioritizes mobile-first, zero-friction deployment, bringing powerful AI API hosting to Android devices through a simplified, menu-driven experience.
Wrap Gemini CLI as an OpenAI-compatible API service, allowing you to enjoy the free Gemini Pro model through API!
Gemini CLI Bridge is a server application built on top of Google's Gemini CLI. It exposes Gemini CLI's native tools via the Model Context Protocol (MCP) and provides a fully compatible OpenAI API endpoint, enabling seamless integration with third-party applications like Open WebUI. ## Key Features - **MCP Toolkit** — Exposes Gemini CLI's built-in tools (file operations, web search, content understanding) through a unified MCP endpoint. - **OpenAI API Bridge** — Provides `/v1/chat/completions` and `/v1/models` endpoints compatible with OpenAI's API, allowing any OpenAI-supporting tool to use Gemini models. - **External MCP Aggregation** — Acts as an MCP hub to connect and proxy tools from external MCP servers (in configured or YOLO modes). - **Flexible Security Policies** — Implements configurable security modes (read-only, edit, configured, yolo) to control tool execution and file operation scope. - **Inherited Authentication** — Uses the same authentication and configuration as the main Gemini CLI tool, requiring no duplicate setup. ## Philosophy The project prioritizes security and extensibility, providing a bridge that unlocks Gemini CLI's capabilities for the broader ecosystem while maintaining granular control over tool access and execution risks.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.