Google ADKgoogle-adk 2.8 · Python 3.10+
Dashboard
0%
1
Curious builder0 XP earned · 300 to level 2
0 daysFinish a lesson to begin
Badge collection0 of 6 unlocked
28 small wins to finish your pathNext lesson →

Built-in tools: tools you did not write

ADK ships tools, and connects to hundreds more. The useful part of this lesson is the one rule that catches people out.

The built-in ones are the things Google can host for you: search, code execution, and the enterprise search products. Beside them are the toolsets for Google's own products, below. Beyond those, the documentation's integrations section lists more than a hundred connectors, from databases to ticketing systems, and MCP servers can be used as tools too.

python
from google.adk.tools import google_search

agent = LlmAgent(
    name="researcher",
    model="gemini-flash-latest",
    instruction="Answer questions about current events.",
    tools=[google_search],
)

That one needs a real model and a key, so there is no output on this page for it. The shape is what matters: a built-in tool goes in the same list your own functions go in.

The rule that catches people

Some built-in tools cannot be combined with anything else in the same agent. The documentation is explicit: Google Search, agent search and code execution with the Gemini API are one-tool-per-agent, in the Python versions where the limitation applies. Putting one of those next to your own functions is not supported.

The fix is the same one you would reach for anyway, and it is the subject of part 4: give the search tool its own agent, and let your main agent hand work to it.

Tools for Google's own APIs

The connectors worth knowing first are the ones for Google's own products, because ADK generates them from Google's API definitions and ships them with the package. Each is a toolset: one object that turns into many tools.

ToolsetWhat the agent can reach
SheetsToolsetGoogle Sheets: read and write a spreadsheet
DocsToolsetGoogle Docs: read and edit a document
GmailToolsetGmail: read, draft and send
CalendarToolsetCalendar: events and free time
SlidesToolsetSlides: build and read decks
YoutubeToolsetYouTube data
BigQueryToolsetBigQuery: datasets, tables and SQL

They act for a person, so they take an OAuth client rather than an API key, and they arrive with the tools extra: pip install "google-adk[tools]". A toolset goes in the same tools list your own functions go in:

python
from google.adk.agents import LlmAgent
from google.adk.tools.google_api_tool import SheetsToolset

sheets = SheetsToolset(
    client_id="YOUR_OAUTH_CLIENT_ID",
    client_secret="YOUR_OAUTH_CLIENT_SECRET",
    tool_filter=["sheets_spreadsheets_get", "sheets_spreadsheets_values_get"],
)

reporter = LlmAgent(
    name="reporter",
    model="gemini-flash-latest",
    instruction="Answer questions about the team's spreadsheet.",
    tools=[sheets],
)

tool_filter is the part to notice. A Google API has dozens of methods, and every one you keep is described to the model on every turn, which is what the callout at the end of this lesson is about. Name the two or three the agent needs and leave the rest out.

BigQuery: the hand-written one

BigQuery has a second toolset, written by hand rather than generated, because the generated one has too many overlapping methods for a model to choose between. It lives in google.adk.integrations.bigquery and needs the gcp extra. The tools it gives you are readable ones:

Example
import asyncio

from google.adk.integrations.bigquery import BigQueryCredentialsConfig, BigQueryToolset
from google.adk.integrations.bigquery.config import BigQueryToolConfig, WriteMode

config = BigQueryToolConfig(write_mode=WriteMode.BLOCKED)
credentials = BigQueryCredentialsConfig(client_id="YOUR_OAUTH_CLIENT_ID",
                                        client_secret="YOUR_OAUTH_CLIENT_SECRET")
toolset = BigQueryToolset(credentials_config=credentials, bigquery_tool_config=config)

for tool in asyncio.run(toolset.get_tools()):
    print(tool.name)

Eleven tools, and this listing ran here with a placeholder client id, because building the toolset asks Google for nothing: the credentials are used when a tool runs. execute_sql is the one that would worry you, which is why the config above exists, and why lesson 26 comes back to it.

It moved in 2.x
google.adk.tools.bigquery still works in 2.8 and warns that it is deprecated: the path is now google.adk.integrations.bigquery. The same move is happening to the other Google Cloud integrations, so import from google.adk.integrations in new code.

Choosing between a tool and an integration

You wantReach for
Your own logic, your own dataA function tool. Lesson 7
Something Google hosts, like searchA built-in tool, on its own agent if the limitation applies
A product with an existing connectorThe integration, rather than writing an API client
An external tool serverMCP, which ADK can consume as tools
A long tool list is not free
Every tool you add is described to the model on every turn, so a long list is a cost you pay continuously. Ten well described tools beat forty that overlap, and the moment you need forty, you need several agents instead.
Try it yourself
  • Look through the integrations list for something you already use at work.
  • Write down which of your team's jobs would need a hosted tool rather than a function.

Little by little, you're building something great.