Skip to main content

Crate adk_rust

Crate adk_rust 

Source
Expand description

§Agent Development Kit (ADK) for Rust

Crates.io Documentation License

A flexible and modular framework for developing and deploying AI agents in Rust. ADK-Rust is model-agnostic and deployment-agnostic: this umbrella crate re-exports the ADK-Rust crates behind feature flags grouped into four tiers.

§Quick Start

Create your first AI agent in minutes:

use adk_rust::prelude::*;
use adk_rust::Launcher;
use std::sync::Arc;

#[tokio::main]
async fn main() -> std::result::Result<(), Box<dyn std::error::Error>> {
    let api_key = std::env::var("GOOGLE_API_KEY")?;
    let model = GeminiModel::new(&api_key, "gemini-3.8-flash")?;

    let agent = LlmAgentBuilder::new("assistant")
        .description("A helpful AI assistant")
        .instruction("You are a friendly assistant. Answer questions concisely.")
        .model(Arc::new(model))
        .build()?;

    // Run in interactive console mode
    Launcher::new(Arc::new(agent)).run().await?;
    Ok(())
}

§Installation

Add to your Cargo.toml:

[dependencies]
adk-rust = "3.0.0"
tokio = { version = "1.40", features = ["full"] }
dotenvy = "0.15"  # For loading .env files

§Feature Presets

# Minimal (default) — agents, Gemini, runner, sessions (fastest build)
adk-rust = "3.0.0"

# Standard — minimal + OpenAI, Anthropic (and the adk-anthropic client), skills, graph,
# auth, server, eval, guardrail, plugin, artifacts, tools, memory, telemetry, computer-use
adk-rust = { version = "3.0.0", features = ["standard"] }

# Enterprise — standard + realtime, browser, rag, payments, awp, and autonomy: the
# harness, its kernel, durable and background runs, approvals and signed audit
adk-rust = { version = "3.0.0", features = ["enterprise"] }

# Full — enterprise + audio, code, sandbox, code-tools, the AWP website, vision, and the
# graph-functional, graph-node-cache, graph-delta, graph-time-travel, and graph-yaml capabilities
adk-rust = { version = "3.0.0", features = ["full"] }

# Custom — pick exactly what you need
adk-rust = { version = "3.0.0", default-features = false, features = [
    "agents", "gemini", "tools", "sessions", "openai", "openrouter"
] }

§Autonomous Agents

3.0 builds agents that work on their own inside limits you set: goals that iterate until a check passes and park on a decision; wake-ups on a schedule, a file change, a webhook or a queue message; one governed tool path with tool policies, approvals across runs, run budgets, spend caps, a kill switch and a signed audit log; and durable runs that resume after a crash.

ModuleFeatureWhat it holds
harnessharness (in enterprise and full)The governed harness agent: modes, standing approvals, a sandboxed shell, plans and durable goals
kernelharness-kernel (in enterprise and full)The agent kernel adk-rust up runs: processes, wake sources, the event bus and the control plane
surfacesurface (in no tier)The surface engine and the web home, over a harness or a kernel
visionvision (in full); vision-local adds the on-device backendsLocal-first perception: regions in source pixels, verified weights, the egress gate, cloud describers and sam-3.1; with harness, the vision pack

Build an autonomous agent takes one agent from a scaffold to running on its own.

§Agent Types

ADK-Rust provides several agent types for different use cases:

§LlmAgent - AI-Powered Reasoning

The core agent type that uses Large Language Models for intelligent reasoning. GoogleSearchTool below requires the tools feature (included in standard and above); the agent itself needs only the default tier:

use adk_rust::prelude::*;
use std::sync::Arc;

let api_key = std::env::var("GOOGLE_API_KEY").map_err(|e| AdkError::config(e.to_string()))?;
let model = GeminiModel::new(&api_key, "gemini-3.8-flash")?;

let agent = LlmAgentBuilder::new("researcher")
    .description("Research assistant with web search")
    .instruction("Search for information and provide detailed summaries.")
    .model(Arc::new(model))
    .tool(Arc::new(GoogleSearchTool::new()))  // Add tools
    .build()?;

§Workflow Agents - Deterministic Pipelines

For predictable, multi-step workflows:

use adk_rust::prelude::*;
use std::sync::Arc;

// Sequential: Execute agents in order
let pipeline = SequentialAgent::new(
    "content_pipeline",
    vec![researcher, writer, reviewer]
);

// Parallel: Execute agents concurrently
let parallel = ParallelAgent::new(
    "multi_analysis",
    vec![analyst1, analyst2]
);

