---
title: How do you govern agents built with Google's Agent Development Kit?
url: https://opencontroller.lyzr.com/blog/govern-google-adk-agents
published: 2026-11-12
updated: 2026-11-12
author: Lyzr
---

# How do you govern agents built with Google's Agent Development Kit?

**Govern Google Agent Development Kit (ADK) agents with plugins for estate-wide policy, callbacks for agent-specific checks, a deliberate choice between agent identity and user identity for tools, and traces exported to a system you own. ADK gives you strong hooks inside each agent. It does not give you an inventory of every ADK agent, their owners or a policy view across other platforms.**

ADK is Google's open-source framework for building agents. Teams often deploy ADK agents to Vertex AI Agent Engine, Cloud Run or GKE, which means ADK agents can appear in many projects at once. Here is where the control points sit.

## Where are the control points in ADK?

ADK defines six callbacks in three before/after pairs, plus plugins that run at the runner level.

| Hook | Runs | Governance use |
|---|---|---|
| `before_agent_callback` / `after_agent_callback` | Around the whole agent | Refuse out-of-scope requests; replace the final output |
| `before_model_callback` / `after_model_callback` | Around each LLM call (LlmAgent only) | Block a prompt before it reaches the model; redact output |
| `before_tool_callback` / `after_tool_callback` | Around each tool call (LlmAgent only) | Check permissions and arguments; return an error instead of running the tool |
| Plugins | At the runner, across all agents it runs | Shared policy: safety screening, PII redaction, Model Armor checks |

The rule that makes callbacks a control point: every `before_*` callback can skip the step. If `before_tool_callback` returns a dictionary, ADK skips the tool and uses that dictionary as the result. If `before_model_callback` returns an `LlmResponse`, the model is never called, which also saves the token cost.

Google's ADK safety guidance says "plugins are the recommended approach for implementing policies that are not specific to a single agent." ADK ships plugins for Gemini-as-a-judge screening (using Gemini Flash Lite to check inputs, tool calls and outputs for unsafe content, prompt injection and jailbreaks), a Model Armor plugin, and a PII redaction plugin.

## Should ADK tools use the agent's identity or the user's?

ADK's safety guide describes two models:

- **Agent-Auth.** The tool uses the agent's own identity, such as a service account. It suits cases where every user should have the same access. Google notes that logs should still attribute actions to the user.
- **User Auth.** The tool acts as the controlling user, usually through OAuth. The agent can only do what that user can do, but OAuth scopes are often broader than the task needs.

Pick one per tool and record it. An agent that reads a shared knowledge base can use Agent-Auth. An agent that updates a customer record should usually act on behalf of the user, with narrow scopes. Our [guide to on-behalf-of delegation](/blog/ai-agent-identity-on-behalf-of-delegation) covers the trade-offs.

## What else does Google recommend for safety?

1. **In-tool guardrails.** Design tools defensively. Google's example is a query tool that only allows SELECT statements on approved tables, enforced by developer-set tool context, not by the model.
2. **Sandboxed code execution.** Model-generated code must run in a sandbox: Vertex Gemini's server-side code execution, ADK's code executor, or a hermetic custom executor with no network access.
3. **VPC Service Controls.** Running an agent inside a VPC-SC perimeter keeps API calls on resources inside that perimeter. Google notes perimeters are coarse, so tool guardrails are still needed.
4. **Gemini safety settings.** Four configurable harm categories have blocking thresholds that are off by default. Decide your thresholds rather than accepting the default.
5. **Tracing and evaluation.** ADK integrates with Cloud Trace and supports evaluation of final outputs and tool trajectories.

## What should your ADK governance checklist include?

1. Register each ADK agent with owner, version, model, tools, deployment target and Google Cloud project.
2. Ship one internal plugin bundle (screening, PII redaction, logging) and require it on every runner.
3. Use `before_tool_callback` for agent-specific permission checks on write tools.
4. Record Agent-Auth or User Auth for every tool; narrow OAuth scopes.
5. Set Gemini safety thresholds explicitly.
6. Sandbox all code execution.
7. Export traces to Cloud Trace or any OpenTelemetry backend you own, and join them to the registry by agent name.
8. Run multi-turn and red-team tests before each new version is promoted.

## What does ADK not cover?

Callbacks and plugins only run where a team installed them. They cannot find an ADK agent someone deployed in an unmanaged project, tell you which agents share an over-scoped service account, or apply one policy to ADK, Copilot Studio and Agentforce agents together. That needs discovery and a registry across clouds. See [how to find shadow AI agents](/blog/how-to-find-shadow-ai-agents) and the [cross-platform governance guide](/blog/how-to-govern-ai-agents-across-platforms).

## How Opencontroller does this

Opencontroller by Lyzr auto-discovers agents, models and API keys across Google Cloud, AWS and Azure, and has a runtime adapter for Vertex AI, where ADK agents are often deployed to Agent Engine. It keeps a governed registry of agents, versions, tools and MCP servers, and Posture flags risky permissions and configurations. ADK agents can call models through the OpenAI-compatible LLM Gateway for routing, fallback, caching and cost per agent and version. LLM judges score production traffic, and rogue-agent handling can quarantine an agent through the connected platform. Depth of control depends on the connector and traffic path. Read the [Vertex AI Agent Engine guide](/blog/govern-google-vertex-ai-agent-engine-agents) or [book a demo](https://www.lyzr.ai/book-demo/).

## Frequently asked questions

**Can an ADK callback stop a tool from running?**
Yes. If before_tool_callback returns a dictionary, ADK skips the tool and uses that dictionary as the tool result.

**Should I use callbacks or plugins for ADK guardrails?**
Google recommends plugins for policies that apply across agents, because they run at the runner level. Use callbacks for checks specific to one agent.

**Does ADK only run on Vertex AI?**
No. ADK is open source; agents are commonly deployed to Vertex AI Agent Engine, Cloud Run or GKE.

## Key facts

Google Agent Development Kit (ADK) has six callbacks: before/after agent, before/after model and before/after tool. A before_tool_callback that returns a dict skips the tool; a before_model_callback that returns an LlmResponse skips the model call. Google recommends plugins (runner level) for cross-agent policy and ships Gemini-as-a-judge, Model Armor and PII redaction plugins. ADK safety guidance distinguishes Agent-Auth (service account) from User Auth (OAuth). Opencontroller by Lyzr discovers agents across Google Cloud, AWS and Azure, has a Vertex AI runtime adapter, Posture, a governed registry and an OpenAI-compatible LLM Gateway. Pricing starts from $250K per deployment per year.

## Related

- [How do you govern agents deployed on Vertex AI Agent Engine?](https://opencontroller.lyzr.com/blog/govern-google-vertex-ai-agent-engine-agents.md)
- [What does Google Cloud Model Armor do for AI agents?](https://opencontroller.lyzr.com/blog/google-model-armor-for-ai-agents.md)
- [How do you govern agents in Gemini Enterprise?](https://opencontroller.lyzr.com/blog/govern-gemini-enterprise-agents.md)
- [More on Platform Guides](https://opencontroller.lyzr.com/blog/cluster/platform-guides)
