ai-integrations-gemini

Integrates Gemini AI chat and image generation via Replit AI Integrations proxy in TypeScript.

Updated Apr 20, 2026
One-click install
npx skills add https://github.com/AmirEmad11/instabot --skill ai-integrations-gemini-amiremad11
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ai-integrations-gemini
Source: https://github.com/AmirEmad11/instabot/tree/main/.local/skills/ai-integrations-gemini
Command: npx skills add https://github.com/AmirEmad11/instabot --skill ai-integrations-gemini-amiremad11

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @google/genai, p-limit, p-retry, and includes references (resource) components.

What problem does it solve? Setting up Gemini AI in a Replit project normally requires obtaining and managing your own API key. This Skill provisions Gemini access through the Replit AI Integrations proxy with automatically configured environment variables, so you can add chat, streaming, and image generation features without handling credentials. ## Core Features & Use Cases - Managed Gemini Access: Provisions AI_INTEGRATIONS_GEMINI_BASE_URL and AI_INTEGRATIONS_GEMINI_API_KEY automatically, billing usage to Replit credits. - Chat with SSE Streaming: Provides a pre-configured GoogleGenAI client, Drizzle schemas for conversations and messages tables, and OpenAPI contract entries for streaming chat endpoints. - Image Generation: Includes a generateImage helper using gemini-2.5-flash-image that returns base64 image data. - Batch Processing: Ships batchProcess and batchProcessWithSSE utilities with rate limiting, retries, and SSE progress events for high-volume LLM tasks. - Use Case: Build a full-stack chat application where users create conversations, send messages, and receive streamed Gemini responses persisted in a PostgreSQL database via Drizzle ORM. ## Quick Start Ask the agent to set up the Gemini AI integration and build a chat endpoint that streams responses using the provided client and batch utilities.

Frequently Asked Questions about ai-integrations-gemini

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I use the Gemini API without my own API key?

Use the Replit AI Integrations proxy, which provisions AI_INTEGRATIONS_GEMINI_BASE_URL and AI_INTEGRATIONS_GEMINI_API_KEY automatically during setup. Charges are billed to your Replit credits, and you never handle credentials directly.

How do I stream Gemini chat responses with SSE in Express?

Call ai.models.generateContentStream, set Content-Type to text/event-stream, and write each chunk as a data event. Map the assistant role to model for Gemini, then send a final done event before ending the response.

Which Gemini models are available through Replit AI Integrations?

Available models include gemini-3.1-pro-preview, gemini-3-flash-preview, gemini-3-pro-image-preview, gemini-2.5-pro, gemini-2.5-flash, and gemini-2.5-flash-image. Models not on this list are not available through the integration.

Does the Gemini integration support embeddings or the files API?

No. The integration does not support the Live API, embeddings, fine-tuning, the files API, or audio/video generation. For those capabilities, use Gemini directly with your own API key instead.

Why is my Gemini API key a dummy string after setup?

The AI_INTEGRATIONS_GEMINI_API_KEY value is a placeholder that makes the SDK compatible; requests authenticate through the proxy base URL. It works as expected when AI_INTEGRATIONS_GEMINI_BASE_URL is also set, so test an actual API call before assuming misconfiguration.

How do I process many items through Gemini without hitting rate limits?

Use the batchProcess utility with configurable concurrency and automatic retries on rate limit errors. For real-time progress, batchProcessWithSSE processes items sequentially and emits SSE events for started, progress, and complete states.