// Loop: Iterate until condition met
let loop_agent = LoopAgent::new("iterative_refiner", vec![refiner])
    .with_max_iterations(5);

§Multi-Agent Systems

Build hierarchical agent systems with automatic delegation:

use adk_rust::prelude::*;
use std::sync::Arc;

let coordinator = LlmAgentBuilder::new("coordinator")
    .description("Development team coordinator")
    .instruction("Delegate coding tasks to specialists.")
    .model(model)
    .sub_agent(code_agent)   // Delegate to sub-agents
    .sub_agent(test_agent)
    .build()?;

§Tools

Give your agents capabilities beyond conversation. The tool types below require the tools feature (included in standard and above):

§Function Tools - Custom Operations

Convert any async function into a tool:

use adk_rust::prelude::*;
use adk_rust::serde_json::{json, Value};
use std::sync::Arc;

async fn get_weather(_ctx: Arc<dyn ToolContext>, args: Value) -> Result<Value> {
    let city = args["city"].as_str().unwrap_or("Unknown");
    // Your weather API call here
    Ok(json!({
        "temperature": 72.0,
        "conditions": "Sunny",
        "city": city
    }))
}

let weather_tool = FunctionTool::new(
    "get_weather",
    "Get current weather for a city",
    get_weather,
);

§Built-in Tools

Ready-to-use tools included with ADK:

  • GoogleSearchTool - Web search via Google
  • ExitLoopTool - Control loop termination
  • LoadArtifactsTool - Access stored artifacts

§MCP Tools - External Integrations

Connect to Model Context Protocol servers using the rmcp crate:

ⓘ
use adk_rust::prelude::*;
use adk_rust::tool::McpToolset;
use rmcp::{ServiceExt, transport::TokioChildProcess};
use tokio::process::Command;

// Connect to an MCP server (e.g., filesystem, database)
let client = ().serve(TokioChildProcess::new(
    Command::new("npx")
        .arg("-y")
        .arg("@modelcontextprotocol/server-filesystem")
        .arg("/path/to/dir")
)?).await?;

let mcp_tools = McpToolset::new(client);

// Add all MCP tools to your agent
let agent = builder.toolset(Arc::new(mcp_tools)).build()?;

§Sessions & State

Manage conversation context and working memory:

use adk_rust::prelude::*;
use adk_rust::session::{SessionService, CreateRequest};
use adk_rust::serde_json::json;
use std::collections::HashMap;

let session_service = InMemorySessionService::new();

// Create a session
let session = session_service.create(CreateRequest {
    app_name: "my_app".to_string(),
    user_id: "user_123".to_string(),
    session_id: None,
    state: HashMap::new(),
}).await?;

// Read state (State trait provides read access)
let state = session.state();
let config = state.get("app:config");  // Returns Option<Value>

§Callbacks

Intercept and customize agent behavior:

use adk_rust::prelude::*;
use std::sync::Arc;

let agent = LlmAgentBuilder::new("monitored_agent")
    .model(model)
    // Modify or inspect model responses
    .after_model_callback(Box::new(|_ctx, response| {
        Box::pin(async move {
            println!("Model responded");
            Ok(Some(response)) // Return modified response or None to keep original
        })
    }))
    // Track tool usage
    .before_tool_callback(Box::new(|_ctx| {
        Box::pin(async move {
            println!("Tool about to be called");
            Ok(None) // Continue execution
        })
    }))
    .build()?;

§Artifacts

Store and retrieve binary data (images, files, etc.). Requires the artifacts feature (included in standard and above):

use adk_rust::prelude::*;
use adk_rust::artifact::{ArtifactService, SaveRequest, LoadRequest};

let artifact_service = InMemoryArtifactService::new();

// Save an artifact
let response = artifact_service.save(SaveRequest {
    app_name: "my_app".to_string(),
    user_id: "user_123".to_string(),
    session_id: "session_456".to_string(),
    file_name: "sales_chart.png".to_string(),
    part: Part::Text { text: "chart data".to_string() },
    version: None,
}).await?;

// Load an artifact
let loaded = artifact_service.load(LoadRequest {
    app_name: "my_app".to_string(),
    user_id: "user_123".to_string(),
    session_id: "session_456".to_string(),
    file_name: "sales_chart.png".to_string(),
    version: None,
}).await?;

§Deployment Options

§Console Mode (Interactive CLI)

use adk_rust::prelude::*;
use adk_rust::Launcher;
use std::sync::Arc;

// Interactive chat in terminal
Launcher::new(agent).run().await?;

§Server Mode (REST API)

With the cli feature, Launcher is adk_cli::Launcher, which also serves the agent over HTTP on 127.0.0.1:

