← ClaudeAtlas

geminilisted

Call the Gemini API (gemini-2.5-flash, gemini-2.5-pro, gemini-3-flash-preview, gemini-3-pro-preview, gemini-3.1-pro-preview) through RunAPI using the official OpenAI SDK or the native Google Generative AI SDK. Use when the user asks for Gemini chat, streaming completions, multimodal vision input, Google Search grounding, structured output, reasoning effort, or to point an existing OpenAI-compatible or Gemini-native client at RunAPI as the base URL.
runapi-ai/gemini · ★ 0 · AI & Automation · score 78
Install: claude install-skill runapi-ai/gemini
# Gemini on RunAPI Gemini on RunAPI exposes **two protocols**: | Protocol | Endpoint | Use when | |---|---|---| | OpenAI-compatible | `POST /v1beta/openai/chat/completions` | You already use the OpenAI SDK or any OpenAI client | | Native Gemini | `POST /v1beta/models/<model>:streamGenerateContent` | You use Google's `@google/generative-ai` SDK (currently `gemini-3-flash-preview` only) | Both accept the same RunAPI API Key. ## Setup ```dotenv RUNAPI_TOKEN=YOUR_RUNAPI_TOKEN ``` Get a RunAPI API Key at <https://runapi.ai/api_keys>. ### OpenAI-compatible setup ```python from openai import OpenAI client = OpenAI( api_key="YOUR_RUNAPI_TOKEN", base_url="https://runapi.ai/v1beta/openai", ) ``` ```typescript import OpenAI from "openai"; const client = new OpenAI({ apiKey: "YOUR_RUNAPI_TOKEN", baseURL: "https://runapi.ai/v1beta/openai", }); ``` ### Native Gemini setup ```bash export GOOGLE_API_KEY=YOUR_RUNAPI_TOKEN export GOOGLE_GENAI_BASE_URL=https://runapi.ai ``` ## Core recipe — OpenAI-compatible ```python response = client.chat.completions.create( model="gemini-2.5-flash", messages=[{"role": "user", "content": "Explain quantum computing simply."}], reasoning_effort="high", ) print(response.choices[0].message.content) print(response.usage) ``` ```typescript const response = await client.chat.completions.create({ model: "gemini-2.5-flash", messages: [{ role: "user", content: "Explain quantum computing simply." }], }); ``` ```bash curl -X P