gemini-api-dev

Implements Gemini API integrations for text, multimodal, agents, and streaming in Python and TypeScript.

1|Updated Sep 15, 2026
One-click install
npx skills add https://github.com/amoai-tech/mdeai --skill gemini-api-dev-amoai-tech
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gemini-api-dev
Source: https://github.com/amoai-tech/mdeai/tree/main/.claude/skills/gemini/references/official/gemini-api-dev
Command: npx skills add https://github.com/amoai-tech/mdeai --skill gemini-api-dev-amoai-tech

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve? Writing code against the Gemini API is error-prone when relying on outdated training data: deprecated models, legacy SDKs, and the old generateContent API lead to broken integrations. This Skill provides current model names, SDK versions, and correct Interactions API patterns so generated code works against the live API. ## Core Features & Use Cases - Current API Patterns: Provides correct usage of the Interactions API (client.interactions.create) with current models like gemini-3.8-flash, replacing deprecated generateContent code. - Full Feature Coverage: Covers text generation, multi-turn chat, streaming, function calling, structured output, image/video generation, embeddings, and managed agents such as Deep Research and Antigravity. - Migration Workflow: Includes a reference guide with scoping rules, checklists, and model replacement tables for migrating legacy Gemini code safely. - Use Case: A developer asks to add streaming chat to a TypeScript app; the Skill supplies the correct @google/genai SDK calls, event handling for step.delta streams, and points to the authoritative docs page before writing code. ## Quick Start Ask the assistant to write a Gemini API call for your task, for example: generate a streaming text response using gemini-3.8-flash in TypeScript.

Frequently Asked Questions about gemini-api-dev

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

FAQPage Schema
How do I call the Gemini API in Python?

Install google-genai version 2.3.0 or higher, create a client with genai.Client(), and call client.interactions.create with a model like gemini-3.8-flash and your input. Read the response via interaction.output_text.

How do I migrate from generateContent to the Interactions API?

Replace client.models.generate_content() with client.interactions.create(), read responses from interaction.steps instead of response.text, and use previous_interaction_id for multi-turn context. The migration reference includes a full checklist and model replacement table.

Which Gemini model should I use for my project?

Use gemini-3.8-flash for general agentic and multimodal tasks, gemini-3.5-flash-lite for high-throughput low-cost workloads, and gemini-3.1-pro-preview for complex reasoning. Deprecated models like gemini-2.0 and gemini-1.5 should be replaced with gemini-3.8-flash.

Does the Gemini API support streaming responses?

Yes, set stream=True (Python) or stream: true (TypeScript) in client.interactions.create to receive server-sent events. Handle step.delta events for incremental text and interaction.completed for final token usage.

Can I use the old google-generativeai SDK with new Gemini models?

No, the legacy google-generativeai (Python) and @google/generative-ai (JS) packages are deprecated and do not support the Interactions API. Upgrade to google-genai or @google/genai version 2.0.0 or higher.

How do I run background research tasks with Gemini agents?

Use the deep-research-preview-04-2026 or deep-research-max-preview-04-2026 agent with background=True, then poll client.interactions.get until the status is completed. Managed agents like Antigravity require environment="remote" to provision a sandbox.