cargo run -- serve --port 8080

The server exposes GET /api/health, the session endpoints under /api/sessions and /api/apps/{app}/users/{user}/sessions, POST /api/run/{app}/{user}/{session} (SSE), and POST /api/run_sse. See adk-server for the full list. The web home of adk-surface (feature surface) is served by the harness launcher, or mounted on a server you build (spec 3.3 §5.1).

§Agent-to-Agent (A2A) Protocol

Expose your agent for inter-agent communication. Requires the server feature (included in standard and above):

use adk_rust::server::{create_app_with_a2a, ServerConfig};
use adk_rust::AgentLoader;

// Create server with A2A protocol support
let config = ServerConfig::new(agent_loader, session_service);
let app = create_app_with_a2a(config, Some("http://localhost:8080"));

// Run the server (requires axum dependency)
// let listener = tokio::net::TcpListener::bind("127.0.0.1:8080").await?;
// axum::serve(listener, app).await?;

§Observability

Built-in OpenTelemetry support for production monitoring. Requires the telemetry feature (included in standard and above); OTLP export adds telemetry-otlp:

use adk_rust::telemetry::init_telemetry;

// Basic telemetry with console logging
init_telemetry("my-agent-service")?;

// With `features = ["telemetry-otlp"]`, export spans to a collector instead:
// adk_rust::telemetry::init_with_otlp("my-agent-service", "http://localhost:4317")?;

// All agent operations now emit traces and metrics

§Architecture

ADK-Rust uses a layered architecture for modularity:

┌─────────────────────────────────────────────────────────────┐
│                    Application Layer                        │
│              Launcher • REST Server • A2A                   │
├─────────────────────────────────────────────────────────────┤
│                      Runner Layer                           │
│           Agent Execution • Event Streaming                 │
├─────────────────────────────────────────────────────────────┤
│                      Agent Layer                            │
│    LlmAgent • CustomAgent • Sequential • Parallel • Loop    │
├─────────────────────────────────────────────────────────────┤
│                     Service Layer                           │
│      Models • Tools • Sessions • Artifacts • Memory         │
└─────────────────────────────────────────────────────────────┘

§Feature Flags

FeatureDescriptionPreset
agentsAgent implementationsminimal (default)
modelsModel integrationsminimal (default)
geminiGemini model supportminimal (default)
runnerExecution runtimeminimal (default)
sessionsSession managementminimal (default)
openaiOpenAI model supportstandard
anthropic / anthropic-clientAnthropic model support / the adk-anthropic clientstandard
toolsTool systemstandard
skillsSkill discoverystandard
artifactsArtifact storagestandard
memorySemantic memorystandard
telemetryOpenTelemetrystandard
guardrailInput/output validationstandard
authAccess controlstandard
pluginPlugin systemstandard
serverHTTP server + A2Astandard
graphGraph workflowsstandard
evalAgent evaluationstandard
computer-useGoverned desktop-automation orchestrationstandard
realtimeVoice/audio streamingenterprise
browserBrowser automationenterprise
ragRAG pipelineenterprise
paymentsAgentic commerce (ACP/AP2)enterprise
awpAgentic Web Protocolenterprise
autonomyAn agent that runs unattended: the harness and its kernel, durable and background runs, cron and webhook wake-ups, the approvals service, SQLite stores, signed auditenterprise
code, sandbox, code-toolsCode execution and sandboxed executionfull
audioAudio processingfull
graph-functional, graph-node-cache, graph-delta, graph-time-travel, graph-yamlGraph capabilitiesfull
harnessThe governed, durable harness agent (adk-harness)enterprise
harness-kernelThe agent kernel, the harness’s always-on form (adk-kernel)enterprise
websiteThe AWP website product (adk-website, adk-site)full
visionLocal-first perception (adk-vision): regions, manifests, the egress gate, cloud describers, sam-3.1, the image privacy guardrailfull
vision-localvision + the on-device backends: RF-DETR, EfficientSAM, SAM 2.1, SigLIP 2, PP-OCRv6, PaddleOCR-VL-1.6opt-in
surfaceAgent surfaces: the engine and the web home (adk-surface)opt-in
harness-browser, harness-computer-use, harness-payments, harness-voice, harness-managedHarness packsopt-in
cliCLI launcher with serve modeopt-in
managed-runtimeManaged agent runtime (adk-managed)opt-in
enterprise-clientEnterprise client SDK (adk-enterprise)opt-in
gemini-agent-platformEvery Gemini Enterprise Agent Platform integration except realtime transports and host-side deploy toolingopt-in
gemini-agent-platform-fullgemini-agent-platform + Vertex AI Live API (realtime stack)opt-in
gcp-deployAgent Engine deployment client (host-side; not part of gemini-agent-platform)opt-in

