AdkServerConfig

data class AdkServerConfig(val agentLoader: AgentLoader, val sessionService: SessionService, val artifactService: ArtifactService, val port: Int = DEFAULT_PORT, val host: String = DEFAULT_HOST, val apiServerSpanExporter: ApiServerSpanExporter = ApiServerSpanExporter(), val captureMessageContent: Boolean = false, val plugins: List<Plugin> = emptyList(), val webUiEnabled: Boolean? = null, val camelCaseEnforced: Boolean? = null, val includeAppInfo: Boolean? = null)

What an AdkApiServer or AdkDevServer needs to serve a set of agents over HTTP.

Constructors

Link copied to clipboard
constructor(agentLoader: AgentLoader, sessionService: SessionService, artifactService: ArtifactService, port: Int = DEFAULT_PORT, host: String = DEFAULT_HOST, apiServerSpanExporter: ApiServerSpanExporter = ApiServerSpanExporter(), captureMessageContent: Boolean = false, plugins: List<Plugin> = emptyList(), webUiEnabled: Boolean? = null, camelCaseEnforced: Boolean? = null, includeAppInfo: Boolean? = null)

Types

Link copied to clipboard
class Builder

Fluent builder for AdkServerConfig, provided primarily for Java callers. Any property left unset falls back to the same default as the constructor.

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Whether responses use the strict camelCase spelling. Off leaves every response as it is today: /version emits language_version and the development trace endpoints emit span_id and its siblings, which the Development UI reads under those names. Every other response has always been camelCase either way. Null means unset, so the default can move to true in a later release without overriding a deployment that pinned it; adk.wire.camelcase.enforced overrides it either way, so a deployment that cannot change code can still choose.

Link copied to clipboard

When true the server records prompt and response content into telemetry spans so the Dev UI trace view can display it. This may capture PII, so it defaults to false; enable it only for local development.

Link copied to clipboard

Interface AdkApiServer and AdkDevServer bind to; IPv4 loopback by default, since these endpoints are unauthenticated; nothing listens on ::1. Installing a module into your own engine binds whatever that engine was given, not this.

Link copied to clipboard

Whether to mount /apps/{appName}/app-info, which reports every agent's instruction and tool declarations; off when unset, since that is more than a deployment needs to publish. adk.app.info.enabled overrides it either way, as the Development UI property does, so a deployment that cannot change code can still turn the endpoint off. Experimental: setting it requires @OptIn(ExperimentalAppInfoFeature::class).

Link copied to clipboard
Link copied to clipboard
val port: Int
Link copied to clipboard
Link copied to clipboard

Whether to mount the Development UI; null leaves the choice to the server variant, off for AdkApiServer and on for AdkDevServer. The adk.web.ui.enabled property overrides it either way, so that a deployment which cannot change code can still turn the UI off; the corollary is that an ambient property beats an explicit setting here.

Functions

Link copied to clipboard

Returns a Builder initialized with this instance's properties, primarily for Java callers. Prefer it over copy from Java: copy takes every property positionally, so its signature changes whenever a property is added.