Back to articles
AI Agents

Gemini API Managed Agents Add 3.6 Flash, Hooks and Production Controls

3 min read

Introduction

Google is turning Managed Agents in the Gemini API into a more production-oriented layer for autonomous development workflows. The update is not only about switching the default model to Gemini 3.6 Flash. It also adds execution controls, cost safeguards, scheduling, free-tier access and better sandbox management — all of which matter when agents move from demos into real engineering pipelines.

Key points

  • Gemini 3.6 Flash becomes the default: The antigravity-preview-05-2026 agent now runs on Gemini 3.6 Flash by default. Developers do not need to change code; the next interaction will automatically use the new default. Google describes the model as balanced for reasoning, coding and tool use.
  • Model selection remains available: Teams can still set agent_config.model when creating an interaction or managed agent. Supported options include Gemini 3.6 Flash, Gemini 3.5 Flash and Gemini 3.5 Flash-Lite, with the Lite model positioned for lower latency and lower cost.
  • Environment hooks add a governance layer: Developers can place a .agents/hooks.json file in the sandbox and run custom handlers before or after tool calls. These hooks can target specific tools through matchers, including code execution and file writing.
  • Blocking, linting and auditing are built into the workflow: A pre-tool hook can deny an operation, skip the tool call and feed the reason back into the model context. Post-tool hooks can run formatting, validation or audit scripts after a tool finishes. HTTP hooks are also supported for external endpoints.
  • Budget controls reduce runaway risk: Because managed agents may execute multi-turn autonomous loops, Google has added max_total_tokens to cap total input, output and thinking tokens. When the cap is reached, the interaction pauses as incomplete while preserving the environment state.
  • Scheduled triggers enable recurring work: A trigger can bind an agent, environment, prompt and cron schedule into a persistent resource. Each run reuses the same sandbox, so files can persist across scheduled executions.
  • Free-tier and environment APIs broaden access: Managed agents are now available to free-tier projects. The Environments API lets developers list, inspect and delete sandbox sessions, which helps with recovery after disconnects and explicit cleanup.

Why it matters

The most important part of this release is the shift from raw agent capability toward controllable agent operations. Agents that can run code, install packages, edit files and retrieve web content need guardrails. Environment hooks give teams a place to enforce security gates, style rules, quality checks and business-specific validation inside the same sandbox where the agent is acting.

The budget and scheduling features address another practical concern: autonomous tasks can be long-running and difficult to estimate. A token cap gives developers a hard stop instead of an open-ended bill, while preserved environment state allows work to continue later with a fresh budget. Scheduled triggers also reduce the need for separate orchestration when teams want agents to perform recurring tasks.

This does not remove the need for human oversight or careful system design. Hooks are only as good as the validation scripts and policies behind them, and teams still need to define permissions, failure handling and review processes. But the direction is clear: Gemini Managed Agents are becoming less like one-off API experiments and more like sandboxed, governable cloud workers for software and operational workflows.

Source: Google AI Blog

Comments

Checking sign-in status...

Loading comments...

Related articles