Production backends (postgres-session, redis-memory, …), additional providers, and specialist integrations are opt-in features as well; Cargo.toml lists every one.

§Examples

The adk-playground repository holds the teaching examples. This repository’s examples directory holds the standalone scenario and release-validation crates that CI runs.

ADK-Rust is composed of modular crates that can be used independently:

Re-exports§

pub use anyhow;
pub use futures;
pub use serde;
pub use serde_json;
pub use tokio;

Modules§

acting
Core traits and types.
action_ledger
Core traits and types.
agentagents
Agent implementations (LLM, Custom, Workflow agents).
agent_invoker
Core traits and types.
agent_loader
Core traits and types.
anthropic_clientanthropic-client
Anthropic API client types and HTTP client.
approval
Core traits and types.
artifactartifacts
Artifact storage.
audioaudio
Audio processing pipeline (experimental — full preset).
audit_log
Core traits and types.
authauth
Authentication and access control.
awpawp
Agentic Web Protocol: discovery, capability manifests, trust, consent, and events for agent-facing websites.
browserbrowser
Browser automation (WebDriver).
budget
Core traits and types.
callbacks
Core traits and types.
clock
Core traits and types.
codecode
Code execution substrate (experimental — full preset).
codeact_montycodeact-monty
Python CodeRuntime for the CodeActAgent, backed by the Monty interpreter (experimental).
computer
Core traits and types.
computer_usecomputer-use
Graph, auth, and v8 wire contracts for safe computer-use orchestration.
context
Core traits and types.
credential
Core traits and types.
decision
Core traits and types.
egress
Core traits and types.
error
Core traits and types.
evaleval
Agent evaluation framework.
event
Core traits and types.
event_summarizer
Core traits and types.
evidence
Core traits and types.
governance
Core traits and types.
governance_state
Core traits and types.
graphgraph
Graph-based workflow engine (LangGraph-inspired).
grounding
Core traits and types.
guardrailguardrail
Guardrails for safety and policy enforcement.
harnessharness
The governed, durable harness agent (spec 3.1 §8.4).
history
Core traits and types.
identity
Core traits and types.
instruction_template
Core traits and types.
intra_compaction
Core traits and types.
kernelharness-kernel
The agent kernel, the always-on form of the harness (spec 3.2 §8.2).
lease
Core traits and types.
memorymemory
Memory system with semantic search.
metering
Core traits and types.
modelmodels
Model integrations (Gemini, etc.).
paymentpayments
Agentic commerce and payment orchestration.
personaseval
User personas for evaluation.
pluginplugin
Plugin system for extending agent behavior.
policy
Core traits and types.
prelude
Convenience prelude for common imports.
principal
Core traits and types.
queue_source
Core traits and types.
ragrag
Retrieval-Augmented Generation (RAG) pipeline.
realtimerealtime
Real-time bidirectional streaming (voice, video).
registryserver
Agent Registry REST API for agent discovery and management.
request_context
Core traits and types.
review
Core traits and types.
run_store
Core traits and types.
runnerrunner
Agent execution runtime.
sandboxsandbox
Isolated code execution runtime (experimental — full preset).
schedule
Core traits and types.
schema_adapter
Core traits and types.
schema_cache
Core traits and types.
schema_utils
Core traits and types.
serverserver
HTTP server (REST + A2A).
sessionsessions
Session management.
shared_state
Core traits and types.
sitewebsite
The site pipeline of an AWP 2.0 website (spec 3.5 §7.8): content as files, the built-in generator, the launch gate, signed releases in the site log, hosts, migration and freeze.
skillskills
AgentSkills parsing, indexing, and runtime injection helpers.
spend
Core traits and types.
steering
Core traits and types.
subagent
Core traits and types.
subject
Core traits and types.
surfacesurface
Agent surfaces: the engine every surface runs on, and the web home (spec 3.3).
telemetrytelemetry
Telemetry (OpenTelemetry integration).
tooltools
Tool system and built-in tools.
tool_concurrency
Core traits and types.
tool_response
Core traits and types.
types
Core traits and types.
usage
Core traits and types.
visionvision
Local-first perception for agents (spec 3.7).
webhookwebhooks
Core traits and types.
webhook_deliverywebhook-delivery
Core traits and types.
websitewebsite
The AWP 2.0 website product (spec 3.5 Part C, §7.1, D-14): site kinds and their charter templates, the team of eight agents, onboarding, jobs, incidents, alarms and the weekly review.

