agentleFS
hybridlabor-apihybridlabor-api/aos/skills/global_config/gemini-api-dev/SKILL.md

gemini-api-dev

Skill9 starsChanged 23 days agoApache-2.0View on GitHub

The Gemini API provides access to Google's most advanced AI models. Key capabilities include:

  • Reads credentials
  • Installs packages

14 other projects use a version of this, 8 of them edited.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 7 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 14 edited versions we read keep these.

  • 7

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Code execution: - Run Python code in a sandboxed environment

    line 19
  2. Distinctive:

    Use this unless the integration is explicitly pinned to v1.

    line 107
  3. Distinctive:

    Use only when the integration is specifically set to v1.

    line 109
  4. Distinctive:

    When in doubt, use v1beta.

    line 111
  5. Distinctive:

    Use this skill only when the task clearly matches the scope described above.

    line 144
  6. Distinctive:

    Do not treat the output as a substitute for environment-specific validation, testing, or expert review.

    line 145
  7. Distinctive:

    Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.

    line 146

“Common” is measured: kept by at least 6 in 10 of the 14 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Gemini API Development Skill

Overview

The Gemini API provides access to Google's most advanced AI models. Key capabilities include:

  • Text generation - Chat, completion, summarization
  • Multimodal understanding - Process images, audio, video, and documents
  • Function calling - Let the model invoke your functions
  • Structured output - Generate valid JSON matching your schema
  • Code execution - Run Python code in a sandboxed environment
  • Context caching - Cache large contexts for efficiency
  • Embeddings - Generate text embeddings for semantic search

Models

Do not rely on your training knowledge of model names or IDs — they change frequently. Before choosing a model, look up the current model list in the provider docs at the time of use (Models via the llms.txt index below).

Capability tiers to pick between:

  • A flagship reasoning-tier model: complex reasoning, coding, research
  • A fast balanced model: quick turnarounds, everyday multimodal tasks
  • A dedicated image-generation model: image generation and editing

Choose the current model ID for each tier from the official documentation, never from memory.

SDKs

  • Python: google-genai install with pip install google-genai
  • JavaScript/TypeScript: @google/genai install with npm install @google/genai
  • Go: google.golang.org/genai install with go get google.golang.org/genai

[!WARNING] Legacy SDKs google-generativeai (Python) and @google/generative-ai (JS) are deprecated. Migrate to the new SDKs above urgently by following the Migration Guide.

Quick Start

Python

from google import genai

import os
client = genai.Client()
MODEL = os.environ["GEMINI_MODEL"]  # current model ID from the provider docs
response = client.models.generate_content(
    model=MODEL,
    contents="Explain quantum computing"
)
print(response.text)

JavaScript/TypeScript

import { GoogleGenAI } from "@google/genai";

const ai = new GoogleGenAI({});
const MODEL = process.env.GEMINI_MODEL ?? '<model-id>'; // current model ID from the provider docs
const response = await ai.models.generateContent({
  model: MODEL,
  contents: "Explain quantum computing"
});
console.log(response.text);

Go

package main

import (
	"context"
	"fmt"
	"log"
	"os"
	"google.golang.org/genai"
)

func main() {
	ctx := context.Background()
	client, err := genai.NewClient(ctx, nil)
	if err != nil {
		log.Fatal(err)
	}

	modelName := os.Getenv("GEMINI_MODEL") // current model ID from the provider docs
	resp, err := client.Models.GenerateContent(ctx, modelName, genai.Text("Explain quantum computing"), nil)
	if err != nil {
		log.Fatal(err)
	}

	fmt.Println(resp.Text)
}

API spec (source of truth)

Always use the latest REST API discovery spec as the source of truth for API definitions (request/response schemas, parameters, methods). Fetch the spec when implementing or debugging API integration:

  • v1beta (default): https://generativelanguage.googleapis.com/$discovery/rest?version=v1beta
    Use this unless the integration is explicitly pinned to v1. The official SDKs (google-genai, @google/genai, google.golang.org/genai) target v1beta.
  • v1: https://generativelanguage.googleapis.com/$discovery/rest?version=v1
    Use only when the integration is specifically set to v1.

When in doubt, use v1beta. Refer to the spec for exact field names, types, and supported operations.

How to use the Gemini API

For detailed API documentation, fetch from the official docs index:

llms.txt URL: https://ai.google.dev/gemini-api/docs/llms.txt

This index contains links to all documentation pages in .md.txt format. Use web fetch tools to:

  1. Fetch llms.txt to discover available documentation pages
  2. Fetch specific pages (e.g., https://ai.google.dev/gemini-api/docs/function-calling.md.txt)

Key Documentation Pages

[!IMPORTANT] Those are not all the documentation pages. Use the llms.txt index to discover available documentation pages

When to Use

This skill is applicable to execute the workflow or actions described in the overview.

Limitations

  • Use this skill only when the task clearly matches the scope described above.
  • Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
  • Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.