🌐
GitHub
googleapis.github.io › python-genai
Google Gen AI SDK documentation
from google import genai # Only run this block for Vertex AI API client = genai.Client( vertexai=True, project='your-project-id', location='us-central1' )
@google/genai
If you are not redirected automatically, click here to go to the release version docs
Submodules
Find your Google Cloud project ID. ... The location to send API requests to (for example, us-central1). Can be obtained from environment variables. Applies to the Vertex AI API only. ... Config settings that control network behavior of the client. This is typically used when running test code. ... Http options to use for the client. These options will be applied to all requests made by the client. Example usage: client = genai...
🌐
Google AI
ai.google.dev › gemini-api › docs
Gemini API | Google AI for Developers
1 week ago - from google import genai client = genai.Client() interaction = client.interactions.create( model="gemini-3.5-flash", input="Explain how AI works in a few words" ) print(interaction.output_text)
🌐
Google
docs.cloud.google.com › ai and ml › generative ai
Generative AI | Google Cloud Documentation
Documentation and resources for building and implementing generative AI applications with Google Cloud tools and productss.
🌐
Google
docs.cloud.google.com › gemini enterprise agent platform › google gen ai sdk
Google Gen AI SDK | Gemini Enterprise Agent Platform | Google Cloud Documentation
from google import genai from google.genai.types import HttpOptions client = genai.Client(http_options=HttpOptions(api_version="v1")) response = client.models.generate_content( model="gemini-3.5-flash", contents="How does AI work?", ) print(response.text) # Example response: # Okay, let's break down how AI works.
🌐
Google AI
ai.google.dev › gemini api › gemini api libraries
Gemini API libraries | Google AI for Developers
April 28, 2026 - When building with the Gemini API, we recommend using the Google GenAI SDK. These are the official, production-ready libraries that we develop and maintain for the most popular languages. They are in General Availability and used in all our official documentation and examples.
🌐
npm
npmjs.com › package › @google › genai
google/genai
1 week ago - Documentation: https://googleapis.github.io/js-genai/ The Google Gen AI JavaScript SDK is designed for TypeScript and JavaScript developers to build applications powered by Gemini.
      » npm install @google/genai
    
Published   Jun 24, 2026
Version   2.10.0
🌐
Google AI
ai.google.dev › gemini api › getting started with gemini api
Getting started with Gemini API | Google AI for Developers
2 weeks ago - Index and search across uploaded documents and media files. ... Ground responses in real-world geospatial and location data. ... Browser automation and screen interaction. Function calling lets you connect the model to your code. You declare a function's name and parameters, the model decides when to call it and returns structured arguments, and you execute it locally and send the result back. import json from google import genai client = genai.Client() weather_tool = { "type": "function", "name": "get_current_temperature", "description": "Gets the current temperature for a given location.", "parameters": { "type": "object", "properties": { "location": { "type": "string", "description": "The city name, e.g.
🌐
GitHub
github.com › google › generative-ai-docs
GitHub - google/generative-ai-docs: This repository is deprecated and will be archived · GitHub
Notebooks and other content used directly on ai.google.dev.
Starred by 2.2K users
Forked by 744 users
Languages   Jupyter Notebook
🌐
GitHub
github.com › googleapis › python-genai
GitHub - googleapis/python-genai: Google Gen AI Python SDK provides an interface for developers to integrate Google's generative models into their Python applications. · GitHub
1 month ago - By default we use httpx for both sync and async client implementations. In order to have faster performance, you may install google-genai[aiohttp]. In Gen AI SDK we configure trust_env=True to match with the default behavior of httpx.
Starred by 3.8K users
Forked by 929 users
Languages   Python
Find elsewhere
🌐
Google
developers.google.com › ml kit › overview of the ml kit genai apis
Overview of the ML Kit GenAI APIs | Google for Developers
The ML Kit GenAI APIs are built on top of AICore, an Android system service that enables on-device execution of GenAI foundation models to facilitate features such as enhanced app functionality and improved user privacy by processing data locally.
🌐
PyPI
pypi.org › project › google-generativeai
google-generativeai · PyPI
Google Generative AI High level API client library and tools.
      » pip install google-generativeai
    
Published   Dec 16, 2025
Version   0.8.6
🌐
Llamaindex
developers.llamaindex.ai › python › examples › llm › google_genai
Google GenAI | Developer Documentation
from llama_index.llms.google_genai import GoogleGenAI ... Here's a cute dog for you! We can also edit the image! ... content="Please edit the image to make the dog a mini-schnauzer, but keep the same overall pose, framing, background, and art style.", ... Here's your mini-schnauzer! Note for AI agents: this documentation is built for programmatic access.
🌐
Langchain
reference.langchain.com › python › integrations › langchain_google_genai
langchain_google_genai | LangChain Reference
These reference pages contain auto-generated API documentation for each module, focusing on the "what" rather than the "how" or "why" (i.e. no end-to-end tutorials or conceptual overviews). ... Gemini chat models (primary interface). ... Gemini embedding models. ... Utility to create a context cache for reusing large content across requests. ... Custom exception class for errors associated with the Google GenAI API.
🌐
Google AI
ai.google.dev › gemini api › migrate to the google genai sdk
Migrate to the Google GenAI SDK | Gemini API | Google AI for Developers
April 28, 2026 - import requests import pathlib from google import genai from google.genai import types client = genai.Client() # Check which models support caching. for m in client.models.list(): for action in m.supported_actions: if action == "createCachedContent": print(m.name) break # Download file response = requests.get( 'https://storage.googleapis.com/generativeai-downloads/data/a11.txt') pathlib.Path('a11.txt').write_text(response.text) # Upload file document = client.files.upload(file='a11.txt') # Create cache model='gemini-3.5-flash' apollo_cache = client.caches.create( model=model, config={ 'contents': [document], 'system_instruction': 'You are an expert at analyzing transcripts.', }, ) # Generate response response = client.models.generate_content( model=model, contents='Find a lighthearted moment from this transcript', config=types.GenerateContentConfig( cached_content=apollo_cache.name, ) )
🌐
Google
docs.cloud.google.com › gemini enterprise agent platform › generative ai beginner's guide
Generative AI beginner's guide | Gemini Enterprise Agent Platform | Google Cloud Documentation
5 days ago - This beginner's guide introduces you to the core technologies of generative AI and explains how they fit together to power chatbots and applications. Generative AI (also known as genAI or gen AI) is a field of machine learning (ML) that develops ...
🌐
GitHub
github.com › googleapis › python-genai › blob › main › codegen_instructions.md
python-genai/codegen_instructions.md at main · googleapis/python-genai
Official Documentation: ai.google.dev/gemini-api/docs · Always use the Google GenAI SDK (google-genai), which is the unified standard library for all Gemini API requests (AI Studio/Gemini Developer API and Vertex AI) as of 2025.
Author   googleapis