Structs§

ActingConfig
Core traits and types.
ActingContext
Core traits and types.
ActionRecord
Core traits and types.
AdkError
Core traits and types.
AdkIdentity
Core traits and types.
AgentCapabilities
Core traits and types.
AgentCredential
Core traits and types.
AgentId
Core traits and types.
AgentPrincipal
Core traits and types.
AgentProfile
Core traits and types.
AgentTopology
Core traits and types.
AgentTopologyMember
Core traits and types.
AgentTopologyRelationship
Core traits and types.
AgentTransferRequest
Core traits and types.
AppName
Core traits and types.
ApprovalCall
Core traits and types.
ApprovalCursor
Core traits and types.
ApprovalDecision
Core traits and types.
ApprovalDelegation
Core traits and types.
ApprovalNotification
Core traits and types.
ApprovalPolicy
Core traits and types.
ApprovalRequest
Core traits and types.
ApprovalRequestQuery
Core traits and types.
ApprovalRoute
Core traits and types.
ApprovalScope
Core traits and types.
ApprovalTick
Core traits and types.
ArtifactLocator
Core traits and types.
BatchCall
Core traits and types.
BatchGroup
Core traits and types.
BlobResourceContents
Core traits and types.
BudgetExceeded
Core traits and types.
BudgetTracker
Core traits and types.
BudgetUsage
Core traits and types.
BuiltinToolGovernor
Core traits and types.
BuiltinToolUse
Core traits and types.
ChoiceOption
Core traits and types.
CitationMetadata
Core traits and types.
CitationSource
Core traits and types.
ClaimedRun
Core traits and types.
CompactedHistory
Core traits and types.
ConcurrencyPermit
Core traits and types.
Content
Core traits and types.
ContextCacheConfig
Core traits and types.
CredentialSecret
Core traits and types.
DataDestination
Core traits and types.
Decider
Core traits and types.
Decision
Core traits and types.
DeclarativePolicy
Core traits and types.
DeclarativePolicyBuilder
Core traits and types.
DelegationScope
Core traits and types.
DelegationWindow
Core traits and types.
ErrorDetails
Core traits and types.
ErrorDiagnostics
Core traits and types.
EscalationStep
Core traits and types.
Event
Core traits and types.
EventActions
Core traits and types.
EventCompaction
Core traits and types.
EventTextDeltas
Core traits and types.
EventsCompactionConfig
Core traits and types.
ExecutionIdentity
Core traits and types.
FileDataPart
Core traits and types.
FirePlan
Core traits and types.
FunctionResponseData
Core traits and types.
GenerateContentConfig
Core traits and types.
GenericSchemaAdapter
Core traits and types.
GovernanceControl
Core traits and types.
GovernanceMirrorConfig
Core traits and types.
GovernanceState
Core traits and types.
GovernedCall
Core traits and types.
GroundingSource
Core traits and types.
HeldToolCall
Core traits and types.
HistoryCompactionRequest
Core traits and types.
ImageEvidence
Core traits and types.
InMemoryActionLedger
Core traits and types.
InMemoryApprovalStore
Core traits and types.
InMemoryGovernanceStateStore
Core traits and types.
InMemoryLeaseStore
Core traits and types.
InMemoryQueueSource
Core traits and types.
InMemoryRunStore
Core traits and types.
InMemoryScheduleStore
Core traits and types.
InMemorySpendLedger
Core traits and types.
InboxPage
Core traits and types.
InboxQuery
Core traits and types.
IngressReport
Core traits and types.
InlineDataPart
Core traits and types.
IntraCompactionConfig
Core traits and types.
InvocationId
Core traits and types.
Jitter
Core traits and types.
Launcherrunner
Lightweight console launcher — always available with the runner feature.
Lease
Core traits and types.
LedgerAnswer
Core traits and types.
LedgeredCall
Core traits and types.
LlmEventSummarizer
Core traits and types.
LlmRequest
Core traits and types.
LlmResponse
Core traits and types.
LlmSpendEstimate
Core traits and types.
ManualClock
Core traits and types.
MemoryEntry
Core traits and types.
MeteredLlm
Core traits and types.
MeteredUsage
Core traits and types.
ModelApprover
Core traits and types.
ModelCallMeter
Core traits and types.
ModelCallScope
Core traits and types.
ModelSpendHold
Core traits and types.
MultiAgentLoader
Core traits and types.
NativeCompaction
Core traits and types.
NativeCompactionRequest
Core traits and types.
NativeWebSearch
Core traits and types.
NewRun
Core traits and types.
PendingApproval
Core traits and types.
PolicyCall
Core traits and types.
PolicyRule
Core traits and types.
QueueIngress
Core traits and types.
QueueMessage
Core traits and types.
RequestContext
Core traits and types.
RequestedCall
Core traits and types.
RequestedVia
Core traits and types.
ReservationId
Core traits and types.
ResolvedContext
Core traits and types.
RetryBackoff
Core traits and types.
RetryBudget
Core traits and types.
RetryHint
Core traits and types.
ReviewScope
Core traits and types.
RunBudget
Core traits and types.
RunConfig
Core traits and types.
RunConfigBuilder
Core traits and types.
RunFilter
Core traits and types.
RunLimits
Core traits and types.
RunRecord
Core traits and types.
RuntimeToolset
Core traits and types.
Schedule
Core traits and types.
SchemaCache
Core traits and types.
ScopedToken
Core traits and types.
ScreenPoint
Core traits and types.
Screenshot
Core traits and types.
SealedCall
Core traits and types.
SecretRequest
Core traits and types.
SessionId
Core traits and types.
SharedState
Core traits and types.
SingleAgentLoader
Core traits and types.
SpendKey
Core traits and types.
SpendLimit
Core traits and types.
SpendLimits
Core traits and types.
StaticIdentitySource
Core traits and types.
StaticSubjectDelegation
Core traits and types.
SteerReceipt
Core traits and types.
SteeringInbox
Core traits and types.
SteeringMarker
Core traits and types.
SteeringMessage
Core traits and types.
StoreApprovalService
Core traits and types.
StrictestPolicy
Core traits and types.
SubagentLaunch
Core traits and types.
SubagentParent
Core traits and types.
SubagentRecord
Core traits and types.
SubagentRequest
Core traits and types.
SubagentScope
Core traits and types.
SubagentStart
Core traits and types.
SubagentTarget
Core traits and types.
SubjectDelegationRequest
Core traits and types.
SubjectRef
Core traits and types.
SystemClock
Core traits and types.
TextResourceContents
Core traits and types.
ToolApproval
Core traits and types.
ToolCallView
Core traits and types.
ToolCallbackContext
Core traits and types.
ToolCeiling
Core traits and types.
ToolConcurrencyConfig
Core traits and types.
ToolConcurrencyManager
Core traits and types.
ToolConfirmationRequest
Core traits and types.
ToolDeclarations
Core traits and types.
ToolDeclarationsKeys
Core traits and types.
ToolDeclarationsValues
Core traits and types.
ToolGate
Core traits and types.
ToolOrigin
Core traits and types.
ToolOutcome
Core traits and types.
ToolPolicyRequest
Core traits and types.
ToolProfile
Core traits and types.
ToolResultView
Core traits and types.
ToolReview
Core traits and types.
UnitRate
Core traits and types.
Url
Core traits and types.
UsageCall
Core traits and types.
UsageHold
Core traits and types.
UsageMetadata
Core traits and types.
UsageVector
Core traits and types.
UserId
Core traits and types.
WithheldBuiltinTool
Core traits and types.
WorkflowPosition
Core traits and types.

