gemini-business  by linlee996

Google Gemini Business API with OpenAI compatibility

Created 3 months ago
256 stars

Top 98.5% on SourcePulse

GitHubView on GitHub
Project Summary

Summary This project offers an automated service that bridges Google Gemini Business with OpenAI-compatible APIs. It targets developers and power users needing to integrate Gemini's capabilities into existing workflows, providing automated account management, token refreshing, and a unified API endpoint. The core benefit is simplified access to Gemini's advanced features, including multi-modal processing and image generation, without manual intervention.

How It Works The system acts as a proxy, translating requests to an OpenAI-compatible format and routing them to managed Gemini Business accounts. It utilizes Docker with Chrome/Xvfb for automated browser tasks like registration and login refreshes. Key features include robust multi-account management with load balancing, automatic failover, intelligent circuit breaking for failed accounts, and a three-layer retry strategy for high availability. A web-based admin panel offers real-time monitoring and configuration.

Quick Start & Requirements Deployment options include Docker Compose (Linux/amd64 only), Docker build, or local Python/uv.

  • Docker Compose: Download docker-compose.yml, configure environment variables, and run docker-compose up -d.
  • Docker Build: Clone repo, build image (docker build), and run container (docker run).
  • Local: Install dependencies (uv sync), configure .env, and run uv run main.py. Prerequisites: Docker, Python 3.11+, and specific environment variables for auto-registration (temporary email API, Google login URL).

Highlighted Details

  • Multi-Account Management: Load balancing, failover, circuit breaking (429/error disabling), triple retries, auto-disable on expiration, manual disable/enable.
  • Automated Operations: One-click batch registration, auto email verification, cookie/token refresh, browser process crash recovery.
  • Extensive Multi-modal Support: Handles 100+ file types (images, PDFs, Office, audio, video, code).
  • Image Capabilities: Supports gemini-3-pro-preview for image generation and image-to-image tasks.
  • Admin Panel: Real-time monitoring, usage stats, online configuration management.

Maintenance & Community No explicit maintainers or direct community links (Discord/Slack) are listed. Discussions are referenced via external platforms like Linux.do.

Licensing & Compatibility Released under the MIT License, which is generally permissive for commercial use and integration into closed-source projects.

Limitations & Caveats Docker Compose deployment is restricted to linux/amd64 architectures. Auto-registration setup requires external email services and Google login URLs. Generated images and in-memory logs are temporary and may be lost on restart unless specific configurations are used. Configuration persistence across restarts may require syncing environment variables with saved JSON files.

Health Check
Last Commit

2 months ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
1
Star History
25 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.