Interface: ActivityAsToolOptions
googleAdkAgentsWorkflow.ActivityAsToolOptions
Options for activityAsTool.
Properties
activity
• Optional activity: ActivityOptions
Per-call Activity configuration (timeouts, retry, task queue).
description
• description: string
Description advertised to the model.
name
• name: string
The registered Activity name to dispatch. Must match an @activity-style
function registered on the worker (e.g. via the worker's activities).
parameters
• Optional parameters: Schema
Parameter schema advertised to the model. The model's tool-call arguments are passed as the Activity's single argument. Defaults to an empty object schema.
requireConfirmation
• Optional requireConfirmation: ActivityRequireConfirmation
Gate the Activity behind human approval, like ADK's
FunctionTool({ requireConfirmation }). The Activity is NOT scheduled on
the pass that raises the confirmation request, nor after a rejection; it
runs once the resumed turn carries the approval (see hitlConfirmationResponse).
A predicate must be a pure function of the arguments: ADK re-evaluates it
when binding the approval to the pinned call and refuses the approval if
it then answers false. Only enforced on an LlmAgent turn — ADK 2.0's
workflow ToolNode does not route through the confirmation path, so a
gated tool used directly as a graph node returns the "requires
confirmation" error as its output instead of pausing; use a RequestInput
node for graph-level approval.