Enums§

ActionOutcome
Core traits and types.
ActuationOutput
Core traits and types.
AgentInteractionMode
Core traits and types.
AgentKind
Core traits and types.
AgentRelationshipKind
Core traits and types.
AgentTransferDecision
Core traits and types.
ApprovalAction
Core traits and types.
ApprovalEventKind
Core traits and types.
ApprovalRisk
Core traits and types.
ApprovalState
Core traits and types.
ApproverSelector
Core traits and types.
ArgPredicate
Core traits and types.
BackpressurePolicy
Core traits and types.
BeforeModelResult
Core traits and types.
BudgetLimit
Core traits and types.
BuiltinToolWithholding
Core traits and types.
CompactionTrigger
Core traits and types.
ComputerAction
Core traits and types.
ComputerActionKind
Core traits and types.
CredentialKind
Core traits and types.
DataLocality
Core traits and types.
Effort
Core traits and types.
EmbeddedResource
Core traits and types.
Enqueued
Core traits and types.
ErrorCategory
Core traits and types.
ErrorComponent
Core traits and types.
Evidence
Core traits and types.
ExpiryAction
Core traits and types.
FinishReason
Core traits and types.
FollowUp
Core traits and types.
GovernanceScope
Core traits and types.
IdentityError
Core traits and types.
IncludeContents
Core traits and types.
MissedFirePolicy
Core traits and types.
MouseButton
Core traits and types.
NativeWebSearchTool
Core traits and types.
OnConflict
Core traits and types.
Part
Core traits and types.
PolicyDecision
Core traits and types.
PrincipalError
Core traits and types.
RequestedViaKind
Core traits and types.
ReviewVerdict
Core traits and types.
RevocationScope
Core traits and types.
RunCheckpointRef
Core traits and types.
RunOutcome
Core traits and types.
RunState
Core traits and types.
ScheduleSpec
Core traits and types.
ScrollDirection
Core traits and types.
SharedStateError
Core traits and types.
SpendError
Core traits and types.
SpendPeriod
Core traits and types.
SteerOutcome
Core traits and types.
StreamingMode
Core traits and types.
SubagentMode
Core traits and types.
SubagentStatus
Core traits and types.
SubjectKind
Core traits and types.
ToolAuthorization
Core traits and types.
ToolConfirmationDecision
Core traits and types.
ToolConfirmationPolicy
Core traits and types.
ToolEffect
Core traits and types.
ToolExecutionStrategy
Core traits and types.
ToolResultStatus
Core traits and types.
UsageUnit
Core traits and types.
ValidationMode
Core traits and types.

