This page provides information about how to download or install the libraries for accessing the Gemini API. If you're new to the Gemini API, try out the API quickstart.
Python
We provide a Python SDK which you can install by running:
pip install google-genai
Node.js
We provide a Node SDK which you can install by running:
npm install @google/generative-ai
Go
We provide a Go SDK which you can install by running:
go get github.com/google/generative-ai-go
Dart (Flutter)
We provide a Dart and Flutter SDK which you can install by running either:
dart pub add google_generative_ai
If you're using Flutter, run the following command:
flutter pub add google_generative_ai
Swift
We provide a Swift SDK
which you can install by adding generative-ai-swift
to your Xcode project
using Swift Package Manager.
Android
We provide an Android SDK
which you can install by adding the dependency
implementation("com.google.ai.client.generativeai:generativeai:0.9.0")
to your Android project.