Migrating from ADK-Rust 2.x to 3.0

3.0.0 is a major release. This guide lists the breaking changes between the published 2.3.0 crates and 3.0.0: the API breaks and the behaviour changes that need a code change or a decision. Crates that are new in 3.0.0 have no 2.x users and are not covered. The CHANGELOG has the full entry for each.

Note: the API breaks come from the release's changelog entries and from a comparison of the public structs, enums, trait methods and function signatures of every crate published at 2.3.0 between the v2.3.0 tag and 3.0.0. cargo semver-checks has not been run against 2.3.0 for 3.0.0: the semver CI job runs with SEMVER_RELEASE_TYPE: major, which accepts every change.

Related guides:

Moving fromGuide
SQLx 0.8 pools, migrations and feature flagsSQLx 0.9 in ADK-Rust 3.0
An AWP 1.x site (business.toml, /awp/* routes)Migrating from AWP 1.x to 2.0
adk_agent::coding::CodingAgentMigrating from CodingAgent to the harness
ADK Studio 1.xADK Studio: Studio 3 is in development against ADK-Rust 3.0
adk-ui 2 render toolsAgent-drawn UI
The runtime UI that adk-server served at /ui/The web home

Update every adk-* dependency together — the crates are versioned in lockstep:

[dependencies]
adk-rust = { version = "3.0.0", features = ["standard"] }

Quick reference

If your code…Do this
passes a reqwest::Client or other reqwest type to an adk-* APIdepend on reqwest = "0.13" (reqwest 0.13)
builds RunConfig, EventActions, LlmResponse or another config struct with a literalend the literal with ..Default::default() or use the constructor (struct literals)
builds RunnerConfig with a literaluse Runner::builder()
matches exhaustively on ErrorCategory, GraphError, GuardrailError, an adk-anthropic enum, or another enum in the tableadd the new arms
matches on FinishReason, or shows a model's refusal as its answeradd a wildcard arm, and expect a refusal to fail the run with model.refusal (refusals)
relies on a tool being retrieddeclare ToolEffect::Idempotent or ReadOnly (retries)
reads the error text the model receives for a failed toolcall expose_tool_error_messages(true) (tool errors)
builds tool_confirmation_fingerprints with tool_call_fingerprinttake fingerprint() from the held call's request (fingerprints)
wraps Tool, ReadonlyContext, or Agentforward the new trait methods (wrappers)
serves agents to other machines or browsersset the bind address, allowed_hosts, and allowed_origins (server exposure)
has graph runs paused under 2.3.0finish them before upgrading, or re-key their checkpoints (graph threads)
uses #[tool], FunctionTool, or StatefulTool with a schemaexpect undeclared keys and out-of-range values to be rejected (argument validation)
uses PostgresAuditSinkcall migrate() before the first write (audit)
enables a feature named after a dependency (adk-session/tokio, adk-auth/jsonwebtoken, adk-guardrail/jsonschema, …)enable the feature that uses it (optional dependencies)
calls SessionService::rewind or rewind_stepspass an AdkIdentity (rewind)
implements PaymentPolicyGuardrailmake evaluate async and add the context parameter (payments)
runs cargo adk evalpass --agent-cmd (eval)
queries exported GenAI spans or uses adk_telemetry::semconvuse the current GenAI attribute names (telemetry)
runs cargo adk benchinstall with cargo install cargo-adk --features bench (benchmarks)
depends on adk-agent or adk-runner directly and calls a skill method (with_skills, with_auto_skills, with_skill_injector, …)enable skills on that crate (skills)
names an adk-rust alias feature (fireworks, whisper-onnx, action-db, a2a, personas, …)replace it with its sibling (features)
consumes or implements SttProvider::transcribe_streammatch TranscriptEvents (audio)
builds adk_memory::MemoryEntry with a literal, implements or wraps MemoryService, or sets RedisMemoryConfig::ttluse MemoryEntry::new, forward delete_memory and purge_expired, and expect the TTL per entry (memory expiry)
reads SandboxPolicy::allow_network or network_rules, implements SandboxEnforcer, or runs WindowsEnforcer with the network denieduse SandboxPolicy::network, add network_support, or call acknowledge_open_network (sandbox network)
implements Llm or CacheCapable, or reads or edits LlmRequest::toolsuse ToolDeclarations (tool declarations)
opens / or /ui/ on a server built with adk-servermount adk-surface's web home, or run adk-rust serve (runtime UI)
calls POST /api/run or POST /api/run_sse for a session it has not createdcreate the session first (runs)
serves or calls A2A v1, or has an A2A 0.3 client that reads /.well-known/agent-card.jsonsend A2A-Version: 1.0, match SendMessageResponse, read .tasks, and read 0.3 cards from /.well-known/agent.json (A2A v1)
mounts registry_router or implements AgentRegistryStorepass a RequestContextExtractor and implement replace_owned and delete_owned (agent registry)
calls ModelProvider::default_model, or relies on a provider's default modelhandle None for Bedrock and Azure AI, and check the new defaults (default models)
validates tokens with JwtValidator or an SSO providerset an audience, pass JwtAlgorithm to algorithm(..), and expect tokens without iss or aud to be refused (SSO)
matches error codes artifact.legacy, artifact.gcs.not_found, or config.legacy for a session identifiermatch the new codes (artifacts, sessions)
runs graph HTTP, notification, or RSS nodes against an internal serviceadd allow_private_networks() to the policy (graph HTTP)
runs adk-rust without a subcommand, adk-rust serve, or code, goal, ultracode from a scriptuse adk-rust chat, serve --agent chat, or --yes (adk-cli)
uses adk-acp's server or the agent_client_protocol re-exportfollow the ACP SDK 5 layout and the new handler signatures (adk-acp)

Before you upgrade

Some changes affect state written by 2.3.0 or the way a deployment is reached. Handle these before or during the upgrade.

Stored state or deploymentWhat 3.0 doesDo this
Graph runs paused by GraphAgent or a NodeToolKeys checkpoints by app, user, and session; checkpoints under a bare session id are not readFinish paused runs on 2.3.0, or re-key them (details)
Runs paused inside a SubgraphNode or a run_node childKeys child work by activation, so the child starts again on resumeFinish those runs on 2.3.0
Tool calls held for confirmationBinds approvals to the agent and the tool's origin; a call held under 2.3.0 is answered as not run when a decision resumes itRe-issue the held calls after the upgrade
PostgresAuditSink tablesWrites the new agent_id and on_behalf_of columnsCall migrate() once; until then every insert fails and guarded tools are refused
SQLite, PostgreSQL, and MongoDB session storesAdds migration 2 (sessions.initial_state on SQLite, events.seq on PostgreSQL, an index on MongoDB)Call the service's migrate()
RedisSessionServiceWrites sessions through Lua scriptsAllow EVAL for the service's Redis user
FileArtifactService directoriesWrites a new layout for names and user-scoped artifacts; the earlier layout is still readUpdate tools that read the directory tree directly
Artifacts saved under the session id userReserves that id for user-scoped artifacts, so those artifacts are unreachableCopy them to another session before upgrading
pgvector collectionsValidates collection names instead of rewriting themUse the existing table's name without its rag_ prefix
RAG vector store collectionsKeys every chunk by scope and chunk IDpgvector: call create_collection once (it migrates in place). LanceDB, Qdrant, Agent Retrieval: re-create and re-ingest (details)
SurrealDB vector store collectionsRemoves SurrealVectorStore and the surrealdb featureRe-ingest the source documents into another vector store (details)
Background runs persisted by FileRunPersistenceRemoves the file store; runs live in a DurableRunStoreLet persisted runs finish on 2.3.0, and re-create cron jobs
Servers reached from other machines or browsersListens on 127.0.0.1, allows no cross-origin access, and checks the Host headerConfigure the bind address, hosts, and origins (details)
Deployments whose users open / or /ui/ on an adk-server serverServes no page at those pathsMount the web home, or run adk-rust serve (details)
A2A peers of a server built with a2a-v1Serves A2A v1 beside 0.3, serves the v1 card at /.well-known/agent-card.json (the 0.3 card stays at /.well-known/agent.json), and refuses v1 requests without A2A-VersionPoint 0.3 clients at agent.json, and send A2A-Version: 1.0 from v1 clients (details)
Clients that call POST /api/run with a new session idAnswers 404 with session.not_foundCreate the session before the first run (details)
Scripts that run adk-rust code, goal, or ultracodeRuns them on the harness in ask mode, so edits and host commands wait for approvalPass --yes or a --mode (details)

reqwest 0.13

Every crate builds its HTTP clients on reqwest 0.13 (2.3.0 used 0.12). An API that takes or returns a reqwest type — adk_auth's with_http_client(reqwest::Client), adk_core::egress's RequestBuilder, the Slack tools, adk_gemini's and adk_gcp's clients, and the others — takes the 0.13 type, so an application that passes its own client depends on the same version:

[dependencies]
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls"] }

TLS is rustls on aws-lc-rs with the platform verifier, which checks certificates against the operating system's trust store, as rustls-tls-native-roots did. ring is no longer compiled for HTTP, so a binary that installs a rustls provider itself installs aws-lc-rs, or calls adk_core::ensure_crypto_provider(). On Windows x86_64 (MSVC), aws-lc-sys assembles with NASM for every tier, minimal included; without NASM installed, set AWS_LC_SYS_PREBUILT_NASM=1 to use the objects it ships.

Struct literals

Most API breaks are new public fields. A struct literal that names every field stops compiling; one that ends with ..Default::default(), or a constructor, keeps compiling:

use adk_core::{Content, EventActions, LlmResponse, RunConfig, StreamingMode};

let config = RunConfig { streaming_mode: StreamingMode::SSE, ..Default::default() };
let actions = EventActions { escalate: true, ..Default::default() };
let response = LlmResponse {
    content: Some(Content::new("model").with_text("Done.")),
    ..Default::default()
};
TypeCrateNew or changed fieldsBuild it with
RunConfigadk-coreinvocation_hooks, budget, budget_tracker, action_ledger, tool_policy, tool_reviewer, governance, tool_approvals, approval_store, approval_service, durable_run_id, tool_confirmation_timeout, spend_ledger, llm_spend_estimate, audit, acting, deny_on_confirmation_timeout, intra_compaction, history_compactor, consent_gate, egress_policy, request_context, request_metadata, requested_call, transfer_target_descriptions..Default::default() or RunConfig::builder()
IntraCompactionConfigadk-coreenabled, context_window_fraction, native, background, background_fraction; token_threshold is Option<u64>IntraCompactionConfig::at_tokens(n), with_overlap_event_count, with_native and in_background
MessageCreateParamsadk-anthropiccompaction, thread, betasMessageCreateParams::new or ..Default::default()
RunnerConfigadk-runnertool_policy, governance, action_ledger, approval_store, spend_ledger, durable_runs, audit, identity_source, subject_delegation, egress_policyRunner::builder(), or set each to None
EventActionsadk-coreinput_screened, workflow_positions, steering, grounding_sources..Default::default()
LlmResponseadk-coremodel, provider..Default::default()
UsageMetadataadk-corebuiltin_tool_uses..Default::default()
GenerateContentConfigadk-coreeffort (per-call reasoning effort, spec 3.1 §7.23), response_modalities..Default::default()
ToolConfirmationRequestadk-coreacting, origin, evidenceToolConfirmationRequest::new and with_evidence
ToolOutcomeadk-coreerroradd the field
RetryBudgetadk-coremax_delayRetryBudget::new
TeamBudgetadk-agentallow_unpriced_models..TeamBudget::default()
CodeActCheckpointadk-agent (codeact)run_idadd run_id: None
AnthropicConfigadk-modelrequest_timeout_secs, prompt_cache_ttl, thinking_display, inline_tool_changes, message_threads; max_tokens is Option<u32>AnthropicConfig::new and its with_* methods
OpenAIResponsesConfigadk-modeltransport removeddrop the field
Usage, MessageDeltaUsageadk-anthropicrawadd raw: None
ServerToolUsageadk-anthropicweb_fetch_requests, code_execution_requests..Default::default()
ServerToolUseBlock, WebSearchToolResultBlock, WebFetchToolResultBlockadk-anthropiccallertheir new constructors
ToolUseBlock, ToolResultBlockadk-anthropictoolset_nameToolUseBlock::new, ToolResultBlock::new
UserEvent::DefineOutcomeadk-anthropic (managed-agents)description, rubric, max_iterations replace criteriaUserEvent::define_outcome
UsageMetadata, interactions::Usageadk-geminirawadd raw: None
GroundingMetadata, GroundingSegmentadk-geminisearch_entry_point, part_index..Default::default()
ServerConfigadk-servergovernance, session_activityServerConfig::new
SecurityConfigadk-serverallowed_hosts, admin_scope, run_timeout..SecurityConfig::default()
RemoteA2aConfigadk-serverallowed_endpoint_origins, credential_broker, credential_scopesRemoteA2aAgent::builder
RemoteA2aV1Configadk-server (a2a-v1)credential_broker, credential_scopes, send_configuration, hooksadd the fields
TaskStoreEntryadk-server (a2a-v1)versionadd version: 0
AgUiRunInput, MessagePart, CreateSessionBodyRequestadk-serverresume; function_call, function_response; session_id..Default::default()
registry::AgentCardadk-server (agent-registry)owneradd owner: None; the server sets it from the caller
SubmitRunRequest, CreateCronJobRequestadk-server (background)see background runsadd the fields
CronStateadk-server (background)jitter, audit; the struct is #[non_exhaustive], so no literal outside adk-serverCronState::new and with_schedule_store, with_jitter, with_audit
ExecutionConfigadk-grapha crate-private field, so no literal outside adk-graphExecutionConfig::new and its builder methods
Checkpointadk-graphversion, pending_writesCheckpoint::new
RetentionPolicyadk-graph#[non_exhaustive]; pinnedRetentionPolicy::keep_last, max_age, with_max_age, with_max_per_thread, pinning
InterruptedExecutionadk-graphinterruptsInterruptedExecution::new
executor::SuperStepResultadk-graphinterrupt replaced by interrupts; updatesadd the fields
ContainerConfig, DockerConfigadk-codedrop_capabilities, no_new_privileges, pids_limit..ContainerConfig::default(), ..DockerConfig::default()
MemoryEntryadk-memoryid, expires_at; the struct is #[non_exhaustive], so no literal outside adk-memoryMemoryEntry::new(content, author) and with_timestamp, with_id, with_ttl, with_expires_at
TriggerEventadk-agent (ambient)none; the struct is #[non_exhaustive], so no literal outside adk-agentTriggerEvent::new(source, payload) and with_principal
AuditEvent, AuditFilteradk-authagent_id, on_behalf_of (AuditFilter: agent_id)add the fields
ManagedSessionStateadk-managedrecord, pending, durable_run_idManagedSessionState::new
LlmJudgeConfigadk-evalmax_tokens and temperature are Optionwrap values in Some
StructuredJudgeConfigadk-evaltemperature is Optionwrap the value in Some
DeploymentManifestadk-deploytargets..DeploymentManifest::default()
RetryConfigadk-modelmax_server_delay..RetryConfig::default()
ToolDefinitionadk-realtimebehaviorToolDefinition::new, or add behavior: None
Message, MessageDeltaadk-anthropicstop_detailsMessage::new, MessageDelta::new
GenerationConfig, Candidateadk-geminipresence_penalty, frequency_penalty, response_logprobs, logprobs; logprobs_result, avg_logprobs..Default::default()
Turn, TurnResultadk-evalexpected_vision, actual_visionadd the field as None
EvaluationCriteriaadk-evalvision..Default::default()
GraphInterruptPayloadadk-graphinterrupt_id, response_schemaGraphInterruptPayload::new or from_event
CapabilityEntryawp-typesaccess_leveladd access_level: None
BusinessCapabilityawp-typesinput_schema, output_schemaadd both as None
AcpServerConfigadk-acp (server)standing_permissions, authenticator, system_prompts, providersAcpServerConfigBuilder::new()
AcpAgentConfig, PromptResultadk-acpnew fields; both are #[non_exhaustive], so no literal outside adk-acpAcpAgentConfig::new and its builder methods
RetryReflectConfigadk-retry-reflectrecord_payloads..RetryReflectConfig::default()

Runner::builder() replaces a RunnerConfig literal, which has no Default:

use adk_runner::Runner;

let runner = Runner::builder()
    .app_name("support")
    .agent(agent)
    .session_service(sessions)
    .build()?;

Optional dependencies are no longer features

Optional dependencies of eleven crates were reachable as features named after the dependency, because the crates enabled them without the dep: prefix. 3.0.0 names them with dep:, so those names are no longer features; enable the feature that uses the dependency.

CrateRemoved implicit featuresEnable instead
adk-agentadk-guardrailguardrails
adk-artifactadk-gcp, google-cloud-auth, reqwest, serde, tracinggcs
adk-authaxum, base64, dashmap, jsonwebtoken, reqwestsso, auth-bridge, signed-audit, token-exchange, web-bot-auth
adk-deployadk-core, adk-gcp, google-cloud-authgcp
adk-evaladk-gcp, google-cloud-auth, reqwestvertex-eval
adk-guardrailjsonschemaschema
adk-memoryadk-gcp, fred, google-cloud-auth, reqwestredis-memory, vertex-memory
adk-sessionadk-gcp, aes-gcm, base64, fred, google-cloud-auth, rand, reqwest, sha2, sqlx, tokiosqlite, postgres, redis, vertex-session, encrypted-session
adk-surfaceadk-toolgenui-apps
adk-telemetrygoogle-cloud-auth, http, tokio, tonicgcp
adk-tooladk-gcp, google-cloud-auth, reqwesthttp-transport, slack, example-store, vertex-agent-registry

Exhaustive matches

These enums gain variants and are not #[non_exhaustive], so an exhaustive match needs the new arms:

EnumCrateNew variants
ErrorCategoryadk-coreResourceExhausted (HTTP 429), Conflict (HTTP 409)
GuardrailErroradk-guardrailBlocked
ClientErroradk-geminiErrorInResponse; BadResponse gains retry_after
Erroradk-anthropicnone; RateLimit, ServiceUnavailable and Timeout gain status_code, and Api and InternalServer gain retry_after, so a pattern that names every field ends with ..
ThinkingConfigadk-anthropicBetweenTools
ModelProvideradk-modelBedrock, AzureAi, Muse, Openrouter, Opencode, OpencodeGo
ThinkingModeadk-model (anthropic)BetweenTools
A2aErroradk-server (a2a-v1)ConcurrentModification
SsoErroradk-auth (sso)AuditFailed
RealtimeErroradk-realtimeOutputBlocked, SpendRefused
RagErroradk-ragInvalidScope, UnsupportedFilter
DevToolErroradk-devtoolsExcluded, Stale
schema::Partadk-evalImage
BenchErroradk-benchVision
AwpConfigErroradk-awpSerialize
AcpErroradk-acpUnsupported
AcpServerErroradk-acp (server)AuthRequired, Unsupported
composition::CompositionErrorcargo-adkUnsupportedProvider
ContentBlockadk-anthropicCodeExecutionToolResult, BashCodeExecutionToolResult, TextEditorCodeExecutionToolResult, Compaction, ToolAddition, ToolRemoval, Unknown
MessageRoleadk-anthropicSystem (a mid-conversation system message)
ContentBlockDelta, MessageStreamEventadk-anthropicUnknown
StopReasonadk-anthropicCompaction, Unknown(String)
ToolUnionParamadk-anthropicWebSearch20260209, WebFetch20260209, ComputerToolset20260801, BrowserToolset20260801, Computer20251124, Computer20250124, Advisor20260301
Contentadk-anthropicBrowserState
WebFetchErrorCodeadk-anthropicUrlTooLong, UrlNotAccessible, UnsupportedContentType; Unknown becomes Unknown(String)
WebSearchErrorCodeadk-anthropicRequestTooLarge, Unknown(String)
WebhookVerifyErroradk-anthropic (managed-agents)MissingHeader, TimestampInFuture
TaskStateadk-serverAuthRequired
V1ClientErroradk-server (a2a-v1)CardEndpoint, Credential
ServerStatusadk-tool (mcp)Starting
auth::PaymentOperationadk-paymentsExecutePayment

These enums become #[non_exhaustive], so a match on them outside their crate needs a wildcard arm:

EnumCrateNew variants
FinishReasonadk-coreRefusal, MalformedToolCall
FinishReasonadk-gemininone
GraphErroradk-graphAgentFailed, FanInIncomplete, CheckpointConflict, Suspended, Cancelled, ResumeRejected; DatabaseError is removed
EvalErroradk-evalRefused
OutputChunkadk-acpplans, notices, compactions, mode, config, command and session-info changes, user text, subagents; Done becomes Done { stop_reason, usage }
SandboxErroradk-sandboxUnsupported, Remote (with workspace)
background::RunStatusadk-serverWaiting
ServerTooladk-anthropicComputerUse20251124, ComputerToolset20260801, BrowserToolset20260801
use adk_core::{AdkError, ErrorCategory};

fn next_step(error: &AdkError) -> &'static str {
    match error.category {
        ErrorCategory::InvalidInput | ErrorCategory::Unsupported => "fix the request",
        ErrorCategory::Unauthorized | ErrorCategory::Forbidden => "check the credentials",
        ErrorCategory::NotFound => "check the id",
        ErrorCategory::RateLimited | ErrorCategory::Timeout | ErrorCategory::Unavailable => {
            "retry later"
        }
        ErrorCategory::Cancelled => "stop",
        ErrorCategory::Internal => "report a bug",
        // New in 3.0
        ErrorCategory::ResourceExhausted => "raise the budget or stop",
        ErrorCategory::Conflict => "reload and retry",
    }
}

adk-core and adk-runner

LlmRequest::tools keeps declaration order

LlmRequest::tools is an adk_core::ToolDeclarations instead of a HashMap<String, serde_json::Value>. It keeps the order the agent declares its tools in — static tools, then each toolset's — and every provider sends them in that order. CacheCapable::create_cache and GeminiModel::create_cached_content take &ToolDeclarations. A custom Llm, a cache implementation, and a before_model_callback that names the map type change it:

use std::collections::HashMap;
use serde_json::Value;

// 2.3
fn tool_names(tools: &HashMap<String, Value>) -> Vec<String> {
    let mut names: Vec<String> = tools.keys().cloned().collect();
    names.sort();
    names
}
use adk_core::{LlmRequest, ToolDeclarations};
use serde_json::json;

// 3.0
fn tool_names(tools: &ToolDeclarations) -> Vec<String> {
    // Already in declaration order.
    tools.keys().cloned().collect()
}

fn declare_lookup(request: &mut LlmRequest) {
    request.tools.insert("lookup_order".to_string(), json!({ "name": "lookup_order" }));
}

insert, get, contains_key, remove, iter, keys, values, len and is_empty work as on a HashMap, ToolDeclarations collects from (name, declaration) pairs, and tools: Default::default() still fills an LlmRequest literal. Anthropic, Bedrock and the OpenAI clients no longer sort tools by name, so a prompt-cache prefix written before the upgrade misses once.

Tool retries follow the declared effect

A RetryBudget retried every failed call, including one that timed out after its side effect happened. LlmAgent and CodeActAgent now retry only a tool whose Tool::effect() is ReadOnly or Idempotent, and only after a retryable error or a timeout. A tool that declares nothing and is not is_read_only() is NonIdempotent and runs once. Declare the effect to keep retrying a tool — #[tool(idempotent)], FunctionTool::with_effect, or Tool::effect:

use adk_core::ToolEffect;
use adk_tool::FunctionTool;
use serde_json::json;

let lookup = FunctionTool::new("lookup_order", "Looks up an order", |_ctx, args| async move {
    Ok(json!({ "order": args["id"] }))
})
.with_effect(ToolEffect::Idempotent);

The delay ceiling now doubles per retry up to RetryBudget::max_delay (30 seconds by default), and each delay is drawn from the upper half of that ceiling. Build the budget with its constructor:

use std::time::Duration;
use adk_core::RetryBudget;

// 2.3
let budget = RetryBudget { max_retries: 2, delay: Duration::from_millis(500) };
use std::time::Duration;
use adk_core::RetryBudget;

// 3.0
let budget = RetryBudget::new(2, Duration::from_millis(500))
    .with_max_delay(Duration::from_secs(5));

An AgentTool delegation no longer stops at the parent agent's tool_timeout; set AgentTool::timeout to bound it. A delegation that runs past that timeout is a tool error with ErrorCategory::Timeout, not an {"error": ...} result.

Interrupted calls report an unknown outcome

A non-idempotent call that times out or panics, and a call still in flight when a run is cancelled, is answered with {"status": "outcome_unknown", ...} instead of {"error": ...}, so the model does not call it again. Code that reads function responses detects it with adk_core::is_outcome_unknown.

Approval fingerprints name the agent and the tool

ToolConfirmationRequest::fingerprint() now covers the acting agent's id and the tool's origin as well as the tool name and arguments, so an approval for one agent's call does not authorize another agent's call with the same arguments. A fingerprint built with tool_call_fingerprint(name, args), or from a request without an acting agent, matches no call, and the call stays held; RunConfigBuilder::tool_approval refuses one. Take the fingerprint from the request the held call surfaced, or build it for the agent and tool:

use adk_core::tool_call_fingerprint;

// 2.3
let fingerprint = tool_call_fingerprint(transfer.name(), &args);
use adk_core::{ActingContext, AgentPrincipal, ToolConfirmationRequest};

// 3.0
// From the request the held call surfaced:
let fingerprint = request.fingerprint();
// Or built for a known agent and tool:
let fingerprint = ToolConfirmationRequest::for_tool(transfer.as_ref(), args)
    .with_acting_context(ActingContext::new(AgentPrincipal::derived("ops", "treasurer")))
    .fingerprint();

A call held under 2.3.0 records no agent or origin, so it is answered as not run when a decision resumes it; re-issue it.

Held calls are answered and resumed

  • Enhanced plugins, runner hooks, and BeforeToolCallbacks run before the policy, guardrails, and confirmation, so an approval covers the arguments that execute, and the ToolConfirmationRequest carries them.
  • A call awaiting confirmation without a handler receives confirmation_pending_response ("status": "confirmation_pending"), and the turn's other calls run before the run ends.
  • The next run executes an approved held call under its original call ID, so the model does not need to issue it again.
  • SequentialAgent, LoopAgent, ParallelAgent, ConditionalAgent, and LlmConditionalAgent stop at a held call and resume at the sub-agent that held it, instead of running their later sub-agents in the same run.
  • Compaction stops before the earliest held call, so a custom CompactionStrategy receives fewer events while a call is undecided.
  • A ToolConfirmationHandler decision that takes longer than RunConfig::tool_confirmation_timeout (five minutes by default) leaves the call waiting in the run's approval store, or denies it when the run has none or sets RunConfig::deny_on_confirmation_timeout, and decisions in one batch run concurrently. A handler that prompts on a shared device serializes its own prompts.

Wrappers forward the new trait methods

A type that wraps another and implements the trait itself must forward the new methods, or it reports the trait default instead of the wrapped value.

Tool gains effect(), origin(), annotations(), timeout_override(), egress(), approval_evidence(), and batch_group(). Without forwarding, a wrapped tool is NonIdempotent, its approvals bind to the "static" origin, its annotations are lost, a run with an egress policy refuses it as undeclared, a held call shows no evidence, and its calls no longer stop at the first failure in an ordered batch:

use std::time::Duration;
use adk_core::ToolEffect;
use adk_core::egress::ToolEgress;
use serde_json::Value;

fn effect(&self) -> ToolEffect {
    self.inner.effect()
}
fn origin(&self) -> &str {
    self.inner.origin()
}
fn annotations(&self) -> Option<&Value> {
    self.inner.annotations()
}
fn timeout_override(&self) -> Option<Option<Duration>> {
    self.inner.timeout_override()
}
fn egress(&self, args: &Value) -> ToolEgress {
    self.inner.egress(args)
}
fn approval_evidence(&self, args: &Value) -> Vec<adk_core::Evidence> {
    self.inner.approval_evidence(args)
}
fn batch_group(&self) -> Option<adk_core::BatchGroup> {
    self.inner.batch_group()
}

ReadonlyContext gains acting_context(). A context wrapper that does not forward it reports the derived identity (urn:adk:agent:{app}/{agent}) instead of the configured principal:

use adk_core::ActingContext;

fn acting_context(&self) -> ActingContext {
    self.inner.acting_context()
}

Llm gains context_window(), which auto-compaction reads to set its threshold. A model wrapper that does not forward it compacts at the 100,000-token default instead of near the wrapped model's window:

fn context_window(&self) -> Option<u64> {
    self.inner.context_window()
}

Llm also gains native_compaction(), which tells auto-compaction that the model's provider writes the summary itself. A wrapper that does not forward it compacts with the runner's summarizer instead:

use adk_core::NativeCompaction;

fn native_compaction(&self) -> Option<NativeCompaction> {
    self.inner.native_compaction()
}

Llm also gains data_locality(), which says whether a call's data leaves the process or the machine. A wrapper that does not forward it reports Remote, so a guardrail gates a local model's calls as if they left the machine:

use adk_core::DataLocality;

fn data_locality(&self) -> DataLocality {
    self.inner.data_locality()
}

Agent gains screen_user_input, which the runner calls on the root agent before it saves a user message. Its default screens with sub_agents(), so an agent that runs another without listing it as a sub-agent delegates to it:

use adk_core::{Content, Result};

async fn screen_user_input(&self, content: &Content) -> Result<Option<Content>> {
    self.inner.screen_user_input(content).await
}

Agent also gains allows_transfer_to_parent and allows_transfer_to_peers, which the runner reads when it checks a transfer, and profile, from which A2A v1 cards build their skills. A wrapper that does not forward them allows both transfers and reports a custom agent:

use adk_core::AgentProfile;

fn allows_transfer_to_parent(&self) -> bool {
    self.inner.allows_transfer_to_parent()
}
fn allows_transfer_to_peers(&self) -> bool {
    self.inner.allows_transfer_to_peers()
}
fn profile(&self) -> AgentProfile {
    self.inner.profile()
}

Instructions travel as system contents

LlmAgent sends its global instruction, instruction, and output-schema directive with role "system" instead of "user". A custom Llm implementation maps system contents to its provider's system prompt.

Run lifecycle

  • Transfers obey the source agent's restrictions. A transfer that a tool or a custom agent requests is checked like the model's transfer_to_agent call: to a sub-agent, to the parent unless disallow_transfer_to_parent, or to a peer unless disallow_transfer_to_peers. Any other target is refused and control stays with the source; a root with strict_transfer_policy() fails the run with agent.transfer.target_forbidden.
  • after_agent runs on every exit except a failure or a held call, including a transfer, a turn-ending tool result, and a cancellation, so after-agent callbacks see these exits. Plugins' after_run runs once, after the run's last event, also when the consumer drops the stream.
  • Input guardrails of every agent in the tree screen each user message before it is saved. An input guardrail on a sub-agent, workflow step, or transfer target screens the message for the whole run instead of only when that agent runs, and a blocked message is not saved.
  • Runner plugins' agent, model, and tool callbacks run. A PluginManager on the runner had only its run, user-message, and event callbacks called. Its before_agent, after_agent, before_model, after_model, before_tool, after_tool, and on_tool_error now run ahead of each agent's own, and a callback that returns a value short-circuits the agent's callbacks of that kind.
  • adk_runner::Callbacks is removed, with its BeforeModelCallback, AfterModelCallback, BeforeToolCallback, and AfterToolCallback aliases; the runtime never called them. Register callbacks on the agent builder or as runner plugins.
  • ${x}, \{x}, and {{x}} in instructions stay literal. Only {var}, {var?}, and {artifact.name} are substituted.

History sent to the model

  • Workflow sub-agents see other agents' turns as context. An LlmAgent without transfer targets, such as a SequentialAgent step, receives another agent's text, calls, and results as quoted user-role context instead of as its own model turns. Code that matched the old request shape needs updating.
  • Calls without IDs get generated adk-call- IDs. A function call a provider sends without an ID carries a generated ID (adk_core::GENERATED_CALL_ID_PREFIX) in the saved event, its responses, and ToolContext::function_call_id(), instead of {invocation}_{name}_{index}. Model requests leave the generated IDs out.
  • A model turn without an answer fails the run with model.empty_response, instead of succeeding with no output: a final turn with no parts, only thinking, or only whitespace.
  • History is compacted before each model call. Auto-compaction is on by default: once a request passes 80% of the model's context window, or 100,000 estimated tokens, the agent's history is summarized and the compaction recorded in the session. The runner no longer compacts once before the agent runs or retries agent.run() on a token-limit error. Runner::builder().without_intra_compaction() restores the uncompacted history; see Context Compaction. On a model whose provider compacts conversations itself, such as Claude Sonnet 5.5 on the Claude API, the provider writes the summary and its signed block opens later requests; IntraCompactionConfig::with_native(false) keeps the runner's summarizer.
  • Model events carry one bounded copy of the request (trace_payload_max_bytes, full only with record_payloads) and no gcp.vertex.agent.llm_request provider metadata. With record_payloads off, the call_llm span and the DEBUG tool-call logs record a marker instead of the first 2 KB of each payload.
  • An agent that can transfer is told what each target does. An LlmAgent with transfer targets adds a system instruction after its own that lists each target with its description.
  • Provider-native items replay only to the provider and model that produced them. Thinking and its signatures, server-side tool calls and preserved provider messages reach no other provider or model, and A2A responses no longer carry server_tool_call or server_tool_response data parts.

adk-agent

Tool failures reach the model without their message

A tool that returns Err, or a before-tool callback that fails, is answered with the error's component, category, and code — {"error": "tool '<name>' failed: <component>.<category> (<code>)"} — instead of its message, so connection strings and upstream bodies stay out of model requests and sessions. The message still reaches on_tool_error and ToolOutcome::error. An error with code tool.invalid_arguments keeps its text.

When an after-tool callback or plugin fails after the tool ran, the call is answered with adk_core::result_withheld_response ("status": "result_withheld") instead of the callback's error, so the model does not repeat the side effect.

A failing toolset no longer fails the turn

When a toolset's tools() call fails, LlmAgent skips that toolset, logs a warning, and runs the model with the tools that resolved. Both 2.3.0 behaviours are one builder call away:

use adk_agent::LlmAgentBuilder;

let agent = LlmAgentBuilder::new("assistant")
    .model(model)
    .toolset(toolset)
    // Fail the turn when a toolset cannot list its tools, as 2.3.0 did.
    .strict_toolsets(true)
    // Send tool error messages to the model, as 2.3.0 did.
    .expose_tool_error_messages(true)
    .build()?;

A refusal ends the run with an error

A model that declines finishes with FinishReason::Refusal on every provider — Anthropic's refusal stop reason was Safety, an OpenAI Chat Completions refusal was Safety, and a Responses refusal part was Stop. LlmAgent and CodeActAgent emit the model's event, so the session keeps the refusal text, and then end the run with model.refusal (ErrorCategory::Forbidden); no tool call of that turn runs. A Chat Completions refusal was the run's successful answer in 2.3.0, so adk-rust code and adk-rust goal now exit 1 on one.

A tool call the provider reports as invalid — Gemini MALFORMED_FUNCTION_CALL and UNEXPECTED_TOOL_CALL, Bedrock malformed_tool_use — finishes with FinishReason::MalformedToolCall and ends the run with model.malformed_tool_call.

A chat surface that showed the refusal as the answer reads it from the run's last model event:

use adk_core::{AdkError, Event, FinishReason};

fn refusal_text(events: &[Event], error: &AdkError) -> Option<String> {
    if error.code != "model.refusal" {
        return None;
    }
    let event = events
        .iter()
        .rev()
        .find(|event| event.llm_response.finish_reason == Some(FinishReason::Refusal))?;
    let content = event.llm_response.content.as_ref()?;
    Some(content.parts.iter().filter_map(|part| part.text()).collect())
}

Skills are not a default feature

adk-agent and adk-runner no longer enable skills by default, so a project that depends on either crate directly compiles no adk-skill. The skill methods on the agent builders (with_skills, with_auto_skills, with_skills_from_root, with_skill_policy, with_skill_budget) and on Runner (with_skill_injector, with_auto_skills_mut) need the feature on the crate that provides them:

[dependencies]
adk-agent = { version = "3.0.0", features = ["skills"] }
adk-runner = { version = "3.0.0", features = ["skills"] }

Through adk-rust, the skills feature (in standard and above) enables both.

Other agent changes

  • A panicking before-tool callback answers the call not run with callback.panicked, in LlmAgent, CodeActAgent and EnhancedPluginManager, instead of unwinding through the agent.
  • Two static tools with one name fail the build. LlmAgentBuilder::build, CodeActAgentBuilder::build, and the realtime builders return agent.duplicate_tool_name instead of letting the last registration win. Rename one tool or register it once.
  • Team cost caps fail closed. TeamBudget::max_cost_microusd is enforced against priced usage, and a response with no known cost stops the team unless allow_unpriced_models is set. Team budget errors use ErrorCategory::ResourceExhausted (codes budget.*) instead of the retryable RateLimited.
use adk_agent::TeamBudget;

let budget = TeamBudget {
    max_cost_microusd: Some(2_000_000),
    // Count a response with no known cost as free instead of stopping the team.
    allow_unpriced_models: true,
    ..TeamBudget::default()
};

adk-tool and adk-rust-macros

Tool arguments are checked against the schema

#[tool] validates each call against its parameters schema before the function runs, with additionalProperties: false on every object that declares all its fields. An undeclared key, a value outside a range, length, or pattern bound, or a missing required field fails the call with tool.invalid_arguments, which the model can correct; serde used to drop unknown keys and the bounds were never enforced. FunctionTool and StatefulTool with with_parameters_schema::<T>() validate the same way. A tool that accepts input its schema does not describe, such as a #[serde(alias)] key, opts out:

use adk_tool::{AdkError, tool};
use schemars::JsonSchema;
use serde::Deserialize;
use serde_json::{Value, json};

#[derive(Deserialize, JsonSchema)]
struct LookupArgs {
    /// The order to look up.
    #[serde(alias = "orderId")]
    order_id: String,
}

/// Looks up an order, accepting the legacy `orderId` key.
#[tool(lenient_args)]
async fn lookup_order(args: LookupArgs) -> Result<Value, AdkError> {
    Ok(json!({ "order_id": args.order_id }))
}
use adk_tool::FunctionTool;
use schemars::JsonSchema;
use serde::Serialize;

#[derive(Serialize, JsonSchema)]
struct LookupArgs {
    order_id: String,
}

let tool = FunctionTool::new("lookup_order", "Looks up an order", |_ctx, args| async move {
    Ok(args)
})
.with_parameters_schema::<LookupArgs>()
.with_lenient_args(true);

MCP

SimpleClient::inner returns the shared connection, since requests no longer go through a mutex:

// 2.3
let peer = client.inner().lock().await.peer().clone();
// 3.0
let peer = client.inner().peer().clone();

should_refresh_connection takes the rmcp::ServiceError instead of its text, and reconnects only on a closed transport, a broken connection, an interrupted stream, an expired session, or an HTTP 401:

use adk_tool::mcp::should_refresh_connection;

// 2.3
let reconnect = should_refresh_connection(&error.to_string());
use adk_tool::mcp::should_refresh_connection;

// 3.0
let reconnect = should_refresh_connection(&error);

OAuth2Config sends the client-credentials request only to an https token URL, or http on localhost or a loopback address; any other URL fails with AuthError::TokenFetch.

McpServerManager reports a server whose handshake is in progress as ServerStatus::Starting, and a server that has not finished its handshake within with_startup_timeout (30 seconds by default) is FailedToStart. Raise the timeout for a server that downloads a package on its first start. McpToolset caches a server's tools/list for 60 seconds; a server that changes its tools without sending notifications/tools/list_changed needs with_tool_list_cache_ttl or invalidate_tool_list_cache().

AgentTool

A delegation that runs past AgentTool::timeout is a Timeout tool error in every AgentToolFailureMode. In the default ReturnErrorObject mode a failed delegation's object names the error's component, category and code instead of its message; AgentTool::expose_error_messages(true) restores the message. Under AgentToolFailureMode::Propagate, a failed delegate's error keeps its category and code instead of becoming tool.legacy. The delegate's session_id() is its caller's session ID instead of an agent-tool-{uuid} ID.

adk-model

  • Unsupported generation settings fail by name. The OpenAI Chat Completions, OpenAI Responses, Anthropic, Bedrock, Groq, DeepSeek, and Azure AI Inference clients dropped stop_sequences, seed, frequency_penalty, presence_penalty, and top_logprobs. Each now sends the ones its API supports and fails a request that sets any other with model.unsupported_config before sending it; remove that field from the provider's GenerateContentConfig.

  • GeminiModel, OllamaModel, and OpenRouter send the same settings. GeminiModel and OllamaModel now send all five. Current Gemini models (gemini-3.5-flash-lite, gemini-3.8-flash) answer penalties and log probabilities with INVALID_ARGUMENT, so a Gemini config that set them fails with ErrorCategory::InvalidInput where it ran without them; remove them. The Gemini Interactions transport and OpenRouter's Responses mode fail with model.unsupported_config on the fields their APIs lack (penalties and top_logprobs; seed). adk_gemini::GenerationConfig and adk_gemini::Candidate gain fields, so struct literals end with ..Default::default().

  • A request's effort wins over the client's. GenerateContentConfig::effort is new; a request that sets it runs at that level on every client with an effort control, whatever the client was built with (see Per-Call Reasoning Effort). OpenAIClient built with reasoning effort None sends a GPT-5.6 tool call that sets an effort through the Responses API.

  • Bedrock prompt_token_count includes cache reads and writes, as AnthropicClient reports it. Code that added the cache counts itself counts them twice.

  • The openai feature enables async-openai's byot feature. An application that also calls async-openai 0.41 directly sets stream: Some(true) on requests it passes to create_stream.

  • Groq presets for delisted models are removed. GroqConfig::llama8b, GroqConfig::mixtral, GroqConfig::gemma, GroqClient::llama8b, and GroqClient::mixtral selected models Groq no longer serves. Use GroqConfig::gpt_oss_20b, GroqConfig::gpt_oss_120b, or GroqConfig::new(key, model).

  • The Gemini Interactions allowlist names current models. InteractionTarget::parse and GeminiModel::use_interactions_api(true) refuse gemini-2.5-pro, gemini-2.5-flash, gemini-2.5-flash-lite, and gemini-3-flash-preview with model.gemini.interactions.unsupported_target; gemini-3.8-flash is accepted.

  • Server retry hints are bounded. RetryConfig::max_server_delay (60 seconds by default) is the longest Retry-After the retry executor waits for; a longer hint returns the error at once instead of waiting a shortened delay. HTTP 520 to 524 are retryable.

Default models

ModelProvider::default_model returns Option<&'static str>: None for Bedrock and AzureAi, whose model or deployment ID depends on the account, region or endpoint:

use adk_model::ModelProvider;

// 2.3
let model: &str = ModelProvider::Gemini.default_model();
use adk_model::ModelProvider;

// 3.0
fn model_for(provider: ModelProvider, configured: Option<String>) -> Option<String> {
    configured.or_else(|| provider.default_model().map(str::to_string))
}

The catalog defaults move to current models, so a client, template or judge built without a model ID calls a different model. Pin the model ID to keep the earlier one.

Default2.3.03.0.0
catalog::GEMINI_DEFAULT, adk_gemini::Model::default()gemini-3.7-flashgemini-3.8-flash
catalog::OPENAI_DEFAULTgpt-5.6-terragpt-6.1-sol
catalog::ANTHROPIC_DEFAULTclaude-sonnet-5claude-sonnet-5-5
BedrockConfig::default()us.anthropic.claude-sonnet-4-6us.anthropic.claude-sonnet-5-5
catalog::XAI_DEFAULTgrok-4.6grok-4.7
catalog::MISTRAL_DEFAULTmistral-medium-latestmistral-large-latest
catalog::FIREWORKS_DEFAULTaccounts/fireworks/models/kimi-k2p6accounts/fireworks/models/kimi-k3
catalog::TOGETHER_DEFAULTMiniMaxAI/MiniMax-M2.7moonshotai/Kimi-K3.1-Pro
catalog::MINIMAX_DEFAULTMiniMax-M2.7MiniMax-M3
catalog::ZHIPU_DEFAULTglm-5.2glm-5.3

OpenAIResponsesClient always uses HTTP

ResponsesTransport, OpenAIResponsesConfig::transport, and with_transport are removed; the option was never read. WebSocket mode is WsTransport (openai-ws feature):

use adk_model::openai::{OpenAIResponsesClient, OpenAIResponsesConfig, ResponsesTransport};

// 2.3
let config = OpenAIResponsesConfig::new(api_key, "gpt-6.1-sol")
    .with_transport(ResponsesTransport::WebSocket);
let client = OpenAIResponsesClient::new(config)?;
use adk_model::openai::{OpenAIResponsesClient, OpenAIResponsesConfig, WsTransport};

// 3.0, with the `openai-ws` feature
let config = OpenAIResponsesConfig::new(api_key, "gpt-6.1-sol");
let client = OpenAIResponsesClient::new(config.clone())?.with_websocket(WsTransport::new(&config)?);

AnthropicConfig::max_tokens is optional

None, the default, requests 64,000 output tokens from Claude 5, Opus 4.6 to 4.8 and Sonnet 4.6 (128,000 at xhigh or max effort), 32,000 from earlier Claude 4 models and 4,096 from others, instead of a fixed 4,096 that left always-thinking Claude 5 models stopping before the answer:

use adk_model::anthropic::AnthropicConfig;

// 2.3
let config = AnthropicConfig::new(api_key, "claude-sonnet-5-5");
let limit: u32 = config.max_tokens;
use adk_model::anthropic::AnthropicConfig;

// 3.0
let config = AnthropicConfig::new(api_key, "claude-sonnet-5-5");
// `None` resolves per model: 64,000 for current models, 32,000 for earlier Claude 4, 4,096 otherwise.
let limit: Option<u32> = config.max_tokens;
let config = config.with_max_tokens(8_192);

adk-anthropic

  • New API values no longer fail the turn. A content block, delta, stream event, or stop reason newer than the client is kept in the new Unknown variants; see exhaustive matches.
  • StopReason and Usage are no longer Copy; clone them where they were copied. StopReason::from_str is infallible.
  • BatchResult::Succeeded boxes its message: message is a Box<Message>; construction wraps it in Box::new, and code that moves it out dereferences the box.
  • StopReasonParseError is removed, since parsing a stop reason no longer fails.
  • Errors carry transport metadata. Error::RateLimit and Error::ServiceUnavailable gain status_code, Error::Timeout an optional status_code, and Error::Api and Error::InternalServer gain retry_after. The constructors keep their signatures; code that builds a variant directly adds the field, and a pattern ends with ...
  • Message and MessageDelta gain stop_details, the refusal details of a refused turn, and ThinkingConfig gains BetweenTools (adk_model::anthropic::ThinkingMode too).

Managed Agents

define_outcome sends the documented body: a description and a rubric instead of criteria. Pass former criteria as OutcomeRubric::text:

// 2.3
client.define_outcome(session_id, "The report cites three sources.").await?;
use adk_anthropic::managed_agents::OutcomeRubric;

// 3.0
client
    .define_outcome(
        session_id,
        "A research report",
        OutcomeRubric::text("The report cites three sources."),
    )
    .await?;

Webhook verification follows Standard Webhooks. verify_webhook takes the webhook-id, webhook-timestamp, and webhook-signature headers instead of one signature string; WebhookHeaders::from_header_map reads them from an HTTP header map:

use adk_anthropic::managed_agents::verify_webhook;

// 2.3
let event = verify_webhook(body, signature, secret)?;
use adk_anthropic::managed_agents::{WebhookHeaders, verify_webhook};

// 3.0
let headers = WebhookHeaders {
    id: webhook_id,
    timestamp: webhook_timestamp,
    signature: webhook_signature,
};
let event = verify_webhook(body, headers, secret)?;

Defaults deny network egress. CreateEnvironmentParams::cloud creates limited networking with no allowed hosts; use cloud_limited(name, hosts) or cloud_unrestricted(name). ToolConfig::agent_toolset and agent_toolset_with_policy leave out web_fetch and web_search; ToolConfig::agent_toolset_with_web enables all eight tools.

adk-gemini

ClientError gains ErrorInResponse, which reports an error object inside a successful response, and ClientError::BadResponse gains retry_after: Option<String>, the raw Retry-After header. GroundingMetadata, GroundingSegment, UsageMetadata, interactions::Usage, GenerationConfig, and Candidate gain fields, and FinishReason is #[non_exhaustive]. See struct literals and exhaustive matches.

use adk_gemini::ClientError;

// 3.0
fn is_unavailable(error: &ClientError) -> bool {
    matches!(error, ClientError::BadResponse { code: 503, .. })
}

adk-session

Rewind takes the full session identity, so one user's rewind cannot truncate another user's session with the same ID:

// 2.3
let session = sessions.rewind_steps("session-1", 2).await?;
use adk_core::{AdkIdentity, AppName, SessionId, UserId};

// 3.0
let identity = AdkIdentity::new(
    AppName::try_from("support")?,
    UserId::try_from("user-1")?,
    SessionId::try_from("session-1")?,
);
let session = sessions.rewind_steps(&identity, 2).await?;
  • create for an existing session fails with session.already_exists (ErrorCategory::Conflict) on every backend and writes nothing. The in-memory and Redis backends replaced the session. Check AdkError::is_conflict() where a create may race.
  • delete_all_sessions also deletes the user's user: state in the app, on every backend; Vertex AI implements it by deleting each session. Keep a value that must outlive the user's sessions in app: state or outside the session store. The trait's default implementation returns session.delete_all.unsupported (ErrorCategory::Unsupported).
  • sql_schema_version and schema_version() report read failures as errors instead of version 0; they return 0 only when the registry table does not exist.
  • SQL migration steps are 'static: migration::sqlite_runner::run_sql_migrations and migration::pg_runner::run_sql_migrations take &'static [(i64, &'static str, &'static str)]. Declare custom steps as a const or static slice.
  • SQLx 0.9: applications that share pools or call the migration runners update their SQLx dependency; see SQLx 0.9 in ADK-Rust 3.0.
  • A custom SessionService implements history primitives, not rewind. rewind and rewind_steps are provided methods built on rewrite_history, and fork on history and import_session. Implement those three to support history operations; plan with SessionHistory::rewrite and SessionHistory::fork inside the backend's transaction. The defaults return session.history.unsupported, which replaces session.rewind.unsupported. See Fork, Rewind, and Edit History.
  • Rewinds keep tool calls paired and stop at held calls: a rewind that would keep a tool call without its response fails with session.history.splits_tool_call, and a rewind of a session holding a call for a decision fails with session.history.held_call.
  • PostgreSQL migration 3 adds sessions.initial_state; run migrate() after upgrading.
  • Invalid identifiers fail with session.invalid_identifier. An empty, oversized, or NUL-containing app name, user ID, or session ID fails on every backend, in the encrypted wrapper, and in Runner::run_str with session.invalid_identifier (ErrorComponent::Session, ErrorCategory::InvalidInput, HTTP 400) instead of config.legacy, so AdkError::is_config() is false for it. VertexAiSessionService reports an empty identifier with this code instead of session.vertex.invalid_input.

adk-artifact

  • Artifact versions are immutable. A save with version: Some(n) for an existing n fails with artifact.version_exists (ErrorCategory::Conflict) instead of replacing it; save with version: None to add a version.

  • The session id user is reserved for user-scoped artifacts and is rejected with artifact.reserved_session_id.

  • FileArtifactService writes a new on-disk layout; see before you upgrade.

  • Errors are typed on every backend. InMemoryArtifactService and FileArtifactService reported these failures as artifact.legacy (ErrorCategory::Internal):

    Failure3.0 codeCategory
    Missing artifact or versionartifact.not_foundNotFound, so AdkError::is_not_found() is true
    Invalid file name, such as ../escape.txtartifact.invalid_nameInvalidInput
    Invalid app name, user ID, or session IDartifact.invalid_identifierInvalidInput
    FileArtifactService filesystem failureartifact.file.ioInternal

    GcsArtifactService uses the same codes for the same failures instead of artifact.gcs.not_found and artifact.gcs.invalid_input, which remain for failed GCS requests.

adk-memory and adk-rag

PgVectorStore accepts collection names of 1 to 59 ASCII lowercase letters, digits, and underscores, and returns RagError::VectorStoreError for any other name; 2.3.0 rewrote invalid characters to _, so docs-v1 and docs_v1 shared one table. PgVectorStore::new returns adk_rag::Result. The SQLx and pgvector feature changes are in the SQLx 0.9 guide.

AgentRetrievalStore refuses a collection name it would have rewritten onto another collection, with RagError::VectorStoreError:

Store2.x3.0
AgentRetrievalStoreLowercased, replaced other characters with -, and truncated to 63, so Docs, docs, and docs_ could share a collectionAccepts ASCII lowercase letters, digits, and underscores; _ becomes - in the collection ID, so my_docs still reaches the collection 2.x named my-docs

QdrantVectorStore stores each chunk under the UUID v5 of its chunk ID and keeps the chunk ID in the point's chunk_id payload; 2.x used the chunk ID as the point ID, which Qdrant refused unless it was a UUID. A collection written by 2.x with UUID chunk IDs is still searchable, but upserts and deletes now address the derived point IDs, so re-ingest it.

RagTool (rag_search) answers each result as {"id", "document_id", "text", "metadata", "score"} instead of the whole SearchResult, so embedding vectors no longer reach the model. A top_k argument goes through RagPipeline::query_with_top_k, which reranks and applies the similarity threshold as query does, and a missing query or a top_k that is not a positive integer fails with tool.invalid_arguments.

RagTool searches only its configured collections. RagTool::new(pipeline, "kb") has no collection argument and refuses a call that names another collection with tool.invalid_arguments; 2.x searched whatever collection the model named. To let the model choose, list the collections:

use std::sync::Arc;

use adk_rag::{RagPipeline, RagTool};

fn search_tool(pipeline: Arc<RagPipeline>) -> RagTool {
    RagTool::new(pipeline, "docs").with_allowed_collections(["faq", "changelog"])
}

RagTool is read-only and concurrency-safe, so DeclarativePolicy::allow_read_only() admits it.

Memories carry ids and expire

adk_memory::MemoryEntry has two new fields, id and expires_at, and is #[non_exhaustive]:

use adk_core::Content;
use adk_memory::MemoryEntry;

// 2.x
// let entry = MemoryEntry { content, author: "user".to_string(), timestamp: chrono::Utc::now() };
let entry = MemoryEntry::new(Content::new("user").with_text("Prefers email"), "user");
Change2.x3.0
MemoryService—delete_memory(app, user, id) and purge_expired(), with defaults that return an error; a wrapper forwards both
Search and listingReturned every stored entrySkip entries whose expires_at has passed; each returned entry carries its id
RedisMemoryConfig::ttlExpired a whole session list, refreshed by every write to itThe default TTL of each entry written without an expiry; a list key expires with its latest entry
Schema—Migration 3 adds memory_id and expires_at to SQLite and PostgreSQL, and indexes to MongoDB (a TTL index on expires_at) and Neo4j; the knowledge graph's migration 2 adds them to its episodic log. migrate() applies them and gives existing entries ids

The SurrealDB vector store is removed

SurrealVectorStore and the surrealdb feature of adk-rag are removed, and full no longer enables them. The backend's dependency tree carried RUSTSEC-2026-0453 and RUSTSEC-2026-0454, the second fixed only in surrealdb 4.0, and every Business Source License crate in the workspace.

2.x3.0
features = ["surrealdb"]Remove the feature and choose another backend: pgvector, lancedb, qdrant, or agent-retrieval
SurrealVectorStore::in_memory()InMemoryVectorStore::new(), or LanceDBVectorStore for an embedded store on disk
SurrealVectorStore::rocksdb(path), SurrealVectorStore::remote(url)Another VectorStore; re-ingest the source documents into it

A deployment that keeps SurrealDB implements VectorStore over the surrealdb crate in its own code; the shared contract in adk-rag/tests/common/vector_store_contract.rs states what an implementation must satisfy.

Every vector store operation names a scope

VectorStore methods take a Scope, and a stored chunk is identified by its collection, scope, and chunk ID together. RagPipeline loses ingest, ingest_batch, query, and query_with_top_k; they move to ScopedRag, from pipeline.scoped(scope), which adds count and purge_scope. create_collection takes a CollectionSpec, and search a VectorQuery:

use adk_rag::{Document, RagPipeline};

// 2.3
async fn ingest_and_query(pipeline: &RagPipeline, document: &Document) -> adk_rag::Result<()> {
    pipeline.ingest("docs", document).await?;
    let results = pipeline.query_with_top_k("docs", "refund window", 3).await?;
    Ok(())
}
use adk_rag::{Document, QueryOptions, RagPipeline, Scope};

// 3.0
async fn ingest_and_query(pipeline: &RagPipeline, document: &Document) -> adk_rag::Result<()> {
    let rag = pipeline.scoped(Scope::single_tenant());
    rag.ingest("docs", document).await?;
    let options = QueryOptions::new().with_top_k(3);
    let results = rag.query_with("docs", "refund window", &options).await?;
    Ok(())
}

A multi-tenant application builds the scope from the authenticated tenant, for example Scope::from_parts(["support-app", tenant_id])?, and gives it to RagTool::with_scope. A custom VectorStore implements the scoped signatures plus count and purge_scope, and must apply the scope inside its search, before the top k are chosen; the shared contract in adk-rag/tests/common/vector_store_contract.rs checks this.

StoreStored data
PgVectorStorecreate_collection adds a scope column, assigns existing rows to Scope::single_tenant(), and re-keys the table by (scope, id)
LanceDBVectorStoreDelete the collection, create it again, and re-ingest; upsert into an old table fails with that guidance
QdrantVectorStoreRe-ingest: point IDs now derive from scope and chunk ID, and old points carry no scope
AgentRetrievalStoreDelete the collection, create it again, and re-ingest: collections now declare a data schema, metadata is stored as metadataJson, and Data Object IDs derive from scope and chunk ID

AgentRetrievalStore::hybrid_search takes the scope after the collection name.

A custom VectorStore also implements delete_where(collection, scope, &Filter), takes filter: Option<&Filter> in count, and applies VectorQuery::filter in search, inside its query and before the top k, returning RagError::UnsupportedFilter for a filter it cannot express. Filter::matches is the reference semantics, and the shared contract's filter_catalogue checks them.

ScopedRag::ingest replaces a document's chunks: after upserting the new chunks it deletes the document's chunks in the scope that the new version no longer has, where 2.x left them in place. To filter on a metadata key, declare it when creating the collection, with RagPipeline::create_collection_with_filterable or CollectionSpec::with_filterable; LanceDB and Agent Retrieval store each declared key as a field of its own, so their collections are created again to add one.

Documents and chunks carry provenance

Document gains title, and Chunk gains source_uri and title. Both types are #[non_exhaustive], so code outside adk-rag builds them with constructors:

use std::collections::HashMap;
use adk_rag::Document;

// 2.3
let document = Document {
    id: "refunds".to_string(),
    text: "Refunds are issued within 30 days.".to_string(),
    metadata: HashMap::from([("section".to_string(), "billing".to_string())]),
    source_uri: Some("https://example.com/refunds".to_string()),
};
use adk_rag::{Chunk, Document};

// 3.0
let document = Document::new("refunds", "Refunds are issued within 30 days.")
    .with_metadata("section", "billing")
    .with_source_uri("https://example.com/refunds")
    .with_title("Refund policy");
let chunk = Chunk::from_document(&document, "refunds_0", "Refunds are issued")
    .with_embedding(vec![0.1, 0.2]);

A custom Chunker builds chunks with Chunk::from_document, which copies the document's ID, metadata, source URI, and title. Every vector store persists source_uri and title as fields of their own, and RagTool results include them when present. Stored data:

StoreDo this
PgVectorStoreCall create_collection once; it adds the source_uri and title columns in place
LanceDBVectorStoreDelete the collection, create it again, and re-ingest; upsert into a 2.x table fails with that guidance
QdrantVectorStore, AgentRetrievalStoreNothing; chunks stored by 2.x return None for both fields until re-ingested

adk-graph

ExecutionConfig has no struct literal

ExecutionConfig gains public fields and a crate-private one, so code outside adk-graph builds it with its constructor and builder methods:

use std::collections::HashMap;
use adk_graph::node::ExecutionConfig;

// 2.3
let config = ExecutionConfig {
    thread_id: "refund-42".to_string(),
    resume_from: None,
    recursion_limit: 25,
    metadata: HashMap::new(),
    parent_context: None,
};
use adk_graph::node::ExecutionConfig;

// 3.0
let config = ExecutionConfig::new("refund-42").with_recursion_limit(25);

The graph's recursion limit bounds its runs

ExecutionConfig::recursion_limit is Option<usize>. None, the default, applies the graph's limit — 100 unless CompiledGraph::with_recursion_limit or GraphAgentBuilder::recursion_limit sets it — and ExecutionConfig::with_recursion_limit overrides it for one run. 2.3.0 ignored the graph's limit and capped every run at the ExecutionConfig default of 50 super-steps, so a run that stopped at 50 now continues to the graph's limit. Code that read the field as a usize reads an Option.

Checkpoints carry a per-thread version

Checkpointer::save refuses a version that is not greater than every stored version of the thread (GraphError::CheckpointConflict). A caller that saves several checkpoints on one thread numbers them:

use adk_graph::state::{Checkpoint, State};

let first = Checkpoint::new("thread-1", State::new(), 0, vec!["plan".to_string()]);
checkpointer.save(&first).await?;
let next = Checkpoint::new("thread-1", State::new(), 1, vec![]).with_version(first.version + 1);
checkpointer.save(&next).await?;

A custom Checkpointer implements prune, which no longer has a default that kept everything.

Retention keeps what a resume needs

RetentionPolicy never removes a checkpoint a resume still needs: besides the newest, each pause no run has resumed and each effect-log entry (checkpoint::needed_to_resume). A custom Checkpointer gets this by selecting with RetentionPolicy::expired; one that hides checkpoint metadata from the store it wraps pins needed_to_resume of its own view before delegating, as adk_harness::SealedCheckpointer does.

ExecutionConfig::with_resume_from naming a checkpoint the store no longer holds fails with GraphError::CheckpointError before any node runs. In 2.3 the run started again from the graph's entry and failed on its first save with GraphError::CheckpointConflict.

Functional resume loads the checkpoint resume_from names

The #[entrypoint]-generated invoke loads ExecutionConfig::resume_from by checkpoint id, and fails with GraphError::CheckpointError when the thread has no checkpoint with that id. To resume where a thread left off, pass the id Checkpointer::load returns:

use adk_graph::node::ExecutionConfig;

// 2.3
let config = ExecutionConfig::new("refund-42").with_resume_from("latest");
use adk_graph::node::ExecutionConfig;

// 3.0
let latest = checkpointer
    .load("refund-42")
    .await?
    .ok_or_else(|| anyhow::anyhow!("thread refund-42 has no checkpoint to resume"))?;
let config = ExecutionConfig::new("refund-42").with_resume_from(&latest.checkpoint_id);

Graph checkpoints are keyed by app, user, and session

GraphAgent runs a session on session_thread_id(app_name, user_id, session_id) and NodeTool runs each call on tool_call_thread_id(app_name, user_id, session_id, function_call_id), instead of the bare session id, so a user who picks another user's session id cannot resume that user's run. Checkpoints written under a bare session id are not read. Code that loads a session's checkpoints directly uses the new id:

// 2.3
let latest = checkpointer.load(session_id).await?;
use adk_graph::agent::session_thread_id;

// 3.0
let latest = checkpointer.load(&session_thread_id(app_name, user_id, session_id)).await?;

To keep a paused run across the upgrade, re-key its checkpoints from the bare session id to session_thread_id(app_name, user_id, session_id); otherwise the session starts over on its next turn.

Errors, pauses, and events

  • An agent node's failure is GraphError::AgentFailed { node, source }, and From<GraphError> for AdkError returns the agent's own error, so a rate-limited model stays RateLimited. GraphAgent and NodeTool convert graph errors with AdkError::from instead of flattening them to AdkError::agent or AdkError::tool.
  • A functional suspension is GraphError::Suspended and a cancellation GraphError::Cancelled, instead of GraphError::Other.
  • InterruptedExecution::interrupts and SuperStepResult::interrupts carry every pause of a step, and GraphAgent yields one event per pause. Read a pause with GraphInterruptPayload::from_event.
  • GraphAgent streams its agent nodes' events under the turn's invocation id, and every event it builds carries that id instead of "graph_output" or "graph_interrupted".
  • SubgraphNode threads become <parent thread>/<node>@<step>, and an entry of {node}_fan_in is the predecessor's own updates instead of the whole state.
  • Interrupt::Dynamic gains id and response_schema, StreamEvent::Interrupted gains interrupt_id, and StreamEvent::NodeInterrupt gains response_schema: end a pattern that names every field with .., and build pauses with interrupt, interrupt_with_data and StreamEvent::interrupted. GraphError is #[non_exhaustive] and gains ResumeRejected, so a match on it needs a wildcard arm. See Interrupt Ids, Typed Answers and Strict Resume.

HTTP action nodes reach public addresses only

HttpActionPolicy refuses loopback, private, link-local (the cloud metadata endpoint included), CGNAT and unspecified addresses, also for an allowlisted host, and the HTTP, notification and RSS nodes no longer use the system proxies. 2.3.0 allowed any host. A workflow that calls a service on a private network or on the same host allows it, ideally beside allow_hosts naming the service:

use adk_action::ActionNodeConfig;
use adk_graph::action::ActionNodeExecutor;
use adk_graph::action::http::HttpActionPolicy;

// 3.0
fn executor(config: ActionNodeConfig) -> ActionNodeExecutor {
    let policy = HttpActionPolicy::new()
        .allow_hosts(["billing.internal.example.com"])
        .allow_private_networks();
    ActionNodeExecutor::new(config).with_http_policy(policy)
}

allow_private_networks also uses the system proxies again.

adk-skill

Skill frontmatter is read and written with serde-saphyr instead of the deprecated serde_yaml, and SkillError::Yaml carries the YAML library's message instead of its error type, so a later change of YAML library is not a breaking change.

2.3.03.0
SkillError::Yaml(serde_yaml::Error)SkillError::Yaml { message: String }

Both libraries read YAML 1.2, so yes, no and 1.0 in frontmatter stay strings. adk-site front matter, adk-server's YAML agent definitions (yaml-agent) and cargo adk read and write YAML through the same library.

adk-server

The bundled runtime UI moves to adk-surface

adk-server serves no page: /, /ui/, /ui/{*path} and /ui/assets/config/runtime-config.json are no longer routed and answer 404, and the web_ui module, with RuntimeConfig and its handlers, is removed. The REST, SSE, A2A and /api/ui/* APIs are unchanged. adk_cli::Launcher serve mode serves the REST API only.

To keep a pageDo this
On a server you build with adk-serverMount adk-surface's web home (web feature): adk_surface::web::router(engine) with ServerBuilder::add_api_routes and adk_surface::web::home() with add_root_routes, behind a RequestContextExtractor (Mount it on your own server)
Without writing a serveradk-rust serve or adk-rust up serve the web home at /ui/ (The web home)

A run needs an existing session

POST /api/run, and POST /api/run_sse without a UI protocol, answer 404 with code session.not_found for a session that does not exist, as the path-style /api/run/{app}/{user}/{session} already did; 2.3.0 created it. A run with a UI protocol (a2ui, ag_ui, mcp_apps) still starts its thread's session. Create the session first:

curl -X POST http://127.0.0.1:8080/api/apps/support/users/user-1/sessions/session-1 \
  -H 'Content-Type: application/json' -d '{}'

curl -X POST http://127.0.0.1:8080/api/run_sse \
  -H 'Content-Type: application/json' \
  -d '{"appName":"support","userId":"user-1","sessionId":"session-1",
       "newMessage":{"role":"user","parts":[{"text":"Hello"}]}}'

POST /api/sessions with appName and userId creates a session with a generated id.

The server is reachable from this machine only by default

Launcher serve mode, adk_cli::serve::run_serve, and adk-rust serve listen on 127.0.0.1 instead of 0.0.0.0. An empty SecurityConfig::allowed_origins, the default, allows no cross-origin access, and a request whose Host is not localhost, *.localhost, an IP address, the A2A or backend URL's host, or a listed name is refused with 403. SecurityConfig::development() allows loopback origins on any port instead of every origin. Where the server must be reachable from other machines, set all three:

use std::net::{IpAddr, Ipv4Addr};
use adk_cli::Launcher;
use adk_server::SecurityConfig;

let security = SecurityConfig {
    allowed_origins: vec!["https://app.example.com".to_string()],
    ..SecurityConfig::default()
}
.with_allowed_hosts(["agents.example.com"]);
Launcher::new(agent)
    .with_bind_address(IpAddr::V4(Ipv4Addr::UNSPECIFIED))
    .with_security_config(security)
    .run_serve_directly(8080)
    .await?;

With ServerBuilder, set the hosts and origins on the ServerConfig:

use adk_server::ServerConfig;

let config = ServerConfig::new(agent_loader, session_service)
    .with_allowed_origins(vec!["https://app.example.com".to_string()])
    .with_allowed_hosts(vec!["agents.example.com".to_string()]);

vec!["*".to_string()] as allowed_origins restores the previous CORS behaviour. The cargo-adk api and server addons read BIND_HOST (default 127.0.0.1), and the generated Dockerfiles set BIND_HOST=0.0.0.0.

A2A

The A2A v1 layer (adk_server::a2a::v1, A2aV1Client) uses a2a-protocol-types 0.15 (2.3.0 used 0.12). Code that builds messages, tasks or agent cards for it depends on the same version; the JSON on the wire is unchanged:

[dependencies]
a2a-protocol-types = "0.15"

A2A clients send messages only to the origin the agent card came from, and refuse a card whose endpoint is elsewhere with a2a.card_endpoint_refused. Allow a further origin explicitly:

use adk_server::a2a::RemoteA2aAgent;

let agent = RemoteA2aAgent::builder("billing")
    .description("Billing agent")
    .agent_url("https://agents.example.com")
    .allow_endpoint_origin("https://rpc.example.com")
    .build()?;

Model thinking never reaches a peer. v1::convert::adk_part_to_wire returns Option, with None for a thinking part:

use adk_server::a2a::v1::convert::adk_part_to_wire;

// 2.3
for part in parts {
    wire.push(adk_part_to_wire(part)?);
}
use adk_server::a2a::v1::convert::adk_part_to_wire;

// 3.0
for part in parts {
    // `None` for a thinking part, which stays private.
    if let Some(converted) = adk_part_to_wire(part)? {
        wire.push(converted);
    }
}

RemoteA2aConfig, RemoteA2aV1Config, RemoteA2aAgent, and RemoteA2aAgentBuilder hold an optional credential broker, so they are no longer UnwindSafe or RefUnwindSafe.

A task that ends on a held or long-running call is input-required, and one that ends on an adk_request_credential call is auth-required (the new TaskState::AuthRequired).

A2A v1 wire and API

With the a2a-v1 feature, which adk-rust's server feature enables, the A2A v1 layer changes in ways a 2.3.0 peer or caller sees:

Change3.0Do this
Endpoints and cardsServerBuilder::with_a2a, create_app_with_a2a and A2aServer serve A2A v1 beside 0.3: JSON-RPC at /a2a/v1, HTTP+JSON under /a2a/v1/rest, and the v1 card at /.well-known/agent-card.json, which served nothing in 2.3.0. The 0.3 card stays at /.well-known/agent.json; /a2a and /a2a/stream stayPoint an A2A 0.3 client that tries agent-card.json first (A2A 0.3's well-known path) at agent.json, since agent-card.json now answers with the v1 card; adk-server's A2aClient falls back to agent.json
Version negotiationv1::version::SUPPORTED_VERSIONS is ["1.0"]: a v1 request without A2A-Version, or with 0.3, gets VersionNotSupportedError, which JSON-RPC reports as error -32009. The header may also be the A2A-Version query parameter. Card routes are not version-checkedSend A2A-Version: 1.0; the ADK-Rust, adk-python and adk-go clients do
SendMessageJSON-RPC SendMessage and REST POST /message:send answer {"task": …} (the SendMessageResponse oneof) instead of a bare Task. A2aV1Client::send_message and send_message_rest return SendMessageResponse and still read a bare Task from older serversMatch SendMessageResponse::Task and SendMessageResponse::Message
ListTasksReturns {tasks, nextPageToken, pageSize, totalSize}, newest first, 50 per page by default (1 to 100); RequestHandler::tasks_list, CallerScope::tasks_list, A2aV1Client::list_tasks and list_tasks_rest return TaskListResponse. The push config list returns {configs, nextPageToken}Read .tasks, and follow next_page_token until it is empty
Continuing a taskA message's taskId must name one of the caller's tasks that waits on the caller (INPUT_REQUIRED or AUTH_REQUIRED): an unknown task gets TaskNotFoundError, another task's contextId gets InvalidParams, a finished or running task gets UnsupportedOperationError. An INPUT_REQUIRED task needs an answer to every call it waits onSend a follow-up without taskId to start a new task in the context
Task updatesEach event becomes one artifact update with all its parts and its metadata (adk_invocation_id, adk_author, …); OutputMode::ArtifactPerRun, the default, keeps the answer in one artifact and streams partial events into an artifact marked adk_partial. Without a run_config, model output no longer streams token by token. The session user without authentication is A2A_USER_{contextId} instead of a2a-{contextId}Read the answer from artifacts not marked adk_partial; set a RunConfig with StreamingMode::SSE to stream
Task versionsTaskStoreEntry::version rises with each save, and InMemoryTaskStore refuses a stale save_task_if_version with A2aError::ConcurrentModification (-32603)Add version: 0 to TaskStoreEntry literals; check the version in a store shared between processes
Errors and cardsHTTP+JSON errors name their google.rpc.Code in status (NOT_FOUND, INVALID_ARGUMENT, …) instead of an HTTP phrase. GetExtendedAgentCard no longer returns the public card: it answers UnsupportedOperation (-32004) when the card declares no extended card, as the card with_a2a builds does, and ExtendedAgentCardNotConfigured (-32007) when no ExtendedCardProducer is set. Card skills are built as adk-go builds them, from Agent::profileMatch the google.rpc.Code names; set A2aV1ServerBuilder::extended_agent_card to serve an extended card
use a2a_protocol_types::{Message, SendMessageResponse, Task};
use adk_server::a2a::client::v1_client::{A2aV1Client, V1ClientError};

// 3.0
async fn send_and_list(client: &A2aV1Client, message: Message) -> Result<Vec<Task>, V1ClientError> {
    let mut tasks = Vec::new();
    if let SendMessageResponse::Task(task) = client.send_message(message).await? {
        tasks.push(task);
    }
    let mut page_token: Option<String> = None;
    loop {
        let page = client.list_tasks(None, None, None, page_token.as_deref()).await?;
        tasks.extend(page.tasks);
        if page.next_page_token.is_empty() {
            return Ok(tasks);
        }
        page_token = Some(page.next_page_token);
    }
}

Background runs and cron jobs use the durable stores

The background feature's process-local stores are removed: RunStore, BackgroundRun, BackgroundRunner, RunPersistence, FileRunPersistence, PersistedRun, RunRetention, CronJobStore, CronJob, DEFAULT_MAX_QUEUE_DEPTH, and CronState::with_max_queue_depth. BackgroundState keeps runs in a DurableRunStore (in memory unless with_run_store gives it a shared one) and CronState keeps jobs in a ScheduleStore:

use std::sync::Arc;
use adk_server::background::{
    BackgroundRunner, BackgroundState, CronState, FileRunPersistence, RunStore, WorkflowExecutor,
};

// 2.3
let store = RunStore::new().with_persistence(Arc::new(FileRunPersistence::new("runs.json")));
let runner = BackgroundRunner::new(store.clone()).with_executor(executor);
let background = BackgroundState { store, runner };
let cron = CronState::new(background.clone()).with_max_queue_depth(10);
use std::sync::Arc;
use adk_server::background::{BackgroundState, CronState, WorkflowExecutor};
use adk_session::{SqliteRunStore, SqliteScheduleStore};

// 3.0
let runs = SqliteRunStore::new("sqlite://runs.db?mode=rwc").await?;
runs.migrate().await?;
let schedules = SqliteScheduleStore::new("sqlite://runs.db?mode=rwc").await?;
schedules.migrate().await?;
let background =
    BackgroundState::new().with_run_store(Arc::new(runs)).with_executor(executor);
let cron = CronState::new(background.clone()).with_schedule_store(Arc::new(schedules));
  • SubmitRunRequest::timeout_secs is removed; use DurableWorkerConfig::run_timeout. SubmitRunRequest gains target, session_id, user_id, idempotency_key, concurrency_key, on_conflict, and not_before, and CreateCronJobRequest gains timezone and missed_fire_policy.
  • CronState::cron_store is now schedules, and validate_cron_expression returns Result<(), String>.
  • REST responses change: RunStatusResponse adds target, attempt, maxAttempts, cancelRequested, sessionId, and checkpoint; CronJobResponse uses the job name as jobId and drops createdAt, lastExecution, executionCount, and activeRunCount. Creating a job with an existing name returns 409, and DELETE /runs/{id} on a running run returns it running with cancelRequested: true until its worker stops it.
  • Runs and cron jobs belong to their caller on a server with a RequestContextExtractor: GET /runs lists the caller's runs, another owner's run or job answers 404, idempotencyKey and concurrencyKey are scoped to the owner, and a cron job's runs act for its owner instead of the user cron.

The agent registry checks card owners

With agent-registry, registry_router takes a RequestContextExtractor and authenticates every request through it (401 for a refused token or an empty user id). A registered card records its owner (AgentCard::owner); any authenticated caller lists and reads every card, a taken name answers 409, and only the owner updates the card through PUT /agents/{name} or deletes it — anyone else gets 403. An AgentRegistryStore implements replace_owned and delete_owned, which check the owner and write in one step:

use std::sync::Arc;
use adk_server::auth_bridge::RequestContextExtractor;
use adk_server::registry::{InMemoryAgentRegistryStore, registry_router};

// 2.3: registry_router(store)
// 3.0
fn registry(extractor: Arc<dyn RequestContextExtractor>) -> axum::Router {
    registry_router(Arc::new(InMemoryAgentRegistryStore::new()), extractor)
}

Run timeouts and error responses

  • Agent runs get their own timeout. /api/run, /api/run/{app}/{user}/{session}, /api/run_sse, /a2a, /a2a/stream, /a2a/v1 and /a2a/v1/rest/message:* answer 408 after SecurityConfig::run_timeout (15 minutes by default; ServerConfig::with_run_timeout) instead of the 30-second request_timeout, which every other route keeps.
  • Error responses keep upstream text out. With SecurityConfig::expose_error_details off, the default, the run endpoints' Problem JSON, SSE error event and AG-UI RUN_ERROR carry the error's message only when the server rejected the request itself (categories such as invalid_input, not_found, conflict); a provider's or a store's text is replaced by a generic message for its category and logged with the request's x-request-id. code, category, requestId and retryAfter are kept.
  • AG-UI held calls end as interrupts. A protocol-native AG-UI stream no longer sends a held call's placeholder TOOL_CALL_RESULT or text message; the run ends with an interrupt for the call, and its result arrives against the same toolCallId in the run that resumes it.
  • The debug trace route answers its owner only. GET /api/debug/trace/{event_id} matches the span's event id only (404 for any other value), and with a RequestContextExtractor answers 403 unless the span's user is the caller.
  • Handlers called directly take more extractors. rest::controllers::session::list_sessions takes a Query<ListSessionsQuery>, and a2a::v1::jsonrpc_handler::jsonrpc_handler takes the requested extensions and the raw body. Routers that mount them, create_app included, are unaffected.
  • A2A push notifications reach public addresses only. HttpPushNotificationSender refuses a webhook host that resolves to a loopback, private, link-local or metadata address, and ignores proxy settings.

The OpenAI webhook handler verifies Standard Webhooks deliveries

OpenAIWebhookHandler (openai-webhooks) checks the webhook-id, webhook-timestamp and webhook-signature headers OpenAI sends, in place of a hex HMAC in x-openai-signature.

2.x3.0
OpenAIWebhookHandler::new(config) returns SelfReturns Result<Self, WebhookError>; the secret is the whsec_... value from the OpenAI dashboard
handler.validate_signature(body, hex)handler.verify(&WebhookHeaders, body)
Any delivery with a valid signature is broadcastA delivery signed more than five minutes from the local clock is refused, and a repeated webhook-id is acknowledged without a second broadcast
use adk_server::webhooks::{OpenAIWebhookConfig, OpenAIWebhookHandler};

let handler = OpenAIWebhookHandler::new(OpenAIWebhookConfig {
    webhook_secret: std::env::var("OPENAI_WEBHOOK_SECRET")?,
    path: "/webhooks/openai".to_string(),
})?;
let router = handler.router();
# let _ = router;
# Ok::<(), Box<dyn std::error::Error>>(())

adk-auth

A guarded tool whose audit sink fails is refused. ProtectedTool, ProtectedToolDyn, ScopedTool, and ScopedToolDyn default to AuditFailureMode::Block, so a sink error fails the call with auth.audit_failed instead of being ignored. To keep running while the sink is down:

use adk_auth::{AccessControl, AuditFailureMode, AuditSink, ProtectedTool};

let protected = ProtectedTool::with_audit(tool, access_control, sink)
    .with_audit_failure_mode(AuditFailureMode::Warn);

PostgresAuditSink writes two new columns, agent_id and on_behalf_of. Call migrate() once on a database created by 2.3.0; until then every insert fails.

SSO

  • Tokens need iss and aud. JwtValidator and the Google, Azure AD, Okta, Auth0 and generic OIDC providers refuse a token without an iss or aud claim with TokenError::MissingClaim (auth.missing_claim); jsonwebtoken checked those claims only when a token carried them. A token without exp fails with MissingClaim instead of DecodingError. AzureADProvider::multi_tenant requires iss and checks no issuer value.

  • JwtValidatorBuilder::build requires an audience. Call audience(..), or without_audience() for an issuer whose tokens carry no aud; that validator refuses a token that carries one.

  • SsoAccessControl refuses a grant it cannot audit. A grant whose audit record fails returns SsoError::AuditFailed; SsoAccessControlBuilder::audit_failure_mode(AuditFailureMode::Warn) grants it with a warning.

  • No jsonwebtoken types in the API. adk-auth moves to jsonwebtoken 12 and keeps its types private, so a later jsonwebtoken major does not break adk-auth.

    2.x3.0
    JwtValidatorBuilder::algorithm(jsonwebtoken::Algorithm::ES256)algorithm(JwtAlgorithm::ES256), or algorithm("ES256".parse()?)
    jsonwebtoken::Algorithm::HS256 (refused by build)No JwtAlgorithm variant; "HS256".parse::<JwtAlgorithm>() fails with TokenError::UnsupportedAlgorithm
    ? on a jsonwebtoken::errors::Error into TokenErrorMap it yourself, for example TokenError::DecodingError(err.to_string())
    JwksCache::get_key(kid) returning jsonwebtoken::DecodingKeyCrate-private; validate with JwtValidator or a provider
  • Unknown critical headers are refused. A token whose crit header names an extension the validator does not implement fails with TokenError::DecodingError.

use adk_auth::sso::{JwtAlgorithm, JwtValidator, TokenError};

// 3.0
fn validator() -> Result<JwtValidator, TokenError> {
    JwtValidator::builder()
        .issuer("https://login.example.com/")
        .jwks_uri("https://login.example.com/.well-known/jwks.json")
        // Required: `without_audience()` only for an issuer that sends no `aud` claim.
        .audience("api://agents")
        .algorithm(JwtAlgorithm::ES256)
        .build()
}

adk-guardrail

  • Guardrail blocks are structured errors. An input or output block ends the run with ErrorComponent::Guardrail, ErrorCategory::InvalidInput (HTTP 400), and code guardrail.input_blocked or guardrail.output_blocked, instead of agent.legacy (HTTP 500). Code that matched agent.legacy or is_agent() for a block matches the new codes.
  • PathAllowList denies a call that omits a path argument, which it allowed unchecked.
  • PathAllowList checks the keys it names at any depth, in nested objects and arrays, not only at the top level. A call holding a path outside the allowed roots, or a value other than a path, under a named key anywhere in its arguments is denied. Scope the guardrail with on_tools when a tool uses a key of the same name for something other than a filesystem path.
  • ContentFilter::new and ContentFilter::blocked_keywords return Result, failing with GuardrailError::Regex for a keyword list that cannot compile instead of building a filter that blocks nothing.
use adk_guardrail::{ContentFilter, PathAllowList};

let filter = ContentFilter::blocked_keywords(vec!["internal-only".to_string()])?;
// Allow calls that omit the path arguments, as 2.3.0 did.
let paths = PathAllowList::new("workspace", ["path"], ["/srv/data"]).allow_missing();

adk-eval and cargo-adk

BaselineStore::check_regressions returns an error when the baseline file does not exist, and reports a metric or case with no score in the current run as a regression, so Regression::current_value is an Option:

use adk_eval::BaselineStore;

// 2.3
let store = BaselineStore::new(".eval-baseline.json");
for regression in store.check_regressions(&current, 0.05)? {
    println!("{}: {:.3}", regression.metric_name, regression.current_value);
}
use adk_eval::BaselineStore;

// 3.0
let store = BaselineStore::new(".eval-baseline.json");
// Fails when the baseline file does not exist.
for regression in store.check_regressions(&current, 0.05)? {
    match regression.current_value {
        Some(value) => println!("{}: {value:.3}", regression.metric_name),
        None => println!("{}: no score in this run", regression.metric_name),
    }
}

Judge settings are applied and are optional, because Claude 5 and OpenAI reasoning models reject sampling parameters:

use adk_eval::{LlmJudge, LlmJudgeConfig, StructuredJudgeConfig};

// 2.3
let judge = LlmJudge::with_config(model, LlmJudgeConfig { max_tokens: 1024, temperature: 0.0 });
let structured = StructuredJudgeConfig { temperature: 0.0, ..Default::default() };
use adk_eval::{LlmJudge, LlmJudgeConfig, StructuredJudgeConfig};

// 3.0
let judge = LlmJudge::with_config(
    model,
    LlmJudgeConfig { max_tokens: Some(1024), temperature: Some(0.0) },
);
let structured = StructuredJudgeConfig { temperature: Some(0.0), ..Default::default() };

Evaluator::evaluate_cases_parallel returns a Result, failing for a concurrency of 0 or an empty slice:

// 2.3
let results = evaluator.evaluate_cases_parallel(agent, cases, 4).await;
// 3.0
let results = evaluator.evaluate_cases_parallel(agent, cases, 4).await?;
  • Judged criteria fail closed. A judge reply without a valid SCORE: line is an error, and safety, hallucination, and semantic replies need their SAFE:, HALLUCINATION_FREE:, or EQUIVALENT: line; a SemanticMatchConfig::custom_prompt asks for the EQUIVALENT: line too. A judged criterion without a judge fails the case instead of being skipped.
  • Evaluations that evaluate nothing fail: a file without cases, a case without turns, an evaluator without criteria, or an evaluate_directory directory without *.test.json files is EvalError::ConfigError. A case that no configured criterion applies to fails with a not_evaluated failure, and EvaluationReport::all_passed() is false for a report without results. Custom criteria do not count, because Evaluator does not score them: a configuration with only EvaluationCriteria::custom entries is a ConfigError before the agent runs.
  • The eval schema gains vision fields: Turn::expected_vision, TurnResult::actual_vision, EvaluationCriteria::vision, schema::Part::Image and BenchError::Vision. Eval files without images parse unchanged; struct literals and exhaustive matches add them.
  • cargo adk eval runs your agent. It starts the command given with --agent-cmd, sends one JSON request per turn on its stdin, and reads one JSON response per turn from its stdout. The --model and --concurrency flags are removed.
  • Refusals stop an evaluation. Judge calls meter against the current ModelCallScope, and a run or judge call refused by a budget, a spend ledger or a frozen kill switch returns EvalError::Refused instead of a failed case. EvalError is #[non_exhaustive], so an exhaustive match needs a wildcard arm. Drop a MeteredLlm wrapper around a judge model that runs under a scope, which would meter each call twice.
cargo adk eval tests/support.test.json --agent-cmd "./target/release/support-agent-eval"

Benchmarks

  • cargo adk bench is behind the bench feature, off by default, so cargo install cargo-adk no longer compiles adk-bench. Without the feature the subcommand exits with status 2 and names the install command: cargo install cargo-adk --features bench.
  • cargo adk bench --suite, BenchConfig::suite, and adk_bench::TaskSuite are removed; the flag ran the ordinary workloads whatever suite it named.
  • BenchmarkResult reports only what the runner measures: tool_invocation, token_overhead, ToolInvocationMetrics, TokenOverheadMetrics, and TokenBreakdown are removed. memory is filled on Linux and macOS, and model and the cost estimate use BenchConfig::model instead of the workload's declared model.

adk-payments

PaymentPolicyGuardrail::evaluate and PaymentPolicySet::evaluate are async and take a PaymentPolicyContext, which carries the operation, the paying org and agent, and the spend ledger:

use adk_payments::domain::{ProtocolDescriptor, TransactionRecord};
use adk_payments::guardrail::{PaymentPolicyDecision, PaymentPolicyGuardrail};

// 2.3
impl PaymentPolicyGuardrail for NoTestMerchant {
    fn name(&self) -> &str {
        "no_test_merchant"
    }

    fn evaluate(
        &self,
        record: &TransactionRecord,
        _protocol: &ProtocolDescriptor,
    ) -> PaymentPolicyDecision {
        if record.merchant_of_record.merchant_id == "test" {
            return PaymentPolicyDecision::deny(Vec::new());
        }
        PaymentPolicyDecision::allow()
    }
}
use adk_payments::domain::{ProtocolDescriptor, TransactionRecord};
use adk_payments::guardrail::{
    PaymentPolicyContext, PaymentPolicyDecision, PaymentPolicyGuardrail,
};
use async_trait::async_trait;

// 3.0
#[async_trait]
impl PaymentPolicyGuardrail for NoTestMerchant {
    fn name(&self) -> &str {
        "no_test_merchant"
    }

    async fn evaluate(
        &self,
        record: &TransactionRecord,
        _protocol: &ProtocolDescriptor,
        _context: &PaymentPolicyContext,
    ) -> PaymentPolicyDecision {
        if record.merchant_of_record.merchant_id == "test" {
            return PaymentPolicyDecision::deny(Vec::new());
        }
        PaymentPolicyDecision::allow()
    }
}

Payment tools enforce their declared scopes. PaymentToolsetBuilder::build wraps every tool in an adk-auth ScopeGuard, which reads ToolContext::user_scopes() by default; grant the scopes, or supply a resolver:

use adk_auth::{ScopeGuard, StaticScopeResolver};
use adk_payments::tools::PaymentToolsetBuilder;

let toolset = PaymentToolsetBuilder::new(checkout, transactions)
    .with_scope_guard(ScopeGuard::new(StaticScopeResolver::new(vec![
        "payments:checkout:create",
        "payments:checkout:update",
        "payments:checkout:complete",
    ])))
    .build();
  • Payment tools govern checkouts. Checkout creation and completion go through GovernedCheckoutService: a policy escalation fails with payments.policy.approval_required unless the run approves the call, and completion fails with payments.policy.checkout_not_found when the backend cannot return the checkout.
  • The acting agent is the commerce actor. The tools record the acting agent's id (urn:adk:agent:{app}/{agent} unless configured) instead of agent-tool.
  • auth::PaymentOperation gains ExecutePayment, with the scope payments:payment:execute.
  • Autonomous AP2 payments need a verified intent authorization: submit the intent mandate with its user authorization artifact.

adk-realtime

  • RealtimeAgent, RealtimeRunner, IntegratedRealtimeRunner, and ToolBridgeAdapter answer a failed tool without its message; call expose_tool_error_messages(true) on the builder, or ToolBridgeAdapter::with_exposed_error_messages(true), for the 2.3.0 behaviour.

  • A failed after-tool stage answers with result_withheld_response instead of the tool's result or the callback's error.

  • Tool-call arguments that are not valid JSON are answered with an error instead of running the tool with {}.

  • Two static tools with one name fail the build.

  • RealtimeRunner and IntegratedRealtimeRunner run every tool call through the governed path, under RunConfig::default() and a kill switch of their own when no tool_governance is set, instead of executing it directly. A call nothing denies still runs; a call marked with require_tool_confirmation that nothing can decide is refused.

    2.x3.0
    Every tool call executesEvery tool call is authorized first; restrict calls with a ToolPolicy in tool_governance
    No kill switchrunner.governance().freeze(reason); share one with .governance(control) on the builder
    Tool contexts answer run_config() with NoneTool contexts answer with the governance config, runner.run_config()

adk-audio

SttProvider::transcribe_stream yields TranscriptEvents instead of Transcripts, so a stream tells interim text from final text. The method has a default that returns AudioError::Stt, so a provider without streaming drops its own implementation. SttOptions is #[non_exhaustive]: build it with SttOptions::default() and the with_* methods.

2.x stream item3.0 event
Ok(transcript) for an interim resultOk(TranscriptEvent::Partial { text, .. })
Ok(transcript) for a final resultOk(TranscriptEvent::Final { transcript, .. })
—Started, SpeechStarted, SpeechEnded, Speaker, Progress, Usage
use adk_audio::{AudioResult, TranscriptEvent, TranscriptStream};
use futures::StreamExt;

async fn finals(mut events: TranscriptStream) -> AudioResult<Vec<String>> {
    let mut texts = Vec::new();
    while let Some(event) = events.next().await {
        if let TranscriptEvent::Final { transcript, .. } = event? {
            texts.push(transcript.text);
        }
    }
    Ok(texts)
}

adk-browser

Navigation refuses loopback, private, link-local, shared-address, and cloud metadata addresses, host names that resolve to them, and host names the agent host cannot resolve, and checks the page the browser ends on after a redirect. browser_file_upload is in no profile and uploads only inside configured roots. For an agent meant to reach an internal network or upload files:

use adk_browser::{BrowserSession, BrowserToolset};

// Only for an agent meant to browse an internal network and upload files.
let toolset = BrowserToolset::new(browser)
    .with_private_network_access(true)
    .with_file_upload(["/srv/agent/uploads"]);

with_unresolved_hosts(true) permits host names the agent host cannot resolve, for a browser that resolves names through a proxy.

adk-devtools

Workspace::new disables bash, which runs model-written commands outside the file tools' path containment, and DevToolset omits the tool until it is enabled. A model-supplied timeout_secs can no longer extend a command past Workspace::bash_timeout.

use adk_devtools::{DevToolset, Workspace};

let toolset = DevToolset::new(Workspace::new("./my-repo").allow_bash(true));
  • An edit of a file changed since it was read is refused. edit_file without expect_sha256 requires the file to still have the digest recorded when it was read, and answers devtools.stale (DevToolError::Stale, ErrorCategory::Conflict) otherwise, writing nothing; Workspace::with_read_ledger sets where the records live.
  • bash returns at most 30,000 characters of output: the first 10,000 and the last 20,000 around a marker, instead of up to 1 MiB per stream from the start.

adk-code and adk-sandbox

ContainerConfig and DockerConfig drop every capability, set no-new-privileges, and limit a container to 256 processes by default. A DockerConfig setup command that switches users, such as apt-get, needs the capabilities:

use adk_code::DockerConfig;

let docker = DockerConfig {
    image: "python:3.12-slim".to_string(),
    setup_commands: vec!["apt-get update && apt-get install -y git".to_string()],
    // `apt-get` switches users, which needs the capabilities kept.
    drop_capabilities: false,
    ..DockerConfig::default()
};

SandboxError is #[non_exhaustive], so a match on it needs a wildcard arm.

SandboxPolicy's allow_network: bool and network_rules: Vec<NetworkRule> become one network: NetworkAccess — Denied (the default), Proxied { endpoint }, or Open. SandboxPolicyBuilder::allow_network() still sets Open; allow_domain and NetworkRule are removed, since no enforcer applied them. Policies serialized by 2.x load unchanged in meaning. An enforcer refuses a mode it cannot enforce with SandboxError::Unenforceable instead of logging a warning and running:

2.x3.0
policy.allow_networkpolicy.network == NetworkAccess::Open, or policy.network.restricts()
.allow_domain("api.example.com", &[443]).proxied(endpoint) with an egress proxy that admits the host
impl SandboxEnforcer for MyEnforceradd fn network_support(&self) -> NetworkSupport; a wrapper forwards its inner enforcer's
WindowsEnforcer::new() with the network deniedWindowsEnforcer::new().acknowledge_open_network(), accepting that the network stays open
WindowsEnforcer written as a unit valueWindowsEnforcer::new(): the struct has private fields
bubblewrap granting /run (or a path under it holding a socket), /tmp, /var/tmp or /dev/shm with the network deniedgrant a narrower directory
use adk_sandbox::sandbox::{NetworkAccess, SandboxPolicyBuilder};

let policy = SandboxPolicyBuilder::new().allow_read("/usr").build();
assert_eq!(policy.network, NetworkAccess::Denied);
assert!(policy.network.restricts());

adk-managed

  • A custom tool call ends the turn with agent.custom_tool_use and a status.idle that requires action; the turn continues after user.custom_tool_result. ToolParkingLot and the parking module are removed, and SessionLoop::new and SessionLoop::with_pause_controls no longer take a parking lot.
  • DefaultModelResolver is no longer a unit struct; build it with DefaultModelResolver::new().
  • Built-in tools run confined. bash and code_execution run under the platform's OS sandbox (Seatbelt on macOS, bubblewrap on Linux) in a workspace of the session's own, and are refused with managed.builtin.sandbox_unavailable where none runs, Windows included. filesystem resolves every path inside that workspace. Running the commands on the host as 2.x did takes an explicit BuiltinTools::unsafe_unconfined_host().
  • The sandbox feature is removed: adk-sandbox always links and with_sandbox needs no feature. build_agent(def, model, sandbox) becomes build_agent(def, model, &tools) with a BuiltinTools, ManagedBuiltinTool::new takes a BuiltinTools, and DefaultManagedAgentRuntime::sandbox() becomes builtin_tools().
  • Every turn's Runner shares the runtime's GovernanceControl, ToolPolicy and action ledger, set with with_governance, with_tool_policy and with_action_ledger.
use std::sync::Arc;

use adk_managed::builtin::BuiltinTools;
use adk_managed::resolver::DefaultModelResolver;
use adk_managed::DefaultManagedAgentRuntime;
use adk_session::InMemorySessionService;

// 2.3: built-in tools ran on the host with nothing confining them.
// 3.0: the same, chosen explicitly; the default confines them.
let runtime = DefaultManagedAgentRuntime::new(
    Arc::new(DefaultModelResolver::new()),
    Arc::new(InMemorySessionService::new()),
)
.with_builtin_tools(BuiltinTools::unsafe_unconfined_host());

ManagedSessionState gains record, pending, and durable_run_id; build it with its constructor:

use adk_managed::{ManagedSessionState, RunState};

let state = ManagedSessionState::new(Vec::new(), RunState::initial());

ScriptedLlm is adk_model::ScriptedLlm. A call past the last scripted turn fails with model.scripted.exhausted, and the turn counters are replaced:

use adk_managed::{ScriptedLlm, ScriptedTurn};

// 2.3
let llm = ScriptedLlm::new(
    "scripted-model",
    vec![ScriptedTurn { text: Some("Done.".to_string()), tool_calls: vec![] }],
);
let calls = llm.turns_consumed();
let left = llm.total_turns() - calls;
use adk_managed::{ScriptedLlm, ScriptedTurn};

// 3.0
let llm = ScriptedLlm::new(
    "scripted-model",
    vec![ScriptedTurn { text: Some("Done.".to_string()), tool_calls: vec![] }],
);
let calls = llm.requests().len();
let left = llm.remaining();

adk-acp

adk-acp moves from agent-client-protocol 2.2 to ~5.2 (ACP schema 1.17). Code that uses the adk_acp::agent_client_protocol re-export follows the SDK's v5 layout: protocol v1 messages move from agent_client_protocol::schema::v1 to agent_client_protocol::v1::schema, and Client.builder() and Agent.builder() become Client.v1() and Agent.v1(); the SDK's changelog has the rest. The ACP wire protocol stays at version 1; the draft protocol v2 is behind the unstable-protocol-v2 feature.

  • AcpAgentConfig, PromptResult and OutputChunk are #[non_exhaustive]. Build AcpAgentConfig with AcpAgentConfig::new(command) and its builder methods. PromptResult gains stop_reason and usage, OutputChunk::Done becomes Done { stop_reason, usage }, and OutputChunk gains variants for plans, notices, compactions, mode, config, command and session-info changes, user text and subagents.
  • AcpSession::start returns once the agent created the session, so a refused handshake or session/new fails start instead of the first prompt. The client requests the highest version in SUPPORTED_PROTOCOL_VERSIONS and rejects an agent that selects another.
  • Errors: AcpError gains Unsupported, returned when the agent did not advertise what a request needs, and AcpServerError gains AuthRequired and Unsupported. A request that names a missing session gets ACP's session_not_found error (-32002 with {"sessionId"}) instead of -32602.
use adk_acp::OutputChunk;

// 3.0
fn print_chunk(chunk: &OutputChunk) {
    match chunk {
        OutputChunk::Text(text) => print!("{text}"),
        OutputChunk::Done { stop_reason, .. } => println!("\n[done: {stop_reason:?}]"),
        OutputChunk::Error(message) => eprintln!("{message}"),
        // Plans, notices, tool calls, and variants added later.
        _ => {}
    }
}

With the server feature, AcpSessionHandler's session setup takes the client connection and the SDK's request types, and AcpServerConfig gains fields (build it with AcpServerConfigBuilder::new()):

2.3.03.0
create_session(request, cancellation)create_session(request, cancellation, connection)
resume_session(&session_id, cwd, directories, mcp_servers, cancellation)resume_session(ResumeSessionRequest, cancellation, connection)
load_session(&session_id, cwd, directories, mcp_servers, cancellation, connection)load_session(LoadSessionRequest, cancellation, connection)
fork_session(&source_id, cwd, directories, mcp_servers, cancellation)fork_session(ForkSessionRequest, cancellation, connection)
handle_prompt(..) returns StopReasonreturns the full PromptResponse, with the turn's token usage
AcpServerConfig { agent, session_service, …, session_controls }adds standing_permissions, authenticator, system_prompts, providers, governance (GovernanceControl::new() in a struct literal)

adk-awp

InMemoryEventSubscriptionService delivers events over HTTP with Standard Webhooks signatures, and refuses a subscription whose callback URL names a loopback, private, link-local or other non-public address. An in-cluster receiver needs a delivery that allows private networks:

use adk_awp::events::InMemoryEventSubscriptionService;
use adk_core::egress::EgressPolicy;
use adk_core::webhook_delivery::WebhookDelivery;

let subscriptions = InMemoryEventSubscriptionService::new().with_delivery(
    WebhookDelivery::new().with_egress_policy(EgressPolicy::allow_private_networks()),
);

The 1.x types and helpers change as well:

  • The capability manifest carries access levels and schemas. build_manifest and GET /awp/manifest keep them: CapabilityEntry gains access_level: Option<TrustLevel> (accessLevel, omitted when absent), and BusinessCapability gains input_schema and output_schema, read from business.toml. The wire change is additive; struct literals add the fields.
  • business_context_to_toml reports AwpConfigError::Serialize for a context TOML cannot represent, instead of AwpConfigError::WatcherError.
  • sign_payload and verify_signature are deprecated: event deliveries carry Standard Webhooks signatures, which receivers verify with adk_core::webhook::WebhookVerifier. The sha256=<hex_digest> pair stays for receivers of the earlier format and warns on use.

Moving a site to AWP 2.0 is covered in Migrating from AWP 1.x to 2.0.

adk-retry-reflect

RetryTracker keeps counts per invocation, so its methods take the invocation ID, the tool name, and the call key:

use adk_retry_reflect::RetryTracker;

// 2.3
let mut tracker = RetryTracker::new();
let attempts = tracker.increment("search:call-1");
let total = tracker.total();
use adk_retry_reflect::RetryTracker;

// 3.0
let mut tracker = RetryTracker::new();
let attempts = tracker.increment("invocation-1", "search", "call-1");
let total = tracker.total("invocation-1");

adk-telemetry

The GenAI spans follow the current OpenTelemetry GenAI conventions, those of the semantic-conventions-genai repository (Telemetry). Dashboards, alerts and queries that read the old names need the new ones; there is no dual emission, since the 2.x names (total_tokens, cache_read_tokens, thinking_tokens) matched no released version of the conventions.

2.x3.0
Model span gen_ai.generate with gen_ai.system{gen_ai.operation.name} {gen_ai.request.model}, such as chat claude-sonnet-5-5, with gen_ai.provider.name and gen_ai.operation.name
gen_ai.system values gemini, bedrock, azure-aigen_ai.provider.name values gcp.gemini (gcp.vertex_ai on Vertex), aws.bedrock, azure.ai.inference
gen_ai.usage.total_tokensNot recorded; add input and output
gen_ai.usage.cache_read_tokens, cache_creation_tokensgen_ai.usage.cache_read.input_tokens, gen_ai.usage.cache_write.input_tokens
gen_ai.usage.thinking_tokensgen_ai.usage.reasoning.output_tokens
gen_ai.usage.audio_input_tokens, audio_output_tokensgen_ai.usage.audio.input_tokens, gen_ai.usage.audio.output_tokens
gen_ai.request.stream = false on a unary callAbsent; present (true) only when streaming
Agent span agent.executeExported as invoke_agent {agent} with gen_ai.operation.name, gen_ai.agent.name
Tool span execute_tool {tool} with tool.nameThe same name, with gen_ai.operation.name, gen_ai.tool.name, gen_ai.tool.type, gen_ai.tool.call.id
Finish reasons max_tokens, tool_calls (map_finish_reason)length, tool_call
SemconvConfig { capture_content: true }SemconvConfig { capture_content: CaptureContent::SpanOnly }, or OTEL_INSTRUMENTATION_GENAI_CAPTURE_CONTENT=SPAN_ONLY
ContentEventEmitter::emit_prompt, emit_completion (gen_ai.content.prompt, gen_ai.content.completion)ContentEventEmitter::emit_inference_details (gen_ai.client.inference.operation.details)
semconv::GEN_AI_SYSTEM, GEN_AI_USAGE_TOTAL_TOKENS, GEN_AI_USAGE_CACHE_READ_TOKENS, GEN_AI_USAGE_CACHE_CREATION_TOKENS, GEN_AI_USAGE_THINKING_TOKENS, GEN_AI_CONTENT_PROMPT, GEN_AI_CONTENT_COMPLETIONGEN_AI_PROVIDER_NAME, GEN_AI_USAGE_CACHE_READ_INPUT_TOKENS, GEN_AI_USAGE_CACHE_WRITE_INPUT_TOKENS, GEN_AI_USAGE_REASONING_OUTPUT_TOKENS, GEN_AI_INFERENCE_DETAILS_EVENT
GenAiSpanBuilder::top_k(f64)top_k(i64)
Exhaustive matches on GenAiProvider, GenAiOperationAdd a wildcard arm: both are #[non_exhaustive]

The tracing span names agent.execute, gen_ai.generate and execute_tool are unchanged, so the in-process debug exporter and the SQLite exporter keep their keys; only the exported OpenTelemetry name follows the conventions.

adk-cli

The adk-rust binary runs on the harness (spec 3.1, adk-harness):

Command2.3.03.0Keep the 2.3.0 behaviour
adk-rust without a subcommandThe chat REPLThe harness in ask mode in the current directory, full screen on a capable terminal: workspace-confined file tools, host bash behind per-call approval, and long-term facts kept in harness.dbadk-rust chat
adk-rust serveServed the chat agentServes the harness in plan mode with the approval inbox under /api/approvals; a host other than loopback needs --auth-token or ADK_SERVE_TOKENadk-rust serve --agent chat
adk-rust code, goal, ultracodeEdited files and ran commands without askingRun on the harness in ask mode: edits and host commands wait for approval; without a terminal and without --yes, code holds the calls, prints the session id and exits with status 3--yes, or --mode

The REPL, code and goal make one extra model call when a session ends, to keep facts for later sessions; --no-memory or --ephemeral keeps none. adk_cli::serve::run_serve logs its listening address through tracing instead of printing it.

adk-rust features

3.0.0 removes the 19 umbrella features that only aliased a sibling, and folds what each compiled into that sibling, so replacing the name keeps the same code. Cargo rejects a manifest that names a removed feature, so the build fails until the name is replaced.

Removed adk-rust featureUse insteadNotes
cerebras, fireworks, mistral, perplexity, sambanova, togetheropenaiConstruct the client with OpenAICompatible::new(OpenAICompatibleConfig::<provider>(api_key, model))
whisper-onnx, distil-whisper, moonshine, chatterboxaudio-onnxaudio-onnx now compiles all four models
action-code, action-db, action-emailactionaction now compiles the database and email placeholders
action-rssaction-httpaction-http now compiles the RSS node
a2aserverserver already enabled A2A v1
agent-registryserveradk_rust::registry is now available with server
cli-deepseek, cli-groqclicli now compiles the DeepSeek and Groq providers
personasevaladk_rust::personas is now available with eval

Member crates drop the features that compiled nothing:

CrateRemoved featureUse instead
adk-modelcerebras, fireworks, mistral, perplexity, sambanova, together, xaiopenai with the OpenAICompatibleConfig preset
adk-audiostreamingnothing: the streaming methods are always compiled
adk-authadk-servernothing: auth-bridge no longer needs adk-server
adk-geministudio (was the default)nothing: the AI Studio backend is always compiled
adk-telemetrymetricsotlp
adk-graphaction-db-mongo, action-db-redisaction-db, which builds the MongoDB and Redis placeholders
adk-graphaction-codeaction, which builds the code node
adk-audiovadnothing: VadProcessor is always compiled; desktop-audio no longer lists it

adk-audio's whisper-onnx, distil-whisper, moonshine and chatterbox, adk-graph's action-db, action-email and action-rss, adk-server's agent-registry, adk-eval's personas and adk-cli's deepseek and groq gate code and are unchanged.

Verifying your upgrade

cargo update
cargo check --all-targets
cargo test
Migrating from ADK-Rust 2.x to 3.0 - ADK-Rust दस्तावेज़ीकरण | ADK-Rust