Constants§

APPROVAL_REAPPLY_GRACE
Core traits and types.
BUDGET_LIMIT_KEY
Core traits and types.
BUDGET_RECORDED_KEY
Core traits and types.
BUILTIN_TOOLS_WITHHELD_KEY
Core traits and types.
BUILTIN_TOOL_ORIGIN
Core traits and types.
CALLBACK_PANICKED_CODE
Core traits and types.
CONFIRMATION_PENDING_STATUS
Core traits and types.
DEFAULT_APPROVAL_PAGE
Core traits and types.
DEFAULT_RESERVATION_TTL
Core traits and types.
DEFAULT_REVIEW_TIMEOUT
Core traits and types.
DEFAULT_TOOL_CONFIRMATION_TIMEOUT
Core traits and types.
DRAW_TOOL_NAMES
Core traits and types.
DUPLICATE_TOOL_NAME_CODE
Core traits and types.
GENERATED_CALL_ID_PREFIX
Core traits and types.
GOVERNANCE_FROZEN_CODE
Core traits and types.
GOVERNANCE_STALE_CODE
Core traits and types.
INVALID_TOOL_ARGUMENTS_KEY
Core traits and types.
KEY_PREFIX_APP
Core traits and types.
KEY_PREFIX_TEMP
Core traits and types.
KEY_PREFIX_USER
Core traits and types.
MAX_INLINE_DATA_SIZE
Core traits and types.
MAX_STATE_KEY_LEN
Core traits and types.
MODEL_REVIEWER_PREFIX
Core traits and types.
NOT_RUN_PREFIX
Core traits and types.
OUTCOME_UNKNOWN_STATUS
Core traits and types.
PRINCIPAL_NOT_ALLOWED_CODE
Core traits and types.
REQUESTED_CALL_ID_PREFIX
Core traits and types.
REQUESTED_CALL_METADATA_KEY
Core traits and types.
RESULT_WITHHELD_STATUS
Core traits and types.
REVIEW_SOURCE
Core traits and types.
SPEND_LIMIT_EXCEEDED_CODE
Core traits and types.
STATIC_TOOL_ORIGIN
Core traits and types.
STEER_INVALID_MESSAGE_CODE
Core traits and types.
STEER_NO_ACTIVE_RUN_CODE
Core traits and types.
SUBJECT_MISMATCH_CODE
Core traits and types.
TOOL_ERROR_MESSAGE_LIMIT
Core traits and types.
TOOL_INVALID_ARGUMENTS_CODE
Core traits and types.
TOOL_PERMISSION_DENIED_CODE
Core traits and types.
TOOL_PROGRESS_CALL_ID_KEY
Core traits and types.
TOOL_PROGRESS_STREAM_KEY
Core traits and types.
TOOL_RESULT_ERROR_CATEGORY_KEY
Core traits and types.
TOOL_RESULT_ERROR_CODE_KEY
Core traits and types.
TOOL_RESULT_STATUS_KEY
Core traits and types.
UNBOUNDED_HOLD_MICRO_USD
Core traits and types.
UPSTREAM_EXCERPT_BYTES
Core traits and types.

Traits§

