# Gemini API **Provider:** Google DeepMind **Category:** ai **Base URL:** `https://generativelanguage.googleapis.com/v1beta` **Auth:** api-key — `x-goog-api-key: AIzaSy...` **Rate Limit:** 15 RPM (free) · 2,000 RPM (paid) **Free Tier:** Yes — [object Object] **Pricing:** Pay per use (pay-as-you-go) **Docs:** https://ai.google.dev/gemini-api/docs ## Description Google's Gemini API provides access to Gemini 2.5 Pro and Gemini 2.5 Flash — Google's latest multimodal AI models. Supports text, images, audio, video, and code with up to 2M token context windows. Integrated with Google Search grounding for real-time information access. Note: Gemini 2.0 Flash is deprecated and will be shut down June 1, 2026. ## Endpoints | Method | Endpoint | Description | |--------|----------|-------------| | POST | `https://generativelanguage.googleapis.com/v1beta/models/{model}:generateContent` | Generate text, multimodal content | | POST | `https://generativelanguage.googleapis.com/v1beta/models/{model}:streamGenerateContent` | Stream generated content as SSE | | POST | `https://generativelanguage.googleapis.com/v1beta/models/{model}:embedContent` | Create text embeddings | | GET | `https://generativelanguage.googleapis.com/v1beta/models` | List all available models | ## Authentication Pass your Google API key as a query parameter or in the x-goog-api-key header. ``` x-goog-api-key: AIzaSy... ``` ## Sample Request ```bash curl "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash:generateContent" \ -H "x-goog-api-key: $GEMINI_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "contents": [{ "parts": [{"text": "Explain quantum entanglement simply."}] }] }' ``` ## Sample Response ```json { "candidates": [{ "content": { "parts": [{"text": "Quantum entanglement is when two particles become linked..."}], "role": "model" }, "finishReason": "STOP" }], "usageMetadata": { "promptTokenCount": 9, "candidatesTokenCount": 120, "totalTokenCount": 129 } } ``` ## Pricing Details Gemini 2.5 Flash: $0.15/M input, $0.60/M output. Gemini 2.5 Flash-Lite: $0.10/M input, $0.40/M output. Gemini 2.5 Pro: $1.25/M input, $5/M output (>200K context). Batch: 50% off. Note: Gemini 2.0 Flash deprecated, ends June 1, 2026. --- *Source: [API Map](https://apimap.dev/apis/google-gemini/) — CC BY 4.0*