Commit Graph

962 Commits

Author SHA1 Message Date
Zyan be16c617e7 Update lifespan per issue #1521 - 15
Adding documentation for lifespan argument in the `to_a2a` function to manage external resources like database connections.
2026-08-18 12:21:15 -06:00
Shahin Saadati e705f84906 Add Kotlin snippet for DebugLoggingPlugin (#2105)
* Add Kotlin snippet for DebugLoggingPlugin

The Kotlin logging page covered LoggingPlugin's console output but not
DebugLoggingPlugin, available since adk-kotlin 0.6.0, which records the same
activity in full to a YAML file instead of truncated console summaries. Both
plugins override the same twelve callbacks, so the difference really is only
fidelity and destination.

Transcluded from the existing LoggingExamples.kt rather than written inline,
matching the rest of the page and keeping it in the compile regression suite --
the file is already registered in files_to_test.txt.

The sample passes includeSystemInstruction = false, since the plugin's KDoc
cautions that it writes raw prompts, tool arguments and session state to disk.
Verified against the upstream test that the flag records has_system_instruction
in place of the instruction text rather than dropping the field, and the
comment names that field so it can be found in the output.

outputPath is left at its default rather than passed explicitly; the default
filename is given in the prose instead, so the snippet does not imply the
parameter is required.

Page badge left at Kotlin v0.1.0: the other snippets on the page have worked
since then, so the version requirement for this one is noted in the prose.

* docs: add Kotlin version support tag to debug logging documentation
2026-08-18 10:01:42 -07:00
Shahin Saadati 718bcf5c6d Document how to check whether the context cache was used (#2120)
* Document how to check whether the context cache was used

The caching page explained how to turn caching on and never how to tell whether
it is working. CacheMetadata has been available since adk-kotlin 0.6.0 and is
undocumented: adk-python has fourteen code references to cache_metadata, while
adk-docs mentions it twice, both incidental -- a BigQuery schema table and a
bullet in the Live dev guide.

The snippet reads it from Event.cacheMetadata and covers both states the type
can be in, because the constructor enforces the split: cacheName, expireTime and
invocationsUsed must either all be set (an active cache) or all be null (the
fingerprint-only state used for prefix matching before a cache exists).

Notes that token counts live on LlmResponse.usageMetadata rather than here,
which the KDoc calls out to avoid duplication and a reader would otherwise
reasonably look for on CacheMetadata.

Badged Kotlin v0.6.0 and verified rather than assumed: the snippet compiles
against a temporary 0.6.0 pin as well as the current 0.7.0 one.

Transcluded and registered, so CI compiles and lints it. Exercised all four
paths with synthetic events: no metadata, fingerprint-only, active, and active
with expireSoon true.

* Correct when CacheMetadata is present on an event

The section claimed every event backed by an LLM response carries a
CacheMetadata. It does not: LlmResponse.cacheMetadata is null when caching
is disabled and also when the call produced no cache information, so the
claim was wrong even with caching on.

Say "can carry", name both null cases, and explain why the snippet checks
before reading. The snippet's own comment made the same overstatement.

* docs: clarify the behavior of expireSoon and cache status in documentation and snippets
2026-08-17 15:40:28 -07:00
Shahin Saadati 5607a3c45d Document createHttpOptions on the Kotlin context cache config (#2115)
* Document createHttpOptions on the Kotlin context cache config

ContextCacheConfig gained a fourth parameter, createHttpOptions, in adk-kotlin
0.7.0. It bounds the CachedContent.create() call specifically, and is fail-open:
when the create exceeds the timeout it fails and the request proceeds uncached,
so it is a latency guard rather than a correctness switch. The snippet says so,
since that is the part the signature does not convey.

No other language documents this. Python and Java have no equivalent parameter
at all -- the Java record has exactly three components -- so this is Kotlin-first
rather than a backfill.

HttpOptions is ADK's own com.google.adk.kt.types.HttpOptions, deliberately not
the backend SDK's, so the import matters: two other types share the name.

Extracted, compiled and ran the snippet against the 0.7.0 pin: OK timeout=10s.

* docs: add create_http_options parameter documentation for cache configuration
2026-08-17 15:24:27 -07:00
Shahin Saadati 772a0639d5 Add Kotlin snippet for token-threshold context compaction (#2107)
* Add Kotlin snippet for token-threshold context compaction

The compaction page had no Kotlin at all. EventsCompactionConfig gained
tokenThreshold and eventRetentionSize in adk-kotlin 0.6.0, so the Kotlin tab
shows that pair, matching the TypeScript tab's strategy.

Kotlin sits across the two groupings the prose already draws: the config
attaches to App, as in Python and Java, but supports the token-threshold pair
like TypeScript. Both parentheticals are updated to say so rather than adding
new prose.

The snippet notes that tokenThreshold and eventRetentionSize must be set
together. That is a runtime require, not a compile error, so it is easy to hit:
setting one alone throws "tokenThreshold and eventRetentionSize must be set
together or both null". The same rule applies to compactionInterval and
overlapSize, which Kotlin also supports.

Badged Kotlin v0.7.0 rather than 0.6.0, when the fields landed: appName is
"my-agent" to match the sibling tabs, and hyphens in app names were only
allowed from 0.7.0.

Inline to match the page's other tabs, so CI will not compile it. Extracted,
compiled and ran it against the 0.7.0 pin in a throwaway project:
OK app=my-agent tokenThreshold=1000 retention=1 paired=true.

* Note that Kotlin also supports the sliding-window pair

Self-review finding. The Kotlin tab shows tokenThreshold/eventRetentionSize
while Python and Java show compactionInterval/overlapSize, so a reader
comparing tabs could conclude the strategy is fixed per language. It is not:
EventsCompactionConfig accepts either pair, and exposes hasTokenThresholdConfig
and hasSlidingWindowConfig for each.
2026-08-17 15:13:28 -07:00
Shahin Saadati f9ae6d937c Add Kotlin snippet for VertexAiSessionService (#2102)
* Add Kotlin snippet for VertexAiSessionService

The VertexAiSessionService section showed Python, Go and Java. Kotlin gained
the service in adk-kotlin 0.7.0, so add a Kotlin tab and Kotlin to that
section's language-support badge.

Kotlin addresses the reasoning engine differently from every sibling tab on
the page, so the snippet says so at the point of use:

- The engine is fixed at construction via `reasoningEngineId`. The 0.7.0 KDoc
  is explicit that, unlike the Python and Java ADK, `SessionKey.appName` is
  never parsed to derive the engine -- it is only a label. The Python tab
  above passes the engine through `app_name` on each call.
- `reasoningEngineId` must be the bare numeric id. The constructor rejects a
  full resource name outright (`require(reasoningEngineId.all { it.isDigit() })`),
  while the Python tab passes
  `projects/.../locations/.../reasoningEngines/...`.

A reader copying the adjacent Python idiom would therefore fail twice over.

Written inline to match the two existing Kotlin tabs on this page. Inline
snippets never reach Gradle, so this one was additionally compiled against the
0.7.0 pin in a scratch file that is not part of the commit.

* Address review: JVM-only note, wire the service to a Runner

Five fixes from self-review against the 0.7.0 sources and upstream's own
VertexAiSessionServiceExample.kt, which I should have consulted before writing
the first version:

- State that the service is JVM-only. It lives in core/src/jvmMain, so it does
  not exist on Android. Kotlin is the only language on this page where that
  distinction applies, so if the Kotlin tab omits it, nothing carries it.
- Show the service actually being used. The snippet stopped at an uncalled
  `suspend fun`; it now hands the service to an InMemoryRunner, which is what
  the section is about and what the upstream example does.
- Use `runBlocking` in a `main`, matching upstream, instead of a suspend
  function nothing calls.
- Drop `state = mapOf(...)`. It defaults to null, upstream omits it, and the
  Java tab explicitly notes no initial state is needed, so it introduced a
  concept the sibling tabs deliberately avoid.
- Widen the comparison from "the Python and Java tabs" to all the other tabs.
  The KDoc phrasing names Python and Java, but this page also has a Go tab.

The added LlmAgent needs an explicit `model`; the first draft would not have
compiled without it, which the scratch compile caught.

* Trim the snippet back to parity with the sibling tabs

The previous revision added an LlmAgent, a Gemini model and an InMemoryRunner,
taking the tab to 30 code lines against Python's 5, Go's 8 and Java's 12. No
sibling tab on this page constructs a runner or an agent, and this section's
prose never mentions one -- it is a characteristics list, not a wiring guide.

That change came from misapplying a review finding. On sessions/memory the
equivalent note was right: the prose there says "instantiating the
VertexAiMemoryBankService and passing it to the Runner" and the Python tab
shows exactly that. Neither holds here, so the runner was answering a question
this page does not ask.

Now scoped like the Java tab, the closest analogue: construct the service, then
create one session. That is still enough to demonstrate both divergences -- the
engine pinned at construction as a bare numeric id, and appName being only a
label -- since showing the second requires a SessionKey.

`runBlocking` stays, because createSession is a suspend function; it is the
direct counterpart of the Java tab's `.blockingGet()`, and the comment now says
so. Recompiled against the 0.7.0 pin in a scratch file.

* docs: update experimental annotation placement and refine context caching documentation note
2026-08-17 14:56:57 -07:00
George Weale c236a946a7 docs(callbacks): correct Python callback signatures and return types (#2016)
* docs(callbacks): correct Python callback signatures and return types

* docs(callbacks): state the real chain-stop rule per callback family

* docs(callbacks): tighten wording and drop out-of-scope safety page edits

* Update index.md

* Update types-of-callbacks.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-14 16:06:26 -07:00
George Weale 5cd8d56dbe docs(runtime): correct API routes, CLI flags, and RunConfig fields (#2020)
* docs(runtime): correct API routes, CLI flags, and RunConfig fields

* docs(runtime): correct per-agent service URI defaults and resume version

* docs: drop e.g. from the adk run timeout flag description

* Update event-loop.md

* Update runconfig.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-14 14:47:21 -07:00
George Weale 1bd29540df docs(evaluate): fix conformance CLI, defaults, optimizer imports (#2018)
* docs(evaluate): fix conformance CLI, defaults, optimizer imports

* docs(evaluate): fix App construction, agent path type, user-sim coverage

* docs: drop parenthetical asides and future tense from the evaluate corrections

* Update environment_simulation.md

* Update user-sim.md

* Update user-sim.md

* Update index.md

* Update index.md

removing repetitive (and soon out of date) default model declarations.

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-14 14:04:31 -07:00
George Weale c85aecd2a9 docs(sessions): fix async examples, imports and state claims (#2017)
* docs(sessions): fix async examples, imports and state claims

* docs(sessions): correct event id/timestamp ownership and artifact service list

* docs: apply style guide pass and revert out-of-scope artifact section

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-14 20:41:03 +00:00
Shahin Saadati c317e48208 Add Kotlin tabs for creating and registering a plugin (#2119)
adk-kotlin 0.7.0 added a plugins parameter to the agent-based InMemoryRunner
constructor. App.plugins already existed at 0.6.0, so this is an ergonomic
shorthand rather than a new capability, but it is the form a Kotlin reader
should see and the plugins page had no Kotlin at all.

Two tab groups rather than one. The Register group's prose refers to
"the CountInvocationPlugin plugin defined in the previous section", so a Kotlin
tab there alone would point at a class the page never defines in Kotlin. Adding
the Create group as well makes the pair self-contained.

Kotlin now appears in two of the page's nine groups; the remaining seven are
per-callback detail. Whether to finish the page is a separate decision.

Plugin declares exactly one abstract member, name -- all twelve callbacks and
close() have defaults -- so a custom plugin only overrides what it needs. The
snippet overrides beforeAgent and beforeModel, matching the callbacks the
surrounding prose describes.

Transcluded and registered, so CI compiles and lints it. Also run: the runner is
constructed with the plugin wired, and invoking beforeAgent twice prints
"[Plugin] Agent run count: 1" then 2, so the counter callbacks work.
2026-08-14 07:57:23 -07:00
Shahin Saadati 6b8b086052 Add Kotlin snippet for remote MCP with a suspend headerProvider (#2113)
* Add Kotlin snippet for remote MCP with a suspend headerProvider

The MCP tools page had no Kotlin content. This adds a Kotlin tab to the
"Agent Configuration for Remote MCP" group, where it differs from the sibling
tabs in a way worth showing: adk-kotlin 0.7.0 made McpToolset's headerProvider
a suspend function, so a token can be minted per request rather than baked in
as a static header the way the Python and Java tabs do.

Two things the snippet has to get right, both of which a reader porting from
the Java tab would otherwise hit:

- McpToolset's constructor is internal. The Java tab's
  `new McpToolset(streamableParams)` has no Kotlin equivalent; instances come
  from McpToolsetConfig.toToolset(), as the KDoc directs. Confirmed by
  compiling the direct form, which fails with "Cannot access 'constructor
  (...)': it is internal".
- Supplying a headerProvider disables session reuse, so that headers can vary
  per context. That is a real cost, so the comment says so and points at static
  headers on StreamableHttp for callers who want a single cached session.

Badged Kotlin v0.7.0: the page had no Kotlin badge, and the suspend
headerProvider signature is 0.7.0.

Inline to match the page's other tabs, so CI will not compile it. Extracted,
compiled and ran it against the 0.7.0 pin in a throwaway project:
OK toolset=McpToolset.

* Tighten the MCP snippet after self-review

Three presentation fixes; no change to what the snippet does.

- Comment cut from five lines to three. The Python and Java tabs in this group
  carry a single comment line each, so the original block was well out of step
  with its neighbours.
- Closed the config constructor before chaining .toToolset(), removing an
  eight-space hanging indent that no formatter would produce. Nothing catches
  it, since inline snippets are never linted.
- Said that fetchToken() awaits. The v0.7.0 badge on this page rests entirely
  on that: headerProvider existed at 0.6.0, just not as a suspend function.
  Compiling the snippet against a 0.6.0 pin confirms it -- with a suspend
  fetchToken() it fails, with a plain one it compiles. A reader whose token
  source is synchronous does not need 0.7.0, and nothing in the visible code
  said which case this is.

Re-ran the snippet against the 0.7.0 pin: OK toolset=McpToolset.
2026-08-13 08:30:49 -07:00
Zyan a7584a1dc9 Create integration page for Bashtool per Issue 1438 - 5 (#2048)
* Create bashtool.md

This PR adds the integration documentation for the new ExecuteBashTool in the Python ADK.

Rendered view:
Agent's PR: #1442 
Original Issue: #1438  

Key additions:

- Documented the tool's core capabilities and experimental status.
- Added security and execution safeguards (User Confirmation, Command Validation, Resource Limits, Disabled Core Dumps, and Process Group Termination).
- Reviewed against ADK integration-create and review guidelines 
- Checked against the repository> https://github.com/google/adk-python/blob/ecb759cc16bc870aa190d01c4c3f0e1e3e97afab/src/google/adk/tools/bash_tool.py

Icon PR: #2047

* Update bashtool.md

* Update bashtool.md

* Add files via upload

* Add files via upload
2026-08-12 15:54:16 -06:00
George Weale d9e930e823 docs(integrations): fix unresolvable imports and stale API claims (#2031)
* docs(integrations): fix unresolvable imports and stale API claims

* docs: apply style pass and drop out-of-scope import cleanup

* docs(integrations): address review feedback on gcs, cloud-trace, reflect-and-retry

Restore the gcs_ tool name prefixes in the GCS tool tables, since both
toolsets set tool_name_prefix="gcs" and the tables list names as the
model sees them. Use the current Agent Platform SDK name in cloud-trace
prose, make the reflect-and-retry failure description language-neutral
for Python and Go, and drop the redundant re-export clause.

* docs(gcs): note that tool_filter matches unprefixed tool names

Tool filtering runs inside get_tools() against the unprefixed name, and
get_tools_with_prefix() applies the gcs_ prefix afterwards, so the names
in the tables are not the names tool_filter expects.

* docs(computer-use): drop unused Gemini and override imports

---------

Co-authored-by: Kristopher Overholt <koverholt@google.com>
2026-08-11 18:11:00 -05:00
adk-bot 60b802ed32 ADK_SUPPRESS_A2A_EXPERIMENTAL_FEATURE_WARNINGS #1521 - 25 (#1533)
* Update ADK doc according to issue #1521 - 25

* Document suppression of experimental feature warnings

Added instructions to suppress experimental feature warnings in logs in a note, whole section deleted

* Document suppression of experimental warnings

Added information on suppressing experimental feature warnings in logs.

* Update quickstart-exposing.md

---------

Co-authored-by: Juan Carlos Gonzalez Resendiz <juancarlosgon@google.com>
Co-authored-by: Zyan <zyanya@google.com>
2026-08-10 14:30:12 -06:00
Shahin Saadati d94dc2cd1b Add Kotlin snippet for context caching configuration (#2091)
* Add Kotlin snippet for context caching configuration

The context caching page showed Python and Java only. `ContextCacheConfig` and
the `App`-level wiring are available in adk-kotlin as of 0.7.0, so add a Kotlin
tab and advertise Kotlin support in the page badge.

The snippet is inline rather than transcluded to match the Python and Java tabs
on this page. It opts in at file level via `ExperimentalContextCachingFeature`,
which the API still requires, and uses `kotlin.time` durations so the TTL reads
as `10.minutes` rather than a `Duration.ofMinutes` call.

* Fix broken links to adk-python plugin samples

The three plugin sample links 404. adk-python renamed
`contributing/samples/plugin/` to `contributing/samples/plugins/`; the
directory contents are otherwise unchanged, so only the path segment moves.

This is what the repo-wide `link-check` job has been failing on. It is
unrelated to the 0.7.0 upgrade in this PR, but the check gates the merge and
the fix is confined to the three URLs.

Verified all three targets return 200.

* Use a minTokens value that actually has an effect

The snippet carried Python's `minTokens = 2048`. The 0.7.0 KDoc is explicit
that "Gemini enforces a hard 4096-token minimum that always applies, so values
below 4096 have no additional effect" -- so as written the line was inert and
the comment implied otherwise. Use a value above the floor and say where the
floor comes from.
2026-08-10 09:57:20 -07:00
Shahin Saadati 12c70c7106 Add Kotlin snippets for Memory Bank and RAG memory (#2089)
* Upgrade Kotlin examples to adk-kotlin 0.7.0

The Kotlin examples were pinned to adk-kotlin 0.5.0, which predates the
context caching, Vertex AI memory, and RAG retrieval APIs. Bump the pin to
0.7.0 so snippets for those features can be added.

Three consequences of the bump are handled here:

- `ExperimentalResumabilityFeature` was removed in 0.7.0, so RunConfigExample
  no longer opts into it. The annotation class is gone, not merely deprecated,
  so this is a hard compile break rather than a warning that could be deferred.
- The Vertex AI session and memory services expose Ktor's `HttpClient` as a
  defaulted constructor parameter, so any snippet naming them needs Ktor on the
  compile classpath, not just at runtime.
- The `resolutionStrategy` block forcing kotlin-stdlib 2.1.20 is now dead. It
  worked around 0.5.0 publishing a stdlib newer than this project's compiler;
  0.6.0 fixed that upstream. Verified that the highest stdlib on the compile
  classpath is still 2.1.20 without it.

Also fixes two unrelated snags found while validating the above:

- `check_kotlin_snippets.sh` walked `examples/kotlin` without pruning build
  output, so after any local build it reported every generated KSP file as an
  unregistered snippet. CI only ever ran it against a clean checkout, so the
  bug was invisible there.
- A transclusion path in logging.md was split across two lines, so the include
  never resolved and the code block rendered empty.

* Fix broken links to adk-python plugin samples

The three plugin sample links 404. adk-python renamed
`contributing/samples/plugin/` to `contributing/samples/plugins/`; the
directory contents are otherwise unchanged, so only the path segment moves.

This is what the repo-wide `link-check` job has been failing on. It is
unrelated to the 0.7.0 upgrade in this PR, but the check gates the merge and
the fix is confined to the three URLs.

Verified all three targets return 200.

* Add Kotlin snippets for Memory Bank and RAG memory

The memory page documented `VertexAiMemoryBankService` and
`VertexAiRagMemoryService` for Python and Java only; the Kotlin tab stopped at
the in-memory service. Both are available in adk-kotlin as of 0.7.0, so add
the two missing tabs.

Both services declare an `internal` primary constructor, so the snippets use
the public secondary one that takes project/location plus the engine or corpus
id -- reading the primary signature alone gives a constructor callers cannot
invoke.

The page's language-support badge stays at Kotlin v0.1.0: it marks when Kotlin
support for the page was introduced, and the other six Kotlin snippets on it
have worked since then.

The remaining diff in MemoryExample.kt is ktlint bringing pre-existing lines
into line with the repo style, which the linter now gates on because the file
is touched here.

* Correct the ragCorpus contract and wire both services to a Runner

Three fixes from review:

- The `rag_memory` KDoc claimed `ragCorpus` accepts a bare id or a full
  resource name. It is the opposite: `normalizeCorpusName` does
  `require(!ragCorpus.startsWith("projects/"))` and throws on a full name. The
  Python tab directly above this snippet passes a full resource name, so a
  reader switching tabs would have hit an IllegalArgumentException with a
  comment telling them it was fine. The note now states the bare-id rule and
  calls out the divergence from Python explicitly.
- Dropped "the primary constructor is internal" from the rendered snippet. It
  is a note for reviewers, not for readers, who cannot see that constructor.
  It stays in the PR description.
- Both snippets stopped at a factory function while the surrounding prose says
  "instantiating the service and passing it to the Runner" and the Python tab
  shows exactly that. They now build the service and pass it to a Runner.
2026-08-10 08:29:26 -07:00
Shahin Saadati 34d4ec2921 Add Kotlin snippet for the Knowledge Engine retrieval tool (#2090)
* Upgrade Kotlin examples to adk-kotlin 0.7.0

The Kotlin examples were pinned to adk-kotlin 0.5.0, which predates the
context caching, Vertex AI memory, and RAG retrieval APIs. Bump the pin to
0.7.0 so snippets for those features can be added.

Three consequences of the bump are handled here:

- `ExperimentalResumabilityFeature` was removed in 0.7.0, so RunConfigExample
  no longer opts into it. The annotation class is gone, not merely deprecated,
  so this is a hard compile break rather than a warning that could be deferred.
- The Vertex AI session and memory services expose Ktor's `HttpClient` as a
  defaulted constructor parameter, so any snippet naming them needs Ktor on the
  compile classpath, not just at runtime.
- The `resolutionStrategy` block forcing kotlin-stdlib 2.1.20 is now dead. It
  worked around 0.5.0 publishing a stdlib newer than this project's compiler;
  0.6.0 fixed that upstream. Verified that the highest stdlib on the compile
  classpath is still 2.1.20 without it.

Also fixes two unrelated snags found while validating the above:

- `check_kotlin_snippets.sh` walked `examples/kotlin` without pruning build
  output, so after any local build it reported every generated KSP file as an
  unregistered snippet. CI only ever ran it against a clean checkout, so the
  bug was invisible there.
- A transclusion path in logging.md was split across two lines, so the include
  never resolved and the code block rendered empty.

* Fix broken links to adk-python plugin samples

The three plugin sample links 404. adk-python renamed
`contributing/samples/plugin/` to `contributing/samples/plugins/`; the
directory contents are otherwise unchanged, so only the path segment moves.

This is what the repo-wide `link-check` job has been failing on. It is
unrelated to the 0.7.0 upgrade in this PR, but the check gates the merge and
the fix is confined to the three URLs.

Verified all three targets return 200.

* Add Kotlin snippet for the Knowledge Engine retrieval tool

The Knowledge Engine integration page only showed Python. `VertexAiRagRetrieval`
landed in adk-kotlin 0.7.0, so add a Kotlin tab and advertise Kotlin support in
the page badge.

Retrieval runs inside the model through the Gemini-native `vertexRagStore` kind
rather than as a locally executed tool, so the snippet configures the corpus via
`VertexRagStoreRagResource` and leaves invocation to the model.

Registers the new file in files_to_test.txt so it stays in the compile
regression suite.

* Use the conventional package for the RAG retrieval snippet

RagEngine.kt declared `package integrations`. Every other snippet in the tree
uses `com.google.adk.kt.examples.<area>`. It compiled either way because the
source root is `snippets/` and Kotlin does not require the directory to match
the package, so nothing would have caught it.

Also worth flagging for anyone reading this alongside the memory snippets: the
two APIs take opposite corpus formats. `VertexAiRagRetrieval` here wants the
full `projects/.../ragCorpora/...` resource name, while
`VertexAiRagMemoryService` wants a bare corpus id and rejects the full name.
That is the library's doing, not a docs inconsistency.
2026-08-10 08:22:15 -07:00
Milen Kovachev ab749867b0 docs(eventarc): Address technical verification report feedback (#2074)
- Add pip install "google-adk[gcp]" step to Eventarc Prerequisites.
- Clarify datacontenttype inference defaults and specify application/json in snippet prompt.
- Update Runtime Lambda table entry to use ctx.session_id and note support for payload and Context.
- Update OMIT table entry to list all mandatory attributes (type, source, bus, id, specversion).

Addresses feedback in https://github.com/google/adk-docs/pull/2045#issuecomment-5184438669

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-07 20:30:29 +00:00
Shahin Saadati b1b2eaa102 Upgrade Kotlin examples to adk-kotlin 0.7.0 (#2088)
* Upgrade Kotlin examples to adk-kotlin 0.7.0

The Kotlin examples were pinned to adk-kotlin 0.5.0, which predates the
context caching, Vertex AI memory, and RAG retrieval APIs. Bump the pin to
0.7.0 so snippets for those features can be added.

Three consequences of the bump are handled here:

- `ExperimentalResumabilityFeature` was removed in 0.7.0, so RunConfigExample
  no longer opts into it. The annotation class is gone, not merely deprecated,
  so this is a hard compile break rather than a warning that could be deferred.
- The Vertex AI session and memory services expose Ktor's `HttpClient` as a
  defaulted constructor parameter, so any snippet naming them needs Ktor on the
  compile classpath, not just at runtime.
- The `resolutionStrategy` block forcing kotlin-stdlib 2.1.20 is now dead. It
  worked around 0.5.0 publishing a stdlib newer than this project's compiler;
  0.6.0 fixed that upstream. Verified that the highest stdlib on the compile
  classpath is still 2.1.20 without it.

Also fixes two unrelated snags found while validating the above:

- `check_kotlin_snippets.sh` walked `examples/kotlin` without pruning build
  output, so after any local build it reported every generated KSP file as an
  unregistered snippet. CI only ever ran it against a clean checkout, so the
  bug was invisible there.
- A transclusion path in logging.md was split across two lines, so the include
  never resolved and the code block rendered empty.

* Fix broken links to adk-python plugin samples

The three plugin sample links 404. adk-python renamed
`contributing/samples/plugin/` to `contributing/samples/plugins/`; the
directory contents are otherwise unchanged, so only the path segment moves.

This is what the repo-wide `link-check` job has been failing on. It is
unrelated to the 0.7.0 upgrade in this PR, but the check gates the merge and
the fix is confined to the three URLs.

Verified all three targets return 200.
2026-08-07 13:24:29 -07:00
George Weale 839e898fcf docs(tutorials): fix ToolContext, output_key and persistence claims (#2032)
* docs(tutorials): fix ToolContext, output_key and persistence claims

* Update agent-team.md

* docs: address review — revert get-started changes, move streaming note

Reverts docs/get-started/python.md entirely and drops the edit to the
retired quickstart-streaming.md page. The corrected streaming caveat now
lands on docs/live/get-started/streaming-python.md, scoped to the
run_async path and naming SequentialAgent as the only workflow agent
with live support.

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-07 13:15:39 -07:00
Lucas Kang 88dbd90cae docs: add telemetry disclosure notices to Web UI and CLI docs (#2092)
* docs: add telemetry consent notice to Web UI docs

* docs: add telemetry consent notice to CLI docs

* Update index.md

* Update command-line.md

* Update index.md

* Update command-line.md

* Update command-line.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-07 10:55:21 -07:00
George Weale ab2d035e0d docs(observability): correct metric names, span attributes, logger names (#2013)
* docs(observability): correct metric names, span attributes, logger names

* docs(observability): restore otel_to_cloud metrics recipe, fix log-level fallback

* Update logging.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-07 10:28:30 -07:00
George Weale 80bdb8d0af docs(a2a): fix unresolvable imports, wrong kwargs and sample paths (#2014)
* docs(a2a): fix unresolvable imports, wrong kwargs and sample paths

* docs(a2a): correct port/agent_card semantics and the a2a_basic sample

* Update quickstart-consuming.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-07 17:08:47 +00:00
Zyan e25527b1dd Create enterprise web search integration page per issue #1113 - 3 (#2058)
* Create enterprise-web-search.md

Rendered page:
Logo's PR: #2057 
Agent's PR: #1121 and #1122 
Original Issue: #1113 

--

This PR adds the official documentation for the new EnterpriseWebSearchTool.

Key additions:

- Overview & Use Cases: Explains enterprise compliance, controlled web access, and regulated workflows.
- Code Examples checked against repositories: Provides initialization snippets for both Python (google-adk) and TypeScript (@google/adk).

* Update enterprise-web-search.md

* Update enterprise-web-search.md
2026-08-06 17:00:24 -06:00
Zyan 135350b340 Logo for Enterprise Web Search integration page (#2057) 2026-08-06 16:57:20 -06:00
Zyan 4453bcd1f6 Add allow_origins flag to cloud run page per issue #1113 - 1 (#2064)
* Add allow_origins flag to cloud run page per issue #1113 - 1

Rendered page: 
Agent's PR: #1118 
Original Issue: #1113 

--

This PR updates the deployment documentation to include --allow_origins flag (with regex support).

While the original draft suggested updating multiple pages, a review of the live site confirmed that this feature is already documented in the main CLI reference for the api_server and web commands.

Additional format changes:

- Fixed Markdown rendering bugs: Repaired broken code blocks in the Environment variables and Cloud Build permissions sections, fixed the misplaced Secret command, and corrected the malformed numbered list under Prerequisites.
- Style changes.

* Update cloud-run.md

* Update cloud-run.md
2026-08-06 16:54:48 -06:00
Zyan 2af8fdeea0 Update GlobalInstructionPlugin per issue #1227 - 10 (#2065)
Rendered page:
Agent's PR: #1244 
Original Issue: #1227 

--

The formal deprecation note for the old global_instruction parameter is already in the source code and API documentation (https://adk.dev/api-reference/python/google-adk.html) (https://adk.dev/plugins/).

Additionally I added a note here to explain it.
2026-08-06 19:12:50 +00:00
Zyan c07062e153 Add optimization section in agent index per issue #1227 - 12 (#2059)
* Add optimization section in agent index per issue #1227 - 12

Rendered page:
Agent's PR: #1248 
Original Issue: #1227

* Update index.md
2026-08-06 13:12:07 -06:00
Kristopher Overholt d5ad625366 Add July 2026 ADK Community Call recording (#2073)
Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-05 23:32:16 +00:00
Amaad Martin c75e61f5f3 docs: normalize Typescript to TypeScript across the site (#2079)
The site rendered one language under two names. Tab labels were split
137 `TypeScript` / 53 `Typescript`, with three pages carrying both
spellings at once (custom-agents.md 7/7, patterns.md 1/7,
function-tools.md 4/1), and the language-support badges were split 67/18
the same way. Because pymdownx.tabbed slugifies tab labels to lowercase,
both variants rendered and linked fine, so no link check or build warning
ever flagged it -- it was visible only to readers, as two names for one
SDK.

Every user-visible occurrence is normalized to `TypeScript`, plus the two
inconsistencies that turned up while doing it. 80 changed lines, accounted
for exactly:

  53  tab label       === "Typescript"            -> === "TypeScript"
  18  badge span      lst-typescript">Typescript  -> TypeScript
   3  prose mention   cloud-run.md, mcp-tools.md, workflows/patterns.md
   2  api-reference/index.md card heading and link text
   1  badge div attr  title="...Python and Typescript."
   1  mkdocs.yml nav  Typescript ADK              -> TypeScript ADK
   1  code fence      ```javascript -> ```typescript on a .ts include
   1  artifacts/index.md closing summary sentence
  ---
  80

The first six rows are pure casing: 78 lines that differ from their
originals by nothing but `Typescript` -> `TypeScript`. The last two are
not, and are the reason this is not a `sed`:

llm-agents.md:872 fenced `--8<-- ".../capital_agent.ts"` as ```javascript.
It was the only javascript-fenced `.ts` include in docs/ (the other 189
TypeScript fences are correct), and it cost that one snippet its
TypeScript highlighting.

artifacts/index.md:1084 closed the page by naming languages and got the
list wrong. It described reaching the artifact methods "using Python's
context objects or directly interacting with the `BaseArtifactService` in
Java" -- a two-language enumeration at the end of a page that carries
Python, TypeScript, Go, Java and Kotlin tabs (11/10/10/10/11), and one
that contradicts :556, which correctly names four of them. The
enumeration is dropped rather than extended: the sentence now describes
the two ways to reach these methods -- through the context object, or
through `BaseArtifactService` -- which is what the page actually teaches
and does not rot when a sixth language is added.

docs/api-reference/index.md is included even though the rest of
docs/api-reference/ is generated output that must not be touched. That
tree holds 3,140 generated HTML files and exactly one hand-authored page:
this one. It is Markdown, it is the only api-reference entry mkdocs.yml
lists as `.md` rather than `index.html` (:272, :441), it uses Material
`grid cards` and `:fontawesome-*:` shortcodes, and it carries a
`CONTRIBUTORS:` note citing issues #1716 and #1717. Its TypeScript card
already said "TypeScript" twice in its body text while its heading and
link text said "Typescript"; those two are now consistent with the body.
No generated file is modified.

Not in this change: the broken `SseConnectionParams` sample in
mcp-tools.md (docs-ts/p6c-mcp-ts-sample) and the `@google/adk` example
version bumps (docs-ts/p6b-example-versions). Only the casing of the
prose line above that sample is touched here.

Verified: `mkdocs build` exits 0 with an empty warning set on both main
and this branch, and the two warning sets are identical. A rendered
before/after diff of the whole site shows every `__tabbed_*` id, every
tab radio id and every heading anchor unchanged. Zero `=== "Typescript"`
and zero `lst-typescript">Typescript` remain anywhere in the repo.

Co-authored-by: Amaad Martin <amaadmartin@google.com>
2026-08-05 15:58:49 -07:00
Haiyuan Cao 0fba5aa6f0 Enhance BigQuery Agent Analytics documentation (#2028)
* Enhance BigQuery Agent Analytics documentation

Updated documentation to clarify Java and Python plugin differences, added details on dropped-event observability, and improved explanations of event types and attributes.

* Address review: use language support tags and a single drop-reasons table

- Replace the inline Java version callouts in prose with language-support-tag
  blocks on the relevant sections (Built-in redaction, Dropped-event
  observability; ADK 2.0 workflow events already carried one).
- Collapse the duplicated 'Drop reasons (Python)' / 'Drop reasons (Java)'
  tables into a single table with a per-language column.
- Trim the duplicated Java scope prose in the intro and the ADK 2.0 note.

---------

Co-authored-by: Kristopher Overholt <koverholt@google.com>
2026-08-05 08:50:09 -05:00
Joe Fernandez 1d8a608348 docs(live): Refactor streaming docs, move streaming/ to live/ directory (#2063)
Co-authored-by: Shahin Saadati <happyhuman@users.noreply.github.com>
2026-08-04 16:09:24 -07:00
Milen Kovachev 9f1ae0d3f0 docs: add Eventarc tool integration page and code snippets (#2045)
* docs: add Eventarc tool integration page and code snippets

- Document general-purpose EventarcToolset and publish_message tool
- Document domain-specific create_publish_tool with static, dynamic, and runtime lambda attribute bindings
- Add complete, runnable Python code snippets for both built-in tool and domain-specific publishing
- Add Eventarc icon asset

* Improve the documentation after running integration-review script.

* Update eventarc.md

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-04 20:48:26 +00:00
George Weale 71dc8b0b61 docs(models): fix unparseable snippets and stale Claude setup steps (#2012)
* docs(models): fix unparseable snippets and stale Claude setup steps

* docs(models): correct apigee retry claim, LlmResponse.text, McpToolset spelling

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-08-03 16:38:17 -07:00
Zyan 308c783180 Update slack integration page tag to connectors (#2049) 2026-07-31 18:18:26 -05:00
Joe Fernandez 9dae39408d docs (python): Python API Reference docs v2.6.0 (#2039)
- generated using https://github.com/google/adk-docs/tree/main/tools/python-api-docs
2026-07-31 13:51:30 -07:00
Zyan e62aa9b2d3 Create slack runner integration page #1521 - 4 (#2035)
* Create slack runner integration page #1521 - 4

Adds the official integration documentation for `SlackRunner`. 

- Created `docs/integrations/slack.md` following the Plugin template.
- Added Socket Mode installation and initialization instructions (`google-adk[slack]`).
- Checked against the integration-review and integration-create instructions.

* Update slack.md

* Update slack.md

Worked on feedback
2026-07-31 14:23:17 -06:00
Mikalai Senkevich f58f09c0df docs: add documentation for OpenAI model support in ADK agents (#2000)
Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-07-31 18:29:21 +00:00
Kristopher Overholt bc749667a7 Update API reference docs for ADK TypeScript 1.5.0 (#2040) 2026-07-31 18:21:37 +00:00
Joe Fernandez 3e4a9ea715 docs: Update REST API reference to 2.6.0 (#2042)
* git

* docs: Update REST API reference to 2.6.0
2026-07-31 11:20:00 -07:00
Joe Fernandez c7827b6335 git (#2041) 2026-07-31 11:19:06 -07:00
Zyan cd66bc5128 Update propagate grounding metadata as per Issue #1587 - 6 (#2033)
* Update propagate grounding metadata as per Issue #1587 - 6

Rendered view
PR #1598 
Original Issue #1587 

--

- Improved explanation of original ask bot draft
- Added code example

* Update function-tools.md

* Update function-tools.md

* Update function-tools.md
2026-07-31 12:11:57 -06:00
Shivansh Sharma 0e1d6094e9 docs: document new RunConfig parameters (#2006)
Co-authored-by: SHAI-shivansh-sharma <SHAI-shivansh-sharma@users.noreply.github.com>
2026-07-31 15:45:42 +00:00
Shobhit Singh de510f8059 docs: remove experimental banner from data agent tools (#2037)
* docs: remove experimental banner from data agent tools

* Update data-agent.md

also remove "Experimental" tag subheader

---------

Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-07-31 08:15:21 -07:00
Zyan b0c2f1665a Slack logo (#2036)
Uploading png image for Slack logo
2026-07-30 20:56:41 -06:00
Zyan 7f1ce79a6f Update custom_metadata per Issue 1292 - 8 (#1983)
* Update custom_metadata per Issue 1292 - 8

Rendered page:
Agent PR: #1306 
Original Issue: #1292 

-Polished the explanation of how and why custom_metadata works. It now clearly outlines how developers can pass service-specific configurations (like ttl and revision_ttl) directly to the underlying Agent Platform.
- I found that the add_events_to_memory(events=...) section that the agent was proposing was already documented in the site.

* Update memory.md

Worked on feedback. Updated the custom metadata documentation to use a generic BaseMemoryService example instead of platform-specific services. The code snippet was also revised to use generic key-value pairs rather than prescriptive TTL keys.
2026-07-30 20:49:29 -06:00
Umer Ali b30cf33cd4 docs: fix missing imports in custom agents and graph routes examples (#1995)
Co-authored-by: Joe Fernandez <931947+joefernandez@users.noreply.github.com>
2026-07-30 23:03:54 +00:00
Joe Fernandez c2c5359807 Update code-exec-agent-runtime.md (#2034) 2026-07-30 15:29:08 -07:00
Zyan 890af7cf79 Add Spanner Admin Toolset per issue #1521 - 6 (#1998)
* Update Spanner Toolset per issue #1521 - 6

Rendered page:
PR: #1525 
Original Issue #1521 

---

- Updated the page to add the Spanner admin toolset info with examples.
- Added configuration details for environment variables.
- Added alias for gemini-flash-latest to the bot's original snippet.
- Added contextual system instruction for the agent.

* Update spanner.md
2026-07-29 12:42:44 -06:00