ActionLedger
Core traits and types.
Agent
Core traits and types.
AgentInvoker
Core traits and types.
AgentLoader
Core traits and types.
ApprovalNotifier
Core traits and types.
ApprovalResolution
Core traits and types.
ApprovalRouter
Core traits and types.
ApprovalService
Core traits and types.
ApprovalStore
Core traits and types.
ApproverDirectory
Core traits and types.
Artifacts
Core traits and types.
BaseEventsSummarizer
Core traits and types.
CacheCapable
Core traits and types.
CallbackContext
Core traits and types.
Choice
Core traits and types.
Clock
Core traits and types.
ComputerActuator
Core traits and types.
CredentialBroker
Core traits and types.
DurableRunStore
Core traits and types.
GovernanceStateStore
Core traits and types.
GovernanceWatch
Core traits and types.
HistoryCompactor
Core traits and types.
IdentitySource
Core traits and types.
InvocationContext
Core traits and types.
InvocationHooks
Core traits and types.
LeaseStore
Core traits and types.
Llm
Core traits and types.
Memory
Core traits and types.
QueueSource
Core traits and types.
ReadonlyContext
Core traits and types.
ReadonlyState
Core traits and types.
RequestedCallSeal
Core traits and types.
ScheduleStore
Core traits and types.
SchemaAdapter
Core traits and types.
SecretService
Core traits and types.
Session
Core traits and types.
SpendLedger
Core traits and types.
State
Core traits and types.
SubagentHost
Core traits and types.
SubjectDelegationPolicy
Core traits and types.
Tool
Core traits and types.
ToolCallScreen
Core traits and types.
ToolConfirmationHandler
Core traits and types.
ToolContext
Core traits and types.
ToolPolicy
Core traits and types.
ToolRegistry
Core traits and types.
ToolResultScreen
Core traits and types.
ToolReviewer
Core traits and types.
Toolset
Core traits and types.

Functions§

authorize_tool_call
Core traits and types.
begin_ledgered_call
Core traits and types.
bind_markdown_citations
Core traits and types.
budget_exceeded_event
Core traits and types.
builtin_tool_configuration
Core traits and types.
confirm_tool_call
Core traits and types.
confirmation_decision_available
Core traits and types.
confirmation_pending_response
Core traits and types.
decide
Core traits and types.
ensure_crypto_provider
Core traits and types.
ensure_unique_tool_names
Core traits and types.
event_belongs_to_branch
Core traits and types.
firing_idempotency_key
Core traits and types.
generate_metered
Core traits and types.
generate_with_budget
Core traits and types.
guard_callback
Core traits and types.
held_call_compaction_limit
Core traits and types.
held_call_ledger_key
Core traits and types.
held_tool_calls
Core traits and types.
inject_session_state
Core traits and types.
interrupted_call_response
Core traits and types.
invalid_tool_arguments
Core traits and types.
invalid_tool_arguments_reason
Core traits and types.
is_confirmation_pending
Core traits and types.
is_not_run
Core traits and types.
is_outcome_unknown
Core traits and types.
json_digest
Core traits and types.
json_error_summary
Core traits and types.
manual_idempotency_key
Core traits and types.
meter_stream
Core traits and types.
meter_usage
Core traits and types.
not_run_text
Core traits and types.
nullable_count
Core traits and types.
outcome_unknown_response
Core traits and types.
plan_fires
Core traits and types.
provider_from_env
Detect LLM provider from environment variables.
record_grounding_sources
Core traits and types.
record_outcome_unknown
Core traits and types.
resource_indicator
Core traits and types.
result_blocked_response
Core traits and types.
result_withheld_response
Core traits and types.
runagents and runner and sessions
High-level single-turn agent invocation.
screen_tool_result
Core traits and types.
screen_user_input_with
Core traits and types.
subject_mismatch_error
Core traits and types.
supersede_pending_responses
Core traits and types.
tool_call_fingerprint
Core traits and types.
tool_error_response
Core traits and types.
untrusted_block
Core traits and types.
upstream_excerpt
Core traits and types.
usd_to_micro_usd
Core traits and types.
validate_state_key
Core traits and types.
validate_steering_message
Core traits and types.
vendor_for_model
Core traits and types.
withdraw_held_call
Core traits and types.
workflow_resume_positions
Core traits and types.

Type Aliases§

AfterAgentCallback
Core traits and types.
AfterModelCallback
Core traits and types.
AfterToolCallback
Core traits and types.
AfterToolCallbackFull
Core traits and types.
BeforeAgentCallback
Core traits and types.
BeforeModelCallback
Core traits and types.
BeforeToolCallback
Core traits and types.
EventStream
Core traits and types.
GlobalInstructionProvider
Core traits and types.
HistoryProcessor
Core traits and types.
InstructionProvider
Core traits and types.
LlmResponseStream
Core traits and types.
OnToolErrorCallback
Core traits and types.
Result
Core traits and types.
ToolDeclarationsIter
Core traits and types.
ToolPredicate
Core traits and types.

Attribute Macros§

async_trait