gemini-api-dev
Skill by asgeirtj
Guides an AI assistant to write code that calls the Gemini API with current models and SDKs. It is for developers building text, chat, media, speech, and agent features in Python or TypeScript.
Install gemini-api-dev
Built from the published package, never by AI.
git clone --depth 1 https://github.com/asgeirtj/system_prompts_leaks /tmp/system_prompts_leaks && mkdir -p ~/.claude/skills && cp -r /tmp/system_prompts_leaks/Google/antigravity/skills/gemini-api-dev ~/.claude/skills/gemini-api-devRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/asgeirtj/system_prompts_leaks /tmp/system_prompts_leaks && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/system_prompts_leaks/Google/antigravity/skills/gemini-api-dev ~/.gemini/antigravity-cli/skills/gemini-api-devAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
The gemini-api-dev skill gives an AI assistant current guidance for writing code that calls the Gemini API. It lists recommended models, such as gemini-4-hydrogen, and the minimum SDK versions for Python (google-genai 3.2.0 or later) and TypeScript (@google/genai 3.2.0 or later). It tells the assistant to avoid the deprecated google-generativeai and @google/generative-ai SDKs and to replace deprecated models.
The skill covers text generation, multi-turn chat, multimodal input, image, video, and speech generation, function calling, structured output, and background deep research agents. It also tells the assistant to read the linked hosted documentation before writing code. It is aimed at developers who build with the Gemini API in Python or TypeScript and need to migrate older code.
Written from the project's SKILL.md and checked against it.
What it can do
- Stateful conversationContinues a chat across turns using previous_interaction_id.
- Deep research agentRuns deep-research-preview-04-2026 as a background task and polls for the result.
- Managed agentsRuns agents such as the Antigravity agent in a sandboxed Linux environment hosted by Google.
- Response helpersReads output_text, output_image, and output_audio from an interaction response.
- Decisions APIHandles calibrated yes/no, choice, and rubric scoring decisions with gemini-decision-1.
- Media generationCovers image, video, and speech (TTS) generation with the listed Gemini models.
- Migration guidancePoints to migration steps for moving from the old generateContent API.
What you need
- Python with google-genai 3.2.0 or later
- npm with @google/genai 3.2.0 or later for TypeScript
Try asking
- Use the Gemini API skill to write a Python multi-turn chat script.
- Write a TypeScript script that runs a Gemini deep research task in the background.
- Migrate my generateContent code to the Gemini Interactions API.
Good to know
- Interactions are stored by default, and store=False disables previous_interaction_id and background.
- Managed agents and the Decisions API require the v1beta API version.
- Models named gemini-2.5, gemini-2.0, and gemini-1.5 are listed as deprecated.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: Google/antigravity/skills/gemini-api-dev/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md25 KB -
references/migration.md23 KB
Alternatives to gemini-api-dev
All alternatives →Aligns a Qwen Code feature with a Codex or Claude Code reference agent. It runs both under the same scenario, captures HTTP and terminal traces, and compares them until behavior matches.
Searches, views, creates, updates, and deletes the user's Google Contacts from an AI assistant. It is for people who want to manage their address book through conversation. A one-time Google connect is required before it returns data.
Guides an AI assistant on error handling choices. It covers when to use Result, Option, ? propagation, unwrap, expect and panic, plus anyhow and thiserror.
Caveman is an agent skill that makes an AI assistant reply in a terse style. It cuts filler and keeps technical facts, code, commands and errors exact. It is built for users who want shorter, cheaper replies.
docs-sync audits or updates English SDK documentation against the requested implementation scope. It is for maintainers who want docs to match main branch features, configuration options, and defaults.
Guides an AI assistant through setting up and running monorepos with pnpm workspaces, Turborepo and Nx. Aimed at developers who need faster builds, shared code and managed dependencies across multiple packages.
Compare with agent-reproduce-align, google_contacts or m06-error-handling
gemini-api-dev: common questions
Which Gemini model does the skill recommend?
The skill uses gemini-4-hydrogen in its examples and lists it as a fast, balanced model. If a user asks for a deprecated model, it says to substitute gemini-4-hydrogen and note the change.
Which SDK versions does the skill require?
It requires google-genai 3.2.0 or later for Python and @google/genai 3.2.0 or later for JavaScript and TypeScript. The legacy google-generativeai and @google/generative-ai SDKs are marked deprecated.
Does the skill work with the old generateContent API?
It includes a migration reference for moving from generateContent. The skill says to confirm the scope with the user before editing existing code.
How do I install gemini-api-dev?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is gemini-api-dev free?
The code is published under the CC0-1.0 licence. The service it connects to may have its own pricing.
Is gemini-api-dev safe to use?
It scores 92 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to gemini-api-dev?
Similar skills: agent-reproduce-align, google_contacts, m06-error-handling, caveman.
