gemini-interactions-api
Installation
SKILL.md
Gemini Interactions API Skill
This skill provides instructions for authenticating, connecting to, and utilizing the stateful, server-managed Gemini Interactions API on Gemini Enterprise Agent Platform.
The Interactions API is the modern, recommended way to execute Generative AI agent conversations, background research tasks, multi-turn chats, and structured, multi-step workflows.
[!IMPORTANT] CRITICAL: Unified SDK & Latest Models
- Unified SDK: Use the Google Gen AI SDK (
google-genai >= 2.0.0for Python,@google/genai >= 2.0.0for JS/TS). Legacy SDKs likegoogle-cloud-aiplatform,@google-cloud/vertexai, andgoogle-generativeaiare strictly unsupported for Interactions.- Latest Models Only: Use
gemini-3.1-pro-preview,gemini-3.1-flash-lite,gemini-3-flash-preview,gemini-2.5-pro, orgemini-2.5-flash. Refer to the latest model versions to check for new updates. Legacy models (gemini-2.0-*,gemini-1.5-*) are deprecated and do not support interactions.- Turn-Scoped Parameters: Parameters like
tools,system_instruction, andgeneration_configare turn-scoped. They MUST be passed with each interaction request.
1. Authentication
Before running any code, ensure you are authenticated with Application Default Credentials (ADC) and have the necessary API enabled.