Interactions API: our primary interface for Gemini models and agents

Interactions API: our primary interface for Gemini models and agents
A single unified endpoint for Gemini models and agents with server-side state, background execution, tool combination and multimodal generation.
Today we’re announcing that the Interactions API has reached general availability and is now our primary API for interacting with Gemini models and agents. We launched its public beta in December 2025, and it has quickly become developers’ favorite way to build applications with Gemini.
With this GA release, the API now has a stable schema and we also added major new capabilities that developers asked for, including Managed Agents, background execution, Gemini Omni (soon) and more. All of our documentation now defaults to Interactions API and we are working with ecosystem partners to make it the default interface across 3P SDKs and Libraries.
The simplest way to build with Gemini
Whether you’re calling a model or running an agent, the Interactions API gets you there in a few lines of code. Pass a model ID for inference, an agent ID for autonomous tasks, set background=True for anything long-running.
from google import genai
client = genai.Client()
# Talk to a model
interaction = client.interactions.create(
model="gemini-3.5-flash",
input="Explain quantum entanglement simply.",
)
# Run an agent
interaction = client.interactions.create(
agent="antigravity-preview-05-2026",
input="Plot the growth of solar energy generation globally and make some slides in HTML.",
environment="remote",
)
Key updates since December
- Managed Agents: A single API call provisions a remote Linux sandbox where an agent can reason, execute code, browse the web and manage files. The Antigravity agent ships as the default, and you can define your own custom agents with instructions, skills and data sources.
- Background execution: Set background=True on any call. The server runs the interaction asynchronously.
- Tool improvements: Mix built-in tools , such as Google Search, Google Maps with your own functions in one request. Tool results can now return images alongside text.
- Deep Research upgrades: Two new agent versions (speed vs. depth), collaborative planning, native charts and infographics, and multimodal grounding with images, PDFs and audio.
- Media generation: Image generation with Nano Banana 2 and Google Image Search grounding, music with Lyria 3, and expressive speech with multi-speaker TTS.
- From Roles to Steps: Simplified schema where every action (user_input, thought, function_call, model_output, etc.) is its own typed step, replacing the old role structure.
- Cost and developer optimizations: Flex and Priority tiers let you optimize for cost or latency (Flex offers 50% cost reduction). Errors now pinpoint the exact field. Past interactions are retrievable with 55-day retention on the paid tier.
The new standard for development
The Interactions API is now the default for Google AI Studio, the Gemini API, and all our documentation, which includes a toggle to switch snippets back to the legacy format. We recommend using the Interactions API for all new projects and applications.
While the legacy generateContent API remains fully supported and will continue to receive new mainline Gemini models for the foreseeable future, we expect frontier capabilities for long-running models and agents to increasingly land exclusively on the Interactions API. This is because it is designed from the ground up for stateful, agentic workflows. We have published a migration guide to help you transition at your own pace.
An agent-first ecosystem
Most developers are now using coding agents (such as Antigravity) to build applications. To make it easier for agents to stay up to date with the latest API patterns, we built the gemini-interactions-api Skill. It injects best-practice patterns for Interactions API development into your agent’s context (streaming, function calling, structured output, Deep Research and more).
npx skills add google-gemini/gemini-skills --skill gemini-interactions-api
Get started
The Interactions API is available through the Python and JavaScript SDKs. If you’re already building with one of our supported partners, LiteLLM, Eigent or Agno, you can start using their Interactions API integrations today.
Grab your API key from Google AI Studio and follow the Interactions API documentation to get started. If you’re migrating from generateContent, our migration guide maps every field to the new schema. You can also view the full API Reference.
The Interactions API was built based on developer feedback, and that focus won’t change with general availability. Tell us what you need on the developer forum.
generateContent remain active for stateless, single-turn tasks, Google now recommends the Interactions API for all new development. It is built specifically to handle multi-turn, multimodal, and complex agentic workflows seamlessly. [2, 4, 5] Key Capabilities of the Interactions API
- Unified Interface: Access raw foundational models or fully managed AI agents through a single, consistent API endpoint (
/interactions). [6, 7] - Server-Side State Management: The server automatically manages conversation context and session history using a unique Interaction ID. This eliminates the need to manually pass client-side chat histories, increasing efficiency. [8, 9]
- Managed Agents: Spin up autonomous agents (like the pre-built Antigravity agent) capable of reasoning and executing code inside an isolated, remote Linux sandbox. [10]
- Background Execution: Offload long-running multi-step processes or asynchronous tasks to the server without maintaining an active client connection. [11, 12]
- Exclusive Access to Deep Research: The autonomous Gemini Deep Research Agent—which iteratively searches, reads, and generates detailed reports—is available exclusively through the Interactions API. [13]
- Rich Native Tooling: Built-in support for advanced tool integration, including Grounding with Google Maps for spatial and local data, Google Search, and code execution. [14, 15]
Migration and SDK Support
gemini-interactions-api Skill to inject modern development patterns directly into AI assistant context layers. [16, 17] Read more
. AirPods Pro 3 starring Vini Jr. (Music Edit) with the world’s best in-ear Active Noise Cancellation
. This Father’s Day, helping families build safer digital habits together
. Street View opens a new window into Georgia
. Build A Live Data Stack With MCP For Smarter Campaign Performance
. HSBC expands AI banking partnership with Google Cloud
. Brain for Perplexity Computer
. How Data Centers in Space Could Change AI
. The 5-Minute AI Weekly Recap: Realignment Week
. Troubleshoot formula errors quickly with Gemini in Google Sheets
. Google DeepMind and A24 announce first-of-its-kind research partnership
. How to Share Your Google AI Studio App in Minutes
. Google NotebookLM is transforming student success at FSU
for more refer Gemini website click here
for more refer Artificial Intelligence website click here

